我刚刚安装了 Ubuntu 18.04,并且安装了 grub-customizer。但是当我尝试启动它时,我得到了以下输出:
user@ubuntu:~$ grub-customizer
grub-customizer: error while loading shared libraries: libpangomm-1.4.so.1: cannot open shared object file: No such file or directory
我尝试重新安装 grub-customizer,重新安装 libpangomm,但都不起作用。我能做什么?
答案1
Grub 定制器
$ sudo apt install g++ g++-5 libarchive-dev libssl-dev libgtkmm-3.0-dev
$ git clone https://git.launchpad.net/grub-customizer
$ cd grub-customizer/ && mkdir build18
$ cd build18/
$ CC=gcc-5 CXX=g++-5 cmake .. && make && sudo make install
从安装结果构建 Ubuntu 18.04 包:
$ dpkg-shlibdeps -t grub-customizer // get the dependencies for the control file
Directory : grub-customizer/{ DEBIAN/{control, md5}}, usr/
$ dpkg-deb -b grub-customizer grub-customizer_5.0.7-1git050618-ubuntu18_amd64.deb
链接,包https://drive.google.com/file/d/1sdMSjj2Cf2uEM5VHUztYdM7QkyjBAE7M/view?usp=sharing
下载并安装:sudo gdebi Downloads/grub-customizer_5.0.7-1git050618-ubuntu18_amd64.deb
答案2
截至我撰写本文时,它似乎已经正常(它以 GUI 应用程序的形式打开并运行),运行 18.04.1(64 位)。以下是我发现有效的步骤:
sudo apt-get update && sudo apt-get upgrade && sudo apt-get dist-upgrade
sudo add-apt-repository ppa:danielrichter2007/grub-customizer
sudo apt-get update
sudo apt-get install grub-customizer
(基于:https://launchpad.net/~danielrichter2007/+archive/ubuntu/grub-customizer)
以下是从上述第 2 步开始的终端输出:
robdaviswork@Workstation-U64:~$ sudo add-apt-repository ppa:danielrichter2007/grub-customizer
This PPA contains the latest release of Grub Customizer.
sudo add-apt-repository ppa:danielrichter2007/grub-customizer
sudo apt-get update
sudo apt-get install grub-customizer
More info: https://launchpad.net/~danielrichter2007/+archive/ubuntu/grub-customizer
Press [ENTER] to continue or Ctrl-c to cancel adding it.
Hit:1 http://gb.archive.ubuntu.com/ubuntu bionic InRelease
Hit:2 http://gb.archive.ubuntu.com/ubuntu bionic-updates InRelease
Get:3 http://ppa.launchpad.net/danielrichter2007/grub-customizer/ubuntu bionic InRelease [15.4 kB]
Hit:4 http://gb.archive.ubuntu.com/ubuntu bionic-backports InRelease
Get:5 http://security.ubuntu.com/ubuntu bionic-security InRelease [83.2 kB]
Ign:6 http://www.scootersoftware.com bcompare4 InRelease
Hit:7 http://www.scootersoftware.com bcompare4 Release
Get:8 http://ppa.launchpad.net/danielrichter2007/grub-customizer/ubuntu bionic/main amd64 Packages [680 B]
Get:10 http://ppa.launchpad.net/danielrichter2007/grub-customizer/ubuntu bionic/main i386 Packages [680 B]
Get:11 http://ppa.launchpad.net/danielrichter2007/grub-customizer/ubuntu bionic/main Translation-en [356 B]
Fetched 100 kB in 1s (163 kB/s)
Reading package lists... Done
robdaviswork@Workstation-U64:~$ sudo apt-get update
Hit:1 http://ppa.launchpad.net/danielrichter2007/grub-customizer/ubuntu bionic InRelease
Hit:2 http://gb.archive.ubuntu.com/ubuntu bionic InRelease
Hit:3 http://gb.archive.ubuntu.com/ubuntu bionic-updates InRelease
Hit:4 http://gb.archive.ubuntu.com/ubuntu bionic-backports InRelease
Get:5 http://security.ubuntu.com/ubuntu bionic-security InRelease [83.2 kB]
Ign:6 http://www.scootersoftware.com bcompare4 InRelease
Hit:7 http://www.scootersoftware.com bcompare4 Release
Fetched 83.2 kB in 1s (133 kB/s)
Reading package lists... Done
robdaviswork@Workstation-U64:~$ sudo apt-get install grub-customizer
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
hwinfo libgtkmm-3.0-1v5 libhd21 libx86emu1
The following NEW packages will be installed
grub-customizer hwinfo libgtkmm-3.0-1v5 libhd21 libx86emu1
0 to upgrade, 5 to newly install, 0 to remove and 0 not to upgrade.
Need to get 2,762 kB of archives.
After this operation, 16.5 MB of additional disk space will be used.
Do you want to continue? [Y/n] Y
Get:1 http://ppa.launchpad.net/danielrichter2007/grub-customizer/ubuntu bionic/main amd64 grub-customizer amd64 5.0.8-0ubuntu1~ppa1b [1,152 kB]
Get:2 http://gb.archive.ubuntu.com/ubuntu bionic/main amd64 libgtkmm-3.0-1v5 amd64 3.22.2-2 [850 kB]
Get:3 http://gb.archive.ubuntu.com/ubuntu bionic/universe amd64 libx86emu1 amd64 1.12-1 [48.1 kB]
Get:4 http://gb.archive.ubuntu.com/ubuntu bionic/universe amd64 libhd21 amd64 21.52-1 [694 kB]
Get:5 http://gb.archive.ubuntu.com/ubuntu bionic/universe amd64 hwinfo amd64 21.52-1 [18.0 kB]
Fetched 2,762 kB in 2s (1,391 kB/s)
Selecting previously unselected package libgtkmm-3.0-1v5:amd64.
(Reading database ... 168557 files and directories currently installed.)
Preparing to unpack .../libgtkmm-3.0-1v5_3.22.2-2_amd64.deb ...
Unpacking libgtkmm-3.0-1v5:amd64 (3.22.2-2) ...
Selecting previously unselected package grub-customizer.
Preparing to unpack .../grub-customizer_5.0.8-0ubuntu1~ppa1b_amd64.deb ...
Unpacking grub-customizer (5.0.8-0ubuntu1~ppa1b) ...
Selecting previously unselected package libx86emu1:amd64.
Preparing to unpack .../libx86emu1_1.12-1_amd64.deb ...
Unpacking libx86emu1:amd64 (1.12-1) ...
Selecting previously unselected package libhd21:amd64.
Preparing to unpack .../libhd21_21.52-1_amd64.deb ...
Unpacking libhd21:amd64 (21.52-1) ...
Selecting previously unselected package hwinfo.
Preparing to unpack .../hwinfo_21.52-1_amd64.deb ...
Unpacking hwinfo (21.52-1) ...
Setting up libx86emu1:amd64 (1.12-1) ...
Processing triggers for mime-support (3.60ubuntu1) ...
Processing triggers for desktop-file-utils (0.23-1ubuntu3.18.04.1) ...
Setting up libgtkmm-3.0-1v5:amd64 (3.22.2-2) ...
Setting up grub-customizer (5.0.8-0ubuntu1~ppa1b) ...
Processing triggers for libc-bin (2.27-3ubuntu1) ...
Processing triggers for man-db (2.8.3-2) ...
Setting up libhd21:amd64 (21.52-1) ...
Processing triggers for gnome-menus (3.13.3-11ubuntu1.1) ...
Processing triggers for hicolor-icon-theme (0.17-2) ...
Setting up hwinfo (21.52-1) ...
Processing triggers for libc-bin (2.27-3ubuntu1) ...
robdaviswork@Workstation-U64:~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04.1 LTS
Release: 18.04
Codename: bionic
robdaviswork@Workstation-U64:~$