* Add `activeworkspace` hyprctl command
* fix format in hyprctl
* Make stuff more shared in workspace hyprctl
---------
Co-authored-by: vaxerski <43317083+vaxerski@users.noreply.github.com>
* cmake: unbreak on non-GNU after 474ada9267
CMake Error at CMakeLists.txt:121 (target_link_libraries):
The keyword signature for target_link_libraries has already been used with
the target "Hyprland". All uses of target_link_libraries with a target
must be either all-keyword or all-plain.
The uses of the keyword signature are here:
* CMakeLists.txt:107 (target_link_libraries)
Fixes https://github.com/hyprwm/Hyprland/issues/1780
* cmake: always link with dependencies via imported targets
On BSD systems base compiler by default only looks for headers and
libraries from base system. For dependencies from packages extra flags
are necessary.
ld: error: unable to find library -lxcb
ld: error: unable to find library -lpixman-1
ld: error: unable to find library -lOpenGL
ld: error: unable to find library -lGLESv2
* make: use same make in recursive calls
On BSDs `make` is BSD make while `gmake` is GNU make
* make: work around GNU vs. BSD sed -i incompatibility
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=254091
* make: replace GNU make extension with POSIX sh
`$(shell ...)` in GNU make is similar to `${:!..!}` in BSD make
* make: fall back when nproc isn't available
Only FreeBSD added nproc for compatibility with Linux.
* make: unbreak hyprctl on Clang-based systems
/bin/sh: g++: not found
error: invalid value 'c++23' in '-std=c++23'
* make: create lib/ before copying libwlroots.so there
$ make install PREFIX=/tmp/test
[...]
cp: directory /tmp/test/lib does not exist
* make: pass cp(1) flags before arguments
cp: -f is not a directory
* make: replace install -Dt with mkdir
install: illegal option -- t
* make: replace cp --parents with cpio -dump
cp: illegal option -- -
* make: limit pkg-config workaround to Linux when run as root
/usr/share/pkgconfig doesn't exist on BSDs or may not be writable.
* added some workspace-specific rules
* added some worskpace-specific rules, with windowrule like syntax
* monitor is not mandatory anymore
* pointers to config are now static
* fixed optional WorkspaceRule fields
* Windows can now specify border size
* removed CHyprOpenGLImpl::renderBorder borderSize default value
* stuff
---------
Co-authored-by: Alessio Molinari <alessiomolinari@gmail.com>
Co-authored-by: vaxerski <43317083+vaxerski@users.noreply.github.com>
* Declarative plugin management
Allow declaring `plugin` entries in the hyprland configuration.
Plugins will be loaded if an entry is added and unloaded if that entry
is removed.
* Replace pointers with copying in updateconfigPlugins
* Include which plugin was declared twice in error
In the case that the prefix is `/usr`, system wlroots headers installed in `/usr/include/wlr` will be preferred over those bundled by hyprland as `-I` directories are searched [from left to right](https://gcc.gnu.org/onlinedocs/cpp/Search-Path.html), which is not great since the system wlroots headers might not be compatible with hyprland. Fix the order of cflags so bundled wlroots headers will be preferred over system ones.
hyprctl/main.cpp:83:5: warning: 'strncpy' size argument is too large; destination buffer has size 104, but size argument is 107 [-Wfortify-source]
strncpy(serverAddress.sun_path, socketPath.c_str(), 107);
^
hyprctl/main.cpp:146:5: warning: 'strncpy' size argument is too large; destination buffer has size 104, but size argument is 107 [-Wfortify-source]
strncpy(serverAddress.sun_path, socketPath.c_str(), 107);
^
src/managers/EventManager.cpp:70:9: warning: 'strncpy' size argument is too large; destination buffer has size 104, but size argument is 107 [-Wfortify-source]
strncpy(SERVERADDRESS.sun_path, socketPath.c_str(), 107);
^