index : builder | |
Archlinux32 build system | gitolite user |
summaryrefslogtreecommitdiff |
author | Erich Eckner <erich.eckner.ext@bestsecret.com> | 2023-05-22 16:22:29 +0200 |
---|---|---|
committer | Erich Eckner <erich.eckner.ext@bestsecret.com> | 2023-05-22 16:22:29 +0200 |
commit | 62f871fb25b70860364b0023745c0f31516e69d0 (patch) | |
tree | 8efdaff49293547ee945ff0d10612187a3b06594 /bin/check-opcodes | |
parent | d14686b0bdc0b2418300c5d34d5f13c19988f020 (diff) |
-rwxr-xr-x | bin/check-opcodes | 10 |
diff --git a/bin/check-opcodes b/bin/check-opcodes index 2949819..48a1d45 100755 --- a/bin/check-opcodes +++ b/bin/check-opcodes @@ -93,7 +93,6 @@ PACKAGE=$1 if test "$PACKAGE" = ""; then echo "ERROR: Filename of a package required as argument" >&2 usage - exit 1 fi OPCODE_ARGS="" @@ -111,7 +110,6 @@ case $ARCH in *) echo "ERROR: architecture must currently be one of i486, i686 and pentium3" >&2 usage - exit 1 esac debug "Unpacking $PACKAGE to $tmp_dir.." @@ -133,7 +131,7 @@ for absfile in $(find $tmp_dir \( -regextype grep -regex '.*\.so\(\.[0-9.]\+\)\? continue fi file $absfile > $tmp_dir/$file.file - + arch=$(grep ^architecture $tmp_dir/$file.objdump | sed 's/^architecture: //g' | cut -f 1 -d ,) case $arch in i386:x86-64) @@ -147,7 +145,7 @@ for absfile in $(find $tmp_dir \( -regextype grep -regex '.*\.so\(\.[0-9.]\+\)\? ;; esac debug " Objdump architecture: $arch" - + archelf=$(grep '^ \+Class' $tmp_dir/$file.elf | cut -f 2 -d : | tr -d ' ') case $archelf in ELF64) @@ -165,7 +163,7 @@ for absfile in $(find $tmp_dir \( -regextype grep -regex '.*\.so\(\.[0-9.]\+\)\? if test $arch != $archelf; then err "ERROR: $file ambigous architecture information (objdump: $arch, ELF: $archelf)" fi - + if test $arch = "x86_64"; then err "ERROR: $file is a 64-bit library!" continue @@ -193,7 +191,7 @@ for absfile in $(find $tmp_dir \( -regextype grep -regex '.*\.so\(\.[0-9.]\+\)\? verbose "OK: $relfile fullfills architecture constraint for $ARCH" fi fi - + done exit $EXIT_CODE |