Package: luakit / 1:2.1-1

cross.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
--- luakit-2017.08.10.orig/config.mk
+++ luakit-2017.08.10/config.mk
@@ -5,6 +5,7 @@
 CFLAGS     += -std=gnu99 -ggdb -W -Wall -Wextra -Werror=unused-result
 LDFLAGS    +=
 CPPFLAGS   +=
+PKG_CONFIG ?= pkg-config
 
 # Get current luakit version.
 VERSION    ?= $(shell ./build-utils/getversion.sh)
@@ -64,7 +65,7 @@
 # Search for Lua package name if not forced by user.
 ifeq ($(LUA_PKG_NAME),)
 LUA_PKG_NAME = $(shell sh -c '(for name in $(LUA_PKG_NAMES); do \
-	       pkg-config --exists $$name && echo $$name; done) | head -n 1')
+	       $(PKG_CONFIG) --exists $$name && echo $$name; done) | head -n 1')
 endif
 
 # === Lua binary name detection =============================================
@@ -102,15 +103,15 @@
 endif
 
 # Check user has correct packages installed (and found by pkg-config).
-PKGS_OK := $(shell pkg-config --print-errors --exists $(PKGS) && echo 1)
+PKGS_OK := $(shell $(PKG_CONFIG) --print-errors --exists $(PKGS) && echo 1)
 ifneq ($(PKGS_OK),1)
     $(error Cannot find required package(s\) to build luakit. Please \
     check you have the above packages installed and try again)
 endif
 
 # Add pkg-config options to compile flags.
-CFLAGS  += $(shell pkg-config --cflags $(PKGS))
+CFLAGS  += $(shell $(PKG_CONFIG) --cflags $(PKGS))
 CFLAGS  += -I./
 
 # Add pkg-config options to linker flags.
-LDFLAGS += $(shell pkg-config --libs $(PKGS))
+LDFLAGS += $(shell $(PKG_CONFIG) --libs $(PKGS))