Skip to content

Commit

Permalink
Update build settings
Browse files Browse the repository at this point in the history
  • Loading branch information
bubio committed Oct 23, 2023
1 parent 89f7d3c commit ec45447
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 21 deletions.
4 changes: 2 additions & 2 deletions Builder/Linux/dist_app.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,15 @@ cmake --build build -j 2 --target package
if [ -f build/xm8*.rpm ]; then
mv build/xm8*.rpm build/xm8_linux_x86_64.rpm

read -p "Do you want to install the package? (y/N): " yn
read -p "Do you want to install the rpm package? (y/N): " yn
case "$yn" in [yY]*) ;; *) echo "abort." ; exit ;; esac
sudo dnf install ./build/xm8_linux_x86_64.rpm
fi

if [ -f build/xm8*.deb ]; then
mv build/xm8*.deb build/xm8_linux_x86_64.deb

read -p "Do you want to install the package? (y/N): " yn
read -p "Do you want to install the deb package? (y/N): " yn
case "$yn" in [yY]*) ;; *) echo "abort." ; exit ;; esac
sudo apt install ./build/xm8_linux_x86_64.deb
fi
Expand Down
30 changes: 11 additions & 19 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -48,12 +48,10 @@ if(CCACHE_PROGRAM)
set(CMAKE_CXX_COMPILER_LAUNCHER "${CCACHE_PROGRAM}")
endif()

# Despite setting C++ standard to 20, features from this version are not being used.
# The oldest compiler used is GCC 6.5 - and that defines our C++ feature set (meaning most of C++17).
# It's present only to take advantage of fmt::format build time errors.
# set(CMAKE_CXX_STANDARD 20)
# set(CMAKE_CXX_EXTENSIONS OFF)
# set(CMAKE_CXX_STANDARD_REQUIRED OFF)
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_C_STANDARD 17)
set(CMAKE_CXX_EXTENSIONS OFF)
set(CMAKE_CXX_STANDARD_REQUIRED OFF)
# set(CMAKE_EXPORT_COMPILE_COMMANDS ON) # for clang-tidy
# set(CMAKE_THREAD_PREFER_PTHREAD ON)
# set(THREADS_PREFER_PTHREAD_FLAG ON)
Expand All @@ -62,7 +60,6 @@ endif()

# Find SDL2 library and add to linker flags
if(NOT APPLE)
# find_package(SDL2 2.24.2 EXACT REQUIRED)
find_package(SDL2 REQUIRED)
else()
# Dependencies must be included after Platforms.
Expand All @@ -78,18 +75,13 @@ add_definitions(-D_PC8801MA)

# Set compile options
add_compile_options(-Wall)
if(APPLE)
add_compile_options(
-Wno-macro-redefined
-Wno-non-c-typedef-for-linkage
-Wno-deprecated-declarations
-Wno-overloaded-virtual
-Wno-c++11-compat-deprecated-writable-strings)
else()
add_compile_options(-Wno-narrowing)
endif()
add_compile_options(-Wno-c++11-extensions)

add_compile_options(
-Wno-macro-redefined
-Wno-non-c-typedef-for-linkage
-Wno-deprecated-declarations
-Wno-overloaded-virtual
-Wno-c++11-compat-deprecated-writable-strings
-Wno-narrowing)

# Include directories
include_directories(
Expand Down
1 change: 1 addition & 0 deletions Source/Filter/xBRZ/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
cmake_minimum_required(VERSION 3.10)

set(CMAKE_CXX_STANDARD 17)
set(CMAKE_C_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED OFF)
set(CMAKE_OSX_DEPLOYMENT_TARGET "10.13.0")
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
Expand Down

0 comments on commit ec45447

Please sign in to comment.