dixonary / draft-reMarkable

A launcher for the reMarkable tablet, which wraps around the standard interface.
Apache License 2.0
147 stars 19 forks source link

real-ld: cannot find -lqsgepaper #36

Open SnorlaxYum opened 1 year ago

SnorlaxYum commented 1 year ago
~/draft-reMarkable$ arm-remarkable-linux-gnueabi-g++  -mfpu=neon -mfloat-abi=hard -mcpu=cortex-a9 --sysroot=/opt/codex/rm10x/3.1.15/sysroots/cortexa9hf-neon-remarkable-linux-gnueabi -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed --sysroot=/opt/codex/rm10x/3.1.15/sysroots/cortexa9hf-neon-remarkable-linux-gnueabi -Wl,-O1 -o draft main.o mainview.o options.o handler.o moc_handler.o   -lqsgepaper /opt/codex/rm10x/3.1.15/sysroots/cortexa9hf-neon-remarkable-linux-gnueabi/usr/lib/libQt5Quick.so /opt/codex/rm10x/3.1.15/sysroots/cortexa9hf-neon-remarkable-linux-gnueabi/usr/lib/libQt5Gui.so /opt/codex/rm10x/3.1.15/sysroots/cortexa9hf-neon-remarkable-linux-gnueabi/usr/lib/libQt5QmlModels.so /opt/codex/rm10x/3.1.15/sysroots/cortexa9hf-neon-remarkable-linux-gnueabi/usr/lib/libQt5Qml.so /opt/codex/rm10x/3.1.15/sysroots/cortexa9hf-neon-remarkable-linux-gnueabi/usr/lib/libQt5Network.so /opt/codex/rm10x/3.1.15/sysroots/cortexa9hf-neon-remarkable-linux-gnueabi/usr/lib/libQt5Core.so -lpthread
/opt/codex/rm10x/3.1.15/sysroots/x86_64-codexsdk-linux/usr/libexec/arm-remarkable-linux-gnueabi/gcc/arm-remarkable-linux-gnueabi/9.3.0/real-ld: cannot find -lqsgepaper
collect2: error: ld returned 1 exit status

how to solve it?

Eeems commented 1 year ago

You are missing libqsgepaper.a. You can find it here: https://github.com/Eeems-Org/oxide/tree/master/shared/epaper

SnorlaxYum commented 1 year ago

Thank you for ur timely help. However, I found it hard to use draft:

  1. xochitl will still override the draft even if I systemctl disable --now xochitl
  2. I tried the mentioned button-capture, which is not working.
  3. rsync 11 happens, making me have to change the deployment path to home [minor issue though].

Hmm, the scarce space.......

reMarkable: ~/ df -h
Filesystem                Size      Used Available Use% Mounted on
/dev/root               230.2M    222.5M         0 100% /
devtmpfs                104.7M         0    104.7M   0% /dev
tmpfs                   233.2M         0    233.2M   0% /dev/shm
tmpfs                   233.2M    608.0K    232.6M   0% /run
tmpfs                   233.2M         0    233.2M   0% /sys/fs/cgroup
tmpfs                   233.2M     12.0K    233.1M   0% /tmp
tmpfs                   233.2M         0    233.2M   0% /var/volatile
/dev/mmcblk1p1           19.0M     11.0M      8.1M  58% /var/lib/uboot
/dev/mmcblk1p7            6.6G    710.2M      5.5G  11% /home

On 3/22/23 23:52, Nathaniel van Diepen wrote:

You are missing |libqsgepaper.a|. You can find it here: https://github.com/Eeems-Org/oxide/tree/master/shared/epaper

— Reply to this email directly, view it on GitHub https://github.com/dixonary/draft-reMarkable/issues/36#issuecomment-1479827399, or unsubscribe https://github.com/notifications/unsubscribe-auth/AEGUCRQVJKFUVSH4R5CYNCDW5MN4BANCNFSM6AAAAAAWDQV6XM. You are receiving this because you authored the thread.Message ID: @.***>

Eeems commented 1 year ago

There is another systemd service that will start xochitl even if it's disabled. I think it's sync.service.

If you want to install draft without any changes, I'd recommend installing toltec, as it has draft packaged, and handles the issues you are encountering.

SnorlaxYum commented 1 year ago

I'd love to use toltec. Sadly, on the official site, it said: "/Toltec does not support OS builds newer than 2.15.1.1189/" My remarkable version is well beyond 3. Tried to disable sync and it worked. Sadly the only drawback is that draft launcher doesn't support multitasking. For example, I have to click power off in xochitl to get back to draft.

On 3/23/23 22:28, Nathaniel van Diepen wrote:

There is another systemd service that will start xochitl even if it's disabled. I think it's sync.service.

If you want to install draft without any changes, I'd recommend installing toltec, as it has draft packaged, and handles the issues you are encountering.

— Reply to this email directly, view it on GitHub https://github.com/dixonary/draft-reMarkable/issues/36#issuecomment-1481299170, or unsubscribe https://github.com/notifications/unsubscribe-auth/AEGUCRSE4ZLAWFN2QGONXVTW5RMX3ANCNFSM6AAAAAAWDQV6XM. You are receiving this because you authored the thread.Message ID: @.***>

Eeems commented 1 year ago

It looks like you are using a rM1 and not a rM2? You in theory should be able to use toltec on 3.x with no issue, but we haven't tested yet, so there might be issues. You shouldn't have the soft-brick problem that rM2's have with rm2fb not working. Also, recovery on a rM1 is much easier than a rM2.

SnorlaxYum commented 1 year ago

I tried according to the official doc. I connected to the wifi. You can see it's working.

reMarkable: ~/ curl https://bing.com    
<html><head><title>Object moved</title></head><body>
<h2>Object moved to <a href="https://www.bing.com:443/?toWww=1&amp;redig=68C29191AF1C4152AFE65C7422E7AF41">here</a>.</h2>
</body></html>

However, I got stuck on the following things. It seems the secure wget is not compatible with the rM (Segmentation fault happened).

reMarkable: ~/ wget http://toltec-dev.org/bootstrap                                                                                                                                                               
Connecting to toltec-dev.org (5.161.99.157:80)
saving to 'bootstrap'
bootstrap            100% |*******************************************************************************************************************************************************************|  8491  0:00:00 ETA
'bootstrap' saved
reMarkable: ~/ echo "04a28483286f88c5c7f39e352afb62adc57f6162a29fd7e124d832205bb0980e  bootstrap" | sha256sum -c && bash bootstrap                                                                                
bootstrap: OK
INFO:  Fetching secure wget
wget: connection closed prematurely
ERROR: Could not fetch wget, make sure you have a stable Wi-Fi connection
reMarkable: ~/ echo "04a28483286f88c5c7f39e352afb62adc57f6162a29fd7e124d832205bb0980e  bootstrap" | sha256sum -c && bash bootstrap                                                                                
bootstrap: OK
ERROR: '/home/root/.local/bin/wget' exists, but is not executable
ERROR: You may need to delete it and try again.
reMarkable: ~/ chmod +x .local/bin/wget                                                                                                                                                                           
reMarkable: ~/ echo "04a28483286f88c5c7f39e352afb62adc57f6162a29fd7e124d832205bb0980e  bootstrap" | sha256sum -c && bash bootstrap                                                                                
bootstrap: OK
INFO:  Bootstrapping Opkg
bootstrap: line 119:   576 Segmentation fault      wget --no-verbose "$entware_remote/opkg" --output-document "$opkg_path"
ERROR: Could not fetch opkg, make sure you have a stable Wi-Fi connection
Eeems commented 1 year ago
bootstrap: OK
INFO:  Fetching secure wget
wget: connection closed prematurely
ERROR: Could not fetch wget, make sure you have a stable Wi-Fi connection

You'll want to delete /home/root/.local/bin/wget and try again. You pulled down a partial file, which will not run properly.

SnorlaxYum commented 1 year ago

Well, I think the network is just not that good in rM because that's the same result after multiple tries. I had to check the bootstrap thoroughly and find the wget url and do it in the scp way.

$ wget http://toltec-dev.org/thirdparty/bin/wget-v1.21.1 && scp wget-v1.21.1 root@remarkable:/home/root/.local/bin/wget
--2023-03-24 11:32:20--  http://toltec-dev.org/thirdparty/bin/wget-v1.21.1
Resolving toltec-dev.org (toltec-dev.org)... 5.161.99.157, 2a01:4ff:f0:471a::1
Connecting to toltec-dev.org (toltec-dev.org)|5.161.99.157|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 3115800 (3.0M) [application/octet-stream]
Saving to: ‘wget-v1.21.1’

wget-v1.21.1                                         100%[=====================================================================================================================>]   2.97M  2.19MB/s    in 1.4s    

2023-03-24 11:32:23 (2.19 MB/s) - ‘wget-v1.21.1’ saved [3115800/3115800]

wget-v1.21.1                                                                                                                                                                     100% 3043KB 998.8KB/s   00:03    
$ ssh root@remarkable
reMarkable
╺━┓┏━╸┏━┓┏━┓   ┏━╸┏━┓┏━┓╻ ╻╻╺┳╸┏━┓┏━┓
┏━┛┣╸ ┣┳┛┃ ┃   ┃╺┓┣┳┛┣━┫┃┏┛┃ ┃ ┣━┫┗━┓
┗━╸┗━╸╹┗╸┗━┛   ┗━┛╹┗╸╹ ╹┗┛ ╹ ╹ ╹ ╹┗━┛
reMarkable: ~/ chmod +x .local/bin/wget                                                                                                                                                                           
reMarkable: ~/ echo "04a28483286f88c5c7f39e352afb62adc57f6162a29fd7e124d832205bb0980e  bootstrap" | sha256sum -c && bash bootstrap                                                                                
bootstrap: OK
INFO:  Bootstrapping Opkg
2023-03-24 03:33:52 URL:https://bin.entware.net/armv7sf-k3.2/installer/opkg [752476/752476] -> "/home/root/.local/bin/opkg" [1]
2023-03-24 03:33:57 URL:https://toltec-dev.org/stable/rmall/toltec-bootstrap_0.2.2-1_rmall.ipk [6667/6667] -> "/tmp/toltec-bootstrap_0.2.2-1_rmall.ipk" [1]
INFO:  Installing Toltec and Entware
Mounting '/home/root/.entware' over '/opt'
Created symlink /etc/systemd/system/local-fs.target.wants/opt.mount → /lib/systemd/system/opt.mount.
Downloading https://bin.entware.net/armv7sf-k3.2/Packages.gz
Updated list of available packages in /opt/var/opkg-lists/entware
Downloading https://toltec-dev.org/stable/rmall/Packages.gz
Updated list of available packages in /opt/var/opkg-lists/toltec-rmall
Downloading https://toltec-dev.org/stable/rm1/Packages.gz
Updated list of available packages in /opt/var/opkg-lists/toltec-rm1
Installing entware-opt (227000-3) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/entware-opt_227000-3_all.ipk
Installing libgcc (8.4.0-11) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/libgcc_8.4.0-11_armv7-3.2.ipk
Installing libc (2.27-11) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/libc_2.27-11_armv7-3.2.ipk
Installing libssp (8.4.0-11) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/libssp_8.4.0-11_armv7-3.2.ipk
Installing libpthread (2.27-11) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/libpthread_2.27-11_armv7-3.2.ipk
Installing librt (2.27-11) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/librt_2.27-11_armv7-3.2.ipk
Installing libstdcpp (8.4.0-11) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/libstdcpp_8.4.0-11_armv7-3.2.ipk
Installing entware-release (1.0-2) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/entware-release_1.0-2_all.ipk
Installing zoneinfo-asia (2022g-1) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/zoneinfo-asia_2022g-1_armv7-3.2.ipk
Installing zoneinfo-europe (2022g-1) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/zoneinfo-europe_2022g-1_armv7-3.2.ipk
Installing findutils (4.9.0-1) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/findutils_4.9.0-1_armv7-3.2.ipk
Installing terminfo (6.4-1) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/terminfo_6.4-1_armv7-3.2.ipk
Installing libpcre2 (10.37-2) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/libpcre2_10.37-2_armv7-3.2.ipk
Installing grep (3.8-2) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/grep_3.8-2_armv7-3.2.ipk
Installing locales (2.27-9) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/locales_2.27-9_armv7-3.2.ipk
Installing opkg (2022-02-24-d038e5b6-1) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/opkg_2022-02-24-d038e5b6-1_armv7-3.2.ipk
Installing entware-upgrade (1.0-1) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/entware-upgrade_1.0-1_all.ipk
Configuring libgcc.
Configuring libc.
Configuring libssp.
Configuring libpthread.
Configuring librt.
Configuring terminfo.
Configuring libpcre2.
Configuring grep.
Configuring locales.
Entware uses separate locale-archive file independent from main system
Creating locale archive /opt/usr/lib/locale/locale-archive
Adding en_EN.UTF-8
Adding ru_RU.UTF-8
You can download locale sources from http://bin.entware.net/other/i18n_glib227.tar.gz
You can add new locales to Entware using /opt/bin/localedef.new
Configuring entware-upgrade.
Upgrade operations are not required.
Configuring opkg.
Configuring zoneinfo-europe.
Configuring zoneinfo-asia.
Configuring libstdcpp.
Configuring entware-release.
Configuring findutils.
Configuring entware-opt.
Installing toltec-base (1.1-1) to root...
Downloading https://toltec-dev.org/stable/rm1/toltec-base_1.1-1_rm1.ipk
Installing bash-completion (2.11-3) to root...
Downloading https://toltec-dev.org/stable/rmall/bash-completion_2.11-3_rmall.ipk
Installing toltec-completion (0.3.1-1) to root...
Downloading https://toltec-dev.org/stable/rmall/toltec-completion_0.3.1-1_rmall.ipk
Installing coreutils (9.1-1) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/coreutils_9.1-1_armv7-3.2.ipk
Installing coreutils-tsort (9.1-1) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/coreutils-tsort_9.1-1_armv7-3.2.ipk
Installing toltec-base (1.1-1) to root...
Installing toltec-bootstrap (0.2.2-1) to root...
Downloading https://toltec-dev.org/stable/rmall/toltec-bootstrap_0.2.2-1_rmall.ipk
Installing rm2fb-client (1:0.0.30-1) to root...
Downloading https://toltec-dev.org/stable/rm1/rm2fb-client_1_0.0.30-1_rm1.ipk
Installing xochitl (0.0.0-14) to root...
Downloading https://toltec-dev.org/stable/rmall/xochitl_0.0.0-14_rmall.ipk
Installing display (1:0.0.30-1) to root...
Downloading https://toltec-dev.org/stable/rm1/display_1_0.0.30-1_rm1.ipk
Installing remarkable-splash (1.0-5) to root...
Downloading https://toltec-dev.org/stable/rmall/remarkable-splash_1.0-5_rmall.ipk
Installing open-remarkable-shutdown (1.0-1) to root...
Downloading https://toltec-dev.org/stable/rmall/open-remarkable-shutdown_1.0-1_rmall.ipk
Installing ca-certificates (20211016-1) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/ca-certificates_20211016-1_all.ipk
Installing wget-ssl (1.21.3-2) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/wget-ssl_1.21.3-2_armv7-3.2.ipk
Installing libpcre (8.45-3) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/libpcre_8.45-3_armv7-3.2.ipk
Installing zlib (1.2.13-1) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/zlib_1.2.13-1_armv7-3.2.ipk
Installing libatomic (8.4.0-11) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/libatomic_8.4.0-11_armv7-3.2.ipk
Installing libopenssl (3.0.8-2a) to root...
Downloading https://bin.entware.net/armv7sf-k3.2/libopenssl_3.0.8-2a_armv7-3.2.ipk
Configuring libatomic.
Configuring coreutils.
Configuring coreutils-tsort.
Configuring bash-completion.
Bash completions should take affect on next login.
To apply them immediately, run
 $ source /etc/profile.d/bash_completion.sh
Configuring toltec-completion.
Configuring xochitl.
Created symlink /etc/systemd/system/sync.service → /dev/null.
Created symlink /etc/systemd/system/multi-user.target.wants/manual-sync.service → /etc/systemd/system/manual-sync.service.
Configuring display.
Configuring rm2fb-client.
Configuring remarkable-splash.
Configuring open-remarkable-shutdown.
Configuring toltec-base.
Disabling usb1 network device to avoid long boots
Created symlink /etc/systemd/system/sys-subsystem-net-devices-usb1.device → /dev/null.
Configuring toltec-bootstrap.
Please restart your SSH session or run 'exec bash --login' to use Toltec
Configuring libpcre.
Configuring ca-certificates.
Configuring zlib.
Configuring libopenssl.
Configuring wget-ssl.
Package toltec-bootstrap (0.2.2-1) installed in root is up to date.
INFO:  After each system upgrade, run 'toltecctl reenable' to re-enable Toltec
reMarkable: ~/ exec bash --login                                                                                                                                                                                  
reMarkable: ~/ opkg install draft
Installing draft (0.2.0-21) to root...
Downloading https://toltec-dev.org/stable/rmall/draft_0.2.0-21_rmall.ipk
Configuring draft.

Run the following command(s) to use draft as your launcher
$ systemctl disable --now xochitl
$ systemctl enable --now draft

reMarkable: ~/ systemctl disable --now xochitl && systemctl enable --now draft                                                                                                                                    
Removed /etc/systemd/system/launcher.service.
Removed /etc/systemd/system/multi-user.target.wants/xochitl.service.
Created symlink /etc/systemd/system/launcher.service → /lib/systemd/system/draft.service.
Created symlink /etc/systemd/system/multi-user.target.wants/draft.service → /lib/systemd/system/draft.service.
reMarkable: ~/ ls /etc/draft                                                                                                                                                                                      
icons          shutdown       xochitl.draft
reMarkable: ~/ ls /etc/draft/icons                                                                                                                                                                                
power.png    xochitl.png
reMarkable: ~/ rm -rf /etc/draft                                                                                                                                                                                  
reMarkable: ~/ cp -r draft /etc/draft                                                                                                                                                                             
reMarkable: ~/ systemctl restart draft                                                                                                                                              
reMarkable: ~/ logout
Connection to 10.11.99.1 closed.

Anyway it's working. I just replaced the config with my previous version where I had specied the path to the installed KOReader. Awesome work, thank you bro~

SnorlaxYum commented 1 year ago

The only thing that still doesn't work, is button-capture. I held and held, nothing happened.

Eeems commented 1 year ago

You might be more interested in remux or oxide as an alternative to draft.

SnorlaxYum commented 1 year ago

Yep, I guess