| 1 | --- a/gcc-libs/PKGBUILD.vile |
| 2 | +++ b/gcc-libs/PKGBUILD.vile |
| 3 | @@ -6,2 +6 @@ |
| 4 | -arm := string=?(arch, "aarch64") |
| 5 | -libc := if arm { "musl>=1.2.6-4" } else { "musl" } |
| 6 | +libc := if string=?(arch, "aarch64") { "musl>=1.2.6-3" } else { "musl" } |
| 7 | @@ -14 +13 @@ |
| 8 | - #:pkgrel, if arm { 2 } else { 1 }, |
| 9 | + #:pkgrel, 1, |
| 10 | @@ -41 +39,0 @@ |
| 11 | - target-flags := if arm { "-O2 -g0 -mno-outline-atomics" } else { "-O2 -g0" } |
| 12 | @@ -43,5 +41 @@ |
| 13 | - list("CC_FOR_BUILD=gcc", "CXX_FOR_BUILD=g++", "CFLAGS_FOR_BUILD=-O2 -g0", "CXXFLAGS_FOR_BUILD=-O2 -g0", "LDFLAGS_FOR_BUILD=", |
| 14 | - "AR_FOR_BUILD=ar", "RANLIB_FOR_BUILD=ranlib", |
| 15 | - string-append("AR=", prefix, "ar"), string-append("AS=", prefix, "as"), |
| 16 | - string-append("LD=", prefix, "ld"), string-append("NM=", prefix, "nm"), |
| 17 | - string-append("RANLIB=", prefix, "ranlib"), string-append("STRIP=", prefix, "strip"), |
| 18 | + list("CFLAGS_FOR_BUILD=-O2 -g0", "CXXFLAGS_FOR_BUILD=-O2 -g0", "LDFLAGS_FOR_BUILD=", |
| 19 | @@ -53 +47 @@ |
| 20 | - "CFLAGS=-O1 -g0", string-append("CFLAGS_FOR_TARGET=", target-flags), string-append("CXXFLAGS_FOR_TARGET=", target-flags)), target-tools, |
| 21 | + "CFLAGS=-O1 -g0", "CFLAGS_FOR_TARGET=-O2 -g0", "CXXFLAGS_FOR_TARGET=-O2 -g0"), target-tools, |
| 22 | @@ -60,2 +54 @@ |
| 23 | - apply(run, append(list("make"), target-tools, list("configure-gcc", "all-build-libiberty", "all-build-fixincludes", |
| 24 | - "all-libiberty", "all-libcpp", "all-libdecnumber", "all-libbacktrace"))) |
| 25 | + run("make", "configure-gcc", "all-build-libiberty", "all-build-fixincludes", "all-libiberty", "all-libcpp", "all-libdecnumber", "all-libbacktrace") |
| 26 | @@ -64,2 +57,2 @@ |
| 27 | - apply(run, append(list("make", "-C", "gcc", "-o", "xgcc", "-o", "specs", "-o", "cc1", "GCC_FOR_TARGET=vinix-cc"), |
| 28 | - target-tools, list("GENERATOR_CFLAGS=-O2 -g0", "libgcc-support", "tm.h", "options.h", "insn-constants.h", "insn-modes.h", "insn-modes-inline.h"))) |
| 29 | + run("make", "-C", "gcc", "-o", "xgcc", "-o", "specs", "-o", "cc1", "GCC_FOR_TARGET=vinix-cc", |
| 30 | + "GENERATOR_CFLAGS=-O2 -g0", "libgcc-support", "tm.h", "options.h", "insn-constants.h", "insn-modes.h", "insn-modes-inline.h") |
| 31 | @@ -95,6 +88,2 @@ |
| 32 | - if arm { |
| 33 | - for-each(fn(lib) { |
| 34 | - file := string-append(dest, "/", lib) |
| 35 | - run("vinix-elf-pages", arch, file) |
| 36 | - run("sh", "-ec", "readelf --wide --dyn-syms \"$1\" | awk '$7 == \"UND\" && $8 ~ /^__aarch64_(cas|swp|ldadd|ldclr|ldeor|ldset)/ { print $8; bad=1 } END { exit bad }'", "check-outlined-atomics", file) |
| 37 | - }, libs) |
| 38 | + if string=?(arch, "aarch64") { |
| 39 | + for-each(fn(lib) { run("vinix-elf-pages", arch, string-append(dest, "/", lib)) }, libs) |
| 40 | |