-
Notifications
You must be signed in to change notification settings - Fork 71
/
package.yml
179 lines (175 loc) · 6.51 KB
/
package.yml
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
name : gcc
version : 14.1.0
release : 82
source :
- https://ftp.gnu.org/gnu/gcc/gcc-14.1.0/gcc-14.1.0.tar.xz : e283c654987afe3de9d8080bc0bd79534b5ca0d681a73a11ff2b5d3767426840
homepage : https://gcc.gnu.org/
license : GPL-3.0-or-later
component :
- system.devel
- ^g++ : system.devel
- ^gfortran : system.devel
- ^gfortran-32bit : emul32
- ^libgcc : system.base
- ^libgcc-32bit : emul32
- ^libstdc++ : system.base
- ^libstdc++-32bit : emul32
- ^libgomp : system.base
- ^libgomp-32bit : emul32
- ^libgfortran : programming.library
- ^libgfortran-32bit : emul32
autodep : no
ccache : no
mancompress: yes
summary : GNU Compiler Collection
description: |
The GNU Compiler Collection includes front ends for C, C++, Objective-C, Fortran, Java, Ada, and Go, as well as libraries for these languages (libstdc++, libgcj,...). GCC was originally written as the compiler for the GNU operating system. The GNU system was developed to be 100% free software, free in the sense that it respects the user's freedom.
builddeps :
- pkgconfig32(libzstd)
- glibc-32bit-devel
- gcc-ada-32bit
- gcc-ada
- isl-32bit-devel
- libgcc-32bit
- libstdc++-32bit
rundeps :
- mpc
- mpfr
- ^g++ : gcc
- ^gfortran :
- gcc
- libgfortran
- ^libgcc-32bit : libgcc
- ^libstdc++-32bit : libstdc++
- ^libgomp-32bit :
- libgcc-32bit
- libgomp
- ^libgfortran-32bit : libgfortran
replaces :
- ^libgfortran-32bit : gfortran-32bit
patterns :
- ^libgcc :
- /usr/lib64/libatomic*.so*
- /usr/lib64/libgcc*.so*
- /usr/lib64/libquadmath.so*
- /* # No idea why but ypkg errors out during pspec creation if this isn't present
- ^libgcc-32bit :
- /usr/lib32/libatomic*.so*
- /usr/lib32/libgcc*.so*
- /usr/lib32/libquadmath.so*
- ^libgfortran :
- /usr/lib64/*fortran.so*
- ^libgfortran-32bit :
- /usr/lib32/*fortran.so*
- ^libgomp :
- /usr/lib64/libgomp.so*
- ^libgomp-32bit :
- /usr/lib32/libgomp.so*
- ^libstdc++ :
- /usr/lib64/lib*++*.so*
- /usr/share/gcc-*/python/libstdcxx
- /usr/share/gdb/auto-load/usr/lib64/libstdc++*
- /usr/share/locale/*/LC_MESSAGES/libstdc++.mo
- ^libstdc++-32bit :
- /usr/lib32/lib*++*.so*
- /usr/share/gdb/auto-load/usr/lib32/libstdc++*
- main :
- /usr/bin
- /usr/lib64/bfd-plugins
- /usr/lib64/gcc
- /usr/share/info
- /usr/share/locale/*/LC_MESSAGES/gcc.mo
- /usr/share/man
- /usr/lib*/*.a
- /usr/lib*/*.o
- /usr/lib*/*.so
- /usr/lib*/*.spec
- /usr/lib*/libasan*.so*
- /usr/lib*/libcc1*.so*
- /usr/lib*/libhwasan*.so*
- /usr/lib*/libitm*.so*
- /usr/lib*/liblsan*.so*
- /usr/lib*/libtsan*.so*
- /usr/lib*/libubsan*.so*
- ^g++ :
- /usr/bin/c++
- /usr/bin/cpp
- /usr/bin/g++*
- /usr/bin/*-g++*
- /usr/bin/*-c++*
- /usr/include/c++
- /usr/lib*/lib*++*.a
- /usr/lib*/lib*++*.so
- /usr/share/locale/*/LC_MESSAGES/cpplib.mo
- /usr/share/man/*/cpp*
- /usr/share/man/*/g++*
- ^gfortran :
- /usr/bin/*fortran*
- /usr/lib*/*fortran*.spec
- /usr/lib*/*fortran*.a
- /usr/share/man/*/*fortran*
- ^gcc-ada :
- /usr/bin/gnat*
- /usr/lib64/gcc/x86_64-solus-linux/14/gnat1
- /usr/lib64/gcc/x86_64-solus-linux/14/ada*
- /usr/share/info/gnat*.info
- ^gcc-ada-32bit :
- /usr/lib64/gcc/x86_64-solus-linux/14/32/ada*
environment: |
export triplet=x86_64-solus-linux
# Set sane and safe flags for a compiler build
export CFLAGS="-mtune=generic -march=x86-64 -g1 -O3 -fstack-protector -pipe -fPIC -Wl,-z,relro -Wl,-z,now -Wl,-z,max-page-size=0x1000"
export CXXFLAGS="-mtune=generic -march=x86-64 -g1 -O3 -pipe -fPIC -Wl,-z,max-page-size=0x1000"
export CFLAGS_FOR_TARGET=${CFLAGS}
export CC=${triplet}-gcc
export CXX=${triplet}-g++
setup : |
%patch -p1 -i $pkgfiles/0002-Use-usr-lib-64-32-x32-for-linker-locations-on-Solus-.patch
%patch -p1 -i $pkgfiles/optimize.patch
%patch -p1 -i $pkgfiles/0001-Ignore-Werror-if-GCC_IGNORE_WERROR-environment-varia.patch
%patch -p1 -i $pkgfiles/0001-libtool-no-rpath.patch
mkdir build && pushd build
../configure --prefix=/usr \
--with-pkgversion='Solus' \
--libdir=/usr/lib64 \
--libexecdir=/usr/lib64 \
--with-arch_32=i686 \
--with-bugurl='https://dev.getsol.us/' \
--with-build-config=bootstrap-lto-lean \
--with-gcc-major-version-only \
--with-linker-hash-style=gnu \
--with-multilib-list=m32,m64 \
--with-system-zlib \
--enable-cet \
--enable-checking=release \
--enable-default-pie \
--enable-default-ssp \
--enable-gnu-indirect-function \
--enable-host-bind-now \
--enable-host-pie \
--enable-host-shared \
--enable-languages=c,c++,fortran,ada \
--enable-linker-build-id \
--enable-multilib \
--enable-plugin \
--enable-shared \
--enable-threads=yes \
--disable-libssp \
--build=${triplet} \
--target=${triplet}
build : |
# Note: If you're working on GCC and want fast build times then use `bootstrap2-lean` instead of `profiledbootstrap`,
# and `bootstrap-O1` for the build config above instead of `bootstrap-lto-lean`. This cuts build times by ~68%
%make -C build profiledbootstrap -O
install : |
%make_install -C build
sversion=${version%.*.*}
# Linky linky
ln -srv $installdir/usr/bin/gcc $installdir/usr/bin/cc
# Ensure LTO will work properly.
install -dm 00755 $installdir/%libdir%/bfd-plugins
ln -srv $installdir/%libdir%/gcc/$triplet/$sversion/liblto_plugin.so $installdir/%libdir%/bfd-plugins/liblto_plugin.so
# Install gdb files to right location
install -dm00755 $installdir/usr/share/gdb/auto-load/usr/lib{32,64}
mv $installdir/usr/lib32/libstdc++.so.*-gdb.py $installdir/usr/share/gdb/auto-load/usr/lib32/.
mv $installdir/%libdir%/libstdc++.so.*-gdb.py $installdir/usr/share/gdb/auto-load/%libdir%/.