[Fawkes Git] branch/timn/freebsd-fixes: created (0.5.0-3471-g04dc8d6)

Tim Niemueller niemueller at kbsg.rwth-aachen.de
Thu Dec 22 21:36:26 CET 2016


Changes have been pushed for the project "Fawkes Robotics Software Framework".

Gitweb: http://git.fawkesrobotics.org/fawkes.git
Trac:   http://trac.fawkesrobotics.org

The branch, timn/freebsd-fixes has been created
        at  04dc8d6ec56db636905a90dd48bdedf353458270 (commit)

http://git.fawkesrobotics.org/fawkes.git/timn/freebsd-fixes

- *Log* ---------------------------------------------------------------
commit 56fc23ce27fbbeb3eaf837d12a0b8c1bc8813180
Author:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
AuthorDate: Thu Dec 22 20:55:50 2016 +0100
Commit:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
CommitDate: Thu Dec 22 20:55:50 2016 +0100

    buildsys: allow Boost sub-library specific cflags/ldflags

http://git.fawkesrobotics.org/fawkes.git/commit/56fc23c
http://trac.fawkesrobotics.org/changeset/56fc23c

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
commit ccb3f3b1803cebe35876f3defdda86f668180def
Author:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
AuthorDate: Thu Dec 22 20:56:15 2016 +0100
Commit:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
CommitDate: Thu Dec 22 20:56:15 2016 +0100

    buildsys: for Boost up to 1.55 and clang ignore some warnings
    
    There is a bug up until Boost 1.55 which triggers a clang warning.
    However, we do not trigger this issue and FreeBSD comes with 1.55, hence
    ignore this specific warning in that situation. The situation will
    improve once newer Boost versions are available.

http://git.fawkesrobotics.org/fawkes.git/commit/ccb3f3b
http://trac.fawkesrobotics.org/changeset/ccb3f3b

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
commit e459ceb1e8f4266d455495715a21a6ae501abffe
Author:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
AuthorDate: Thu Dec 22 20:58:03 2016 +0100
Commit:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
CommitDate: Thu Dec 22 20:58:03 2016 +0100

    buildsys: fix compile flags for CGAL with clang
    
    The rounding math option is not available and the local unused typedef
    warning must be ignored for the code to compile.

http://git.fawkesrobotics.org/fawkes.git/commit/e459ceb
http://trac.fawkesrobotics.org/changeset/e459ceb

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
commit 3d371bfccfe242ab2aabca463d0d721153ec2641
Author:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
AuthorDate: Thu Dec 22 20:58:47 2016 +0100
Commit:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
CommitDate: Thu Dec 22 20:58:47 2016 +0100

    buildsys: do not use MFLAGS to pass make flags
    
    This causes problems with the GNU Make 4.2 about jobserver settings not
    properly passed. Since this was a backward compatibility variable only
    anyway and it works without.

http://git.fawkesrobotics.org/fawkes.git/commit/3d371bf
http://trac.fawkesrobotics.org/changeset/3d371bf

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
commit 8d05708bd29c3875012a5d6b29f3d175f977f649
Author:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
AuthorDate: Thu Dec 22 21:07:56 2016 +0100
Commit:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
CommitDate: Thu Dec 22 21:07:56 2016 +0100

    baseapp: add indirectly used Boost asio
    
    Get proper compile flags for Boost Asio.

http://git.fawkesrobotics.org/fawkes.git/commit/8d05708
http://trac.fawkesrobotics.org/changeset/8d05708

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
commit 6c39a3ab4a1755749ed05f81fab1643d222fd50e
Author:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
AuthorDate: Thu Dec 22 21:19:03 2016 +0100
Commit:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
CommitDate: Thu Dec 22 21:19:03 2016 +0100

    gossip: add indirectly used Boost asio
    
    Get proper compile flags for Boost Asio.

http://git.fawkesrobotics.org/fawkes.git/commit/6c39a3a
http://trac.fawkesrobotics.org/changeset/6c39a3a

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
commit d78cfc1134491069df23685477a98d7111a1ebd8
Author:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
AuthorDate: Thu Dec 22 21:25:17 2016 +0100
Commit:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
CommitDate: Thu Dec 22 21:25:17 2016 +0100

    libbaseapp: destroy main thread later
    
    On exit of fawkes the main loop aspect needs to access the main loop
    employer, which is the main thread, to reset the main loop. The main
    thread was destroyed too early leading to a segfault if another main
    loop was registered, e.g., through ttmainloop.

http://git.fawkesrobotics.org/fawkes.git/commit/d78cfc1
http://trac.fawkesrobotics.org/changeset/d78cfc1

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
commit 1c2be60a1f799801d705b070672acbf7de751037
Author:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
AuthorDate: Thu Dec 22 21:27:00 2016 +0100
Commit:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
CommitDate: Thu Dec 22 21:27:00 2016 +0100

    libconfig: add missing includes for YAML config
    
    Required with inet_pton() on FreeBSD.

http://git.fawkesrobotics.org/fawkes.git/commit/1c2be60
http://trac.fawkesrobotics.org/changeset/1c2be60

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
commit 222c778ae95fb43481a55d413c98a694bb5fae7d
Author:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
AuthorDate: Thu Dec 22 21:27:28 2016 +0100
Commit:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
CommitDate: Thu Dec 22 21:27:28 2016 +0100

    fvutils: fix invalid call in JPEG compressor
    
    Instead of calling the underlying implementation the compressor
    errorneously called itself for one method that would lead to an endless
    recursion.

http://git.fawkesrobotics.org/fawkes.git/commit/222c778
http://trac.fawkesrobotics.org/changeset/222c778

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
commit 91ed9344f990a33b60e8b317e9cadddd3ff2452c
Author:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
AuthorDate: Thu Dec 22 21:28:19 2016 +0100
Commit:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
CommitDate: Thu Dec 22 21:28:19 2016 +0100

    fvutils: fix seemingly ambiguous use of std::abs
    
    A clang/libc++ complaint on FreeBSD.

http://git.fawkesrobotics.org/fawkes.git/commit/91ed934
http://trac.fawkesrobotics.org/changeset/91ed934

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
commit ad96d9f0940f3ad5d6deb7ffc10d13bfc145eb7f
Author:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
AuthorDate: Thu Dec 22 21:28:55 2016 +0100
Commit:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
CommitDate: Thu Dec 22 21:28:55 2016 +0100

    netcomm: fix ambiguous template parameter name
    
    The template parameter conflicted with a new enum type name.

http://git.fawkesrobotics.org/fawkes.git/commit/ad96d9f
http://trac.fawkesrobotics.org/changeset/ad96d9f

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
commit 66682355753e248a66c628f2884f14047feb539c
Author:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
AuthorDate: Thu Dec 22 21:29:25 2016 +0100
Commit:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
CommitDate: Thu Dec 22 21:29:25 2016 +0100

    netcomm: add missing include for clang/libc++

http://git.fawkesrobotics.org/fawkes.git/commit/6668235
http://trac.fawkesrobotics.org/changeset/6668235

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
commit 04dc8d6ec56db636905a90dd48bdedf353458270
Author:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
AuthorDate: Thu Dec 22 21:29:39 2016 +0100
Commit:     Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
CommitDate: Thu Dec 22 21:29:39 2016 +0100

    amcl: fix ambiguous use of std::abs with clang/libc++

http://git.fawkesrobotics.org/fawkes.git/commit/04dc8d6
http://trac.fawkesrobotics.org/changeset/04dc8d6

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -


- *Summary* -----------------------------------------------------------
 etc/buildsys/boost.mk                          |    7 +++++++
 etc/buildsys/cgal.mk                           |    8 +++++++-
 etc/buildsys/rules.mk                          |    2 +-
 src/libs/baseapp/Makefile                      |    2 +-
 src/libs/baseapp/run.cpp                       |    2 +-
 src/libs/config/yaml.cpp                       |    2 ++
 src/libs/fvutils/compression/jpeg_compressor.h |    2 +-
 src/libs/fvutils/statistical/imagediff.cpp     |    2 +-
 src/libs/netcomm/socket/socket.h               |    6 +++---
 src/libs/netcomm/utils/resolver_thread.h       |    1 +
 src/plugins/amcl/amcl_thread.cpp               |    2 +-
 src/plugins/gossip/aspect/Makefile             |    2 +-
 12 files changed, 27 insertions(+), 11 deletions(-)


- *Diffs* -------------------------------------------------------------

- *commit* 56fc23ce27fbbeb3eaf837d12a0b8c1bc8813180 - - - - - - - - - -
Author:  Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
Date:    Thu Dec 22 20:55:50 2016 +0100
Subject: buildsys: allow Boost sub-library specific cflags/ldflags

 etc/buildsys/boost.mk |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

_Diff for modified files_:
diff --git a/etc/buildsys/boost.mk b/etc/buildsys/boost.mk
index 3317dee..1bb0f49 100644
--- a/etc/buildsys/boost.mk
+++ b/etc/buildsys/boost.mk
@@ -30,8 +30,8 @@ boost-find-include = $(firstword $(wildcard $(foreach i,$(BOOST_INCLUDE_DIRS) /u
 boost-have-include = $(if $(call boost-find-include,$1),1)
 boost-have-libfile = $(if $(wildcard $(foreach l,$(BOOST_LIB_DIRS),$(foreach s,$(BOOST_LIBRARY_SUFFIXES),$l/libboost_$1$(subst NOSUFFIX,,$s).$(SOEXT) ))),1)
 boost-have-lib     = $(if $(or $(call boost-have-libfile,$1),$(call boost-have-include,$(1).hpp)),1)
-boost-lib-cflags   = $(addprefix -I,$(wildcard $(BOOST_INCLUDE_DIRS)))
-boost-lib-ldflags  = $(addprefix -lboost_,$(foreach l,$(BOOST_LIB_DIRS),$(foreach s,$(BOOST_LIBRARY_SUFFIXES),$(if $(wildcard $l/libboost_$1$(subst NOSUFFIX,,$s).$(SOEXT)),$1$(subst NOSUFFIX,,$s) ))))
+boost-lib-cflags   = $(addprefix -I,$(wildcard $(BOOST_INCLUDE_DIRS))) $(BOOST_CFLAGS_$1)
+boost-lib-ldflags  = $(addprefix -lboost_,$(foreach l,$(BOOST_LIB_DIRS),$(foreach s,$(BOOST_LIBRARY_SUFFIXES),$(if $(wildcard $l/libboost_$1$(subst NOSUFFIX,,$s).$(SOEXT)),$1$(subst NOSUFFIX,,$s) )))) $(BOOST_LDFLAGS_$1)
 
 boost-have-libs    = $(if $(strip $(subst 1,,$(foreach l,$1,$(or $(call boost-have-lib,$l),0)))),,1)
 boost-libs-cflags  = $(foreach l,$1,$(call boost-lib-cflags,$l))

- *commit* ccb3f3b1803cebe35876f3defdda86f668180def - - - - - - - - - -
Author:  Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
Date:    Thu Dec 22 20:56:15 2016 +0100
Subject: buildsys: for Boost up to 1.55 and clang ignore some warnings

 etc/buildsys/boost.mk |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)

_Diff for modified files_:
diff --git a/etc/buildsys/boost.mk b/etc/buildsys/boost.mk
index 1bb0f49..0a0f69e 100644
--- a/etc/buildsys/boost.mk
+++ b/etc/buildsys/boost.mk
@@ -47,6 +47,13 @@ endif
 
 boost-version-create = $(shell echo $$(($1 * 100000 + $2 * 100 + $3)))
 boost-version-atleast = $(shell echo $$(($(BOOST_VERSION) >= $1 * 100000 + $2 * 100 + $3)))
+boost-version-atmost = $(shell echo $$(($(BOOST_VERSION) <= $1 * 100000 + $2 * 100 + $3)))
 boost-version-parse  = $(shell echo $$(($1 / 100000)).$$(($1 / 100 % 1000)).$$(($1 % 100)))
 
+ifeq ($(CC),clang)
+  ifeq ($(call boost-version-atmost,1,55,0),1)
+    BOOST_CFLAGS_asio=-Wno-infinite-recursion -Wno-unused-local-typedef
+  endif
+endif
+
 endif # __buildsys_boost_mk_

- *commit* e459ceb1e8f4266d455495715a21a6ae501abffe - - - - - - - - - -
Author:  Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
Date:    Thu Dec 22 20:58:03 2016 +0100
Subject: buildsys: fix compile flags for CGAL with clang

 etc/buildsys/cgal.mk |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)

_Diff for modified files_:
diff --git a/etc/buildsys/cgal.mk b/etc/buildsys/cgal.mk
index 0b7c53a..8b07ad8 100644
--- a/etc/buildsys/cgal.mk
+++ b/etc/buildsys/cgal.mk
@@ -33,9 +33,15 @@ ifeq ($(CGAL_HAVE_BOOST_LIBS),1)
     ifneq ($(wildcard $(SYSROOT)/usr/include/gmp.h $(SYSROOT)/usr/local/include/gmp.h $(SYSROOT)/usr/include/$(ARCH)-linux-gnu/gmp.h),)
       ifneq ($(wildcard $(SYSROOT)/usr/include/mpfr.h $(SYSROOT)/usr/local/include/mpfr.h),)
         HAVE_CGAL:=1
-        CFLAGS_CGAL:= -DHAVE_CGAL $(call boost-libs-cflags,$(CGAL_REQ_BOOST_LIBS)) -Wno-deprecated-register -frounding-math
+        CFLAGS_CGAL:= -DHAVE_CGAL $(call boost-libs-cflags,$(CGAL_REQ_BOOST_LIBS)) -Wno-deprecated-register
         LDFLAGS_CGAL:=-lCGAL -lCGAL_Core -lgmp -lmpfr -lm \
 		      $(call boost-libs-ldflags,$(REQ_BOOST_LIBS))
+
+        ifeq ($(CC),clang)
+          CFLAGS_CGAL += -Wno-unused-local-typedef
+        else
+          CFLAGS_CGAL += -frounding-math
+        endif
       else
         CGAL_ERRORS += "MPFR_not_found"
       endif

- *commit* 3d371bfccfe242ab2aabca463d0d721153ec2641 - - - - - - - - - -
Author:  Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
Date:    Thu Dec 22 20:58:47 2016 +0100
Subject: buildsys: do not use MFLAGS to pass make flags

 etc/buildsys/rules.mk |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

_Diff for modified files_:
diff --git a/etc/buildsys/rules.mk b/etc/buildsys/rules.mk
index 8b5f5f1..e4f71bb 100644
--- a/etc/buildsys/rules.mk
+++ b/etc/buildsys/rules.mk
@@ -169,7 +169,7 @@ $(PRESUBDIRS) $(SUBDIRS):
 	else \
 		echo -e "$(INDENT_PRINT)--> Entering sub-directory $(TBOLDGRAY)$(PARENTDIR)$(TNORMAL)$(TBOLDBLUE)$@$(TNORMAL)"; \
 		$(MAKE) --no-print-directory --no-keep-going -C "$(abspath $(SRCDIR)/$@)" \
-		$(MFLAGS) $(MAKECMDGOALS) INDENT="$(INDENT)$(INDENT_STRING)" \
+		$(MAKECMDGOALS) INDENT="$(INDENT)$(INDENT_STRING)" \
 		SRCDIR="$(abspath $(SRCDIR)/$@)" OBJSSUBMAKE=0 || exit $$?; \
 		if [ "$(MAKECMDGOALS)" != "clean" ]; then \
 			echo -e "$(INDENT_PRINT)$(subst -, ,$(INDENT_STRING))<-- Leaving $(PARENTDIR)$(TBOLDGRAY)$@$(TNORMAL)"; \

- *commit* 8d05708bd29c3875012a5d6b29f3d175f977f649 - - - - - - - - - -
Author:  Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
Date:    Thu Dec 22 21:07:56 2016 +0100
Subject: baseapp: add indirectly used Boost asio

 src/libs/baseapp/Makefile |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

_Diff for modified files_:
diff --git a/src/libs/baseapp/Makefile b/src/libs/baseapp/Makefile
index 3eeadf2..4ca6733 100644
--- a/src/libs/baseapp/Makefile
+++ b/src/libs/baseapp/Makefile
@@ -26,7 +26,7 @@ LIBS_libfawkesbaseapp = stdc++ pthread fawkescore fawkesutils fawkesconfig \
 			fawkesblackboard fawkesplugin fawkesnetcomm \
 			fawkesaspects fawkeslogging
 
-REQ_BOOST_LIBS = system
+REQ_BOOST_LIBS = asio system
 HAVE_BOOST_LIBS = $(call boost-have-libs,$(REQ_BOOST_LIBS))
 
 ifeq ($(HAVE_TF),1)

- *commit* 6c39a3ab4a1755749ed05f81fab1643d222fd50e - - - - - - - - - -
Author:  Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
Date:    Thu Dec 22 21:19:03 2016 +0100
Subject: gossip: add indirectly used Boost asio

 src/plugins/gossip/aspect/Makefile |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

_Diff for modified files_:
diff --git a/src/plugins/gossip/aspect/Makefile b/src/plugins/gossip/aspect/Makefile
index 2efae16..323ff49 100644
--- a/src/plugins/gossip/aspect/Makefile
+++ b/src/plugins/gossip/aspect/Makefile
@@ -21,7 +21,7 @@ include $(BUILDSYSDIR)/boost.mk
 
 CFLAGS += $(CFLAGS_CPP11)
 
-REQ_BOOST_LIBS = system
+REQ_BOOST_LIBS = asio system
 HAVE_BOOST_LIBS = $(call boost-have-libs,$(REQ_BOOST_LIBS))
 
 LIBS_libfawkesgossipaspect = stdc++ fawkescore fawkesaspects fawkesutils fawkesgossip

- *commit* d78cfc1134491069df23685477a98d7111a1ebd8 - - - - - - - - - -
Author:  Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
Date:    Thu Dec 22 21:25:17 2016 +0100
Subject: libbaseapp: destroy main thread later

 src/libs/baseapp/run.cpp |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

_Diff for modified files_:
diff --git a/src/libs/baseapp/run.cpp b/src/libs/baseapp/run.cpp
index fbc9118..6bbbb5f 100644
--- a/src/libs/baseapp/run.cpp
+++ b/src/libs/baseapp/run.cpp
@@ -452,10 +452,10 @@ cleanup()
     delete network_logger;
   }
 
-  delete main_thread;
   delete nethandler_config;
   delete nethandler_plugin;
   delete plugin_manager;
+  delete main_thread;
 #ifdef HAVE_TF
   delete tf_listener;
   delete tf_transformer;

- *commit* 1c2be60a1f799801d705b070672acbf7de751037 - - - - - - - - - -
Author:  Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
Date:    Thu Dec 22 21:27:00 2016 +0100
Subject: libconfig: add missing includes for YAML config

 src/libs/config/yaml.cpp |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

_Diff for modified files_:
diff --git a/src/libs/config/yaml.cpp b/src/libs/config/yaml.cpp
index 5c81630..c064ca5 100644
--- a/src/libs/config/yaml.cpp
+++ b/src/libs/config/yaml.cpp
@@ -40,6 +40,8 @@
 #include <cerrno>
 #include <dirent.h>
 #include <sys/stat.h>
+#include <sys/socket.h>
+#include <netinet/in.h>
 #include <arpa/inet.h>
 
 #include <yaml-cpp/exceptions.h>

- *commit* 222c778ae95fb43481a55d413c98a694bb5fae7d - - - - - - - - - -
Author:  Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
Date:    Thu Dec 22 21:27:28 2016 +0100
Subject: fvutils: fix invalid call in JPEG compressor

 src/libs/fvutils/compression/jpeg_compressor.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

_Diff for modified files_:
diff --git a/src/libs/fvutils/compression/jpeg_compressor.h b/src/libs/fvutils/compression/jpeg_compressor.h
index 23e07aa..6c1175f 100644
--- a/src/libs/fvutils/compression/jpeg_compressor.h
+++ b/src/libs/fvutils/compression/jpeg_compressor.h
@@ -64,7 +64,7 @@ class JpegImageCompressor : public ImageCompressor {
   virtual void          set_compression_destination(ImageCompressor::CompressionDestination cd)
   { impl_->set_compression_destination(cd); }
   virtual bool          supports_compression_destination(ImageCompressor::CompressionDestination cd)
-  { return supports_compression_destination(cd); }
+  { return impl_->supports_compression_destination(cd); }
   virtual void          compress()
   { impl_->compress(); }
   virtual size_t        recommended_compressed_buffer_size()

- *commit* 91ed9344f990a33b60e8b317e9cadddd3ff2452c - - - - - - - - - -
Author:  Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
Date:    Thu Dec 22 21:28:19 2016 +0100
Subject: fvutils: fix seemingly ambiguous use of std::abs

 src/libs/fvutils/statistical/imagediff.cpp |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

_Diff for modified files_:
diff --git a/src/libs/fvutils/statistical/imagediff.cpp b/src/libs/fvutils/statistical/imagediff.cpp
index 0ad3ed4..9c056ec 100644
--- a/src/libs/fvutils/statistical/imagediff.cpp
+++ b/src/libs/fvutils/statistical/imagediff.cpp
@@ -155,7 +155,7 @@ ImageDiff::numDifferingPixels()
   if ( (buffer_a == NULL) && (buffer_b != NULL) ) return (width_b * height_b);
   if ( (buffer_a != NULL) && (buffer_b == NULL) ) return (width_a * height_a);
   if ( (width_a != width_b) || (height_a != height_b) ) {
-    return abs(width_a - width_b) * abs(height_a - height_b);
+    return std::abs((long)width_a - (long)width_b) * std::abs((long)height_a - (long)height_b);
   }
 
   unsigned int num = 0;

- *commit* ad96d9f0940f3ad5d6deb7ffc10d13bfc145eb7f - - - - - - - - - -
Author:  Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
Date:    Thu Dec 22 21:28:55 2016 +0100
Subject: netcomm: fix ambiguous template parameter name

 src/libs/netcomm/socket/socket.h |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

_Diff for modified files_:
diff --git a/src/libs/netcomm/socket/socket.h b/src/libs/netcomm/socket/socket.h
index 234bc40..dc34c83 100644
--- a/src/libs/netcomm/socket/socket.h
+++ b/src/libs/netcomm/socket/socket.h
@@ -153,12 +153,12 @@ class Socket
 };
 
 
-template <class SocketType>
-SocketType *
+template <class SocketTypeC>
+SocketTypeC *
 Socket::accept()
 {
   Socket *s = accept();
-  if (SocketType *ts = dynamic_cast<SocketType *>(s)) {
+  if (SocketTypeC *ts = dynamic_cast<SocketTypeC *>(s)) {
     return ts;
   } else {
     delete s;

- *commit* 66682355753e248a66c628f2884f14047feb539c - - - - - - - - - -
Author:  Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
Date:    Thu Dec 22 21:29:25 2016 +0100
Subject: netcomm: add missing include for clang/libc++

 src/libs/netcomm/utils/resolver_thread.h |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

_Diff for modified files_:
diff --git a/src/libs/netcomm/utils/resolver_thread.h b/src/libs/netcomm/utils/resolver_thread.h
index 17f8d80..7c75383 100644
--- a/src/libs/netcomm/utils/resolver_thread.h
+++ b/src/libs/netcomm/utils/resolver_thread.h
@@ -35,6 +35,7 @@
 #include <netinet/in.h>
 #include <stdint.h>
 #include <cstddef>
+#include <string>
 #include <utility>
 #include <map>
 #include <list>

- *commit* 04dc8d6ec56db636905a90dd48bdedf353458270 - - - - - - - - - -
Author:  Tim Niemueller <niemueller at kbsg.rwth-aachen.de>
Date:    Thu Dec 22 21:29:39 2016 +0100
Subject: amcl: fix ambiguous use of std::abs with clang/libc++

 src/plugins/amcl/amcl_thread.cpp |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

_Diff for modified files_:
diff --git a/src/plugins/amcl/amcl_thread.cpp b/src/plugins/amcl/amcl_thread.cpp
index ebe13f3..f502992 100644
--- a/src/plugins/amcl/amcl_thread.cpp
+++ b/src/plugins/amcl/amcl_thread.cpp
@@ -177,7 +177,7 @@ void AmclThread::init()
     angle_max_idx_ = 359;
   }
   if (angle_max_idx_ > angle_min_idx_) {
-    angle_range_ = (unsigned int)abs(angle_max_idx_ - angle_min_idx_);
+    angle_range_ = (unsigned int)abs((long)angle_max_idx_ - (long)angle_min_idx_);
   } else {
     angle_range_ = (360 - angle_min_idx_) + angle_max_idx_;
   }




-- 
Fawkes Robotics Framework                 http://www.fawkesrobotics.org


More information about the fawkes-commits mailing list