[MacPorts] #31851: subtitle ripper @0.3-4_1 fails to build under 10.7
MacPorts
noreply at macports.org
Tue Nov 1 12:37:52 PDT 2011
#31851: subtitle ripper @0.3-4_1 fails to build under 10.7
------------------------------------------+---------------------------------
Reporter: r.pedroche.novillo@… | Owner: macports-tickets@…
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version: 2.0.3
Keywords: getline | Port: subtitleripper
------------------------------------------+---------------------------------
subtitleripper port fails to build in Lion, resulting in the following
errors in main.log:
{{{
:info:build Compiling vobsub2pgm.c
:info:build vobsub.c:60: error: static declaration of ‘getline’ follows
non-static declaration
:info:build /usr/include/stdio.h:449: error: previous declaration of
‘getline’ was here
:info:build vobsub.c: In function ‘vobsub_open’:
:info:build vobsub.c:912: warning: cast to pointer from integer of
different size
:info:build make: *** [vobsub.o] Error 1
}}}
The package assumes there is no "getline" function in standard library,
but it seems to have been added in 10.7 (my Snow Leopard box lacks it).
The bug is in the original package itself, which seems unmantained, but it
is easily worked around with a trivial change to the port file (complete
Portfile attached):
{{{
--- Portfile.old 2011-02-23 07:00:16.000000000 +0100
+++ Portfile 2011-11-01 20:32:24.000000000 +0100
@@ -34,6 +34,12 @@
CFLAGS="${configure.cflags}" \
LDFLAGS="${configure.ldflags}"
+platform darwin 11 {
+ build.args CC="${configure.cc} ${configure.cc_archflags}" \
+ CFLAGS="${configure.cflags} -DHAVE_GETLINE" \
+ LDFLAGS="${configure.ldflags}"
+}
+
destroot {
xinstall -W ${worksrcpath} \
srttool \
}}}
--
Ticket URL: <https://trac.macports.org/ticket/31851>
MacPorts <http://www.macports.org/>
Ports system for Mac OS
More information about the macports-tickets
mailing list