-
Notifications
You must be signed in to change notification settings - Fork 68
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Integrate the Rive renderer into iOS
Diffs= afc961233 Integrate the Rive renderer into iOS (#5952) Co-authored-by: Chris Dalton <[email protected]> Co-authored-by: Luigi Rosso <[email protected]>
- Loading branch information
1 parent
cc236e3
commit b1f11bf
Showing
18 changed files
with
639 additions
and
213 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
f96c86fcc800a1fa2bec3e97be00cab395ea838d | ||
afc961233ea9dd22bf654d277b27de4d35b6a01f |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
#define RIVE_NO_PLS |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
workspace 'rive' | ||
configurations {'debug', 'release'} | ||
|
||
require 'setup_compiler' | ||
|
||
newoption { | ||
trigger = 'no-rive-decoders', | ||
description = '' | ||
} | ||
|
||
-- Build a no-op librive_pls_renderer.a so xcode still sees a static library to link with when the | ||
-- module isn't available. | ||
project 'rive_pls_renderer' | ||
do | ||
kind 'StaticLib' | ||
language 'C++' | ||
cppdialect 'C++17' | ||
exceptionhandling 'Off' | ||
rtti 'Off' | ||
targetdir '%{cfg.buildcfg}' | ||
objdir 'obj/%{cfg.buildcfg}' | ||
files {'../pls.cpp'} | ||
|
||
if os.host() == 'macosx' then | ||
iphoneos_sysroot = os.outputof('xcrun --sdk iphoneos --show-sdk-path') | ||
iphonesimulator_sysroot = os.outputof('xcrun --sdk iphonesimulator --show-sdk-path') | ||
|
||
filter {'system:ios', 'options:variant=system'} | ||
do | ||
targetdir 'iphoneos_%{cfg.buildcfg}' | ||
objdir 'obj/iphoneos_%{cfg.buildcfg}' | ||
buildoptions { | ||
'--target=arm64-apple-ios13.0.0', | ||
'-mios-version-min=13.0.0', | ||
'-isysroot ' .. iphoneos_sysroot | ||
} | ||
end | ||
|
||
filter {'system:ios', 'options:variant=simulator'} | ||
do | ||
targetdir 'iphonesimulator_%{cfg.buildcfg}' | ||
objdir 'obj/iphonesimulator_%{cfg.buildcfg}' | ||
buildoptions { | ||
'--target=arm64-apple-ios13.0.0-simulator', | ||
'-mios-version-min=13.0.0', | ||
'-arch x86_64', | ||
'-arch arm64', | ||
'-isysroot ' .. iphonesimulator_sysroot | ||
} | ||
end | ||
end | ||
end | ||
|
||
newoption { | ||
trigger = 'variant', | ||
value = 'type', | ||
description = 'Choose a particular variant to build', | ||
allowed = { | ||
{'system', 'Builds the static library for the provided system'}, | ||
{'simulator', 'Builds for an emulator/simulator for the provided system'} | ||
}, | ||
default = 'system' | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
// Build a no-op librive_pls_renderer.a so xcode still sees a static library to link with when the | ||
// module isn't available. | ||
void NullPLS() {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.