aboutsummaryrefslogtreecommitdiff
path: root/astro
diff options
context:
space:
mode:
authorDmitry Marakasov <amdmi3@FreeBSD.org>2011-08-24 13:00:42 +0000
committerDmitry Marakasov <amdmi3@FreeBSD.org>2011-08-24 13:00:42 +0000
commit2f77a31a81bf0a34780d174429a233e72ace6b46 (patch)
treed0c3c0cfb6a1d45d467bed404b7339f2e7f928e1 /astro
parent5a9b380865be32f9daa607dc8508ec9de6468e82 (diff)
downloadports-2f77a31a81bf0a34780d174429a233e72ace6b46.tar.gz
ports-2f77a31a81bf0a34780d174429a233e72ace6b46.zip
Notes
Diffstat (limited to 'astro')
-rw-r--r--astro/gpsd/Makefile286
-rw-r--r--astro/gpsd/distinfo4
-rw-r--r--astro/gpsd/files/patch-SConstruct58
-rw-r--r--astro/gpsd/files/patch-libgps_json.c11
-rw-r--r--astro/gpsd/files/pkg-message.in9
-rw-r--r--astro/gpsd/pkg-plist33
6 files changed, 274 insertions, 127 deletions
diff --git a/astro/gpsd/Makefile b/astro/gpsd/Makefile
index 5bbe537828ef..33d2b2abe724 100644
--- a/astro/gpsd/Makefile
+++ b/astro/gpsd/Makefile
@@ -6,10 +6,9 @@
#
PORTNAME= gpsd
-PORTVERSION= 2.96
+PORTVERSION= 3.0
CATEGORIES= astro geography
-MASTER_SITES= ${MASTER_SITE_BERLIOS}
-MASTER_SITE_SUBDIR= ${PORTNAME}
+MASTER_SITES= BERLIOS
MAINTAINER= glebius@FreeBSD.org
COMMENT= Daemon that monitors one or more GPSes attached to a host computer
@@ -17,169 +16,272 @@ COMMENT= Daemon that monitors one or more GPSes attached to a host computer
BUILD_DEPENDS= docbook-xsl>=0:${PORTSDIR}/textproc/docbook-xsl \
xsltproc:${PORTSDIR}/textproc/libxslt
+USE_GNOME= pkgconfig
+USE_SCONS= yes
USE_RC_SUBR= gpsd
-USE_AUTOTOOLS= libtool
-GNU_CONFIGURE= yes
-USE_GNOME= gnomehack pkgconfig
-USE_LDCONFIG= yes
-CONFIGURE_ENV= CFLAGS="${CFLAGS} ${PTHREAD_CFLAGS}" \
- LDFLAGS="${LDFLAGS} ${PTHREAD_LIBS}"
-CONFIGURE_ARGS= --disable-libQgpsmm
USE_PYTHON= yes
INSTALLS_EGGINFO= yes
-PYDISTUTILS_PKGNAME= gps
-
-MAN1= cgps.1 gps.1 gpscat.1 gpsctl.1 gpsfake.1 \
- gpspipe.1 gpsprof.1 xgps.1 xgpsspeed.1 gpsmon.1 \
- lcdgps.1
-MAN3= libgps.3 libgpsd.3 libgpsmm.3
-MAN5= srec.5
-MAN8= gpsd.8
+PYDISTUTILS_EGGINFO= gps-${PORTVERSION}.egg-info
+MAKE_JOBS_UNSAFE=yes
+
+SCONS_BUILDENV= ${SCONS_ENV}
+SCONS_ARGS= prefix="${PREFIX}" mandir="/man"
+
+MAN1= cgps.1 gegps.1 gps.1 gpscat.1 gpsctl.1 gpsdecode.1 \
+ gpsfake.1 gpspipe.1 gpsprof.1 xgps.1 xgpsspeed.1 \
+ gpsmon.1 lcdgps.1
+MAN3= libgps.3 libgpsd.3 libgpsmm.3 libQgpsmm.3
+MAN5= srec.5 gpsd_json.5
+MAN8= gpsd.8 gpsdctl.8
MANCOMPRESSED= no
-SUB_FILES= pkg-message
-
-OPTIONS= GTK2 "Install py-gtk2 (required for xgps & xgpsspeed)" off \
- NMEA "NMEA support" on \
- SIRF "SiRF chipset support" on \
- SUPERSTARII "SuperStarII support" off \
- TSIP "Trimble TSIP support" on \
- FV18 "San Jose Navigation FV-18 support" on \
- TRIPMATE "DeLorme TripMate support" on \
- EARTHMATE "DeLorme EarthMate Zodiac support" on \
- ITRAX "iTrax support" on \
+OPTIONS= AIVDM "Aivdm support" on \
ASHTECH "Ashtech support" on \
- NAVCOM "Navcom support" on \
- GARMIN "Garmin kernel driver support" on \
- GARMINTXT "Garmin Simple Text support" off \
- TNT "True North Technologies support" off \
- OCEANSERVER "Oceanserver support" off \
- UBX "UBX protocol support" on \
+ CPPBIND "Build C++ bindings" on \
+ EARTHMATE "DeLorme EarthMate Zodiac support" on \
EVERMORE "Evermore binary support" on \
+ FV18 "San Jose Navigation FV-18 support" on \
+ GARMIN "Garmin kernel driver support" on \
+ GARMINTXT "Garmin Simple Text support" on \
+ GEOSTAR "Geostar Protocol support" on \
GPSCLOCK "GPSclock support" on \
- RTCM104V2 "rtcm104v2 support" on \
- RTCM104V3 "rtcm104v3 support" on \
- AIVDM "Aivdm support" on \
+ GTK2 "Install py-gtk2 (required for xgps & xgpsspeed)" off \
+ IP6 "IPv6 support" on \
+ ITRAX "iTrax support" on \
+ MTK "MTK-3301 support" on \
+ NAVCOM "Navcom support" on \
+ NCURSES "Build with ncurses(3)" off \
+ NMEA "NMEA support" on \
+ NTPSHM "NTP time hinting support" on \
NTRIP "NTRIP support" on \
+ OCEANSERVER "Oceanserver support" on \
+ OLDPROTO "Old (pre-JSON) protocol support in client lib" on \
+ ONCORE "Motorola OnCore chipset support" on \
+ PASSTHROUGH "Build support for passing through JSON" on \
+ PPS "PPS time syncing support" on \
+ PPSONCTS "PPS pulse on CTS rather than DCD" off \
PROFILING "Profiling support" off \
- NTPSHM "NTP time hinting support" on \
- PPS "PPS time syncing support" off \
- DBUS "DBUS support" off
+ RTCM104V2 "rtcm104v2 support" on \
+ RTCM104V3 "rtcm104v3 support" on \
+ SHMEXPORT "Enable export via shared memory" on \
+ SIRF "SiRF chipset support" on \
+ SUPERSTARII "SuperStarII support" on \
+ TIMING "Build latency timing support" on \
+ TNT "True North Technologies support" on \
+ TRIPMATE "DeLorme TripMate support" on \
+ TSIP "Trimble TSIP support" on \
+ QTBIND "build QT bindings" off \
+ UBX "UBX protocol support" on \
+ USB "libusb support for USB devices" on
+
+# Doesn't build
+# DBUS "DBUS support" off \
+# Doesn't build when toggled
+# NETFEED "Build support for handling TCP/IP data sources" on \
+# SOCKEXPORT "Enable export over sockets" on \
+# RECONFIGURE "Allow gpsd to change device settings" on \
.include <bsd.port.options.mk>
-.if defined(WITH_GTK2)
-USE_GNOME+= pygtk2
-.endif
+# This is only temporary for my tinderbox not to try these options
+# Options related to GPS protocols
.if defined(WITHOUT_NMEA)
-CONFIGURE_ARGS+=--disable-nmea
+SCONS_ARGS+= nmea=no
.endif
-.if defined(WITHOUT_SIRF)
-CONFIGURE_ARGS+=--disable-sirf
+.if defined(WITHOUT_ASHTECH)
+SCONS_ARGS+= ashtech=no
.endif
-.if defined(WITH_SUPERSTARII)
-CONFIGURE_ARGS+= --enable-superstar2
+.if defined(WITHOUT_EARTHMATE)
+SCONS_ARGS+= earthmate=no
.endif
-.if defined(WITHOUT_TSIP)
-CONFIGURE_ARGS+=--disable-tsip
+.if defined(WITHOUT_EVERMORE)
+SCONS_ARGS+= evermore=no
.endif
.if defined(WITHOUT_FV18)
-CONFIGURE_ARGS+=--disable-fv18
+SCONS_ARGS+= fv18=no
.endif
-.if defined(WITHOUT_TRIPMATE)
-CONFIGURE_ARGS+=--disable-tripmate
+.if defined(WITHOUT_GARMIN)
+SCONS_ARGS+= garmin=no
.endif
-.if defined(WITHOUT_EARTHMATE)
-CONFIGURE_ARGS+=--disable-earthmate
+.if defined(WITHOUT_GARMINTXT)
+SCONS_ARGS+= garmintxt=no
+.endif
+
+.if defined(WITHOUT_GEOSTAR)
+SCONS_ARGS+= geostar=no
.endif
.if defined(WITHOUT_ITRAX)
-CONFIGURE_ARGS+=--disable-itrax
+SCONS_ARGS+= itrax=no
.endif
-.if defined(WITHOUT_ASHTECH)
-CONFIGURE_ARGS+=--disable-ashtech
+.if defined(WITHOUT_MTK)
+SCONS_ARGS+= mtk3301=no
.endif
.if defined(WITHOUT_NAVCOM)
-CONFIGURE_ARGS+=--disable-navcom
+SCONS_ARGS+= navcom=no
.endif
-.if defined(WITHOUT_GARMIN)
-CONFIGURE_ARGS+=--disable-garmin
+.if defined(WITHOUT_ONCORE)
+SCONS_ARGS+= oncore=no
.endif
-.if defined(WITH_GARMINTXT)
-CONFIGURE_ARGS+=--enable-garmintxt
+.if defined(WITHOUT_SIRF)
+SCONS_ARGS+= sirf=no
+.endif
+
+.if defined(WITHOUT_SUPERSTARII)
+SCONS_ARGS+= superstar2=no
+.endif
+
+.if defined(WITHOUT_TNT)
+SCONS_ARGS+= tnt=no
.endif
-.if defined(WITH_TNT)
-CONFIGURE_ARGS+=--enable-tnt
+.if defined(WITHOUT_TRIPMATE)
+SCONS_ARGS+= tripmate=no
.endif
-.if defined(WITH_OCEANSERVER)
-CONFIGURE_ARGS+=--enable-oceanserver
+.if defined(WITHOUT_TSIP)
+SCONS_ARGS+= tsip=no
.endif
.if defined(WITHOUT_UBX)
-CONFIGURE_ARGS+=--disable-ubx
+SCONS_ARGS+= ubx=no
.endif
-.if defined(WITHOUT_EVERMORE)
-CONFIGURE_ARGS+=--disable-evermore
+# Options related to Non-GPS protocols
+.if defined(WITHOUT_AIVDM)
+SCONS_ARGS+= aivdm=no
.endif
.if defined(WITHOUT_GPSCLOCK)
-CONFIGURE_ARGS+=--disable-gpscloclk
+SCONS_ARGS+= gpsclock=no
.endif
-.if defined(WITHOUT_AIVDM)
-CONFIGURE_ARGS+=--disable-aivdm
+.if defined(WITHOUT_NTRIP)
+SCONS_ARGS+= ntrip=no
.endif
-.if defined(WITH_RTCM104V2) && defined(WITH_RTCM104V3) && defined(WITH_AIVDM)
-PLIST_SUB+= DECODE=""
-MAN1+= gpsdecode.1
-.else
-PLIST_SUB+= DECODE="@comment "
+.if defined(WITHOUT_OCEANSERVER)
+SCONS_ARGS+= oceanserver=no
.endif
.if defined(WITHOUT_RTCM104V2)
-CONFIGURE_ARGS+=--disable-rtcm104v2
+SCONS_ARGS+= rtcm104v2=no
.endif
.if defined(WITHOUT_RTCM104V3)
-CONFIGURE_ARGS+=--disable-rtcm104v3
+SCONS_ARGS+= rtcm104v3=no
.endif
-.if defined(WITHOUT_NTRIP)
-CONFIGURE_ARGS+=--disable-ntrip
+# Time service
+.if defined(WITHOUT_NTPSHM)
+SCONS_ARGS+= ntpshm=no
.endif
-.if defined(WITH_PROFILING)
-CONFIGURE_ARGS+=--enable-profiling
+.if defined(WITHOUT_PPS)
+SCONS_ARGS+= pps=no
.endif
-.if defined(WITHOUT_NTPSHM)
-CONFIGURE_ARGS+=--disable-ntpshm
+.if defined(WITH_PPSONCTS)
+SCONS_ARGS+= pps_on_cts=yes
+.endif
+
+# Export methods
+
+# Won't build
+#.if defined(WITHOUT_SOCKEXPORT)
+#SCONS_ARGS+= socket_export=no
+#.endif
+
+# doesn't build; too many unsolvable problems with lib detection,
+# include paths etc.
+#.if defined(WITH_DBUS)
+#LIB_DEPENDS+= dbus:${PORTSDIR}/devel/dbus \
+# dbus-glib-1.2:${PORTSDIR}/devel/dbus-glib
+#SCONS_ARGS+= dbus_export=yes
+#.endif
+
+.if defined(WITHOUT_SHMEXPORT)
+SCONS_ARGS+= shm_export=no
+.endif
+
+# Communication
+.if defined(WITHOUT_USB)
+SCONS_ARGS+= usb=no
+.endif
+
+.if defined(WITHOUT_IPV6)
+SCONS_ARGS+= ipv6=no
+.endif
+
+# Won't build
+#.if defined(WITHOUT_NETFEED)
+#SCONS_ARGS+= netfeed=no
+#.endif
+
+.if defined(WITHOUT_PASSTHROUGH)
+SCONS_ARGS+= passthrough=no
+.endif
+
+# Other daemon options
+.if defined(WITHOUT_TIMING)
+SCONS_ARGS+= timing=no
.endif
-.if defined(WITH_PPS)
-CONFIGURE_ARGS+=--enable-pps
+# Client-side options
+.if defined(WITHOUT_OLDPROTO)
+SCONS_ARGS+= oldstyle=no
.endif
-.if defined(WITH_DBUS)
-CONFIGURE_ARGS+=--enable-dbus
+.if defined(WITH_QTBIND)
+USE_QT_VER= 4
+QT_COMPONENTS= network
+SCONS_ARGS+= libQgpsmm=yes
+PLIST_SUB+= QTBIND=""
+.else
+SCONS_ARGS+= libQgpsmm=no
+PLIST_SUB+= QTBIND="@comment "
+.endif
+
+# Won't build
+#.if defined(WITHOUT_RECONFIGURE)
+#SCONS_ARGS+= reconfigure=no
+#.endif
+
+.if defined(WITHOUT_CPPBIND)
+SCONS_ARGS+= libgpsmm=no
+.endif
+
+.if defined(WITHOUT_NCURSES)
+SCONS_ARGS+= ncurses=no
+PLIST_SUB+= CURSES="@comment "
+.else
+PLIST_SUB+= CURSES=""
+.endif
+
+# Build control
+.if defined(WITH_PROFILING)
+SCONS_ARGS+= profiling=yes
.endif
+# generates .py[co] files for installed modules
+# if that's not done, ${PYTHON_SITELIBDIR}/gps will be polluted
+# with these files when module is imported from root user
post-install:
- @${CAT} ${PKGMESSAGE}
+ @${FIND} ${PYTHON_SITELIBDIR}/gps -name "*.py" -exec \
+ ${PYTHON_CMD} ${PYTHON_LIBDIR}/py_compile.py {} \;
+ @${SETENV} PYTHONOPTIMIZE=yes \
+ ${FIND} ${PYTHON_SITELIBDIR}/gps -name "*.py" -exec \
+ ${PYTHON_CMD} ${PYTHON_LIBDIR}/py_compile.py {} \;
.include <bsd.port.mk>
diff --git a/astro/gpsd/distinfo b/astro/gpsd/distinfo
index 215021699968..7a5b3ea77813 100644
--- a/astro/gpsd/distinfo
+++ b/astro/gpsd/distinfo
@@ -1,2 +1,2 @@
-SHA256 (gpsd-2.96.tar.gz) = 054772152d2e3299913fa2470d6fc5c05af9ba1ea63a2f0db711e0aabb96f139
-SIZE (gpsd-2.96.tar.gz) = 1554607
+SHA256 (gpsd-3.0.tar.gz) = 542ed7a5885205604eb60e2d0895b9d6cdefb30fc2028d2ba4ebfe5ba01d95e7
+SIZE (gpsd-3.0.tar.gz) = 2133361
diff --git a/astro/gpsd/files/patch-SConstruct b/astro/gpsd/files/patch-SConstruct
new file mode 100644
index 000000000000..e9573e72a455
--- /dev/null
+++ b/astro/gpsd/files/patch-SConstruct
@@ -0,0 +1,58 @@
+--- SConstruct.orig 2011-08-19 09:36:28.000000000 +0400
++++ SConstruct 2011-08-24 14:13:54.000000000 +0400
+@@ -155,7 +155,10 @@
+ j = i
+ if i == "LD":
+ i = "SHLINK"
+- env[j]=os.getenv(i)
++ if i == "CFLAGS" or i == "CCFLAGS":
++ env.Replace(**{j: Split(os.getenv(i))})
++ else:
++ env.Replace(**{j: os.getenv(i)})
+ for flags in ["LDFLAGS", "CPPFLAGS"]:
+ if os.environ.has_key(flags):
+ env.MergeFlags([os.getenv(flags)])
+@@ -173,7 +176,7 @@
+ else:
+ pkg_config = lambda pkg: ['!pkg-config --cflags --libs --static %s' %(pkg, )]
+
+-if env['CC'] == 'gcc':
++if env['CC'] == 'gcc' or env['CC'] == 'cc':
+ # Enable all GCC warnings except uninitialized and
+ # missing-field-initializers, which we can't help triggering because
+ # of the way some of the JSON-parsing code is generated.
+@@ -326,22 +329,12 @@
+ confdefs.append("/* #undef HAVE_%s */\n" % f.upper())
+
+ if env['ncurses']:
+- if config.CheckPKG('ncurses'):
+- ncurseslibs = pkg_config('ncurses')
+- elif config.CheckExecutable('ncurses5-config --version', 'ncurses5-config'):
+- ncurseslibs = ['!ncurses5-config --libs --cflags']
+- else:
+- ncurseslibs= []
++ ncurseslibs= [ '/usr/lib/libncurses.so' ]
+ else:
+ ncurseslibs= []
+
+-if env['usb'] and config.CheckPKG('libusb-1.0'):
+- confdefs.append("#define HAVE_LIBUSB 1\n")
+- try:
+- usblibs = pkg_config('libusb-1.0')
+- except OSError:
+- print "pkg_config is confused about the state of libusb-1.0."
+- usblibs = []
++if env['usb']:
++ usblibs = [ "-lusb" ]
+ else:
+ confdefs.append("/* #undef HAVE_LIBUSB */\n")
+ usblibs = []
+@@ -950,7 +943,7 @@
+ python_progs_install,
+ python_egg_info_install]
+
+-pkgconfigdir = os.path.join(installdir('libdir'), 'pkgconfig')
++pkgconfigdir = os.path.join(env['prefix'], 'libdata', 'pkgconfig')
+ pc_install = [ env.Install(pkgconfigdir, x) for x in ("libgps.pc", "libgpsd.pc") ]
+
+ maninstall = []
diff --git a/astro/gpsd/files/patch-libgps_json.c b/astro/gpsd/files/patch-libgps_json.c
deleted file mode 100644
index c463be48706e..000000000000
--- a/astro/gpsd/files/patch-libgps_json.c
+++ /dev/null
@@ -1,11 +0,0 @@
---- libgps_json.c.orig
-+++ libgps_json.c
-@@ -203,7 +203,7 @@ static int json_sky_read(const char *buf, struct gps_data_t *gpsdata,
- .len = sizeof(gpsdata->tag)},
- {"time", t_string, .addr.string = tbuf,
- .len = sizeof(tbuf)},
-- {"time", t_real, .addr.real = &gpsdata->fix.time,
-+ {"time", t_real, .addr.real = &gpsdata->skyview_time,
- .dflt.real = NAN},
- {"hdop", t_real, .addr.real = &gpsdata->dop.hdop,
- .dflt.real = NAN},
diff --git a/astro/gpsd/files/pkg-message.in b/astro/gpsd/files/pkg-message.in
deleted file mode 100644
index 706e12cf9a55..000000000000
--- a/astro/gpsd/files/pkg-message.in
+++ /dev/null
@@ -1,9 +0,0 @@
-=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=
-* NOTE:
-
-%%PREFIX%%/bin/gpsfake and %%PREFIX%%/bin/gpsprof
-are Python script text executables.
-To use them, please ensure you have appropriate
-Python install.
-
-=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=
diff --git a/astro/gpsd/pkg-plist b/astro/gpsd/pkg-plist
index 25d2919263d6..459b3c99d36c 100644
--- a/astro/gpsd/pkg-plist
+++ b/astro/gpsd/pkg-plist
@@ -1,42 +1,49 @@
-bin/cgps
+bin/gegps
bin/gpscat
bin/gpsctl
-%%DECODE%%bin/gpsdecode
+bin/gpsdecode
bin/gpsfake
-bin/gpsmon
bin/gpspipe
bin/gpsprof
bin/gpxlogger
bin/lcdgps
bin/xgps
bin/xgpsspeed
+%%CURSES%%bin/cgps
+%%CURSES%%bin/gpsmon
include/gps.h
-include/gpsd.h
include/libgpsmm.h
-lib/libgps.a
-lib/libgps.la
+%%QTBIND%%lib/libQgpsmm.so
+%%QTBIND%%lib/libQgpsmm.so.20
+%%QTBIND%%lib/libQgpsmm.so.20.0
+%%QTBIND%%lib/libQgpsmm.so.20.0.0
lib/libgps.so
lib/libgps.so.20
-lib/libgpsd.a
-lib/libgpsd.la
+lib/libgps.so.20.0
+lib/libgps.so.20.0.0
lib/libgpsd.so
-lib/libgpsd.so.0
+lib/libgpsd.so.20
+lib/libgpsd.so.20.0
+lib/libgpsd.so.20.0.0
%%PYTHON_SITELIBDIR%%/gps/__init__.py
%%PYTHON_SITELIBDIR%%/gps/__init__.pyc
+%%PYTHON_SITELIBDIR%%/gps/__init__.pyo
%%PYTHON_SITELIBDIR%%/gps/client.py
%%PYTHON_SITELIBDIR%%/gps/client.pyc
+%%PYTHON_SITELIBDIR%%/gps/client.pyo
%%PYTHON_SITELIBDIR%%/gps/clienthelpers.so
%%PYTHON_SITELIBDIR%%/gps/fake.py
%%PYTHON_SITELIBDIR%%/gps/fake.pyc
+%%PYTHON_SITELIBDIR%%/gps/fake.pyo
%%PYTHON_SITELIBDIR%%/gps/gps.py
%%PYTHON_SITELIBDIR%%/gps/gps.pyc
+%%PYTHON_SITELIBDIR%%/gps/gps.pyo
%%PYTHON_SITELIBDIR%%/gps/misc.py
%%PYTHON_SITELIBDIR%%/gps/misc.pyc
+%%PYTHON_SITELIBDIR%%/gps/misc.pyo
%%PYTHON_SITELIBDIR%%/gps/packet.so
-%%PYTHON_SITELIBDIR%%/gpscap.py
-%%PYTHON_SITELIBDIR%%/gpscap.pyc
-%%PYTHON_SITELIBDIR%%/gpscap.pyo
+@dirrm %%PYTHON_SITELIBDIR%%/gps
libdata/pkgconfig/libgps.pc
libdata/pkgconfig/libgpsd.pc
sbin/gpsd
-@dirrm %%PYTHON_SITELIBDIR%%/gps
+sbin/gpsdctl