Add slightly better library configuration
authorChip Black <bytex64@bytex64.net>
Sat, 8 Jan 2011 05:45:43 +0000 (23:45 -0600)
committerChip Black <bytex64@bytex64.net>
Sat, 8 Jan 2011 05:45:43 +0000 (23:45 -0600)
Makefile
libs.mk [new file with mode: 0644]

index 640be85..ed19b52 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,10 +1,12 @@
+include libs.mk
+
 CFLAGS ?= -g
-INCLUDES = -I. -Idatabase -Icommon -Iyajl/build/yajl-1.0.11/include
-HTTP_INCLUDES = -Ihttp -Ilibmicrohttpd-0.9.3/src/include
-CGI_INCLUDES = -Icgi -Icgi-util-2.2.1
+INCLUDES = -I. -Idatabase -Icommon $(YAJL_INCLUDES)
+HTTP_INCLUDES = -Ihttp $(MHD_INCLUDES)
+CGI_INCLUDES = -Icgi $(CGI_UTIL_INCLUDES)
 LDFLAGS ?=
-HTTP_LIBDIRS = -Llibmicrohttpd-0.9.3/src/daemon/.libs -Lyajl/build/yajl-1.0.11/lib
-CGI_LIBDIRS = -Lcgi-util-2.2.1 -Lyajl/build/yajl-1.0.11/lib
+HTTP_LIBDIRS = $(MHD_LIBDIR) $(YAJL_LIBDIR)
+CGI_LIBDIRS = $(CGI_UTIL_LIBDIR) $(YAJL_LIBDIR)
 
 targets = blerg.a blergtool http_blerg cgi_blerg rss
 blerg_a_objects = database/database.o database/tags.o database/util.o
diff --git a/libs.mk b/libs.mk
new file mode 100644 (file)
index 0000000..09479c5
--- /dev/null
+++ b/libs.mk
@@ -0,0 +1,12 @@
+# Configure paths to the needed libraries here.  If all your libraries
+# can be found in /usr (i.e., if they're provided by your distro), you
+# won't need to touch this.
+
+YAJL_INCLUDES =
+YAJL_LIBDIR =
+
+MHD_INCLUDES =
+MHD_LIBDIR =
+
+CGI_UTIL_INCLUDES =
+CGI_UTIL_LIBDIR =