From 6a8d7e2c5c1f35527fff876bc3ae2a976a8a22b7 Mon Sep 17 00:00:00 2001 From: stupidcomputer Date: Sat, 26 Oct 2024 12:08:22 -0500 Subject: [PATCH] make rebuilds on termux faster --- boxes/phone/out-of-tree/Makefile | 14 +++++++++++++- builds/rebuild/rebuild | 7 +++++++ 2 files changed, 20 insertions(+), 1 deletion(-) diff --git a/boxes/phone/out-of-tree/Makefile b/boxes/phone/out-of-tree/Makefile index 960d2ce..9c2923f 100644 --- a/boxes/phone/out-of-tree/Makefile +++ b/boxes/phone/out-of-tree/Makefile @@ -1,10 +1,22 @@ -termux: termux-pkgs termux-dots utils-sh st pip-pkgs git-annex.linux +termux: termux-pkgs termux-dots utils-sh rebuild-sh st pip-pkgs git-annex.linux + +list: options # alias +options: + @echo specific options + @echo st - rebuild st + @echo utils-sh - copy utilities + @echo pip-pkgs - install pip packages + @echo termux-pkgs - install termux pkgs + @echo termux-dots - install termux dotfiles + @echo git-annex.linux - install git-annex st: cd ../../../builds/st/ && CFLAGS="-DIS_PHONE" CC=clang make && cp st ~/.local/bin/st utils-sh: cp ../../../builds/utils/* ~/.local/bin +rebuild-sh: + cp ../../../builds/rebuild/* ~/.local/bin pip-pkgs: pip3 install vdirsyncer diff --git a/builds/rebuild/rebuild b/builds/rebuild/rebuild index dc96b9f..1ea01b9 100755 --- a/builds/rebuild/rebuild +++ b/builds/rebuild/rebuild @@ -1,6 +1,13 @@ #!/bin/sh cd ~/dot_testing +if [ "$(hostname)" = "localhost" ]; then + # we're on a phone + cd boxes/phone/out-of-tree + make $@ + exit +fi + if [ -f "boxes/$(hostname)/custom_command" ]; then eval "$(cat boxes/$(hostname)/custom_command)" exit