[MacPorts] #47498: gpsd @3.14: error: redefinition of typedef 'clockid_t'

MacPorts noreply at macports.org
Wed Apr 29 03:03:24 PDT 2015

#47498: gpsd @3.14: error: redefinition of typedef 'clockid_t'
  Reporter:  valerio@…  |      Owner:  ryandesign@…
      Type:  defect     |     Status:  assigned
  Priority:  Normal     |  Milestone:
 Component:  ports      |    Version:  2.3.3
Resolution:             |   Keywords:  snowleopard
      Port:  gpsd       |

Comment (by davide.liessi@…):

 Installation fails with MacPorts gcc 4.7 and 4.8, with the same error but
 in a different file:
 :info:build /opt/local/bin/gcc-mp-4.8 -m64 -o monitor_garmin.o -c -Os -m64
 -Wextra -Wall -Wno-uninitialized -Wno-missing-field-initializers -Wcast-
 align -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes
 -Wpointer-arith -Wreturn-type -pthread -Wmissing-declarations -O2
 -I/opt/local/include/dbus-1.0 -I/opt/local/lib/dbus-1.0/include
 -I/opt/local/include monitor_garmin.c
 :info:build /usr/bin/gcc-4.2 -o gpsclient-py_2_7_9_final_0.so -c -fno-
 strict-aliasing -fno-common -dynamic -Wmissing-declarations -O2 -DNDEBUG
 -g -fwrapv -O3 -Wall -Wstrict-prototypes
 :info:build /opt/local/bin/gcc-mp-4.8 -m64 -o gpsmon gpsmon.o
 monitor_italk.o monitor_nmea0183.o monitor_oncore.o monitor_sirf.o
 monitor_superstar2.o monitor_tnt.o monitor_ubx.o monitor_garmin.o -L.
 -L/opt/local/lib -ldbus-1 -lgpsd -lgps -ldbus-1 -lncurses -lm
 :info:build /usr/bin/gcc-4.2 -o gpsdclient-py_2_7_9_final_0.so -c -fno-
 strict-aliasing -fno-common -dynamic -Wmissing-declarations -O2 -DNDEBUG
 -g -fwrapv -O3 -Wall -Wstrict-prototypes
 :info:build /usr/bin/gcc-4.2 -o geoid-py_2_7_9_final_0.so -c -fno-strict-
 aliasing -fno-common -dynamic -Wmissing-declarations -O2 -DNDEBUG -g
 -fwrapv -O3 -Wall -Wstrict-prototypes
 :info:build In file included from compiler.h:23,
 :info:build                  from gpsd.h:353,
 :info:build                  from geoid.c:12:
 :info:build gpsd_config.h:303: error: redefinition of typedef 'clockid_t'
 :info:build gpsd.h:323: error: previous declaration of 'clockid_t' was
 :info:build scons: *** [geoid-py_2_7_9_final_0.so] Error 1
 :info:build scons: building terminated because of errors.
 :info:build Command failed:  cd "/opt/local/var/macports/build
 /_opt_macports-git_trunk_dports_net_gpsd/gpsd/work/gpsd-3.14" &&
 /opt/local/bin/scons -j2 prefix=/opt/local libQgpsmm=no usb=no strip=no
 :info:build Exit code: 2

 I included also some lines of the log before the error, to show that
 although I specified `configure.compiler=macports-gcc-4.8`, the build
 script used `/usr/bin/gcc-4.2` on three files and the error happened in
 one of those files.

 Maybe SCons is not obeying the compiler setting?

 I'm trying with `macports-clang-3.4` now.


 > that will use a different C++ library than the rest of your software and
 could lead to crashes

 Is this only hypothetical or is it a real risk? I actually installed a
 couple of ports with `macports-gcc-4.7` or `macports-gcc-4.8`, because
 they wouldn't build otherwise.

Ticket URL: <https://trac.macports.org/ticket/47498#comment:11>
MacPorts <https://www.macports.org/>
Ports system for OS X

More information about the macports-tickets mailing list