Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 194 lines (156 sloc) 6.908 kB
f158695 *** empty log message ***
Pascal Brisset authored
1 # Hey Emacs, this is a -*- makefile -*-
9907c23 This commit was generated by cvs2svn to compensate for changes in r2,
Antoine Drouin authored
2 # Paparazzi main $Id$
3 # Copyright (C) 2004 Pascal Brisset Antoine Drouin
4 #
5 # This file is part of paparazzi.
6 #
7 # paparazzi is free software; you can redistribute it and/or modify
8 # it under the terms of the GNU General Public License as published by
9 # the Free Software Foundation; either version 2, or (at your option)
10 # any later version.
11 #
12 # paparazzi is distributed in the hope that it will be useful,
13 # but WITHOUT ANY WARRANTY; without even the implied warranty of
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 # GNU General Public License for more details.
16 #
17 # You should have received a copy of the GNU General Public License
18 # along with paparazzi; see the file COPYING. If not, write to
19 # the Free Software Foundation, 59 Temple Place - Suite 330,
8d02fa0 @flixr removed old booz generation of radio_control ppm
flixr authored
20 # Boston, MA 02111-1307, USA.
9907c23 This commit was generated by cvs2svn to compensate for changes in r2,
Antoine Drouin authored
21
22 # Preprocessing of XML configuration files
23
2858204 install
Pascal Brisset authored
24 PAPARAZZI_SRC=$(shell pwd)
25
9907c23 This commit was generated by cvs2svn to compensate for changes in r2,
Antoine Drouin authored
26 include conf/Makefile.local
27
28 CONF=$(PAPARAZZI_HOME)/conf
29 CONF_XML=$(CONF)/conf.xml
2858204 install
Pascal Brisset authored
30 AIRBORNE=sw/airborne
1cfa447 *** empty log message ***
Antoine Drouin authored
31 MESSAGES_XML = $(CONF)/messages.xml
9907c23 This commit was generated by cvs2svn to compensate for changes in r2,
Antoine Drouin authored
32 ACINCLUDE = $(PAPARAZZI_HOME)/var/$(AIRCRAFT)
b333d9e MD5 digest transmitted in the ALIVE message
Pascal Brisset authored
33 AIRCRAFT_CONF_DIR = $(ACINCLUDE)/conf
7fd01bc @flixr put generated headers in a seperate generated dir and specifically in…
flixr authored
34 AC_GENERATED = $(ACINCLUDE)/generated
f481c46 changing telemetry frequency
Antoine Drouin authored
35
36 ifndef PERIODIC_FREQ
37 PERIODIC_FREQ = 60
38 endif
39
7fd01bc @flixr put generated headers in a seperate generated dir and specifically in…
flixr authored
40 AIRFRAME_H=$(AC_GENERATED)/airframe.h
bb192c0 @gautierhattenberger rename periodic.h to periodic_telemetry.h; remove channel/device at c…
gautierhattenberger authored
41 PERIODIC_H=$(AC_GENERATED)/periodic_telemetry.h
7fd01bc @flixr put generated headers in a seperate generated dir and specifically in…
flixr authored
42 RADIO_H=$(AC_GENERATED)/radio.h
43 FLIGHT_PLAN_H=$(AC_GENERATED)/flight_plan.h
5d6a84a *** empty log message ***
Pascal Brisset authored
44 FLIGHT_PLAN_XML=$(ACINCLUDE)/flight_plan.xml
7fd01bc @flixr put generated headers in a seperate generated dir and specifically in…
flixr authored
45 SETTINGS_H=$(AC_GENERATED)/settings.h
ac93b91 *** empty log message ***
Pascal Brisset authored
46 SETTINGS_XMLS=$(patsubst %,$(CONF)/%,$(SETTINGS))
47 SETTINGS_XML=$(ACINCLUDE)/settings.xml
1e2333c @gautierhattenberger add settings to start and stop the modules
gautierhattenberger authored
48 SETTINGS_MODULES=$(ACINCLUDE)/settings_modules.xml
c30b724 @gautierhattenberger the telemetry settings are automatically generated and included to the
gautierhattenberger authored
49 SETTINGS_TELEMETRY=$(ACINCLUDE)/settings_telemetry.xml
01a078a *** empty log message ***
Pascal Brisset authored
50 MAKEFILE_AC=$(ACINCLUDE)/Makefile.ac
6dcf9e7 @gautierhattenberger generate tuning files in var/include and var/<AC>,
gautierhattenberger authored
51 SETTINGS_FILE=$(SETTINGS:settings%=%)
9dbe645 @gautierhattenberger correction for multiple settings file as input
gautierhattenberger authored
52 #TUNING_FILE=$(subst ,_,$(SETTINGS:settings/%.xml=%)).h
7fd01bc @flixr put generated headers in a seperate generated dir and specifically in…
flixr authored
53 TUNING_H=$(AC_GENERATED)/tuning.h
dcce09f demo Makefile target out of date
Pascal Brisset authored
54 SUPERVISION=./paparazzi
2858204 install
Pascal Brisset authored
55 MAKE=make PAPARAZZI_SRC=$(PAPARAZZI_SRC) PAPARAZZI_HOME=$(PAPARAZZI_HOME)
7fd01bc @flixr put generated headers in a seperate generated dir and specifically in…
flixr authored
56 MODULES_H=$(AC_GENERATED)/modules.h
998a767 - added dependency over .md5 file
Pascal Brisset authored
57 AIRCRAFT_MD5=$(AIRCRAFT_CONF_DIR)/aircraft.md5
2858204 install
Pascal Brisset authored
58
beb9c96 *** empty log message ***
Pascal Brisset authored
59 # "make Q=''" to get full echo
60 Q=@
7168721 New infrared neutral. aileron_of_gaz
Pascal Brisset authored
61
2858204 install
Pascal Brisset authored
62 init:
6d53c13 @flixr don't attempt to (non-existing) copy map tiles on init
flixr authored
63 @[ -d $(PAPARAZZI_HOME) ] || (echo "Copying config example in your $(PAPARAZZI_HOME) directory"; mkdir -p $(PAPARAZZI_HOME); cp -a conf $(PAPARAZZI_HOME); cp -a data $(PAPARAZZI_HOME); mkdir -p $(PAPARAZZI_HOME)/var/maps; mkdir -p $(PAPARAZZI_HOME)/var/include)
2858204 install
Pascal Brisset authored
64
dcce09f demo Makefile target out of date
Pascal Brisset authored
65 demo:
66 $(SUPERVISION)
2858204 install
Pascal Brisset authored
67
8d02fa0 @flixr removed old booz generation of radio_control ppm
flixr authored
68 ifeq ($(MAKECMDGOALS),all_ac_h)
44357d5 @dewagter Makefile echo problem
dewagter authored
69 -include $(MAKEFILE_AC)
70 endif
71
72
73
1e2333c @gautierhattenberger add settings to start and stop the modules
gautierhattenberger authored
74 all_ac_h: $(AIRFRAME_H) $(MODULES_H) $(SETTINGS_H) $(TUNING_H) $(MAKEFILE_AC) $(PERIODIC_H)
d198072 @flixr also print LDFLAGS to var/ac/target_srcs.list
flixr authored
75 @echo "TARGET: " $(TARGET)"\n" > $(ACINCLUDE)/$(TARGET)_srcs.list
76 @echo "CFLAGS: " $($(TARGET).CFLAGS)"\n" >> $(ACINCLUDE)/$(TARGET)_srcs.list
77 @echo "LDFLAGS: " $($(TARGET).LDFLAGS)"\n" >> $(ACINCLUDE)/$(TARGET)_srcs.list
44357d5 @dewagter Makefile echo problem
dewagter authored
78 @echo "srcs: " $($(TARGET).srcs) >> $(ACINCLUDE)/$(TARGET)_srcs.list
8db4c1d radio attribute is now optional in aircraft config
Pascal Brisset authored
79
8d02fa0 @flixr removed old booz generation of radio_control ppm
flixr authored
80 radio_ac_h : $(RADIO_H)
8db4c1d radio attribute is now optional in aircraft config
Pascal Brisset authored
81
82 flight_plan_ac_h : $(FLIGHT_PLAN_H) $(FLIGHT_PLAN_XML)
2858204 install
Pascal Brisset authored
83
e11b3e8 Makefile.ac now generated before headers
Pascal Brisset authored
84 makefile_ac: $(MAKEFILE_AC)
85
998a767 - added dependency over .md5 file
Pascal Brisset authored
86 $(AIRFRAME_H) : $(CONF)/$(AIRFRAME_XML) $(CONF_XML) $(AIRCRAFT_MD5)
7fd01bc @flixr put generated headers in a seperate generated dir and specifically in…
flixr authored
87 $(Q)test -d $(AC_GENERATED) || mkdir -p $(AC_GENERATED)
beb9c96 *** empty log message ***
Pascal Brisset authored
88 @echo BUILD $@
b333d9e MD5 digest transmitted in the ALIVE message
Pascal Brisset authored
89 $(Q)$(TOOLS)/gen_airframe.out $(AC_ID) $(AIRCRAFT) $(MD5SUM) $< > /tmp/airframe.h
beb9c96 *** empty log message ***
Pascal Brisset authored
90 $(Q)mv /tmp/airframe.h $@
b333d9e MD5 digest transmitted in the ALIVE message
Pascal Brisset authored
91 $(Q)cp $(CONF)/airframes/airframe.dtd $(AIRCRAFT_CONF_DIR)/airframes
9907c23 This commit was generated by cvs2svn to compensate for changes in r2,
Antoine Drouin authored
92
5528979 dependency over gen_radio added
Pascal Brisset authored
93 $(RADIO_H) : $(CONF)/$(RADIO) $(CONF_XML) $(TOOLS)/gen_radio.out
7fd01bc @flixr put generated headers in a seperate generated dir and specifically in…
flixr authored
94 $(Q)test -d $(AC_GENERATED) || mkdir -p $(AC_GENERATED)
beb9c96 *** empty log message ***
Pascal Brisset authored
95 @echo BUILD $@
96 $(Q)$(TOOLS)/gen_radio.out $< > /tmp/radio.h
97 $(Q)mv /tmp/radio.h $@
b333d9e MD5 digest transmitted in the ALIVE message
Pascal Brisset authored
98 $(Q)cp $< $(AIRCRAFT_CONF_DIR)/radios
7cda6a8 big arm7/sys_time_hw cleaning
Antoine Drouin authored
99
7367465 @gautierhattenberger add a "module" attribute in telemetry definition
gautierhattenberger authored
100 $(PERIODIC_H) : $(CONF)/$(AIRFRAME_XML) $(MESSAGES_XML) $(CONF_XML) $(CONF)/$(TELEMETRY) $(MAKEFILE_AC)
7fd01bc @flixr put generated headers in a seperate generated dir and specifically in…
flixr authored
101 $(Q)test -d $(AC_GENERATED) || mkdir -p $(AC_GENERATED)
beb9c96 *** empty log message ***
Pascal Brisset authored
102 @echo BUILD $@
c30b724 @gautierhattenberger the telemetry settings are automatically generated and included to the
gautierhattenberger authored
103 $(Q)$(TOOLS)/gen_periodic.out $(CONF)/$(AIRFRAME_XML) $(MESSAGES_XML) $(CONF)/$(TELEMETRY) $(PERIODIC_FREQ) $(SETTINGS_TELEMETRY) > $@
beb9c96 *** empty log message ***
Pascal Brisset authored
104 $(Q)chmod a+r $@
b333d9e MD5 digest transmitted in the ALIVE message
Pascal Brisset authored
105 $(Q)cp $< $(AIRCRAFT_CONF_DIR)
106 $(Q)cp $(CONF)/$(TELEMETRY) $(AIRCRAFT_CONF_DIR)/telemetry
1cfa447 *** empty log message ***
Antoine Drouin authored
107
36c208b failsafe modes
Pascal Brisset authored
108 $(FLIGHT_PLAN_H) : $(CONF)/$(FLIGHT_PLAN) $(CONF_XML) $(TOOLS)/gen_flight_plan.out
7fd01bc @flixr put generated headers in a seperate generated dir and specifically in…
flixr authored
109 $(Q)test -d $(AC_GENERATED) || mkdir -p $(AC_GENERATED)
beb9c96 *** empty log message ***
Pascal Brisset authored
110 @echo BUILD $@
d914f7f add a temporary file for the flight plan to properly stop a wrong co…
Pascal Brisset authored
111 $(Q)$(TOOLS)/gen_flight_plan.out $< > /tmp/$(AC_ID)_fp.h
112 $(Q)mv /tmp/$(AC_ID)_fp.h $@
120a456 dynamic settings removed from fp, moved to conf/settings/, specified in
Pascal Brisset authored
113 $(Q)chmod a+r $@
b333d9e MD5 digest transmitted in the ALIVE message
Pascal Brisset authored
114 $(Q)cp $< $(AIRCRAFT_CONF_DIR)/flight_plans
9907c23 This commit was generated by cvs2svn to compensate for changes in r2,
Antoine Drouin authored
115
0c7dfff bug fixed in exceptions appearing in procedures
Pascal Brisset authored
116 $(FLIGHT_PLAN_XML) : $(CONF)/$(FLIGHT_PLAN) $(CONF_XML) $(TOOLS)/gen_flight_plan.out
beb9c96 *** empty log message ***
Pascal Brisset authored
117 @echo BUILD $@
120a456 dynamic settings removed from fp, moved to conf/settings/, specified in
Pascal Brisset authored
118 $(Q)$(TOOLS)/gen_flight_plan.out -dump $< > $@
119 $(Q)chmod a+r $@
5d6a84a *** empty log message ***
Pascal Brisset authored
120
c30b724 @gautierhattenberger the telemetry settings are automatically generated and included to the
gautierhattenberger authored
121 $(SETTINGS_H) : $(SETTINGS_XMLS) $(CONF_XML) $(SETTINGS_MODULES) $(SETTINGS_TELEMETRY) $(TOOLS)/gen_settings.out
7fd01bc @flixr put generated headers in a seperate generated dir and specifically in…
flixr authored
122 $(Q)test -d $(AC_GENERATED) || mkdir -p $(AC_GENERATED)
beb9c96 *** empty log message ***
Pascal Brisset authored
123 @echo BUILD $@
afe5c5b @flixr make telemetry settings the first tab
flixr authored
124 $(Q)$(TOOLS)/gen_settings.out $(SETTINGS_XML) $(SETTINGS_TELEMETRY) $(SETTINGS_XMLS) $(SETTINGS_MODULES) > $@
120a456 dynamic settings removed from fp, moved to conf/settings/, specified in
Pascal Brisset authored
125 $(Q)chmod a+r $@
b333d9e MD5 digest transmitted in the ALIVE message
Pascal Brisset authored
126 $(Q)cp $(SETTINGS_XMLS) $(AIRCRAFT_CONF_DIR)/settings
9907c23 This commit was generated by cvs2svn to compensate for changes in r2,
Antoine Drouin authored
127
6dcf9e7 @gautierhattenberger generate tuning files in var/include and var/<AC>,
gautierhattenberger authored
128 $(TUNING_H) : $(SETTINGS_XMLS) $(CONF_XML) $(TOOLS)/gen_tuning.out
7fd01bc @flixr put generated headers in a seperate generated dir and specifically in…
flixr authored
129 $(Q)test -d $(AC_GENERATED) || mkdir -p $(AC_GENERATED)
6dcf9e7 @gautierhattenberger generate tuning files in var/include and var/<AC>,
gautierhattenberger authored
130 @echo BUILD $@
131 $(Q)$(TOOLS)/gen_tuning.out $(SETTINGS_XMLS) > $@
132
4b9b4f2 @gautierhattenberger add dependencies for modules compilation and protection flags USE_MOD…
gautierhattenberger authored
133 $(MODULES_H) : $(CONF)/$(AIRFRAME_XML) $(TOOLS)/gen_modules.out $(CONF)/modules/*.xml
7fd01bc @flixr put generated headers in a seperate generated dir and specifically in…
flixr authored
134 $(Q)test -d $(AC_GENERATED) || mkdir -p $(AC_GENERATED)
dd18c15 @gautierhattenberger add modules to the Makefile
gautierhattenberger authored
135 @echo BUILD $@
e945dc8 @gautierhattenberger factorize most of the modules tools
gautierhattenberger authored
136 $(Q)$(TOOLS)/gen_modules.out $(SETTINGS_MODULES) $< > $@
dd18c15 @gautierhattenberger add modules to the Makefile
gautierhattenberger authored
137 $(Q)chmod a+r $@
01a078a *** empty log message ***
Pascal Brisset authored
138
624a080 SETTINGS_MODULES aka settings_modules.xml is generated by gen_modules…
Allen Ibara authored
139 $(SETTINGS_MODULES) : $(MODULES_H)
c30b724 @gautierhattenberger the telemetry settings are automatically generated and included to the
gautierhattenberger authored
140 $(SETTINGS_TELEMETRY) : $(PERIODIC_H)
624a080 SETTINGS_MODULES aka settings_modules.xml is generated by gen_modules…
Allen Ibara authored
141
f4b3988 ac_h depends on gen_aircraft.out
Allen Ibara authored
142 %.ac_h : $(TOOLS)/gen_aircraft.out
2858204 install
Pascal Brisset authored
143 $(Q)if (expr "$(AIRCRAFT)"); then : ; else echo "AIRCRAFT undefined: type 'make AIRCRAFT=AircraftName ...'"; exit 1; fi
acdf61f @gautierhattenberger unload modules if the target is not supported (this may require a cle…
gautierhattenberger authored
144 @echo BUILD $(AIRCRAFT), TARGET $*
0281d66 Use + for jobserver since gen_aircraft.out calles make directly
Allen Ibara authored
145 +$(Q)PAPARAZZI_SRC=$(PAPARAZZI_SRC) PAPARAZZI_HOME=$(PAPARAZZI_HOME) TARGET=$* Q=$(Q) $(TOOLS)/gen_aircraft.out $(AIRCRAFT)
2858204 install
Pascal Brisset authored
146
acdf61f @gautierhattenberger unload modules if the target is not supported (this may require a cle…
gautierhattenberger authored
147 %.compile: %.ac_h
2858204 install
Pascal Brisset authored
148 cd $(AIRBORNE); $(MAKE) TARGET=$* all
149
150 %.wr_fuses: %.compile
151 cd $(AIRBORNE); $(MAKE) TARGET=$* wr_fuses
152
153 %.rd_fuses: %.compile
154 cd $(AIRBORNE); $(MAKE) TARGET=$* rd_fuses
155
156 %.check_fuses: %.compile
157 cd $(AIRBORNE); $(MAKE) TARGET=$* check_fuses
158
159 %.erase: %.compile
160 cd $(AIRBORNE); $(MAKE) TARGET=$* erase
161
162 %.upload: %.compile
163 cd $(AIRBORNE); $(MAKE) TARGET=$* upload
164
9598e60 bootloader install
Pascal Brisset authored
165 # Copy from Makefile, to get it in the paparazzi-bin package
166 BOOTLOADER_DEVICE=/dev/ttyUSB0
167 tiny_bl.upload:
03a9ab6 @flixr moved arm7 directory to arch/lpc21 and set most makefiles accordingly
flixr authored
168 lpc21isp -control $(AIRBORNE)/arch/lpc21/test/bootloader/bl.hex $(BOOTLOADER_DEVICE) 38400 12000
9598e60 bootloader install
Pascal Brisset authored
169
3a7ab4b @gautierhattenberger fixing compilation for target sim and jsbsim
gautierhattenberger authored
170 jsbsim jsbsim.compile: jsbsim.ac_h
7367465 @gautierhattenberger add a "module" attribute in telemetry definition
gautierhattenberger authored
171 cd $(AIRBORNE); $(MAKE) TARGET=jsbsim ARCHI=jsbsim ARCH=jsbsim all
906e178 @gautierhattenberger Add target jsbsim to compile both simulator independantly
gautierhattenberger authored
172
3a7ab4b @gautierhattenberger fixing compilation for target sim and jsbsim
gautierhattenberger authored
173 sim sim.compile: sim.ac_h
7367465 @gautierhattenberger add a "module" attribute in telemetry definition
gautierhattenberger authored
174 cd $(AIRBORNE); $(MAKE) TARGET=sim ARCHI=sim ARCH=sim all
2858204 install
Pascal Brisset authored
175
176 # Rules for backward compatibility (old guys are used to !)
177 fbw : fbw.compile
178 ap: ap.compile
179 upload_fbw: fbw.upload
180 upload_ap: ap.upload
181 erase_fbw: fbw.erase
182 erase_ap: ap.erase
183 wr_fuses_ap: ap.wr_fuses
184 wr_fuses_fbw: fbw.wr_fuses
185 rd_fuses_ap: ap.rd_fuses
186 rd_fuses_fbw: fbw.rd_fuses
187 check_fuses_ap: ap.check_fuses
188 check_fuses_fbw: fbw.check_fuses
189 hard_ac ac: ac_h fbw ap
190
191 clean_ac :
192 $(Q)if (expr "$(AIRCRAFT)"); then : ; else echo "AIRCRAFT undefined: type 'make AIRCRAFT=AircraftName ...'"; exit 1; fi
193 rm -fr $(PAPARAZZI_HOME)/var/$(AIRCRAFT)
Something went wrong with that request. Please try again.