Skip to content

Commit

Permalink
Remove dependency on glaze
Browse files Browse the repository at this point in the history
Using an advanced JSON library for string parsing was overkill,
and limited compatibility as glaze compiles on fewer systems than all of hypr*
  • Loading branch information
earboxer committed Jan 15, 2025
1 parent 9e15bbb commit 88c3624
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 29 deletions.
9 changes: 0 additions & 9 deletions .github/actions/setup_base/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,15 +63,6 @@ runs:
librsvg \
re2
- name: Get glaze
shell: bash
run: |
git clone https://github.com/stephenberry/glaze.git
cd glaze
cmake --no-warn-unused-cli -DCMAKE_BUILD_TYPE:STRING=Release -DCMAKE_INSTALL_PREFIX:PATH=/usr -S . -B ./build
cmake --build ./build --config Release --target all -j`nproc 2>/dev/null || getconf NPROCESSORS_CONF`
cmake --install build
- name: Get hyprwayland-scanner-git
shell: bash
run: |
Expand Down
16 changes: 1 addition & 15 deletions hyprpm/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,23 +11,9 @@ set(CMAKE_CXX_STANDARD 23)

pkg_check_modules(hyprpm_deps REQUIRED IMPORTED_TARGET tomlplusplus hyprutils>=0.2.4)

find_package(glaze QUIET)
if (NOT glaze_FOUND)
set(GLAZE_VERSION v4.2.3)
message(STATUS "glaze dependency not found, retrieving ${GLAZE_VERSION} with FetchContent")
include(FetchContent)
FetchContent_Declare(
glaze
GIT_REPOSITORY https://github.com/stephenberry/glaze.git
GIT_TAG ${GLAZE_VERSION}
GIT_SHALLOW TRUE
)
FetchContent_MakeAvailable(glaze)
endif()

add_executable(hyprpm ${SRCFILES})

target_link_libraries(hyprpm PUBLIC PkgConfig::hyprpm_deps glaze::glaze)
target_link_libraries(hyprpm PUBLIC PkgConfig::hyprpm_deps)

# binary
install(TARGETS hyprpm)
Expand Down
1 change: 0 additions & 1 deletion hyprpm/src/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ executable(
dependency('hyprutils', version: '>= 0.1.1'),
dependency('threads'),
dependency('tomlplusplus'),
dependency('glaze', method: 'cmake'),
],
install: true,
)
Expand Down
4 changes: 0 additions & 4 deletions nix/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,12 @@
pkg-config,
pkgconf,
makeWrapper,
cmake,
meson,
ninja,
aquamarine,
binutils,
cairo,
git,
glaze,
hyprcursor,
hyprgraphics,
hyprland-protocols,
Expand Down Expand Up @@ -104,7 +102,6 @@ in
makeWrapper
meson
ninja
cmake # needed for glaze
pkg-config
];

Expand All @@ -119,7 +116,6 @@ in
aquamarine
cairo
git
glaze
hyprcursor
hyprgraphics
hyprland-protocols
Expand Down

0 comments on commit 88c3624

Please sign in to comment.