diff options
author | Matthias Schiffer <mschiffer@universe-factory.net> | 2021-10-30 00:21:04 +0200 |
---|---|---|
committer | Matthias Schiffer <mschiffer@universe-factory.net> | 2021-10-30 21:15:09 +0200 |
commit | 3fbe53aec0f340a90858265ca8f890314fa5d523 (patch) | |
tree | 32a666397b7c97c6ba202274b7f0aaf0e2166422 /examples/recipes/libgcc-initial.yml | |
parent | 6d77ac17b4414d30384473c667e08199f428d94e (diff) | |
download | rebel-3fbe53aec0f340a90858265ca8f890314fa5d523.tar rebel-3fbe53aec0f340a90858265ca8f890314fa5d523.zip |
examples: move recipes to subdirectory
Diffstat (limited to 'examples/recipes/libgcc-initial.yml')
-rw-r--r-- | examples/recipes/libgcc-initial.yml | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/examples/recipes/libgcc-initial.yml b/examples/recipes/libgcc-initial.yml new file mode 100644 index 0000000..fc047e8 --- /dev/null +++ b/examples/recipes/libgcc-initial.yml @@ -0,0 +1,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 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 |