blob: 66b5e77acc72298f2c4027a6cc14317d4949e423 (
plain)
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
|
meta:
name: 'gcc'
version: '11.2.0'
tasks:
configure:
args:
host: 'platform'
target: 'platform'
inherit:
recipe: 'gcc'
task: 'compile'
depends:
- recipe: 'gcc'
task: 'header-stubs'
run: |
cd {{pn}}-build
make configure-target-libgcc
# A hack borrowed from OpenEmbedded:
# We can build an initial libgcc without having to rebuild the whole gcc
# afterwards by manipulating the Makefile
sed -i -r \
-e 's@^(INHIBIT_LIBC_CFLAGS =).*@\1 -Dinhibit_libc@' \
gcc/libgcc.mvars
sed -i -r \
-e 's@^(thread_header =).*@\1 gthr-single.h@' \
-e 's@^(enable_shared =).*@\1 no@' \
{{target.gnu_triplet}}/libgcc/Makefile
compile:
args:
host: 'platform'
target: 'platform'
inherit:
task: 'configure'
run: |
cd {{pn}}-build
make -j8 all-target-libgcc
install:
args:
host: 'platform'
target: 'platform'
inherit:
task: 'compile'
output:
default: {}
run: |
cd {{pn}}-build
make DESTDIR={{destdir}} install-target-libgcc
ln -s libgcc.a {{destdir}}{{host.prefix}}/lib/gcc/{{target.gnu_triplet}}/"$(cat ../{{pn}}-{{pv}}/gcc/BASE-VER)"/libgcc_eh.a
|