forked from flame-engine/flame_gamepad
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Recreating stuff to prepare for iOS support
- Loading branch information
1 parent
d4c19e4
commit b620037
Showing
29 changed files
with
296 additions
and
105 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
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
13 changes: 0 additions & 13 deletions
13
example/android/app/src/main/java/xyz/fireslime/flamegamepadexample/MainActivity.java
This file was deleted.
Oops, something went wrong.
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,2 @@ | ||
org.gradle.jvmargs=-Xmx1536M | ||
|
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,2 @@ | ||
#include "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig" | ||
#include "Generated.xcconfig" |
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,2 @@ | ||
#include "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig" | ||
#include "Generated.xcconfig" |
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,77 @@ | ||
# Using a CDN with CocoaPods 1.7.2 or later can save a lot of time on pod installation, but it's experimental rather than the default. | ||
# source 'https://cdn.cocoapods.org/' | ||
|
||
# Uncomment this line to define a global platform for your project | ||
# platform :ios, '9.0' | ||
|
||
# CocoaPods analytics sends network stats synchronously affecting flutter build latency. | ||
ENV['COCOAPODS_DISABLE_STATS'] = 'true' | ||
|
||
project 'Runner', { | ||
'Debug' => :debug, | ||
'Profile' => :release, | ||
'Release' => :release, | ||
} | ||
|
||
def parse_KV_file(file, separator='=') | ||
file_abs_path = File.expand_path(file) | ||
if !File.exists? file_abs_path | ||
return []; | ||
end | ||
pods_ary = [] | ||
skip_line_start_symbols = ["#", "/"] | ||
File.foreach(file_abs_path) { |line| | ||
next if skip_line_start_symbols.any? { |symbol| line =~ /^\s*#{symbol}/ } | ||
plugin = line.split(pattern=separator) | ||
if plugin.length == 2 | ||
podname = plugin[0].strip() | ||
path = plugin[1].strip() | ||
podpath = File.expand_path("#{path}", file_abs_path) | ||
pods_ary.push({:name => podname, :path => podpath}); | ||
else | ||
puts "Invalid plugin specification: #{line}" | ||
end | ||
} | ||
return pods_ary | ||
end | ||
|
||
target 'Runner' do | ||
use_frameworks! | ||
|
||
# Prepare symlinks folder. We use symlinks to avoid having Podfile.lock | ||
# referring to absolute paths on developers' machines. | ||
system('rm -rf .symlinks') | ||
system('mkdir -p .symlinks/plugins') | ||
|
||
# Flutter Pods | ||
generated_xcode_build_settings = parse_KV_file('./Flutter/Generated.xcconfig') | ||
if generated_xcode_build_settings.empty? | ||
puts "Generated.xcconfig must exist. If you're running pod install manually, make sure flutter pub get is executed first." | ||
end | ||
generated_xcode_build_settings.map { |p| | ||
if p[:name] == 'FLUTTER_FRAMEWORK_DIR' | ||
symlink = File.join('.symlinks', 'flutter') | ||
File.symlink(File.dirname(p[:path]), symlink) | ||
pod 'Flutter', :path => File.join(symlink, File.basename(p[:path])) | ||
end | ||
} | ||
|
||
# Plugin Pods | ||
plugin_pods = parse_KV_file('../.flutter-plugins') | ||
plugin_pods.map { |p| | ||
symlink = File.join('.symlinks', 'plugins', p[:name]) | ||
File.symlink(p[:path], symlink) | ||
pod p[:name], :path => File.join(symlink, 'ios') | ||
} | ||
end | ||
|
||
# Prevent Cocoapods from embedding a second Flutter framework and causing an error with the new Xcode build system. | ||
install! 'cocoapods', :disable_input_output_paths => true | ||
|
||
post_install do |installer| | ||
installer.pods_project.targets.each do |target| | ||
target.build_configurations.each do |config| | ||
config.build_settings['ENABLE_BITCODE'] = 'NO' | ||
end | ||
end | ||
end |
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,22 @@ | ||
PODS: | ||
- flame_gamepad (0.0.1): | ||
- Flutter | ||
- Flutter (1.0.0) | ||
|
||
DEPENDENCIES: | ||
- flame_gamepad (from `.symlinks/plugins/flame_gamepad/ios`) | ||
- Flutter (from `.symlinks/flutter/ios`) | ||
|
||
EXTERNAL SOURCES: | ||
flame_gamepad: | ||
:path: ".symlinks/plugins/flame_gamepad/ios" | ||
Flutter: | ||
:path: ".symlinks/flutter/ios" | ||
|
||
SPEC CHECKSUMS: | ||
flame_gamepad: 73ae906e43bba827708a3f0b015359e5b5933ee9 | ||
Flutter: 0e3d915762c693b495b44d77113d4970485de6ec | ||
|
||
PODFILE CHECKSUM: 10ae9c18d12c9ffc2275c9a159a3b1e281990db0 | ||
|
||
COCOAPODS: 1.7.0.beta.2 |
Oops, something went wrong.