Wed, 08 Aug 2012 20:36:32 +0200
Modernize packaging and use parallel make.
udns/udns.spec | file | annotate | diff | comparison | revisions |
1.1 --- a/udns/udns.spec Wed Aug 08 20:34:03 2012 +0200 1.2 +++ b/udns/udns.spec Wed Aug 08 20:36:32 2012 +0200 1.3 @@ -32,18 +32,14 @@ 1.4 Group: DNS 1.5 License: LGPL 1.6 Version: 0.2 1.7 -Release: 20120208 1.8 +Release: 20120800 1.9 1.10 # list of sources 1.11 Source0: http://www.corpit.ru/mjt/udns/udns-%{version}.tar.gz 1.12 1.13 # build information 1.14 -Prefix: %{l_prefix} 1.15 -BuildRoot: %{l_buildroot} 1.16 -BuildPreReq: OpenPKG, openpkg >= 20060823 1.17 -PreReq: OpenPKG, openpkg >= 20060823 1.18 -AutoReq: no 1.19 -AutoReqProv: no 1.20 +BuildPreReq: OpenPKG, openpkg >= 20100101, make 1.21 +PreReq: OpenPKG, openpkg >= 20100101 1.22 1.23 %description 1.24 UDNS is a stub DNS resolver library with ability to perform both 1.25 @@ -61,23 +57,24 @@ 1.26 case "%{l_platform -t}" in 1.27 *-sunos* ) 1.28 %{l_shtool} subst \ 1.29 - -e 's;\(\$(LIBFL)\);\1 -lsocket -lnsl;g' \ 1.30 + -e 's;^\(LIBFL *= *.*\);\1 -lsocket -lnsl;' \ 1.31 Makefile.in 1.32 ;; 1.33 esac 1.34 1.35 %build 1.36 + loccppflags= 1.37 case "%{l_platform -t}" in 1.38 - *-sunos* ) loclibs='-lsocket -lnsl' ;; 1.39 + *-sunos* ) 1.40 + loccflags=-DHAVE_INET_PTON_NTOP 1.41 + ;; 1.42 esac 1.43 CC="%{l_cc}" \ 1.44 - CFLAGS="%{l_cflags -O}" \ 1.45 - LIBS="$loclibs" \ 1.46 + CFLAGS="%{l_cflags -O} $loccflags" \ 1.47 ./configure 1.48 - %{l_make} %{l_mflags} 1.49 + %{l_make} %{l_mflags -O} 1.50 1.51 %install 1.52 - rm -rf $RPM_BUILD_ROOT 1.53 %{l_shtool} mkdir -f -p -m 755 \ 1.54 $RPM_BUILD_ROOT%{l_prefix}/include \ 1.55 $RPM_BUILD_ROOT%{l_prefix}/lib \ 1.56 @@ -93,5 +90,4 @@ 1.57 %files -f files 1.58 1.59 %clean 1.60 - rm -rf $RPM_BUILD_ROOT 1.61