2024-07-03 17:23:27 +00:00
|
|
|
include(vulkan)
|
|
|
|
|
2024-03-25 14:08:52 +00:00
|
|
|
# These are the minimal set of sources needed to build the code generators. We separate them to allow
|
|
|
|
# LibCore to depend on generated sources.
|
2020-05-06 15:40:06 +00:00
|
|
|
set(SOURCES
|
|
|
|
ArgsParser.cpp
|
2022-04-10 16:28:43 +00:00
|
|
|
Directory.cpp
|
2023-03-02 15:39:07 +00:00
|
|
|
DirectoryEntry.cpp
|
2020-05-06 15:40:06 +00:00
|
|
|
DirIterator.cpp
|
2024-03-29 19:32:06 +00:00
|
|
|
Environment.cpp
|
2024-03-25 14:08:52 +00:00
|
|
|
File.cpp
|
|
|
|
StandardPaths.cpp
|
|
|
|
System.cpp
|
|
|
|
Version.cpp
|
|
|
|
)
|
|
|
|
|
2024-03-29 19:32:06 +00:00
|
|
|
serenity_lib(LibCoreMinimal coreminimal)
|
2024-03-25 14:08:52 +00:00
|
|
|
|
2024-06-23 12:35:17 +00:00
|
|
|
if (LAGOM_TOOLS_ONLY)
|
|
|
|
return()
|
|
|
|
endif()
|
|
|
|
|
2024-03-25 14:08:52 +00:00
|
|
|
set(SOURCES
|
|
|
|
AnonymousBuffer.cpp
|
|
|
|
Command.cpp
|
2024-06-23 12:15:58 +00:00
|
|
|
ConfigFile.cpp
|
2024-03-25 14:08:52 +00:00
|
|
|
DateTime.cpp
|
2020-05-06 15:40:06 +00:00
|
|
|
ElapsedTimer.cpp
|
|
|
|
Event.cpp
|
|
|
|
EventLoop.cpp
|
2023-04-24 10:25:14 +00:00
|
|
|
EventLoopImplementation.cpp
|
|
|
|
EventLoopImplementationUnix.cpp
|
2023-08-06 16:09:39 +00:00
|
|
|
EventReceiver.cpp
|
2021-07-22 03:04:24 +00:00
|
|
|
LockFile.cpp
|
2021-11-23 10:32:25 +00:00
|
|
|
MappedFile.cpp
|
2020-05-06 15:40:06 +00:00
|
|
|
MimeData.cpp
|
|
|
|
Notifier.cpp
|
2021-08-05 23:04:11 +00:00
|
|
|
Process.cpp
|
2020-05-06 15:40:06 +00:00
|
|
|
ProcessStatisticsReader.cpp
|
2023-10-02 20:36:53 +00:00
|
|
|
Resource.cpp
|
|
|
|
ResourceImplementation.cpp
|
|
|
|
ResourceImplementationFile.cpp
|
2021-09-12 13:54:57 +00:00
|
|
|
SecretString.cpp
|
2024-06-23 12:15:58 +00:00
|
|
|
SessionManagement.cpp
|
2023-02-08 22:05:44 +00:00
|
|
|
Socket.cpp
|
2022-04-05 23:44:18 +00:00
|
|
|
SOCKSProxyClient.cpp
|
2022-01-15 11:56:48 +00:00
|
|
|
SystemServerTakeover.cpp
|
2020-05-06 15:40:06 +00:00
|
|
|
TCPServer.cpp
|
2023-04-23 17:45:12 +00:00
|
|
|
ThreadEventQueue.cpp
|
2020-05-06 15:40:06 +00:00
|
|
|
Timer.cpp
|
|
|
|
UDPServer.cpp
|
|
|
|
)
|
2022-11-20 03:23:14 +00:00
|
|
|
if (NOT ANDROID AND NOT WIN32 AND NOT EMSCRIPTEN)
|
2022-10-13 20:07:09 +00:00
|
|
|
list(APPEND SOURCES
|
|
|
|
Account.cpp
|
|
|
|
FilePermissionsMask.cpp
|
|
|
|
GetPassword.cpp
|
|
|
|
Group.cpp
|
|
|
|
)
|
2022-07-11 07:06:29 +00:00
|
|
|
endif()
|
2023-07-19 15:55:49 +00:00
|
|
|
if (NOT WIN32 AND NOT EMSCRIPTEN)
|
|
|
|
list(APPEND SOURCES LocalServer.cpp)
|
|
|
|
endif()
|
2020-05-06 15:40:06 +00:00
|
|
|
|
2024-08-24 16:15:13 +00:00
|
|
|
# FIXME: Implement these for other systems.
|
2024-06-04 00:10:39 +00:00
|
|
|
if (LINUX AND NOT EMSCRIPTEN)
|
2024-04-21 03:35:17 +00:00
|
|
|
list(APPEND SOURCES
|
|
|
|
FileWatcherLinux.cpp
|
|
|
|
Platform/ProcessStatisticsLinux.cpp
|
2024-08-24 16:15:13 +00:00
|
|
|
TimeZoneWatcherLinux.cpp
|
2024-04-21 03:35:17 +00:00
|
|
|
)
|
2024-02-27 13:32:29 +00:00
|
|
|
elseif (APPLE AND NOT IOS)
|
2024-04-21 03:35:17 +00:00
|
|
|
list(APPEND SOURCES
|
|
|
|
FileWatcherMacOS.mm
|
|
|
|
Platform/ProcessStatisticsMach.cpp
|
2024-08-24 16:15:13 +00:00
|
|
|
TimeZoneWatcherMacOS.mm
|
2024-04-21 03:35:17 +00:00
|
|
|
)
|
2023-01-17 18:49:21 +00:00
|
|
|
else()
|
2024-04-21 03:35:17 +00:00
|
|
|
list(APPEND SOURCES
|
|
|
|
FileWatcherUnimplemented.cpp
|
|
|
|
Platform/ProcessStatisticsUnimplemented.cpp
|
2024-08-24 16:15:13 +00:00
|
|
|
TimeZoneWatcherUnimplemented.cpp
|
2024-04-21 03:35:17 +00:00
|
|
|
)
|
2023-01-17 18:49:21 +00:00
|
|
|
endif()
|
|
|
|
|
2024-07-03 17:23:27 +00:00
|
|
|
if (HAS_VULKAN)
|
|
|
|
list(APPEND SOURCES VulkanContext.cpp)
|
|
|
|
endif()
|
|
|
|
|
2024-04-04 19:59:44 +00:00
|
|
|
if (APPLE OR CMAKE_SYSTEM_NAME STREQUAL "GNU")
|
|
|
|
list(APPEND SOURCES MachPort.cpp)
|
|
|
|
endif()
|
|
|
|
|
2024-06-20 18:33:34 +00:00
|
|
|
if (APPLE)
|
|
|
|
list(APPEND SOURCES IOSurface.cpp)
|
2024-06-26 15:56:55 +00:00
|
|
|
list(APPEND SOURCES MetalContext.mm)
|
2024-06-20 18:33:34 +00:00
|
|
|
endif()
|
|
|
|
|
2020-05-06 15:40:06 +00:00
|
|
|
serenity_lib(LibCore core)
|
2024-06-25 19:27:20 +00:00
|
|
|
target_link_libraries(LibCore PRIVATE LibCrypt LibUnicode LibURL)
|
2024-03-29 19:32:06 +00:00
|
|
|
target_link_libraries(LibCore PUBLIC LibCoreMinimal)
|
2023-01-18 19:03:14 +00:00
|
|
|
|
|
|
|
if (APPLE)
|
|
|
|
target_link_libraries(LibCore PUBLIC "-framework CoreFoundation")
|
|
|
|
target_link_libraries(LibCore PUBLIC "-framework CoreServices")
|
|
|
|
target_link_libraries(LibCore PUBLIC "-framework Foundation")
|
2024-06-20 18:33:34 +00:00
|
|
|
target_link_libraries(LibCore PUBLIC "-framework IOSurface")
|
2024-06-26 15:56:55 +00:00
|
|
|
target_link_libraries(LibCore PUBLIC "-framework Metal")
|
2023-01-18 19:03:14 +00:00
|
|
|
endif()
|
2023-09-14 05:19:25 +00:00
|
|
|
|
|
|
|
if (ANDROID)
|
|
|
|
target_link_libraries(LibCore PRIVATE log)
|
|
|
|
endif()
|
2024-07-03 17:23:27 +00:00
|
|
|
|
|
|
|
if (HAS_VULKAN)
|
2024-07-05 22:12:52 +00:00
|
|
|
target_link_libraries(LibCore PUBLIC Vulkan::Vulkan Vulkan::Headers)
|
2024-07-03 17:23:27 +00:00
|
|
|
endif()
|