diff options
author | db <db@FreeBSD.org> | 2012-11-06 06:08:20 +0800 |
---|---|---|
committer | db <db@FreeBSD.org> | 2012-11-06 06:08:20 +0800 |
commit | fd54a2936995475cc38c10fb81035bc63f173af3 (patch) | |
tree | 651ee4e1ab74bb9f35e8b0ae91eb4cdca3407f0a | |
parent | 660d7c378a8bbaa9b16368424a9b3e6b3b473428 (diff) | |
download | freebsd-ports-gnome-fd54a2936995475cc38c10fb81035bc63f173af3.tar.gz freebsd-ports-gnome-fd54a2936995475cc38c10fb81035bc63f173af3.tar.zst freebsd-ports-gnome-fd54a2936995475cc38c10fb81035bc63f173af3.zip |
- tidy up header
- options for various versions of splat!
- add LICENSE
- update to 1.4.0
This release introduces a new contour smoothing feature (used to generate
the graphic shown in Figure 1 below), introduces a color key overlay
to GoogleEarth contour displays, and supplants the Longley-Rice
propagation model with a new Irregular Terrain with Obstructions
Model (ITWOM v3.0) created by Sid Shumate, President of Givens & Bell, Inc.
The ITWOM model promises improved performance and greater accuracy over
the older ITM model used in the past.
Feature safe: yes
-rw-r--r-- | comms/splat/Makefile | 110 | ||||
-rw-r--r-- | comms/splat/distinfo | 4 | ||||
-rw-r--r-- | comms/splat/files/patch-splat.cpp | 11 | ||||
-rw-r--r-- | comms/splat/files/patch-utils_fontdata.c | 12 | ||||
-rw-r--r-- | comms/splat/files/patch-utils_postdownload | 8 |
5 files changed, 116 insertions, 29 deletions
diff --git a/comms/splat/Makefile b/comms/splat/Makefile index c73053826d8a..f84df3b532b9 100644 --- a/comms/splat/Makefile +++ b/comms/splat/Makefile @@ -1,12 +1,7 @@ -# New ports collection makefile for: splat -# Date created: 8 July 2005 -# Whom: db -# # $FreeBSD$ -# PORTNAME= splat -PORTVERSION= 1.3.0 +PORTVERSION= 1.4.0 CATEGORIES= comms hamradio MASTER_SITES= ${MASTER_SITE_SUNSITE} MASTER_SITE_SUBDIR= apps/ham @@ -14,19 +9,97 @@ MASTER_SITE_SUBDIR= apps/ham MAINTAINER= db@FreeBSD.org COMMENT= Used in calculating path losses, useful to ham radio and others +LICENSE= GPLv2 + USE_BZIP2= yes PORTDOCS= README README2 CHANGES -PLIST_FILES= bin/splat bin/citydecoder bin/usgs2sdf bin/srtm2sdf \ - bin/fontdata bin/bearing +PLIST_FILES= bin/splat bin/citydecoder bin/usgs2sdf bin/srtm2sdf\ + bin/srtm2sdf-hd bin/fontdata bin/bearing\ + bin/postdownload MAN1= splat.1 +OPTIONS_DEFINE= HRM +OPTIONS_SINGLE= SRM HRM +OPTIONS_SINGLE_SRM= SRM_2X2 SRM_3X3 SRM_4X4 SRM_5X5 SRM_6X6 SRM_7X7 SRM_8X8 +OPTIONS_SINGLE_HRM= HRM_1X1 HRM_2X2 HRM_3X3 HRM_4X4 HRM_5X5 HRM_6X6 +OPTIONS_DEFAULT= SRM_4X4 + +SRM_2X2_DESC= 2 x 2 degrees +SRM_3X3_DESC= 3 x 3 degrees +SRM_4X4_DESC= 4 x 4 degrees +SRM_5X5_DESC= 5 x 5 degrees +SRM_6X6_DESC= 6 X 6 degrees +SRM_7X7_DESC= 7 x 7 degrees +SRM_8X8_DESC= 8 x 8 degrees + +HRM_DESC= Optionally build High Resolution splat-hd +HRM_1X1_DESC= 1 x 1 degrees +HRM_2X2_DESC= 2 x 2 degrees +HRM_3X3_DESC= 3 x 3 degrees +HRM_4X4_DESC= 4 x 4 degrees +HRM_5X5_DESC= 5 x 5 degrees +HRM_6X6_DESC= 6 X 6 degrees + +.include <bsd.port.options.mk> + +.if ${PORT_OPTIONS:MHRM} +PLIST_FILES+= bin/splat-hd +.endif + do-build: - @echo "#define MAXPAGES 9" >> ${WRKSRC}/std-parms.h - @echo "#define HD_MODE 0" >> ${WRKSRC}/std-parms.h - @cp ${WRKSRC}/std-parms.h ${WRKSRC}/splat.h + @${ECHO_CMD} "#define HD_MODE 0" > ${WRKSRC}/splat.h +.if ${PORT_OPTIONS:MSRM_2X2} + @${ECHO_CMD} "#define MAXPAGES 4" >> ${WRKSRC}/splat.h +.endif +.if ${PORT_OPTIONS:MSRM_3X3} + @${ECHO_CMD} "#define MAXPAGES 9" >> ${WRKSRC}/splat.h +.endif +.if ${PORT_OPTIONS:MSRM_4X4} + @${ECHO_CMD} "#define MAXPAGES 16" >> ${WRKSRC}/splat.h +.endif +.if ${PORT_OPTIONS:MSRM_5X5} + @${ECHO_CMD} "#define MAXPAGES 25" >> ${WRKSRC}/splat.h +.endif +.if ${PORT_OPTIONS:MSRM_6X6} + @${ECHO_CMD} "#define MAXPAGES 36" >> ${WRKSRC}/splat.h +.endif +.if ${PORT_OPTIONS:MSRM_7X7} + @${ECHO_CMD} "#define MAXPAGES 49" >> ${WRKSRC}/splat.h +.endif +.if ${PORT_OPTIONS:MSRM_8X8} + @${ECHO_CMD} "#define MAXPAGES 64" >> ${WRKSRC}/splat.h +.endif +.if defined(PACKAGE_BUILDING) || defined(BATCH) + @${ECHO_CMD} "#define HD_MODE 0" > ${WRKSRC}/splat.h + @${ECHO_CMD} "#define MAXPAGES 16" >> ${WRKSRC}/splat.h +.endif + cd ${WRKSRC} && \ + ${CXX} ${CXXFLAGS} -lm -lbz2 -o splat itwom3.0.cpp splat.cpp +.if ${PORT_OPTIONS:MHRM} + @${ECHO_CMD} "#define HD_MODE 1" > ${WRKSRC}/splat.h +.if ${PORT_OPTIONS:MHRM_1X1} + @${ECHO_CMD} "#define MAXPAGES 1" >> ${WRKSRC}/splat.h +.endif +.if ${PORT_OPTIONS:MHRM_2X2} + @${ECHO_CMD} "#define MAXPAGES 4" >> ${WRKSRC}/splat.h +.endif +.if ${PORT_OPTIONS:MHRM_3X3} + @${ECHO_CMD} "#define MAXPAGES 9" >> ${WRKSRC}/splat.h +.endif +.if ${PORT_OPTIONS:MHRM_4X4} + @${ECHO_CMD} "#define MAXPAGES 16" >> ${WRKSRC}/splat.h +.endif +.if ${PORT_OPTIONS:MHRM_5X5} + @${ECHO_CMD} "#define MAXPAGES 25" >> ${WRKSRC}/splat.h +.endif +.if ${PORT_OPTIONS:MHRM_6X6} + @${ECHO_CMD} "#define MAXPAGES 36" >> ${WRKSRC}/splat.h +.endif cd ${WRKSRC} && \ - ${CXX} ${CXXFLAGS} -lm -lbz2 -o splat itm.cpp splat.cpp + ${CXX} ${CXXFLAGS} -fPIC -lm -lbz2 -o splat-hd itwom3.0.cpp splat.cpp + +.endif cd ${WRKSRC}/utils && \ ${CC} ${CFLAGS} -o citydecoder citydecoder.c && \ ${CC} ${CFLAGS} -o usgs2sdf usgs2sdf.c && \ @@ -37,14 +110,19 @@ do-build: do-install: .for f in splat utils/citydecoder utils/usgs2sdf utils/srtm2sdf \ utils/fontdata utils/bearing - ${INSTALL_PROGRAM} ${WRKSRC}/${f} ${PREFIX}/bin + @${INSTALL_PROGRAM} ${WRKSRC}/${f} ${PREFIX}/bin .endfor - ${INSTALL_MAN} ${WRKSRC}/docs/english/man/splat.1 ${MAN1PREFIX}/man/man1 +.if ${PORT_OPTIONS:MHRM} + @${INSTALL_PROGRAM} ${WRKSRC}/splat-hd ${PREFIX}/bin +.endif + @${INSTALL_SCRIPT} ${WRKSRC}/utils/postdownload ${PREFIX}/bin + @${INSTALL_MAN} ${WRKSRC}/docs/english/man/splat.1 ${MAN1PREFIX}/man/man1 .if !defined(NOPORTDOCS) - ${MKDIR} ${DOCSDIR} + @${MKDIR} ${DOCSDIR} . for f in ${PORTDOCS} - ${INSTALL_DATA} ${WRKSRC}/${f} ${DOCSDIR} + @${INSTALL_DATA} ${WRKSRC}/${f} ${DOCSDIR} . endfor .endif + @${LN} -s ${PREFIX}/bin/srtm2sdf ${PREFIX}/bin/srtm2sdf-hd .include <bsd.port.mk> diff --git a/comms/splat/distinfo b/comms/splat/distinfo index 298f999488a8..4c0fa193a5ea 100644 --- a/comms/splat/distinfo +++ b/comms/splat/distinfo @@ -1,2 +1,2 @@ -SHA256 (splat-1.3.0.tar.bz2) = 5075ced59c23155242332cceb6d04dce45bc092cc590f9ebfa47dce72900bd60 -SIZE (splat-1.3.0.tar.bz2) = 328074 +SHA256 (splat-1.4.0.tar.bz2) = f081951c68577234668ac2a1e6eff86e60e57e17c470d765900e9d1461058678 +SIZE (splat-1.4.0.tar.bz2) = 357433 diff --git a/comms/splat/files/patch-splat.cpp b/comms/splat/files/patch-splat.cpp deleted file mode 100644 index 49d37e43f78d..000000000000 --- a/comms/splat/files/patch-splat.cpp +++ /dev/null @@ -1,11 +0,0 @@ ---- splat.cpp.orig 2010-03-21 09:53:44.000000000 -0400 -+++ splat.cpp 2010-03-21 09:54:01.000000000 -0400 -@@ -2586,7 +2586,7 @@ - - if (fgets(string,80,fd)!=NULL) - { -- pointer=strchr(string,':'); -+ pointer=strchr(string,';'); - - if (pointer!=NULL) - *pointer=0; diff --git a/comms/splat/files/patch-utils_fontdata.c b/comms/splat/files/patch-utils_fontdata.c new file mode 100644 index 000000000000..4bc8afc28556 --- /dev/null +++ b/comms/splat/files/patch-utils_fontdata.c @@ -0,0 +1,12 @@ +--- utils/fontdata.c.orig 2012-11-05 15:44:52.000000000 -0500 ++++ utils/fontdata.c 2012-11-05 15:42:54.000000000 -0500 +@@ -39,7 +39,8 @@ + { + int x; + unsigned char line, input; +- FILE *infile, *outfile; ++ gzFile infile; ++ FILE *outfile; + + if (argc==2) + infile=gzopen(argv[1],"rb"); diff --git a/comms/splat/files/patch-utils_postdownload b/comms/splat/files/patch-utils_postdownload new file mode 100644 index 000000000000..be6818c9959f --- /dev/null +++ b/comms/splat/files/patch-utils_postdownload @@ -0,0 +1,8 @@ +--- utils/postdownload.orig 2012-11-03 03:56:52.000000000 -0500 ++++ utils/postdownload 2012-11-03 03:57:09.000000000 -0500 +@@ -1,4 +1,4 @@ +-#!/bin/bash ++#!/bin/sh + + # Simple script for processing of downloaded undelimited gzipped + # USGS DEM files, and converting them to SPLAT Data Files. |