Bug 167985 - [patch] comms/spandsp-devel port build fails on FreeBSD 10
Summary: [patch] comms/spandsp-devel port build fails on FreeBSD 10
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Mark Linimon
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-05-17 00:20 UTC by Don Lewis
Modified: 2012-09-01 18:21 UTC (History)
1 user (show)

See Also:


Attachments
file.diff (741 bytes, patch)
2012-05-17 00:20 UTC, Don Lewis
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Don Lewis freebsd_committer freebsd_triage 2012-05-17 00:20:02 UTC
The port build fails here:

libtool: compile:  cc -DHAVE_CONFIG_H -I. -I. -I. -I.. -I/usr/local/include -I/usr/local/include/libxml2 -DNDEBUG -std=gnu99 -ffast-math -Wall -Wunused-variable -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -fvisibility=hidden -DSWITCH_API_VISIBILITY=1 -DHAVE_VISIBILITY=1 -O2 -pipe -fno-strict-aliasing -MT awgn.lo -MD -MP -MF .deps/awgn.Tpo -c awgn.c  -fPIC -DPIC -o .libs/awgn.o
awgn.c: In function 'awgn_init_dbov':
awgn.c:111: error: 'cpowl' undeclared (first use in this function)
awgn.c:111: error: (Each undeclared identifier is reported only once
awgn.c:111: error: for each function it appears in.)
awgn.c:111: error: 'cpow' undeclared (first use in this function)
awgn.c:111: error: 'cpowf' undeclared (first use in this function)
awgn.c:111: error: 'powl' undeclared (first use in this function)
awgn.c: In function 'awgn':
awgn.c:167: error: 'clogl' undeclared (first use in this function)
awgn.c:167: error: 'clog' undeclared (first use in this function)
awgn.c:167: error: 'clogf' undeclared (first use in this function)
awgn.c:167: error: 'logl' undeclared (first use in this function)
gmake[2]: *** [awgn.lo] Error 1

The port builds on FreeBSD 8, but only because the above errors are warnings.

The problem is that this port brings in <tgmath.h> which redefines pow()
and log() in terms of the above functions, but these functions are not
implemented in FreeBSD.

Fix: This port does not appear to really need to use <tgmath.h> as it already
passes the correct types to pow() and log(). 

One possible fix would be to remove the check for this header from
configure.ac and regenerate configure.

I worked around this problem by creating a config.cache file that tells
configure that we don't have <tgmath.h>.  This is the patch that I made
to my local copy of the port:
How-To-Repeat: 
Attempt to build the port on FreeBSD 10-CURRENT.
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2012-05-17 00:20:16 UTC
Responsible Changed
From-To: freebsd-ports-bugs->gnome

Over to maintainer (via the GNATS Auto Assign Tool)
Comment 2 Jeremy Messenger freebsd_committer freebsd_triage 2012-05-19 21:17:12 UTC
Responsible Changed
From-To: gnome->freebsd-ports-bugs

Not maintain by us, move to freebsd-ports-bugs.
Comment 3 dfilter service freebsd_committer freebsd_triage 2012-05-30 07:34:04 UTC
linimon     2012-05-30 06:33:52 UTC

  FreeBSD ports repository

  Modified files:
    comms/spandsp-devel  Makefile 
  Log:
  Attempt to fix build on -current.
  
  PR:             ports/167985
  Submitted by:   truckman
  
  Revision  Changes    Path
  1.29      +2 -1      ports/comms/spandsp-devel/Makefile
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 4 Mark Linimon freebsd_committer freebsd_triage 2012-05-30 07:34:06 UTC
State Changed
From-To: open->closed

Committed, thanks.
Comment 5 dfilter service freebsd_committer freebsd_triage 2012-05-31 05:40:33 UTC
linimon     2012-05-31 04:40:22 UTC

  FreeBSD ports repository

  Added files:
    comms/spandsp-devel/files patch-configure 
  Log:
  Disable the test for tgmath.h.  From the PR:
  
    This port does not appear to really need to use <tgmath.h> as it already
    passes the correct types to pow() and log().
  
  PR:             ports/167985 (forgotten piece)
  
  Revision  Changes    Path
  1.1       +159 -0    ports/comms/spandsp-devel/files/patch-configure (new)
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 6 dfilter service freebsd_committer freebsd_triage 2012-09-01 18:18:56 UTC
Author: crees
Date: Sat Sep  1 17:18:41 2012
New Revision: 303500
URL: http://svn.freebsd.org/changeset/ports/303500

Log:
  Fix build on FreeBSD 10
  
  PR:		ports/167985 (based on)
  Submitted by:	truckman
  Obtained from:	comms/spandsp-devel

Added:
  head/comms/spandsp/files/
  head/comms/spandsp/files/patch-configure.ac
     - copied unchanged from r303495, head/comms/spandsp-devel/files/patch-configure.ac
Modified:
  head/comms/spandsp/Makefile

Modified: head/comms/spandsp/Makefile
==============================================================================
--- head/comms/spandsp/Makefile	Sat Sep  1 17:16:50 2012	(r303499)
+++ head/comms/spandsp/Makefile	Sat Sep  1 17:18:41 2012	(r303500)
@@ -18,7 +18,7 @@ COMMENT=	A DSP library and software FAX 
 LIB_DEPENDS=	tiff.4:${PORTSDIR}/graphics/tiff
 
 GNU_CONFIGURE=	yes
-USE_AUTOTOOLS=	libtool
+USE_AUTOTOOLS=	libtool autoconf
 USE_GMAKE=	yes
 
 CPPFLAGS+=	-I${LOCALBASE}/include

Copied: head/comms/spandsp/files/patch-configure.ac (from r303495, head/comms/spandsp-devel/files/patch-configure.ac)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/comms/spandsp/files/patch-configure.ac	Sat Sep  1 17:18:41 2012	(r303500, copy of r303495, head/comms/spandsp-devel/files/patch-configure.ac)
@@ -0,0 +1,10 @@
+--- configure.ac.orig	2012-09-01 12:05:10.795461874 +0100
++++ configure.ac	2012-09-01 12:05:47.473457036 +0100
+@@ -194,7 +194,6 @@
+ AC_CHECK_HEADERS([string.h])
+ AC_CHECK_HEADERS([strings.h])
+ AC_CHECK_HEADERS([malloc.h])
+-AC_CHECK_HEADERS([tgmath.h], [INSERT_TGMATH_HEADER="#include <tgmath.h>"])
+ AC_CHECK_HEADERS([math.h], [INSERT_MATH_HEADER="#include <math.h>"])
+ AC_CHECK_HEADERS([float.h])
+ AC_CHECK_HEADERS([fcntl.h])
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 7 Chris Rees freebsd_committer freebsd_triage 2012-09-01 18:21:37 UTC
Responsible Changed
From-To: freebsd-ports-bugs->linimon

Committed by you.