Opened 15 years ago
Closed 15 years ago
#9400 closed Bug Report (Fixed)
MacOS X Compile failure
| Reported by: | Owned by: | Nigel | |
|---|---|---|---|
| Priority: | minor | Milestone: | unknown |
| Component: | Ports - OSX | Version: | 0.24-fixes |
| Severity: | medium | Keywords: | |
| Cc: | Ticket locked: | no |
Description
See attached build log. Fails as follows:
CC ffmpeg.o ffmpeg.c: In function ‘getmaxrss’: ffmpeg.c:3845: error: ‘struct rusage’ has no member named ‘ru_maxrss’ make[1]: *** [ffmpeg.o] Error 1 make[1]: *** Waiting for unfinished jobs.... make: *** [external/FFmpeg] Error 2 [osx-pkg] Failed system call: " /usr/bin/make -j3 " with error code 2 Died at ./osx-packager.pl line 1017.
My working copy of osx-packager.pl also attached with rudimentary support for syncing with git.
Attachments (3)
Change History (7)
by , 15 years ago
| Attachment: | MacOS build fail 23Dec2010.txt added |
|---|
by , 15 years ago
| Attachment: | osx-packager_WCT_git.pl added |
|---|
comment:1 by , 15 years ago
comment:2 by , 15 years ago
Nigel's current Git mods to osx-packager.pl can be found here: https://github.com/MythTV/packaging/compare/Use-Git and latest version here: https://github.com/MythTV/packaging/raw/98927e37ee43a9dea91411652ff41ccc0f878ee0/OSX/build/osx-packager.pl
by , 15 years ago
| Attachment: | osx-packager.pl build fail 02Jan2011.txt added |
|---|
comment:3 by , 15 years ago
I've been trying to test the fixes in "mythtv/master commit: 486dfa729" but the build keeps failing (verbose logs attached). Note that I tried a distclean before this run.
Also, tried to use the gitrev option to switch to the "OSX-fixes" branch. This branch doesn't exist in the Packaging repository and therefore osx-packager.pl dies trying to checkout a non-existent branch. Not sure if this is an ongoing issue or just a gotcha during development.
comment:4 by , 15 years ago
| Resolution: | → Fixed |
|---|---|
| Status: | new → closed |
Commit 3ec48f2 should fix the originally reported fault, though I can only test on 10.6 these days.
That build error (Python related) is a new one to me. I will investigate/email in dev list.
I hadn't thought about creating an OSX-fixes in packaging (not enough cross-platform stuff in packaging to warrant it), but since it doesn't take up any extra space, I just created it. It should now work, but if not, run the script with --gitrev OSX-fixes to checkout mythtv, then with --nohead to skip Git checkouts and actually do the build.

On Mac OS X, /usr/include/sys/resource.h contains:
struct rusage { struct timeval ru_utime; /* user time used (PL) */ struct timeval ru_stime; /* system time used (PL) */ #if defined(_POSIX_C_SOURCE) && !defined(_DARWIN_C_SOURCE) long ru_opaque[14]; /* implementation defined */ #else /* (!_POSIX_C_SOURCE || _DARWIN_C_SOURCE) */ /* * Informational aliases for source compatibility with programs * that need more information than that provided by standards, * and which do not mind being OS-dependent. */ long ru_maxrss; /* max resident set size (PL) */which, because _POSIX_C_SOURCE is defined, is half of the cause of this fault.
The other half is commit 8c6de4675, which enabled building the ffmpeg binary - we never used to compile it before.
Until someone researches the ffmpeg-user or ffmpeg-devel archives to find out the real story, it is simplest to just disable it on OS X:
% git diff diff --git a/mythtv/configure b/mythtv/configure index 7099422..c0e038c 100755 --- a/mythtv/configure +++ b/mythtv/configure @@ -3046,6 +3046,7 @@ case $target_os in enable backend enable darwin disable dvb + disable ffmpeg # Prevent linker problems on default Intel 10.5 XCode: ldver=$(ld -v 2>&1 | sed -e s/^[^-]*-//) osxver=$(uname -r | cut -c 1) %