diff --git a/ReactNativeEnrichedMarkdown.podspec b/ReactNativeEnrichedMarkdown.podspec index e191da8a..01a99c6b 100644 --- a/ReactNativeEnrichedMarkdown.podspec +++ b/ReactNativeEnrichedMarkdown.podspec @@ -22,11 +22,15 @@ Pod::Spec.new do |s| preprocessor_defs = '$(inherited) MD4C_USE_UTF8=1' if enable_math preprocessor_defs += ' ENRICHED_MARKDOWN_MATH=1' - s.dependency 'iosMath', '~> 0.9' + spm_dependency(s, + url: 'https://github.com/kostub/iosMath.git', + requirement: { kind: 'upToNextMajorVersion', minimumVersion: '2.2.0' }, + products: ['iosMath'] + ) end s.pod_target_xcconfig = { - 'HEADER_SEARCH_PATHS' => '"$(PODS_TARGET_SRCROOT)/cpp/md4c" "$(PODS_TARGET_SRCROOT)/cpp/parser" "$(PODS_TARGET_SRCROOT)/ios/internals" "$(PODS_TARGET_SRCROOT)/ios/input/internals"', + 'HEADER_SEARCH_PATHS' => '"$(PODS_TARGET_SRCROOT)/cpp/md4c" "$(PODS_TARGET_SRCROOT)/cpp/parser" "$(PODS_TARGET_SRCROOT)/ios/internals" "$(PODS_TARGET_SRCROOT)/ios/input/internals" "$(SYMROOT)/../../SourcePackages/checkouts/iosMath/iosMath/lib" "$(SYMROOT)/../../SourcePackages/checkouts/iosMath/iosMath/render" "$(SYMROOT)/../../SourcePackages/checkouts/iosMath/iosMath/render/internal"', 'GCC_PREPROCESSOR_DEFINITIONS' => preprocessor_defs, 'CLANG_CXX_LANGUAGE_STANDARD' => 'c++17' } diff --git a/ios/attachments/ENRMMathInlineAttachmentShared.h b/ios/attachments/ENRMMathInlineAttachmentShared.h index a7442e9f..790fe02b 100644 --- a/ios/attachments/ENRMMathInlineAttachmentShared.h +++ b/ios/attachments/ENRMMathInlineAttachmentShared.h @@ -3,7 +3,7 @@ #import "ENRMMathInlineAttachment.h" #if ENRICHED_MARKDOWN_MATH -#import +@import iosMath; @interface ENRMMathInlineAttachment () { CGSize _cachedSize; diff --git a/ios/views/ENRMMathContainerView.m b/ios/views/ENRMMathContainerView.m index 761fcc00..50526978 100644 --- a/ios/views/ENRMMathContainerView.m +++ b/ios/views/ENRMMathContainerView.m @@ -4,7 +4,7 @@ #if ENRICHED_MARKDOWN_MATH #import "PasteboardUtils.h" -#import +@import iosMath; #if TARGET_OS_OSX #import "ENRMMenuAction.h" #endif