Opened 14 years ago

Closed 12 years ago

#26528 closed defect (fixed)

avidemux 2.5.3 uses ffmpeg port headers instead of its own

Reported by: ak.ml@… Owned by: macports-tickets@…
Priority: Normal Milestone:
Component: ports Version: 1.9.1
Keywords: Cc: raimue (Rainer Müller), cssdev, ak.ml@…, icemac (Michael Howitz)
Port: avidemux

Description

avidemux 2.5.3 fails to build at 59%.

It looks like it tries to use the headers of the ffmpeg port rather than its own for some plugins.

When ffmpeg is deactivated, avidemux compiles fine.

MacIntel 10.5.8.

Attachments (2)

main.log.gz (92.9 KB) - added by ak.ml@… 14 years ago.
main.log (168.7 KB) - added by ak.ml@… 14 years ago.
After r71689

Download all attachments as: .zip

Change History (11)

Changed 14 years ago by ak.ml@…

Attachment: main.log.gz added

comment:1 Changed 14 years ago by raimue (Rainer Müller)

Cc: css@… added
Keywords: avidemux ffmpeg removed

The problem is, cmake always has -I/opt/local/include hardcoded and adds other paths specified with include_directories(...) at the end. Of course, this ends up in the wrong order, with -I/opt/local/include at the front while it should be the last.

I tried to fix this in r71635 by adding this flag to cmake, as described in their documentation:

-DCMAKE_INCLUDE_DIRECTORIES_BEFORE=ON

For me on Snow Leopard 10.6.4 using cmake @2.8.2_2+gui. ffmpeg @0.6_2 was active and installed at the same time, the build still was okay. But this could still mean it is picking up wrong headers :-)

And actually, you are right the order is still wrong even for me while building plugins:

...
-I/opt/local/include -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_multimedia_avidemux/work/avidemux_2.5.3/avidemux/ADM_libraries/ffmpeg
...

I am adding css@ as cmake maintainer to CC as he might have a hint where to look at for this problem. I am clueless at the moment...

comment:2 Changed 14 years ago by ak.ml@…

Cc: ak.ml@… added

Cc Me!

comment:3 in reply to:  1 ; Changed 14 years ago by cssdev

Replying to raimue@…:

I tried to fix this in r71635 by adding this flag to cmake, as described in their documentation:

-DCMAKE_INCLUDE_DIRECTORIES_BEFORE=ON

I'm pretty sure that case is important. Try -DCMAKE_include_directories_BEFORE:BOOL=ON instead.

comment:4 in reply to:  3 ; Changed 14 years ago by raimue (Rainer Müller)

Resolution: fixed
Status: newclosed

Replying to css@…:

I'm pretty sure that case is important. Try -DCMAKE_include_directories_BEFORE:BOOL=ON instead.

Damn. Thank you for your help, this seems to solve the problem for me now even for the plugins.

Committed in r71689.

comment:5 in reply to:  4 Changed 14 years ago by ak.ml@…

Damn. Thank you for your help, this seems to solve the problem for me now even for the plugins.

Committed in r71689.

I'm still having some issues compiling.

Changed 14 years ago by ak.ml@…

Attachment: main.log added

After r71689

comment:6 Changed 14 years ago by raimue (Rainer Müller)

Resolution: fixed
Status: closedreopened

comment:7 Changed 14 years ago by icemac (Michael Howitz)

Cc: mh@… added

Cc Me!

comment:8 Changed 12 years ago by kato23@…

The CMake 2.8 Documentation of 2012-03-30 apparently has switched back to CMAKE_INCLUDE_DIRECTORIES_BEFORE (from previous CMAKE_include_directories_BEFORE).

Editing the avidemux Portfile with respect to this change allows avidemux @2.5.3_7+aac+dts+lame+ogg+x264+xvid to build successfully on Mac OS X 10.6.8.

# edit the avidemux Portfile
cd "$(port dir avidemux)"
cat <<-'EOF' | sudo ed -s Portfile
H
/-DCMAKE_include_directories_BEFORE=ON/s//-DCMAKE_INCLUDE_DIRECTORIES_BEFORE=ON/
wq
EOF

(Deactivating an already installed ffmpeg port worked for me as well.)

(Note: I installed avidemux in a custom location as described in the MacPorts Guide, 2.3.4. Install Multiple MacPorts Copies.)

comment:9 Changed 12 years ago by jmroot (Joshua Root)

Resolution: fixed
Status: reopenedclosed
Note: See TracTickets for help on using tickets.