Skip to content

Commit

Permalink
On 64-bit Solaris FILE is an opaque type, disable the rewind function…
Browse files Browse the repository at this point in the history
…ality.

Fixes package build.
  • Loading branch information
jperkin committed Dec 18, 2012
1 parent 2a7072d commit dc89ebc
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 7 deletions.
4 changes: 2 additions & 2 deletions audio/sox/distinfo
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
$NetBSD: distinfo,v 1.22 2012/07/04 09:27:37 adam Exp $
$NetBSD: distinfo,v 1.23 2012/12/18 14:42:29 jperkin Exp $

SHA1 (sox-14.4.0.tar.gz) = d809cab382c7a9d015491c69051a9d1c1a1a44f1
RMD160 (sox-14.4.0.tar.gz) = af1b6c02d29c988f9b0dfec9ca9ebb30949b0663
Size (sox-14.4.0.tar.gz) = 1105756 bytes
SHA1 (patch-aa) = e6f3d06450862795648622a017b2c696328872f5
SHA1 (patch-ak) = 806771b7f7f3e46c28036f9414f8e27b893813c2
SHA1 (patch-ak) = 1691ec39f3c96327f919388cd87b02fb6a99900b
22 changes: 17 additions & 5 deletions audio/sox/patches/patch-ak
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
$NetBSD: patch-ak,v 1.1 2010/12/27 05:32:49 obache Exp $
$NetBSD: patch-ak,v 1.2 2012/12/18 14:42:29 jperkin Exp $

* On DragonFly, FILE is hidden, only allowed to modify in __FILE_public.

--- src/formats.c.orig 2010-01-02 00:07:28.000000000 +0000
+++ src/formats.c
@@ -397,8 +397,14 @@ static void UNUSED rewind_pipe(FILE * fp
* Disable file-type pipe detection on 64-bit Solaris.

--- src/formats.c.orig 2012-03-04 22:54:16.000000000 +0000
+++ src/formats.c 2012-12-18 14:37:03.629252407 +0000
@@ -406,17 +406,22 @@
/* _FSTDIO is for Torek stdio (i.e. most BSD-derived libc's)
* In theory, we no longer need to check _NEWLIB_VERSION or __APPLE__ */
#if defined _FSTDIO || defined _NEWLIB_VERSION || defined __APPLE__
Expand All @@ -18,4 +20,14 @@ $NetBSD: patch-ak,v 1.1 2010/12/27 05:32:49 obache Exp $
+# endif
#elif defined __GLIBC__
fp->_IO_read_ptr = fp->_IO_read_base;
#elif defined _MSC_VER || defined __MINGW_H || defined _ISO_STDIO_ISO_H
-#elif defined _MSC_VER || defined __MINGW_H || defined _ISO_STDIO_ISO_H
+#elif defined _MSC_VER || defined __MINGW_H || (defined _ISO_STDIO_ISO_H && !(defined(__sun) && defined(_LP64)))
fp->_ptr = fp->_base;
#else
/* To fix this #error, either simply remove the #error line and live without
* file-type detection with pipes, or add support for your compiler in the
* lines above. Test with cat monkey.au | ./sox --info - */
- #error FIX NEEDED HERE
#define NO_REWIND_PIPE
(void)fp;
#endif

0 comments on commit dc89ebc

Please sign in to comment.