gtk + -3.0找不到问题 [英] gtk+-3.0 not found issue

查看:1939
本文介绍了gtk + -3.0找不到问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用Vala语言编写程序。当我尝试在Launchpad上构建 .deb 包时,出现

CMake找不到 valac gtk + -3.0 。它使用 valac 版本 0.30 。虽然它确实找到了它,但当我在计算机上执行此操作时(使用cmake来构建)。



这是我第一次尝试构建。 deb 包,所以我有点困惑该怎么办......任何人都可以告诉我如何解决这个问题?
提前致谢。

解决方案

错误很明显,CMake无法找到 pkg-config package 名为'gtk + -3.0'。



您必须安装包含 gtk + -3.0.pc 文件的Ubuntu包(它是 libgtk-3

事实上 pkg-config 是为了编译和链接到libgtk + -3.0库。 / code>在许多Linux发行版中都可用,并且它始终在其搜索路径中查找 gtk + -3.0.pc 文件。包含这个文件的包(以及开发头文件和库)可能在不同的Linux发行版中命名不同。



当我们谈论Vala时:valac编译器也有一个名为 - pkg (例如 - pkg gee-0.8 --pkg gtk + -3.0 )的命令行开关,它使用 pkg-config 来确定根据 .pc 文件创建的库生成必需的头文件和库。


I'm writing program using Vala language. When I try to build a .deb package on Launchpad, I get this error

CMake can't find valac package gtk+-3.0. It uses valac version 0.30. Though it does find it, when I do this on my computer (use cmake to build).

This is first time I try to build .deb package, so I'm a bit confused with what to do... Can anyone tell me how to fix this? Thanks in advance.

解决方案

The error is quite clear, CMake can't find the pkg-config package named 'gtk+-3.0'.

You have to install the Ubuntu package containing the gtk+-3.0.pc file (which is libgtk-3-dev) in order to compile and link against the libgtk+-3.0 library.

In fact pkg-config is available in many Linux distributions and it always looks for the gtk+-3.0.pc file in it's search path. The package containing this file (and the development headers and libraries) may be named differently on differnt Linux distros.

While we are talking about Vala: The valac compiler also has a command line switch named --pkg (e.g. --pkg gee-0.8 --pkg gtk+-3.0) which uses the pkg-config to determine the necessary headers and libs to build against libraries that come with a .pc file.

这篇关于gtk + -3.0找不到问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆