-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgcc.spec
56 lines (47 loc) · 1.39 KB
/
gcc.spec
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
Name: gcc
Version: 14.2.0
Release: 1
Summary: The GNU Compiler Collection
License: GPL-3.0-or-later WITH GCC-exception-3.1
URL: http://gcc.gnu.org
Source0: https://ftp.gnu.org/gnu/%{name}/%{name}-%{version}/%{name}-%{version}.tar.xz
BuildRequires: gcc-c++ make
BuildRequires: gmp-devel mpfr-devel libmpc-devel
# BuildRequires: chrpath
# BuildRequires: isl-devel libzstd-devel
%description
The GNU Compiler Collection includes front ends for C and C++ as well as libraries for C++ (libstdc++)
%prep
%autosetup
%build
# override rpm provided compiler flags
export CFLAGS=""
export CXXFLAGS=""
export LDFLAGS=""
mkdir build
cd build
# libsanitizer has rpath issues:
# 0x0020 an RPATH references '..' of an absolute path; this will break the functionality when the path before '..' is a symlink
# ERROR 0020: file '/usr/lib64/libasan.so.8.0.0' contains a runpath referencing '..' of an absolute path [/usr/lib/../lib64]
# Configure reference:
# https://gcc.gnu.org/install/configure.html
../configure --prefix=%{_prefix} \
--disable-bootstrap \
--enable-languages=c,c++ \
--disable-multilib \
--disable-libsanitizer \
--disable-gcov \
--disable-libquadmath \
--disable-vtv \
--disable-libssp \
--disable-libgomp \
--disable-lto \
--with-arch=x86-64-v3
%make_build
%install
cd build
make DESTDIR=%{buildroot} install-strip
%files
%changelog
* Mon Sep 16 2024 Liu Zixian <[email protected]> 14.2.0-1
- init