Keruspe / GPaste

Clipboard management system
BSD 2-Clause "Simplified" License
756 stars 54 forks source link

build fail ----- ERROR: Dependency "gcr-4" not found, tried pkgconfig and cmake #407

Closed wzh4464 closed 1 year ago

wzh4464 commented 1 year ago

At commit 61f4f4ed92593898ad84c66f3901b6fb7790f73d, I run:

$ mkdir build
$ cd build
$ meson ..

And then it outputs:

The Meson build system
Version: 0.62.2
Source dir: /home/wu/codes/GPaste
Build dir: /home/wu/codes/GPaste/build
Build type: native build
Project name: GPaste
Project version: 42.1
C compiler for the host machine: cc (gcc 11.2.0 "cc (Ubuntu 11.2.0-19ubuntu1) 11.2.0")
C linker for the host machine: cc ld.bfd 2.38
Host machine cpu family: x86_64
Host machine cpu: x86_64
Found pkg-config: /usr/bin/pkg-config (0.29.2)
Run-time dependency appstream-glib found: YES 0.7.18
Found CMake: /usr/bin/cmake (3.22.1)
Run-time dependency gcr-4 found: NO (tried pkgconfig and cmake)

../meson.build:30:0: ERROR: Dependency "gcr-4" not found, tried pkgconfig and cmake

A full log can be found at /home/wu/codes/GPaste/build/meson-logs/meson-log.txt

And here is the full log:

meson-log.txt

I've tried install gcr and

gcr is already the newest version (3.40.0-4).

So why is that? Thank you very much.

System Version: Linux version 5.15.0-48-generic (buildd@lcy02-amd64-080) (gcc (Ubuntu 11.2.0-19ubuntu1) 11.2.0, GNU ld (GNU Binutils for Ubuntu) 2.38) #54-Ubuntu SMP Fri Aug 26 13:26:29 UTC 2022

jtojnar commented 1 year ago

GCR 4 is part of unstable gcr version (≥ 3.90). And even if you install that somehow, the master branch targets GNOME Shell 43, which you probably do not have either.

wzh4464 commented 1 year ago

If so how should I build the stable version from source? Thank you.

jtojnar commented 1 year ago

The link to stable version tarball is at the end of README. Or if you want to build from Git repo, use git checkout v42.1 to change the tree to that. But I would still recommend getting a pre-built package from your distro if that is possible.

jtojnar commented 1 year ago

Since https://github.com/Keruspe/GPaste/commit/189bcc88d5c69753414a62b04067f18c9ce7dc80, the master branch should support GCR 3 again. #409 made it so both versions are supported.

wzh4464 commented 1 year ago

Thank you.

wzh4464 commented 1 year ago

I noticed that it requires gcr-base-3 at version 3.41 or above, but the newest stable version is 3.40. Is it a miss?

jtojnar commented 1 year ago

3.41.1 is the newest stable, see https://gitlab.gnome.org/GNOME/gcr/-/tags/3.41.1. But not sure why Keruspe chose it in https://github.com/Keruspe/GPaste/commit/eece9c374a823234bc20e58bf95bb10ace9590f4.

wzh4464 commented 1 year ago

I think we can close it?