Skip to content

Commit

Permalink
Merge branch 'release/2023.2.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
melpon committed Mar 5, 2023
2 parents 86a95d6 + c4bf4f8 commit 585a742
Show file tree
Hide file tree
Showing 27 changed files with 11,509 additions and 9,659 deletions.
40 changes: 40 additions & 0 deletions .github/actions/download/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: download-artifact

description: Download Artifact

inputs:
platform:
description: Platform
required: true

runs:
using: composite
steps:
- uses: actions/download-artifact@v3
with:
name: ${{ inputs.platform }}.env
path: ${{ inputs.platform }}.env
- name: Env to output
shell: bash
run: |
sed -i 's/\r//g' ${{ inputs.platform }}.env/sora.env
source ${{ inputs.platform }}.env/sora.env
echo "package_name=$PACKAGE_NAME" >> $GITHUB_OUTPUT
echo "boost_package_name=$BOOST_PACKAGE_NAME" >> $GITHUB_OUTPUT
echo "lyra_package_name=$LYRA_PACKAGE_NAME" >> $GITHUB_OUTPUT
echo "$PACKAGE_NAME/$PACKAGE_NAME" >> package_paths.env
echo "$BOOST_PACKAGE_NAME/$BOOST_PACKAGE_NAME" >> package_paths.env
echo "$LYRA_PACKAGE_NAME/$LYRA_PACKAGE_NAME" >> package_paths.env
id: env
- uses: actions/download-artifact@v3
with:
name: ${{ steps.env.outputs.package_name }}
path: ${{ steps.env.outputs.package_name }}
- uses: actions/download-artifact@v3
with:
name: ${{ steps.env.outputs.boost_package_name }}
path: ${{ steps.env.outputs.boost_package_name }}
- uses: actions/download-artifact@v3
with:
name: ${{ steps.env.outputs.lyra_package_name }}
path: ${{ steps.env.outputs.lyra_package_name }}
9 changes: 9 additions & 0 deletions .github/renovate.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"extends": [
"config:base"
],
"schedule": [
"every weekend"
]
}
214 changes: 33 additions & 181 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
runs-on: windows-2019
steps:
- uses: actions/checkout@v3
- uses: microsoft/setup-msbuild@v1.1
- uses: microsoft/setup-msbuild@v1.3
- name: Env to output
run: |
echo "userprofile=${Env:USERPROFILE}" >> ${Env:GITHUB_OUTPUT}
Expand Down Expand Up @@ -139,25 +139,26 @@ jobs:
with:
name: ${{ matrix.name }}.env
path: _package/${{ matrix.name }}/release/sora.env
build-ubuntu-2004:
build-ubuntu:
strategy:
fail-fast: false
matrix:
name:
- ubuntu-20.04_x86_64
- ubuntu-22.04_x86_64
- ubuntu-20.04_armv8_jetson
- android
name: Build sora-cpp-sdk for ${{ matrix.name }}
runs-on: ubuntu-20.04
runs-on: ${{ matrix.name == 'ubuntu-22.04_x86_64' && 'ubuntu-22.04' || 'ubuntu-20.04' }}
steps:
- uses: actions/checkout@v3
- name: Bazel cache
uses: actions/cache@v3
with:
path: "~/.cache/bazel"
key: bazel-${{ matrix.name }}-v1
- name: Install deps for Ubuntu 20.04 x86_64
if: matrix.name == 'ubuntu-20.04_x86_64'
- name: Install deps for ${{ matrix.name }}
if: matrix.name == 'ubuntu-20.04_x86_64' || matrix.name == 'ubuntu-22.04_x86_64'
run: |
source VERSION
# clang-12 と CUDA を入れる
Expand Down Expand Up @@ -186,7 +187,7 @@ jobs:
run: |
sudo apt-get -y install ninja-build
- name: Setup Android SDK
uses: android-actions/[email protected].8
uses: android-actions/[email protected].10
if: matrix.name == 'android'
- run: pip3 install numpy
- run: python3 run.py --test --package ${{ matrix.name }}
Expand Down Expand Up @@ -217,194 +218,45 @@ jobs:
with:
name: ${{ matrix.name }}.env
path: _package/${{ matrix.name }}/release/sora.env
build-ubuntu-2204:
strategy:
fail-fast: false
matrix:
name:
- ubuntu-22.04_x86_64
name: Build sora-cpp-sdk for ${{ matrix.name }}
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Bazel cache
uses: actions/cache@v3
with:
path: "~/.cache/bazel"
key: bazel-${{ matrix.name }}-v1
- name: Install deps for Ubuntu 22.04 x86_64
if: matrix.name == 'ubuntu-22.04_x86_64'
run: |
source VERSION
# clang-12 と CUDA を入れる
sudo apt-get update
sudo apt-get install -y software-properties-common
# CUDA 10 なので ubuntu1804 で正しい
wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64/cuda-ubuntu1804.pin
sudo mv cuda-ubuntu1804.pin /etc/apt/preferences.d/cuda-repository-pin-600
sudo apt-key adv --fetch-keys https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64/3bf863cc.pub
sudo add-apt-repository "deb https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64/ /"
sudo apt-get update
DEBIAN_FRONTEND=noninteractive sudo apt-get -y install cuda=$CUDA_VERSION clang-12
# Intel Media SDK のために libva-dev, libdrm-dev を入れる
DEBIAN_FRONTEND=noninteractive sudo apt-get -y install libva-dev libdrm-dev
- run: pip3 install numpy
- run: python3 run.py --test --package ${{ matrix.name }}
- name: Get package name
run: |
source _package/${{ matrix.name }}/release/sora.env
echo "name=${PACKAGE_NAME}" >> $GITHUB_OUTPUT
echo "boost_name=${BOOST_PACKAGE_NAME}" >> $GITHUB_OUTPUT
echo "lyra_name=${LYRA_PACKAGE_NAME}" >> $GITHUB_OUTPUT
id: package_name
- name: Upload Artifact
uses: actions/upload-artifact@v3
with:
name: ${{ steps.package_name.outputs.name }}
path: _package/${{ matrix.name }}/release/${{ steps.package_name.outputs.name }}
- name: Upload Boost Artifact
uses: actions/upload-artifact@v3
with:
name: ${{ steps.package_name.outputs.boost_name }}
path: _package/${{ matrix.name }}/release/${{ steps.package_name.outputs.boost_name }}
- name: Upload Lyra Artifact
uses: actions/upload-artifact@v3
with:
name: ${{ steps.package_name.outputs.lyra_name }}
path: _package/${{ matrix.name }}/release/${{ steps.package_name.outputs.lyra_name }}
- name: Upload Environment
uses: actions/upload-artifact@v3
with:
name: ${{ matrix.name }}.env
path: _package/${{ matrix.name }}/release/sora.env
create-release:
name: Create Release
if: contains(github.ref, 'tags/202')
needs:
- build-windows
- build-macos
- build-ubuntu-2004
- build-ubuntu-2204
runs-on: ubuntu-latest
steps:
- name: Create Release
id: create_release
uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
draft: false
prerelease: false
- name: Output upload url
shell: bash
run: echo "UPLOAD_URL='${{ steps.create_release.outputs.upload_url }}'" > create-release.env
- name: Upload create-release Environment
uses: actions/upload-artifact@v3
with:
name: create-release.env
path: create-release.env
upload-assets:
name: Upload Assets to Release
needs:
- create-release
- build-ubuntu
runs-on: ubuntu-latest
strategy:
fail-fast: true
matrix:
name:
- windows_x86_64
- macos_arm64
- ios
- ubuntu-20.04_armv8_jetson
- ubuntu-20.04_x86_64
- ubuntu-22.04_x86_64
- android
steps:
- uses: actions/download-artifact@v3
- uses: actions/checkout@v3
- uses: ./.github/actions/download
with:
name: ${{ matrix.name }}.env
path: ${{ matrix.name }}.env
- uses: actions/download-artifact@v3
platform: windows_x86_64
- uses: ./.github/actions/download
with:
name: create-release.env
path: create-release.env
- name: Env to output
shell: bash
run: |
sed -i 's/\r//g' ${{ matrix.name }}.env/sora.env
sed -i 's/\r//g' create-release.env/create-release.env
source ${{ matrix.name }}.env/sora.env
source create-release.env/create-release.env
echo "package_name=$PACKAGE_NAME" >> $GITHUB_OUTPUT
echo "boost_package_name=$BOOST_PACKAGE_NAME" >> $GITHUB_OUTPUT
echo "lyra_package_name=$LYRA_PACKAGE_NAME" >> $GITHUB_OUTPUT
echo "content_type=$CONTENT_TYPE" >> $GITHUB_OUTPUT
echo "upload_url=$UPLOAD_URL" >> $GITHUB_OUTPUT
id: env
- uses: actions/download-artifact@v3
platform: macos_arm64
- uses: ./.github/actions/download
with:
name: ${{ steps.env.outputs.package_name }}
path: ${{ steps.env.outputs.package_name }}
- uses: actions/download-artifact@v3
platform: ios
- uses: ./.github/actions/download
with:
name: ${{ steps.env.outputs.boost_package_name }}
path: ${{ steps.env.outputs.boost_package_name }}
- uses: actions/download-artifact@v3
platform: ubuntu-20.04_armv8_jetson
- uses: ./.github/actions/download
with:
name: ${{ steps.env.outputs.lyra_package_name }}
path: ${{ steps.env.outputs.lyra_package_name }}
- name: Upload ${{ matrix.name }} Release Asset
uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
platform: ubuntu-20.04_x86_64
- uses: ./.github/actions/download
with:
upload_url: ${{ steps.env.outputs.upload_url }}
asset_path: ${{ steps.env.outputs.package_name }}/${{ steps.env.outputs.package_name }}
asset_name: ${{ steps.env.outputs.package_name }}
asset_content_type: ${{ steps.env.outputs.content_type }}
- name: Upload ${{ matrix.name }} Release Asset
uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
platform: ubuntu-22.04_x86_64
- uses: ./.github/actions/download
with:
upload_url: ${{ steps.env.outputs.upload_url }}
asset_path: ${{ steps.env.outputs.boost_package_name }}/${{ steps.env.outputs.boost_package_name }}
asset_name: ${{ steps.env.outputs.boost_package_name }}
asset_content_type: ${{ steps.env.outputs.content_type }}
- name: Upload ${{ matrix.name }} Release Asset
uses: actions/[email protected]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
platform: android
- name: Env to output
run: |
echo "package_paths<<EOF" >> $GITHUB_OUTPUT
cat package_paths.env >> $GITHUB_OUTPUT
echo "EOF" >> $GITHUB_OUTPUT
id: env
- name: Release
uses: softprops/action-gh-release@v1
with:
upload_url: ${{ steps.env.outputs.upload_url }}
asset_path: ${{ steps.env.outputs.lyra_package_name }}/${{ steps.env.outputs.lyra_package_name }}
asset_name: ${{ steps.env.outputs.lyra_package_name }}
asset_content_type: ${{ steps.env.outputs.content_type }}
#notification:
# name: Slack Notification
# runs-on: ubuntu-latest
# needs:
# - build-windows
# - build-macos
# - build-ubuntu-1804
# - build-ubuntu-2004
# - create-release
# - upload-assets
# if: always()
# steps:
# - uses: actions/checkout@v3
# - uses: rtCamp/action-slack-notify@v2
# if: |
# needs.build-windows.result == 'failure' ||
# needs.build-macos.result == 'failure' ||
# needs.build-ubuntu-1804.result == 'failure' ||
# needs.build-ubuntu-2004.result == 'failure' ||
# needs.create-release.result == 'failure' ||
# needs.upload-assets.result == 'failure'
# env:
# SLACK_CHANNEL: open-momo
# SLACK_COLOR: danger
# SLACK_TITLE: Failure build
# SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
files:
${{ steps.env.outputs.package_paths }}
13 changes: 13 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,19 @@

## develop

## 2023.2.0 (2023-03-05)

- [UPDATE] NVIDIA Video Codec SDK を 12.0 に上げる
- @melpon
- [UPDATE] deprecated になった actions/create-release と actions/upload-release の利用をやめて softprops/action-gh-release を利用する
- @melpon
- [FIX] WebSocket 接続時に即エラーになると正常に OnDisconnect が呼ばれないのを修正
- @melpon
- [UPDATE] oneVPL のデコードでリサイズに対応してなかったのを修正
- @melpon
- [UPDATE] WebRTC を m111.5563.4.2 に上げる
- @melpon @miosakuma

## 2023.1.0 (2023-01-12)

- [ADD] SoraSignalingConfig に audio_streaming_language_code を追加
Expand Down
5 changes: 5 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -383,6 +383,11 @@ elseif (SORA_TARGET_OS STREQUAL "android")
src/android/android_capturer.cpp
)

target_compile_options(sora
PUBLIC
-fexperimental-relative-c++-abi-vtables
)

target_compile_definitions(sora
PUBLIC
WEBRTC_POSIX
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ https://github.com/shiguredo/sora-cpp-sdk/releases

## 対応 Sora

- WebRTC SFU Sora 2022.1.0 以降
- WebRTC SFU Sora 2022.2.0 以降

## 動作環境

Expand Down Expand Up @@ -102,8 +102,8 @@ Discord へお願いします。
Apache License 2.0

```
Copyright 2021-2022, Wandbox LLC (Original Author)
Copyright 2021-2022, Shiguredo Inc.
Copyright 2021-2023, Wandbox LLC (Original Author)
Copyright 2021-2023, Shiguredo Inc.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand Down
4 changes: 2 additions & 2 deletions VERSION
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
SORA_CPP_SDK_VERSION=2023.1.0
WEBRTC_BUILD_VERSION=m109.5414.2.0
SORA_CPP_SDK_VERSION=2023.2.0
WEBRTC_BUILD_VERSION=m111.5563.4.2
BOOST_VERSION=1.81.0
CMAKE_VERSION=3.23.1
BAZEL_VERSION=5.3.2
Expand Down
1 change: 1 addition & 0 deletions include/sora/dyn/cuda.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ DYN_REGISTER(CUDA_SO, cuMemcpy2D);
DYN_REGISTER(CUDA_SO, cuMemcpy2DAsync);
DYN_REGISTER(CUDA_SO, cuMemcpy2DUnaligned);
DYN_REGISTER(CUDA_SO, cuStreamSynchronize);
DYN_REGISTER(CUDA_SO, cuStreamCreate);

} // namespace dyn

Expand Down
Loading

0 comments on commit 585a742

Please sign in to comment.