diff --git a/meson-scripts/Makefile b/meson-scripts/Makefile index 8774db7..138b1c7 100644 --- a/meson-scripts/Makefile +++ b/meson-scripts/Makefile @@ -1,4 +1,4 @@ -PYTHON ?= $(shell which python3 >/dev/null && echo python3 || echo python) +PYTHON ?= $(shell command -v python3 >/dev/null && echo python3 || echo python) all $(MAKECMDGOALS): @$(PYTHON) \ @@ -8,7 +8,7 @@ all $(MAKECMDGOALS): $(MAKECMDGOALS) git-submodules: - @if [ ! -f releng/meson/meson.py ]; then \ + @if [ ! -f releng/meson/meson.py ] || git submodule status 2>/dev/null | grep -q '^-'; then \ git submodule update --init --recursive --depth 1; \ fi -include git-submodules diff --git a/meson-scripts/configure b/meson-scripts/configure index a4d189a..12b51a2 100755 --- a/meson-scripts/configure +++ b/meson-scripts/configure @@ -1,12 +1,12 @@ #!/bin/sh -[ -z "$PYTHON" ] && PYTHON=$(which python3 >/dev/null && echo python3 || echo python) +[ -z "$PYTHON" ] && PYTHON=$(command -v python3 >/dev/null && echo python3 || echo python) cd $(dirname $0) srcroot=$(pwd) -if [ ! -f releng/meson/meson.py ]; then +if [ ! -f releng/meson/meson.py ] || git submodule status 2>/dev/null | grep -q '^-'; then git submodule update --init --recursive --depth 1 || exit $? fi diff --git a/wrappers/BSDmakefile b/wrappers/BSDmakefile deleted file mode 100644 index 1d8e4fd..0000000 --- a/wrappers/BSDmakefile +++ /dev/null @@ -1,6 +0,0 @@ -all: .DEFAULT - -.DEFAULT: - @gmake ${.MAKEFLAGS} ${.TARGETS} - -.PHONY: all diff --git a/wrappers/Makefile b/wrappers/Makefile deleted file mode 100644 index 138b1c7..0000000 --- a/wrappers/Makefile +++ /dev/null @@ -1,16 +0,0 @@ -PYTHON ?= $(shell command -v python3 >/dev/null && echo python3 || echo python) - -all $(MAKECMDGOALS): - @$(PYTHON) \ - -c "import sys; sys.path.insert(0, sys.argv[1]); from releng.meson_make import main; main()" \ - "$(shell pwd)" \ - ./build \ - $(MAKECMDGOALS) - -git-submodules: - @if [ ! -f releng/meson/meson.py ] || git submodule status 2>/dev/null | grep -q '^-'; then \ - git submodule update --init --recursive --depth 1; \ - fi --include git-submodules - -.PHONY: all $(MAKECMDGOALS) diff --git a/wrappers/configure b/wrappers/configure deleted file mode 100755 index 12b51a2..0000000 --- a/wrappers/configure +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh - -[ -z "$PYTHON" ] && PYTHON=$(command -v python3 >/dev/null && echo python3 || echo python) - -cd $(dirname $0) - -srcroot=$(pwd) - -if [ ! -f releng/meson/meson.py ] || git submodule status 2>/dev/null | grep -q '^-'; then - git submodule update --init --recursive --depth 1 || exit $? -fi - -cd - >/dev/null - -exec "$PYTHON" \ - -c "import sys; sys.path.insert(0, sys.argv[1]); from releng.meson_configure import main; main()" \ - "$srcroot" \ - "$@" diff --git a/wrappers/configure.bat b/wrappers/configure.bat deleted file mode 100644 index 721c958..0000000 --- a/wrappers/configure.bat +++ /dev/null @@ -1,22 +0,0 @@ -@setlocal -@echo off -rem:: Based on: https://github.com/microsoft/terminal/issues/217#issuecomment-737594785 -goto :_start_ - -:set_real_dp0 -set dp0=%~dp0 -set "dp0=%dp0:~0,-1%" -goto :eof - -:_start_ -call :set_real_dp0 - -if not exist "%dp0%\releng\meson\meson.py" ( - pushd "%dp0%" & git submodule update --init --recursive --depth 1 & popd - if %errorlevel% neq 0 exit /b %errorlevel% -) - -endlocal & goto #_undefined_# 2>nul || title %COMSPEC% & python ^ - -c "import sys; sys.path.insert(0, sys.argv[1]); from releng.meson_configure import main; main()" ^ - "%dp0%" ^ - %* diff --git a/wrappers/make.bat b/wrappers/make.bat deleted file mode 100644 index 6f9f5c0..0000000 --- a/wrappers/make.bat +++ /dev/null @@ -1,23 +0,0 @@ -@setlocal -@echo off -rem:: Based on: https://github.com/microsoft/terminal/issues/217#issuecomment-737594785 -goto :_start_ - -:set_real_dp0 -set dp0=%~dp0 -set "dp0=%dp0:~0,-1%" -goto :eof - -:_start_ -call :set_real_dp0 - -if not exist "%dp0%\releng\meson\meson.py" ( - pushd "%dp0%" & git submodule update --init --recursive --depth 1 & popd - if %errorlevel% neq 0 exit /b %errorlevel% -) - -endlocal & goto #_undefined_# 2>nul || title %COMSPEC% & python ^ - -c "import sys; sys.path.insert(0, sys.argv[1]); from releng.meson_make import main; main()" ^ - "%dp0%" ^ - .\build ^ - %*