Commit Graph

43 Commits (1659f0dc8bcf6e55c4ac45f9baea822c7991bd38)

Author SHA1 Message Date
Juraj Oršulić c370d221d0 Windows build fixes & Azure CI (#1463)
This PR makes libcartographer build on Windows (including tests). Abseil was bumped to avoid a MSVC compiler bug.

I have observed two tests failing:
`MapBuilderTestByGridType/MapBuilderTestByGridType.GlobalSlam2D/1` and `MapBuilderTestByGridType/MapBuilderTestByGridType.LocalizationOnFrozenTrajectory2D/1`.
2018-12-16 17:04:23 +01:00
amikholap b7fb299d1a Better Abseil library order (#1458)
Got linker error for Abseil in the build env due to imprecise library order.
Worked fine on the dev machine though.
Maybe helps someone.

https://pastebin.com/raw/AEKPBt1n
2018-11-06 17:50:19 +01:00
Michael Grupp d0348634b2 Enable -Wthread-safety for Clang and CMake. (#1403)
https://cmake.org/cmake/help/v3.2/variable/CMAKE_LANG_COMPILER_ID.html
2018-10-19 08:28:54 +02:00
Alexander Belyaev bdb6f2db4a
[ABSL] Use flat_hash_map instead of unordered_map. (#1439) 2018-10-08 10:47:28 +02:00
Alexander Belyaev 6274fc1558 [ABSL] Use absl::Substitute in rigid_transform debug messages. (#1373)
it is at least readable.
2018-08-07 12:50:37 +02:00
Arno Fleck 12e11856af Use absl::Mutex instead of custom implementation (#1356)
Makes `common::Mutex` an alias for `absl::Mutex` and replaces the logic inside `common::MutexLocker` with `absl::MutexLock`.

A future PR can then remove these classes entirely and replace references to it across the Cartographer code base with the Abseil classes directly.
2018-08-03 11:15:50 +02:00
Juraj Oršulić 0a10bc3a15 Make standalone_absl imported target global. (#1351) 2018-07-30 13:06:15 +02:00
Juraj Oršulić b1855d0d06 Fix Abseil build command (#1350)
@pifon2a I've noticed the `BUILD_COMMAND` is broken. You're setting `ABSL_BUILD_COMMAND`, but using `ABSEIL_BUILD_COMMAND` (effectively empty). Somehow this doesn't confuse newer CMakes, but the one you install on Trusty gets confused and interprets this as a no-op build step. This causes the indigo pipeline in cartographer_ros to fail.

Use the cross-platform build command instead: 
https://cmake.org/cmake/help/latest/module/ExternalProject.html#obtaining-project-properties (just above the linked paragraph)
2018-07-28 17:42:09 +02:00
Juraj Oršulić 27a7a3dbdf FindAbseil.cmake: cross-platform library names (#1348)
Fixes #1347
2018-07-27 23:41:25 +02:00
Alexander Belyaev 4990d4d5e9
[ABSL] Purge common::optional. (#1339) 2018-07-27 19:05:45 +02:00
Alexander Belyaev e3a7f39889
Add absl to CMake and Bazel builds. (#1301) 2018-07-26 06:49:37 +02:00
Alexander Belyaev 926b8540f6
Use CMake 3.2. (#1332) 2018-07-25 21:40:06 +02:00
gaschler e2966ca156 Do not install gmock (#1047)
Fixes the issue described in https://github.com/googlecartographer/cartographer/pull/1041.

The docker file is not to be merged, it is only here to help reproducing the issue and fix.
2018-04-11 13:48:03 +02:00
Juraj Oršulić ae05658ff7 Work around FindGMock/Catkin target name clash (#1011)
Handle case with multiple invocations (avoid pasting ${CMAKE_THREAD_LIBS_INIT} multiple times).
Also check if target 'gmock' already exists before building GMock to avoid failures if GMock was already
find_packaged() from another subproject.

FIXES=https://github.com/googlecartographer/cartographer_ros/issues/776
2018-03-26 14:23:32 +02:00
gaschler 5c694adf93 Correct cmake install (#739)
Simplify how file lists are collected depending on options.
Omits gRPC headers if they were not built.
2017-12-06 20:34:07 +01:00
Christoph Schütte c233aaaac8 Update CMakeLists.txt to preprare for gRPC deps. (#691) 2017-11-22 16:29:01 +01:00
Holger Rapp 5363285b8f CMake bug fixes and performance improvements. (#648)
- Pin versions of Ceres and protobuf (Fixes #341).
- Require Lua >= 5.2 (Fixes #629).
- No longer run ceres tests in CI. We implicitly test Ceres through Cartographer's tests and this saves ~4 minutes on CI.
2017-11-10 12:55:43 +01:00
Holger Rapp 481211073f Build relocatable code. (#413)
This is required to reuse code from cartographer_ros in cartographer_rviz. Otherwise linking fails with errors like these:

~~~
/usr/bin/ld: libcartographer_ros.a(msg_conversion.cc.o): relocation R_X86_64_32S against `_ZNSs4_Rep20_S_empty_rep_storageE' can not be use
d when making a shared object; recompile with -fPIC
~~~

While this could be fixed locally in cartographer_ros, it is a reasonable default to compile with `-fPIC` always.
2017-07-20 14:31:50 +02:00
Jochen Sprickerhof e345ae8280 Support compiling with CMAKE_BUILD_TYPE set to None (#405)
Debian defaults to setting CMAKE_BUILD_TYPE to None and setting CFLAGS
and alike to Debian standards.
2017-07-17 10:34:14 +02:00
Jochen Sprickerhof 12b3cc0d7b Support new Debian version of gmock and add testing for debian systems (#236) 2017-05-04 12:47:12 +02:00
Wolfgang Hess 6d2feaa8c7 Build and run all tests found by the glob. (#258) 2017-05-03 16:55:13 +02:00
Holger Rapp 1cdcd12a8b Make missing case statements an error. (#245) 2017-05-02 16:56:10 +02:00
Juraj Oršulić 2854c485ef Enable building in Debug mode if the user really wants this (#230)
Also inform the user about slow performance if they do this.
2017-03-30 17:00:50 +02:00
Juraj Oršulić 370e1e52df Enable adding as a CMake subproject (#203)
This is done by replacing CMAKE_*_DIR variables with PROJECT_*_ variables so
that CMake uses correct paths when libcartographer is a subproject

Move AllFiles.cmake into the project binary dir instead of the root CMake binary dir,
use a project-dependent detect_changes target name

This makes overriding it from an upper level CMakeLists.txt possible, which is required
when doing a super-build which doesn't require installing libcartographer.
2017-02-09 15:57:54 +01:00
Damon Kohler 5d56b3190e Rerun CMake when files are added/removed. (#170) 2016-12-21 12:05:15 +01:00
Damon Kohler 4e9c3d69b5 Build all our source files into a single library. (#164) 2016-12-20 11:24:08 +01:00
Wolfgang Hess 3caf5a4b52 Fix the target_include_directories. (#162)
The Boost include directory was not correctly added, and the
headers of the project where always looked up at the source or
build directory, not where they are installed.
2016-12-14 17:54:53 +01:00
Wolfgang Hess ae490c540d Revert to workaround #158. (#160)
Currently, on xenial/kinetic the transitive dependencies on
libcartographer and its dependencies are not duplicated after
each library that depends on it in the linker command.
2016-12-13 13:57:05 +01:00
Wolfgang Hess efe700a9f3 Fix link dependencies. (#159)
Add dependencies via target_link_libraries as PUBLIC.
It seems the new behavior which defaults to PRIVATE was
used implicitly causing transitive dependencies to be
omitted.
2016-12-12 14:56:54 +01:00
Damon Kohler 78f5e2f088 Reorder dependency linking to fix Kintetic. (#158) 2016-12-09 14:45:52 +01:00
Damon Kohler 03c8e8d195 Replace USES_ROS through Catkin auto-detection. (#128) 2016-11-17 11:01:46 +01:00
Wolfgang Hess 1081473be9 Fix FindGMock.cmake and the CMake modules installation. (#112) 2016-10-28 15:43:13 +02:00
Atsushi Watanabe f45eaa9c67 Supports system-wide installed GMock (#105)
This commit fixes #73.
Tested using docker ubuntu:trusty and native Fedora 24 with gmock 1.8.
2016-10-28 12:23:21 +02:00
Holger Rapp 6e6d2decaa Fixes for Xenial. (#103)
- Remove use of get_property(LOCATION in cmake where this is easy. This
  reduces build warnings sufficiently to not drown out other important
  information.
- Mark cairo a dependency in package.xml so rosdep pulls it in.

Tested using docker -t ros:kinetic, which is based on Xenial.
2016-10-26 14:23:00 +02:00
Wolfgang Hess 5b16f4bcb6 Simplify 3D visualization code. (#88)
Removes the non-const Submaps accessor.
Adds -Werror=missing-braces.
2016-10-20 11:29:12 +02:00
Holger Rapp 15b58766f5 Use pkg-config variables for yaml-cpp. (#84)
Related to googlecartographer/cartographer_ros#117.
2016-10-19 17:11:31 +02:00
Holger Rapp c2aed53ce8 Adds a points processing pipeline and a XRay creator. (#66)
- Adds cairo as required dependency.
- Adds an 'io' module.
2016-10-14 15:14:46 +02:00
Holger Rapp edff6a1e24 Remove all mentions of ZLIB. (#49)
We do not actually use zlib anywhere anymore.
2016-10-13 12:33:27 +02:00
Holger Rapp 8f64860b5d Preparing changes to use automatic CMakeFiles also in the ROS projects. (#48) 2016-10-12 17:03:46 +02:00
Holger Rapp be813a06fe Prepare CMake files for testing support. (#47)
- Only build gmock if we really require testing.
- Adds a wrapper for generating catkin aware tests. This works around
  ros/catkin#830.
2016-10-12 15:38:12 +02:00
Holger Rapp 8e7996f015 Extend CMake functions for reuse in other Cartographer subprojects. (#45)
- Change CARTOGRAPHER_LIBRARIES to be absolute path to adhere to the
  CMake documentation.
2016-10-12 13:39:03 +02:00
Holger Rapp eeb17bf055 Adds google_binary to create installable binaries. (#43)
- Do not link in Ceres if gflags or glog is used, but still rely on ceres
  to find those libraries for us.
- Update CMakeLists with new settings.
2016-10-11 15:18:59 +02:00
Damon Kohler 269c28cb0c Moves the contents of the cartographer subdirectory up one level. 2016-08-03 12:48:29 +02:00