authorgravatar for bratishkaerik@getgoogleoff.meEric Joldasov <bratishkaerik@getgoogleoff.me> 2023-05-14 22:59:30+06:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2023-05-14 23:02:01-07:00
log6f3dacc1073c30d10f640fe630580a4866cbd9db
treebc1602327e86cb4f58b66659ce1a3b94c8cab810
parent2516d8671faaaff7e8803a2025ba4891a6ae7c78

CMakeLists.txt and build.zig: remove deprecated options

Signed-off-by: Eric Joldasov <bratishkaerik@getgoogleoff.me>

2 files changed, 1 insertions(+), 26 deletions(-)

CMakeLists.txt-15
...@@ -84,12 +84,6 @@ set(ZIG_NO_LIB off CACHE BOOL...@@ -84,12 +84,6 @@ set(ZIG_NO_LIB off CACHE BOOL
84set(ZIG_NO_LANGREF off CACHE BOOL84set(ZIG_NO_LANGREF off CACHE BOOL
85 "Disable copying of langref to the install prefix during the build phase")85 "Disable copying of langref to the install prefix during the build phase")
8686
87set(ZIG_SKIP_INSTALL_LIB_FILES off CACHE BOOL "Deprecated. Use ZIG_NO_LIB")
88if(ZIG_SKIP_INSTALL_LIB_FILES)
89 message(WARNING "ZIG_SKIP_INSTALL_LIB_FILES is deprecated. Use ZIG_NO_LIB instead.")
90 set(ZIG_NO_LIB ON)
91endif()
92
93set(ZIG_STATIC off CACHE BOOL "Attempt to build a static zig executable (not compatible with glibc)")87set(ZIG_STATIC off CACHE BOOL "Attempt to build a static zig executable (not compatible with glibc)")
94set(ZIG_SHARED_LLVM off CACHE BOOL "Prefer linking against shared LLVM libraries")88set(ZIG_SHARED_LLVM off CACHE BOOL "Prefer linking against shared LLVM libraries")
95set(ZIG_STATIC_LLVM ${ZIG_STATIC} CACHE BOOL "Prefer linking against static LLVM libraries")89set(ZIG_STATIC_LLVM ${ZIG_STATIC} CACHE BOOL "Prefer linking against static LLVM libraries")
...@@ -110,10 +104,6 @@ if (ZIG_SHARED_LLVM AND ZIG_STATIC_LLVM)...@@ -110,10 +104,6 @@ if (ZIG_SHARED_LLVM AND ZIG_STATIC_LLVM)
110 message(SEND_ERROR "-DZIG_SHARED_LLVM and -DZIG_STATIC_LLVM cannot both be enabled simultaneously")104 message(SEND_ERROR "-DZIG_SHARED_LLVM and -DZIG_STATIC_LLVM cannot both be enabled simultaneously")
111endif()105endif()
112106
113string(REGEX REPLACE "\\\\" "\\\\\\\\" ZIG_LIBC_LIB_DIR_ESCAPED "${ZIG_LIBC_LIB_DIR}")
114string(REGEX REPLACE "\\\\" "\\\\\\\\" ZIG_LIBC_STATIC_LIB_DIR_ESCAPED "${ZIG_LIBC_STATIC_LIB_DIR}")
115string(REGEX REPLACE "\\\\" "\\\\\\\\" ZIG_LIBC_INCLUDE_DIR_ESCAPED "${ZIG_LIBC_INCLUDE_DIR}")
116
117set(ZIG_TARGET_TRIPLE "native" CACHE STRING "arch-os-abi to output binaries for")107set(ZIG_TARGET_TRIPLE "native" CACHE STRING "arch-os-abi to output binaries for")
118set(ZIG_TARGET_MCPU "native" CACHE STRING "-mcpu parameter to output binaries for")108set(ZIG_TARGET_MCPU "native" CACHE STRING "-mcpu parameter to output binaries for")
119set(ZIG_SINGLE_THREADED off CACHE BOOL "limit the zig compiler to use only 1 thread")109set(ZIG_SINGLE_THREADED off CACHE BOOL "limit the zig compiler to use only 1 thread")
...@@ -185,11 +175,6 @@ include_directories(${CLANG_INCLUDE_DIRS})...@@ -185,11 +175,6 @@ include_directories(${CLANG_INCLUDE_DIRS})
185find_package(Threads)175find_package(Threads)
186176
187set(ZIG_LIB_DIR "lib/zig")177set(ZIG_LIB_DIR "lib/zig")
188set(C_HEADERS_DEST "${ZIG_LIB_DIR}/include")
189set(LIBC_FILES_DEST "${ZIG_LIB_DIR}/libc")
190set(LIBUNWIND_FILES_DEST "${ZIG_LIB_DIR}/libunwind")
191set(LIBCXX_FILES_DEST "${ZIG_LIB_DIR}/libcxx")
192set(ZIG_STD_DEST "${ZIG_LIB_DIR}/std")
193set(ZIG_CONFIG_H_OUT "${CMAKE_BINARY_DIR}/config.h")178set(ZIG_CONFIG_H_OUT "${CMAKE_BINARY_DIR}/config.h")
194set(ZIG_CONFIG_ZIG_OUT "${CMAKE_BINARY_DIR}/config.zig")179set(ZIG_CONFIG_ZIG_OUT "${CMAKE_BINARY_DIR}/config.zig")
195180
build.zig+1-11
...@@ -28,11 +28,7 @@ pub fn build(b: *std.Build) !void {...@@ -28,11 +28,7 @@ pub fn build(b: *std.Build) !void {
28 const use_zig_libcxx = b.option(bool, "use-zig-libcxx", "If libc++ is needed, use zig's bundled version, don't try to integrate with the system") orelse false;28 const use_zig_libcxx = b.option(bool, "use-zig-libcxx", "If libc++ is needed, use zig's bundled version, don't try to integrate with the system") orelse false;
2929
30 const test_step = b.step("test", "Run all the tests");30 const test_step = b.step("test", "Run all the tests");
31 const deprecated_skip_install_lib_files = b.option(bool, "skip-install-lib-files", "deprecated. see no-lib") orelse false;31 const skip_install_lib_files = b.option(bool, "no-lib", "skip copying of lib/ files and langref to installation prefix. Useful for development") orelse false;
32 if (deprecated_skip_install_lib_files) {
33 std.log.warn("-Dskip-install-lib-files is deprecated in favor of -Dno-lib", .{});
34 }
35 const skip_install_lib_files = b.option(bool, "no-lib", "skip copying of lib/ files and langref to installation prefix. Useful for development") orelse deprecated_skip_install_lib_files;
36 const skip_install_langref = b.option(bool, "no-langref", "skip copying of langref to the installation prefix") orelse skip_install_lib_files;32 const skip_install_langref = b.option(bool, "no-langref", "skip copying of langref to the installation prefix") orelse skip_install_lib_files;
3733
38 const docgen_exe = b.addExecutable(.{34 const docgen_exe = b.addExecutable(.{
...@@ -58,12 +54,6 @@ pub fn build(b: *std.Build) !void {...@@ -58,12 +54,6 @@ pub fn build(b: *std.Build) !void {
58 const docs_step = b.step("docs", "Build documentation");54 const docs_step = b.step("docs", "Build documentation");
59 docs_step.dependOn(&docgen_cmd.step);55 docs_step.dependOn(&docgen_cmd.step);
6056
61 // This is for legacy reasons, to be removed after our CI scripts are upgraded to use
62 // the file from the install prefix instead.
63 const legacy_write_to_cache = b.addWriteFiles();
64 legacy_write_to_cache.addCopyFileToSource(langref_file, "zig-cache/langref.html");
65 docs_step.dependOn(&legacy_write_to_cache.step);
66
67 const check_case_exe = b.addExecutable(.{57 const check_case_exe = b.addExecutable(.{
68 .name = "check-case",58 .name = "check-case",
69 .root_source_file = .{ .path = "test/src/Cases.zig" },59 .root_source_file = .{ .path = "test/src/Cases.zig" },