diff --git a/.gitignore b/.gitignore index cdd3c0c..5eb2ff1 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,2 @@ -/gc-7.4.2.tar.gz -/gc-7.4.4.tar.gz /gc-7.6.0.tar.gz /gc-7.6.2.tar.gz diff --git a/gc.spec b/gc.spec index b934b63..6e089c8 100644 --- a/gc.spec +++ b/gc.spec @@ -1,4 +1,6 @@ +%global compat 1 + Summary: A garbage collector for C and C++ Name: gc Version: 7.6.2 @@ -7,6 +9,9 @@ Release: 4%{?dist} License: BSD Url: http://www.hboehm.info/gc/ Source0: http://www.hboehm.info/gc/gc_source/gc-%{version}%{?pre}.tar.gz +%if 0%{?compat} +Source1: http://www.hboehm.info/gc/gc_source/gc-7.6.0.tar.gz +%endif ## upstreamable patches @@ -33,6 +38,11 @@ Provides: libgc-devel = %{version}-%{release} %description devel %{summary}. +%package -n compat-gc +Summary: Compat gc-7.6.0 runtime library +%description -n compat-gc +%{summary} to ease transition to gc-7.6.2+. + %prep %autosetup -n gc-%{version}%{?pre} @@ -41,6 +51,14 @@ Provides: libgc-devel = %{version}-%{release} rm -f libtool libtool.m4 autoreconf -i -f +%if 0%{?compat} +tar xzf %{SOURCE1} +pushd gc-7.6.0 +rm -f libtool libtool.m4 +autoreconf -i -f +popd +%endif + %build @@ -57,11 +75,35 @@ CPPFLAGS="-DUSE_GET_STACKBASE_FOR_MAIN"; export CPPFLAGS %endif --enable-threads=posix -make %{?_smp_mflags} +%{make_build} + +%if 0%{?compat} +pushd gc-7.6.0 +%configure \ + --disable-static \ + --enable-cplusplus \ + --enable-large-config \ +%ifarch %{ix86} + --enable-parallel-mark \ +%endif + --enable-threads=posix + +%{make_build} +popd +%endif %install -make install DESTDIR=%{buildroot} + +%if 0%{?compat} +%{make_install} -C gc-7.6.0 + +rm -rfv %{buildroot}{%{_includedir},%{_datadir}} +rm -fv %{buildroot}%{_libdir}/lib{cord,gcccpp}* +rm -fv %{buildroot}%{_libdir}/libgc.so +%endif + +%{make_install} install -p -D -m644 doc/gc.man %{buildroot}%{_mandir}/man3/gc.3 @@ -81,6 +123,7 @@ rm -fv %{buildroot}%{_libdir}/lib*.la make check %{?arch_ignore} %endif + %ldconfig_scriptlets %files @@ -100,10 +143,18 @@ make check %{?arch_ignore} %{_libdir}/pkgconfig/bdw-gc.pc %{_mandir}/man3/gc.3* +%if 0%{?compat} +%ldconfig_scriptlets -n compat-gc + +%files -n compat-gc +%{_libdir}/libgc.so.1* +%endif + %changelog * Tue Feb 20 2018 Rex Dieter - 7.6.2-4 - BR: gcc-c++ +- add (temporary) compat-gc * Wed Feb 07 2018 Fedora Release Engineering - 7.6.2-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild diff --git a/sources b/sources index 5f29fdc..cb036ae 100644 --- a/sources +++ b/sources @@ -1 +1,2 @@ SHA512 (gc-7.6.2.tar.gz) = 7b54812903929b0d5d1d696beac54629a7667997b41ef45299373bc18b2153d5755286b25e11cc90ffc572239e52a02900927bc60b0ad3593162b8c8e259fd50 +SHA512 (gc-7.6.0.tar.gz) = 511e8c01287b1ee9dbec87f0573377de77038b7af053a3f33afed9b3ffa30e2402d6a9bb0ca4f4b81cd808209b47b5718d498cff3de6632a057fe03fad51fc43