diff --git a/Makefile b/Makefile index 578c608..8a51517 100644 --- a/Makefile +++ b/Makefile @@ -22,9 +22,21 @@ $(__Tomlplusplus): tomlplusplus ninja -C tomlplusplus/build sudo $(MESON) install -C tomlplusplus/build +# Build hyprlang if the .hpp file is not installed +# Library for hyprwm +__Hyprlang = $(INCLUDE_SYS_PATH)/hyprlang.hpp +$(__Hyprlang): hyprlang + $(CMAKE) --no-warn-unused-cli -DCMAKE_BUILD_TYPE:STRING=Release \ + -DCMAKE_INSTALL_PREFIX:PATH=/usr -S ./hyprlang -B ./hyprlang/build + $(CMAKE) --build ./hyprlang/build --config Release --target hyprlang \ + -j`nproc 2>/dev/null || getconf _NPROCESSORS_CONF` + # At this point install hyprlang since it is a library other apps need + @echo "Installing library hyprlang..." + sudo $(CMAKE) --install ./hyprlang/build + # Build hyprcursor if the .hpp file is not installed (required hyprlang) # Library for hyprwm -__Hyprcursor = $(INCLUDE_SYS_PATH)/hyprcursor/ +__Hyprcursor = $(INCLUDE_SYS_PATH)/hyprcursor $(__Hyprcursor): $(__Tomlplusplus) $(__Hyprlang) hyprcursor $(CMAKE) --no-warn-unused-cli -DCMAKE_BUILD_TYPE:STRING=Release \ -DCMAKE_INSTALL_PREFIX:PATH=/usr -S ./hyprcursor -B ./hyprcursor/build @@ -43,18 +55,6 @@ $(__Hyprutils): hyprutils -j`nproc 2>/dev/null || getconf _NPROCESSORS_CONF` sudo $(CMAKE) --install hyprutils/build -# Build hyprlang if the .hpp file is not installed -# Library for hyprwm -__Hyprlang = $(INCLUDE_SYS_PATH)/hyprlang.hpp -$(__Hyprlang): hyprlang - $(CMAKE) --no-warn-unused-cli -DCMAKE_BUILD_TYPE:STRING=Release \ - -DCMAKE_INSTALL_PREFIX:PATH=/usr -S ./hyprlang -B ./hyprlang/build - $(CMAKE) --build ./hyprlang/build --config Release --target hyprlang \ - -j`nproc 2>/dev/null || getconf _NPROCESSORS_CONF` - # At this point install hyprlang since it is a library other apps need - @echo "Installing library hyprlang..." - sudo $(CMAKE) --install ./hyprlang/build - __Hyprwayland-scanner = /usr/lib64/cmake/hyprwayland-scanner $(__Hyprwayland-scanner): hyprwayland-scanner $(CMAKE) -DCMAKE_INSTALL_PREFIX=/usr -S ./hyprwayland-scanner \