File: linux32-wrapper

package info (click to toggle)
gridengine 6.2u5-1squeeze1
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 57,132 kB
  • ctags: 56,142
  • sloc: ansic: 438,030; java: 66,252; sh: 36,376; jsp: 7,757; xml: 5,850; makefile: 5,514; csh: 4,571; cpp: 2,848; perl: 2,401; tcl: 692; lisp: 669; yacc: 668; ruby: 642; lex: 344
file content (18 lines) | stat: -rw-r--r-- 682 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/sh

# On architectures where we sometimes have 64-bit kernels on buildds when we
# want to build for 32-bit userland (seen especially on the experimental
# buildds), make sure we invoke the commands using linux32 otherwise the
# binaries end up with the wrong arch name hardcoded in them

# TODO: Probably changing how the arch name is detected in the build
#       scripts would be a more clever idea

DEB_BUILD_ARCH=$(dpkg-architecture -qDEB_BUILD_ARCH)

if [ ${DEB_BUILD_ARCH} = "powerpc" -o ${DEB_BUILD_ARCH} = "i386" -o ${DEB_BUILD_ARCH} = "sparc" -o ${DEB_BUILD_ARCH} = "s390" -o ${DEB_BUILD_ARCH} = "hppa" ]; then
    exec /usr/bin/linux32 "$@"
else
    exec "$@"
fi