From f5cc77bffad7263957e9e68f8d1e55c7b21777df Mon Sep 17 00:00:00 2001 From: Jonas Salling Date: Fri, 9 Oct 2020 11:19:13 +0200 Subject: [PATCH] cleanup --- Package.swift | 2 +- Yoga.podspec | 3 +-- yoga/YGMacros.h | 10 ---------- yoga/apple-public/umbrella.h | 19 +++++++++++++++++++ yoga/include/YGEnums.h | 1 - yoga/include/YGMacros.h | 1 - yoga/include/YGNode.h | 1 - yoga/include/YGStyle.h | 1 - yoga/include/YGValue.h | 1 - yoga/include/Yoga.h | 1 - 10 files changed, 21 insertions(+), 19 deletions(-) create mode 100644 yoga/apple-public/umbrella.h delete mode 120000 yoga/include/YGEnums.h delete mode 120000 yoga/include/YGMacros.h delete mode 120000 yoga/include/YGNode.h delete mode 120000 yoga/include/YGStyle.h delete mode 120000 yoga/include/YGValue.h delete mode 120000 yoga/include/Yoga.h diff --git a/Package.swift b/Package.swift index 51db3f0a..29e20190 100644 --- a/Package.swift +++ b/Package.swift @@ -11,7 +11,6 @@ let package = Package( products: [ .library( name: "yoga", - type: .dynamic, targets: ["yoga"] ), ], @@ -20,6 +19,7 @@ let package = Package( name: "yoga", dependencies: [], path: "./yoga", + publicHeadersPath: "./apple-public", cxxSettings: [ .headerSearchPath("../"), ], diff --git a/Yoga.podspec b/Yoga.podspec index 2de2907d..17f46f3d 100644 --- a/Yoga.podspec +++ b/Yoga.podspec @@ -33,7 +33,6 @@ Pod::Spec.new do |spec| '-fPIC' ] spec.source_files = 'yoga/**/*.{c,h,cpp}' - spec.exclude_files = 'yoga/include/*.h' - spec.public_header_files = 'yoga/{Yoga,YGEnums,YGMacros,YGNode,YGStyle,YGValue}.h' + spec.public_header_files = 'yoga/apple-public/umbrella.h' end diff --git a/yoga/YGMacros.h b/yoga/YGMacros.h index 51d41e2b..c6917f1b 100644 --- a/yoga/YGMacros.h +++ b/yoga/YGMacros.h @@ -7,16 +7,6 @@ #pragma once - -#ifdef __OBJC__ -#import -#endif - - - - - - #ifdef __cplusplus #define YG_EXTERN_C_BEGIN extern "C" { #define YG_EXTERN_C_END } diff --git a/yoga/apple-public/umbrella.h b/yoga/apple-public/umbrella.h new file mode 100644 index 00000000..eb8ab61a --- /dev/null +++ b/yoga/apple-public/umbrella.h @@ -0,0 +1,19 @@ +/* + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */ + +#pragma once + +#ifdef __OBJC__ +#import + +#include "../YGEnums.h" +#include "../YGMacros.h" +#include "../YGNode.h" +#include "../YGStyle.h" +#include "../YGValue.h" +#include "../Yoga.h" +#endif diff --git a/yoga/include/YGEnums.h b/yoga/include/YGEnums.h deleted file mode 120000 index b080fca6..00000000 --- a/yoga/include/YGEnums.h +++ /dev/null @@ -1 +0,0 @@ -../YGEnums.h \ No newline at end of file diff --git a/yoga/include/YGMacros.h b/yoga/include/YGMacros.h deleted file mode 120000 index fca0bfed..00000000 --- a/yoga/include/YGMacros.h +++ /dev/null @@ -1 +0,0 @@ -../YGMacros.h \ No newline at end of file diff --git a/yoga/include/YGNode.h b/yoga/include/YGNode.h deleted file mode 120000 index 39b51ee8..00000000 --- a/yoga/include/YGNode.h +++ /dev/null @@ -1 +0,0 @@ -../YGNode.h \ No newline at end of file diff --git a/yoga/include/YGStyle.h b/yoga/include/YGStyle.h deleted file mode 120000 index 9b8fb709..00000000 --- a/yoga/include/YGStyle.h +++ /dev/null @@ -1 +0,0 @@ -../YGStyle.h \ No newline at end of file diff --git a/yoga/include/YGValue.h b/yoga/include/YGValue.h deleted file mode 120000 index 1d340bd1..00000000 --- a/yoga/include/YGValue.h +++ /dev/null @@ -1 +0,0 @@ -../YGValue.h \ No newline at end of file diff --git a/yoga/include/Yoga.h b/yoga/include/Yoga.h deleted file mode 120000 index a148821c..00000000 --- a/yoga/include/Yoga.h +++ /dev/null @@ -1 +0,0 @@ -../Yoga.h \ No newline at end of file