diff --git a/Makefile.install b/Makefile.install index 1e3d5a684f..922651cd36 100644 --- a/Makefile.install +++ b/Makefile.install @@ -1,98 +1,130 @@ # Hey Emacs, this is a -*- makefile -*- -PREFIX=/usr -DESTDIR=$(PREFIX)/share/paparazzi +PREFIX=/ +DESTDIR=$(PREFIX)/usr/share/paparazzi +INSTALL=install -o root +INSTALLDATA=install -o root -m 644 -install: install_data install_conf install_bin install_libs install_tools install_airborne_sources +install : install_files post_install +install_files: install_data install_conf install_bin install_libs install_tools install_airborne_sources + +post_install : + debian/paparazzi-bin.postinst install_data: - install -d $(DESTDIR)/data/maps - install data/maps/*.xml data/maps/*.gif data/maps/*.png $(DESTDIR)/data/maps - install -d $(DESTDIR)/data/pictures - install data/pictures/*.gif data/pictures/*.svg data/pictures/*.jpg $(DESTDIR)/data/pictures - install -d $(DESTDIR)/data/srtm - install data/srtm/N43E001.hgt.bz2 $(DESTDIR)/data/srtm + $(INSTALL) -d $(DESTDIR)/data/maps + $(INSTALLDATA) data/maps/*.xml data/maps/*.gif $(DESTDIR)/data/maps + $(INSTALL) -d $(DESTDIR)/data/pictures + $(INSTALLDATA) data/pictures/*.gif data/pictures/*.svg data/pictures/*.jpg $(DESTDIR)/data/pictures + $(INSTALL) -d $(DESTDIR)/data/srtm + $(INSTALLDATA) data/srtm/N43E001.hgt.bz2 $(DESTDIR)/data/srtm install_conf: - install -d $(DESTDIR)/conf - install conf/conf.xml.example $(DESTDIR)/conf/conf.xml - install conf/control_panel.xml.example $(DESTDIR)/conf/control_panel.xml - install conf/messages.xml $(DESTDIR)/conf/ - install conf/messages.dtd $(DESTDIR)/conf/ - install conf/gui.xml $(DESTDIR)/conf/ - cp -a conf/airframes $(DESTDIR)/conf/ - cp -a conf/autopilot $(DESTDIR)/conf/ - cp -a conf/flight_plans $(DESTDIR)/conf/ - cp -a conf/gps $(DESTDIR)/conf/ - cp -a conf/radios $(DESTDIR)/conf/ - cp -a conf/telemetry $(DESTDIR)/conf/ - cp -a conf/settings $(DESTDIR)/conf/ - cp -a conf/gcs $(DESTDIR)/conf/ + $(INSTALL) -d $(DESTDIR)/conf + $(INSTALLDATA) conf/conf.xml.example $(DESTDIR)/conf/conf.xml + $(INSTALLDATA) conf/control_panel.xml.example $(DESTDIR)/conf/control_panel.xml + $(INSTALLDATA) conf/messages.xml $(DESTDIR)/conf/ + $(INSTALLDATA) conf/messages.dtd $(DESTDIR)/conf/ + $(INSTALLDATA) conf/gui.xml $(DESTDIR)/conf/ + $(INSTALL) -d $(DESTDIR)/conf/airframes + $(INSTALLDATA) conf/airframes/airframe.dtd $(DESTDIR)/conf/airframes + $(INSTALLDATA) conf/airframes/microjet5.xml $(DESTDIR)/conf/airframes + $(INSTALLDATA) conf/airframes/twinstar1.xml $(DESTDIR)/conf/airframes + $(INSTALLDATA) conf/airframes/twinjet1.xml $(DESTDIR)/conf/airframes + $(INSTALL) -d $(DESTDIR)/conf/autopilot + $(INSTALLDATA) conf/autopilot/*.makefile $(DESTDIR)/conf/autopilot + $(INSTALLDATA) conf/autopilot/*.h $(DESTDIR)/conf/autopilot + $(INSTALL) -d $(DESTDIR)/conf/flight_plans + $(INSTALLDATA) conf/flight_plans/*.dtd $(DESTDIR)/conf/flight_plans + $(INSTALLDATA) conf/flight_plans/*.xml $(DESTDIR)/conf/flight_plans + $(INSTALL) -d $(DESTDIR)/conf/gps + $(INSTALLDATA) conf/gps/Makefile $(DESTDIR)/conf/gps + $(INSTALLDATA) conf/gps/ublox_conf.c $(DESTDIR)/conf/gps + $(INSTALLDATA) conf/gps/README $(DESTDIR)/conf/gps + $(INSTALLDATA) conf/gps/*.inf $(DESTDIR)/conf/gps + $(INSTALLDATA) conf/gps/*.txt $(DESTDIR)/conf/gps + $(INSTALL) -d $(DESTDIR)/conf/radios + $(INSTALLDATA) conf/radios/radio.dtd $(DESTDIR)/conf/radios + $(INSTALLDATA) conf/radios/*.xml $(DESTDIR)/conf/radios + $(INSTALL) -d $(DESTDIR)/conf/telemetry + $(INSTALLDATA) conf/telemetry/telemetry.dtd $(DESTDIR)/conf/telemetry + $(INSTALLDATA) conf/telemetry/*.xml $(DESTDIR)/conf/telemetry + $(INSTALL) -d $(DESTDIR)/conf/settings + $(INSTALLDATA) conf/settings/settings.dtd $(DESTDIR)/conf/settings + $(INSTALLDATA) conf/settings/*.xml $(DESTDIR)/conf/settings + $(INSTALL) -d $(DESTDIR)/conf/gcs + $(INSTALLDATA) conf/gcs/layout.dtd $(DESTDIR)/conf/gcs + $(INSTALLDATA) conf/gcs/*.xml $(DESTDIR)/conf/gcs + $(INSTALL) -d $(PREFIX)/etc/udev + $(INSTALLDATA) conf/system/udev/rules/*.rules $(PREFIX)/etc/udev + $(INSTALL) -d $(PREFIX)/etc/modprobe.d + $(INSTALLDATA) conf/system/modprobe.d/paparazzi $(PREFIX)/etc/modprobe.d + install_bin: - install -d $(PREFIX)/bin/ - install -d $(DESTDIR)/sw/supervision - install sw/supervision/paparazzi.pl $(DESTDIR)/sw/supervision - install paparazzi-make $(PREFIX)/bin/ - install -d $(DESTDIR)/sw/simulator - install sw/simulator/gaia $(DESTDIR)/sw/simulator - install sw/simulator/simsitl.pl $(DESTDIR)/sw/simulator - install -d $(DESTDIR)/sw/ground_segment/cockpit - install -d $(DESTDIR)/sw/ground_segment/tmtc - install sw/ground_segment/cockpit/gcs $(DESTDIR)/sw/ground_segment/cockpit - install sw/ground_segment/tmtc/server $(DESTDIR)/sw/ground_segment/tmtc - install sw/ground_segment/tmtc/link $(DESTDIR)/sw/ground_segment/tmtc - install sw/ground_segment/tmtc/messages $(DESTDIR)/sw/ground_segment/tmtc - install -d $(DESTDIR)/sw/logalizer - install sw/logalizer/play $(DESTDIR)/sw/logalizer - install sw/logalizer/plot.pl $(DESTDIR)/sw/logalizer - ln -sf ../share/paparazzi/sw/ground_segment/cockpit/gcs $(PREFIX)/bin/paparazzi-gcs - ln -sf ../share/paparazzi/sw/supervision/paparazzi.pl $(PREFIX)/bin/paparazzi + $(INSTALL) -d $(PREFIX)/usr/bin/ + $(INSTALL) -d $(DESTDIR)/sw/supervision + $(INSTALL) sw/supervision/paparazzi.pl $(DESTDIR)/sw/supervision + $(INSTALL) paparazzi-make $(PREFIX)/usr/bin/ + $(INSTALLDATA) -d $(DESTDIR)/sw/simulator + $(INSTALL) sw/simulator/*.cmo $(DESTDIR)/sw/simulator + $(INSTALL) sw/simulator/simsitl.pl $(DESTDIR)/sw/simulator + $(INSTALL) -d $(DESTDIR)/sw/ground_segment/cockpit + $(INSTALL) -d $(DESTDIR)/sw/ground_segment/tmtc + $(INSTALL) -d $(DESTDIR)/sw/ground_segment/multimon + $(INSTALL) sw/ground_segment/cockpit/*.cmo $(DESTDIR)/sw/ground_segment/cockpit + $(INSTALLDATA) sw/ground_segment/tmtc/*.cmo $(DESTDIR)/sw/ground_segment/tmtc + $(INSTALLDATA) sw/ground_segment/multimon/multimon.cma $(DESTDIR)/sw/ground_segment/multimon + $(INSTALLDATA) sw/ground_segment/multimon/libmultimon.a $(DESTDIR)/sw/ground_segment/multimon + $(INSTALL) -d $(DESTDIR)/sw/logalizer + $(INSTALLDATA) sw/logalizer/*.cmo $(DESTDIR)/sw/logalizer + $(INSTALL) sw/logalizer/plot.pl $(DESTDIR)/sw/logalizer + ln -sf ../share/paparazzi/sw/ground_segment/cockpit/gcs $(PREFIX)/usr/bin/paparazzi-gcs + ln -sf ../share/paparazzi/sw/supervision/paparazzi.pl $(PREFIX)/usr/bin/paparazzi install_libs: - install -d $(PREFIX)/lib/perl5/Paparazzi - install sw/lib/perl/Paparazzi/*.pm $(PREFIX)/lib/perl5/Paparazzi - install sw/supervision/Paparazzi/*.pm $(PREFIX)/lib/perl5/Paparazzi - install -d $(DESTDIR)/sw/lib/ocaml - install sw/lib/ocaml/*.cma $(DESTDIR)/sw/lib/ocaml - install sw/lib/ocaml/*.so $(DESTDIR)/sw/lib/ocaml - install sw/lib/ocaml/*.a $(DESTDIR)/sw/lib/ocaml - install sw/lib/ocaml/*.cmi $(DESTDIR)/sw/lib/ocaml + $(INSTALL) -d $(PREFIX)/usr/lib/perl5/Paparazzi + $(INSTALLDATA) sw/lib/perl/Paparazzi/*.pm $(PREFIX)/usr/lib/perl5/Paparazzi + $(INSTALLDATA) sw/supervision/Paparazzi/*.pm $(PREFIX)/usr/lib/perl5/Paparazzi + $(INSTALL) -d $(DESTDIR)/sw/lib/ocaml + $(INSTALLDATA) sw/lib/ocaml/*.cma $(DESTDIR)/sw/lib/ocaml + $(INSTALLDATA) sw/lib/ocaml/*.so $(DESTDIR)/sw/lib/ocaml + $(INSTALLDATA) sw/lib/ocaml/*.a $(DESTDIR)/sw/lib/ocaml + $(INSTALLDATA) sw/lib/ocaml/*.cmi $(DESTDIR)/sw/lib/ocaml install_tools: - install Makefile.ac $(DESTDIR) - install -d $(DESTDIR)/sw/tools/ - install conf/Makefile* $(DESTDIR)/conf - install sw/tools/*.out $(DESTDIR)/sw/tools/ - install sw/tools/extract_makefile.ml $(DESTDIR)/sw/tools/ - install sw/tools/gen_aircraft.ml $(DESTDIR)/sw/tools/ - install sw/tools/gen_airframe.ml $(DESTDIR)/sw/tools/ - install sw/tools/gen_flight_plan.ml $(DESTDIR)/sw/tools/ - install sw/tools/gen_messages.ml $(DESTDIR)/sw/tools/ - install sw/tools/gen_periodic.ml $(DESTDIR)/sw/tools/ - install sw/tools/gen_radio.ml $(DESTDIR)/sw/tools/ - install sw/tools/gen_settings.ml $(DESTDIR)/sw/tools/ - install sw/tools/gen_ubx.ml $(DESTDIR)/sw/tools/ - install -d $(DESTDIR)/sw/ground_segment/lpc21iap - install sw/ground_segment/lpc21iap/lpc21iap $(DESTDIR)/sw/ground_segment/lpc21iap/ - install -d $(DESTDIR)/sw/simulator - install sw/simulator/sitl.cma $(DESTDIR)/sw/simulator - install sw/simulator/simsitl.ml $(DESTDIR)/sw/simulator - install sw/simulator/sim.cmi $(DESTDIR)/sw/simulator - install sw/simulator/sitl.cmi $(DESTDIR)/sw/simulator - install sw/simulator/libsitl.a $(DESTDIR)/sw/simulator + $(INSTALLDATA) Makefile.ac $(DESTDIR) + $(INSTALL) -d $(DESTDIR)/sw/tools/ + $(INSTALLDATA) conf/Makefile* $(DESTDIR)/conf + $(INSTALL) sw/tools/*.out $(DESTDIR)/sw/tools/ + rm -f $(DESTDIR)/sw/tools/gen_flight_plan.out + $(INSTALLDATA) sw/tools/fp_syntax.cmo $(DESTDIR)/sw/tools + $(INSTALLDATA) sw/tools/fp_parser.cmo $(DESTDIR)/sw/tools + $(INSTALLDATA) sw/tools/fp_lexer.cmo $(DESTDIR)/sw/tools + $(INSTALLDATA) sw/tools/fp_proc.cmo $(DESTDIR)/sw/tools + $(INSTALLDATA) sw/tools/gen_flight_plan.cmo $(DESTDIR)/sw/tools + $(INSTALLDATA) sw/tools/extract_makefile.ml $(DESTDIR)/sw/tools/ + $(INSTALLDATA) sw/tools/gen_aircraft.ml $(DESTDIR)/sw/tools/ + $(INSTALLDATA) sw/tools/gen_airframe.ml $(DESTDIR)/sw/tools/ + $(INSTALLDATA) sw/tools/gen_messages.ml $(DESTDIR)/sw/tools/ + $(INSTALLDATA) sw/tools/gen_periodic.ml $(DESTDIR)/sw/tools/ + $(INSTALLDATA) sw/tools/gen_radio.ml $(DESTDIR)/sw/tools/ + $(INSTALLDATA) sw/tools/gen_settings.ml $(DESTDIR)/sw/tools/ + $(INSTALLDATA) sw/tools/gen_ubx.ml $(DESTDIR)/sw/tools/ + $(INSTALL) -d $(DESTDIR)/sw/ground_segment/lpc21iap + $(INSTALL) sw/ground_segment/lpc21iap/lpc21iap $(DESTDIR)/sw/ground_segment/lpc21iap/ + $(INSTALL) -d $(DESTDIR)/sw/simulator + $(INSTALLDATA) sw/simulator/sitl.cma $(DESTDIR)/sw/simulator + $(INSTALLDATA) sw/simulator/simsitl.ml $(DESTDIR)/sw/simulator + $(INSTALLDATA) sw/simulator/sim.cmi $(DESTDIR)/sw/simulator + $(INSTALLDATA) sw/simulator/sitl.cmi $(DESTDIR)/sw/simulator + $(INSTALLDATA) sw/simulator/libsitl.a $(DESTDIR)/sw/simulator install_airborne_sources: - install -d $(DESTDIR)/sw/ - cp -a sw/airborne $(DESTDIR)/sw - install -d $(DESTDIR)/sw/include - install sw/include/std.h $(DESTDIR)/sw/include - install var/include/*.h $(DESTDIR)/sw/include - - -install_skel: -# cp -a conf $(DESTDIR)/ -# cp -a data $(DESTDIR)/ -# install -d $(DESTDIR)/var + $(INSTALL) -d $(DESTDIR)/sw/ + tar --exclude=CVS -cf - sw/airborne/ | tar -C $(DESTDIR) -xf - + $(INSTALL) -d $(DESTDIR)/sw/include + $(INSTALLDATA) sw/include/std.h $(DESTDIR)/sw/include + $(INSTALLDATA) var/include/*.h $(DESTDIR)/sw/include diff --git a/conf/Makefile.sim b/conf/Makefile.sim index d9c084b955..f1a1f52dfc 100644 --- a/conf/Makefile.sim +++ b/conf/Makefile.sim @@ -68,7 +68,7 @@ all compile: $(OBJDIR)/simsitl $(OBJDIR)/simsitl : $($(TARGET).objs) $(SITLCMA) $(SIMSITLML) @echo LD $@ - $(Q)$(OCAMLC) -custom $(CAMLINCLUDES) -o $@ glibivy-ocaml.cma lib-pprz.cma lablgtk.cma $($(TARGET).objs) gtkInit.cmo $(SITLCMA) $(SIMSITLML) + $(Q)$(OCAMLC) -custom $(CAMLINCLUDES) -o $@ unix.cma str.cma xml-light.cma glibivy-ocaml.cma lib-pprz.cma lablgtk.cma $($(TARGET).objs) gtkInit.cmo $(SITLCMA) $(SIMSITLML) # The id of the A/C is hardcoded in the code (to be improved with dynlink ?) diff --git a/data/maps/sinsat.png b/data/maps/sinsat.png deleted file mode 100644 index 80962c3789..0000000000 Binary files a/data/maps/sinsat.png and /dev/null differ diff --git a/data/maps/sinsat.xml b/data/maps/sinsat.xml deleted file mode 100644 index 80a1d56508..0000000000 --- a/data/maps/sinsat.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - diff --git a/debian/control.etch b/debian/control.etch index 9b77f9a467..95138d296e 100644 --- a/debian/control.etch +++ b/debian/control.etch @@ -6,7 +6,7 @@ Build-Depends: debhelper (>= 4.0.0) Standards-Version: 3.6.1 -Package: paparazzi-base +Package: paparazzi-dev Architecture: any Suggests: paparazzi-avr, paparazzi-arm7 Recommends: eagle, gs-common, tetex-extra, dia-gnome diff --git a/debian/control.sarge b/debian/control.sarge index 4bd9f55b4b..fbe6399566 100644 --- a/debian/control.sarge +++ b/debian/control.sarge @@ -6,7 +6,7 @@ Build-Depends: debhelper (>= 4.0.0) Standards-Version: 3.6.1 -Package: paparazzi-base +Package: paparazzi-dev Architecture: any Suggests: paparazzi-arm7, paparazzi-avr Recommends: eagle, gs-common, tetex-extra, dia-gnome diff --git a/debian/control.sid b/debian/control.sid index 79c3af9fbc..6d72279ab4 100644 --- a/debian/control.sid +++ b/debian/control.sid @@ -6,7 +6,7 @@ Build-Depends: debhelper (>= 4.0.0) Standards-Version: 3.6.1 -Package: paparazzi-base +Package: paparazzi-dev Architecture: any Suggests: mlview, lustre, paparazzi-avr, paparazzi-arm Recommends: eagle, gs-common, tetex-extra, dia-gnome diff --git a/debian/paparazzi-bin.postinst b/debian/paparazzi-bin.postinst new file mode 100755 index 0000000000..d7240f11bc --- /dev/null +++ b/debian/paparazzi-bin.postinst @@ -0,0 +1,25 @@ +#!/bin/sh + +# Link of the Ocaml applications + +set -e + +OCAMLC=ocamlc +DESTDIR=/usr/share/paparazzi + +cd ${DESTDIR}/sw/ground_segment/tmtc +${OCAMLC} -custom -I +lablgtk2 -I ${DESTDIR}/sw/lib/ocaml unix.cma str.cma xml-light.cma lablgtk.cma glibivy-ocaml.cma lib-pprz.cma aircraft.cmo wind.cmo airprox.cmo aircraft.cmo wind.cmo airprox.cmo server.cmo -o server +${OCAMLC} -custom -I +lablgtk2 -I ${DESTDIR}/sw/lib/ocaml -I ../multimon unix.cma str.cma xml-light.cma lablgtk.cma glibivy-ocaml.cma lib-pprz.cma multimon.cma modem.cmo link.cmo -o link +${OCAMLC} -custom -I +lablgtk2 -I ${DESTDIR}/sw/lib/ocaml unix.cma str.cma xml-light.cma lablgtk.cma glibivy-ocaml.cma lib-pprz.cma gtkInit.cmo messages.cmo -o messages + +cd ${DESTDIR}/sw/ground_segment/cockpit +${OCAMLC} -thread -custom -I +lablgtk2 -I ${DESTDIR}/sw/lib/ocaml unix.cma str.cma xml-light.cma lablgtk.cma glibivy-ocaml.cma lib-pprz.cma lablgnomecanvas.cma xlib-pprz.cma threads.cma gtkThread.cmo gtkInit.cmo horizon.cmo strip.cmo pages.cmo speech.cmo plugin.cmo sectors.cmo map2d.cmo editFP.cmo live.cmo gcs.cmo -o gcs + +cd ${DESTDIR}/sw/logalizer +${OCAMLC} -custom -I +lablgtk2 -I ${DESTDIR}/sw/lib/ocaml unix.cma str.cma xml-light.cma lablgtk.cma glibivy-ocaml.cma lib-pprz.cma gtkInit.cmo play.cmo -o play + +cd ${DESTDIR}/sw/simulator +${OCAMLC} -custom -I +lablgtk2 -I ${DESTDIR}/sw/lib/ocaml unix.cma str.cma xml-light.cma lablgtk.cma glibivy-ocaml.cma lib-pprz.cma gtkInit.cmo gaia.cmo -o gaia + +cd ${DESTDIR}/sw/tools +${OCAMLC} -custom -I +lablgtk2 -I ${DESTDIR}/sw/lib/ocaml unix.cma str.cma xml-light.cma ivy-ocaml.cma lib-pprz.cma fp_syntax.cmo fp_parser.cmo fp_lexer.cmo fp_proc.cmo gen_flight_plan.cmo -o gen_flight_plan.out diff --git a/debian/paparazzi-bin.prerm b/debian/paparazzi-bin.prerm new file mode 100755 index 0000000000..003de7bfdd --- /dev/null +++ b/debian/paparazzi-bin.prerm @@ -0,0 +1,18 @@ +#!/bin/sh + +set -e + +OCAMLC=ocamlc +DESTDIR=/usr/share/paparazzi + +rm -f ${DESTDIR}/sw/ground_segment/tmtc/server +rm -f ${DESTDIR}/sw/ground_segment/tmtc/messages +rm -f ${DESTDIR}/sw/ground_segment/tmtc/link + +rm -f ${DESTDIR}/sw/ground_segment/cockpit/gcs + +rm -f ${DESTDIR}/sw/logalizer/play + +rm -f ${DESTDIR}/sw/simulator/gaia + +rm -f ${DESTDIR}/sw/tools/gen_flight_plan.out diff --git a/debian/rules b/debian/rules index a4805d493e..4d4ce4c0a8 100644 --- a/debian/rules +++ b/debian/rules @@ -54,9 +54,7 @@ install: build dh_testroot dh_clean -k dh_installdirs - - # Add here commands to install the package. - $(MAKE) install PREFIX=$(CURDIR)/debian/paparazzi-bin/usr + $(MAKE) -f Makefile.install install_files PREFIX=$(CURDIR)/debian/paparazzi-bin # Build architecture-independent files here. diff --git a/sw/ground_segment/cockpit/Makefile b/sw/ground_segment/cockpit/Makefile index 7be45107cf..b7246580d6 100644 --- a/sw/ground_segment/cockpit/Makefile +++ b/sw/ground_segment/cockpit/Makefile @@ -36,18 +36,13 @@ MAIN=gcs CMO=$(ML:.ml=.cmo) CMX=$(ML:.ml=.cmx) -all : $(MAIN) map2d +all : $(MAIN) opt : $(MAIN).opt -# Only for backward compatibility: should disappear -map2d : gcs - [ -L $@ ] || [ -f $@ ] || ln -s $< $@ - - $(MAIN) : $(CMO) @echo OL $@ - $(Q)$(OCAMLC) $(OCAMLCFLAGS) -custom $(INCLUDES) $(LIBS) threads.cma gtkThread.cmo gtkInit.cmo $(CMO) -o $@ + $(Q)$(OCAMLC) $(OCAMLCFLAGS) -custom $(INCLUDES) unix.cma str.cma xml-light.cma $(LIBS) threads.cma gtkThread.cmo gtkInit.cmo $(CMO) -o $@ $(MAIN).opt : $(CMX) @echo OOL $@ diff --git a/sw/ground_segment/tmtc/Makefile b/sw/ground_segment/tmtc/Makefile index ce868f5c19..3c899ab94b 100644 --- a/sw/ground_segment/tmtc/Makefile +++ b/sw/ground_segment/tmtc/Makefile @@ -49,12 +49,12 @@ $(VAR)/boa.conf :$(CONF)/boa.conf messages : messages.cmo @echo OL $@ - $(Q)$(OCAMLC) -custom $(INCLUDES) -o $@ lablgtk.cma glibivy-ocaml.cma lib-pprz.cma gtkInit.cmo $^ + $(Q)$(OCAMLC) -custom $(INCLUDES) -o $@ unix.cma str.cma xml-light.cma lablgtk.cma glibivy-ocaml.cma lib-pprz.cma gtkInit.cmo $^ server : $(SERVERCMO) @echo OL $@ - $(Q)$(OCAMLC) -custom $(INCLUDES) -o $@ lablgtk.cma glibivy-ocaml.cma lib-pprz.cma $^ + $(Q)$(OCAMLC) -custom $(INCLUDES) -o $@ unix.cma str.cma xml-light.cma lablgtk.cma glibivy-ocaml.cma lib-pprz.cma $^ server.opt : $(SERVERCMX) @echo OOL $@ @@ -62,7 +62,7 @@ server.opt : $(SERVERCMX) link : modem.cmo link.cmo @echo OL $@ - $(Q)$(OCAMLC) -custom $(INCLUDES) -o $@ lablgtk.cma glibivy-ocaml.cma lib-pprz.cma multimon.cma $^ + $(Q)$(OCAMLC) -custom $(INCLUDES) -o $@ unix.cma str.cma xml-light.cma lablgtk.cma glibivy-ocaml.cma lib-pprz.cma multimon.cma $^ %.cmo : %.ml $(LIBPPRZCMA) diff --git a/sw/lib/ocaml/Makefile b/sw/lib/ocaml/Makefile index 3bd6a44226..17c0257546 100644 --- a/sw/lib/ocaml/Makefile +++ b/sw/lib/ocaml/Makefile @@ -44,19 +44,19 @@ opt : all lib-pprz.cmxa xlib-pprz.cmxa lib-pprz.cma : $(CMO) @echo OL $@ - $(Q)ocamlmklib -I +xml-light -o lib-pprz str.cma unix.cma xml-light.cma $^ + $(Q)ocamlmklib $(INCLUDES) -o lib-pprz $^ lib-pprz.cmxa : $(CMX) @echo OOL $@ - $(Q)ocamlmklib -o lib-pprz $^ + $(Q)ocamlmklib $(INCLUDES) -o lib-pprz $^ xlib-pprz.cma : $(XCMO) @echo OL $@ - $(Q)ocamlmklib -I +xml-light -o xlib-pprz $^ + $(Q)ocamlmklib $(XINCLUDES) -o xlib-pprz $^ xlib-pprz.cmxa : $(XCMX) @echo OOL $@ - $(Q)ocamlmklib -I +xml-light -o xlib-pprz $^ + $(Q)ocamlmklib $(XINCLUDES) -o xlib-pprz $^ xml_get.out : lib-pprz.cma xml_get.cmo @echo OL $@ diff --git a/sw/logalizer/Makefile b/sw/logalizer/Makefile index 4774d3a917..1f6ce1504c 100644 --- a/sw/logalizer/Makefile +++ b/sw/logalizer/Makefile @@ -20,16 +20,14 @@ # Boston, MA 02111-1307, USA. # -OCAMLC = ocamlc -I +xml-light +OCAMLC = ocamlc OCAMLOPT = ocamlopt +INCLUDES= -I +xml-light all: play +play : play.ml + $(OCAMLC) $(INCLUDES) -custom -o $@ unix.cma str.cma xml-light.cma glibivy-ocaml.cma -I +lablgtk2 -I ../lib/ocaml lablgtk.cma lib-pprz.cma gtkInit.cmo $^ + clean: rm -f *.opt *.out *~ core *.o *.bak .depend *.cm* play - -play : play.ml - $(OCAMLC) -custom -o $@ unix.cma glibivy-ocaml.cma -I +lablgtk2 -I ../lib/ocaml lablgtk.cma lib-pprz.cma gtkInit.cmo $^ - -plot_adc : plot_adc.c - gcc -Wall `pkg-config gtk+-2.0 --cflags` -o plot_adc plot_adc.c `pkg-config gtk+-2.0 --libs` -lgtkdatabox -lglibivy -lpcre diff --git a/sw/simulator/Makefile b/sw/simulator/Makefile index a7c315b9d3..6e5cf6f8ef 100644 --- a/sw/simulator/Makefile +++ b/sw/simulator/Makefile @@ -55,7 +55,7 @@ sitl.cmxa : $(SIMSCMX) gaia : gaia.cmo @echo OL $@ - $(Q)$(OCAMLC) -custom $(INCLUDES) -o $@ glibivy-ocaml.cma lib-pprz.cma lablgtk.cma gtkInit.cmo $< + $(Q)$(OCAMLC) -custom $(INCLUDES) -o $@ unix.cma str.cma xml-light.cma glibivy-ocaml.cma lib-pprz.cma lablgtk.cma gtkInit.cmo $< %.cmo : %.ml ../lib/ocaml/lib-pprz.cma @echo OC $< diff --git a/sw/tools/Makefile b/sw/tools/Makefile index 3be9bf617c..f7196b7454 100644 --- a/sw/tools/Makefile +++ b/sw/tools/Makefile @@ -30,12 +30,12 @@ OCAMLYACC=ocamlyacc all: gen_aircraft.out gen_airframe.out gen_messages.out gen_ubx.out gen_flight_plan.out gen_radio.out extract_makefile.out gen_periodic.out gen_settings.out -FP_CMO = fp_syntax.cmo fp_parser.cmo fp_lexer.cmo fp_proc.cmo gen_flight_plan.ml +FP_CMO = fp_syntax.cmo fp_parser.cmo fp_lexer.cmo fp_proc.cmo gen_flight_plan.cmo ABS_FP = $(FP_CMO:%=$$PAPARAZZI_SRC/sw/tools/%) gen_flight_plan.out : $(FP_CMO) ../lib/ocaml/lib-pprz.cma @echo OL $@ - $(Q)$(OCAMLC) $(INCLUDES) -custom -o $@ ivy-ocaml.cma lib-pprz.cma $^ + $(Q)$(OCAMLC) $(INCLUDES) -custom -o $@ unix.cma str.cma xml-light.cma ivy-ocaml.cma lib-pprz.cma $^ fp_parser.cmo : fp_parser.cmi fp_syntax.cmi fp_parser.cmi : fp_parser.ml fp_syntax.cmi @@ -47,9 +47,9 @@ fp_syntax.cmo : fp_syntax.cmi %.out : %.ml @echo OC $< - $(Q)$(OCAMLC) $(INCLUDES) -o $@ ivy-ocaml.cma lib-pprz.cma $< + $(Q)$(OCAMLC) $(INCLUDES) -o $@ unix.cma str.cma ivy-ocaml.cma xml-light.cma lib-pprz.cma $< @cat ../../pprz_src_test.sh > $@ - @echo '$(OCAML) -I +xml-light -I $$PAPARAZZI_SRC/sw/lib/ocaml ivy-ocaml.cma lib-pprz.cma $$PAPARAZZI_BIN/$< $$*' >> $@ + @echo '$(OCAML) -I +xml-light -I $$PAPARAZZI_SRC/sw/lib/ocaml unix.cma str.cma ivy-ocaml.cma xml-light.cma lib-pprz.cma $$PAPARAZZI_BIN/$< $$*' >> $@ @chmod a+x $@ %.cmo : %.ml ../lib/ocaml/lib-pprz.cma