Changeset 1036 for spec/trunk/SPECS/rpm.spec
- Timestamp:
- Feb 25, 2017, 7:57:30 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
spec/trunk/SPECS/rpm.spec
r1031 r1036 6 6 %bcond_with int_bdb 7 7 # run internal testsuite? 8 %bcond_without check 9 10 %{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")} 8 %bcond_with check 9 # build with plugins? 10 %bcond_without plugins 11 # build with sanitizers? 12 %bcond_with sanitizer 13 # build with libarchive? (needed for rpm2archive) 14 %bcond_with libarchive 15 # build with libimaevm.so 16 %bcond_with libimaevm 17 # build with new db format 18 %bcond_with ndb 11 19 12 20 %define rpmhome %{_libdir}/rpm 13 21 14 %define rpmver 4.13.0 15 %define snapver %{nil} 16 %define srcver %{rpmver} 17 18 %define bdbver 4.8.24 22 %global rpmver 4.13.0 23 #global snapver rc2 24 %global srcver %{version}%{?snapver:-%{snapver}} 25 26 %define bdbname db4 27 %define bdbver 5.3.15 19 28 %define dbprefix db 20 29 … … 22 31 Name: rpm 23 32 Version: %{rpmver} 24 Release: 13%{?dist}33 Release: %{?snapver:0.%{snapver}.}14%{?dist} 25 34 Group: System Environment/Base 26 35 Url: http://www.rpm.org/ 27 36 28 %scm_source svn http://svn.netlabs.org/repos/rpm/rpm/trunk 1027 37 %scm_source svn http://svn.netlabs.org/repos/rpm/rpm/trunk 1035 38 39 %if %{with int_bdb} 40 Source1: db-%{bdbver}.tar.gz 41 %endif 29 42 30 43 # Partially GPL/LGPL dual-licensed and some bits with BSD … … 35 48 %if %{without int_bdb} 36 49 # db recovery tools, rpmdb_util symlinks 37 Requires: db4-utils50 Requires: %{bdbname}-utils 38 51 %endif 39 52 Requires: popt >= 1.10.2.1 40 53 Requires: curl 54 41 55 Requires: rpm-libs = %{version}-%{release} 42 56 Requires: pthread >= 20151207 43 Requires: cpio44 57 Requires: cube 45 Requires: sed46 58 47 59 Provides: rpm-macros-warpin … … 51 63 52 64 %if %{without int_bdb} 53 BuildRequires: db4-devel65 BuildRequires: %{bdbname}-devel 54 66 %endif 55 67 56 68 %if %{with check} 57 #BuildRequires: fakechroot69 BuildRequires: fakechroot 58 70 %endif 59 71 … … 63 75 BuildRequires: readline-devel zlib-devel 64 76 BuildRequires: nss-devel 77 BuildRequires: nss-softokn-freebl-devel 65 78 # The popt version here just documents an older known-good version 66 79 BuildRequires: popt-devel >= 1.10.2 … … 76 89 BuildRequires: xz-devel >= 4.999.8 77 90 %endif 91 %if ! %{without libarchive} 92 BuildRequires: libarchive-devel 93 %endif 94 BuildRequires: autoconf automake libtool 95 96 %if %{with plugins} 97 #BuildRequires: dbus-devel 98 %endif 99 100 %if %{with sanitizer} 101 BuildRequires: libasan 102 BuildRequires: libubsan 103 #BuildRequires: liblsan 104 #BuildRequires: libtsan 105 %global sanitizer_flags -fsanitize=address -fsanitize=undefined 106 %endif 107 108 %if %{with libimaevm} 109 BuildRequires: ima-evm-utils 110 %endif 78 111 79 112 %description … … 88 121 Group: Development/Libraries 89 122 License: GPLv2+ and LGPLv2+ with exceptions 90 Requires: rpm= %{version}-%{release}123 Requires: %{name} = %{version}-%{release} 91 124 92 125 # We need a fork-friendly PR_LoadLibrary on OS/2 … … 95 128 %description libs 96 129 This package contains the RPM shared libraries. 130 131 %package build-libs 132 Summary: Libraries for building and signing RPM packages 133 Group: Development/Libraries 134 License: GPLv2+ and LGPLv2+ with exceptions 135 Requires: %{name}-libs = %{version}-%{release} 136 #Requires: %{_bindir}/gpg2 137 138 %description build-libs 139 This package contains the RPM shared libraries for building and signing 140 packages. 97 141 98 142 %package devel … … 100 144 Group: Development/Libraries 101 145 License: GPLv2+ and LGPLv2+ with exceptions 102 Requires: rpm = %{version}-%{release} 146 Requires: %{name} = %{version}-%{release} 147 Requires: %{name}-libs = %{version}-%{release} 148 Requires: %{name}-build-libs = %{version}-%{release} 103 149 Requires: popt-devel 104 150 Requires: file-devel … … 119 165 Group: Development/Tools 120 166 Requires: rpm = %{version}-%{release} 121 #Requires: elfutils >= 0.128 binutils 122 Requires: findutils sed grep gawk diffutils 123 Requires: file patch >= 2.5 124 Requires: unzip xz 125 Requires: gzip bzip2 cpio 167 Requires: binutils 168 Requires: findutils sed grep gawk diffutils file patch >= 2.5 169 Requires: tar unzip gzip bzip2 cpio xz 126 170 Requires: pkgconfig >= 1:0.24 127 Requires: tar 128 #Conflicts: ocaml-runtime < 3.11.1-7 171 # Technically rpmbuild doesn't require any external configuration, but 172 # creating distro-compatible packages does. To make the common case 173 # "just work" while allowing for alternatives, depend on a virtual 174 # provide, typically coming from redhat-rpm-config. 175 #Requires: system-rpm-config 176 # Techincally rpmbuild doesn't require python3 (and setuptools), but 177 # pythondistdeps generator expects it. 178 # See: https://bugzilla.redhat.com/show_bug.cgi?id=1410631 179 #Requires: python3-setuptools 129 180 130 181 %description build … … 132 183 that are used to build packages using the RPM Package Manager. 133 184 134 %package python 135 Summary: Python bindings for apps which will manipulate RPM packages 185 %package sign 186 Summary: Package signing support 187 Group: System Environment/Base 188 Requires: rpm-build-libs = %{version}-%{release} 189 190 %description sign 191 This package contains support for digitally signing RPM packages. 192 193 %package -n python2-%{name} 194 Summary: Python 2 bindings for apps which will manipulate RPM packages 136 195 Group: Development/Libraries 137 Requires: rpm = %{version}-%{release} 196 BuildRequires: python2-devel 197 %{?python_provide:%python_provide python2-%{name}} 198 Requires: %{name}-libs = %{version}-%{release} 199 Provides: %{name}-python = %{version}-%{release} 200 Obsoletes: %{name}-python < %{version}-%{release} 138 201 # YD because of ucs4 139 202 Requires: python >= 2.7.6-13 140 203 141 %description python142 The rpm-pythonpackage contains a module that permits applications204 %description -n python2-%{name} 205 The python2-rpm package contains a module that permits applications 143 206 written in the Python programming language to use the interface 144 207 supplied by RPM Package Manager libraries. 145 208 146 This package should be installed if you want to develop Python 209 This package should be installed if you want to develop Python 2 147 210 programs that will manipulate RPM packages and databases. 211 212 #package -n python3-%{name} 213 #Summary: Python 3 bindings for apps which will manipulate RPM packages 214 #Group: Development/Libraries 215 #BuildRequires: python3-devel 216 #{?python_provide:%python_provide python3-%{name}} 217 #{?system_python_abi} 218 #Requires: %{name}-libs%{?_isa} = %{version}-%{release} 219 #Provides: %{name}-python3 = %{version}-%{release} 220 #Obsoletes: %{name}-python3 < %{version}-%{release} 221 222 #description -n python3-%{name} 223 #the python3-rpm package contains a module that permits applications 224 #written in the Python programming language to use the interface 225 #supplied by RPM Package Manager libraries. 226 # 227 #This package should be installed if you want to develop Python 3 228 #programs that will manipulate RPM packages and databases. 148 229 149 230 %package apidocs … … 167 248 168 249 %debug_package 250 251 %if %{with plugins} 252 253 %package plugin-syslog 254 Summary: Rpm plugin for syslog functionality 255 Group: System Environment/Base 256 Requires: rpm-libs%{_isa} = %{version}-%{release} 257 258 %description plugin-syslog 259 %{summary} 260 261 %package plugin-ima 262 Summary: Rpm plugin ima file signatures 263 Group: System Environment/Base 264 Requires: rpm-libs%{_isa} = %{version}-%{release} 265 266 %description plugin-ima 267 %{summary} 268 269 %endif 169 270 170 271 %prep … … 186 287 configure.ac 187 288 289 CPPFLAGS="`pkg-config --cflags nss`" # -DLUA_COMPAT_APIINTCASTS" 290 CFLAGS="$RPM_OPT_FLAGS %{?sanitizer_flags}" # -DLUA_COMPAT_APIINTCASTS" 291 LDFLAGS="%{?__global_ldflags} -Zbin-files -Zhigh-mem -Zomf -Zargs-wild -Zargs-resp" 292 LIBS="-lintl -lcx" 293 export CPPFLAGS CFLAGS LDFLAGS LIBS 294 188 295 autoreconf -i -f 189 296 … … 191 298 export ac_cv_path___SSH=ssh 192 299 193 # Using configure macro has some unwanted side-effects on rpm platform194 # setup, use the old-fashioned way for now only defining minimal paths.195 export LDFLAGS="-Zbin-files -Zhigh-mem -Zomf -Zargs-wild -Zargs-resp"196 export LIBS="-lintl -lcx"197 export CPPFLAGS="$CPPFLAGS `pkg-config --cflags nss`"198 300 %configure \ 199 --enable-shared --disable-static --without-lua\301 --enable-shared --disable-static \ 200 302 %{!?with_int_bdb: --with-external-db} \ 201 --without-archive \ 303 %{!?with_plugins: --disable-plugins} \ 304 %{!?with_lua: --without-lua} \ 305 %{!?with_libarchive: --without-archive} \ 306 %{?with_ndb: --with-ndb} \ 202 307 --enable-python 203 308 204 make %{?_smp_mflags} V=1 309 make %{?_smp_mflags} 310 311 #pushd python 312 #{__python2} setup.py build 313 #{__python3} setup.py build 314 #popd 205 315 206 316 %install … … 208 318 209 319 make DESTDIR="$RPM_BUILD_ROOT" install 320 321 # We need to build with --enable-python for the self-test suite, but we 322 # actually package the bindings built with setup.py (#531543#c26) 323 #pushd python 324 #{__python2} setup.py install --skip-build --root $RPM_BUILD_ROOT 325 #{__python3} setup.py install --skip-build --root $RPM_BUILD_ROOT 326 #popd 210 327 211 328 # Remove OS/2 import libraries from plugins … … 244 361 install -m 644 scripts/rpm.log ${RPM_BUILD_ROOT}%{_sysconfdir}/logrotate.d/rpm 245 362 363 #mkdir -p ${RPM_BUILD_ROOT}/usr/lib/tmpfiles.d 364 #echo "r /var/lib/rpm/__db.*" > ${RPM_BUILD_ROOT}/usr/lib/tmpfiles.d/rpm.conf 365 246 366 mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/rpm 367 mkdir -p $RPM_BUILD_ROOT%{rpmhome}/macros.d 247 368 248 369 mkdir -p $RPM_BUILD_ROOT%{_var}/lib/rpm 249 370 for dbi in \ 250 Basenames Conflictname Dirnames Group Installtid Name Packages \ 251 Providename Provideversion Requirename Requireversion Triggername \ 252 Filedigests Pubkeys Sha1header Sigmd5 Obsoletename \ 371 Basenames Conflictname Dirnames Group Installtid Name Obsoletename \ 372 Packages Providename Requirename Triggername Sha1header Sigmd5 \ 253 373 __db.001 __db.002 __db.003 __db.004 __db.005 __db.006 __db.007 \ 254 374 __db.008 __db.009 … … 271 391 find $RPM_BUILD_ROOT -name "*.la"|xargs rm -f 272 392 273 # avoid dragging in tonne of perl libs for an unused script274 # chmod 0644 $RPM_BUILD_ROOT/%{rpmhome}/perldeps.pl275 276 # compress our ChangeLog, it's fairly big...277 bzip2 -9 ChangeLog 393 # These live in perl-generators now 394 #rm -f $RPM_BUILD_ROOT/%{rpmhome}/{perldeps.pl,perl.*} 395 #rm -f $RPM_BUILD_ROOT/%{_fileattrsdir}/perl* 396 # Axe unused cruft 397 rm -f $RPM_BUILD_ROOT/%{rpmhome}/{tcl.req,osgideps.pl} 278 398 279 399 %clean 280 400 rm -rf $RPM_BUILD_ROOT 281 401 282 #%if %{with check} 283 #%check 284 #make check 285 #[ "$(ls -A tests/rpmtests.dir)" ] && cat tests/rpmtests.log 286 #%endif 287 288 #%post libs -p /sbin/ldconfig 289 #%postun libs -p /sbin/ldconfig 290 291 #%posttrans 292 # XXX this is klunky and ugly, rpm itself should handle this 293 #dbstat=/usr/lib/rpm/rpmdb_stat 294 #if [ -x "$dbstat" ]; then 295 # if "$dbstat" -e -h %{_var}/lib/rpm 2>&1 | grep -q "doesn't match environment version \| Invalid argument"; then 296 # rm -f %{_var}/lib/rpm/__db.* 297 # fi 298 #fi 299 #exit 0 402 %if %{with check} 403 %check 404 make check 405 [ "$(ls -A tests/rpmtests.dir)" ] && cat tests/rpmtests.log 406 %endif 300 407 301 408 %files -f %{name}.lang 302 %defattr(-,root,root,-) 303 %doc GROUPS COPYING CREDITS ChangeLog.bz2 doc/manual/[a-z]* 409 %license COPYING 410 %doc GROUPS CREDITS doc/manual/[a-z]* 411 412 #/usr/lib/tmpfiles.d/rpm.conf 304 413 %dir %{_sysconfdir}/rpm 305 414 … … 309 418 310 419 %{_bindir}/rpm.exe 420 %{?with_libarchive: %{_bindir}/rpm2archive.exe} 311 421 %{_bindir}/rpm2cpio.exe 312 422 %{_bindir}/rpmdb.exe 313 423 %{_bindir}/rpmkeys.exe 314 %{_bindir}/rpmsign.exe315 424 %{_bindir}/rpmquery 316 425 %{_bindir}/rpmverify … … 329 438 %lang(sk) %{_mandir}/sk/man[18]/*.[18]* 330 439 440 %attr(0755, root, root) %dir %{rpmhome} 331 441 %{rpmhome}/macros 442 %{rpmhome}/macros.d 332 443 %{rpmhome}/rpmpopt* 333 444 %{rpmhome}/rpmrc … … 342 453 %{rpmhome}/platform 343 454 455 %dir %{rpmhome}/fileattrs 456 344 457 %{rpmhome}/wps-object.exe 345 458 %{rpmhome}/warpin-conflicts.exe 346 459 347 460 %files libs 348 %defattr(-,root,root) 349 %{_libdir}/rpm*.dll 461 %{_libdir}/rpmio[0-9].dll 462 %{_libdir}/rpm[0-9].dll 463 %if %{with plugins} 350 464 %dir %{_libdir}/rpm-plugins 351 %{_libdir}/rpm-plugins/*.dll 465 466 %files plugin-syslog 467 %{_libdir}/rpm-plugins/syslog.dll 468 469 %files plugin-ima 470 %{_libdir}/rpm-plugins/ima.dll 471 %endif 472 473 %files build-libs 474 %{_libdir}/rpmbuil[0-9].dll 475 %{_libdir}/rpmsign[0-9].dll 352 476 353 477 %files build 354 %defattr(-,root,root)355 478 %{_bindir}/rpmbuild.exe 356 479 %{_bindir}/gendiff 357 480 %{_bindir}/rpmspec.exe 358 %{_bindir}/rpmsign.exe359 481 360 482 %{_mandir}/man1/gendiff.1* … … 362 484 %{_mandir}/man8/rpmdeps.8* 363 485 %{_mandir}/man8/rpmspec.8* 364 %{_mandir}/man8/rpmsign.8*365 486 366 487 %{rpmhome}/brp-* 367 488 %{rpmhome}/check-* 368 489 #{rpmhome}/debugedit 490 #{rpmhome}/sepdebugcrcfix 369 491 #{rpmhome}/find-debuginfo.sh 370 492 %{rpmhome}/find-lang.sh … … 377 499 %{rpmhome}/config.* 378 500 %{rpmhome}/macros.p* 379 %{rpmhome}/fileattrs 380 381 %files python 382 %defattr(-,root,root) 383 %{_usr}/lib/python*.*/* 501 %{rpmhome}/fileattrs/* 502 503 %files sign 504 %{_bindir}/rpmsign.exe 505 %{_mandir}/man8/rpmsign.8* 506 507 %files -n python2-%{name} 508 %{python_sitearch}/%{name}/ 509 #{python_sitearch}/%{name}_python-*.egg-info 510 511 #files -n python3-%{name} 512 #{python3_sitearch}/%{name}/ 513 #{python3_sitearch}/%{name}_python-*.egg-info 384 514 385 515 %files devel 386 %defattr(-,root,root)387 %_includedir/*388 %{_libdir}/rp*[a-z].a389 516 %{_mandir}/man8/rpmgraph.8* 390 517 %{_bindir}/rpmgraph.exe 391 %{_libdir}/pkgconfig/rpm.pc 518 %{_libdir}/rp*[a-z].a 519 %{_libdir}/pkgconfig/%{name}.pc 520 %{_includedir}/%{name}/ 392 521 393 522 %files cron 394 %defattr(-,root,root)395 523 %{_sysconfdir}/cron.daily/rpm 396 524 %config(noreplace) %{_sysconfdir}/logrotate.d/rpm 397 525 398 526 %files apidocs 399 % defattr(-,root,root)400 %doc COPYINGdoc/librpm/html/*527 %license COPYING 528 %doc doc/librpm/html/* 401 529 402 530 %changelog 531 * Sat Feb 25 2017 Dmitriy Kuminov <coding@dmik.org> - 4.13.0-14 532 - Update to version 4.13.0 GA. 533 - Fix sed warnings in find-lang.sh due to ':' in pats on OS/2. 534 - Bring .spec in sync with current Fedora .spec (this renames some packages 535 and adds some more). 536 403 537 * Fri Feb 24 2017 Dmitriy Kuminov <coding@dmik.org> - 4.13.0-13 404 538 - Use proper SVN revision for the build.
Note:
See TracChangeset
for help on using the changeset viewer.