无法使用Snapcraft创建快照

问题描述

我正在尝试在ubuntu 20.04 x64上为Alacritty创建快照。使用cargo build --release创建可执行文件可以正常工作。使用snapcraft创建快照会显示错误消息:

note: /usr/bin/ld: cannot find Scrt1.o: No such file or directory
      /usr/bin/ld: cannot find crti.o: No such file or directory
      collect2: error: ld returned 1 exit status

error: aborting due to prevIoUs error
error: Could not compile `libc`.

To learn more,run the command again with --verbose.
warning: build Failed,waiting for other jobs to finish...
error: build Failed
Failed to run '/root/.cargo/bin/cargo +stable build --release' for 'allacrity-source': Exited with code 101.
Verify that the part is using the correct parameters and try again.
Run the same command again with --debug to shell into the environment if you wish to introspect this failure.

我已经安装了上述两个库Scrt1.o和crti.o。我走得更远,检查了它们的位置,然后编辑了我的〜/ .profile以包含export LIBRARY_PATH=/usr/lib/x86_64-linux-gnu:/usr/lib32:/usr/libx32:$LIBRARY_PATH。这也没有帮助。我该怎么解决

解决方法

可能是64位与32位库不匹配。

Compiling problems: cannot find crt1.o

While building 32-bit executable file in 64-bit Linux I get crt1.o: No such file even with the -m32 flag

相关问答

Selenium Web驱动程序和Java。元素在(x,y)点处不可单击。其...
Python-如何使用点“。” 访问字典成员?
Java 字符串是不可变的。到底是什么意思?
Java中的“ final”关键字如何工作?(我仍然可以修改对象。...
“loop:”在Java代码中。这是什么,为什么要编译?
java.lang.ClassNotFoundException:sun.jdbc.odbc.JdbcOdbc...