Browse Source

Cleanup local source usage

tags/v1.1
falkTX 7 months ago
parent
commit
c128816b40
4 changed files with 23 additions and 7 deletions
  1. +6
    -2
      bootstrap-carla.sh
  2. +2
    -2
      local.env
  3. +3
    -2
      setup/check_target.sh
  4. +12
    -1
      setup/env.sh

+ 6
- 2
bootstrap-carla.sh View File

@@ -170,10 +170,14 @@ function build_pyqt() {
make PREFIX="${PAWPAW_PREFIX}" PKG_CONFIG="${TARGET_PKG_CONFIG}" ${MAKE_ARGS} -j 1 install
if [ -f "QtCore/Makefile.Release" ]; then
if [ "${CROSS_COMPILING}" -eq 1 ]; then
sed -i -e "s|/usr|${PAWPAW_PREFIX}|g" ${PAWPAW_PREFIX}/bin/py*5
sed -i -e "s|/usr|${PAWPAW_PREFIX}|g" "${PAWPAW_PREFIX}/bin"/py*5
fi
if [ -n "${EXE_WRAPPER}" ]; then
sed -i -e "s|exec /|exec ${EXE_WRAPPER} /|" ${PAWPAW_PREFIX}/bin/py*5
sed -i -e "s|exec /|exec ${EXE_WRAPPER} /|" "${PAWPAW_PREFIX}/bin"/py*5
fi
else
if [ "${CROSS_COMPILING}" -eq 1 ]; then
sed -i -e "s|/usr|${PAWPAW_PREFIX}|g" "${PAWPAW_PREFIX}/lib/python3/dist-packages/sipconfig.py"
fi
fi
touch .stamp_installed


+ 2
- 2
local.env View File

@@ -1,7 +1,7 @@
#!/bin/bash

PAWPAW_ROOT="${PWD}"
VALIDATE_TARGET=1
SOURCING_FILES=1

target="${1}"

@@ -22,7 +22,7 @@ source setup/check_target.sh
# ---------------------------------------------------------------------------------------------------------------------
# export vars if valid target

if [ -z "${INVALID_TARGET}" ]; then
if [ "${INVALID_TARGET}" -eq 0 ]; then

source setup/env.sh



+ 3
- 2
setup/check_target.sh View File

@@ -1,6 +1,7 @@
#!/bin/bash

CROSS_COMPILING=0
INVALID_TARGET=0
LINUX=0
MACOS=0
MACOS_OLD=0
@@ -52,7 +53,7 @@ function check_target() {
MACOS_UNIVERSAL=1
fi
;;
default)
default|*)
echo "Invalid target '${target}', possible values are:"
echo "\tmacos"
echo "\tmacos-old"
@@ -60,7 +61,7 @@ function check_target() {
echo "\twin32"
echo "\twin64"
echo "\tnative"
if [ -z "${VALIDATE_TARGET}" ]; then
if [ -z "${SOURCING_FILES}" ]; then
exit 2
else
INVALID_TARGET=1


+ 12
- 1
setup/env.sh View File

@@ -30,7 +30,14 @@ elif [ "${WIN32}" -eq 1 ]; then

else
echo "Unknown target '${target}'"
exit 4
if [ -z "${SOURCING_FILES}" ]; then
exit 4
else
APP_EXT=""
CMAKE_SYSTEM_NAME="Unknown"
PAWPAW_TARGET="unknown"
INVALID_TARGET=1
fi
fi

# ---------------------------------------------------------------------------------------------------------------------
@@ -116,6 +123,9 @@ if [ "${CROSS_COMPILING}" -eq 1 ]; then
TOOLCHAIN_PREFIX="i686-w64-mingw32"
TOOLCHAIN_PREFIX_="${TOOLCHAIN_PREFIX}-"
fi
else
unset TOOLCHAIN_PREFIX
unset TOOLCHAIN_PREFIX_
fi

TARGET_AR="${TOOLCHAIN_PREFIX_}ar"
@@ -134,6 +144,7 @@ TARGET_PKG_CONFIG_PATH="${PAWPAW_PREFIX}/lib/pkgconfig"

MAKE_ARGS=""
WAF_ARGS=""
unset EXE_WRAPPER

if which nproc > /dev/null; then
MAKE_ARGS+="-j $(nproc)"


Loading…
Cancel
Save