Skip to content

Instantly share code, notes, and snippets.

View k0mp1ex's full-sized avatar
🏠
Working from home

k0mp1ex

🏠
Working from home
View GitHub Profile
@k0mp1ex
k0mp1ex / CMakeLists.txt
Created February 21, 2023 00:38
Build console applications with CMake
cmake_minimum_required(VERSION 3.24)
project(IAmAConsoleApp VERSION 0.0.1 LANGUAGES CXX)
add_executable(${PROJECT_NAME} src/main.cpp)
target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_23)
target_link_options(${PROJECT_NAME} PRIVATE "/SUBSYSTEM:WINDOWS" "/ENTRY:mainCRTStartup")
@k0mp1ex
k0mp1ex / CMakeLists.txt
Created February 21, 2023 00:35
Build executable with CMake that requires administrator access to run it
cmake_minimum_required(VERSION 3.24)
project(INeedAdmin VERSION 1.0.0)
set(CMAKE_CXX_STANDARD 23)
add_executable(${PROJECT_NAME} main.cpp)
set_target_properties(${PROJECT_NAME} PROPERTIES LINK_FLAGS " /MANIFESTUAC:\"level='requireAdministrator' uiAccess='false'\" ")
@k0mp1ex
k0mp1ex / AE-build.bat
Created September 18, 2022 01:20
Build SKSE with Debug config for Skyrim 1.5.67 and Skyrim 1.6.xxx
set Skyrim64Path=C:\Development\MO2\Portable\mods\SKSE64 - AE - Debug\Root
git clone https://github.com/ianpatt/common AE/common
git clone https://github.com/ianpatt/skse64 AE/skse64
cd AE
cmake -B common/build -S common -DCMAKE_INSTALL_PREFIX=extern common
cmake --build common/build --config Debug --target install
cmake -B skse64/build -S skse64 -DCMAKE_INSTALL_PREFIX=extern -DSKSE_COPY_OUTPUT=ON
cmake --build skse64/build --config Debug
cd ..
pause