BelledonneCommunications / linphone-sdk

Mirror for linphone-sdk (https://gitlab.linphone.org/BC/public/linphone-sdk.git)
GNU Affero General Public License v3.0
105 stars 81 forks source link

Not able to build the linphone-sdk for ios locally. #343

Open Coderode opened 1 year ago

Coderode commented 1 year ago

System configurations Xcode version - 15.0 mac os - 13.6 mac - MacBook air m1 (2020)

Trying to build the release/5.2 sdk code installed the from using. : git clone https://gitlab.linphone.org/BC/public/linphone-sdk.git --recursive (It installed all the things properly then fetch and checkout to the branch release/5.2)

I have installed all the dependencies as mentioned in the document at. : https://github.com/BelledonneCommunications/linphone-sdk/tree/release/5.2#ios

I am not getting any dependency related error while building the sdk.

I created the build folder in the linphon-sdk folder, moved to it then hit the below commands as mentioned in the document.

The command I tried cmake .. -G Xcode -DLINPHONESDK_PLATFORM=IOS -DENABLE_GPL_THIRD_PARTIES=ON -DENABLE_NON_FREE_CODECS=ON -DENABLE_FFMPEG=ON -DENABLE_H263=ON -DENABLE_H263P=ON -DENABLE_MPEG4=ON -DENABLE_NON_FREE_FEATURES=ON -DLINPHONESDK_VERSION="5.2.0" -DLINPHONESDK_IOS_ARCHS="arm64;x86_64"

or

cmake .. -G Xcode -DLINPHONESDK_PLATFORM=IOS -DENABLE_GPL_THIRD_PARTIES=ON -DENABLE_NON_FREE_CODECS=ON -DENABLE_FFMPEG=ON -DENABLE_H263=ON -DENABLE_H263P=ON -DENABLE_MPEG4=ON -DENABLE_NON_FREE_FEATURES=ON

and then

cmake --build .

Even following all the steps mentioned in the document of the linphone-sdk, I am not able to build the sdk using Mac OS for ios. Can anybody help or tell me the versions of the system or the linphone-sdk which is building properly?

What errors I am gettings are here :

note: Run script build phase 'Generate ios-arm64-prefix/src/ios-arm64-stamp/Debug/ios-arm64-build' will be run during every build because the option to run the script phase "Based on dependency analysis" is unchecked. (in target 'ios-arm64' from project 'linphone-sdk')
note: Run script build phase 'Generate CMakeFiles/ios-arm64' will be run during every build because the option to run the script phase "Based on dependency analysis" is unchecked. (in target 'ios-arm64' from project 'linphone-sdk')
note: Run script build phase 'Generate CMakeFiles/Debug/ios-arm64-complete' will be run during every build because the option to run the script phase "Based on dependency analysis" is unchecked. (in target 'ios-arm64' from project 'linphone-sdk')
note: Run script build phase 'Generate ios-arm64-simulator-prefix/src/ios-arm64-simulator-stamp/Debug/ios-arm64-simulator-force_build' will be run during every build because the option to run the script phase "Based on dependency analysis" is unchecked. (in target 'ios-arm64-simulator' from project 'linphone-sdk')
note: Run script build phase 'Generate ios-arm64-simulator-prefix/src/ios-arm64-simulator-stamp/Debug/ios-arm64-simulator-build' will be run during every build because the option to run the script phase "Based on dependency analysis" is unchecked. (in target 'ios-arm64-simulator' from project 'linphone-sdk')
note: Run script build phase 'Generate CMakeFiles/ios-arm64-simulator' will be run during every build because the option to run the script phase "Based on dependency analysis" is unchecked. (in target 'ios-arm64-simulator' from project 'linphone-sdk')
note: Run script build phase 'Generate CMakeFiles/Debug/ios-arm64-simulator-complete' will be run during every build because the option to run the script phase "Based on dependency analysis" is unchecked. (in target 'ios-arm64-simulator' from project 'linphone-sdk')
** BUILD FAILED **

The following build commands failed:
    PhaseScriptExecution Generate\ ios-x86_64-prefix/src/ios-x86_64-stamp/Debug/ios-x86_64-build /Users/sandeep/Desktop/linphone-sdk/build/build/linphone-sdk.build/Debug-iphonesimulator/ios-x86_64.build/Script-7F025F1EA7C2067AC8F428E6.sh (in target 'ios-x86_64' from project 'linphone-sdk')
    PhaseScriptExecution Generate\ ios-arm64-simulator-prefix/src/ios-arm64-simulator-stamp/Debug/ios-arm64-simulator-build /Users/sandeep/Desktop/linphone-sdk/build/build/linphone-sdk.build/Debug-iphonesimulator/ios-arm64-simulator.build/Script-A637F48C8DCD19A22A148EB3.sh (in target 'ios-arm64-simulator' from project 'linphone-sdk')
    PhaseScriptExecution Generate\ ios-arm64-prefix/src/ios-arm64-stamp/Debug/ios-arm64-build /Users/sandeep/Desktop/linphone-sdk/build/build/linphone-sdk.build/Debug-iphonesimulator/ios-arm64.build/Script-C381405E5663D987458823AB.sh (in target 'ios-arm64' from project 'linphone-sdk')
    PhaseScriptExecution Generate\ CMakeFiles/gen-frameworks /Users/sandeep/Desktop/linphone-sdk/build/build/linphone-sdk.build/Debug-iphonesimulator/gen-frameworks.build/Script-7F1198A405A6B2832F51A1E5.sh (in target 'gen-frameworks' from project 'linphone-sdk')
    PhaseScriptExecution Generate\ CMakeFiles/sdk /Users/sandeep/Desktop/linphone-sdk/build/build/linphone-sdk.build/Debug-iphonesimulator/sdk.build/Script-FD02EB98B80F44016A0CE680.sh (in target 'sdk' from project 'linphone-sdk')
(5 failures)

I am attaching the command line output that I got in the below link, The detailed errors are there but I am not able to find that what is the actual problem is there even if I follow all the steps as mentioned in the document of the linphone-sdk.

linphon-sdk-build-terminal-output-link

Please help if anybody can do it. I tried it many times but it did not work, I tried with prepare.py also but did not work for me. or suggest me if which version of macos and xcode i have to use to build it (5.2 of linphone-sdk).

gaoruiqing187 commented 9 months ago

老哥,你构建出来的是framework吗?

ogrodowski-tomasz commented 7 months ago

Have you managed to build it?