Skip to content

Commit ae1b35b

Browse files
committed
Fixing Linux build
1 parent 7a549a9 commit ae1b35b

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

CMakeLists.txt

+5-2
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ set_property(TARGET smol-cube-viewer PROPERTY MSVC_RUNTIME_LIBRARY "MultiThreade
2525
target_compile_definitions(smol-cube-conv PRIVATE _CRT_SECURE_NO_DEPRECATE _CRT_NONSTDC_NO_WARNINGS NOMINMAX)
2626
target_compile_definitions(smol-cube-viewer PRIVATE _CRT_SECURE_NO_DEPRECATE _CRT_NONSTDC_NO_WARNINGS NOMINMAX)
2727

28-
29-
if((CMAKE_CXX_COMPILER_ID MATCHES "Clang" OR CMAKE_CXX_COMPILER_ID MATCHES "GNU") AND (CMAKE_SYSTEM_PROCESSOR STREQUAL "AMD64"))
28+
if(((CMAKE_CXX_COMPILER_ID MATCHES "Clang") OR (CMAKE_CXX_COMPILER_ID MATCHES "GNU")) AND
29+
((CMAKE_SYSTEM_PROCESSOR STREQUAL "AMD64") OR (CMAKE_SYSTEM_PROCESSOR STREQUAL "x86_64")))
3030
target_compile_options(smol-cube-conv PRIVATE -msse4.1)
3131
target_compile_options(smol-cube-viewer PRIVATE -msse4.1)
3232
endif()
@@ -40,3 +40,6 @@ if (APPLE)
4040
"-framework QuartzCore"
4141
)
4242
endif ()
43+
if (CMAKE_SYSTEM_NAME STREQUAL "Linux")
44+
target_link_libraries(smol-cube-viewer PRIVATE X11 Xi Xcursor GL)
45+
endif ()

readme.md

+1
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@ The library itself is written in C++, and requires C++ 17 or later. It provides
6060
- Access and inspection of the loaded LUT data.
6161

6262
In order to use the library, compile `src/smol_cube.cpp` in your project, and include `src/smol_cube.h`.
63+
If building with clang/gcc for x64, compile with SSE4.1 or later (`-msse4.1`).
6364

6465
License is either MIT or Unlicense, whichever is more convenient for you.
6566

0 commit comments

Comments
 (0)