Opened 16 months ago

Closed 16 months ago

Last modified 16 months ago

#66465 closed defect (fixed)

ffmpeg @4.4.2_3+gpl2+jack+nonfree+x11 fails to configure after x265 3.4_0 < 3.4_1 upgrade on some systems TBA

Reported by: tehcog (tehcog) Owned by: kencu (Ken)
Priority: Normal Milestone:
Component: ports Version: 2.8.0
Keywords: Cc: mascguy (Christopher Nielsen), dbevans (David B. Evans), jeremyhu (Jeremy Huddleston Sequoia), RobK88, dershow, pckizer, elventear (Pepe Barbe), kencu (Ken), janngobble
Port: ffmpeg x265

Description

:info:configure ERROR: x265 not found using pkg-config

please see attached main.log

Attachments (2)

ffmpeg_main.log (22.4 KB) - added by tehcog (tehcog) 16 months ago.
main.log
ffmpeg_config.log (757.2 KB) - added by tehcog (tehcog) 16 months ago.
config.log

Download all attachments as: .zip

Change History (27)

Changed 16 months ago by tehcog (tehcog)

Attachment: ffmpeg_main.log added

main.log

comment:1 Changed 16 months ago by tehcog (tehcog)

Thanks for your help.

comment:2 Changed 16 months ago by RobK88

The x265 upgrade also breaks ffmpeg @4.4.2_3+gpl2+libdc1394+nonfree+x11 on Lion. It also looks like the x265 upgrade breaks libheif too.

See below.

--->  Scanning binaries for linking errors
--->  Found 12 broken files, matching files to ports     
--->  Found 2 broken ports, determining rebuild order
You can always run 'port rev-upgrade' again to fix errors.
The following ports will be rebuilt:
 libheif @1.13.0
 ffmpeg @4.4.2+gpl2+libdc1394+nonfree+x11
Continue? [Y/n]: Y
--->  Computing dependencies for libheif
--->  Cleaning libheif
--->  Computing dependencies for ffmpeg
--->  Cleaning ffmpeg
--->  Scanning binaries for linking errors
--->  Found 12 broken files, matching files to ports     
--->  Found 2 broken ports, determining rebuild order
--->  Rebuilding in order
     libheif @1.13.0_0
     ffmpeg @4.4.2_3+gpl2+libdc1394+nonfree+x11
--->  Computing dependencies for libheif
--->  Fetching distfiles for libheif
--->  Verifying checksums for libheif
--->  Extracting libheif
--->  Configuring libheif
--->  Building libheif                                   
--->  Staging libheif into destroot                      
--->  Unable to uninstall libheif @1.13.0_0, the following ports depend on it:
--->  	gd2 @2.3.3_1+x11
--->  	ImageMagick @6.9.11-60_3+x11
Warning: Uninstall forced.  Proceeding despite dependencies.
--->  Deactivating libheif @1.13.0_0
--->  Cleaning libheif
--->  Uninstalling libheif @1.13.0_0
--->  Cleaning libheif
--->  Computing dependencies for libheif
--->  Installing libheif @1.13.0_0
--->  Activating libheif @1.13.0_0
--->  Cleaning libheif
--->  Computing dependencies for ffmpeg
--->  Fetching distfiles for ffmpeg
--->  Verifying checksums for ffmpeg
--->  Extracting ffmpeg
--->  Applying patches to ffmpeg
--->  Configuring ffmpeg
Error: Failed to configure ffmpeg: configure failure: command execution failed
Error: See /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_multimedia_ffmpeg/ffmpeg/main.log for details.
Error: rev-upgrade failed: Error rebuilding ffmpeg
Error: Follow https://guide.macports.org/#project.tickets if you believe there is a bug.
bash-3.2$ 

comment:3 Changed 16 months ago by RobK88

Cc: RobK88 added

comment:4 Changed 16 months ago by dershow

Cc: dershow added

comment:5 Changed 16 months ago by jmroot (Joshua Root)

Summary: ffmpeg @4.4.2_3+gpl2+jack+nonfree+x11 fails to configure on mavericks after x265 3.4_0 < 3.4_1 upgradeffmpeg @4.4.2_3+gpl2+jack+nonfree+x11 fails to configure after x265 3.4_0 < 3.4_1 upgrade

comment:6 Changed 16 months ago by pckizer

Cc: pckizer added

comment:7 Changed 16 months ago by elventear (Pepe Barbe)

Cc: elventear added

comment:8 Changed 16 months ago by jmroot (Joshua Root)

Cc: kencu janngobble added

comment:9 Changed 16 months ago by jmroot (Joshua Root)

Port: x265 added

comment:10 Changed 16 months ago by janngobble

This seems to be something to do with libx265.dylib not being built.

@KenCu, could this have something to do w/c++11?

Zhenfu Shi had issues over on GitHub with the library not being built, but as he said, -DENABLE_SHARED=OFF was there before this change. (I didn't add it and have no idea why that would be needed for this one addition).

So, why would this change cause that file to disappear?

One more thing: @tehcog's build doesn't have "highdepth" - which is the only place my change applies.

comment:11 Changed 16 months ago by kencu (Ken)

Yeah, I know -- one little thing, should be just fine, but the whole house of cards comes falling down...

I built libx265 locally before I committed the PR. The new configure argument requires c++11

https://bitbucket.org/multicoreware/x265_git/src/4da1198a94028026ce96ba1781d3c7842e74e173/source/CMakeLists.txt#lines-227

so the Portfile was set to require a compiler that can deliver that.

comment:12 Changed 16 months ago by kencu (Ken)

according to this <https://ports.macports.org/port/x265/details/> the new version built on every system, and has the file

/opt/local/lib/libx265.dylib

so must be something else TBD.

comment:13 in reply to:  10 ; Changed 16 months ago by tehcog (tehcog)

Replying to janngobble:

One more thing: @tehcog's build doesn't have "highdepth" - which is the only place my change applies.

this is the version of x265 that I had installed prior to the upgrade:

The following ports are currently installed:
  x265 @3.4_0+highdepth (active)

comment:14 in reply to:  13 Changed 16 months ago by janngobble

Replying to tehcog:

Replying to janngobble:

One more thing: @tehcog's build doesn't have "highdepth" - which is the only place my change applies.

this is the version of x265 that I had installed prior to the upgrade:

The following ports are currently installed:
  x265 @3.4_0+highdepth (active)

understood.

comment:15 in reply to:  12 Changed 16 months ago by tehcog (tehcog)

Replying to kencu:

according to this <https://ports.macports.org/port/x265/details/> the new version built on every system, and has the file

/opt/local/lib/libx265.dylib

so must be something else TBD.

this is what I have for the dylib:

xxxx::xxXXXxx { /opt/local/lib }-> lal | rg4 x265
2178:.rwxr-xr-x   18M root     admin  7 Feb  2021  libx265.192.dylib
2179:.rw-r--r--   20M root     admin  7 Feb  2021  libx265.a
2180:lrwxr-xr-x    17 root     admin  7 Feb  2021  libx265.dylib -> libx265.192.dylib

comment:16 Changed 16 months ago by kencu (Ken)

ffmpeg +gpl2+jack+nonfree+x11 configures just fine for me on Ventura Intel with the new libx265 installed.

Building it now.

I have:

% port contents x265
Port x265 contains:
  /opt/local/bin/x265
  /opt/local/include/x265.h
  /opt/local/include/x265_config.h
  /opt/local/lib/libx265.192.dylib
  /opt/local/lib/libx265.a
  /opt/local/lib/libx265.dylib
  /opt/local/lib/pkgconfig/x265.pc
Last edited 16 months ago by kencu (Ken) (previous) (diff)

comment:17 Changed 16 months ago by kencu (Ken)

maybe someone with a system that won't configure it can post up their config.log so I can take a look.

comment:18 in reply to:  17 ; Changed 16 months ago by janngobble

Replying to kencu:

maybe someone with a system that won't configure it can post up their config.log so I can take a look.

@tehcog?

comment:19 Changed 16 months ago by kencu (Ken)

built no problem:

% port -v installed x265 | grep active
  x265 @3.4_1 (active) requested_variants='' platform='darwin 22' archs='x86_64' date='2022-12-14T15:55:03-0800'

% port -v installed ffmpeg
The following ports are currently installed:
  ffmpeg @4.4.2_3+gpl2+jack+nonfree+x11 (active) requested_variants='+gpl2+jack+nonfree+x11' platform='darwin 22' archs='x86_64' date='2022-12-14T16:27:45-0800'

comment:20 Changed 16 months ago by kencu (Ken)

Summary: ffmpeg @4.4.2_3+gpl2+jack+nonfree+x11 fails to configure after x265 3.4_0 < 3.4_1 upgradeffmpeg @4.4.2_3+gpl2+jack+nonfree+x11 fails to configure after x265 3.4_0 < 3.4_1 upgrade on some systems TBA

comment:21 Changed 16 months ago by mouse07410 (Mouse)

First, on my machine (MacOS 12.6.2 with Xcode-14.2) it does not create libx265.dylib:

$ sudo port install x265 +highdepth
--->  Computing dependencies for x265
--->  Fetching archive for x265
--->  Attempting to fetch x265-3.4_1+highdepth.darwin_21.x86_64.tbz2 from https://packages.macports.org/x265
--->  Attempting to fetch x265-3.4_1+highdepth.darwin_21.x86_64.tbz2 from https://nue.de.packages.macports.org/x265
--->  Attempting to fetch x265-3.4_1+highdepth.darwin_21.x86_64.tbz2 from http://atl.us.packages.macports.org/x265
--->  Fetching distfiles for x265
--->  Verifying checksums for x265
--->  Extracting x265
--->  Applying patches to x265
--->  Configuring x265
--->  Building x265                                      
--->  Staging x265 into destroot                         
--->  Installing x265 @3.4_1+highdepth
--->  Activating x265 @3.4_1+highdepth
--->  Cleaning x265
--->  Scanning binaries for linking errors
--->  Found 7 broken files, matching files to ports      
--->  Found 1 broken port, determining rebuild order
You can always run 'port rev-upgrade' again to fix errors.
The following ports will be rebuilt: ffmpeg @4.4.2+gpl2+gpl3+libdc1394+librtmp+nonfree
Continue? [Y/n]: 
--->  Computing dependencies for ffmpeg
--->  Cleaning ffmpeg
--->  Scanning binaries for linking errors
--->  Found 7 broken files, matching files to ports      
--->  Found 1 broken port, determining rebuild order
--->  Rebuilding in order
     ffmpeg @4.4.2_3+gpl2+gpl3+libdc1394+librtmp+nonfree
--->  Computing dependencies for ffmpeg
--->  Fetching distfiles for ffmpeg
--->  Verifying checksums for ffmpeg
--->  Extracting ffmpeg
--->  Applying patches to ffmpeg
--->  Configuring ffmpeg
Error: Failed to configure ffmpeg: configure failure: command execution failed
Error: See /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_multimedia_ffmpeg/ffmpeg/main.log for details.
Error: rev-upgrade failed: Error rebuilding ffmpeg
Error: Follow https://guide.macports.org/#project.tickets if you believe there is a bug.
$ ll /opt/local/lib/libx265.dylib
ls: /opt/local/lib/libx265.dylib: No such file or directory
$ fd libx265.dylib /opt/local/lib
$ fd libx265.dylib /opt/local
$ fd libx265. /opt/local
/opt/local/lib/libx265.a
/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_multimedia_ffmpeg/ffmpeg/work/ffmpeg-4.4.2/libavcodec/libx265.c
$ port contents x265
Port x265 contains:
  /opt/local/bin/x265
  /opt/local/include/hdr10plus.h
  /opt/local/include/x265.h
  /opt/local/include/x265_config.h
  /opt/local/lib/libhdr10plus.a
  /opt/local/lib/libx265.a
  /opt/local/lib/pkgconfig/x265.pc
$ 

Second, the complaint seems to be about inability to locate x265 using pkg-config?

comment:22 Changed 16 months ago by kencu (Ken)

OK, I see I don't have the "highdepth" option set on x265.

Let me try that, perhaps that will bring out the error.

comment:23 in reply to:  18 Changed 16 months ago by tehcog (tehcog)

Replying to janngobble:

Replying to kencu:

maybe someone with a system that won't configure it can post up their config.log so I can take a look.

@tehcog?

Here you go ...

Changed 16 months ago by tehcog (tehcog)

Attachment: ffmpeg_config.log added

config.log

comment:24 Changed 16 months ago by kencu (Ken)

Owner: set to kencu
Resolution: fixed
Status: newclosed

In 0eff7719b2539fef4798a1a63d213254ed9d7668/macports-ports (master):

x265: revert ENABLE_HDR10_PLUS

completely broke the build of x265
closes: #66465

comment:25 Changed 16 months ago by kencu (Ken)

Reverted this until somebody can figure out how to enable ENABLE_HDR10_PLUS without breaking x265.

Apologies for committing this in the first place -- I thought it was OK but I was wrong.

Note: See TracTickets for help on using tickets.