List for cgit developers and users
 help / color / mirror / Atom feed
* [PATCH] cgit.mk: do not rely on pkg-config
@ 2014-01-17 23:51 Jason
  0 siblings, 0 replies; only message in thread
From: Jason @ 2014-01-17 23:51 UTC (permalink / raw)


If pkg-config is not installed, but Lua vanilla is forced, then we might
be able to get away with just padding "-llua". Unlike LuaJIT, headers
are normally installed to /usr/include, and the libs are usually
installed to /usr/lib and the headers to /usr/include, so we let the
compiler eventually have success or error out.

Signed-off-by: Jason A. Donenfeld <Jason at zx2c4.com>
---
What do you guys think of doing this? Some people don't have
pkg-config... or something? Not sure if this is the best approach but...

 cgit.mk | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/cgit.mk b/cgit.mk
index 056c3f9..78627aa 100644
--- a/cgit.mk
+++ b/cgit.mk
@@ -42,7 +42,8 @@ ifeq (JIT,$(LUA_IMPLEMENTATION))
 	CGIT_CFLAGS += $(LUAJIT_CFLAGS)
 else ifeq (VANILLA,$(LUA_IMPLEMENTATION))
 	ifeq ($(strip $(LUA_LIBS)),)
- 		$(error Lua specified via LUA_IMPLEMENTATION=VANILLA, but library could not be found.)
+ 		$(warning Lua specified via LUA_IMPLEMENTATION=VANILLA, but pkg-config failed to find it. Forcing -llua.)
+		LUA_LIBS := -llua
 	endif
 	LUA_MESSAGE := linking with selected Lua
 	CGIT_LIBS += $(LUA_LIBS)
-- 
1.8.5.2



^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2014-01-17 23:51 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-01-17 23:51 [PATCH] cgit.mk: do not rely on pkg-config Jason

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).