@@ -312,52 +312,6 @@ jobs:
312312 - name : deploy
313313 run : myci-deploy-homebrew.sh --tap cppfw/tap
314314 if : startsWith(github.ref, 'refs/tags/')
315- # #### ios #####
316- ios :
317- runs-on : macos-latest
318- steps :
319- - name : workaround python2 and python3 issue when upgrading python
320- run : |
321- rm -rf /usr/local/bin/2to3*
322- rm -rf /usr/local/bin/idle3*
323- rm -rf /usr/local/bin/pydoc3*
324- rm -rf /usr/local/bin/python3
325- rm -rf /usr/local/bin/python3-config
326- rm -rf /usr/local/bin/python3*
327- rm -rf /usr/local/bin/python3*-config
328- - name : add cppfw tap
329- run : |
330- brew tap cppfw/tap
331- brew update
332- - name : install ci tools
333- run : brew install myci
334- - name : git clone
335- uses : myci-actions/checkout@main
336- - name : set PACKAGE_VERSION
337- uses : myci-actions/export-env-var@main
338- with : {name: PACKAGE_VERSION, value: $(myci-deb-version.sh)}
339- - name : add cocoapods repo
340- run : pod repo add --silent cppfw https://$MYCI_GIT_USERNAME@github.com/cppfw/cocoapods-repo.git
341- - name : install deps
342- run : pod install --project-directory=xcode
343- - name : add sources to xcode project
344- run : |
345- curl -L https://github.com/zackslash/Xcode-Proj-Adder/raw/master/bin/XcodeProjAdder -O
346- chmod +x XcodeProjAdder
347- cd xcode/$PACKAGE_NAME
348- ../../XcodeProjAdder -XCP $PACKAGE_NAME.xcodeproj -SCSV `echo $(find ../../src -type f -name *.cpp) | sed -E -e 's/ /,/g'`
349- - name : build
350- run : |
351- xcodebuild CONFIGURATION_BUILD_DIR=../build_ios -sdk iphoneos -workspace xcode/$PACKAGE_NAME.xcworkspace -scheme $PACKAGE_NAME -configuration Release
352- xcodebuild CONFIGURATION_BUILD_DIR=../build_iossim -sdk iphonesimulator -workspace xcode/$PACKAGE_NAME.xcworkspace -scheme $PACKAGE_NAME -configuration Release
353- xcodebuild -create-xcframework -framework "xcode/build_ios/$PACKAGE_NAME.framework" -framework "xcode/build_iossim/$PACKAGE_NAME.framework" -output "xcode/$PACKAGE_NAME.xcframework"
354- - name : create package
355- run : myci-create-zip-package.sh --headers-dir src --file xcode/$PACKAGE_NAME.xcframework///lib/ios --file LICENSE $PACKAGE_NAME-$PACKAGE_VERSION.zip
356- - name : deploy
357- run : |
358- echo "${{ secrets.MYCI_REPO_SSH_KEY }}" > repo_key_rsa && chmod 600 repo_key_rsa
359- myci-deploy-cocoapods-ssh.sh --repo cppfw --version $PACKAGE_VERSION --server gagis.hopto.org --key repo_key_rsa --generic-repo cppfw/cocoapods --package $PACKAGE_NAME-$PACKAGE_VERSION.zip build/cocoapods/$PACKAGE_NAME.podspec.in
360- if : startsWith(github.ref, 'refs/tags/')
361315# #### android #####
362316 android :
363317 runs-on : ubuntu-latest
@@ -438,31 +392,6 @@ jobs:
438392 myci-deploy-pacman-ssh.sh --server gagis.hopto.org --key repo_key_rsa --repo cppfw/msys2/${{ matrix.repo }} --database cppfw_${{ matrix.repo }} $f
439393 done
440394 if : startsWith(github.ref, 'refs/tags/')
441- # #### msvs #####
442- msvs :
443- runs-on : windows-latest
444- defaults :
445- run :
446- shell : powershell
447- steps :
448- - name : git clone
449- uses : actions/checkout@v3
450- - name : install CoAPP tools
451- uses : myci-actions/install-coapp-tools@main
452- - name : nuget update
453- run : |
454- nuget restore msvs_solution/msvs_solution.sln
455- nuget update msvs_solution/msvs_solution.sln
456- - name : add msbuild to PATH
457- uses : microsoft/setup-msbuild@v1.1
458- - name : build
459- run : .\nuget\build_nuget.ps1
460- - name : deploy
461- uses : myci-actions/publish-nuget@main
462- with :
463- filename : ' .\nuget\*.nupkg'
464- api-key : ${{ secrets.NUGET_DOT_ORG_API_KEY }}
465- if : startsWith(github.ref, 'refs/tags/')
466395# #### vcpkg-linux #####
467396 vcpkg-linux :
468397 strategy :
@@ -557,6 +486,63 @@ jobs:
557486 path : |
558487 vcpkg-installation/buildtrees/${{ env.PACKAGE_NAME }}/
559488 build/vcpkg/**/*.log
489+ # #### vcpkg-ios #####
490+ vcpkg-ios :
491+ runs-on : macos-latest
492+ strategy :
493+ fail-fast : false
494+ matrix :
495+ config :
496+ - Debug
497+ - Release
498+ name : vcpkg - ios | ${{ matrix.config }}
499+ steps :
500+ - name : workaround python2 and python3 issue when upgrading python
501+ run : |
502+ rm -rf /usr/local/bin/2to3*
503+ rm -rf /usr/local/bin/idle3*
504+ rm -rf /usr/local/bin/pydoc3*
505+ rm -rf /usr/local/bin/python3
506+ rm -rf /usr/local/bin/python3-config
507+ rm -rf /usr/local/bin/python3*
508+ rm -rf /usr/local/bin/python3*-config
509+ - name : git clone
510+ uses : myci-actions/checkout@main
511+ with :
512+ submodules : true # non-recursive, no remote
513+ - name : install vcpkg
514+ run : |
515+ git clone https://github.com/microsoft/vcpkg.git vcpkg-installation
516+ (cd vcpkg-installation; ./bootstrap-vcpkg.sh)
517+ - name : set VCPKG_ROOT
518+ uses : myci-actions/export-env-var@main
519+ with : {name: VCPKG_ROOT, value: "$(pwd)/vcpkg-installation"}
520+ - name : add VCPKG_ROOT to PATH
521+ uses : myci-actions/export-env-var@main
522+ with : {name: PATH, value: "$PATH:$VCPKG_ROOT"}
523+ - name : add cppfw tap
524+ run : |
525+ brew tap cppfw/tap
526+ brew update
527+ - name : install ci tools
528+ run : brew install myci cmake
529+ - name : prepare vcpkg port
530+ run : |
531+ myci-vcpkg-prepare.sh --git-ref ${{ github.sha }}
532+ - name : test vcpkg port
533+ run : |
534+ cd build/vcpkg/test
535+ cmake -G Xcode -D CMAKE_SYSTEM_NAME=iOS -D VCPKG_TARGET_TRIPLET=arm64-ios-simulator .
536+ cmake --build . --parallel --config ${{ matrix.config }} -- -sdk iphonesimulator -arch arm64
537+ # ./test
538+ - name : upload vcpkg logs to artifacts
539+ if : always() # even if previous steps fail, this one needs to be run
540+ uses : actions/upload-artifact@v4
541+ with :
542+ name : vcpkg_ios_${{ matrix.config }}_logs
543+ path : |
544+ vcpkg-installation/buildtrees/${{ env.PACKAGE_NAME }}/
545+ build/vcpkg/**/*.log
560546# #### conan - linux #####
561547 conan-linux :
562548 strategy :
0 commit comments