#
# Copyright (c) 2000-2005 Per Liden
# Copyright (c) 2006-2013 by CRUX team (http://crux.nu)
+#
+# Patches for crosscompilation by Jose V Beneyto <sepen@crux.nu>
+# (CRUX-ARM System Team <devel@crux-arm.nu>)
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
find . -type f -printf "%P\n" | $FILTER | while read FILE; do
case $(file -b "$FILE") in
*ELF*executable*not\ stripped)
- strip --strip-all "$FILE"
+ $STRIP_CMD --strip-all "$FILE"
;;
*ELF*shared\ object*not\ stripped)
- strip --strip-unneeded "$FILE"
+ $STRIP_CMD --strip-unneeded "$FILE"
;;
current\ ar\ archive)
- strip --strip-debug "$FILE"
+ $STRIP_CMD --strip-debug "$FILE"
esac
done
}
done
}
+fix_cross_paths() {
+ # remove the last / from CLFS path if appeared
+ CLFS=${CLFS%*/}
+
+ find $PKG -type f -name '*.la' -exec sed -e "s|$CLFS||g" -e "s|$CROSTOOLS/$CTARGET|/usr|g" -i {} \;
+}
+
check_footprint() {
local FILE="$PKGMK_WORK_DIR/.tmp"
if [ "$PKGMK_NO_STRIP" = "no" ]; then
strip_files
fi
-
+
compress_manpages
+ fix_cross_paths
cd $PKG
info "Build result:"
}
main() {
- # multilib
- PKGMK_ARCH=64
- if [ -f ".32bit" ]; then
- PKGMK_ARCH=32
- fi
-
local FILE TARGET
parse_options "$@"