Reviewed By: emilsjolander Differential Revision: D6494379 fbshipit-source-id: f6b78d8a1b3d4bcdeef350ad7bd097cdbe5d15b1
67 lines
1.8 KiB
Python
67 lines
1.8 KiB
Python
# Copyright (c) 2014-present, Facebook, Inc.
|
|
# All rights reserved.
|
|
#
|
|
# This source code is licensed under the BSD-style license found in the
|
|
# LICENSE file in the root directory of this source tree. An additional grant
|
|
# of patent rights can be found in the PATENTS file in the same directory.
|
|
|
|
load("//:yoga_defs.bzl", "yoga_dep", "apple_library", "apple_test")
|
|
|
|
COMPILER_FLAGS = [
|
|
"-fobjc-arc",
|
|
"-Wconditional-uninitialized",
|
|
"-Wdangling-else",
|
|
"-Wdeprecated-declarations",
|
|
"-Wimplicit-retain-self",
|
|
"-Wincomplete-implementation",
|
|
"-Wobjc-method-access",
|
|
"-Wobjc-missing-super-calls",
|
|
"-Wmismatched-return-types",
|
|
"-Wreturn-type",
|
|
"-Wno-global-constructors",
|
|
"-Wno-shadow",
|
|
"-Wunused-const-variable",
|
|
"-Wunused-function",
|
|
"-Wunused-property-ivar",
|
|
"-Wunused-result",
|
|
"-Wunused-value",
|
|
]
|
|
|
|
apple_library(
|
|
name = "YogaKit",
|
|
srcs = glob(["Source/**/*.m"]),
|
|
exported_headers = subdir_glob(
|
|
[
|
|
("", "Source/**/*.h"),
|
|
("Source", "**/*.h"),
|
|
],
|
|
prefix = "YogaKit",
|
|
),
|
|
compiler_flags = COMPILER_FLAGS,
|
|
frameworks = [
|
|
"$SDKROOT/System/Library/Frameworks/Foundation.framework",
|
|
"$SDKROOT/System/Library/Frameworks/UIKit.framework",
|
|
],
|
|
header_path_prefix = "",
|
|
link_whole = True,
|
|
visibility = ["PUBLIC"],
|
|
deps = [
|
|
yoga_dep(":yoga"),
|
|
],
|
|
)
|
|
|
|
apple_test(
|
|
name = "YogaKitTests",
|
|
srcs = glob(["Tests/**/*.m"]),
|
|
compiler_flags = COMPILER_FLAGS,
|
|
frameworks = [
|
|
"$PLATFORM_DIR/Developer/Library/Frameworks/XCTest.framework",
|
|
"$SDKROOT/System/Library/Frameworks/CoreGraphics.framework",
|
|
],
|
|
info_plist = "Tests/Info.plist",
|
|
visibility = ["PUBLIC"],
|
|
deps = [
|
|
":YogaKit",
|
|
],
|
|
)
|