summaryrefslogtreecommitdiff
path: root/bin/Makefile.am
blob: 394bf6207ec06430e12948cc91cb1245c7133d49 (plain)
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
39
40
41
42
43
44


INCLUDES = \
	-I$(top_srcdir)/include \
	-I$(top_builddir)/include \
	$(I2400M_INCLUDES)

LDADD = ../lib/libwimaxll.la $(LIBNL1_LIBS)

bin_SCRIPTS = \
	wimax-tools-version		\
	wimaxll-reset			\
	wimaxll-rfkill			\
	wimaxll-wait-for-state-change

bin_PROGRAMS = 				\
	wimaxll

AM_CFLAGS = @GLIB_CFLAGS@ -DPLUGINDIR=\""$(plugindir)"\"
AM_LDFLAGS = @GLIB_LIBS@ ../lib/libwimaxll.la $(LIBNL1_LIBS)

wimaxll_LDFLAGS = $(AM_LDFLAGS) -ldl -Wl,--export-dynamic -Wl,--version-script=wimaxll.ver
wimaxll_DEPENDENCIES = wimaxll.ver

wimaxll.exp: $(wimaxll_OBJECTS)
	nm -B *.o | awk '{ print $$3 }' | sort -u | grep -E -e '^(w|wimaxll)_' > $@

wimaxll.ver: wimaxll.exp
	echo "{ global:" > $@
	cat $< | sed -e "s/\(.*\)/\1;/" >> $@
	echo "local: *; };" >> $@

plugindir = $(pkglibdir)/plugins
plugin_LTLIBRARIES =		\
	wimaxll-pl-reset.la	\
	wimaxll-pl-rfkill.la	\
	wimaxll-pl-wfsc.la

plugin_LDFLAGS = -no-undefined -module -avoid-version \
	-export-symbols-regex plugin

wimaxll_pl_reset_la_LDFLAGS = $(plugin_LDFLAGS)
wimaxll_pl_rfkill_la_LDFLAGS = $(plugin_LDFLAGS)
wimaxll_pl_wfsc_la_LDFLAGS = $(plugin_LDFLAGS)