mirror of
https://github.com/Relintai/osxcross.git
synced 2025-02-03 22:45:56 +01:00
Some cleanup
This commit is contained in:
parent
85d8dd92f6
commit
ada9ea8d1b
3
build.sh
3
build.sh
@ -158,7 +158,8 @@ popd &>/dev/null
|
|||||||
## Extract SDK and move it to $SDK_DIR ##
|
## Extract SDK and move it to $SDK_DIR ##
|
||||||
|
|
||||||
SDK=$(ls $TARBALL_DIR/MacOSX$SDK_VERSION*)
|
SDK=$(ls $TARBALL_DIR/MacOSX$SDK_VERSION*)
|
||||||
extract $SDK 1 1
|
echo ""
|
||||||
|
extract $SDK
|
||||||
|
|
||||||
rm -rf $SDK_DIR/MacOSX$SDK_VERSION* 2>/dev/null
|
rm -rf $SDK_DIR/MacOSX$SDK_VERSION* 2>/dev/null
|
||||||
if [ "$(ls -l SDKs/*$SDK_VERSION* 2>/dev/null | wc -l | tr -d ' ')" != "0" ]; then
|
if [ "$(ls -l SDKs/*$SDK_VERSION* 2>/dev/null | wc -l | tr -d ' ')" != "0" ]; then
|
||||||
|
@ -82,12 +82,14 @@ echo "cleaning up ..."
|
|||||||
|
|
||||||
rm -rf llvm* 2>/dev/null
|
rm -rf llvm* 2>/dev/null
|
||||||
|
|
||||||
extract "$TARBALL_DIR/$(basename $LLVM_PKG)" 2 0
|
extract "$TARBALL_DIR/$(basename $LLVM_PKG)"
|
||||||
|
|
||||||
pushd llvm* &>/dev/null
|
pushd llvm* &>/dev/null
|
||||||
pushd tools &>/dev/null
|
pushd tools &>/dev/null
|
||||||
|
|
||||||
extract "$TARBALL_DIR/$(basename $CLANG_PKG)" 1
|
extract "$TARBALL_DIR/$(basename $CLANG_PKG)"
|
||||||
|
echo ""
|
||||||
|
|
||||||
[ -e clang* ] && mv clang* clang
|
[ -e clang* ] && mv clang* clang
|
||||||
[ -e cfe* ] && mv cfe* clang
|
[ -e cfe* ] && mv cfe* clang
|
||||||
|
|
||||||
|
@ -51,7 +51,7 @@ popd &>/dev/null
|
|||||||
echo "cleaning up ..."
|
echo "cleaning up ..."
|
||||||
rm -rf gcc* 2>/dev/null
|
rm -rf gcc* 2>/dev/null
|
||||||
|
|
||||||
extract "$OSXCROSS_TARBALL_DIR/gcc-$GCC_VERSION.tar.xz" 1
|
extract "$OSXCROSS_TARBALL_DIR/gcc-$GCC_VERSION.tar.xz"
|
||||||
echo ""
|
echo ""
|
||||||
|
|
||||||
pushd gcc*$GCC_VERSION* &>/dev/null
|
pushd gcc*$GCC_VERSION* &>/dev/null
|
||||||
@ -89,7 +89,7 @@ if [ $(osxcross-cmp $OSXCROSS_SDK_VERSION '>=' 10.14) -eq 1 ] &&
|
|||||||
|
|
||||||
for file in ${files_to_patch[*]}; do
|
for file in ${files_to_patch[*]}; do
|
||||||
if [ -f $file ]; then
|
if [ -f $file ]; then
|
||||||
echo patching $PWD/$file
|
echo "patching $PWD/$file"
|
||||||
$SED -i 's/#include <sys\/sysctl.h>/#define _Atomic volatile\n#include <sys\/sysctl.h>\n#undef _Atomic/g' $file
|
$SED -i 's/#include <sys\/sysctl.h>/#define _Atomic volatile\n#include <sys\/sysctl.h>\n#undef _Atomic/g' $file
|
||||||
$SED -i 's/#include <sys\/mount.h>/#define _Atomic volatile\n#include <sys\/mount.h>\n#undef _Atomic/g' $file
|
$SED -i 's/#include <sys\/mount.h>/#define _Atomic volatile\n#include <sys\/mount.h>\n#undef _Atomic/g' $file
|
||||||
fi
|
fi
|
||||||
|
@ -158,7 +158,6 @@ function verify_sdk_version()
|
|||||||
|
|
||||||
function extract()
|
function extract()
|
||||||
{
|
{
|
||||||
test $# -ge 2 -a $# -lt 4 && test $2 -eq 2 && echo ""
|
|
||||||
echo "extracting $(basename $1) ..."
|
echo "extracting $(basename $1) ..."
|
||||||
|
|
||||||
local tarflags
|
local tarflags
|
||||||
@ -187,10 +186,6 @@ function extract()
|
|||||||
exit 1
|
exit 1
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
if [ $# -eq 2 -o $# -eq 4 ]; then
|
|
||||||
echo ""
|
|
||||||
fi
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user