Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:Andreas_Schwab:riscv:ghc:bootstrap
ghc-prepare-binary-distributions
ghc-prepare-binary-distributions.spec
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File ghc-prepare-binary-distributions.spec of Package ghc-prepare-binary-distributions
# # spec file for package ghc-prepare-binary-distributions # # Copyright (c) 2023 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via https://bugs.opensuse.org/ # #%global unregisterised_archs s390 s390x riscv64 %ifarch aarch64 %define longarch aarch64 %endif %ifarch ppc64 %define longarch powerpc64 %endif %ifarch ppc64le %define longarch powerpc64le %endif %ifarch riscv64 %define longarch riscv64 %endif %ifarch s390 %define longarch s390 %endif %ifarch s390x %define longarch s390x %endif %ifarch x86_64 %define longarch x86_64 %endif %ifarch s390 s390x %define sysname ibm %else %define sysname unknown %endif %define system_libffi 1 Name: ghc-prepare-binary-distributions Version: 9.4.4 Release: 0 Summary: The Glorious Glasgow Haskell Compiler binary distribution License: BSD-3-Clause Group: Development/Languages/Other URL: https://haskell.org/ghc Source: http://haskell.org/ghc/dist/%{version}/ghc-%{version}-src.tar.xz #%%Source: ghc-%{version}-src.tar.xz Source1: 9_4_6_bootstrap_sources.tar.gz Patch1: ghc-gen_contents_index-haddock-path.patch # for unregisterized (s390x) # https://ghc.haskell.org/trac/ghc/ticket/15689 Patch2: ghc-Cabal-install-PATH-warning.patch # PATCH-FIX-UPSTREAM Disable-unboxed-arrays.patch ptrommler@icloud.com -- Do not use unboxed arrays on big-endian platforms. See Haskell Trac #15411. Patch3: Disable-unboxed-arrays.patch # PATCH-FIX-UPSTREAM execstack.patch -- RTS: Add stack marker to StgCRunAsm.S Patch7: execstack.patch # Work around a bug in Sphinx 6.1.x to fix the documentation build. Remove this patch ASAP. Patch8: bytestring.patch # PATCH-FIX-UPSTREAM ghc-pie.patch - set linux as default PIE platform Patch35: ghc-pie.patch Patch200: ghc-hadrian-s390x-rts--qg.patch Patch300: sphinx7.patch BuildRequires: alex BuildRequires: autoconf BuildRequires: automake BuildRequires: binutils-devel BuildRequires: ghc-bytestring-devel BuildRequires: gcc BuildRequires: gcc-c++ BuildRequires: ghc-array-devel BuildRequires: ghc-binary-devel BuildRequires: ghc-containers-devel BuildRequires: ghc-deepseq-devel BuildRequires: ghc-directory-devel BuildRequires: ghc-filepath-devel BuildRequires: ghc-ghc-boot-th-devel BuildRequires: ghc-pretty-devel BuildRequires: ghc-parsec-devel BuildRequires: ghc-Cabal-devel BuildRequires: ghc-process-devel BuildRequires: ghc-rpm-macros-extra BuildRequires: ghc-stm-devel BuildRequires: ghc-mtl-devel BuildRequires: ghc-template-haskell-devel BuildRequires: ghc-text-devel BuildRequires: ghc-time-devel BuildRequires: ghc-transformers-devel BuildRequires: ghc-unix-devel BuildRequires: gmp-devel BuildRequires: happy BuildRequires: libelf-devel BuildRequires: libffi-devel BuildRequires: lzip BuildRequires: make # for terminfo # for terminfo BuildRequires: ncurses-devel BuildRequires: pkgconfig BuildRequires: python3 # ignore failures with unregisterised compilers (s390x) #!BuildIgnore: post-build-checks ExcludeArch: %{arm} %{ix86} %ifarch riscv64 s390x BuildRequires: llvm14-devel BuildRequires: llvm14 BuildRequires: clang14 %define hadrian_llvm +llvm %endif BuildRequires: memory-constraints %description Haskell is the standard purely functional programming language; the current language version is Haskell 98, agreed in December 1998. GHC is a state-of-the-art programming suite for Haskell. Included is an optimising compiler generating good code for a variety of platforms, together with an interactive system for convenient, quick development. The distribution includes space and time profiling facilities, a large collection of libraries, and support for various language extensions, including concurrency, exceptions, and foreign language interfaces (C, C++, etc). A wide variety of Haskell related resources (tutorials, libraries, specifications, documentation, compilers, interprbeters, references, contact information, links to research groups) are available from the Haskell home page at <http://www.haskell.org/>. %prep %setup -q -n ghc-%{version} # workaround bogus gcc warning that causes unregistered builds to be rejected # by OBS - rpmlint filters do not work with OBS checks %patch1 -p1 %patch2 -p1 %patch7 -p1 %patch8 -p1 %ifarch s390 s390x %patch3 -p1 %endif %patch35 -p1 %ifarch ppc64le s390x riscv64 %patch200 -p1 %endif %patch300 -p1 rm libffi-tarballs/libffi-*.tar.gz sed -i -e '/SRC_CC_OPTS/s/$/ -Wno-return-type/' mk/warnings.mk %build autoupdate python3 boot.source --hadrian %if 0%{?qemu_user_space_build} %limit_build -m 15000 %endif cp %{SOURCE1} ./ hadrian/bootstrap/bootstrap.py --bootstrap-sources 9_4_6_bootstrap_sources.tar.gz %global hadrian _build/bin/hadrian #cat > mk/build.mk <<EOF #%ifnarch %{unregisterised_archs} #%ifarch aarch64 %{arm} #BuildFlavour = quick-llvm #%else #BuildFlavour = quick #%endif #%endif #GhcLibWays = v #DYNAMIC_GHC_PROGRAMS = NO #%ifarch %{unregistered_archs} #GhcUnregisterised=YES #GhcUnregisterised = YES #GhcWithNativeCodeGen = NO #SRC_HC_OPTS = -O -H64m #GhcStage1HcOpts = -O #GhcStage2HcOpts = -O #GhcHcOpts = -Rghc-timing #GhcLibHcOpts = -O #SRC_HC_OPTS += -optc-fno-builtin -optc-Wno-return-type #SRC_CC_OPTS += -fno-builtin -Wno-return-type #%endif #HSCOLOUR_SRCS = NO #HADDOCK_DOCS = NO #EOF # macro ... %{ghc_set_gcc_flags} export LANG=C.utf8 export CFLAGS="${CFLAGS:-%{optflags}}" # FIXME: you should use the %%configure macro ./configure --with-system-libffi \ %ifarch %{ghc_unregisterized_arches} --enable-unregisterised \ %endif %{nil} #%%ifarch %{unregisterised_archs} #%%if 0%{?qemu_user_space_build} #%%limit_build -m 15000 #%%else #%%limit_build -m 8000 #%%endif #%%else #%%limit_build -m 2000 #%%endif #make -j 2 #make binary-dist %{hadrian} --docs=none --flavour=quick%{?hadrian_llvm} binary-dist-xz %install mkdir -p %{buildroot}%{_datadir}/ghc cp _build/bindist/ghc-%{version}-%{longarch}-%{sysname}-linux.tar.xz %{buildroot}%{_datadir}/ghc %check #cd /tmp #tar -Jxvf %{buildroot}%{_datadir}/ghc/ghc-%{version}-%{longarch}-%{sysname}-linux.tar.xz #cd ghc-%{version} #./configure --prefix=/tmp/disttest #%make_build install %files %dir %{_datadir}/ghc %{_datadir}/ghc/ghc-%{version}-%{longarch}-%{sysname}-linux.tar.xz %changelog
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor