Summary: | multimedia/handbrake hard codes gcc / ignores CC | ||
---|---|---|---|
Product: | Ports & Packages | Reporter: | Gerald Pfeifer <gerald> |
Component: | Individual Port(s) | Assignee: | Thomas Zander <riggs> |
Status: | Closed FIXED | ||
Severity: | Affects Some People | CC: | naito.yuichiro, riggs |
Priority: | --- | ||
Version: | Latest | ||
Hardware: | Any | ||
OS: | Any | ||
Bug Depends on: | |||
Bug Blocks: | 218330 |
Description
Gerald Pfeifer
2017-04-07 22:06:38 UTC
Do you mean the result of following log? http://package18.nyi.freebsd.org/data/110amd64-default-PR218330/2017-04-06_19h28m41s/logs/errors/handbrake-1.0.3.log HandBrake uses original configure script written in Python that uses hard coded 'gcc'. I made a quick fix for the configure script. Does this work as you expect? ``` Index: files/patch-make_configure.py =================================================================== --- files/patch-make_configure.py (revision 437996) +++ files/patch-make_configure.py (working copy) @@ -36,6 +36,15 @@ grp.add_option( '--flatpak', default=False, action='store_true', help=h ) cli.add_option_group( grp ) +@@ -1517,7 +1520,7 @@ try: + class Tools: + ar = ToolProbe( 'AR.exe', 'ar' ) + cp = ToolProbe( 'CP.exe', 'cp' ) +- gcc = ToolProbe( 'GCC.gcc', 'gcc', IfHost( 'gcc-4', '*-*-cygwin*' )) ++ gcc = ToolProbe( 'GCC.gcc', 'gcc', IfHost( 'gcc-4', '*-*-cygwin*' ), IfHost( os.environ['CC'], '*-*-freebsd*' )) + + if host.match( '*-*-darwin*' ): + gmake = ToolProbe( 'GMAKE.exe', 'make', 'gmake' ) @@ -1924,10 +1927,15 @@ int main() doc.add( 'GCC.sysroot', '' ) doc.add( 'GCC.minver', '' ) ``` (In reply to naito.yuichiro from comment #1) This patch makes it pick up CC. I could also get it to use ccache with it. I'll commit a variant of it (as it is useful in either case), then Gerald can check whether we need something in addition. A commit references this bug: Author: riggs Date: Sat Apr 8 13:49:14 UTC 2017 New revision: 438043 URL: https://svnweb.freebsd.org/changeset/ports/438043 Log: Honour CC var instead of hardcoded gcc PR: 218470 Submitted by: naito.yuichiro@gmail.com Reported by: gerald Changes: head/multimedia/handbrake/Makefile head/multimedia/handbrake/files/patch-make_configure.py Thanks again, closing for now. @gerald, feel free to reopen if we need additional effort here. Thank you so much, Naito-san, and thanks for your help getting this in, Thomas! |