Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can not build with arm arch on mac #900

Closed
cangunaydin opened this issue Dec 9, 2023 · 5 comments
Closed

Can not build with arm arch on mac #900

cangunaydin opened this issue Dec 9, 2023 · 5 comments
Assignees
Labels
apple Affect Apple platforms fixed-on-development Fixed on the development branch. Not released yet. incompatibility ios Affect iOS platform macos Affect macOS platform no-issue-activity scripts Affect build scripts tvos Affect tvOS platform

Comments

@cangunaydin
Copy link

Description
when i try to build with mac-os.sh script i got an error. I have installed the prerequisites on the wiki page. Still i am getting this error. see the build.log

GEN libavformat/libavformat.pc
GEN libswresample/libswresample.pc
GEN libswscale/libswscale.pc
GEN libavutil/libavutil.pc
GEN libavdevice/libavdevice.ver
GEN libavfilter/libavfilter.ver
GEN libswscale/libswscale.ver
GEN libavutil/libavutil.ver
GEN libavformat/libavformat.ver
GEN libavcodec/libavcodec.ver
LD libavutil/libavutil.58.dylib
ld: warning: -single_module is obsolete
GEN libswresample/libswresample.ver
LD libswscale/libswscale.7.dylib
LD libswresample/libswresample.4.dylib
ld: warning: -single_module is obsolete
ld: warning: ignoring duplicate libraries: '-lm'
ld: warning: -single_module is obsolete
ld: warning: ignoring duplicate libraries: '-lavutil', '-lm'
LD libavcodec/libavcodec.60.dylib
ld: warning: -single_module is obsolete
ld: warning: ignoring duplicate libraries: '-lm'
LD libavformat/libavformat.60.dylib
ld: warning: -single_module is obsolete
ld: warning: ignoring duplicate libraries: '-lm'
LD libavfilter/libavfilter.9.dylib
ld: warning: -single_module is obsolete
ld: warning: ignoring duplicate libraries: '-lm'
LD libavdevice/libavdevice.60.dylib
ld: warning: -single_module is obsolete
ld: warning: ignoring duplicate libraries: '-lm'
ld: building exports trie: duplicate symbol '_av_ac3_parse_header'
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [libavdevice/libavdevice.60.dylib] Error 1

Expected behavior
to build successfully

Current behavior
build have failed.

To Reproduce
clone repository from github. run this command
./macos.sh --disable-x86-64 --debug;

Screenshots
Screenshot 2023-12-09 at 23 51 50

Screenshot 2023-12-09 at 23 54 20

Environment

  • Platform: macOS
  • Architecture: arm64
  • Version: v6.0
  • Source branch: main
  • Xcode version: 15.0.1
@cangunaydin
Copy link
Author

here is the config log.
config.log
here is the build log.
build.log

@cangunaydin
Copy link
Author

ok after so many trials i have managed to built it.
I think the problem is related with xcode or specifically apple clang 15.
you need to add "-Wl -ld_classic" flags to --extra-ldflags= inside ffmpeg.sh for apple builds.
Screenshot 2023-12-13 at 00 45 42

thanks to this post. spack/spack#40159
hope it helps someone.

iliaskarim added a commit to iliaskarim/ffmpeg-kit that referenced this issue Dec 20, 2023
@iliaskarim iliaskarim mentioned this issue Dec 20, 2023
4 tasks
Copy link

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days.

Copy link

This issue was closed because it has been stalled for 7 days with no activity.

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Feb 19, 2024
@tanersener tanersener added incompatibility apple Affect Apple platforms tvos Affect tvOS platform macos Affect macOS platform ios Affect iOS platform scripts Affect build scripts labels Apr 18, 2024
@tanersener tanersener self-assigned this Apr 18, 2024
@tanersener
Copy link
Collaborator

This is a known issue that exists in Xcode 15.0 and 15.0.1. Upgrading Xcode to 15.1 or later fixes the issue. I added a workaround in the development branch anyway.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
apple Affect Apple platforms fixed-on-development Fixed on the development branch. Not released yet. incompatibility ios Affect iOS platform macos Affect macOS platform no-issue-activity scripts Affect build scripts tvos Affect tvOS platform
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants