1010#
1111#===----------------------------------------------------------------------===#
1212
13- # The list of sources without which it's impossible to build a core
14- # standard library. Try to add new standard library sources to
15- # SWIFTLIB_SOURCES, below, rather than SWIFTLIB_ESSENTIAL, if
16- # possible, to improve layering. Check that you got it right by
17- # configuring with -DSWIFT_CHECK_ESSENTIAL_STDLIB=YES
18- set (SWIFTLIB_ESSENTIAL
19- ### PLEASE KEEP THIS LIST IN ALPHABETICAL ORDER ###
13+ # The complete list of sources in the core standard library.
14+ set (SWIFTLIB_SOURCES
15+ ### "ESSENTIAL" SOURCES
16+ ### -- PLEASE KEEP THIS LIST IN ALPHABETICAL ORDER ###
2017 # Some files can't be sorted alphabetically, see notes in the list below.
2118 Algorithm.swift
2219 ArrayBody.swift
@@ -199,22 +196,10 @@ set(SWIFTLIB_ESSENTIAL
199196 StringGraphemeBreaking.swift # ORDER DEPENDENCY: Must follow UTF16.swift
200197 ValidUTF8Buffer.swift
201198 WriteBackMutableSlice.swift
202- MigrationSupport.swift)
203-
204- set (SWIFTLIB_ESSENTIAL_GYB_SOURCES
205- AtomicInt.swift.gyb
206- FloatingPointParsing.swift.gyb
207- FloatingPointTypes.swift.gyb
208- IntegerTypes.swift.gyb
209- UnsafeBufferPointer.swift.gyb
210- UnsafeRawBufferPointer.swift.gyb
211- )
199+ MigrationSupport.swift
212200
213- # The complete list of sources in the core standard library. Includes
214- # all the essential sources listed above.
215- set (SWIFTLIB_SOURCES
216- ${SWIFTLIB_ESSENTIAL}
217- ### PLEASE KEEP THIS LIST IN ALPHABETICAL ORDER ###
201+ ### "NON-ESSENTIAL" SOURCES, LAYERED ON TOP OF THE "ESSENTIAL" ONES
202+ ### -- PLEASE KEEP THIS LIST IN ALPHABETICAL ORDER ###
218203 Availability.swift
219204 CollectionDifference.swift
220205 CollectionOfOne.swift
@@ -236,7 +221,12 @@ set(SWIFTLIB_SOURCES
236221 )
237222
238223set (SWIFTLIB_GYB_SOURCES
239- ${SWIFTLIB_ESSENTIAL_GYB_SOURCES}
224+ AtomicInt.swift.gyb
225+ FloatingPointParsing.swift.gyb
226+ FloatingPointTypes.swift.gyb
227+ IntegerTypes.swift.gyb
228+ UnsafeBufferPointer.swift.gyb
229+ UnsafeRawBufferPointer.swift.gyb
240230 Int128.swift.gyb
241231 Tuple.swift.gyb
242232 )
@@ -267,10 +257,6 @@ elseif(SWIFT_PRIMARY_VARIANT_SDK STREQUAL "WINDOWS")
267257 list (APPEND swift_core_private_link_libraries shell32;DbgHelp;Synchronization)
268258endif ()
269259
270- option (SWIFT_CHECK_ESSENTIAL_STDLIB
271- "Check core standard library layering by linking its essential subset"
272- FALSE )
273-
274260if (NOT "${CMAKE_BUILD_TYPE} " STREQUAL "MinSizeRel" )
275261 list (APPEND swift_stdlib_compile_flags "-Xllvm" "-sil-inline-generics" )
276262 list (APPEND swift_stdlib_compile_flags "-Xllvm" "-sil-partial-specialization" )
@@ -292,15 +278,6 @@ list(APPEND swift_stdlib_compile_flags "-Xfrontend" "-enable-experimental-concis
292278list (APPEND swift_stdlib_compile_flags "-enable-experimental-feature" "Macros" )
293279list (APPEND swift_stdlib_compile_flags "-enable-experimental-feature" "FreestandingMacros" )
294280
295- if (SWIFT_CHECK_ESSENTIAL_STDLIB)
296- add_swift_target_library(swift_stdlib_essential ${SWIFT_STDLIB_LIBRARY_BUILD_TYPES} IS_STDLIB IS_STDLIB_CORE
297- INSTALL_IN_COMPONENT never_install
298- ${SWIFTLIB_ESSENTIAL}
299- GYB_SOURCES
300- ${SWIFTLIB_ESSENTIAL_GYB_SOURCES} )
301- target_link_libraries (swift_stdlib_essential ${RUNTIME_DEPENDENCY} )
302- endif ()
303-
304281set (swift_core_incorporate_object_libraries)
305282list (APPEND swift_core_incorporate_object_libraries swiftRuntime)
306283list (APPEND swift_core_incorporate_object_libraries swiftLLVMSupport)
0 commit comments