Compare commits

...

30 Commits

Author SHA1 Message Date
8fd96b93d6
Fix ifnarch condition
Signed-off-by: David Abdurachmanov <davidlt@rivosinc.com>
2024-08-16 10:21:33 +03:00
00611e2b96
Disable execstack for RISC-V (riscv64)
Signed-off-by: David Abdurachmanov <davidlt@rivosinc.com>
2024-08-16 09:29:49 +03:00
Fedora Release Engineering
6ee0285b63 Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild 2024-07-18 09:26:59 +00:00
Software Management Team
bf145ed3b0 Eliminate use of obsolete %patchN syntax (#2283636) 2024-05-30 12:46:47 +02:00
Fedora Release Engineering
b5157cf462 Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild 2024-01-24 21:51:26 +00:00
Florian Weimer
0763f60047 Build with CC="gcc -fpermissive", increase command line buffer size 2024-01-21 16:03:06 +01:00
Fedora Release Engineering
57e632084f Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild 2024-01-20 22:16:48 +00:00
Florian Weimer
36c5ca15c6 Set build_type_safety_c to 0 (#2160645)
Related to:

  <https://fedoraproject.org/wiki/Changes/PortingToModernC>
  <https://fedoraproject.org/wiki/Toolchain/PortingToModernC>
2023-08-29 15:51:42 +02:00
Fedora Release Engineering
3eb97f1d17 Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2023-07-20 06:31:16 +00:00
Fedora Release Engineering
f399d64186 Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2023-01-19 12:18:57 +00:00
Fedora Release Engineering
21c9b60a36 Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2022-07-21 13:50:00 +00:00
Fedora Release Engineering
98417ab363 - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2022-01-20 12:31:16 +00:00
Fedora Release Engineering
7028892f57 - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2021-07-22 07:47:57 +00:00
Fedora Release Engineering
790d9fe232 - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2021-01-26 13:38:37 +00:00
Tom Stellard
b740a68c00 Add BuildRequires: make
https://fedoraproject.org/wiki/Changes/Remove_make_from_BuildRoot
2021-01-05 05:38:17 +00:00
Jens Petersen
edf1dbe341 update config.* paths to redhat 2020-08-03 19:51:08 +08:00
Fedora Release Engineering
6b4bd5b2a7 - Second attempt - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2020-08-01 03:30:14 +00:00
Fedora Release Engineering
354b5f753a - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2020-07-28 01:03:24 +00:00
Jeff Law
136ed1774f - Fix configure test compromised by LTO. 2020-05-26 14:52:36 -06:00
Fedora Release Engineering
aa7ecd4f2d - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2020-01-29 04:30:40 +00:00
Fedora Release Engineering
e3f1166c71 - Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2019-07-25 08:40:48 +00:00
Jens Petersen
b7bd783fdc more explicit filelists 2019-07-13 03:23:08 +00:00
Jens Petersen
2bc22acfde just use installed demos/ 2019-07-13 03:22:34 +00:00
Jens Petersen
89da3551df improve description formatting 2019-07-13 03:22:05 +00:00
Jens Petersen
e2b466df4e drop alternatives 2019-07-13 03:21:26 +00:00
Igor Gnatenko
fd1abaf288 Rebuild for readline 8.0 2019-02-17 09:30:50 +01:00
Jens Petersen
68144ddd78 drop use of execstack on x86_64
BUILDSTDERR: execstack: dso.c:877: reopen_dso: Assertion `dso->shdr[j].sh_size == 0' failed.
BUILDSTDERR: /var/tmp/rpm-tmp.3AqnlA: line 39:  5224 Aborted                 (core dumped) execstack -s /builddir/build/BUILDROOT/hugs98-2006.09-32.fc30.x86_64/usr/bin/{hugs,runhugs,ffihugs}
2019-02-03 14:20:56 +08:00
Fedora Release Engineering
311d9a8b3f - Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2019-02-01 02:30:52 +00:00
Igor Gnatenko
ed8ec45199 Remove obsolete Group tag
References: https://fedoraproject.org/wiki/Changes/Remove_Group_Tag
2019-01-28 20:24:07 +01:00
Fedora Release Engineering
8e995f258a - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2018-07-13 05:09:08 +00:00
3 changed files with 134 additions and 38 deletions

24
hugs98-config.patch Normal file
View File

@ -0,0 +1,24 @@
diff -Nrup a/configure b/configure
--- a/configure 2006-09-20 16:34:03.000000000 -0600
+++ b/configure 2019-12-19 06:07:54.302627575 -0700
@@ -11959,7 +11959,7 @@ cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h. */
#include <malloc.h>
-int test1() {
+__attribute__ ((used)) int test1() {
return _alloca(42);
}
diff -Nrup a/configure.ac b/configure.ac
--- a/configure.ac 2006-05-03 08:10:36.000000000 -0600
+++ b/configure.ac 2019-12-19 06:07:27.468727400 -0700
@@ -451,7 +451,7 @@ dnl Visual C++ doesn't have alloca, does
AC_CACHE_CHECK(for _alloca, ac_cv_c__alloca,
[AC_TRY_LINK([
#include <malloc.h>
-int test1() {
+__attribute__ ((used)) int test1() {
return _alloca(42);
}
],

View File

@ -0,0 +1,17 @@
Increase the buffer size to avoid a build failure with:
ERROR "libraries/bootlib/Foreign/Marshal/Alloc.hs" - Unable to build compilation command
diff --git a/src/machdep.c b/src/machdep.c
index 3cb32c6fd84400d8..b842f16e38cebe62 100644
--- a/src/machdep.c
+++ b/src/machdep.c
@@ -2292,7 +2292,7 @@ void* dll; {
* the above mechanisms.
* ------------------------------------------------------------------------*/
-#define BUFSIZE 1000
+#define BUFSIZE 10000
static char buffer[BUFSIZE];
static Int used = 0;
static Void local insert Args((String));

View File

@ -2,14 +2,15 @@
Name: hugs98
Version: 2006.09
Release: 30%{?dist}
Release: 51.0.riscv64%{?dist}
Summary: Haskell Interpreter
Group: Development/Languages
License: BSD
URL: http://www.haskell.org/hugs
Source0: http://cvs.haskell.org/Hugs/downloads/2006-09/%{name}-%{hugs_ver}.tar.gz
Patch0: hugs98-gnu.patch
Patch1: hugs98-config.patch
Patch2: hugs98-machdep-bufsize.patch
BuildRequires: docbook-utils
BuildRequires: freeglut-devel
@ -26,19 +27,19 @@ BuildRequires: readline-devel
BuildRequires: xorg-x11-proto-devel
BuildRequires: openal-soft-devel
BuildRequires: freealut-devel
%ifnarch aarch64 ppc64le
%ifnarch aarch64 ppc64le x86_64 riscv64
BuildRequires: /usr/bin/execstack
%endif
BuildRequires: make
%description
Hugs 98 is a functional programming system based on Haskell 98, the de
facto standard for non-strict functional programming languages. Hugs
98 provides an almost complete implementation of Haskell 98.
Hugs 98 is a functional programming system based on Haskell 98,
the de facto standard for non-strict functional programming languages.
Hugs 98 provides an almost complete implementation of Haskell 98.
%package openal
Summary: OpenAL package for Hugs98
Group: Development/Languages
Requires: %{name} = %{version}-%{release}
%description openal
@ -47,7 +48,6 @@ OpenAL package for Hugs98.
%package alut
Summary: ALUT package for Hugs98
Group: Development/Languages
Requires: %{name} = %{version}-%{release}
Requires: %{name}-openal = %{version}-%{release}
@ -57,7 +57,6 @@ ALUT package for Hugs98.
%package x11
Summary: X11 package for Hugs98
Group: Development/Languages
Requires: %{name} = %{version}-%{release}
%description x11
@ -66,7 +65,6 @@ X11 package for Hugs98.
%package opengl
Summary: OpenGL package for Hugs98
Group: Development/Languages
Requires: %{name} = %{version}-%{release}
%description opengl
@ -75,7 +73,6 @@ OpenGL package for Hugs98.
%package glut
Summary: GLUT package for Hugs98
Group: Development/Languages
Requires: %{name} = %{version}-%{release}
Requires: %{name}-opengl = %{version}-%{release}
@ -85,7 +82,6 @@ GLUT package for Hugs98.
%package hgl
Summary: Haskell Graphics Library for Hugs98
Group: Development/Languages
Requires: %{name} = %{version}-%{release}
Requires: %{name}-x11 = %{version}-%{release}
@ -95,7 +91,6 @@ Haskell Graphics Library for Hugs98.
%package demos
Summary: Demo files for Hugs98
Group: Development/Languages
Requires: %{name} = %{version}-%{release}
Requires: %{name}-glut = %{version}-%{release}
Requires: %{name}-hgl = %{version}-%{release}
@ -107,7 +102,9 @@ Demo files for Hugs98.
%prep
%setup -q -n %{name}-%{hugs_ver}
# add undefined struct
%patch0 -p1 -b .gnu
%patch -P0 -p1 -b .gnu
%patch -P1 -p1 -b .config
%patch -P 2 -p1
# use inline keyword
sed -i 's|extern inline|inline|' packages/base/include/HsBase.h packages/network/include/HsNet.h packages/unix/include/HsUnix.h hsc2hs/Main.hs
# libalut needs libopenal
@ -115,10 +112,14 @@ sed -i 's|ALUT_LIBS="$ac_cv_search_alutExit"|ALUT_LIBS="$ac_cv_search_alutExit -
# this is to avoid network lookup of the DTD
sed -i 's|\"http://www.oasis-open.org.*\"||' docs/users_guide/users_guide.xml
# Update config.guess/sub to fix builds on new architectures (aarch64/ppc64le)
cp /usr/lib/rpm/config.* .
cp /usr/lib/rpm/redhat/config.* .
%build
# Work around C99 compatibility issues (bug 2160645).
%global build_type_safety_c 0
# Some configure probes do not use CFLAGS.
export CC="gcc -fpermissive"
%define __global_ldflags ""
%configure --with-pthreads --enable-char-encoding=locale
make %{?_smp_mflags}
@ -128,14 +129,13 @@ make %{?_smp_mflags}
make DESTDIR=%{buildroot} install_all_but_docs
make -C docs DESTDIR=%{buildroot} install_man
%ifnarch aarch64 ppc64le
%ifnarch aarch64 ppc64le x86_64 riscv64
execstack -s %{buildroot}%{_bindir}/{hugs,runhugs,ffihugs}
%endif
find %{buildroot} -name '*.so' -exec chmod 0755 '{}' ';'
mv %{buildroot}%{_libdir}/hugs/demos installed-demos
rm installed-demos/Makefile.in
rm %{buildroot}%{_libdir}/hugs/demos/Makefile.in
mv %{buildroot}%{_datadir}/hsc2hs-*/* %{buildroot}%{_libdir}/hugs/programs/hsc2hs
@ -154,7 +154,11 @@ sed -i "s|^bindir.*|bindir=\"%{_bindir}\"|
%doc docs/server.html
%doc docs/libraries-notes.txt
%doc docs/users_guide/users_guide
%{_bindir}/*
%{_bindir}/cpphs-hugs
%{_bindir}/ffihugs
%{_bindir}/hugs
%{_bindir}/hsc2hs-hugs
%{_bindir}/runhugs
%{_libdir}/hugs
%exclude %{_libdir}/hugs/packages/OpenAL
%exclude %{_libdir}/hugs/packages/ALUT
@ -162,11 +166,11 @@ sed -i "s|^bindir.*|bindir=\"%{_bindir}\"|
%exclude %{_libdir}/hugs/packages/OpenGL
%exclude %{_libdir}/hugs/packages/GLUT
%exclude %{_libdir}/hugs/packages/HGL
%{_mandir}/man*/*
%{_mandir}/man1/hugs.1*
%files demos
%doc installed-demos/*
%{_libdir}/hugs/demos
%files openal
@ -193,24 +197,75 @@ sed -i "s|^bindir.*|bindir=\"%{_bindir}\"|
%{_libdir}/hugs/packages/HGL
%post
update-alternatives --install %{_bindir}/runhaskell runhaskell \
%{_bindir}/runhugs 100
update-alternatives --install %{_bindir}/hsc2hs hsc2hs \
%{_bindir}/hsc2hs-hugs 100
update-alternatives --install %{_bindir}/cpphs cpphs \
%{_bindir}/cpphs-hugs 100
%preun
if [ "$1" = 0 ]; then
update-alternatives --remove runhaskell %{_bindir}/runhugs
update-alternatives --remove hsc2hs %{_bindir}/hsc2hs-hugs
update-alternatives --remove cpphs %{_bindir}/cpphs-hugs
fi
%changelog
* Fri Aug 16 2024 David Abdurachmanov <davidlt@rivosinc.com> - 2006.09-51.0.riscv64
- Disable execstack for RISC-V (riscv64)
* Thu Jul 18 2024 Fedora Release Engineering <releng@fedoraproject.org> - 2006.09-51
- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild
* Wed Jan 24 2024 Fedora Release Engineering <releng@fedoraproject.org> - 2006.09-50
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Sun Jan 21 2024 Florian Weimer <fweimer@redhat.com> - 2006.09-49
- Build with CC="gcc -fpermissive", increase command line buffer size
* Sat Jan 20 2024 Fedora Release Engineering <releng@fedoraproject.org> - 2006.09-48
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Tue Aug 29 2023 Florian Weimer <fweimer@redhat.com> - 2006.09-47
- Set build_type_safety_c to 0 (#2160645)
* Thu Jul 20 2023 Fedora Release Engineering <releng@fedoraproject.org> - 2006.09-46
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
* Thu Jan 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 2006.09-45
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
* Thu Jul 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 2006.09-44
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
* Thu Jan 20 2022 Fedora Release Engineering <releng@fedoraproject.org> - 2006.09-43
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
* Thu Jul 22 2021 Fedora Release Engineering <releng@fedoraproject.org> - 2006.09-42
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 2006.09-41
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
* Sat Aug 01 2020 Fedora Release Engineering <releng@fedoraproject.org> - 2006.09-40
- Second attempt - Rebuilt for
https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
* Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 2006.09-39
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
* Tue May 26 2020 Jeff Law <law@redhat.com> - 2006.09-38
- Fix configure test compromised by LTO.
* Wed Jan 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 2006.09-37
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
* Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2006.09-36
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
* Sat Jul 13 2019 Jens Petersen <petersen@redhat.com> - 2006.09-35
- drop alternatives
- more explicit filelists
* Sun Feb 17 2019 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 2006.09-34
- Rebuild for readline 8.0
* Sun Feb 3 2019 Jens Petersen <petersen@redhat.com> - 2006.09-33
- drop use of execstack on x86_64
* Fri Feb 01 2019 Fedora Release Engineering <releng@fedoraproject.org> - 2006.09-32
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2006.09-31
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
* Mon Feb 19 2018 Jens Petersen <petersen@redhat.com> - 2006.09-30
- BR gcc