Commit Graph

91 Commits

Author SHA1 Message Date
Vaxry
3dbf8e936e cursor: add hyprcursor loggers 2024-04-15 16:45:08 +01:00
Jan Beich
2ea367839b
build: Unbreak build on FreeBSD by adjusting dependencies (#5595)
* deps: add epoll-shim for some BSDs after 863c7b6072

ld: error: undefined symbol: timerfd_create
>>> referenced by EventLoopManager.cpp
>>>               src/Hyprland.p/managers_eventLoop_EventLoopManager.cpp.o:(CEventLoopManager::CEventLoopManager())

ld: error: undefined symbol: timerfd_settime
>>> referenced by EventLoopManager.cpp
>>>               src/Hyprland.p/managers_eventLoop_EventLoopManager.cpp.o:(CEventLoopManager::nudgeTimers())

See also
https://github.com/freebsd/freebsd-src/commit/af93fea71038
https://github.com/netbsd/src/commit/75f1bc6655cf

* deps: drop unused xcb-image after 45945a3e7d

$ pkg install <hyprland dependencies>
$ pkg install meson jq `pkg rquery %dn wlroots` hwdata
$ gmake all
[...]
-- Checking for modules 'xcb;xwayland;xcb-util;xcb-render;xcb-image;xcb-xfixes;xcb-icccm;xcb-composite;xcb-res;xcb-ewmh'
--   Package 'xcb-image' not found
CMake Error at /usr/local/share/cmake/Modules/FindPkgConfig.cmake:619 (message):
  The following required packages were not found:

   - xcb-image

Call Stack (most recent call first):
  /usr/local/share/cmake/Modules/FindPkgConfig.cmake:841 (_pkg_check_modules_internal)
  CMakeLists.txt:177 (pkg_check_modules)

See also
https://github.com/swaywm/wlroots/commit/ae7c3f3d1c56
2024-04-15 14:42:17 +01:00
Yaroslav
9e4b2efe7e
cmake: Some small cmake cleanups (#5572)
* remove unnecessary include

* cmake: use pkg_get_variable

We can find wayland-scanner executable and wayland-protocols dir by
taking advantage of this function, so no need to use find_program or
manually call pkgconf executable.

* cmake: remove explicit rdynamic option

CMAKE_ENABLE_EXPORTS=ON already implies rdynamic so it's redundant to
set the latter explicitly.

Also, CMAKE_ENABLE_EXPORTS is superseded by
CMAKE_EXECUTABLE_ENABLE_EXPORTS in cmake 3.27.

* cmake: make xcb-errors dep optional

xcb-errors is being used in wlroots, where it's optional. So make it
optional in hyprland as well
2024-04-13 14:40:28 +01:00
Vaxry
45945a3e7d deps: move from wlroots to wlroots-hyprland 2024-04-12 16:31:50 +01:00
Vaxry
0457c2e348 pkg-config -> pkgconf for hyprpm and cmake 2024-04-08 20:54:06 +03:00
Yaroslav Lelkin
b50182326c cmake: make sure that OpenGL::EGL is populated
bump cmake version cause 3.27 is the version where "... COMPONENTS
GLESx" option is introduced. See
https://cmake.org/cmake/help/latest/module/FindOpenGL.html
2024-04-07 19:08:25 +03:00
Vaxry
568b352b23 cmakelists: remove oopsie 2024-03-22 18:52:07 +00:00
Vaxry
461757e2fb scripts: fix asan patch 2024-03-22 18:45:28 +00:00
Vaxry
c3882bb832
internal: Support libhyprcursor (#5009)
woo

---------

Co-authored-by: Mihai Fufezan <fufexan@protonmail.com>
2024-03-09 16:52:59 +00:00
Vaxry
13f6f0b923
Migrate the config to hyprlang (#4656)
* Migrate to hyprlang

* pop up errors

* fix swapped args

* Meson & Nix: build with hyprlang

* CI: add hyprlang to setup action

* add infra for plugin stuff

* fix hyprctl getoption

* fix hyprctl getoption with json

* format

* fix post parse logic

* fix autogen config

* oops missed exec-once

* fmt

* fix ws rules

* require 0.3.0 for hyprlang

* nix: flaek

* minor type fixes

* fix cfg usages in swipe

* use cvarlist for ws rules

* fix throw in addPluginConfigVar

* Nix: update hyprlang

* minor fixes

* fix disableLogs

* mention hyprlang docs

* bump hyprlang dep in cmake

* Meson: bump min hyprlang version

Nix: update hyprlang

* minor fix

* Nix: update meson patch

---------

Co-authored-by: Mihai Fufezan <fufexan@protonmail.com>
2024-02-18 15:00:34 +00:00
Piroro-hs
955009655d
cmake: Propagate NO_XWAYLAND to wlroots building setup (#4385) 2024-01-08 19:24:52 +01:00
vaxerski
0be36cd02d cmakelists: fix wlroots patch sed 2024-01-01 18:29:10 +01:00
vaxerski
c7ba460687 wlroots: update version patches 2024-01-01 18:19:22 +01:00
Vaxry
d360550546
hyprpm: Add hyprpm, a Hyprland Plugin Manager (#4072) 2023-12-07 10:41:09 +00:00
Vaxry
6f733292bf renderer: nvidia checks and use glFinish on nvidia
fixes #3952 #3946
2023-11-25 17:45:08 +00:00
Vaxry
af5d06593f cmakelists: fix old wlroots sover 2023-11-24 10:59:02 +00:00
Vaxry
2ebfd0c745
renderer: Move to a full Hyprland GL rendering pipeline (#3920)
Also updates wlroots
2023-11-24 10:54:21 +00:00
Vaxry
a903dba858 cmake: include tracy cpp if set 2023-11-17 23:26:54 +00:00
q234rty
ef90d1eaaf Map cmake None to meson's plain
empty is not a build type that exists in meson.

I have no idea why I typed "empty" in #3614 ...

Fixes: ba5f1d8783
2023-11-02 19:20:09 +02:00
Vaxry
6914103289 cmake: set asan for only hyprland not others 2023-10-31 21:45:27 +00:00
Vaxry
edb26e0306 cmake: remove old definitions from cmakelists 2023-10-22 12:25:26 +01:00
q234rty
ba5f1d8783
cmake: Map cmake None to meson empty (#3614)
While not explicitly mentioned by the cmake documentation, cmake
upstream seems to think of None as a vaild CMAKE_BUILD_TYPE. [1]
Handle it properly by mapping it to meson's empty.

[1]: ce1cadd35a
2023-10-19 15:59:24 +01:00
Campbell Barton
d994e6aea6
cmake: Fix error building without CMAKE_BUILD_TYPE being set (#3590)
* Fix error building without CMAKE_BUILD_TYPE being set

This resolves the error building without a CMAKE_BUILD_TYPE.
CMake Error at CMakeLists.txt:36 (string):                                                                                                                                                          
  string no output variable specified

* CMake: convert CMake's build type to meson build type

Fix error when the CMAKE_BUILD_TYPE variable isn't set & properly convert the build type to mesons build type.
2023-10-19 15:00:58 +01:00
Vaxry
8af3e7beeb cmake: search for systemd headers first 2023-10-15 22:35:56 +01:00
Vaxry
d4e4931008
build: CMake pipeline improvements (#3564) 2023-10-14 18:48:05 +01:00
Vaxry
06cc42441c
build: guard execinfo.h via build systems (#3547)
* guard execinfo via cmake

* libexecinfo -> execinfo macro name

* meson: add execinfo check

* move check in cmake up

---------

Co-authored-by: Mihai Fufezan <fufexan@protonmail.com>
2023-10-11 22:27:53 +01:00
Vaxry
914851b91a
internal: better versioning (#3543)
* better versioning

* meson: better versioning

* nix: better versioning

---------

Co-authored-by: Mihai Fufezan <fufexan@protonmail.com>
2023-10-10 20:21:57 +01:00
Vaxry
88b63a00b6
renderer: Tearing implementation (#3441) 2023-09-28 21:48:33 +01:00
memchr
8e9f010ee0
build: use PCH to reduce compile time (#3095) 2023-09-04 19:56:02 +02:00
vaxerski
b48f810a12 meson/cmake: remove refs to ext-workspace-unstable-v1 2023-09-01 17:14:56 +02:00
vaxerski
f5913135c6 input: add support for cursor-shape-v1 2023-07-24 18:50:17 +02:00
vaxerski
7940f779e9 cmakelists: move tracy to debug section 2023-07-20 18:29:37 +02:00
vaxerski
e5dd133808 cmake: fix compile 2023-07-20 17:57:02 +02:00
vaxerski
a921c5b89e Debug: add tracy 2023-07-20 17:47:49 +02:00
vaxerski
b156a9654f build: add asan enable status flag 2023-07-16 17:06:05 +02:00
vaxerski
01f85a09a9 xwayland: send zero scaling to xwayland if enabled 2023-06-23 21:42:44 +02:00
vaxerski
9cf72a30fc debug: add WITH_ASAN flag in cmake 2023-06-01 17:08:11 +02:00
Jan Beich
609c7ab6b5
Unbreak CMake build on FreeBSD (#2209)
* 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.
2023-05-02 14:38:36 +01:00
vaxerski
5ce76cd0b0 internal: add tag to version, send hash in release ci 2023-04-27 14:28:40 +01:00
Ching Pei Yang
38bdbdb0f5
Plugin header overhaul (#2087)
* meson: install headers

* Meson/CMake: add pkg-config file for headers

* makefile: install headers and pkgconfig

* CMake: move protocols to cmake

Co-authored-by: Ching Pei Yang <badnam3o.0@gmail.com>

---------

Co-authored-by: Mihai Fufezan <fufexan@protonmail.com>
Co-authored-by: vaxerski <43317083+vaxerski@users.noreply.github.com>
2023-04-27 00:59:16 +03:00
vaxerski
77223e1cad deps: update wlroots 2023-04-26 17:23:50 +01:00
vaxerski
99079f7094 cmake: ignore format-truncation 2023-04-22 12:38:04 +01:00
Vaxry
046ad79d11
GlobalShortcuts protocol impl (#1886)
Implements the `hyprland-global-shortcuts-v1` protocol

---------

Co-authored-by: Mihai Fufezan <fufexan@protonmail.com>
2023-04-09 13:48:20 +01:00
Vaxry
0a099ca2ab
Hyprland Screencopy impl (#1800)
---------

Co-authored-by: Mihai Fufezan <fufexan@protonmail.com>
2023-04-03 17:01:05 +01:00
vaxerski
71a95a581f feat: add pretty notifications 2023-03-20 15:03:09 +00:00
vaxerski
e8adae65fe debug: unbreak debug builds 2023-03-16 15:40:50 +00:00
stephan-cr
e4b6af41e5
Refactor CMake and Make file (#1766)
* Refactor CMake and Make file

- modernize CMake a bit
- "unscreamify" CMake commands
- replace undocumented CMake option -H by -S in Makefile
- remove unnecessary "cd" in Makefile

* Fix include path to wlroots generated header files
2023-03-14 21:50:30 +00:00
Vaxry
5dc1a5fec6
input: text-input-v1 support (#1778)
support zwp_text_input_v1

---------

Co-authored-by: Mihai Fufezan <fufexan@protonmail.com>
2023-03-14 12:57:50 +00:00
Vaxry
8b81f41e52
Plugin System (#1590)
---------

Co-authored-by: Mihai Fufezan <fufexan@protonmail.com>
2023-02-27 12:32:38 +00:00
vaxerski
431c74f111 remove -g from release compiles 2023-02-20 23:17:31 +00:00