mirror of
https://github.com/italicsjenga/portability.git
synced 2024-11-22 07:01:29 +11:00
Basic UWP target support, readme update
This commit is contained in:
parent
bae930673d
commit
7c42b540a8
16
.github/workflows/check.yml
vendored
16
.github/workflows/check.yml
vendored
|
@ -17,6 +17,22 @@ jobs:
|
|||
- run: rustup target add ${{ env.TARGET }}
|
||||
- run: make check-target
|
||||
|
||||
uwp_build:
|
||||
name: UWP Nightly
|
||||
runs-on: windows-2019
|
||||
env:
|
||||
TARGET: x86_64-uwp-windows-msvc
|
||||
steps:
|
||||
- name: Checkout sources
|
||||
uses: actions/checkout@v2
|
||||
- name: Install latest nightly
|
||||
uses: actions-rs/toolchain@v1
|
||||
with:
|
||||
toolchain: nightly
|
||||
override: true
|
||||
components: rust-src
|
||||
- run: cargo build -Z build-std --manifest-path libportability/Cargo.toml --features dx12 --target ${{ env.TARGET }}
|
||||
|
||||
build:
|
||||
name: ${{ matrix.name }}
|
||||
runs-on: ${{ matrix.os }}
|
||||
|
|
24
.github/workflows/release.yml
vendored
24
.github/workflows/release.yml
vendored
|
@ -11,25 +11,41 @@ jobs:
|
|||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
name: ['macOS stable', 'iOS stable', 'Windows stable']
|
||||
name: ['macOS stable', 'iOS stable', 'Windows stable', 'UWP nightly']
|
||||
include:
|
||||
- name: macOS stable
|
||||
os: macos-10.15
|
||||
target: x86_64-apple-darwin
|
||||
package: gfx-portability.zip
|
||||
- name: iOS stable
|
||||
os: macos-10.15
|
||||
target: aarch64-apple-ios
|
||||
package: gfx-portability.zip
|
||||
- name: Windows stable
|
||||
os: windows-2019
|
||||
target: x86_64-pc-windows-msvc
|
||||
package: gfx-portability.zip
|
||||
- name: UWP nightly
|
||||
os: windows-2019
|
||||
target: x86_64-uwp-windows-msvc
|
||||
package: gfx-portability-custom.zip
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- if: matrix.os == 'windows-2019'
|
||||
name: Install make
|
||||
run: choco install make
|
||||
- run: rustup target add ${{ matrix.target }}
|
||||
- if: matrix.package == 'gfx-portability.zip'
|
||||
name: Install target
|
||||
run: rustup target add ${{ matrix.target }}
|
||||
- if: matrix.package == 'gfx-portability-custom.zip'
|
||||
name: Install latest nightly
|
||||
uses: actions-rs/toolchain@v1
|
||||
with:
|
||||
toolchain: nightly
|
||||
override: true
|
||||
components: rust-src
|
||||
- name: Build
|
||||
run: make CARGO_BUILD_TARGET=${{ matrix.target }} gfx-portability.zip
|
||||
run: make CARGO_BUILD_TARGET=${{ matrix.target }} ${{ matrix.package }}
|
||||
- name: Upload builds
|
||||
id: upload-release-asset
|
||||
uses: actions/upload-release-asset@v1
|
||||
|
@ -37,6 +53,6 @@ jobs:
|
|||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
upload_url: ${{ github.event.release.upload_url }}
|
||||
asset_path: ./gfx-portability.zip
|
||||
asset_path: ./${{ matrix.package }}
|
||||
asset_name: gfx-portability-${{ github.event.release.tag_name }}.${{ matrix.target }}.zip
|
||||
asset_content_type: application/zip
|
||||
|
|
6
Makefile
6
Makefile
|
@ -184,6 +184,12 @@ gfx-portability.zip: version-debug version-release
|
|||
echo "$(GIT_TAG_FULL)" > commit-sha
|
||||
$(ZIP_COMMAND) gfx-portability.zip target/$(CARGO_BUILD_TARGET)/*/$(LIB_FILE_NAME) libportability-icd/portability-$(JSON_SUFFIX).json commit-sha
|
||||
|
||||
gfx-portability-custom.zip:
|
||||
cargo build -Z build-std --manifest-path libportability/Cargo.toml --features $(BACKEND)
|
||||
cargo build -Z build-std=std,panic_abort --manifest-path libportability/Cargo.toml --features $(BACKEND) --release
|
||||
echo "$(GIT_TAG_FULL)" > commit-sha
|
||||
$(ZIP_COMMAND) gfx-portability-custom.zip target/$(CARGO_BUILD_TARGET)/*/$(LIB_FILE_NAME) commit-sha
|
||||
|
||||
target/debug/$(LIB_VULKAN_NAME):
|
||||
cd target/debug && ln -sf $(LIB_FILE_NAME) $(LIB_VULKAN_NAME)
|
||||
|
||||
|
|
12
README.md
12
README.md
|
@ -1,9 +1,17 @@
|
|||
## gfx-portability
|
||||
[![Build Status](https://github.com/gfx-rs/portability/workflows/check/badge.svg?branch=master)](https://github.com/gfx-rs/portability/actions)
|
||||
[![Matrix](https://img.shields.io/badge/Matrix-%23gfx%3Amatrix.org-blueviolet.svg)](https://matrix.to/#/#gfx:matrix.org)
|
||||
[![Build Status](https://github.com/gfx-rs/portability/workflows/Check/badge.svg?branch=master)](https://github.com/gfx-rs/portability/actions)
|
||||
[![Matrix](https://img.shields.io/badge/Matrix-%23gfx%3Amatrix.org-blueviolet.svg)](https://matrix.to/#/#gfx:matrix.org)
|
||||
|
||||
This is a prototype library implementing [Vulkan Portability Initiative](https://www.khronos.org/blog/khronos-announces-the-vulkan-portability-initiative) using [gfx-hal](http://gfx-rs.github.io/2017/07/24/low-level.html). See gfx-rs [meta issue](https://github.com/gfx-rs/gfx/issues/1354) for backend limitations and further details.
|
||||
|
||||
Platform support:
|
||||
- macOS/Metal (lib, icd)
|
||||
- iOS/Metal (lib, icd)
|
||||
- Windows/DX12 (lib, icd)
|
||||
- UWP/DX12 (lib)
|
||||
|
||||
For those interested in performance, we did a comprehensive benchmarks of Dota2 and Dolphin Emulator on macOS. Results were published to gfx-rs blog [here](https://gfx-rs.github.io/2018/08/10/dota2-macos-performance.html) and [there](https://gfx-rs.github.io/2019/03/22/dolphin-macos-performance.html).
|
||||
|
||||
## Showcase
|
||||
|
||||
### [Dota2](https://github.com/ValveSoftware/Dota-2):
|
||||
|
|
Loading…
Reference in a new issue