Skip to content

Commit

Permalink
Import CSSLayout.h as a user include when it isn't available as a lib…
Browse files Browse the repository at this point in the history
…rary header
  • Loading branch information
robhogan committed Aug 24, 2016
1 parent b4999fc commit 141d35d
Show file tree
Hide file tree
Showing 5 changed files with 25 additions and 7 deletions.
6 changes: 6 additions & 0 deletions Libraries/Text/RCTTextManager.m
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,13 @@

#import "RCTTextManager.h"

//Internally we reference a separate library. See https://github.com/facebook/react-native/pull/9544
#if __has_include(<CSSLayout/CSSLayout.h>)
#import <CSSLayout/CSSLayout.h>
#else
#import "CSSLayout.h"
#endif

#import "RCTAccessibilityManager.h"
#import "RCTAssert.h"
#import "RCTConvert.h"
Expand Down
8 changes: 1 addition & 7 deletions React.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,8 @@ Pod::Spec.new do |s|
s.preserve_paths = "cli.js", "Libraries/**/*.js", "lint", "linter.js", "node_modules", "package.json", "packager", "PATENTS", "react-native-cli"

s.subspec 'Core' do |ss|
ss.dependency 'React/CSSLayout'
ss.source_files = "React/**/*.{c,h,m,mm,S}"
ss.exclude_files = "**/__tests__/*", "IntegrationTests/*", "React/CSSLayout/*"
ss.exclude_files = "**/__tests__/*", "IntegrationTests/*"
ss.frameworks = "JavaScriptCore"
ss.libraries = "stdc++"
ss.pod_target_xcconfig = { "CLANG_CXX_LANGUAGE_STANDARD" => "c++14" }
Expand All @@ -43,11 +42,6 @@ Pod::Spec.new do |s|
ss.preserve_paths = "Libraries/ART/**/*.js"
end

s.subspec 'CSSLayout' do |ss|
ss.source_files = "React/CSSLayout/**/*.{c,h}"
ss.header_mappings_dir = "React"
end

s.subspec 'RCTActionSheet' do |ss|
ss.dependency 'React/Core'
ss.source_files = "Libraries/ActionSheetIOS/*.{h,m}"
Expand Down
6 changes: 6 additions & 0 deletions React/Base/RCTConvert.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,13 @@
#import <QuartzCore/QuartzCore.h>
#import <UIKit/UIKit.h>

//Internally we reference a separate library. See https://github.com/facebook/react-native/pull/9544
#if __has_include(<CSSLayout/CSSLayout.h>)
#import <CSSLayout/CSSLayout.h>
#else
#import "CSSLayout.h"
#endif

#import "RCTAnimationType.h"
#import "RCTBorderStyle.h"
#import "RCTTextDecorationLineType.h"
Expand Down
6 changes: 6 additions & 0 deletions React/Modules/RCTUIManager.m
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,13 @@

#import <AVFoundation/AVFoundation.h>

//Internally we reference a separate library. See https://github.com/facebook/react-native/pull/9544
#if __has_include(<CSSLayout/CSSLayout.h>)
#import <CSSLayout/CSSLayout.h>
#else
#import "CSSLayout.h"
#endif

#import "RCTAccessibilityManager.h"
#import "RCTAnimationType.h"
#import "RCTAssert.h"
Expand Down
6 changes: 6 additions & 0 deletions React/Views/RCTShadowView.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,13 @@

#import <UIKit/UIKit.h>

//Internally we reference a separate library. See https://github.com/facebook/react-native/pull/9544
#if __has_include(<CSSLayout/CSSLayout.h>)
#import <CSSLayout/CSSLayout.h>
#else
#import "CSSLayout.h"
#endif

#import "RCTComponent.h"
#import "RCTRootView.h"

Expand Down

0 comments on commit 141d35d

Please sign in to comment.