diff options
author | Sandro Jäckel <sandro.jaeckel@gmail.com> | 2023-11-01 16:49:20 +0100 |
---|---|---|
committer | Christian Marangi <ansuelsmth@gmail.com> | 2023-11-02 20:26:32 +0100 |
commit | 86ca7199dfb132042ce3110acef23d74f4ef14a7 (patch) | |
tree | 706686a0482ffa2afa3feeb8c317f795a46f193d /Makefile | |
parent | 5cdf152b28da70d12cd4eba08e1c75dd7afcced2 (diff) | |
download | openwrt-86ca7199dfb132042ce3110acef23d74f4ef14a7.tar.gz openwrt-86ca7199dfb132042ce3110acef23d74f4ef14a7.tar.bz2 openwrt-86ca7199dfb132042ce3110acef23d74f4ef14a7.zip |
build: fix pkg-config detection when inside of a nix-shell
The output of command_all when inside a nix-shell looks like the below
where /usr does not match:
➜ scripts/command_all.sh pkg-config
/nix/store/ifr6srqgpvygd5vp14748d109ri31isv-pkg-config-wrapper-0.29.2/bin/pkg-config
Signed-off-by: Sandro Jäckel <sandro.jaeckel@gmail.com>
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -14,7 +14,7 @@ $(if $(findstring $(space),$(TOPDIR)),$(error ERROR: The path to the OpenWrt dir world: -DISTRO_PKG_CONFIG:=$(shell $(TOPDIR)/scripts/command_all.sh pkg-config | grep '/usr' -m 1) +DISTRO_PKG_CONFIG:=$(shell $(TOPDIR)/scripts/command_all.sh pkg-config | grep -e '/usr' -e '/nix/store' -m 1) export ORIG_PATH:=$(if $(ORIG_PATH),$(ORIG_PATH),$(PATH)) export PATH:=$(if $(STAGING_DIR),$(abspath $(STAGING_DIR)/../host/bin),$(TOPDIR)/staging_dir/host/bin):$(PATH) |