diff options
author | BlackNoxis <steven.darklight@gmail.com> | 2014-12-03 03:20:49 +0200 |
---|---|---|
committer | BlackNoxis <steven.darklight@gmail.com> | 2014-12-03 03:20:49 +0200 |
commit | 58ae5bbf25835bd30fa385275ff4486dbc31f0a2 (patch) | |
tree | 3a68352e09b5cce3a8a33a7eef956e9d254d126e /bin/armv7a-emerge |
Making public our Kogaion bin
Diffstat (limited to 'bin/armv7a-emerge')
-rwxr-xr-x | bin/armv7a-emerge | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/bin/armv7a-emerge b/bin/armv7a-emerge new file mode 100755 index 0000000..742b925 --- /dev/null +++ b/bin/armv7a-emerge @@ -0,0 +1,28 @@ +#!/bin/sh + +. /etc/make.conf + +# just make sure +FEATURES="${FEATURES} distcc distcc-pump" + +DISTCC_PATH="/usr/lib/distcc/bin" +CUR_CHOST="$(basename /usr/lib/gcc/armv*)" +DISTCC_WRAPPER="${CUR_CHOST}-wrapper" + +pushd "${DISTCC_PATH}" > /dev/null || exit 1 +cur_link=$(readlink cc) +if [ "${cur_link}" = "/usr/bin/distcc" ] || [ ! -f "${DISTCC_WRAPPER}" ]; then + echo "Fixing links in ${DISTCC_PATH}" + rm -f c++ g++ gcc cc || exit 1 + echo "#!/bin/bash" > "${DISTCC_WRAPPER}" + echo "exec /usr/lib/distcc/bin/${CUR_CHOST}-g\${0:\$[-2]} \"\$@\"" >> "${DISTCC_WRAPPER}" + chmod a+x "${DISTCC_WRAPPER}" || exit 1 + ln -s "${DISTCC_WRAPPER}" cc || exit 1 + ln -s "${DISTCC_WRAPPER}" gcc || exit 1 + ln -s "${DISTCC_WRAPPER}" g++ || exit 1 + ln -s "${DISTCC_WRAPPER}" c++ || exit 1 +fi +popd > /dev/null + +export FEATURES PATH +exec emerge "$@" |