| Summary: | Add OPTIONS framework to multimedia/gpac-libgpac | ||||||
|---|---|---|---|---|---|---|---|
| Product: | Ports & Packages | Reporter: | josh.carroll | ||||
| Component: | Individual Port(s) | Assignee: | Li-Wen Hsu <lwhsu> | ||||
| Status: | Closed FIXED | ||||||
| Severity: | Affects Only Me | ||||||
| Priority: | Normal | ||||||
| Version: | Latest | ||||||
| Hardware: | Any | ||||||
| OS: | Any | ||||||
| Attachments: |
|
||||||
Here is an updated patch which adds a LIB_DEPEND for the libGL port if
the OPENGL option is selected (which is the default).
Thanks,
Josh
--- Makefile.orig 2009-02-13 20:55:45.000000000 -0500
+++ Makefile 2009-02-14 15:41:15.000000000 -0500
@@ -27,9 +27,25 @@
LIBVER= 1
CONFIGURE_ARGS= --cc="${CC}" \
- --extra-cflags="${CFLAGS} ${PTHREAD_CFLAGS} -fPIC" \
+ --enable-pic \
+ --extra-cflags="${CFLAGS} ${PTHREAD_CFLAGS}" \
--extra-ldflags="${LDFLAGS} ${PTHREAD_LIBS}"
+OPTIONS= OPENGL "OpenGL support" on \
+ IPV6 "IPv6 support" on
+
+.include <bsd.port.pre.mk>
+
+.if defined(WITHOUT_OPENGL)
+CONFIGURE_ARGS+= --disable-opengl
+.else
+LIB_DEPENDS+= GL.1:${PORTSDIR}/graphics/libGL
+.endif
+
+.if defined(WITHOUT_IPV6)
+CONFIGURE_ARGS+= --disable-ipv6
+.endif
+
post-patch:
${CHMOD} +x ${WRKSRC}/configure
@@ -41,4 +57,4 @@
${LN} -sf libgpac.so.${LIBVER} ${PREFIX}/lib/libgpac.so
${INSTALL_DATA} ${INSTALL_WRKSRC}/libgpac_static.a ${PREFIX}/lib
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
Responsible Changed From-To: freebsd-ports-bugs->freebsd-multimedia Fix synopsis and assign. Responsible Changed From-To: freebsd-multimedia->lwhsu I'll take it. jkim 2009-02-19 23:20:57 UTC
FreeBSD ports repository
Modified files:
multimedia/gpac-libgpac Makefile
Added files:
multimedia/gpac-libgpac/files patch-configure
Removed files:
multimedia/gpac-libgpac/files patch-src_Makefile
Log:
- Make IPv6 and OpenGL optional but turn them on by default[1].
- Fix build with OpenGL and register its dependency when it is enabled.
- Move FreeBSD-specific stuff into configure script from src/Makefile.
- Make portlint happy with PKGNAMESUFFIX.
PR: ports/131681[1], ports/131713, ports/131789
Revision Changes Path
1.17 +23 -8 ports/multimedia/gpac-libgpac/Makefile
1.1 +66 -0 ports/multimedia/gpac-libgpac/files/patch-configure (new)
1.3 +0 -19 ports/multimedia/gpac-libgpac/files/patch-src_Makefile (dead)
_______________________________________________
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"
State Changed From-To: open->closed jkim Committed. Thanks! |
I wanted to disable IPv6 and OpenGL support for the gpac-libgpac port, but there were no existing knobs. So I added OPTIONS support to this port and added two configurable options to enable/disable IPV6 and OpenGL. Both default to "on" and thus the port should build by default with the same options as before. I also made a minor change to the CONFIGURE_ARGS to add --enable-pic rather than manually adding -fPIC to the --extra-ldflags option. Below is the plain text of the patch (in case the attachment does not work - I seem to have problems attaching patches to PRs - user error, I know). Thanks! Josh Fix: diff -urN gpac-libgpac.old/Makefile gpac-libgpac/Makefile --- gpac-libgpac.old/Makefile 2009-02-14 13:52:47.000000000 -0500 +++ gpac-libgpac/Makefile 2009-02-14 14:54:56.000000000 -0500 @@ -27,9 +27,22 @@ LIBVER= 1 CONFIGURE_ARGS= --cc="${CC}" \ - --extra-cflags="${CFLAGS} ${PTHREAD_CFLAGS} -fPIC" \ - --extra-ldflags="${LDFLAGS} ${PTHREAD_LIBS}" \ - --disable-opengl + --enable-pic \ + --extra-cflags="${CFLAGS} ${PTHREAD_CFLAGS}" \ + --extra-ldflags="${LDFLAGS} ${PTHREAD_LIBS}" + +OPTIONS= OPENGL "OpenGL support" on \ + IPV6 "IPv6 support" on + +.include <bsd.port.pre.mk> + +.if defined(WITHOUT_OPENGL) +CONFIGURE_ARGS+= --disable-opengl +.endif + +.if defined(WITHOUT_IPV6) +CONFIGURE_ARGS+= --disable-ipv6 +.endif post-patch: ${CHMOD} +x ${WRKSRC}/configure @@ -42,4 +55,4 @@ ${LN} -sf libgpac.so.${LIBVER} ${PREFIX}/lib/libgpac.so ${INSTALL_DATA} ${INSTALL_WRKSRC}/libgpac_static.a ${PREFIX}/lib -.include <bsd.port.mk> +.include <bsd.port.post.mk> Patch attached with submission follows: How-To-Repeat: n/a