1diff --git i/CMakeLists.txt w/CMakeLists.txt
2index 364f72b..2d5070d 100644
3--- i/CMakeLists.txt
4+++ w/CMakeLists.txt
5@@ -7,16 +7,8 @@ project(qzdl LANGUAGES C CXX)
6 find_package(QT NAMES Qt6 Qt5 REQUIRED COMPONENTS Core Widgets)
7 find_package(Qt${QT_VERSION_MAJOR} REQUIRED COMPONENTS Core Widgets REQUIRED)
8
9-include(FetchContent)
10-FetchContent_Declare(
11- inih
12- GIT_REPOSITORY https://github.com/benhoyt/inih.git
13- GIT_TAG r44
14-)
15-FetchContent_GetProperties(inih)
16-if (NOT inih_POPULATED)
17- FetchContent_MakeAvailable(inih)
18-endif()
19+find_package(PkgConfig)
20+pkg_check_modules(INIH inih)
21
22 add_executable(
23 zdl
24@@ -46,9 +38,9 @@ add_executable(
25 libwad.cpp
26 qzdl.cpp
27 ${PROJECT_SOURCE_DIR}/zdlconf/zdlconf.cpp
28- ${inih_SOURCE_DIR}/ini.c
29 )
30
31-target_include_directories(zdl PRIVATE ${PROJECT_SOURCE_DIR}/zdlconf)
32-target_include_directories(zdl PRIVATE ${inih_SOURCE_DIR})
33-target_link_libraries(zdl Qt${QT_VERSION_MAJOR}::Core Qt${QT_VERSION_MAJOR}::Widgets)
34+target_include_directories(zdl PRIVATE ${PROJECT_SOURCE_DIR}/zdlconf ${inih_INCLUDE_DIR})
35+target_link_libraries(zdl Qt${QT_VERSION_MAJOR}::Core Qt${QT_VERSION_MAJOR}::Widgets ${INIH_LDFLAGS})
36+
37+install(TARGETS zdl RUNTIME DESTINATION "bin")