2015-02-08 12:35:34 +01:00
|
|
|
include ../CapwapConfig.mak
|
2015-02-01 16:49:34 +01:00
|
|
|
include ../Macros.mak
|
2014-11-02 07:34:17 +01:00
|
|
|
|
2014-07-20 07:54:39 +02:00
|
|
|
ifndef CC
|
|
|
|
CC=gcc
|
|
|
|
endif
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2014-07-20 07:54:39 +02:00
|
|
|
ifndef AR
|
|
|
|
AR = ar
|
2014-07-11 22:12:11 +02:00
|
|
|
endif
|
|
|
|
|
2016-02-22 09:18:35 +01:00
|
|
|
#ifndef ARCH
|
|
|
|
# ARCH = $(shell $(CC) -dumpmachine)
|
|
|
|
#endif
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2015-02-08 12:35:34 +01:00
|
|
|
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2015-02-01 16:49:34 +01:00
|
|
|
#OPENSSLINC=$(OPENSSLINC)
|
|
|
|
#../contrib/openssl-1.0.1i/include
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2016-02-26 23:33:30 +01:00
|
|
|
NAME=libcw.a
|
|
|
|
LIBDIR=../lib/$(ARCH)
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2015-04-14 07:42:23 +02:00
|
|
|
SOCKOBJS=\
|
|
|
|
sock_create.o\
|
|
|
|
sock_copyaddr.o\
|
|
|
|
sock_strtoaddr.o\
|
|
|
|
sock_cmpaddr.o\
|
|
|
|
sock_addrlen.o \
|
|
|
|
sock_mwait.o\
|
|
|
|
sock_addrtostr.o \
|
|
|
|
sock_setport.o \
|
|
|
|
sock_getport.o \
|
|
|
|
sock_getifaddr.o \
|
|
|
|
sock_getifhwaddr.o \
|
|
|
|
sock_hwaddrtostr.o \
|
|
|
|
sock_set_recvtimeout.o \
|
|
|
|
sock_getbroadcastaddr.o \
|
|
|
|
sock_addrinit.o \
|
|
|
|
sock_set_dontfrag.o \
|
|
|
|
sock_get_primary_if.o \
|
|
|
|
sock_receive.o \
|
2016-02-22 09:18:35 +01:00
|
|
|
sock_getifinfo.o \
|
2015-04-14 07:42:23 +02:00
|
|
|
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2015-04-10 19:51:56 +02:00
|
|
|
LOGOBJS=log.o \
|
|
|
|
log_syslog.o \
|
|
|
|
log_file.o \
|
2015-04-14 07:42:23 +02:00
|
|
|
dbg_strings.o\
|
2016-02-22 09:18:35 +01:00
|
|
|
dbg.o \
|
2014-07-11 22:12:11 +02:00
|
|
|
|
|
|
|
|
2015-04-14 07:42:23 +02:00
|
|
|
WTPINFOOBJS =\
|
2015-05-01 20:34:50 +02:00
|
|
|
#wtpinfo_print.o
|
|
|
|
#wtpinfo_set_location.o \
|
|
|
|
wtpinfo_lwreadelem_wtp_descriptor.o \
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2014-08-18 01:40:35 +02:00
|
|
|
UTILOBJS= \
|
|
|
|
cw_setstr.o \
|
|
|
|
cw_is_printable.o \
|
|
|
|
cw_rand.o \
|
|
|
|
stravltree.o \
|
2015-04-06 09:22:51 +02:00
|
|
|
intavltree.o \
|
2015-03-15 14:32:42 +01:00
|
|
|
cw_util.o \
|
2016-02-27 05:35:25 +01:00
|
|
|
send.o \
|
2016-02-27 14:25:32 +01:00
|
|
|
cw_read_wtp_descriptor.o \
|
2016-02-27 10:47:37 +01:00
|
|
|
cw_read_wtp_descriptor_7.o \
|
2016-03-15 00:31:31 +01:00
|
|
|
cw_read_wtp_descriptor_versions.o \
|
2016-03-28 02:00:43 +02:00
|
|
|
cw_read_descriptor_subelems.o \
|
|
|
|
cw_out_80211_supported_rates.o
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2015-04-17 07:38:44 +02:00
|
|
|
MAVLOBJS= \
|
|
|
|
mavl_del.o \
|
|
|
|
mavl_add.o \
|
|
|
|
mavl_create.o\
|
2015-04-19 16:44:20 +02:00
|
|
|
mavl_get.o\
|
|
|
|
mavl_del_all.o\
|
|
|
|
mavliter_seek.o \
|
|
|
|
mavliter_next.o \
|
2015-04-19 23:27:44 +02:00
|
|
|
mavl_get_node.o \
|
|
|
|
mavl_foreach.o \
|
|
|
|
mavl_foreach_lr.o \
|
2015-05-01 12:42:19 +02:00
|
|
|
mavl_merge.o \
|
2015-05-02 02:02:06 +02:00
|
|
|
mavl_create_conststr.o \
|
2016-02-28 13:41:45 +01:00
|
|
|
mlist.o \
|
2015-10-18 10:43:16 +02:00
|
|
|
cw_load_file.o \
|
|
|
|
cw_save_file.o
|
2015-04-17 07:38:44 +02:00
|
|
|
|
2016-03-27 04:49:16 +02:00
|
|
|
|
|
|
|
FORMATOBJS = \
|
|
|
|
format_is_utf8.o \
|
|
|
|
format_dot11_fc.o \
|
|
|
|
|
2015-03-23 07:48:27 +01:00
|
|
|
|
|
|
|
|
|
|
|
# LWAPP objs
|
|
|
|
LWAPPOBJS = \
|
|
|
|
lw_checksum.o \
|
2015-03-23 22:26:05 +01:00
|
|
|
lw_put_ac_descriptor.o \
|
2015-03-24 20:14:26 +01:00
|
|
|
lw_put_cisco_path_mtu.o \
|
2015-03-28 18:31:33 +01:00
|
|
|
lw_readelem_vendor_specific.o \
|
|
|
|
lw_elem_id_to_str.o \
|
|
|
|
lw_msg_id_to_str.o \
|
2015-04-05 02:07:59 +02:00
|
|
|
lw_cisco_id_to_str.o \
|
|
|
|
lw_put_sockaddr.o \
|
2016-03-27 16:48:39 +02:00
|
|
|
lw_put_image_data.o \
|
|
|
|
lw_in_vendor_specific.o
|
|
|
|
|
2015-03-28 18:31:33 +01:00
|
|
|
|
2015-05-01 20:34:50 +02:00
|
|
|
#lw_put_80211_wtp_wlan_radio_configuration.o \
|
2015-04-11 19:00:51 +02:00
|
|
|
# lw_readelem_wtp_name.o \
|
|
|
|
lw_readelem_wtp_board_data.o \
|
2015-04-12 19:19:29 +02:00
|
|
|
cw_log_debug.o \
|
2015-04-30 18:49:12 +02:00
|
|
|
lw_vendor_id_to_str.o \
|
2015-03-23 07:48:27 +01:00
|
|
|
|
2015-03-24 20:14:26 +01:00
|
|
|
|
2015-03-23 07:48:27 +01:00
|
|
|
# LWAPP cisco vendor specific objs
|
|
|
|
LWAPPCISCOOBJS = \
|
|
|
|
lw_addelem.o
|
|
|
|
|
|
|
|
|
2014-08-16 15:12:35 +02:00
|
|
|
# cw_tohex.o\
|
2014-07-11 22:12:11 +02:00
|
|
|
#capwap_parse_ctrlhdr.o \
|
|
|
|
|
2016-03-11 22:23:00 +01:00
|
|
|
# hdr_print.o \
|
2015-03-23 07:48:27 +01:00
|
|
|
|
2014-07-11 22:12:11 +02:00
|
|
|
CAPWAPOBJS= \
|
|
|
|
aciplist.o \
|
2014-07-26 20:27:57 +02:00
|
|
|
lwmsg_init.o \
|
2015-03-28 18:31:33 +01:00
|
|
|
cw_cisco_id_to_str.o\
|
2015-03-31 08:04:03 +02:00
|
|
|
cw_strlist_get_str.o \
|
2015-04-11 19:00:51 +02:00
|
|
|
cw_strlist_get_id.o \
|
2015-03-31 14:10:55 +02:00
|
|
|
capwap_strings_msg.o \
|
2015-04-10 17:14:55 +02:00
|
|
|
capwap_strings_elem80211.o\
|
|
|
|
acpriolist.o\
|
2015-03-31 14:10:55 +02:00
|
|
|
capwap_strings_state.o \
|
2015-03-31 18:37:07 +02:00
|
|
|
capwap_strings_vendor.o \
|
2015-04-05 02:07:59 +02:00
|
|
|
capwap_strings_elem.o \
|
2015-03-31 12:47:39 +02:00
|
|
|
cw_in_vendor_specific_payload.o \
|
2016-03-10 07:48:59 +01:00
|
|
|
cw_in_mtu_discovery_padding.o\
|
2015-04-05 02:07:59 +02:00
|
|
|
cw_in_wtp_board_data.o \
|
2015-04-06 09:22:51 +02:00
|
|
|
cw_in_check_disc_req.o \
|
2015-04-26 23:52:11 +02:00
|
|
|
cw_in_check_chng_state_evnt_req.o\
|
2015-04-10 17:14:55 +02:00
|
|
|
cw_in_check_disc_resp.o\
|
2015-04-28 10:21:12 +02:00
|
|
|
cw_in_check_cfg_update_req.o\
|
2015-04-06 09:22:51 +02:00
|
|
|
cw_in_check_join_req.o \
|
2015-04-13 11:00:46 +02:00
|
|
|
cw_in_check_cipwap_join_req.o \
|
2015-04-10 17:14:55 +02:00
|
|
|
cw_in_check_join_resp.o \
|
2015-04-11 19:00:51 +02:00
|
|
|
cw_in_check_img_data_req_ac.o \
|
|
|
|
cw_in_check_img_data_req_wtp.o \
|
|
|
|
cw_in_check_img_data_resp.o \
|
2016-03-05 14:12:49 +01:00
|
|
|
cw_in_check_generic_resp.o \
|
2016-03-07 19:09:54 +01:00
|
|
|
cw_in_check_generic_req.o \
|
2015-04-05 02:07:59 +02:00
|
|
|
cw_out_generic.o \
|
2015-04-11 19:00:51 +02:00
|
|
|
cw_out_wtp_descriptor.o \
|
2016-03-11 22:23:00 +01:00
|
|
|
cw_out_wtp_reboot_statistics.o \
|
2016-03-11 23:45:35 +01:00
|
|
|
cw_in_wtp_reboot_statistics.o\
|
2015-04-07 07:42:36 +02:00
|
|
|
cw_in_cisco_image_identifier.o\
|
2016-03-19 12:57:47 +01:00
|
|
|
cw_out_radio_operational_states.o\
|
|
|
|
cw_out_radio_operational_states_7.o\
|
|
|
|
cw_put_radio_operational_states.o \
|
2016-03-21 20:10:47 +01:00
|
|
|
cw_put_ac_status.o \
|
2015-04-26 23:52:11 +02:00
|
|
|
cw_in_ac_descriptor.o\
|
2016-03-15 00:31:31 +01:00
|
|
|
cw_read_ac_descriptor.o\
|
2015-04-26 16:50:53 +02:00
|
|
|
cw_out_capwap_local_ip_address.o\
|
2016-03-13 01:54:51 +01:00
|
|
|
cw_out_wtp_ip_address.o\
|
2015-04-10 17:14:55 +02:00
|
|
|
cw_out_capwap_control_ip_addr_list.o \
|
2016-03-06 13:34:34 +01:00
|
|
|
cw_in_capwap_control_ip_address.o\
|
2016-03-06 19:14:02 +01:00
|
|
|
cw_in_capwap_local_ipv4_address.o \
|
|
|
|
cw_in_capwap_local_ipv6_address.o \
|
2015-04-24 07:13:54 +02:00
|
|
|
cw_in_radio_administrative_state.o \
|
2015-04-28 10:21:12 +02:00
|
|
|
cw_in_radio_administrative_state_wtp.o \
|
2016-03-09 20:15:36 +01:00
|
|
|
cw_in_radio_operational_state.o\
|
2016-04-02 09:01:46 +02:00
|
|
|
cw_radio_set_admin_state.o \
|
|
|
|
cw_put_elem_radio_administrative_state.o\
|
|
|
|
cw_put_elem_radio_operational_state.o \
|
|
|
|
cw_out_radio_administrative_states.o\
|
2015-04-06 09:22:51 +02:00
|
|
|
strheap.o \
|
|
|
|
cw_check_missing_mand.o \
|
2015-04-07 07:42:36 +02:00
|
|
|
md5sum.o \
|
2015-04-10 17:14:55 +02:00
|
|
|
format.o \
|
2016-03-26 09:42:12 +01:00
|
|
|
cw_in_cisco_add_wlan.o
|
|
|
|
|
|
|
|
DOT11OBJS = \
|
|
|
|
dot11.o \
|
|
|
|
dot11_beacon.o
|
2015-04-19 23:27:44 +02:00
|
|
|
|
2016-03-05 10:11:39 +01:00
|
|
|
# cw_out_ac_descriptor.o \
|
2015-04-19 23:27:44 +02:00
|
|
|
|
|
|
|
|
2016-03-28 16:43:09 +02:00
|
|
|
CAPWAP80211OBJS=\
|
|
|
|
capwap80211_items.o\
|
|
|
|
capwap80211_type_rateset.o \
|
|
|
|
|
2015-04-19 23:27:44 +02:00
|
|
|
|
2015-02-08 12:35:34 +01:00
|
|
|
#
|
|
|
|
# SSL objects
|
|
|
|
#
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2015-02-08 12:35:34 +01:00
|
|
|
ifeq ($(WITH_OPENSSL),1)
|
|
|
|
CFLAGS+=$(OPENSSL_CFLAGS)
|
|
|
|
CFLAGS+=-DWITH_OPENSSL
|
|
|
|
DTLSOBJS += dtls_openssl.o \
|
2015-02-07 02:59:49 +01:00
|
|
|
dtls_openssl_accept.o \
|
|
|
|
dtls_openssl_connect.o \
|
|
|
|
dtls_openssl_get_cipher.o \
|
2015-02-08 12:35:34 +01:00
|
|
|
dtls_openssl_bio.o
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifeq ($(WITH_GNUTLS),1)
|
|
|
|
CFLAGS+=$(GNUTLS_CFLAGS)
|
|
|
|
CFLAGS+=-DWITH_GNUTLS
|
|
|
|
DTLSOBJS+= dtls_gnutls.o \
|
2015-02-07 02:59:49 +01:00
|
|
|
dtls_gnutls_accept.o \
|
2015-02-08 21:07:55 +01:00
|
|
|
dtls_gnutls_connect.o \
|
2015-02-08 16:28:04 +01:00
|
|
|
dtls_gnutls_bio.o \
|
2015-02-09 22:04:54 +01:00
|
|
|
dtls_gnutls_get_cipher.o \
|
|
|
|
dtls_gnutls_get_peers_cert.o
|
2015-02-08 12:35:34 +01:00
|
|
|
endif
|
|
|
|
|
2015-02-08 16:28:04 +01:00
|
|
|
DTLSOBJS+=dtls_bio.o
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2015-03-20 22:31:09 +01:00
|
|
|
CONNOBJS= conn_create.o \
|
2014-07-11 22:12:11 +02:00
|
|
|
conn_process_packet.o \
|
|
|
|
conn_q_add_packet.o \
|
|
|
|
conn_q_get_packet.o \
|
|
|
|
conn_q_recv_packet.o \
|
|
|
|
conn_recv_packet.o \
|
2014-07-20 12:50:01 +02:00
|
|
|
conn_destroy.o \
|
2014-07-20 16:00:27 +02:00
|
|
|
connlist.o \
|
2014-07-25 00:27:17 +02:00
|
|
|
conn_create_noq.o \
|
2015-04-05 02:07:59 +02:00
|
|
|
conn_init.o \
|
2015-04-14 07:42:23 +02:00
|
|
|
conn_send_packet.o \
|
2016-03-27 04:49:16 +02:00
|
|
|
conn_send_data_packet.o
|
2015-04-14 07:42:23 +02:00
|
|
|
|
|
|
|
# conn_send_msg.o
|
2015-04-07 07:42:36 +02:00
|
|
|
#conn_get_message.o \
|
2015-04-14 07:42:23 +02:00
|
|
|
# conn_send_response.o \
|
|
|
|
# cw_prepare_configuration_status_request.o \
|
|
|
|
# cw_prepare_change_state_event_request.o \
|
|
|
|
conn_prepare_configuration_update_request.o \
|
2015-03-16 21:41:33 +01:00
|
|
|
|
|
|
|
|
2016-03-12 16:12:36 +01:00
|
|
|
#bstr_to_str.o \
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2015-01-31 12:21:20 +01:00
|
|
|
BSTROBJS= bstr_create.o \
|
|
|
|
bstr_create_from_cfgstr.o \
|
2016-03-04 22:47:49 +01:00
|
|
|
bstr16_create_from_cfgstr.o \
|
2015-03-14 21:41:50 +01:00
|
|
|
bstr_replace.o \
|
2015-05-04 07:45:17 +02:00
|
|
|
bstr16cfgstr.o \
|
|
|
|
bstr16_create_from_str.o \
|
|
|
|
bstr_create_from_str.o \
|
2016-03-13 09:34:54 +01:00
|
|
|
bstrv_create_from_str.o
|
2015-05-04 07:45:17 +02:00
|
|
|
|
2014-07-11 22:12:11 +02:00
|
|
|
|
|
|
|
|
|
|
|
FRAGOBJS=fragman.o
|
|
|
|
|
2016-03-04 21:01:38 +01:00
|
|
|
# cw_in_wtp_descriptor.o \
|
2016-03-08 19:58:04 +01:00
|
|
|
# capwap_80211_actions_wtp.o \
|
|
|
|
# capwap_80211_actions_ac.o \
|
2016-03-11 22:23:00 +01:00
|
|
|
# capwap_actions_ac.o \
|
|
|
|
#capwap_actions_wtp.o \
|
2016-03-04 21:01:38 +01:00
|
|
|
|
2016-04-02 09:01:46 +02:00
|
|
|
#cipwap_actions_ac.o \
|
|
|
|
#cipwap_actions_wtp.o \
|
|
|
|
|
2015-04-05 02:07:59 +02:00
|
|
|
CWACTION=action.o \
|
|
|
|
cw_in_generic.o \
|
2016-02-23 20:03:25 +01:00
|
|
|
cw_in_generic2.o \
|
2015-04-07 07:42:36 +02:00
|
|
|
cw_out_wtp_board_data.o \
|
2015-04-26 08:41:12 +02:00
|
|
|
cw_out_ac_name_with_priority.o \
|
|
|
|
cw_in_ac_name_with_priority.o \
|
2015-04-11 19:00:51 +02:00
|
|
|
cw_out_image_data.o \
|
2015-04-05 20:27:17 +02:00
|
|
|
cipwap_strings_elem.o \
|
2015-04-10 17:14:55 +02:00
|
|
|
capwap_strings_result.o\
|
2016-03-13 18:48:45 +01:00
|
|
|
capwap_strings_board.o \
|
2016-04-02 09:01:46 +02:00
|
|
|
cipwap_items.o\
|
2015-04-05 20:27:17 +02:00
|
|
|
cw_put_msg.o \
|
2016-03-13 18:48:45 +01:00
|
|
|
cw_put_mbag_item.o \
|
2016-03-13 01:54:51 +01:00
|
|
|
cw_put_local_ip_address.o \
|
2015-04-05 20:27:17 +02:00
|
|
|
capwap_action_helpers.o \
|
2015-04-19 16:44:20 +02:00
|
|
|
cw_put_image_data.o \
|
|
|
|
cisco.o \
|
2016-03-28 02:00:43 +02:00
|
|
|
radio.o \
|
2016-03-28 16:43:09 +02:00
|
|
|
cw_in_radio_generic.o\
|
2016-03-28 02:00:43 +02:00
|
|
|
cw_out_radio_info.o \
|
|
|
|
capwap_items.o \
|
|
|
|
item.o \
|
|
|
|
mod.o
|
|
|
|
|
|
|
|
# cw_process_msg.o \
|
|
|
|
# item_strings.o \
|
|
|
|
#
|
|
|
|
|
|
|
|
MBAGOBJS = \
|
2015-04-19 16:44:20 +02:00
|
|
|
mbag.o\
|
2015-05-01 20:34:50 +02:00
|
|
|
mbag_type_word.o\
|
2015-05-04 07:45:17 +02:00
|
|
|
mbag_type_byte.o\
|
2015-05-02 10:45:16 +02:00
|
|
|
mbag_type_vendorstr.o\
|
|
|
|
mbag_type_sockaddr.o\
|
2015-05-04 07:45:17 +02:00
|
|
|
mbag_type_dword.o\
|
|
|
|
mbag_type_bstr16.o\
|
|
|
|
mbag_type_mbag.o\
|
2016-03-19 12:32:02 +01:00
|
|
|
mbag_set_from_buf.o\
|
2016-03-28 02:00:43 +02:00
|
|
|
mbag_type_str.o \
|
|
|
|
mbag_type_ptr.o \
|
|
|
|
mbag_type_data.o
|
2015-04-05 02:07:59 +02:00
|
|
|
|
2015-04-10 17:14:55 +02:00
|
|
|
|
2015-03-30 07:56:42 +02:00
|
|
|
|
|
|
|
|
2015-03-23 07:48:27 +01:00
|
|
|
OBJS=$(CONNOBJS) $(FRAGOBJS) $(SOCKOBJS) $(CAPWAPOBJS) $(WTPINFOOBJS) \
|
|
|
|
$(LOGOBJS) $(UTILOBJS) $(DTLSOBJS) $(BSTROBJS) \
|
|
|
|
$(LWAPPOBJS) \
|
2015-03-30 07:56:42 +02:00
|
|
|
$(LWAPPCISCOOBJS) \
|
2015-04-17 07:38:44 +02:00
|
|
|
$(CWACTION) \
|
2016-02-22 09:18:35 +01:00
|
|
|
$(MAVLOBJS) \
|
2016-03-27 04:49:16 +02:00
|
|
|
$(FORMATOBJS) \
|
2016-03-28 02:00:43 +02:00
|
|
|
$(DOT11OBJS) \
|
2016-03-28 16:43:09 +02:00
|
|
|
$(MBAGOBJS) \
|
|
|
|
$(CAPWAP80211OBJS)
|
2015-03-23 07:48:27 +01:00
|
|
|
|
2015-03-28 12:51:34 +01:00
|
|
|
#include $(OBJS:.o=.d)
|
|
|
|
|
2014-07-11 22:12:11 +02:00
|
|
|
O:=$(OBJS);
|
|
|
|
|
|
|
|
OBJS:=$(patsubst %.o,$(ARCH)/%.o,$(OBJS))
|
|
|
|
|
2016-02-22 09:18:35 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2016-02-26 23:33:30 +01:00
|
|
|
CFLAGS = -Wall -g -O0 -D_REENTRANT -DWITH_IPV6 -DWITH_RMAC_SUPPORT -I /usr/local/include -I../
|
2015-04-26 08:41:12 +02:00
|
|
|
#CFLAGS = -Wall -Os -D_REENTRANT -DWITH_IPV6 -DWITH_RMAC_SUPPORT -I/usr/local/include
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2015-02-08 11:42:01 +01:00
|
|
|
CFLAGS += $(GNUTLS_CFLAGS) \
|
|
|
|
-DWITH_CW_LOG \
|
2014-07-11 22:12:11 +02:00
|
|
|
-DWITH_CW_LOG_DEBUG \
|
|
|
|
-DWITH_DTLS \
|
2014-08-16 09:10:38 +02:00
|
|
|
$(XINCLUDE)\
|
2015-02-01 16:49:34 +01:00
|
|
|
-I $(OPENSSLINC)\
|
|
|
|
-Werror
|
|
|
|
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2016-02-22 09:18:35 +01:00
|
|
|
|
|
|
|
|
2014-07-11 22:12:11 +02:00
|
|
|
#SRCS = $(OBJS:.o=.c)
|
2016-02-26 23:33:30 +01:00
|
|
|
#MODOBJS=$(wildcard ./mod/cipwap/$(ARCH)/*.o)
|
|
|
|
#MODOBJS+=$(wildcard ./mod/capwap/$(ARCH)/*.o)
|
2014-07-11 22:12:11 +02:00
|
|
|
|
|
|
|
$(ARCH)/%.o:%.c
|
|
|
|
@mkdir -p $(ARCH)
|
|
|
|
@echo " CC "$<
|
|
|
|
@$(CC) -c $(CFLAGS) $< -o $@
|
2015-04-05 02:07:59 +02:00
|
|
|
# @$(CC) -MM $(CFLAGS) $< > $*.d
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2016-02-26 23:33:30 +01:00
|
|
|
$(LIBDIR)/$(NAME) : $(OBJS) $(MODOBJS)
|
|
|
|
@mkdir -p $(LIBDIR)
|
|
|
|
@echo " AR $(LIBDIR)/$(NAME)"
|
|
|
|
@$(AR) rcs $(LIBDIR)/$(NAME) $(OBJS) $(MODOBJS)
|
2014-07-11 22:12:11 +02:00
|
|
|
|
|
|
|
|
|
|
|
SRCS = $(OBJS:.o=.c)
|
|
|
|
DEPS := $(OBJS:.o=.d)
|
|
|
|
|
|
|
|
|
|
|
|
.PHONY: deps clean clean_libs libs
|
|
|
|
|
2016-02-22 18:33:47 +01:00
|
|
|
|
2014-07-11 22:12:11 +02:00
|
|
|
# top-level rule, to compile everything.
|
2016-02-26 23:33:30 +01:00
|
|
|
all: $(ARCH)/$(NAME)
|
2016-02-22 18:33:47 +01:00
|
|
|
|
2016-02-22 09:18:35 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
2014-07-11 22:12:11 +02:00
|
|
|
|
|
|
|
clean:
|
2015-04-06 09:22:51 +02:00
|
|
|
$(RM) $(ARCH)/*
|
2016-03-04 22:10:21 +01:00
|
|
|
$(RM) $(LIBDIR)/$(NAME)
|
2015-04-06 09:22:51 +02:00
|
|
|
# $(RM) $(OBJS)
|
|
|
|
# $(RM) $(DEPS)
|
|
|
|
# $(RM) $(ARCH)/$(NAME)
|
2014-07-11 22:12:11 +02:00
|
|
|
|
|
|
|
|
|
|
|
clean_deps:
|
|
|
|
$(DEPS)
|
|
|
|
|
2016-03-26 09:42:12 +01:00
|
|
|
deps:
|
|
|
|
$(CC) -MM -E *.c $(CFLAGS) > .depend
|
2014-07-11 22:12:11 +02:00
|
|
|
|
2016-03-28 10:54:27 +02:00
|
|
|
-include .depend
|