mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 10:12:45 +00:00 
			
		
		
		
	Libraries: Move to Userland/Libraries/
This commit is contained in:
		
							parent
							
								
									dc28c07fa5
								
							
						
					
					
						commit
						13d7c09125
					
				
					 1857 changed files with 266 additions and 274 deletions
				
			
		
							
								
								
									
										2
									
								
								.github/workflows/cmake.yml
									
										
									
									
										vendored
									
									
								
							
							
						
						
									
										2
									
								
								.github/workflows/cmake.yml
									
										
									
									
										vendored
									
									
								
							|  | @ -80,7 +80,7 @@ jobs: | |||
|         # This assumes that *ALL* LibC headers have an impact on the Toolchain. | ||||
|         # This is wrong, and causes more Toolchain rebuilds than necessary. | ||||
|         # However, we want to avoid false cache hits at all costs. | ||||
|         key: ${{ runner.os }}-toolchain-i686-${{ hashFiles('Libraries/LibC/**/*.h', 'Toolchain/Patches/*.patch', 'Toolchain/BuildIt.sh') }} | ||||
|         key: ${{ runner.os }}-toolchain-i686-${{ hashFiles('Userland/Libraries/LibC/**/*.h', 'Toolchain/Patches/*.patch', 'Toolchain/BuildIt.sh') }} | ||||
|     - name: Restore or regenerate Toolchain | ||||
|       run: TRY_USE_LOCAL_TOOLCHAIN=y ${{ github.workspace }}/Toolchain/BuildIt.sh | ||||
| 
 | ||||
|  |  | |||
|  | @ -68,14 +68,14 @@ if (ENABLE_ALL_THE_DEBUG_MACROS) | |||
|     include(${CMAKE_SOURCE_DIR}/Meta/CMake/all_the_debug_macros.cmake) | ||||
| endif(ENABLE_ALL_THE_DEBUG_MACROS) | ||||
| 
 | ||||
| include_directories(Libraries) | ||||
| include_directories(Userland/Libraries) | ||||
| include_directories(.) | ||||
| 
 | ||||
| add_subdirectory(Meta/Lagom) | ||||
| add_subdirectory(DevTools/IPCCompiler) | ||||
| add_subdirectory(Libraries/LibWeb/CodeGenerators) | ||||
| add_subdirectory(Userland/Libraries/LibWeb/CodeGenerators) | ||||
| add_subdirectory(AK/Tests) | ||||
| add_subdirectory(Libraries/LibRegex/Tests) | ||||
| add_subdirectory(Userland/Libraries/LibRegex/Tests) | ||||
| 
 | ||||
| set(write_if_different ${CMAKE_SOURCE_DIR}/Meta/write-only-on-difference.sh) | ||||
| 
 | ||||
|  | @ -134,18 +134,17 @@ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pie -fpic") | |||
| 
 | ||||
| add_link_options(--sysroot ${CMAKE_BINARY_DIR}/Root) | ||||
| 
 | ||||
| include_directories(Libraries/LibC) | ||||
| include_directories(Libraries/LibM) | ||||
| include_directories(Userland/Libraries/LibC) | ||||
| include_directories(Userland/Libraries/LibM) | ||||
| include_directories(Services) | ||||
| include_directories(Userland) | ||||
| include_directories(${CMAKE_CURRENT_BINARY_DIR}) | ||||
| include_directories(${CMAKE_CURRENT_BINARY_DIR}/Services) | ||||
| include_directories(${CMAKE_CURRENT_BINARY_DIR}/Libraries) | ||||
| include_directories(${CMAKE_CURRENT_BINARY_DIR}/Userland/Libraries) | ||||
| include_directories(${CMAKE_CURRENT_BINARY_DIR}/Userland) | ||||
| 
 | ||||
| add_subdirectory(AK) | ||||
| add_subdirectory(Kernel) | ||||
| add_subdirectory(Libraries) | ||||
| add_subdirectory(Services) | ||||
| add_subdirectory(DevTools) | ||||
| add_subdirectory(Userland) | ||||
|  |  | |||
|  | @ -230,26 +230,26 @@ set(AK_SOURCES | |||
| ) | ||||
| 
 | ||||
| set(ELF_SOURCES | ||||
|     ../Libraries/LibELF/Image.cpp | ||||
|     ../Libraries/LibELF/Validation.cpp | ||||
|     ../Userland/Libraries/LibELF/Image.cpp | ||||
|     ../Userland/Libraries/LibELF/Validation.cpp | ||||
| ) | ||||
| 
 | ||||
| set(VT_SOURCES | ||||
|     ../Libraries/LibVT/Terminal.cpp | ||||
|     ../Libraries/LibVT/Line.cpp | ||||
|     ../Userland/Libraries/LibVT/Terminal.cpp | ||||
|     ../Userland/Libraries/LibVT/Line.cpp | ||||
| ) | ||||
| 
 | ||||
| set(KEYBOARD_SOURCES | ||||
|     ../Libraries/LibKeyboard/CharacterMap.cpp | ||||
|     ../Userland/Libraries/LibKeyboard/CharacterMap.cpp | ||||
| ) | ||||
| 
 | ||||
| set(CRYPTO_SOURCES | ||||
|     ../Libraries/LibCrypto/Cipher/AES.cpp | ||||
|     ../Libraries/LibCrypto/Hash/SHA2.cpp | ||||
|     ../Userland/Libraries/LibCrypto/Cipher/AES.cpp | ||||
|     ../Userland/Libraries/LibCrypto/Hash/SHA2.cpp | ||||
| ) | ||||
| 
 | ||||
| set(C_SOURCES | ||||
|     ../Libraries/LibC/ctype.cpp | ||||
|     ../Userland/Libraries/LibC/ctype.cpp | ||||
| ) | ||||
| 
 | ||||
| set(SOURCES | ||||
|  |  | |||
|  | @ -26,7 +26,7 @@ endfunction() | |||
| 
 | ||||
| function(serenity_lib target_name fs_name) | ||||
|     serenity_install_headers(${target_name}) | ||||
|     serenity_install_sources("Libraries/${target_name}") | ||||
|     serenity_install_sources("Userland/Libraries/${target_name}") | ||||
|     #add_library(${target_name} SHARED ${SOURCES} ${GENERATED_SOURCES}) | ||||
|     add_library(${target_name} SHARED ${SOURCES} ${GENERATED_SOURCES}) | ||||
|     install(TARGETS ${target_name} DESTINATION usr/lib) | ||||
|  | @ -36,7 +36,7 @@ endfunction() | |||
| 
 | ||||
| function(serenity_shared_lib target_name fs_name) | ||||
|     serenity_install_headers(${target_name}) | ||||
|     serenity_install_sources("Libraries/${target_name}") | ||||
|     serenity_install_sources("Userland/Libraries/${target_name}") | ||||
|     add_library(${target_name} SHARED ${SOURCES} ${GENERATED_SOURCES}) | ||||
|     install(TARGETS ${target_name} DESTINATION usr/lib) | ||||
|     set_target_properties(${target_name} PROPERTIES OUTPUT_NAME ${fs_name}) | ||||
|  | @ -45,7 +45,7 @@ endfunction() | |||
| 
 | ||||
| function(serenity_libc target_name fs_name) | ||||
|     serenity_install_headers("") | ||||
|     serenity_install_sources("Libraries/LibC") | ||||
|     serenity_install_sources("Userland/Libraries/LibC") | ||||
|     set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -nostdlib -fpic") | ||||
|     add_library(${target_name} SHARED ${SOURCES}) | ||||
|     install(TARGETS ${target_name} DESTINATION usr/lib) | ||||
|  | @ -56,7 +56,7 @@ endfunction() | |||
| 
 | ||||
| function(serenity_libc_static target_name fs_name) | ||||
|     serenity_install_headers("") | ||||
|     serenity_install_sources("Libraries/LibC") | ||||
|     serenity_install_sources("Userland/Libraries/LibC") | ||||
|     add_library(${target_name} ${SOURCES}) | ||||
|     install(TARGETS ${target_name} ARCHIVE DESTINATION usr/lib) | ||||
|     set_target_properties(${target_name} PROPERTIES OUTPUT_NAME ${fs_name}) | ||||
|  |  | |||
|  | @ -40,31 +40,31 @@ elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") | |||
| endif() | ||||
| 
 | ||||
| file(GLOB AK_SOURCES CONFIGURE_DEPENDS "../../AK/*.cpp") | ||||
| file(GLOB LIBREGEX_LIBC_SOURCES "../../Libraries/LibRegex/C/Regex.cpp") | ||||
| file(GLOB LIBREGEX_SOURCES CONFIGURE_DEPENDS "../../Libraries/LibRegex/*.cpp") | ||||
| file(GLOB LIBCORE_SOURCES CONFIGURE_DEPENDS "../../Libraries/LibCore/*.cpp") | ||||
| file(GLOB LIBELF_SOURCES CONFIGURE_DEPENDS "../../Libraries/LibELF/*.cpp") | ||||
| file(GLOB LIBREGEX_LIBC_SOURCES "../../Userland/Libraries/LibRegex/C/Regex.cpp") | ||||
| file(GLOB LIBREGEX_SOURCES CONFIGURE_DEPENDS "../../Userland/Libraries/LibRegex/*.cpp") | ||||
| file(GLOB LIBCORE_SOURCES CONFIGURE_DEPENDS "../../Userland/Libraries/LibCore/*.cpp") | ||||
| file(GLOB LIBELF_SOURCES CONFIGURE_DEPENDS "../../Userland/Libraries/LibELF/*.cpp") | ||||
| # There's no way we can reliably make this cross platform | ||||
| list(REMOVE_ITEM LIBELF_SOURCES "${CMAKE_CURRENT_SOURCE_DIR}/../../Libraries/LibELF/DynamicLinker.cpp") | ||||
| list(REMOVE_ITEM LIBELF_SOURCES "${CMAKE_CURRENT_SOURCE_DIR}/../../Userland/Libraries/LibELF/DynamicLinker.cpp") | ||||
| 
 | ||||
| 
 | ||||
| file(GLOB LIBGEMINI_SOURCES CONFIGURE_DEPENDS "../../Libraries/LibGemini/*.cpp") | ||||
| file(GLOB LIBGFX_SOURCES CONFIGURE_DEPENDS "../../Libraries/LibGfx/*.cpp") | ||||
| file(GLOB LIBGUI_GML_SOURCES CONFIGURE_DEPENDS "../../Libraries/LibGUI/GML*.cpp") | ||||
| list(REMOVE_ITEM LIBGUI_GML_SOURCES ../../Libraries/LibGUI/GMLSyntaxHighlighter.cpp) | ||||
| file(GLOB LIBHTTP_SOURCES CONFIGURE_DEPENDS "../../Libraries/LibHTTP/*.cpp") | ||||
| file(GLOB LIBIPC_SOURCES CONFIGURE_DEPENDS "../../Libraries/LibIPC/*.cpp") | ||||
| file(GLOB LIBLINE_SOURCES CONFIGURE_DEPENDS "../../Libraries/LibLine/*.cpp") | ||||
| set(LIBM_SOURCES "../../Libraries/LibM/math.cpp") | ||||
| file(GLOB LIBMARKDOWN_SOURCES CONFIGURE_DEPENDS "../../Libraries/LibMarkdown/*.cpp") | ||||
| file(GLOB LIBX86_SOURCES CONFIGURE_DEPENDS "../../Libraries/LibX86/*.cpp") | ||||
| file(GLOB LIBJS_SOURCES CONFIGURE_DEPENDS "../../Libraries/LibJS/*.cpp") | ||||
| file(GLOB LIBJS_SUBDIR_SOURCES CONFIGURE_DEPENDS "../../Libraries/LibJS/*/*.cpp") | ||||
| file(GLOB LIBCOMPRESS_SOURCES CONFIGURE_DEPENDS "../../Libraries/LibCompress/*.cpp") | ||||
| file(GLOB LIBCRYPTO_SOURCES CONFIGURE_DEPENDS "../../Libraries/LibCrypto/*.cpp") | ||||
| file(GLOB LIBCRYPTO_SUBDIR_SOURCES CONFIGURE_DEPENDS "../../Libraries/LibCrypto/*/*.cpp") | ||||
| file(GLOB LIBTLS_SOURCES CONFIGURE_DEPENDS "../../Libraries/LibTLS/*.cpp") | ||||
| file(GLOB LIBTTF_SOURCES CONFIGURE_DEPENDS "../../Libraries/LibTTF/*.cpp") | ||||
| file(GLOB LIBGEMINI_SOURCES CONFIGURE_DEPENDS "../../Userland/Libraries/LibGemini/*.cpp") | ||||
| file(GLOB LIBGFX_SOURCES CONFIGURE_DEPENDS "../../Userland/Libraries/LibGfx/*.cpp") | ||||
| file(GLOB LIBGUI_GML_SOURCES CONFIGURE_DEPENDS "../../Userland/Libraries/LibGUI/GML*.cpp") | ||||
| list(REMOVE_ITEM LIBGUI_GML_SOURCES ../../Userland/Libraries/LibGUI/GMLSyntaxHighlighter.cpp) | ||||
| file(GLOB LIBHTTP_SOURCES CONFIGURE_DEPENDS "../../Userland/Libraries/LibHTTP/*.cpp") | ||||
| file(GLOB LIBIPC_SOURCES CONFIGURE_DEPENDS "../../Userland/Libraries/LibIPC/*.cpp") | ||||
| file(GLOB LIBLINE_SOURCES CONFIGURE_DEPENDS "../../Userland/Libraries/LibLine/*.cpp") | ||||
| set(LIBM_SOURCES "../../Userland/Libraries/LibM/math.cpp") | ||||
| file(GLOB LIBMARKDOWN_SOURCES CONFIGURE_DEPENDS "../../Userland/Libraries/LibMarkdown/*.cpp") | ||||
| file(GLOB LIBX86_SOURCES CONFIGURE_DEPENDS "../../Userland/Libraries/LibX86/*.cpp") | ||||
| file(GLOB LIBJS_SOURCES CONFIGURE_DEPENDS "../../Userland/Libraries/LibJS/*.cpp") | ||||
| file(GLOB LIBJS_SUBDIR_SOURCES CONFIGURE_DEPENDS "../../Userland/Libraries/LibJS/*/*.cpp") | ||||
| file(GLOB LIBCOMPRESS_SOURCES CONFIGURE_DEPENDS "../../Userland/Libraries/LibCompress/*.cpp") | ||||
| file(GLOB LIBCRYPTO_SOURCES CONFIGURE_DEPENDS "../../Userland/Libraries/LibCrypto/*.cpp") | ||||
| file(GLOB LIBCRYPTO_SUBDIR_SOURCES CONFIGURE_DEPENDS "../../Userland/Libraries/LibCrypto/*/*.cpp") | ||||
| file(GLOB LIBTLS_SOURCES CONFIGURE_DEPENDS "../../Userland/Libraries/LibTLS/*.cpp") | ||||
| file(GLOB LIBTTF_SOURCES CONFIGURE_DEPENDS "../../Userland/Libraries/LibTTF/*.cpp") | ||||
| file(GLOB SHELL_SOURCES CONFIGURE_DEPENDS "../../Userland/Shell/*.cpp") | ||||
| file(GLOB SHELL_TESTS CONFIGURE_DEPENDS "../../Userland/Shell/Tests/*.sh") | ||||
| list(REMOVE_ITEM SHELL_SOURCES ../../Userland/Shell/main.cpp) | ||||
|  | @ -74,7 +74,7 @@ set(LAGOM_CORE_SOURCES ${AK_SOURCES} ${LIBCORE_SOURCES}) | |||
| set(LAGOM_MORE_SOURCES ${LIBELF_SOURCES} ${LIBIPC_SOURCES} ${LIBLINE_SOURCES} ${LIBJS_SOURCES} ${LIBJS_SUBDIR_SOURCES} ${LIBX86_SOURCES} ${LIBCRYPTO_SOURCES} ${LIBCOMPRESS_SOURCES} ${LIBCRYPTO_SUBDIR_SOURCES} ${LIBTLS_SOURCES} ${LIBTTF_SOURCES} ${LIBMARKDOWN_SOURCES} ${LIBGEMINI_SOURCES} ${LIBGFX_SOURCES} ${LIBGUI_GML_SOURCES} ${LIBHTTP_SOURCES} ${LAGOM_REGEX_SOURCES} ${SHELL_SOURCES}) | ||||
| 
 | ||||
| include_directories (../../) | ||||
| include_directories (../../Libraries/) | ||||
| include_directories (../../Userland/Libraries/) | ||||
| add_library(LagomCore ${LAGOM_CORE_SOURCES}) | ||||
| 
 | ||||
| 
 | ||||
|  |  | |||
|  | @ -91,7 +91,7 @@ $ gdb ./Meta/Lagom/Fuzzers/FuzzBMP | |||
| <... SNIP some output ...> | ||||
| (gdb) run -handle_abrt=0 -handle_segv=0 crash-27480a219572aa5a11b285968a3632a4cf25388e | ||||
| <... SNIP some output ...> | ||||
| FuzzBMP: ../../Libraries/LibGfx/Bitmap.cpp:84: Gfx::Bitmap::Bitmap(Gfx::BitmapFormat, const Gfx::IntSize &, Gfx::Bitmap::Purgeable): Assertion `m_data && m_data != (void*)-1' failed. | ||||
| FuzzBMP: ../../Userland/Libraries/LibGfx/Bitmap.cpp:84: Gfx::Bitmap::Bitmap(Gfx::BitmapFormat, const Gfx::IntSize &, Gfx::Bitmap::Purgeable): Assertion `m_data && m_data != (void*)-1' failed. | ||||
| 
 | ||||
| Thread 1 "FuzzBMP" received signal SIGABRT, Aborted. | ||||
| __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50 | ||||
|  |  | |||
|  | @ -96,8 +96,8 @@ mkdir -p mnt/home/anon/Desktop | |||
| mkdir -p mnt/home/anon/Downloads | ||||
| mkdir -p mnt/home/nona | ||||
| cp "$SERENITY_ROOT"/ReadMe.md mnt/home/anon/ | ||||
| cp -r "$SERENITY_ROOT"/Libraries/LibJS/Tests mnt/home/anon/js-tests | ||||
| cp -r "$SERENITY_ROOT"/Libraries/LibWeb/Tests mnt/home/anon/web-tests | ||||
| cp -r "$SERENITY_ROOT"/Userland/Libraries/LibJS/Tests mnt/home/anon/js-tests | ||||
| cp -r "$SERENITY_ROOT"/Userland/Libraries/LibWeb/Tests mnt/home/anon/web-tests | ||||
| chmod 700 mnt/root | ||||
| chmod 700 mnt/home/anon | ||||
| chmod 700 mnt/home/nona | ||||
|  |  | |||
|  | @ -20,7 +20,7 @@ done < <( | |||
|         '*.cpp' \ | ||||
|         '*.h' \ | ||||
|         ':!:Kernel/FileSystem/ext2_fs.h' \ | ||||
|         ':!:Libraries/LibELF/exec_elf.h' \ | ||||
|         ':!:Userland/Libraries/LibELF/exec_elf.h' \ | ||||
|     | xargs grep -P '^ *#.*DEBUG' \ | ||||
|     | sed -re 's,^.*[^a-zA-Z0-9_]([a-zA-Z0-9_]*DEBUG[a-zA-Z0-9_]*).*$,\1,' \ | ||||
|     | sort \ | ||||
|  |  | |||
|  | @ -21,10 +21,10 @@ files = subprocess.run( | |||
|         "**/CMake*.txt", | ||||
|         ":!:Base", | ||||
|         ":!:Kernel/FileSystem/ext2_fs.h", | ||||
|         ":!:Libraries/LibC/getopt.cpp", | ||||
|         ":!:Libraries/LibCore/puff.h", | ||||
|         ":!:Libraries/LibCore/puff.cpp", | ||||
|         ":!:Libraries/LibELF/exec_elf.h" | ||||
|         ":!:Userland/Libraries/LibC/getopt.cpp", | ||||
|         ":!:Userland/Libraries/LibCore/puff.h", | ||||
|         ":!:Userland/Libraries/LibCore/puff.cpp", | ||||
|         ":!:Userland/Libraries/LibELF/exec_elf.h" | ||||
|     ], | ||||
|     capture_output=True | ||||
| ).stdout.decode().strip('\n').split('\n') | ||||
|  |  | |||
|  | @ -41,10 +41,10 @@ done < <(git ls-files -- \ | |||
|     '*.h' \ | ||||
|     ':!:Base' \ | ||||
|     ':!:Kernel/FileSystem/ext2_fs.h' \ | ||||
|     ':!:Libraries/LibC/getopt.cpp' \ | ||||
|     ':!:Libraries/LibCore/puff.h' \ | ||||
|     ':!:Libraries/LibCore/puff.cpp' \ | ||||
|     ':!:Libraries/LibELF/exec_elf.h' \ | ||||
|     ':!:Userland/Libraries/LibC/getopt.cpp' \ | ||||
|     ':!:Userland/Libraries/LibCore/puff.h' \ | ||||
|     ':!:Userland/Libraries/LibCore/puff.cpp' \ | ||||
|     ':!:Userland/Libraries/LibELF/exec_elf.h' \ | ||||
| ) | ||||
| 
 | ||||
| exit_status=0 | ||||
|  |  | |||
|  | @ -9,7 +9,7 @@ cd "$script_path/.." || exit 1 | |||
| # To eliminate the need for these symbols, avoid doing non-trivial construction of local statics in LibC. | ||||
| 
 | ||||
| FORBIDDEN_SYMBOLS="__cxa_guard_acquire __cxa_guard_release" | ||||
| LIBC_PATH="Build/Libraries/LibC/libc.a"  | ||||
| LIBC_PATH="Build/Userland/Libraries/LibC/libc.a"  | ||||
| for forbidden_symbol in $FORBIDDEN_SYMBOLS; do | ||||
|     # check if symbol is undefined | ||||
|     if nm $LIBC_PATH | grep "U $forbidden_symbol" ; then | ||||
|  |  | |||
|  | @ -13,11 +13,11 @@ if [ "$#" -eq "1" ]; then | |||
|             ':!:Base' \ | ||||
|             ':!:Kernel/Arch/i386/CPU.cpp' \ | ||||
|             ':!:Kernel/FileSystem/ext2_fs.h' \ | ||||
|             ':!:Libraries/LibC/getopt.cpp' \ | ||||
|             ':!:Libraries/LibC/syslog.h' \ | ||||
|             ':!:Libraries/LibCore/puff.h' \ | ||||
|             ':!:Libraries/LibCore/puff.cpp' \ | ||||
|             ':!:Libraries/LibELF/exec_elf.h' | ||||
|             ':!:Userland/Libraries/LibC/getopt.cpp' \ | ||||
|             ':!:Userland/Libraries/LibC/syslog.h' \ | ||||
|             ':!:Userland/Libraries/LibCore/puff.h' \ | ||||
|             ':!:Userland/Libraries/LibCore/puff.cpp' \ | ||||
|             ':!:Userland/Libraries/LibELF/exec_elf.h' | ||||
|     ) | ||||
| else | ||||
|     files=() | ||||
|  |  | |||
|  | @ -7,7 +7,7 @@ cd "$script_path/.." | |||
| 
 | ||||
| # The dollar symbol in sed's argument is for "end of line", not any shell variable. | ||||
| # shellcheck disable=SC2016 | ||||
| grep -Pirh '(?<!file://)(?<!\.)(?<!})(?<!\()/(etc|res|usr|www)/' AK/ Applications/ Base Demos/ DevTools/ Documentation/ Games/ Kernel/ Libraries/ MenuApplets/ Services/ Userland/ | \ | ||||
| grep -Pirh '(?<!file://)(?<!\.)(?<!})(?<!\()/(etc|res|usr|www)/' AK/ Base DevTools/ Documentation/ Kernel/ Services/ Userland/ | \ | ||||
| sed -re 's,^.*["= `]/([^"%`: ]+[^"%`: /.])/?(["%`: .].*)?$,\1,' | \ | ||||
| sort -u | \ | ||||
| while read -r referenced_resource | ||||
|  |  | |||
|  | @ -237,9 +237,9 @@ pushd "$DIR/Build/$ARCH" | |||
|         pushd "$BUILD" | ||||
|             mkdir -p Root/usr/include/ | ||||
|             SRC_ROOT=$(realpath "$DIR"/..) | ||||
|             FILES=$(find "$SRC_ROOT"/Libraries/LibC "$SRC_ROOT"/Libraries/LibM -name '*.h' -print) | ||||
|             FILES=$(find "$SRC_ROOT"/Userland/Libraries/LibC "$SRC_ROOT"/Userland/Libraries/LibM -name '*.h' -print) | ||||
|             for header in $FILES; do | ||||
|                 target=$(echo "$header" | sed -e "s@$SRC_ROOT/Libraries/LibC@@" -e "s@$SRC_ROOT/Libraries/LibM@@") | ||||
|                 target=$(echo "$header" | sed -e "s@$SRC_ROOT/Userland/Libraries/LibC@@" -e "s@$SRC_ROOT/Userland/Libraries/LibM@@") | ||||
|                 $INSTALL -D "$header" "Root/usr/include/$target" | ||||
|             done | ||||
|             unset SRC_ROOT | ||||
|  |  | |||
|  | @ -2,6 +2,7 @@ add_subdirectory(Applications) | |||
| add_subdirectory(Demos) | ||||
| add_subdirectory(DynamicLoader) | ||||
| add_subdirectory(Games) | ||||
| add_subdirectory(Libraries) | ||||
| add_subdirectory(MenuApplets) | ||||
| add_subdirectory(Shell) | ||||
| add_subdirectory(Tests) | ||||
|  |  | |||
|  | @ -5,11 +5,11 @@ set(LOADER_SOURCES | |||
| ) | ||||
| 
 | ||||
| file(GLOB AK_SOURCES "../../AK/*.cpp") | ||||
| file(GLOB ELF_SOURCES "../../Libraries/LibELF/*.cpp") | ||||
| set(ELF_SOURCES ${ELF_SOURCES} ../../Libraries/LibELF/Arch/i386/plt_trampoline.S) | ||||
| file(GLOB LIBC_SOURCES1 "../../Libraries/LibC/*.cpp") | ||||
| file(GLOB LIBC_SOURCES2 "../../Libraries/LibC/*/*.cpp") | ||||
| file(GLOB LIBC_SOURCES3 "../../Libraries/LibC/*.S") | ||||
| file(GLOB ELF_SOURCES "../Libraries/LibELF/*.cpp") | ||||
| set(ELF_SOURCES ${ELF_SOURCES} ../Libraries/LibELF/Arch/i386/plt_trampoline.S) | ||||
| file(GLOB LIBC_SOURCES1 "../Libraries/LibC/*.cpp") | ||||
| file(GLOB LIBC_SOURCES2 "../Libraries/LibC/*/*.cpp") | ||||
| file(GLOB LIBC_SOURCES3 "../Libraries/LibC/*.S") | ||||
| 
 | ||||
| list(FILTER LIBC_SOURCES1 EXCLUDE REGEX ".+crt0.cpp") | ||||
| list(FILTER LIBC_SOURCES1 EXCLUDE REGEX ".+crt0.+.cpp") | ||||
|  | @ -18,7 +18,7 @@ set(SOURCES ${LOADER_SOURCES} ${AK_SOURCES} ${ELF_SOURCES} ${LIBC_SOURCES1} ${LI | |||
| 
 | ||||
| set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fno-rtti -nostdlib -pie -fpic -DNO_TLS") | ||||
| 
 | ||||
| set_source_files_properties (../../Libraries/LibC/ssp.cpp PROPERTIES COMPILE_FLAGS | ||||
| set_source_files_properties (../Libraries/LibC/ssp.cpp PROPERTIES COMPILE_FLAGS | ||||
|     "-fno-stack-protector") | ||||
| 
 | ||||
| add_executable(Loader.so ${SOURCES}) | ||||
|  |  | |||
|  | @ -48,7 +48,7 @@ set(LIBC_SOURCES | |||
|     wchar.cpp | ||||
| ) | ||||
| 
 | ||||
| file(GLOB AK_SOURCES CONFIGURE_DEPENDS "../../AK/*.cpp") | ||||
| file(GLOB AK_SOURCES CONFIGURE_DEPENDS "../../../AK/*.cpp") | ||||
| file(GLOB ELF_SOURCES CONFIGURE_DEPENDS "../LibELF/*.cpp") | ||||
| set(ELF_SOURCES ${ELF_SOURCES} ../LibELF/Arch/i386/plt_trampoline.S) | ||||
| 
 | ||||
Some files were not shown because too many files have changed in this diff Show more
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Andreas Kling
						Andreas Kling