build: Reduce debug info produced (#1720)
This commit is contained in:
parent
0b0bf90e0b
commit
92b1234ddb
7
.github/workflows/build.yml
vendored
7
.github/workflows/build.yml
vendored
@ -384,6 +384,11 @@ jobs:
|
||||
apt update
|
||||
bash dist/get_deps_debian.sh
|
||||
|
||||
apt install software-properties-common -y
|
||||
add-apt-repository ppa:ubuntu-toolchain-r/test -y
|
||||
apt update
|
||||
apt install -y gcc-13 g++-13
|
||||
|
||||
- name: ⬇️ Install .NET
|
||||
uses: actions/setup-dotnet@v4
|
||||
with:
|
||||
@ -397,7 +402,7 @@ jobs:
|
||||
git config --global --add safe.directory '*'
|
||||
mkdir -p build
|
||||
cd build
|
||||
CC=gcc-12 CXX=g++-12 cmake -G "Ninja" \
|
||||
CC=gcc-13 CXX=g++-13 cmake -G "Ninja" \
|
||||
-DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} \
|
||||
-DCMAKE_INSTALL_PREFIX="/usr" \
|
||||
-DCMAKE_C_COMPILER_LAUNCHER=ccache \
|
||||
|
@ -600,6 +600,15 @@ macro(setupCompilerFlags target)
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${IMHEX_COMMON_FLAGS} ${IMHEX_C_CXX_FLAGS}")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${IMHEX_COMMON_FLAGS} ${IMHEX_C_CXX_FLAGS} ${IMHEX_CXX_FLAGS}")
|
||||
set(CMAKE_OBJC_FLAGS "${CMAKE_OBJC_FLAGS} ${IMHEX_COMMON_FLAGS}")
|
||||
|
||||
# Only generate minimal debug information for stacktraces in RelWithDebInfo builds
|
||||
set(CMAKE_C_FLAGS_RELWITHDEBINFO "${CMAKE_C_FLAGS_RELWITHDEBINFO} -g1")
|
||||
set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "${CMAKE_CXX_FLAGS_RELWITHDEBINFO} -g1")
|
||||
if (CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
|
||||
# Add flags for debug info in inline functions
|
||||
set(CMAKE_C_FLAGS_RELWITHDEBINFO "${CMAKE_C_FLAGS_RELWITHDEBINFO} -gstatement-frontiers -ginline-points")
|
||||
set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "${CMAKE_CXX_FLAGS_RELWITHDEBINFO} -gstatement-frontiers -ginline-points")
|
||||
endif()
|
||||
endmacro()
|
||||
|
||||
# uninstall target
|
||||
|
2
lib/external/pattern_language
vendored
2
lib/external/pattern_language
vendored
@ -1 +1 @@
|
||||
Subproject commit 5d247e431935a1b67e5319526ff37a93847a6a8a
|
||||
Subproject commit f83b855b9778327cb0ac72996b73ae990966ec1c
|
@ -30,6 +30,7 @@ add_executable(main ${APPLICATION_TYPE}
|
||||
|
||||
target_include_directories(main PUBLIC include)
|
||||
setupCompilerFlags(main)
|
||||
setupCompilerFlags(libimhex)
|
||||
|
||||
set(LIBROMFS_RESOURCE_LOCATION ${CMAKE_CURRENT_SOURCE_DIR}/romfs)
|
||||
set(LIBROMFS_PROJECT_NAME imhex)
|
||||
|
Loading…
Reference in New Issue
Block a user