Skip to content

Commit 39c1cf0

Browse files
authored
Merge pull request #173 from baronha/nitro
🌈 HXPhoto Picker & Nitro Modules
2 parents 469336a + b881413 commit 39c1cf0

File tree

301 files changed

+37918
-30265
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

301 files changed

+37918
-30265
lines changed

.gitignore

+22-7
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,3 @@
1-
# Whitelist com.luck.picture.lib package
2-
#
3-
!picture_library/src/com/luck/picture/lib/
4-
51
# OSX
62
#
73
.DS_Store
@@ -35,19 +31,27 @@ project.xcworkspace
3531

3632
# Android/IJ
3733
#
38-
.idea
34+
.classpath
35+
.cxx
3936
.gradle
37+
.idea
38+
.project
39+
.settings
4040
local.properties
4141
android.iml
4242

4343
# Cocoapods
4444
#
4545
example/ios/Pods
4646

47+
# Ruby
48+
example/vendor/
49+
4750
# node.js
4851
#
4952
node_modules/
5053
npm-debug.log
54+
yarn-debug.log
5155
yarn-error.log
5256

5357
# BUCK
@@ -56,8 +60,19 @@ buck-out/
5660
android/app/libs
5761
android/keystores/debug.keystore
5862

63+
# Yarn
64+
.yarn/*
65+
!.yarn/patches
66+
!.yarn/plugins
67+
!.yarn/releases
68+
!.yarn/sdks
69+
!.yarn/versions
70+
5971
# Expo
60-
.expo/*
72+
.expo/
73+
74+
# Turborepo
75+
.turbo/
6176

6277
# generated by bob
63-
lib/*
78+
lib/

MultipleImagePicker.podspec

+47
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
require "json"
2+
3+
package = JSON.parse(File.read(File.join(__dir__, "package.json")))
4+
5+
Pod::Spec.new do |s|
6+
s.name = "MultipleImagePicker"
7+
s.version = package["version"]
8+
s.summary = package["description"]
9+
s.homepage = package["homepage"]
10+
s.license = package["license"]
11+
s.authors = package["author"]
12+
13+
s.platforms = { :ios => min_ios_version_supported }
14+
s.source = { :git => "https://github.com/baronha/react-native-multiple-image-picker.git", :tag => "#{s.version}" }
15+
16+
s.source_files = [
17+
# Implementation (Swift)
18+
"ios/**/*.{swift}",
19+
# Autolinking/Registration (Objective-C++)
20+
"ios/**/*.{m,mm}",
21+
# Implementation (C++ objects)
22+
"cpp/**/*.{hpp,cpp}",
23+
]
24+
25+
s.resource_bundles = {
26+
"MultipleImagePicker" => ["ios/Assets.xcassets"]
27+
}
28+
29+
30+
s.dependency "HXPhotoPicker/Picker/Lite", "4.2.3"
31+
s.dependency "HXPhotoPicker/Editor/Lite", "4.2.3"
32+
33+
s.pod_target_xcconfig = {
34+
# C++ compiler flags, mainly for folly.
35+
"GCC_PREPROCESSOR_DEFINITIONS" => "$(inherited) FOLLY_NO_CONFIG FOLLY_CFG_NO_COROUTINES"
36+
}
37+
38+
load 'nitrogen/generated/ios/MultipleImagePicker+autolinking.rb'
39+
40+
41+
add_nitrogen_files(s)
42+
43+
s.dependency 'React-jsi'
44+
s.dependency 'React-callinvoker'
45+
46+
install_modules_dependencies(s)
47+
end

android/.project

-17
This file was deleted.

android/CMakeLists.txt

+29
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
project(MultipleImagePicker)
2+
cmake_minimum_required(VERSION 3.9.0)
3+
4+
set (PACKAGE_NAME MultipleImagePicker)
5+
set (CMAKE_VERBOSE_MAKEFILE ON)
6+
set (CMAKE_CXX_STANDARD 20)
7+
8+
# Define C++ library and add all sources
9+
add_library(${PACKAGE_NAME} SHARED
10+
src/main/cpp/cpp-adapter.cpp
11+
)
12+
13+
# Add Nitrogen specs :)
14+
include(${CMAKE_SOURCE_DIR}/../nitrogen/generated/android/MultipleImagePicker+autolinking.cmake)
15+
16+
# Set up local includes
17+
include_directories(
18+
"src/main/cpp"
19+
"../cpp"
20+
)
21+
22+
find_library(LOG_LIB log)
23+
24+
# Link all libraries together
25+
target_link_libraries(
26+
${PACKAGE_NAME}
27+
${LOG_LIB}
28+
android # <-- Android core
29+
)

0 commit comments

Comments
 (0)