pentamassiv / keyboard

Fingerboard is an open-source keyboard meant to be used on a smartphone. It uses wayland protocols
11 stars 0 forks source link

Build not possible on ubuntu and on pinephone (postmarketos) #13

Open coxtor opened 3 years ago

coxtor commented 3 years ago

Hi, I would love to check out your keyboard, however it is not possible to cross compile or build on the pinephone using postmarketos, this is the output:

ine64-pinephone:/home/user/keyboard# cargo build --release Compiling wayland-sys v0.28.5 Compiling libdbus-sys v0.2.1 Compiling libc v0.2.91 Compiling memchr v2.3.4 error: failed to run custom build command for wayland-sys v0.28.5

Caused by:
  process didn't exit successfully: `/home/user/keyboard/target/release/build/wayland-sys-b3c73d9f2edceb6e/build-script-build` (exit code: 101)
  --- stdout
  cargo:rerun-if-env-changed=WAYLAND_CLIENT_NO_PKG_CONFIG
  cargo:rerun-if-env-changed=PKG_CONFIG
  cargo:rerun-if-env-changed=WAYLAND_CLIENT_STATIC
  cargo:rerun-if-env-changed=WAYLAND_CLIENT_DYNAMIC
  cargo:rerun-if-env-changed=PKG_CONFIG_ALL_STATIC
  cargo:rerun-if-env-changed=PKG_CONFIG_ALL_DYNAMIC
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH_aarch64-unknown-linux-musl
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH_aarch64_unknown_linux_musl
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_PATH
  cargo:rerun-if-env-changed=PKG_CONFIG_PATH
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_aarch64-unknown-linux-musl
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR_aarch64_unknown_linux_musl
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_LIBDIR
  cargo:rerun-if-env-changed=PKG_CONFIG_LIBDIR
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_aarch64-unknown-linux-musl
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR_aarch64_unknown_linux_musl
  cargo:rerun-if-env-changed=HOST_PKG_CONFIG_SYSROOT_DIR
  cargo:rerun-if-env-changed=PKG_CONFIG_SYSROOT_DIR

  --- stderr
  thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: Failure { command: "\"pkg-config\" \"--libs\" \"--cflags\" \"wayland-client\"", output: Output { status: ExitStatus(ExitStatus(256)), stdout: "", stderr: "Package wayland-client was not found in the pkg-config search path.\nPerhaps you should add the directory containing `wayland-client.pc\'\nto the PKG_CONFIG_PATH environment variable\nPackage \'wayland-client\', required by \'virtual:world\', not found\n" } }', /root/.cargo/registry/src/github.com-1ecc6299db9ec823/wayland-sys-0.28.5/build.rs:10:47
  stack backtrace:
     0:           0x433ed4 - std::backtrace_rs::backtrace::libunwind::trace::hc19c439db762579d
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/std/src/../../backtrace/src/backtrace/libunwind.rs:90:5
     1:           0x433ed4 - std::backtrace_rs::backtrace::trace_unsynchronized::hd01fc167d5fb9c3c
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/std/src/../../backtrace/src/backtrace/mod.rs:66:5
     2:           0x433ed4 - std::sys_common::backtrace::_print_fmt::hefac8cba8ae793dd
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/std/src/sys_common/backtrace.rs:67:5
     3:           0x433ed4 - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::hd6c7364f3501db4b
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/std/src/sys_common/backtrace.rs:46:22
     4:           0x45d8c8 - core::fmt::write::hce64cd44f98a6bf2
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/core/src/fmt/mod.rs:1092:17
     5:           0x431838 - std::io::Write::write_fmt::h07b2da884b47d1eb
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/std/src/io/mod.rs:1572:15
     6:           0x435bd4 - std::sys_common::backtrace::_print::hcd4c3bf8fe8ebd58
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/std/src/sys_common/backtrace.rs:49:5
     7:           0x435bd4 - std::sys_common::backtrace::print::ha8600706ea81d68b
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/std/src/sys_common/backtrace.rs:36:9
     8:           0x435bd4 - std::panicking::default_hook::{{closure}}::hb1cb92b1b647ba52
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/std/src/panicking.rs:208:50
     9:           0x4356dc - std::panicking::default_hook::he3ae729404661581
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/std/src/panicking.rs:225:9
    10:           0x4361b0 - std::panicking::rust_panic_with_hook::hae82c49ec2c37d45
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/std/src/panicking.rs:591:17
    11:           0x435d6c - std::panicking::begin_panic_handler::{{closure}}::he0d09d173874d769
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/std/src/panicking.rs:497:13
    12:           0x434344 - std::sys_common::backtrace::__rust_end_short_backtrace::h423e6ab919f25976
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/std/src/sys_common/backtrace.rs:141:18
    13:           0x435cd4 - rust_begin_unwind
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/std/src/panicking.rs:493:5
    14:           0x40127c - core::panicking::panic_fmt::hb1d12e65e9311827
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/core/src/panicking.rs:92:14
    15:           0x4011c8 - core::option::expect_none_failed::h050ca4504dfa4ddb
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/core/src/option.rs:1329:5
    16:           0x401a44 - core::result::Result<T,E>::unwrap::h7a27595d14d19208
    17:           0x401b48 - build_script_build::main::hc395d96868db1688
    18:           0x401920 - core::ops::function::FnOnce::call_once::h6062ccfb6bcc5568
    19:           0x401878 - std::sys_common::backtrace::__rust_begin_short_backtrace::h57d956063584d7f4
    20:           0x4019d0 - std::rt::lang_start::{{closure}}::h7cd3183f1b37e082
    21:           0x4364c4 - core::ops::function::impls::<impl core::ops::function::FnOnce<A> for &F>::call_once::hfffee0f9df069f27
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/core/src/ops/function.rs:259:13
    22:           0x4364c4 - std::panicking::try::do_call::h606339b5d58ec0b3
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/std/src/panicking.rs:379:40
    23:           0x4364c4 - std::panicking::try::hed6d7cbdedef327a
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/std/src/panicking.rs:343:19
    24:           0x4364c4 - std::panic::catch_unwind::h1d1be6c1ab1ec376
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/std/src/panic.rs:431:14
    25:           0x4364c4 - std::rt::lang_start_internal::hb3fb54487e87dde7
                                 at /rustc/88f19c6dab716c6281af7602e30f413e809c5974/library/std/src/rt.rs:51:25
    26:           0x4019ac - std::rt::lang_start::h24212f646af7f3ac
    27:           0x401e18 - main
warning: build failed, waiting for other jobs to finish...
error: build failed
pentamassiv commented 2 years ago

Hi @coxtor, I'm sorry I am just now replying to you. Somehow I forgot about the issue until I had a look at this repo today. From your output, it looks as if a dependency is missing. On Ubuntu Jammy, you have to install the following packages: apt-get install -q -y binutils rust-all libgtk-3-dev libwayland-dev libgtk-layer-shell-dev I updated the build Action and it at least builds on x86. I'm running Arch on my Pinephone and there I was able to build it a while back. I don't know if you have a problem on PostmarketOS due to musl? I did not forget about this keyboard, even though the repo has been stale for quite some time. It was a project for university and after I turned it in, I needed a little bit of space from it. I started working on the underlying crates and should soon start on this repo again. Feel free to ask me again about the build process. I promise to reply faster this time

pentamassiv commented 2 years ago

The language model is missing from this repo though so next word prediction and gesture typing would not work. The language model is too big to upload here. That's also the reason why I haven't really put much effort into making it more popular. Without the language model, the keyboard doesn't really start. You'd have to create your own language model. It's probably best for you to wait until I sort out these issues and then I'll let you know