Skip to content

Commit

Permalink
fix: set proper runpath on linux for all executables
Browse files Browse the repository at this point in the history
  • Loading branch information
craftablescience committed Jun 14, 2024
1 parent 4dadfdf commit 3bc4c24
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
5 changes: 5 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,11 @@ option(VPKEDIT_USE_LTO "Build VPKEdit with link-time optimization enabled" OFF)

# Global CMake options
if(PROJECT_IS_TOP_LEVEL)
# Set proper runpath
set(CMAKE_SKIP_BUILD_RPATH OFF)
set(CMAKE_BUILD_RPATH_USE_ORIGIN ON)
set(CMAKE_INSTALL_RPATH $ORIGIN)

# Compile with PIC
set(CMAKE_POSITION_INDEPENDENT_CODE ON)

Expand Down
4 changes: 0 additions & 4 deletions src/gui/_gui.cmake
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
set(CMAKE_SKIP_BUILD_RPATH FALSE)
set(CMAKE_BUILD_RPATH_USE_ORIGIN TRUE)
set(CMAKE_INSTALL_RPATH $ORIGIN)

# discord-rpc
add_subdirectory("${CMAKE_CURRENT_LIST_DIR}/thirdparty/discord")

Expand Down
2 changes: 1 addition & 1 deletion src/gui/previews/MDLPreview.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,7 @@ void MDLWidget::mouseMoveEvent(QMouseEvent* event) {
}

QVector3D inputAxis;
if (!rmbBeingHeld) {
if (!this->rmbBeingHeld) {
// Rotation axis is perpendicular to the mouse position difference vector
inputAxis = QVector3D(diff.y(), diff.x(), 0.0).normalized();
} else {
Expand Down

0 comments on commit 3bc4c24

Please sign in to comment.