Skip to content
Closed

v10 POC #1222

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -120,4 +120,8 @@ coverage
*.core.prefs
*.iml

example/accesstoken
example/env.json
example/ios/Podfile.lock

react-native-mapbox-gl-maps.tgz
33 changes: 31 additions & 2 deletions example/ios/Podfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
require_relative '../node_modules/react-native/scripts/react_native_pods'
require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules'

platform :ios, '10.0'
platform :ios, '13.0'


# We ingore warning except for RNMBGL
INHIBIT_WARNING_BY_DEFAULT = true
Expand Down Expand Up @@ -42,10 +43,38 @@ target 'RNMapboxGLExample' do
#
# Note that if you have use_frameworks! enabled, Flipper will not work and
# you should disable these next few lines.
use_flipper!
# use_flipper!
use_flipper!({ 'Flipper-Folly' => '2.3.0' })

post_install do |installer|
flipper_post_install(installer)
$RNMBGL.post_install(installer)


# Work around for issue described here: https://github.com/CocoaPods/CocoaPods/issues/8122#issuecomment-427680543
project_path = 'RNMapboxGLExample.xcodeproj'
project = Xcodeproj::Project.open(project_path)
project.targets.each do |target|
build_phase = target.build_phases.find { |bp| bp.display_name == '[CP] Copy Pods Resources' }

puts "build_phase: #{build_phase}"
if build_phase.present?
puts "Input paths: #{build_phase.input_paths.join(',')}"
build_phase.input_paths.push('${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/Assets.car')
build_phase.output_paths.delete('${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/Assets.car')
end
end
project.save(project_path)

project = Xcodeproj::Project.open(project_path)
project.targets.each do |target|
build_phase = target.build_phases.find { |bp| bp.display_name == '[CP] Copy Pods Resources' }

puts "[1] build_phase: #{build_phase}"
if build_phase.present?
puts "[2] Input paths: #{build_phase.input_paths.join(',')}"
end
end
end
end

Expand Down
12 changes: 10 additions & 2 deletions example/ios/RNMapboxGLExample.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -478,6 +478,8 @@
);
inputPaths = (
"${PODS_ROOT}/Target Support Files/Pods-RNMapboxGLExample/Pods-RNMapboxGLExample-resources.sh",
"${PODS_ROOT}/MapboxMaps/Sources/MapboxMaps/Ornaments/en.lproj/OrnamentsLocalizable.strings",
"${PODS_ROOT}/MapboxMaps/Sources/MapboxMaps/Location/Pucks/IndicatorAssets.xcassets",
"${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/AntDesign.ttf",
"${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/Entypo.ttf",
"${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/EvilIcons.ttf",
Expand All @@ -495,9 +497,11 @@
"${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/SimpleLineIcons.ttf",
"${PODS_ROOT}/../../node_modules/react-native-vector-icons/Fonts/Zocial.ttf",
"${PODS_CONFIGURATION_BUILD_DIR}/React-Core/AccessibilityResources.bundle",
"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/Assets.car",
);
name = "[CP] Copy Pods Resources";
outputPaths = (
"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/OrnamentsLocalizable.strings",
"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/AntDesign.ttf",
"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/Entypo.ttf",
"${TARGET_BUILD_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}/EvilIcons.ttf",
Expand Down Expand Up @@ -550,13 +554,17 @@
);
inputPaths = (
"${PODS_ROOT}/Target Support Files/Pods-RNMapboxGLExample/Pods-RNMapboxGLExample-frameworks.sh",
"${PODS_ROOT}/Mapbox-iOS-SDK/dynamic/Mapbox.framework",
"${BUILT_PRODUCTS_DIR}/MapboxMobileEvents/MapboxMobileEvents.framework",
"${BUILT_PRODUCTS_DIR}/Turf/Turf.framework",
"${PODS_XCFRAMEWORKS_BUILD_DIR}/MapboxCommon/MapboxCommon.framework/MapboxCommon",
"${PODS_XCFRAMEWORKS_BUILD_DIR}/MapboxCoreMaps/MapboxCoreMaps.framework/MapboxCoreMaps",
);
name = "[CP] Embed Pods Frameworks";
outputPaths = (
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/Mapbox.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/MapboxMobileEvents.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/Turf.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/MapboxCommon.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/MapboxCoreMaps.framework",
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
Expand Down
3 changes: 3 additions & 0 deletions ios/RCTMGL/Bridge/RCTMGL.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
/* Those will be available for Swift */
#import <React/RCTEventEmitter.h>
#import <React/RCTViewManager.h>
17 changes: 0 additions & 17 deletions ios/RCTMGL/CameraMode.h

This file was deleted.

17 changes: 0 additions & 17 deletions ios/RCTMGL/CameraMode.m

This file was deleted.

26 changes: 0 additions & 26 deletions ios/RCTMGL/CameraStop.h

This file was deleted.

81 changes: 0 additions & 81 deletions ios/RCTMGL/CameraStop.m

This file was deleted.

18 changes: 0 additions & 18 deletions ios/RCTMGL/CameraUpdateItem.h

This file was deleted.

Loading