Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 18 Mar 2013 11:04:02 +0000 (UTC)
From:      Pietro Cerutti <gahr@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r314551 - in head/audio/sbagen: . files
Message-ID:  <201303181104.r2IB4253009877@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: gahr
Date: Mon Mar 18 11:04:01 2013
New Revision: 314551
URL: http://svnweb.freebsd.org/changeset/ports/314551

Log:
  - Fix build with clang
  - While at it, get rid of PTHREAD_LIBS

Added:
  head/audio/sbagen/files/
  head/audio/sbagen/files/patch-sbagen.c   (contents, props changed)
Modified:
  head/audio/sbagen/Makefile   (contents, props changed)

Modified: head/audio/sbagen/Makefile
==============================================================================
--- head/audio/sbagen/Makefile	Mon Mar 18 10:23:47 2013	(r314550)
+++ head/audio/sbagen/Makefile	Mon Mar 18 11:04:01 2013	(r314551)
@@ -19,12 +19,8 @@ OPTIONS_DEFINE=	DOCS EXAMPLES
 
 .include <bsd.port.options.mk>
 
-post-patch:
-	@${REINPLACE_CMD} -e 's,linux/soundcard\.h,sys/soundcard.h,g' \
-		${WRKSRC}/sbagen.c
-
 do-build:
-	(cd ${WRKSRC} && ${CC} ${CFLAGS} -DT_LINUX ${PTHREAD_LIBS} -lm \
+	(cd ${WRKSRC} && ${CC} ${CFLAGS} -DT_LINUX -pthread -lm \
 		sbagen.c -o sbagen)
 
 do-install:

Added: head/audio/sbagen/files/patch-sbagen.c
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/audio/sbagen/files/patch-sbagen.c	Mon Mar 18 11:04:01 2013	(r314551)
@@ -0,0 +1,29 @@
+--- sbagen.c.orig	2013-03-18 12:02:21.000000000 +0100
++++ sbagen.c	2013-03-18 12:02:43.000000000 +0100
+@@ -141,7 +141,7 @@
+ #endif
+ 
+ #ifdef OSS_AUDIO
+- #include <linux/soundcard.h>
++ #include <sys/soundcard.h>
+  //WAS: #include <sys/soundcard.h>
+ #endif
+ #ifdef WIN_AUDIO
+@@ -181,7 +181,7 @@
+ void warn(char *fmt, ...) ;
+ void * Alloc(size_t len) ;
+ char * StrDup(char *str) ;
+-inline int calcNow() ;
++static inline int calcNow() ;
+ void loop() ;
+ void outChunk() ;
+ void corrVal(int ) ;
+@@ -1207,7 +1207,7 @@
+   time_ref_ms= 1000*tt->tm_sec + 60000*tt->tm_min + 3600000*tt->tm_hour;
+ }  
+ 
+-inline int  
++static inline int  
+ calcNow() {
+   struct timeval tv;
+   if (0 != gettimeofday(&tv, 0)) error("Can't get current time");



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