hawk/hawk/mod/Makefile.am

92 lines
2.3 KiB
Makefile
Raw Normal View History

2019-12-13 04:29:58 +00:00
AUTOMAKE_OPTIONS = nostdinc
CPPFLAGS_COMMON = \
2020-01-04 05:21:00 +00:00
-I$(abs_builddir) \
-I$(abs_builddir)/../lib \
-I$(abs_srcdir) \
-I$(abs_srcdir)/../lib \
2019-12-13 04:29:58 +00:00
-I$(includedir)
2020-11-15 04:50:40 +00:00
CFLAGS_COMMON =
2019-12-13 04:29:58 +00:00
##################################################
if ENABLE_STATIC_MODULE
##################################################
#-------------------------------------------------
# STATIC MODULES BUILT INTO MAIN LIBRARY
#-------------------------------------------------
2020-12-04 09:40:24 +00:00
LDFLAGS_COMMON =-L$(libdir)
2019-12-13 04:29:58 +00:00
LIBADD_COMMON =
noinst_LTLIBRARIES =
2020-12-17 10:12:57 +00:00
if ENABLE_MOD_FFI
noinst_LTLIBRARIES += libhawk-ffi.la
endif
2019-12-13 04:29:58 +00:00
if ENABLE_MOD_MYSQL
noinst_LTLIBRARIES += libhawk-mysql.la
endif
if ENABLE_MOD_UCI
noinst_LTLIBRARIES += libhawk-uci.la
endif
##################################################
else
##################################################
#-------------------------------------------------
# DYNAMIC MODULES
#-------------------------------------------------
LDFLAGS_COMMON = -L../lib -L$(libdir) -version-info 1:0:0 ## -no-undefined
2019-12-13 04:29:58 +00:00
LIBADD_COMMON = -lhawk
pkgmodexecdir = $(libdir)
pkgmodexec_LTLIBRARIES =
2020-12-17 10:12:57 +00:00
if ENABLE_MOD_FFI
pkgmodexec_LTLIBRARIES += libhawk-ffi.la
endif
2019-12-13 04:29:58 +00:00
if ENABLE_MOD_MYSQL
pkgmodexec_LTLIBRARIES += libhawk-mysql.la
endif
if ENABLE_MOD_UCI
pkgmodexec_LTLIBRARIES += libhawk-uci.la
endif
##################################################
endif
##################################################
#-------------------------------------------------
# ACTUAL MODULES
#-------------------------------------------------
2020-12-17 10:12:57 +00:00
if ENABLE_MOD_FFI
libhawk_ffi_la_SOURCES = mod-ffi.c mod-ffi.h
2020-12-20 17:50:30 +00:00
libhawk_ffi_la_CPPFLAGS = $(CPPFLAGS_COMMON)
2020-12-17 10:12:57 +00:00
libhawk_ffi_la_CFLAGS = $(CFLAGS_COMMON)
2020-12-20 17:50:30 +00:00
libhawk_ffi_la_LDFLAGS = $(LDFLAGS_COMMON)
2020-12-27 19:28:49 +00:00
libhawk_ffi_la_LIBADD = $(LIBADD_COMMON) $(FFI_LIBS)
2020-12-17 10:12:57 +00:00
endif
2019-12-13 04:29:58 +00:00
if ENABLE_MOD_MYSQL
libhawk_mysql_la_SOURCES = mod-mysql.c mod-mysql.h
libhawk_mysql_la_CPPFLAGS = $(CPPFLAGS_COMMON) $(MYSQL_CFLAGS)
2020-11-15 04:50:40 +00:00
libhawk_mysql_la_CFLAGS = $(CFLAGS_COMMON)
2019-12-13 04:29:58 +00:00
libhawk_mysql_la_LDFLAGS = $(LDFLAGS_COMMON) $(MYSQL_LDFLAGS)
2020-08-15 15:07:10 +00:00
libhawk_mysql_la_LIBADD = $(LIBADD_COMMON) $(MYSQL_LIBS)
2019-12-13 04:29:58 +00:00
endif
if ENABLE_MOD_UCI
libhawk_uci_la_SOURCES = mod-uci.c mod-uci.h
libhawk_uci_la_CPPFLAGS = $(CPPFLAGS_COMMON)
2020-11-15 04:50:40 +00:00
libhawk_uci_la_CFLAGS = $(CFLAGS_COMMON)
2019-12-13 04:29:58 +00:00
libhawk_uci_la_LDFLAGS = $(LDFLAGS_COMMON)
libhawk_uci_la_LIBADD = $(LIBADD_COMMON) $(UCI_LIBS)
endif