oops
[gnuradio.git] / gnuradio.spec
1 # SPEC file for gnuradio
2 #
3 #
4 # Source: ftp://ftp.gnu.org/gnu/gnuradio/gnuradio-3.2.2.tar.gz
5 #
6 # Signature: ftp://ftp.gnu.org/gnu/gnuradio/gnuradio-3.2.2.tar.gz.sig
7 #
8 %define name gnuradio
9 %define version 3.2.2
10 %define release 21
11 %define actual_name %{name}-%{version}
12
13 %define module_taglevel_varname release
14
15 Name: %{name}
16 Summary: GNU software radio
17 Version: %{version}
18 Release: %{release}
19 License: GPLv3
20 URL: ftp://ftp.gnu.org/gnu/gnuradio/gnuradio-3.2.2.tar.gz
21 Group: Productivity/Hamradio/Other
22 Source0: %{actual_name}.tar.gz
23 Source1:        10-usrp.rules
24 Patch0:         gnuradio-3.2-libtool.patch
25
26 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
27
28
29 BuildRequires: python python-numeric PyQt4 swig fftw sdcc gsl libtool 
30 BuildRequires: subversion guile cppunit gcc gcc-c++ make
31 BuildRequires: boost-devel >= 1.35
32 BuildRequires: python-devel fftw-devel boost-devel gsl-devel libusb-devel
33 BuildRequires: cppunit-devel
34
35
36 Requires: python python-numeric PyQt4 swig fftw libtool
37 Requires: boost >= 1.35
38
39 %description
40 gnuradio is a free software radio toolkit
41
42 %prep
43 %setup -q -n %{actual_name}
44 %patch0 -p1 -b .libtool
45
46
47 %build
48 export PKG_CONFIG_PATH="/usr/lib/pkgconfig"
49 # dirty hack to let gnuradio configure find sdcc
50 export PATH=%{_libexecdir}/sdcc:$PATH
51
52 ########## the bootstrap script basically reruns autoconf and automake
53 %if "%{distro}" == "Fedora" && %{distrorelease} >= 12
54 autoreconf -i
55 %configure --disable-doxygen
56 sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
57 sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
58 make %{?_smp_mflags}
59 %else
60 bash -x ./bootstrap
61 %configure --disable-doxygen
62 make
63 %endif
64
65 %install
66 rm -rf $RPM_BUILD_ROOT
67 make install DESTDIR=$RPM_BUILD_ROOT
68 install -D -m0644 %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/udev/rules.d/10-usrp.rules
69
70 #make DESTDIR=$RPM_BUILD_ROOT install
71 %makeinstall
72
73 %post
74 echo 'export PYTHONPATH=/usr/lib/python2.5/site-packages/' >> ~/.bashrc
75 /sbin/ldconfig
76
77 %postun
78 /sbin/ldconfig
79
80 %clean
81 rm -rf $RPM_BUILD_ROOT
82
83
84
85 %package -n %{name}-devel
86 Summary: gnuradio devel files
87 Version: %{version}
88 Release: %{release}
89 Group:   Productivity/Hamradio/Other
90 Requires: gnuradio
91
92 %description -n %{name}-devel
93 Devel package of gnuradio
94
95 %post -n %{name}-devel
96 /sbin/ldconfig
97
98 %postun -n %{name}-devel
99 /sbin/ldconfig
100
101 %files -n %{name}-devel
102 %defattr(-,root,root,-)
103 %{_includedir}/*
104 %{_libdir}/pkgconfig/*
105 %{_libdir}/lib*.la
106
107
108 %files -n %{name}
109 %defattr(-,root,root,-)
110 %{_bindir}/*
111 %dir /etc/gnuradio
112 %config /etc/gnuradio/*
113 %{_libdir}/lib*so*
114 %{_libdir}/python*/site-packages/
115 %{_datadir}/doc/*
116 %dir %{_datadir}/gnuradio
117 %{_datadir}/gnuradio/*
118 %dir %{_datadir}/usrp
119 %{_datadir}/usrp/*
120 # TO FIX: if the 2 following commands are removed, the rpmbuild fails!
121 # It's weird because rev2 and rev3 directories are indeed created at the 
122 # right place (/usr/share/rev*) when the rpm is installed...
123 %{_datadir}/rev2/*
124 %{_datadir}/rev4/*
125 %config(noreplace) %{_sysconfdir}/udev/rules.d/10-usrp.rules
126 %doc AUTHORS README README.hacking ChangeLog NEWS INSTALL COPYING
127
128
129
130 %changelog -n gnuradio
131 * Wed Oct 8 2009 Thierry Turletti <turletti@sophia.inria.fr> 3.2.2-2.1
132 - fixed lots of missing parameters...
133
134 * Thu Oct 1 2009 Thierry Turletti <turletti@sophia.inria.fr> 3.2.2-2.0
135 - derived from previous gnuradio-3.2 spec file written by Ben Yahmed Maher <ben.yahmed.maher@gmail.com>. Changes made to compile the new 3.2.2 gnuradio version on F10 with both USRP and USRP2 hardware enabled.
136
137 * Wed Apr 1 2009  Ben Yahmed Maher <ben.yahmed.maher@gmail.com> 3.2.2-1.2
138 - change to svn 10720 with fedora 10