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