Skip to content

Instantly share code, notes, and snippets.

View hendych's full-sized avatar

Hendy Christianto hendych

  • Traveloka
  • Jakarta, Indonesia
View GitHub Profile
@hendych
hendych / convert-arm64-m1-guideline
Last active January 26, 2022 06:36
convert lib arm64 built for iOS devices to arm64 simulator
# In older arm64 architecture, xcode will build the library for iPhone devices.
# We need to change LC_VERSION_MIN_IPHONEOS to IOSSIMULATOR in the library linking command.
# You can check if the arm64 arch support simulator or not by running this command below:
# otool -l -arch arm64 lib.a
# We can create xcframework manually by creating folder with extension .xcframework,
# then inside the dir, we can create ios-arm64 and ios-arm64_x86_64-simulator folder with each contains framework
# or library that we want to link.
#
# But first we can remove the unused arch using this command
@hendych
hendych / BUCK
Created July 19, 2021 11:07
Quote import using Buck
apple_library(
name = "MyLibrary",
exported_headers = glob([
"MyLibary/**/*.h"
]),
srcs = glob([
"MyLibrary/**/*.m"
])
preprocessor_flags = [
"-I$(location //path_to_another_lib:rule_name#%s,private-headers)" % read_config("cxx", "default_platform")