-
Notifications
You must be signed in to change notification settings - Fork 440
[CMake] Add option to set the target namespace #2659
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
da1afec
to
93fc0a1
Compare
@swift-ci Please test |
93fc0a1
to
97805e9
Compare
@swift-ci Please test |
97805e9
to
2e419fd
Compare
@swift-ci Please test |
@swift-ci Please test Windows |
@swift-ci Please test |
1 similar comment
@swift-ci Please test |
@swift-ci please test Linux |
@swift-ci please test Linux platform |
2e419fd
to
0a8476a
Compare
@swift-ci Please test |
@swift-ci Please test Windows |
0a8476a
to
c2b41d8
Compare
@swift-ci Please test |
1 similar comment
@swift-ci Please test |
c2b41d8
to
ea53d4d
Compare
@swift-ci Please test |
@swift-ci Please test Windows |
ea53d4d
to
26ae5e9
Compare
@swift-ci Please test |
@swift-ci Please test Windows |
@@ -17,10 +17,21 @@ | |||
# | |||
# Remove once rdar://102202478 is fixed. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Presumably we now need to use this function regardless of whether rdar://102202478
is fixed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 Moved the comment to the -dep.swift
hack.
cmake_parse_arguments(ARGS "PUBLIC;PRIVATE;INTERFACE" "" "" ${ARGN}) | ||
foreach(DEPENDENCY ${ARGS_UNPARSED_ARGUMENTS}) | ||
set(link_type) | ||
if(ARGS_PUBLIC) | ||
set(link_type PUBLIC) | ||
elseif(ARGS_PRIVATE) | ||
set(link_type PRIVATE) | ||
elseif(ARGS_INTERFACE) | ||
set(link_type INTERFACE) | ||
endif() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should it be an error if you omit the link type?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
https://cmake.org/cmake/help/latest/command/target_link_libraries.html#libraries-for-both-a-target-and-its-dependents
Since it's optional for target_link_libraries
, I'm leaving it as is for now
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fair enough, my main concern would be if a new link type was added that wasn't handled here, it may get silently dropped
Each target name is prefixed with SWIFTSYNTAX_TARGET_NAMESPACE Also, add SWIFTSYNTAX_EMIT_MODULE setting; 'true' for building library-evolution enabled modules with .swiftinterface, 'false' for building fragile modules, undefined is 'true'
26ae5e9
to
4e7bb71
Compare
@swift-ci Please test |
@swift-ci Please test Windows |
Each target name is prefixed with
SWIFTSYNTAX_TARGET_NAMESPACE
Also, add
SWIFTSYNTAX_EMIT_MODULE
setting;true
for building library-evolution enabled modules with .swiftinterface,false
for building fragile modules, undefined istrue