FS-5412 --resolve use getlib to build radius client and stop statically defining path to freeradius-client.so

Thanks Sven Neuhaus <neuhaus@tyntec.com>
This commit is contained in:
Ken Rice 2014-02-24 16:56:48 -06:00
parent 6e97a9f55b
commit 5047ba5b95
1 changed files with 23 additions and 4 deletions

View File

@ -1,7 +1,26 @@
switch_srcdir=../../../..
RADCLIENT_VERSION=1.1.6
RADCLIENT=freeradius-client-$(RADCLIENT_VERSION)
RADCLIENT_DIR=$(switch_srcdir)/libs/$(RADCLIENT)
RADCLIENT_BUILDDIR=$(switch_builddir)/libs/$(RADCLIENT)
RADCLIENT_LIBDIR=$(RADCLIENT_BUILDDIR)/lib
RADCLIENT_LA=${RADCLIENT_LIBDIR}/libfreeradius-client.la
FREERADIUSLA=/usr/local/lib/libfreeradius-client.so
LOCAL_LIBADD=$(FREERADIUSLA)
LOCAL_CFLAGS=-I$(RADCLIENT_DIR)/include
LOCAL_LIBADD=$(RADCLIENT_LA)
BASE=../../../..
include $(BASE)/build/modmake.rules
$(RADCLIENT_DIR):
$(GETLIB) $(RADCLIENT).tar.gz
$(RADCLIENT_BUILDDIR)/Makefile: $(RADCLIENT_DIR)
mkdir -p $(RADCLIENT_BUILDDIR)
cd $(RADCLIENT_BUILDDIR) && $(DEFAULT_VARS) $(RADCLIENT_DIR)/configure $(DEFAULT_ARGS) --srcdir=$(RADCLIENT_DIR)
$(TOUCH_TARGET)
$(RADCLIENT_LA): $(RADCLIENT_BUILDDIR)/Makefile
cd $(RADCLIENT_BUILDDIR) && CFLAGS="$(CFLAGS)" $(MAKE)
$(TOUCH_TARGET)
include $(switch_srcdir)/build/modmake.rules