Commit Graph

129 Commits

Author SHA1 Message Date
Lorenz Meier 05c7a0683d Re-add missing ease-of-use make targets 2015-09-12 15:44:05 +02:00
James Goppert 54f8dd2f4d Support parallel building through -j flag in makefile. 2015-09-12 01:33:36 -04:00
Lorenz Meier 6eb4d015fd Bring back user-friendly Makefile for non-Ubuntu users 2015-09-12 01:39:57 +02:00
Mark Charlebois e4b9212e96 cmake: Updated makefie to show the available build configs
Also fixed param support for nuttx and qurt

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-09-11 16:15:48 -07:00
James Goppert 298fbf0080 Added more targets to phony. 2015-09-11 13:52:14 -04:00
James Goppert 8bc81d985f Fixed typo in version, exposed some more useful cmake targets. 2015-09-11 00:24:30 -04:00
James Goppert 0e8cc821a9 More config cleanup. 2015-09-11 00:15:33 -04:00
James Goppert 07851b79c2 Work on config only for cmake arguments. 2015-09-10 23:43:59 -04:00
James Goppert a2615d793e Put warning on spacing in makefile. 2015-09-10 21:20:49 -04:00
James Goppert 2c33f4921c Add makefile magic to simplify maintenance. 2015-09-10 21:15:55 -04:00
Mark Charlebois a456b6a1c6 Added missing Makefile update
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-09-10 16:25:30 -07:00
James Goppert b073edc684 Set makefile default target explicity. 2015-09-10 14:08:03 -04:00
James Goppert 34eeee9fa9 Added defautl config for nuttx, nuttx now works over usb. 2015-09-10 13:57:54 -04:00
James Goppert cadc7280b7 Fixed makefile upload link. 2015-09-10 03:05:17 -04:00
James Goppert 323ae36d9f Added nuttx sim config. 2015-09-09 23:07:30 -04:00
James Goppert bf18c84652 Cleanup of module building. 2015-09-09 23:00:58 -04:00
Mark Charlebois 9c376119d0 cmake: changes required for qurt build
Fixed CMakeLists.txt to be consistent with module.mk
Converted PX4_TICKS_PER_SEC to define for QURT to get around relocation error
Added stubs for QURT so building a full executable can be tested. This will
enable CI testing without the full Hexagon SDK.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-09-09 13:24:29 -07:00
James Goppert b6b25f2ad1 Nuttx sim support. 2015-09-09 08:18:41 -04:00
Mark Charlebois 7e1c984234 Hack to get posix build partially working
Created a dummy build_git_version.h so I did not have to figure out
how to generate it.

Commented out topic_listener.cpp from src/systemcmds/CMakeLists.txt
because it depends on a generated cpp file.

Link doesn't work mut many modules build

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-09-08 15:39:13 -07:00
James Goppert 1d6b31d196 Switch to cmake build system. 2015-09-07 20:37:45 -04:00
Daniel Agar 3b0390d432 cleanup 'make check_format and exclude directories not ready for formatting
-uORB, sdlog2, vtol_att_control, ekf_att_pos_estimator
2015-09-05 12:12:52 -04:00
Daniel Agar 5391e8a24f unittests trivial cleanup
-add -Qunused-arguments for clang
-update to a recent cmake
-comment unused variables
2015-08-29 20:43:00 -04:00
Mark Charlebois 3a47434749 Fixes for qurt HIL build
Workaround required Eigen downgrade to 3.2. Hexagon toolchain does
not support C++11 features of newest version of Eigen.

Running make qurt_fixup will downgrade and patch Eigen for qurt.
Running make restore will revert the patch and do a git submodule update
to restore the expected Eigen version.

Added a "restore" target to undo qurt_fixup

Before doing a qurt build run:

    make qurt_fixup

That will downgrade Eigen to 3.2 and apply the require patch.
To build another target after downgrading:

    make restore

Them make the desired target (other than qurt).

Fixed type used in orb_priority to be consistent with the code
(int* was used in declaration but int32_t* used in code)

Removed unused class member variable in sensors.cpp

Added cmake fix for unit tests. The location of px4_log.c changed.

Fixed the qurt drv_hrt.c implementation to use us instead of ms for time resolution

Added px4_led.c to nuttx platform layer
Use the posix version of px4_led.c for nuttx so we don't end up with
duplicate files. It was moved out of common because it is not used by qurt.

Changed PX4_DEBUG to PX4_WARN when checking for the error condition for store_poll_waiter in vdev.cpp

Updated the px4_log.h file to make calls to the qurt_log functions.
The qurt_log function is defined in the platforms/qurt layer.

Added an option to control starting the commander module in HIL mode.

Moved the flight specific drivers to the configuration file instead of adding them
to the common tool chain file because HIL mode does not need them.

Added the uorb Subscriber and Publisher classes

Call PX4_ISFINITE macro instead of isfinite().

Added px4_led.c to nuttx platform layer
Use the posix version of px4_led.c for nuttx so we don't end up with duplicate files.
It was moved out of common because it is not used by qurt.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-08-25 21:59:01 -07:00
devbharat 9a6f52736b Added launchfile to launch gazebo iris and mavros bridge. Added sitl_gazebo to makefile and new init rc file for gazebo iris apps and params 2015-07-23 15:45:59 +02:00
Lorenz Meier 7277d390c4 Merge branch 'beta' 2015-07-12 15:52:02 +02:00
Lorenz Meier cdc17f1fdd Keep temporary topic files to avoid constant re-generation, but delete them on clean 2015-07-12 15:51:43 +02:00
Lorenz Meier 48c356fb2b Fix parallel build for POSIX / QuRT 2015-07-05 12:06:45 +02:00
Lorenz Meier 52687cb8e1 Rename make sitlrun to make sitl_quad 2015-07-04 07:25:08 -07:00
Mark Charlebois 26d2589e97 makefile cleanup
Moved nuttx specific make rules to files in makefiles/nuttx.

All target specific makefiles are in their target sub directories.

To minimize file duplication, targets that share rules include a
common file. For example the posix and posix-arm targets both use
makefiles/posix/posix_elf.mk

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-06-16 09:58:48 -07:00
Mark Charlebois 729653ba71 SITL: changed posix_default to posix_sitl
The SITL build is now the default posix build.

The linker script for posix was moved to makefiles/posix.
The rc.S file was moved to posix-configs/SITL/init/
The POSIXTEST board definition is now SITL

To run the SITL test run:

make sitlrun

This replaces the make posixrun target.

The build directory is now Build/posix_sitl.build/

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-06-15 09:51:07 -07:00
David Sidrane 447b93c090 Add size Makefile target for elf 2015-06-13 06:07:57 -10:00
David Sidrane 428611119f Merged GIT version changes 2015-06-12 19:32:55 +02:00
David Sidrane 17fddb1556 Back Port of Git Versioning - without side effects Part 1 2015-06-12 06:49:15 -10:00
Mark Charlebois 58e263d534 Added posix-arm target and refactored toolchain_* files
The toolchain_* files are target OS specific so they were moved to
the target OS subdir.

The gcc_version.* files are only cleared once per make instantiation so
a build that creates multiple HW targets will try to link with an
incompatible .o file (i.e. x86 build linking ARM .o).  I created
posix-arm as a separate target to fix this problem.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-06-08 22:21:59 -07:00
Mark Charlebois 77cc3cdde1 Remove Build/git_version.* on each make
The Build/git_version.d and Build/git_version.o files need to be
removed on each make to prevent confusion from a previously
generated dependency file for a different target.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-05-27 19:50:39 -07:00
Mark Charlebois d4749551da git_version.* not removed on clean
The Build/git_version.* files need to be removed on make clean.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-05-27 19:30:05 -07:00
Lorenz Meier 92f67a923a Make sure the build directory exists 2015-05-27 19:54:46 +02:00
Lorenz Meier 8fd00f4d6d Merged release_v1.0.0 into master 2015-05-23 11:07:10 +02:00
Lorenz Meier ccac324f5b mavlink: Fix GIT string transmission 2015-05-23 11:04:19 +02:00
Lorenz Meier 0d134aac53 systemlib: Use build directory for git version 2015-05-23 10:18:20 +02:00
Lorenz Meier 6d7e063148 Added GIT version which recompiles on each build 2015-05-23 09:59:46 +02:00
Mark Charlebois 2d22e8325d Fix double build when using new make target syntax
When make is invoked as "make posix posix_default"
it will build the posix_default target twice. The Makefile was
fixed to correct this.

If "make posix" is run, the Makefile still calls "make PX4_TARGET_OS=posix".

If "make posix posix_default" is run, the posix target just exports
PX4_TARGET_OS=posix and then make evaluates the next goal (posix_default).

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-05-21 13:45:53 -07:00
Mark Charlebois 43345e29dc Makefile multi-target support
NuttX is still the default target and all NuttX configs can still
be built with:

make

Individual NuttX, POSIX, and QuRT configs can now be built more
easily by specifying the target and configs:

make posix posix_default
make qurt qurt_hello
make nuttx aerocore_default

Running make with just the target will make all the configs for
that target:

make nuttx
make qurt
make posix

The help is also target specific:
make nuttx help
make qurt help
make posix help

"make help" will still assume you want help for the NuttX target

Added a new QuRT config called qurt_hello as a sample config to
test buiding in different commands for separate configs.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-05-20 19:19:08 -07:00
Mark Charlebois 9f391b1867 NuttX: fixes for NuttX build
In the upstream tree ringbuffer.h includes the method implementations
in the header file which causes multiple definitions in the link for
other targets. Changed so ringbuffer.cpp is build separately for other
platforms and is included by ringbuffer.h on NuttX.

uORB changes do not link without uORBTest_UnitTest.cpp enabled for
the NuttX build.

px4_getopt was not exported and wasn't visible in NuttX build.

The makefiles were restored to be as close as possible to upstream
so the NuttX build builtin's work again. The code will have to be
refactored after the merge.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-05-15 12:56:18 -07:00
Mark Charlebois 6a439f7ddc QuRT: Hello world app for QuRT
DSPAL for QuRT is still missing the pthreads exports and there is no
exported sleep function. These functions are stubbed out for the time being.

This is based on the 6.4.05 version of the Hexagon tools.

The Hexagon tools and DSPAL are needed to build the qurt target.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-04-22 08:48:48 -07:00
Mark Charlebois 19162ba5be Posix: Changed PreflightCheck to read Vdev
PreflightCheck was failing because it was trying to read actual
devices instad of virtual devices.

ADCSIM had a LINUXTEST ifdef that was removed.

posix_run.sh was using the wrong path

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-04-21 17:14:52 -07:00
Mark Charlebois f3b5076d70 Linux to posix conversion
Changed "linux" target to "posix". Most of the changes are shared with
QuRT and with OSX. The Linux specific parts are in for i2c which uses
<linux/i2c.h> and <linux/i2c-dev.h>.

There is also a check for __PX4_LINUX in mavlink for a tty ioctl that is
not supported.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-04-21 09:53:09 -07:00
Mark Charlebois 6ce0b7b753 QuRT: added missing make pieces
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-04-20 11:37:51 -07:00
Mark Charlebois cf71db74d7 Support to specify build time OS target
Now run:

make PX4_TARGET_OS=nuttx

or

make PX4_TARGET_OS=linux

To test the linux build and make sure that the required directories
exist, run:

make linuxrun

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-04-20 11:16:26 -07:00
Mark Charlebois 2cd44a24ea Linux: Added linker script support for param and added mc_att_control
Added linker script to resolve __param_start and __param_end.

Added mc_att_control to list of supported builtins.

Signed-off-by: Mark Charlebois <charlebm@gmail.com>
2015-04-20 11:16:26 -07:00