diff options
Diffstat (limited to 'src/configure.cc')
-rw-r--r-- | src/configure.cc | 39 |
1 files changed, 0 insertions, 39 deletions
diff --git a/src/configure.cc b/src/configure.cc index bb94202..8348c19 100644 --- a/src/configure.cc +++ b/src/configure.cc @@ -51,40 +51,6 @@ const Configuration& defConfiguration() #endif -#ifdef _WIN32 -#define WIN32_LEAN_AND_MEAN -#include <windows.h> -#endif - -void _copyAndRelaunch(int argc, char* argv[], - const std::string& copy_src, - const std::string& copy_tar, - const std::string& compilation_name) -{ -#ifdef _WIN32 - CopyFile(copy_src.data(), copy_tar.data(), false); - SetFileAttributes(copy_tar.data(), FILE_ATTRIBUTE_HIDDEN); - auto t = std::filesystem::last_write_time(copy_src); - std::filesystem::last_write_time(copy_tar, t); - - STARTUPINFO si{}; - PROCESS_INFORMATION pi{}; - si.cb = sizeof(pi); - - std::string args = copy_tar + " configure"; - for(int i = 1; i < argc; ++i) - { - args += " "; - args += argv[i]; - } - args += " --name "; - args += compilation_name; - - CreateProcess(nullptr, args.data(), 0,0,0,0,0,0,&si,&pi); - exit(1); -#endif // _WIN32 -} - namespace ctor { std::optional<std::string> includedir; @@ -428,11 +394,6 @@ int regenerateCache(Settings& settings, argv0_file = std::filesystem::current_path() / argv0_file; } - if(settings_file.string() == argv0_file.string()) - { - _copyAndRelaunch(vargs.size(), vargs.data(), vargs[0], "ctor-configure-tmp.exe", settings.name); - exit(0); - } if(host_arch.empty()) { |