Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 27 Jun 2014 19:59:47 +0000 (UTC)
From:      Stephen Hurd <shurd@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r359602 - in head/comms/gmfsk: . files
Message-ID:  <201406271959.s5RJxlqN074856@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: shurd
Date: Fri Jun 27 19:59:47 2014
New Revision: 359602
URL: http://svnweb.freebsd.org/changeset/ports/359602
QAT: https://qat.redports.org/buildarchive/r359602/

Log:
  - STAGEify
  - Make build with Clang
  - Add LICENSE
  - USES_GNOME=gnomehack -> USES=pathfix
  - Bump PORTREVISION
  
  PR:		191241
  Submitted by:	shurd
  Reviewed by:	skreuzer
  Approved by:	db, skreuzer (mentors)

Added:
  head/comms/gmfsk/files/patch-Makfile.in   (contents, props changed)
  head/comms/gmfsk/files/patch-help_gmfsk_C_Makefile.in   (contents, props changed)
  head/comms/gmfsk/files/patch-src_misc_cmplx.h   (contents, props changed)
  head/comms/gmfsk/files/patch-src_misc_filter-i386.h   (contents, props changed)
  head/comms/gmfsk/files/patch-src_misc_filter.h   (contents, props changed)
  head/comms/gmfsk/files/patch-src_misc_misc.c   (contents, props changed)
  head/comms/gmfsk/files/patch-src_misc_misc.h   (contents, props changed)
Deleted:
  head/comms/gmfsk/files/extra-patch-misc_misc.c
  head/comms/gmfsk/files/extra-patch-misc_misc.h
Modified:
  head/comms/gmfsk/Makefile

Modified: head/comms/gmfsk/Makefile
==============================================================================
--- head/comms/gmfsk/Makefile	Fri Jun 27 19:55:50 2014	(r359601)
+++ head/comms/gmfsk/Makefile	Fri Jun 27 19:59:47 2014	(r359602)
@@ -6,20 +6,23 @@ PORTVERSION=	0.6
 PORTREVISION=	12
 CATEGORIES=	comms audio hamradio
 MASTER_SITES=	http://gmfsk.connect.fi/ \
+		http://he.fi/pub/ham/unix/linux/hfmodems/ \
 		${MASTER_SITE_LOCAL}
 MASTER_SITE_SUBDIR=	db
 
 MAINTAINER=	carl@stagecraft.cx
 COMMENT=	The Gnome MFSK terminal program
 
+LICENSE=	GPLv2
+
 LIB_DEPENDS=	libfftw.so:${PORTSDIR}/math/fftw
 
 GNU_CONFIGURE=	yes
 CPPFLAGS+=	-I${LOCALBASE}/include
-LIBS+=		-L${LOCALBASE}/lib
+LDFLAGS+=	-L${LOCALBASE}/lib
 USES_CSTD=	gnu89
-USES=		gmake pkgconfig
-USE_GNOME=	libgnomeui gnomehack gnomeprefix
+USES=		gmake pkgconfig pathfix
+USE_GNOME=	libgnomeui gnomeprefix
 INSTALLS_OMF=	yes
 
 GCONF_SCHEMAS=	gmfsk.schemas
@@ -28,7 +31,6 @@ OPTIONS_DEFINE=	HAMLIB
 HAMLIB_DESC=	Enable HAMLIB Support
 OPTIONS_DEFAULT=	HAMLIB
 
-NO_STAGE=	yes
 .include <bsd.port.pre.mk>
 
 .if ${PORT_OPTIONS:MHAMLIB}
@@ -40,8 +42,7 @@ CONFIGURE_ARGS+=	--disable-hamlib
 .endif
 
 .if ( ${OSVERSION} >= 802502 && ${OSVERSION} < 900000 ) || ${OSVERSION} >= 900027
-EXTRA_PATCHES+=	${FILESDIR}/extra-patch-misc_misc.c
-EXTRA_PATCHES+=	${FILESDIR}/extra-patch-misc_misc.h
+CPPFLAGS+=	-DFBSD_HAS_LOG2
 .endif
 
 post-patch:

Added: head/comms/gmfsk/files/patch-Makfile.in
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/comms/gmfsk/files/patch-Makfile.in	Fri Jun 27 19:59:47 2014	(r359602)
@@ -0,0 +1,11 @@
+--- Makefile.in.orig	2014-06-24 21:35:13.000000000 -0700
++++ Makefile.in	2014-06-24 21:35:24.000000000 -0700
+@@ -598,8 +598,6 @@
+ 	    fi \
+ 	  done \
+ 	fi
+-	GCONF_CONFIG_SOURCE=$(GCONF_SCHEMA_CONFIG_SOURCE) \
+-	$(GCONFTOOL) --makefile-install-rule $(top_builddir)/gmfsk.schemas
+ 
+ dist-hook:
+ 	if test -d pixmaps; then \

Added: head/comms/gmfsk/files/patch-help_gmfsk_C_Makefile.in
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/comms/gmfsk/files/patch-help_gmfsk_C_Makefile.in	Fri Jun 27 19:59:47 2014	(r359602)
@@ -0,0 +1,10 @@
+--- help/gmfsk/C/Makefile.in.orig	2014-06-24 21:40:46.000000000 -0700
++++ help/gmfsk/C/Makefile.in	2014-06-24 21:40:55.000000000 -0700
+@@ -383,7 +383,6 @@
+ 	for file in $(omffile); do \
+ 		$(INSTALL_DATA) $$file.out $(DESTDIR)$(omf_dest_dir)/$$file; \
+ 	done
+-	-scrollkeeper-update -p $(scrollkeeper_localstate_dir) -o $(DESTDIR)$(omf_dest_dir)
+ 
+ uninstall-local-omf:
+ 	-for file in $(srcdir)/*.omf; do \

Added: head/comms/gmfsk/files/patch-src_misc_cmplx.h
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/comms/gmfsk/files/patch-src_misc_cmplx.h	Fri Jun 27 19:59:47 2014	(r359602)
@@ -0,0 +1,181 @@
+--- src/misc/cmplx.h.orig	2004-06-22 14:43:31.000000000 -0700
++++ src/misc/cmplx.h	2014-06-21 03:17:56.000000000 -0700
+@@ -40,10 +40,19 @@
+ 
+ typedef fftw_complex complex;
+ 
++#ifdef __OPTIMIZE__
++#define INLINE_EXTERN	static inline
++#else
++#define INLINE_EXTERN	extern
++#endif
++
+ /*
+  * Complex multiplication.
+  */
+-extern __inline__ complex cmul(complex x, complex y)
++INLINE_EXTERN  complex cmul(complex x, complex y)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	complex z;
+ 
+@@ -52,11 +61,15 @@
+ 
+ 	return z;
+ }
++#endif
+ 
+ /*
+  * Complex addition.
+  */
+-extern __inline__ complex cadd(complex x, complex y)
++INLINE_EXTERN  complex cadd(complex x, complex y)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	complex z;
+ 
+@@ -65,11 +78,15 @@
+ 
+ 	return z;
+ }
++#endif
+ 
+ /*
+  * Complex subtraction.
+  */
+-extern __inline__ complex csub(complex x, complex y)
++INLINE_EXTERN  complex csub(complex x, complex y)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	complex z;
+ 
+@@ -78,11 +95,15 @@
+ 
+ 	return z;
+ }
++#endif
+ 
+ /*
+  * Complex multiply-accumulate.
+  */
+-extern __inline__ complex cmac(complex *a, complex *b, int ptr, int len)
++INLINE_EXTERN  complex cmac(complex *a, complex *b, int ptr, int len)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	complex z;
+ 	int i;
+@@ -99,12 +120,16 @@
+ 
+ 	return z;
+ }
++#endif
+ 
+ /*
+  * Complex ... yeah, what??? Returns a complex number that has the
+  * properties: |z| = |x| * |y|  and  arg(z) = arg(y) - arg(x)
+  */
+-extern __inline__ complex ccor(complex x, complex y)
++INLINE_EXTERN  complex ccor(complex x, complex y)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	complex z;
+ 
+@@ -113,51 +138,75 @@
+ 
+ 	return z;
+ }
++#endif
+ 
+ /*
+  * Real part of the complex ???
+  */
+-extern __inline__ double ccorI(complex x, complex y)
++INLINE_EXTERN  double ccorI(complex x, complex y)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	return c_re(x) * c_re(y) + c_im(x) * c_im(y);
+ }
++#endif
+ 
+ /*
+  * Imaginary part of the complex ???
+  */
+-extern __inline__ double ccorQ(complex x, complex y)
++INLINE_EXTERN  double ccorQ(complex x, complex y)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	return c_re(x) * c_im(y) - c_im(x) * c_re(y);
+ }
++#endif
+ 
+ /*
+  * Modulo (absolute value) of a complex number.
+  */
+-extern __inline__ double cmod(complex x)
++INLINE_EXTERN  double cmod(complex x)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	return sqrt(c_re(x) * c_re(x) + c_im(x) * c_im(x));
+ }
++#endif
+ 
+ /*
+  * Square of the absolute value (power).
+  */
+-extern __inline__ double cpwr(complex x)
++INLINE_EXTERN  double cpwr(complex x)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	return (c_re(x) * c_re(x) + c_im(x) * c_im(x));
+ }
++#endif
+ 
+ /*
+  * Argument of a complex number.
+  */
+-extern __inline__ double carg(complex x)
++INLINE_EXTERN  double carg(complex x)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	return atan2(c_im(x), c_re(x));
+ }
++#endif
+ 
+ /*
+  * Complex square root.
+  */
+-extern __inline__ complex csqrt(complex x)
++INLINE_EXTERN  complex csqrt(complex x)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	complex z;
+ 
+@@ -166,5 +215,6 @@
+ 
+ 	return z;
+ }
++#endif
+ 
+ #endif

Added: head/comms/gmfsk/files/patch-src_misc_filter-i386.h
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/comms/gmfsk/files/patch-src_misc_filter-i386.h	Fri Jun 27 19:59:47 2014	(r359602)
@@ -0,0 +1,42 @@
+--- src/misc/filter-i386.h.orig	2004-06-16 13:32:13.000000000 -0700
++++ src/misc/filter-i386.h	2014-06-21 03:22:13.000000000 -0700
+@@ -32,7 +32,16 @@
+ 
+ #include <stdio.h>
+ 
+-extern inline float __mac_g(const float *a, const float *b, unsigned int size)
++#ifdef __OPTIMIZE__
++#define INLINE_EXTERN	static inline
++#else
++#define INLINE_EXTERN	extern
++#endif
++
++INLINE_EXTERN float __mac_g(const float *a, const float *b, unsigned int size)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	float sum = 0;
+ 	unsigned int i;
+@@ -41,8 +50,12 @@
+ 		sum += (*a++) * (*b++);
+ 	return sum;
+ }
++#endif
+ 
+-extern inline float __mac_c(const float *a, const float *b, unsigned int size)
++INLINE_EXTERN float __mac_c(const float *a, const float *b, unsigned int size)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	float f;
+ 
+@@ -971,6 +984,7 @@
+ 		return __mac_g(a, b, size);
+ 	}
+ }
++#endif
+ 
+ /* ---------------------------------------------------------------------- */
+ #endif				/* _FILTER_I386_H */

Added: head/comms/gmfsk/files/patch-src_misc_filter.h
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/comms/gmfsk/files/patch-src_misc_filter.h	Fri Jun 27 19:59:47 2014	(r359602)
@@ -0,0 +1,22 @@
+--- src/misc/filter.h.orig	2004-04-13 05:43:45.000000000 -0700
++++ src/misc/filter.h	2014-06-21 03:16:02.000000000 -0700
+@@ -39,7 +39,10 @@
+ 
+ 
+ #ifndef __HAVE_ARCH_MAC
+-extern __inline__ float mac(const float *a, const float *b, unsigned int size)
++INLINE_EXTERN float mac(const float *a, const float *b, unsigned int size)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	float sum = 0;
+ 	unsigned int i;
+@@ -48,6 +51,7 @@
+ 		sum += (*a++) * (*b++);
+ 	return sum;
+ }
++#endif
+ #endif				/* __HAVE_ARCH_MAC */
+ 
+ #endif				/* __OPTIMIZE__ */

Added: head/comms/gmfsk/files/patch-src_misc_misc.c
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/comms/gmfsk/files/patch-src_misc_misc.c	Fri Jun 27 19:59:47 2014	(r359602)
@@ -0,0 +1,20 @@
+--- src/misc/misc.c.orig	2004-04-13 05:49:04.000000000 -0700
++++ src/misc/misc.c	2014-06-21 02:32:50.000000000 -0700
+@@ -101,7 +101,7 @@
+ }
+ 
+ /* ---------------------------------------------------------------------- */
+-
++#ifndef FBSD_HAS_LOG2
+ /*
+  * Integer base-2 logarithm
+  */
+@@ -118,7 +118,7 @@
+ 
+ 	return y;
+ }
+-
++#endif
+ /* ---------------------------------------------------------------------- */
+ 
+ /*

Added: head/comms/gmfsk/files/patch-src_misc_misc.h
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/comms/gmfsk/files/patch-src_misc_misc.h	Fri Jun 27 19:59:47 2014	(r359602)
@@ -0,0 +1,235 @@
+--- src/misc/misc.h.orig	2004-04-13 05:45:19.000000000 -0700
++++ src/misc/misc.h	2014-06-21 03:17:38.000000000 -0700
+@@ -27,12 +27,21 @@
+ 
+ #include <math.h>
+ 
++#ifdef __OPTIMIZE__
++#define INLINE_EXTERN	static inline
++#else
++#define INLINE_EXTERN	extern
++#endif
++
+ /* ---------------------------------------------------------------------- */
+ 
+ /*
+  * Hamming weight (number of bits that are ones).
+  */
+-extern inline unsigned int hweight32(unsigned int w) 
++INLINE_EXTERN unsigned int hweight32(unsigned int w) 
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	w = (w & 0x55555555) + ((w >>  1) & 0x55555555);
+ 	w = (w & 0x33333333) + ((w >>  2) & 0x33333333);
+@@ -41,8 +50,12 @@
+ 	w = (w & 0x0000FFFF) + ((w >> 16) & 0x0000FFFF);
+ 	return w;
+ }
++#endif
+ 
+-extern inline unsigned int hweight16(unsigned short w)
++INLINE_EXTERN unsigned int hweight16(unsigned short w)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	w = (w & 0x5555) + ((w >> 1) & 0x5555);
+ 	w = (w & 0x3333) + ((w >> 2) & 0x3333);
+@@ -50,31 +63,43 @@
+ 	w = (w & 0x00FF) + ((w >> 8) & 0x00FF);
+ 	return w;
+ }
++#endif
+ 
+-extern inline unsigned int hweight8(unsigned char w)
++INLINE_EXTERN unsigned int hweight8(unsigned char w)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	w = (w & 0x55) + ((w >> 1) & 0x55);
+ 	w = (w & 0x33) + ((w >> 2) & 0x33);
+ 	w = (w & 0x0F) + ((w >> 4) & 0x0F);
+ 	return w;
+ }
++#endif
+ 
+ /* ---------------------------------------------------------------------- */
+ 
+ /*
+  * Parity function. Return one if `w' has odd number of ones, zero otherwise.
+  */
+-extern inline int parity(unsigned int w)
++INLINE_EXTERN int parity(unsigned int w)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	return hweight32(w) & 1;
+ }
++#endif
+ 
+ /* ---------------------------------------------------------------------- */
+ 
+ /*
+  * Reverse order of bits.
+  */
+-extern inline unsigned int rbits32(unsigned int w)
++INLINE_EXTERN unsigned int rbits32(unsigned int w)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	w = ((w >>  1) & 0x55555555) | ((w <<  1) & 0xAAAAAAAA);
+ 	w = ((w >>  2) & 0x33333333) | ((w <<  2) & 0xCCCCCCCC);
+@@ -83,8 +108,12 @@
+ 	w = ((w >> 16) & 0x0000FFFF) | ((w << 16) & 0xFFFF0000);
+ 	return w;
+ }
++#endif
+ 
+-extern inline unsigned short rbits16(unsigned short w)
++INLINE_EXTERN unsigned short rbits16(unsigned short w)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	w = ((w >> 1) & 0x5555) | ((w << 1) & 0xAAAA);
+ 	w = ((w >> 2) & 0x3333) | ((w << 2) & 0xCCCC);
+@@ -92,21 +121,29 @@
+ 	w = ((w >> 8) & 0x00FF) | ((w << 8) & 0xFF00);
+ 	return w;
+ }
++#endif
+ 
+-extern inline unsigned char rbits8(unsigned char w)
++INLINE_EXTERN unsigned char rbits8(unsigned char w)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	w = ((w >> 1) & 0x55) | ((w << 1) & 0xFF);
+ 	w = ((w >> 2) & 0x33) | ((w << 2) & 0xCC);
+ 	w = ((w >> 4) & 0x0F) | ((w << 4) & 0xF0);
+ 	return w;
+ }
++#endif
+ 
+ /* ---------------------------------------------------------------------- */
+-
++#ifndef FBSD_HAS_LOG2
+ /*
+  * Integer base-2 logarithm
+  */
+-extern inline int log2(unsigned int x)
++INLINE_EXTERN int log2(unsigned int x)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	int y = 0;
+ 
+@@ -119,13 +156,17 @@
+ 
+ 	return y;
+ }
+-
++#endif
++#endif
+ /* ---------------------------------------------------------------------- */
+ 
+ /*
+  * Gray encoding and decoding (8 bit)
+  */
+-extern inline unsigned char grayencode(unsigned char data)
++INLINE_EXTERN unsigned char grayencode(unsigned char data)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	unsigned char bits = data;
+ 
+@@ -139,50 +180,75 @@
+ 
+ 	return bits;
+ }
++#endif
+ 
+-extern inline unsigned char graydecode(unsigned char data)
++INLINE_EXTERN unsigned char graydecode(unsigned char data)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	return data ^ (data >> 1);
+ }
++#endif
+ 
+ /* ---------------------------------------------------------------------- */
+ 
+ /*
+  * Hamming window function
+  */
+-extern inline double hamming(double x)
++INLINE_EXTERN double hamming(double x)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+         return 0.54 - 0.46 * cos(2 * M_PI * x);
+ }
++#endif
+ 
+ /* ---------------------------------------------------------------------- */
+ 
+ /*
+  * Sinc etc...
+  */
+-extern inline double sinc(double x)
++INLINE_EXTERN double sinc(double x)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	return (fabs(x) < 1e-10) ? 1.0 : (sin(M_PI * x) / (M_PI * x));
+ }
++#endif
+ 
+-extern inline double cosc(double x)
++INLINE_EXTERN double cosc(double x)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	return (fabs(x) < 1e-10) ? 0.0 : ((1.0 - cos(M_PI * x)) / (M_PI * x));
+ }
++#endif
+ 
+ /* ---------------------------------------------------------------------- */
+ 
+-extern inline float clamp(float x, float min, float max)
++INLINE_EXTERN float clamp(float x, float min, float max)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	return (x < min) ? min : ((x > max) ? max : x);
+ }
++#endif
+ 
+ /* ---------------------------------------------------------------------- */
+ 
+-extern inline float decayavg(float average, float input, float weight)
++INLINE_EXTERN float decayavg(float average, float input, float weight)
++#ifndef __OPTIMIZE__
++;
++#else
+ {
+ 	return input * (1.0 / weight) + average * (1.0 - (1.0 / weight));
+ }
++#endif
+ 
+ /* ---------------------------------------------------------------------- */
+ 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201406271959.s5RJxlqN074856>