Vim4 Ubuntu 20.04

Hello, Do you have any suggestions to fix the error with this undefined reference? It seems to be related to this repository, but I wasn’t able to compile it successfully on vim4.

@w407022008 Please try to apply the patch to fenix then rebuild the server image and try again.

diff --git a/config/boards/VIM4.conf b/config/boards/VIM4.conf
index 3854d68f..c4e16ca3 100644
--- a/config/boards/VIM4.conf
+++ b/config/boards/VIM4.conf
@@ -260,10 +260,10 @@ install_deb_packages_platform() {
                return 0
        fi
 
-       if [ "$LINUX" == "5.4" ]; then
-               info_msg "Installing mali-debs package ..."
-               install_deb_chroot $BUILD_DEBS/$VERSION/$KHADAS_BOARD/mali-debs/${GPU_PLATFORM}/*.deb
-       fi
+#      if [ "$LINUX" == "5.4" ]; then
+#              info_msg "Installing mali-debs package ..."
+#              install_deb_chroot $BUILD_DEBS/$VERSION/$KHADAS_BOARD/mali-debs/${GPU_PLATFORM}/*.deb
+#      fi
 
        if [ "$LINUX" == "5.4" ] && [ "$DISTRIBUTION" == "Ubuntu" ]; then
                info_msg "Installing OPTEE userspace package..."

Ok, looks like I just need to comment out the mali-debs package.
I have built it with :

#6 VIM4
#1 uboot
#1 Ubuntu
#2 focal 20.04
#5 gnome
#1 emmc
Y compress image
Y generate raw
make
enter as default for all

I got the vim4-ubuntu-20.04-gnome-linux-5.4-fenix-1.0.11-220705-emmc-develop.raw.img file and *.xz file in /build/images.
So, could you pls tell me how should i install it on vim4? by using the aml-burn-tool look like $ aml-burn-tool -b VIM4 -i /path/to/image ?
Could i install it directly via TypeC or the only way that install it in TF card first?

I use oowow on sd and and just copy it to the dumps/download folder for emmc install. Or if you are going to run it off a SD or USB SSD drive Pi imager works the best and that is on a Ubuntu 20.04 machine.

recommend local files copy it to the dumps/
dumps/download - for auto downloads

for common situation oowow already inside VIM4 board

how-to write custom image to VIM4

  • copy your image into any removable storage SD / USB Flash , etc (formatted by exfat or ext234 or fat)
  • start oowow by press FUNCTION + RESET
  • exit from wizard
  • plug removable storage with image
  • choose this image to write by menu -> write into emmc and up to … mounts

its just one example i will write man about other ways soon

2 Likes

Okay, thank you, I will try it that way.

Ok, thanks @foxsquirrel . Have you encountered this error when compiling anything, when you use custom image? The problem seems to be a linker setup issue with the official image.

/usr/bin/ld: /lib/aarch64-linux-gnu/libSDL2-2.0.so.0: undefined reference to `wl_egl_window_resize'
/usr/bin/ld: /lib/aarch64-linux-gnu/libSDL2-2.0.so.0: undefined reference to `wl_egl_window_destroy'
/usr/bin/ld: /lib/aarch64-linux-gnu/libSDL2-2.0.so.0: undefined reference to `wl_egl_window_create'
/usr/bin/ld: /lib/aarch64-linux-gnu/libSDL2-2.0.so.0: undefined reference to `wl_egl_window_get_attached_size'

Ok, pretty good. I will have a try later.

No.
fenix should work perfectly.

in your fenix directory

$ git pull

At least make sure its all up to date before starting out.

Are you using Ubuntu 20.04 on x86 ?

1 Like

Yes, I’m using Ubuntu20.04 VMware base on x86 Windows 10.
I have already built one. Could you pls tell me how could i copy it into sd card? I have formatted a 128G sd card by vfat. So what should i do the next? by this dd if=<image.img> of=<dev> bs=32M right? :joy: sorry i have poor knowledge about Linux.

Command (m for help): p
Disk /dev/sdb: 119.26 GiB, 128043712512 bytes, 250085376 sectors
Disk model: Storage Device  
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0xee4d5643

Device     Boot Start       End   Sectors   Size Id Type
/dev/sdb1        4096 250085375 250081280 119.3G 83 Linux

That might be why those files are missing.

Do you have a x86 box that can run Ubuntu 20.04 natively.

To install I would try it per these instructions.

Okay, let me explain my situation. I compiled the latest fenix on a ubuntu 20.04 VM. But I haven’t copied it onto vim4 yet though, because I really don’t know how to do it. Currently I am using the official ubuntu20.04-server image downloaded from oowow. libSDL linker is also the official version of the OS that is having trouble. I’ve tried debugging in various ways, but it didn’t solve the issue, so I’d like to recompile the custome image. Since I haven’t done this, I don’t know how to burn the compiled image to the sdcard and subsequently overwrite the OS in emmc. Could you give me a more detailed steps on how to do this?

u can use common way and copy files via file-manager

PS: dd not for copy files

PSS: if u prefer command line cp can help your

1 Like

Ok the installation worked, but I found that I couldn’t login to the GUI interface because it would flash. I checked the status of lightdm.service and it shows that the startup failed due to D-Bus connection failure. Do you have any ideas to fix it please?

khadas@Khadas:~/Downloads$ systemctl status lightdm.service 
● lightdm.service - Light Display Manager
     Loaded: loaded (/lib/systemd/system/lightdm.service; static; vendor preset: enabled)
     Active: failed (Result: exit-code) since Thu 2022-07-07 17:33:29 CEST; 3min 3s ago
       Docs: man:lightdm(1)
    Process: 30310 ExecStartPre=/bin/sh -c [ "$(basename $(cat /etc/X11/default-display-manager 2>/dev/null))" = "li>

Jul 07 17:33:29 Khadas systemd[1]: lightdm.service: Scheduled restart job, restart counter is at 5.
Jul 07 17:33:29 Khadas systemd[1]: Stopped Light Display Manager.
Jul 07 17:33:29 Khadas systemd[1]: lightdm.service: Start request repeated too quickly.
Jul 07 17:33:29 Khadas systemd[1]: lightdm.service: Failed with result 'exit-code'.
Jul 07 17:33:29 Khadas systemd[1]: Failed to start Light Display Manager.
khadas@Khadas:~/Downloads$ lightdm --test-mode --debug 
[+0.00s] DEBUG: Logging to /home/khadas/.cache/lightdm/log/lightdm.log
[+0.00s] DEBUG: Starting Light Display Manager 1.30.0, UID=1000 PID=31013
[+0.00s] DEBUG: Loading configuration dirs from /usr/share/lightdm/lightdm.conf.d
[+0.00s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-disable-guest.conf
[+0.00s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-disable-log-backup.conf
[+0.00s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-greeter-wrapper.conf
[+0.00s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-guest-wrapper.conf
[+0.00s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-ubuntu.conf
[+0.00s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/50-xserver-command.conf
[+0.00s] DEBUG: Loading configuration from /usr/share/lightdm/lightdm.conf.d/60-lightdm-gtk-greeter.conf
[+0.00s] DEBUG: Loading configuration dirs from /usr/local/share/lightdm/lightdm.conf.d
[+0.00s] DEBUG: Loading configuration dirs from /etc/xdg/lightdm/lightdm.conf.d
[+0.00s] DEBUG: Loading configuration from /etc/lightdm/lightdm.conf
[+0.00s] DEBUG: Running in user mode
[+0.00s] DEBUG: Registered seat module local
[+0.00s] DEBUG: Registered seat module xremote
[+0.00s] DEBUG: Using D-Bus name org.freedesktop.DisplayManager
[+0.01s] DEBUG: _g_io_module_get_default: Found default implementation local (GLocalVfs) for ?gio-vfs?
[+0.02s] DEBUG: Monitoring logind for seats
[+0.02s] DEBUG: New seat added from logind: seat0
[+0.02s] DEBUG: Seat seat0: Loading properties from config section Seat:*
[+0.02s] DEBUG: Seat seat0: Starting
[+0.02s] DEBUG: Seat seat0: Creating greeter session
[+0.02s] DEBUG: Loading users from org.freedesktop.Accounts
[+0.02s] DEBUG: User /org/freedesktop/Accounts/User1000 added
[+0.02s] DEBUG: Seat seat0: Creating display server of type x
[+0.02s] DEBUG: posix_spawn avoided (fd close requested) 
[+0.03s] DEBUG: Seat seat0: Starting local X display
[+0.03s] DEBUG: XServer 0: Logging to /home/khadas/.cache/lightdm/log/x-0.log
[+0.03s] DEBUG: XServer 0: Writing X server authority to /home/khadas/.cache/lightdm/run/root/:0
[+0.03s] DEBUG: XServer 0: Launching X Server
[+0.03s] DEBUG: Launching process 31018: /usr/bin/X -core :0 -seat seat0 -auth /home/khadas/.cache/lightdm/run/root/:0 -nolisten tcp
[+0.03s] DEBUG: XServer 0: Waiting for ready signal from X server :0
Failed to get D-Bus connection