2018-02-01 01:08:37 +01:00
|
|
|
DEVTOOLS_SRC := devtools/gen_print_wire.c devtools/print_wire.c
|
|
|
|
DEVTOOLS_OBJS := $(DEVTOOLS_SRC:.c=.o)
|
2018-06-06 22:40:30 +02:00
|
|
|
DEVTOOLS_TOOL_SRC := devtools/bolt11-cli.c devtools/decodemsg.c devtools/onion.c
|
2018-02-01 01:08:37 +01:00
|
|
|
DEVTOOLS_TOOL_OBJS := $(DEVTOOLS_TOOL_SRC:.c=.o)
|
2017-11-22 01:26:08 +01:00
|
|
|
|
2018-02-01 01:08:37 +01:00
|
|
|
DEVTOOLS_COMMON_OBJS := \
|
2018-06-28 03:34:47 +02:00
|
|
|
common/base32.o \
|
2017-11-22 01:26:08 +01:00
|
|
|
common/bech32.o \
|
2018-04-23 16:20:55 +02:00
|
|
|
common/bech32_util.o \
|
2017-11-22 01:26:08 +01:00
|
|
|
common/bolt11.o \
|
|
|
|
common/hash_u5.o \
|
|
|
|
common/type_to_string.o \
|
|
|
|
common/utils.o \
|
2018-06-28 03:34:47 +02:00
|
|
|
common/version.o \
|
|
|
|
common/wireaddr.o
|
2017-11-22 01:26:08 +01:00
|
|
|
|
2018-03-01 16:58:18 +01:00
|
|
|
devtools-all: devtools/bolt11-cli devtools/decodemsg devtools/onion
|
2017-11-22 01:26:08 +01:00
|
|
|
|
2018-02-01 01:08:37 +01:00
|
|
|
devtools/gen_print_wire.h: $(WIRE_GEN) wire/gen_peer_wire_csv
|
|
|
|
$(WIRE_GEN) --bolt --printwire --header $@ wire_type < wire/gen_peer_wire_csv > $@
|
2017-11-22 01:26:08 +01:00
|
|
|
|
2018-02-01 01:08:37 +01:00
|
|
|
devtools/gen_print_wire.c: $(WIRE_GEN) wire/gen_peer_wire_csv
|
|
|
|
$(WIRE_GEN) --bolt --printwire ${@:.c=.h} wire_type < wire/gen_peer_wire_csv > $@
|
|
|
|
|
|
|
|
devtools/bolt11-cli: $(DEVTOOLS_OBJS) $(DEVTOOLS_COMMON_OBJS) $(JSMN_OBJS) $(CCAN_OBJS) $(BITCOIN_OBJS) wire/fromwire.o wire/towire.o devtools/bolt11-cli.o
|
|
|
|
|
|
|
|
devtools/decodemsg: $(DEVTOOLS_OBJS) $(DEVTOOLS_COMMON_OBJS) $(JSMN_OBJS) $(CCAN_OBJS) $(BITCOIN_OBJS) wire/fromwire.o wire/towire.o devtools/decodemsg.o
|
|
|
|
|
2018-03-08 21:08:04 +01:00
|
|
|
devtools/onion.c: ccan/config.h
|
|
|
|
|
2018-03-01 16:58:18 +01:00
|
|
|
devtools/onion: $(DEVTOOLS_OBJS) $(DEVTOOLS_COMMON_OBJS) $(JSMN_OBJS) $(CCAN_OBJS) $(BITCOIN_OBJS) wire/fromwire.o wire/towire.o devtools/onion.o common/sphinx.o
|
|
|
|
|
2018-02-01 01:08:37 +01:00
|
|
|
$(DEVTOOLS_OBJS) $(DEVTOOLS_TOOL_OBJS): wire/wire.h devtools/gen_print_wire.h
|
2018-06-28 03:30:49 +02:00
|
|
|
devtools/gen_print_wire.o: devtools/gen_print_wire.h wire/gen_peer_wire.h devtools/print_wire.h
|
2017-11-22 01:26:08 +01:00
|
|
|
|
|
|
|
# Make sure these depend on everything.
|
2018-03-01 16:58:18 +01:00
|
|
|
ALL_PROGRAMS += devtools/bolt11-cli devtools/decodemsg devtools/onion
|
2018-02-01 01:08:37 +01:00
|
|
|
ALL_OBJS += $(DEVTOOLS_OBJS) $(DEVTOOLS_TOOL_OBJS)
|
2017-11-22 01:26:08 +01:00
|
|
|
|
2018-02-01 01:08:37 +01:00
|
|
|
check-source: $(DEVTOOLS_SRC:%=check-src-include-order/%) $(DEVTOOLS_TOOLS_SRC:%=check-src-include-order/%)
|
2017-11-22 01:26:08 +01:00
|
|
|
|
|
|
|
clean: devtools-clean
|
|
|
|
|
|
|
|
devtools-clean:
|
|
|
|
$(RM) $(DEVTOOLS_CLI_OBJS)
|