reorganize folders/build system

This commit is contained in:
Akash Mozumdar 2019-01-11 16:20:57 -05:00
parent d8429851cb
commit 8e80543e2e
4 changed files with 14 additions and 9 deletions

5
.gitignore vendored
View File

@ -1,5 +1,6 @@
Build/ /Textractor*
Builds/ /build/
/builds/
*.vs/ *.vs/
*.vscode/ *.vscode/
*.user *.user

View File

@ -1,6 +1,6 @@
cmake_minimum_required(VERSION 3.5) cmake_minimum_required(VERSION 3.5)
set(MODULE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/cmake") set(MODULE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/cmake)
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${MODULE_DIR}) set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${MODULE_DIR})
project(Textractor) project(Textractor)
@ -15,10 +15,10 @@ add_compile_options(
include_directories(include) include_directories(include)
if(${CMAKE_SIZEOF_VOID_P} STREQUAL "8") if(${CMAKE_SIZEOF_VOID_P} EQUAL 8)
set(CMAKE_FINAL_OUTPUT_DIRECTORY ${CMAKE_SOURCE_DIR}/Builds/${CMAKE_BUILD_TYPE}_x64) set(CMAKE_FINAL_OUTPUT_DIRECTORY ${CMAKE_SOURCE_DIR}/builds/${CMAKE_BUILD_TYPE}_x64)
else() else()
set(CMAKE_FINAL_OUTPUT_DIRECTORY ${CMAKE_SOURCE_DIR}/Builds/${CMAKE_BUILD_TYPE}_x86) set(CMAKE_FINAL_OUTPUT_DIRECTORY ${CMAKE_SOURCE_DIR}/builds/${CMAKE_BUILD_TYPE}_x86)
endif() endif()
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_FINAL_OUTPUT_DIRECTORY}) set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_FINAL_OUTPUT_DIRECTORY})
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_FINAL_OUTPUT_DIRECTORY}) set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_FINAL_OUTPUT_DIRECTORY})
@ -26,6 +26,9 @@ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_FINAL_OUTPUT_DIRECTORY})
set(CMAKE_CONFIGURATION_TYPES Debug Release) set(CMAKE_CONFIGURATION_TYPES Debug Release)
file(GLOB MISC_FILES "release/*.dll")
file(COPY ${MISC_FILES} DESTINATION ${CMAKE_FINAL_OUTPUT_DIRECTORY})
add_subdirectory(GUI) add_subdirectory(GUI)
add_subdirectory(vnrhook) add_subdirectory(vnrhook)
add_subdirectory(extensions) add_subdirectory(extensions)

View File

@ -1,4 +1,4 @@
Set-Location "$($PSScriptRoot)/Builds"; Set-Location $PSScriptRoot;
foreach ($arch in @("86", "64")) { foreach ($arch in @("86", "64")) {
$folder = "Textractor$($arch)"; $folder = "Textractor$($arch)";
@ -14,12 +14,12 @@ foreach ($arch in @("86", "64")) {
"Google Translate.dll", "Google Translate.dll",
"Regex Filter.dll", "Regex Filter.dll",
"Remove Repetition.dll", "Remove Repetition.dll",
"Extensions.txt",
"platforms", "platforms",
"styles" "styles"
) | ForEach-Object { "RelWithDebInfo_x$($arch)/$($_)" }; ) | ForEach-Object { "builds/RelWithDebInfo_x$($arch)/$($_)" };
mkdir -Force -Verbose $folder; mkdir -Force -Verbose $folder;
Remove-Item -Force -Recurse -Verbose "$($folder)/*"; Remove-Item -Force -Recurse -Verbose "$($folder)/*";
Copy-Item -Force -Recurse -Verbose -Destination $folder -Path $targets; Copy-Item -Force -Recurse -Verbose -Destination $folder -Path $targets;
Copy-Item -Force -Recurse -Verbose -Destination $folder -Path "release/*";
Compress-Archive -Force -Verbose -DestinationPath $folder -Path $folder; Compress-Archive -Force -Verbose -DestinationPath $folder -Path $folder;
} }

1
release/Extensions.txt Normal file
View File

@ -0,0 +1 @@
Remove Repetition>Copy to Clipboard>Google Translate>Extra Newlines>