我正在尝试跟随这在 Ubuntu 上安装 GnuPG 接口的描述。输出./configure
是
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking whether make supports nested variables... (cached) yes
checking for style of include used by make... GNU
checking for gcc... no
checking for cc... no
checking for cl.exe... no
configure: error: in `/home/batzinger/Downloads/gpgme-1.8.0':
configure: error: no acceptable C compiler found in $PATH
See `config.log' for more details
build-essential 包已安装。网上好像没有其他解决方案。还有其他方法可以解决这个问题吗?
答案1
如果使用 Ubuntu,只需从存储库安装一些数据包即可。php-gnupg
有 GPGME 的libgpgme11
包作为依赖项。因此,您无需自行编译 GPGME,只需安装所需的包即可:
sudo apt-get install php-gnupg
这也意味着您将获得 GPGME 和 PHP 库以及操作系统的更新,并且不必手动关心它们。