%build: --with-libatomic-ops=yes
This commit is contained in:
Rex Dieter 2020-01-15 09:31:31 -06:00
parent bda426f9cb
commit 190bf7e289
5 changed files with 14 additions and 120 deletions

1
.gitignore vendored
View File

@ -1,3 +1,4 @@
/gc-7.6.0.tar.gz
/gc-7.6.2.tar.gz
/gc-7.6.4.tar.gz
/gc-8.0.4.tar.gz

View File

@ -1,52 +0,0 @@
diff -ur gc-7.6.4.old/include/private/gcconfig.h gc-7.6.4.new/include/private/gcconfig.h
--- gc-7.6.4.old/include/private/gcconfig.h 2018-01-26 13:16:17.000000000 +0000
+++ gc-7.6.4.new/include/private/gcconfig.h 2018-02-27 09:33:05.840680540 +0000
@@ -602,6 +602,15 @@
# define I386
# define mach_type_known
# endif
+# if defined(__riscv) && defined(LINUX)
+# if __riscv_xlen == 32
+# define RISCV32
+# define mach_type_known
+# elif __riscv_xlen == 64
+# define RISCV64
+# define mach_type_known
+# endif
+# endif
/* Feel free to add more clauses here */
@@ -2650,6 +2659,32 @@
# endif
# endif
+# ifdef RISCV32
+# define CPP_WORDSZ 32
+# define MACH_TYPE "RISC-V32"
+# define ALIGNMENT 4
+# ifdef LINUX
+# define OS_TYPE "LINUX"
+ extern int __data_start[];
+# define DATASTART ((ptr_t)__data_start)
+# define LINUX_STACKBOTTOM
+# define DYNAMIC_LOADING
+# endif
+# endif /* RISCV32 */
+
+# ifdef RISCV64
+# define CPP_WORDSZ 64
+# define MACH_TYPE "RISC-V64"
+# define ALIGNMENT 8
+# ifdef LINUX
+# define OS_TYPE "LINUX"
+ extern int __data_start[];
+# define DATASTART ((ptr_t)__data_start)
+# define LINUX_STACKBOTTOM
+# define DYNAMIC_LOADING
+# endif
+# endif /* RISCV64 */
+
#if defined(__GLIBC__) && !defined(DONT_USE_LIBC_PRIVATES)
/* Use glibc's stack-end marker. */
# define USE_LIBC_PRIVATES

View File

@ -1,56 +0,0 @@
diff -ur gc-7.6.4.old/include/private/gcconfig.h gc-7.6.4/include/private/gcconfig.h
--- gc-7.6.4.old/include/private/gcconfig.h 2018-02-27 09:35:01.074561443 +0000
+++ gc-7.6.4/include/private/gcconfig.h 2018-02-27 09:35:38.571522689 +0000
@@ -603,13 +603,8 @@
# define mach_type_known
# endif
# if defined(__riscv) && defined(LINUX)
-# if __riscv_xlen == 32
-# define RISCV32
-# define mach_type_known
-# elif __riscv_xlen == 64
-# define RISCV64
-# define mach_type_known
-# endif
+# define RISCV
+# define mach_type_known
# endif
/* Feel free to add more clauses here */
@@ -2659,23 +2654,10 @@
# endif
# endif
-# ifdef RISCV32
-# define CPP_WORDSZ 32
-# define MACH_TYPE "RISC-V32"
-# define ALIGNMENT 4
-# ifdef LINUX
-# define OS_TYPE "LINUX"
- extern int __data_start[];
-# define DATASTART ((ptr_t)__data_start)
-# define LINUX_STACKBOTTOM
-# define DYNAMIC_LOADING
-# endif
-# endif /* RISCV32 */
-
-# ifdef RISCV64
-# define CPP_WORDSZ 64
-# define MACH_TYPE "RISC-V64"
-# define ALIGNMENT 8
+# ifdef RISCV
+# define MACH_TYPE "RISC-V"
+# define CPP_WORDSZ __riscv_xlen /* 32 or 64 */
+# define ALIGNMENT (CPP_WORDSZ/8)
# ifdef LINUX
# define OS_TYPE "LINUX"
extern int __data_start[];
@@ -2683,7 +2665,7 @@
# define LINUX_STACKBOTTOM
# define DYNAMIC_LOADING
# endif
-# endif /* RISCV64 */
+# endif /* RISCV */
#if defined(__GLIBC__) && !defined(DONT_USE_LIBC_PRIVATES)
/* Use glibc's stack-end marker. */

23
gc.spec
View File

@ -1,8 +1,8 @@
Summary: A garbage collector for C and C++
Name: gc
Version: 7.6.4
Release: 6%{?dist}
Version: 8.0.4
Release: 1%{?dist}
License: BSD
Url: http://www.hboehm.info/gc/
@ -11,10 +11,6 @@ Source0: http://www.hboehm.info/gc/gc_source/gc-%{version}%{?pre}.tar.gz
## upstreamable patches
## upstream patches
# Upstream commit 4f7f0eebd24dcde9f2b3ec2cb98913fc39bbdda3.
Patch1: 0001-Add-initial-RISC-V-support.patch
# Upstream commit 3b008f79ee29dbd0d61cf163d20eee21412df95b.
Patch2: 0001-Merge-RISCV-32-64-bit-configurations-definition.patch
## downstream patches
# https://bugzilla.redhat.com/show_bug.cgi?id=1551671
@ -51,7 +47,7 @@ Provides: libgc-devel = %{version}-%{release}
rm -f libtool libtool.m4
autoreconf -i -f
# see bugzilla.redhat.com/689877
# see https://bugzilla.redhat.com/689877
CPPFLAGS="-DUSE_GET_STACKBASE_FOR_MAIN"; export CPPFLAGS
%configure \
@ -62,13 +58,14 @@ CPPFLAGS="-DUSE_GET_STACKBASE_FOR_MAIN"; export CPPFLAGS
%ifarch %{ix86}
--enable-parallel-mark \
%endif
--enable-threads=posix
--enable-threads=posix \
--with-libatomic-ops=yes
%{make_build}
%make_build
%install
%{make_install}
%make_install
install -p -D -m644 doc/gc.man %{buildroot}%{_mandir}/man3/gc.3
@ -98,7 +95,7 @@ make check %{?arch_ignore}
%files devel
%doc doc/README.environment doc/README.linux
%doc doc/*.html
%doc doc/*.md
%{_includedir}/gc.h
%{_includedir}/gc_cpp.h
%{_includedir}/gc/
@ -110,6 +107,10 @@ make check %{?arch_ignore}
%changelog
* Wed Jan 15 2020 Rex Dieter <rdieter@fedoraproject.org> - 8.0.4-1
- 8.0.4
- %%build: --with-libatomic-ops=yes
* Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org> - 7.6.4-6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild

View File

@ -1 +1 @@
SHA512 (gc-7.6.4.tar.gz) = 2c85be3e24b85732b3dc6f08fe98cf1a82b6fb2a22ec73090f80920721c737ef92cee8f0cd7ea7228d686005d164e7da54ce3907c3a1ba5eefa43355a472085e
SHA512 (gc-8.0.4.tar.gz) = 57ccca15c6e50048d306a30de06c1a844f36103a84c2d1c17cbccbbc0001e17915488baec79737449982da99ce5d14ce527176afae9ae153cbbb5a19d986366e