1all: hs20-osu-client 2 3ifndef CC 4CC=gcc 5endif 6 7ifndef LDO 8LDO=$(CC) 9endif 10 11Q=@ 12E=echo 13ifeq ($(V), 1) 14Q= 15E=true 16endif 17 18ifndef CFLAGS 19CFLAGS = -MMD -O2 -Wall -g 20endif 21 22CFLAGS += -I../../src/utils 23CFLAGS += -I../../src/common 24CFLAGS += -I../../src 25 26ifndef CONFIG_NO_BROWSER 27ifndef CONFIG_BROWSER_SYSTEM 28GTKCFLAGS := $(shell pkg-config --cflags gtk+-3.0 webkitgtk-3.0) 29GTKLIBS := $(shell pkg-config --libs gtk+-3.0 webkitgtk-3.0) 30CFLAGS += $(GTKCFLAGS) 31LIBS += $(GTKLIBS) 32endif 33endif 34 35OBJS=spp_client.o 36OBJS += oma_dm_client.o 37OBJS += osu_client.o 38OBJS += est.o 39OBJS += ../../src/utils/xml-utils.o 40CFLAGS += -DCONFIG_CTRL_IFACE 41CFLAGS += -DCONFIG_CTRL_IFACE_UNIX 42OBJS += ../../src/common/wpa_ctrl.o ../../src/common/wpa_helpers.o 43ifdef CONFIG_NO_BROWSER 44CFLAGS += -DCONFIG_NO_BROWSER 45else 46ifdef CONFIG_BROWSER_SYSTEM 47OBJS += ../../src/utils/eloop.o 48OBJS += ../../src/utils/wpabuf.o 49OBJS += ../../src/wps/httpread.o 50OBJS += ../../src/wps/http_server.o 51OBJS += ../../src/utils/browser-system.o 52else 53OBJS += ../../src/utils/browser.o 54endif 55endif 56OBJS += ../../src/utils/xml_libxml2.o 57OBJS += ../../src/utils/http_curl.o 58OBJS += ../../src/utils/base64.o 59OBJS += ../../src/utils/os_unix.o 60CFLAGS += -DCONFIG_DEBUG_FILE 61OBJS += ../../src/utils/wpa_debug.o 62OBJS += ../../src/utils/common.o 63OBJS += ../../src/crypto/crypto_internal.o 64OBJS += ../../src/crypto/md5-internal.o 65OBJS += ../../src/crypto/sha1-internal.o 66OBJS += ../../src/crypto/sha256-internal.o 67 68CFLAGS += $(shell xml2-config --cflags) 69LIBS += $(shell xml2-config --libs) 70LIBS += -lcurl 71 72CFLAGS += -DEAP_TLS_OPENSSL 73LIBS += -lssl -lcrypto 74 75hs20-osu-client: $(OBJS) 76 $(Q)$(LDO) $(LDFLAGS) -o hs20-osu-client $(OBJS) $(LIBS) 77 @$(E) " LD " $@ 78 79%.o: %.c 80 $(Q)$(CC) -c -o $@ $(CFLAGS) $< 81 @$(E) " CC " $< 82 83clean: 84 rm -f core *~ *.o *.d hs20-osu-client 85 rm -f ../../src/utils/*.o 86 rm -f ../../src/utils/*.d 87 rm -f ../../src/common/*.o 88 rm -f ../../src/common/*.d 89 rm -f ../../src/crypto/*.o 90 rm -f ../../src/crypto/*.d 91 rm -f ../../src/wps/*.o 92 rm -f ../../src/wps/*.d 93 94-include $(OBJS:%.o=%.d) 95