Skip to content

Not able to build on M1 Mac #163

@tamoanxx

Description

@tamoanxx

Describe the Bug

Not able to build on mac manually or with Mac Ports

scale.dylib
-- /opt/homebrew/Cellar/ffmpeg/5.0.1/lib/libavformat.dylib/opt/homebrew/Cellar/ffmpeg/5.0.1/lib/libavdevice.dylib/opt/homebrew/Cellar/ffmpeg/5.0.1/lib/libavcodec.dylib/opt/homebrew/Cellar/ffmpeg/5.0.1/lib/libavutil.dylib/opt/homebrew/Cellar/ffmpeg/5.0.1/lib/libswscale.dylib
CMake Warning (dev) at /opt/local/share/cmake-3.22/Modules/FindPackageHandleStandardArgs.cmake:438 (message):
  The package name passed to `find_package_handle_standard_args` (FFMPEG)
  does not match the name of the calling package (FFmpeg).  This can lead to
  problems in calling code that expects `find_package` result variables
  (e.g., `_FOUND`) to follow a certain pattern.
Call Stack (most recent call first):
  cmake/FindFFmpeg.cmake:141 (find_package_handle_standard_args)
  CMakeLists.txt:134 (find_package)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Configuring done
CMake Error at CMakeLists.txt:428 (add_executable):
  Cannot find source file:

    sunshine/platform/macos/TPCircularBuffer/TPCircularBuffer.c

  Tried extensions .c .C .c++ .cc .cpp .cxx .cu .mpp .m .M .mm .ixx .cppm .h
  .hh .h++ .hm .hpp .hxx .in .txx .f .F .for .f77 .f90 .f95 .f03 .hip .ispc


CMake Error at CMakeLists.txt:428 (add_executable):
  No SOURCES given to target: sunshine
info:build   "_X509_verify_cert", referenced from:
:info:build       crypto::cert_chain_t::verify(x509_st*) in crypto.cpp.o
:info:build   "_X509_verify_cert_error_string", referenced from:
:info:build       crypto::cert_chain_t::verify(x509_st*) in crypto.cpp.o
:info:build ld: symbol(s) not found for architecture arm64
:info:build clang: error: linker command failed with exit code 1 (use -v to see invocation)
:info:build make[2]: *** [sunshine-0.12.0] Error 1
:info:build make[2]: Leaving directory `/opt/local/var/macports/build/_private_tmp/sunshine/work/build'
:info:build make[1]: *** [CMakeFiles/sunshine.dir/all] Error 2
:info:build make[1]: Leaving directory `/opt/local/var/macports/build/_private_tmp/sunshine/work/build'
:info:build make: *** [all] Error 2
:info:build make: Leaving directory `/opt/local/var/macports/build/_private_tmp/sunshine/work/build'
:info:build Command failed:  cd "/opt/local/var/macports/build/_private_tmp/sunshine/work/build" && /usr/bin/make -j8 -w all VERBOSE=ON 
:info:build Exit code: 2
:error:build Failed to build sunshine: command execution failed
:debug:build Error code: CHILDSTATUS 66597 2
:debug:build Backtrace: command execution failed
:debug:build     while executing
:debug:build "system {*}$notty {*}$callback {*}$nice $fullcmdstring"
:debug:build     invoked from within
:debug:build "command_exec -callback portprogress::target_progress_callback build"
:debug:build     (procedure "portbuild::build_main" line 8)
:debug:build     invoked from within
:debug:build "$procedure $targetname"
:error:build See /opt/local/var/macports/logs/_private_tmp/sunshine/main.log for details.

Expected Behavior

Successful Build

Additional Context

No response

Sunshine Host Operating System and Version

Mac OS Latest

Architecture

arm

Sunshine Version

13

GPU Type

Mac M1

GPU Model

Mac M1

GPU Driver/Mesa Version

Mac M1

Capture Method (Linux Only)

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions