sync/Makefile
author Krista 'DarthMama' Bennett <krista@pep.foundation>
Fri, 31 Jul 2020 21:10:17 +0200
branchENGINE-781
changeset 4922 32a5d2ca9691
parent 4255 25a0aa0af8fa
permissions -rw-r--r--
ENGINE-781: tests and memory fun!
     1 # This file is under GNU General Public License 3.0
     2 # see LICENSE.txt
     3 
     4 include ../Makefile.conf
     5 
     6 .PHONY: all clean
     7 
     8 all: .copy
     9 
    10 generated:
    11 	mkdir -p $@
    12 
    13 .actions: sync.fsm gen_actions.ysl2 fsm.yml2 functions.ysl2 $(wildcard cond_act_*.yml2) | generated
    14 	$(YML2_PROC) -y gen_actions.ysl2 $< -o $@
    15 
    16 .statemachines: sync.fsm gen_statemachine.ysl2 fsm.yml2 functions.ysl2 | generated
    17 	$(YML2_PROC) -y gen_statemachine.ysl2 $< -o $@
    18 
    19 .codecs: sync.fsm distribution.fsm gen_codec.ysl2 fsm.yml2 functions.ysl2 | generated
    20 	$(YML2_PROC) -y gen_codec.ysl2 $< -o $@
    21 	$(YML2_PROC) -y gen_codec.ysl2 distribution.fsm -o $@
    22 
    23 .messages: sync.fsm distribution.fsm gen_messages.ysl2 gen_message_func.ysl2 fsm.yml2 functions.ysl2 | generated
    24 	$(YML2_PROC) -y gen_messages.ysl2 $< -o $@
    25 	$(YML2_PROC) -y gen_message_func.ysl2 $< -o $@
    26 	$(YML2_PROC) -y gen_messages.ysl2 distribution.fsm -o $@
    27 
    28 clean:
    29 	rm -rf generated
    30 	rm -f *.xml *.xsl .statemachines .actions .codecs .messages .copy *.dot *.svg
    31 
    32 .copy: .actions .statemachines .codecs .messages
    33 	cp -f generated/*.c generated/*.h ../src
    34 	cp -f generated/*.asn1 ../asn.1
    35 	touch .copy
    36 
    37 %.xml: %.fsm
    38 	yml2c $< -o $@
    39 
    40 %.dot: sync.fsm gen_dot.ysl2
    41 	$(YML2_PROC) -y gen_dot.ysl2 $<
    42 
    43 %.svg: %.dot
    44 	dot -Tsvg -o $@ $<
    45