Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on Mar 28, 2020. It is now read-only.
/swift-clangPublic archive

Commit36a5e1a

Browse files
committed
Merge remote-tracking branch 'origin/apple/stable/20190619' into stable
2 parentsdbf97d9 +7c4fe05 commit36a5e1a

File tree

5 files changed

+24
-4
lines changed

5 files changed

+24
-4
lines changed

‎cmake/modules/AddClang.cmake‎

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,9 +86,13 @@ macro(add_clang_library name)
8686
# llvm_add_library ignores BUILD_SHARED_LIBS if STATIC is explicitly set,
8787
# so we need to handle it here.
8888
if(BUILD_SHARED_LIBS)
89-
set(LIBTYPE SHARED OBJECT)
89+
set(LIBTYPE SHARED)
9090
else()
91-
set(LIBTYPESTATIC OBJECT)
91+
set(LIBTYPESTATIC)
92+
endif()
93+
if(NOT XCODE)
94+
# The Xcode generator doesn't handle object libraries correctly.
95+
list(APPEND LIBTYPE OBJECT)
9296
endif()
9397
set_property(GLOBALAPPEND PROPERTY CLANG_STATIC_LIBS${name})
9498
endif()

‎include/indexstore/indexstore.h‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -297,6 +297,7 @@ typedef enum {
297297
INDEXSTORE_SYMBOL_ROLE_ADDRESSOF=1 <<7,
298298
INDEXSTORE_SYMBOL_ROLE_IMPLICIT=1 <<8,
299299
INDEXSTORE_SYMBOL_ROLE_UNDEFINITION=1 <<19,
300+
INDEXSTORE_SYMBOL_ROLE_NAMEREFERENCE=1 <<20,
300301

301302
// Relation roles.
302303
INDEXSTORE_SYMBOL_ROLE_REL_CHILDOF=1 <<9,

‎lib/DirectoryWatcher/DirectoryWatcher.cpp‎

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,11 @@ struct DirectoryScan {
9292
#define__has_include(x)0
9393
#endif
9494

95-
#if __has_include(<CoreServices/CoreServices.h>)
95+
#if !defined(__is_target_os)
96+
#define__is_target_os(x)0
97+
#endif
98+
99+
#if __is_target_os(macos)
96100
#include"DirectoryWatcher-mac.inc.h"
97101
#elif __has_include(<sys/inotify.h>)
98102
#include"DirectoryWatcher-linux.inc.h"

‎lib/Index/IndexDataStoreUtils.cpp‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -275,6 +275,8 @@ SymbolRoleSet index::getSymbolRoles(uint64_t Roles) {
275275
SymbolRoles |= (SymbolRoleSet)SymbolRole::RelationIBTypeOf;
276276
if (Roles & INDEXSTORE_SYMBOL_ROLE_REL_SPECIALIZATIONOF)
277277
SymbolRoles |= (SymbolRoleSet)SymbolRole::RelationSpecializationOf;
278+
if (Roles & INDEXSTORE_SYMBOL_ROLE_NAMEREFERENCE)
279+
SymbolRoles |= (SymbolRoleSet)SymbolRole::NameReference;
278280

279281
return SymbolRoles;
280282
}
@@ -511,6 +513,9 @@ uint64_t index::getIndexStoreRoles(SymbolRoleSet Roles) {
511513
case SymbolRole::RelationSpecializationOf:
512514
storeRoles |= INDEXSTORE_SYMBOL_ROLE_REL_SPECIALIZATIONOF;
513515
break;
516+
case SymbolRole::NameReference:
517+
storeRoles |= INDEXSTORE_SYMBOL_ROLE_NAMEREFERENCE;
518+
break;
514519
}
515520
});
516521
return storeRoles;

‎tools/clang-shlib/CMakeLists.txt‎

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,13 @@ endif()
66
get_property(clang_libsGLOBAL PROPERTY CLANG_STATIC_LIBS)
77

88
foreach (lib${clang_libs})
9-
list(APPEND _OBJECTS $<TARGET_OBJECTS:obj.${lib}>)
9+
if(XCODE)
10+
# Xcode doesn't support object libraries, so we have to trick it into
11+
# linking the static libraries instead.
12+
list(APPEND _DEPS"-force_load"${lib})
13+
else()
14+
list(APPEND _OBJECTS $<TARGET_OBJECTS:obj.${lib}>)
15+
endif()
1016
list(APPEND _DEPS $<TARGET_PROPERTY:${lib},INTERFACE_LINK_LIBRARIES>)
1117
list(APPEND _DEPS $<TARGET_PROPERTY:${lib},LINK_LIBRARIES>)
1218
endforeach ()

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp