Page MenuHomePhabricator

FreeBSD: E-0.24.2 + EFL-1.25.1 + wayland + drm.
Open, Incoming QueuePublic

Description

Hello world :-)

I came back to EFL-1.25.1 on FreeBSD in order to see if it works with WAYLAND here already. However, when wl and drm options are enabled the Meson configuration fails. With wl enabled build is okay, so there must be a problem with drmswitch. eeze is always disabled on FreeBSD.

Build started at 2020-12-14T22:17:23.809261
Main binary: /usr/local/bin/python3.7
Build Options: -Dsystemd=false -Deeze=false -Davahi=false -Defl-one=true -Dbuild-examples=true -Dfribidi=true -Dcrypto=openssl -Dgstreamer=true -Dharfbuzz=true -Dglib=false -Dlua-interpreter=luajit -Dnls=true -Dopengl=full -Dphysics=true -Dpulseaudio=true -Dsdl=false -Dv4l2=true -Dvnc-server=false -Dwl=true -Ddrm=true -Decore-imf-loaders-disabler=ibus -Devas-loaders-disabler=json,jp2k,avif -Dbindings=cxx -Dprefix=/usr/local -Dinfodir=share/info -Dmandir=man -Dbuildtype=release -Dstrip=True
Python system: FreeBSD
The Meson build system
Version: 0.55.3
Source dir: /usr/local/tmpfs/portswrkdir/usr/ports/devel/efl-1.25.1/work/efl-1.25.1
Build dir: /usr/local/tmpfs/portswrkdir/usr/ports/devel/efl-1.25.1/work/efl-1.25.1/_build
Build type: native build
None of 'PKG_CONFIG_PATH' are defined in the environment, not changing global flags.
None of 'PKG_CONFIG_PATH' are defined in the environment, not changing global flags.
Project name: efl
Project version: 1.25.1
Using 'CC' from environment with value: 'cc'
Using 'CFLAGS' from environment with value: '-O2 -pipe  -I/usr/local/include/libepoll-shim -DLIBICONV_PLUG -fstack-protector-strong -fno-strict-aliasing '
Using 'LDFLAGS' from environment with value: ' -L/usr/local/lib -lepoll-shim  -fstack-protector-strong '
Using 'CPPFLAGS' from environment with value: '-I/usr/local/include -DLIBICONV_PLUG'
None of 'CC_LD' are defined in the environment, not changing global flags.
Sanity testing C compiler: cc
Is cross compiler: False.
None of 'CC_LD' are defined in the environment, not changing global flags.
Sanity check compiler command line: cc /usr/local/tmpfs/portswrkdir/usr/ports/devel/efl-1.25.1/work/efl-1.25.1/_build/meson-private/sanitycheckc.c -o /usr/local/tmpfs/portswrkdir/usr/ports/devel/efl-1.25.1/work/efl-1.25.1/_build/meson-private/sanitycheckc.exe -O2 -pipe -I/usr/local/include/libepoll-shim -DLIBICONV_PLUG -fstack-protector-strong -fno-strict-aliasing -I/usr/local/include -DLIBICONV_PLUG -pipe -D_FILE_OFFSET_BITS=64 -L/usr/local/lib -lepoll-shim

(..)
 
Library Xcursor found: YES
Running compile:
Working directory:  /usr/local/tmpfs/portswrkdir/usr/ports/devel/efl-1.25.1/work/efl-1.25.1/_build/meson-private/tmpb_srtp1p
Command line:  cc -I/usr/local/include/libepoll-shim -I/usr/local/include /usr/local/tmpfs/portswrkdir/usr/ports/devel/efl-1.25.1/work/efl-1.25.1/_build/meson-private/tmpb_srtp1p/testfile.c -o /usr/local/tmpfs/portswrkdir/usr/ports/devel/efl-1.25.1/work/efl-1.25.1/_build/meson-private/tmpb_srtp1p/output.obj -pipe -c -D_THREAD_SAFE -pthread -O2 -fstack-protector-strong -fno-strict-aliasing -DLIBICONV_PLUG -D_FILE_OFFSET_BITS=64 -O0 

Code:
 
        #include <X11/Xcursor/Xcursor.h>
        int main(void) {
            /* If it's not defined as a macro, try to use as a symbol */
            #ifndef XcursorSupportsARGB
                XcursorSupportsARGB;
            #endif
            return 0;
        }
Compiler stdout:
 
Compiler stderr:
 /usr/local/tmpfs/portswrkdir/usr/ports/devel/efl-1.25.1/work/efl-1.25.1/_build/meson-private/tmpb_srtp1p/testfile.c:6:17: warning: expression result unused [-Wunused-value]
                XcursorSupportsARGB;
                ^~~~~~~~~~~~~~~~~~~
1 warning generated.

Header <X11/Xcursor/Xcursor.h> has symbol "XcursorSupportsARGB" with dependencies x11, xcb: YES 
Message: ecore_fb disabled!
Dependency wayland-client found: YES 1.18.0 (cached)
Pkg-config binary for MachineChoice.HOST is cached.
Determining dependency 'wayland-server' with pkg-config executable '/usr/local/bin/pkgconf'
PKG_CONFIG_PATH: 
Called `/usr/local/bin/pkgconf --modversion wayland-server` -> 0
1.18.0
PKG_CONFIG_PATH: 
Called `/usr/local/bin/pkgconf --cflags wayland-server` -> 0
-I/usr/local/include -I/usr/local/include/libepoll-shim
PKG_CONFIG_PATH: 
Called `/usr/local/bin/pkgconf wayland-server --libs` -> 0
-L/usr/local/lib -lwayland-server
PKG_CONFIG_PATH: 
Called `/usr/local/bin/pkgconf wayland-server --libs` -> 0
-L/usr/local/lib -lwayland-server
None of 'PKG_CONFIG_PATH' are defined in the environment, not changing global flags.
Run-time dependency wayland-server found: YES 1.18.0
Pkg-config binary for MachineChoice.HOST is cached.
Determining dependency 'xkbcommon' with pkg-config executable '/usr/local/bin/pkgconf'
PKG_CONFIG_PATH: 
Called `/usr/local/bin/pkgconf --modversion xkbcommon` -> 0
1.0.1
PKG_CONFIG_PATH: 
Called `/usr/local/bin/pkgconf --cflags xkbcommon` -> 0
-I/usr/local/include
PKG_CONFIG_PATH: 
Called `/usr/local/bin/pkgconf xkbcommon --libs` -> 0
-L/usr/local/lib -lxkbcommon
PKG_CONFIG_PATH: 
Called `/usr/local/bin/pkgconf xkbcommon --libs` -> 0
-L/usr/local/lib -lxkbcommon
None of 'PKG_CONFIG_PATH' are defined in the environment, not changing global flags.
Run-time dependency xkbcommon found: YES 1.0.1
Dependency wayland-client found: YES 1.18.0 (cached)
Dependency wayland-server found: YES 1.18.0 (cached)
Dependency xkbcommon found: YES 1.0.1 (cached)
Message: ecore_sdl disabled!
Message: ecore_buffer disabled!

src/lib/elput/meson.build:1:0: ERROR: Unknown variable "eeze".

The same problem of ignoring disabled eeze (ERROR: Unknown variable "eeze".) with:

  • src/lib/ecore_drm2/meson.build.
  • src/modules/ecore_evas/engines/drm/meson.build.

Afther removing the eeze from those files following problems need fixing:

  • src/modules/ecore_evas/engines/drm/meson.build:6:2: ERROR: Unknown variable "engine_gl_drm".
cederom created this task.Dec 14 2020, 1:37 PM
cederom added a project: Restricted Project.
cederom renamed this task from FreeBSD: wayland+drm meson eeze problem. to FreeBSD: EFL-1.25.1 wayland+drm meson eeze problem..Dec 14 2020, 1:38 PM
cederom updated the task description. (Show Details)
cederom renamed this task from FreeBSD: EFL-1.25.1 wayland+drm meson eeze problem. to FreeBSD: EFL-1.25.1 wayland+drm..Dec 14 2020, 1:57 PM
cederom updated the task description. (Show Details)
cederom added a comment.EditedDec 16 2020, 8:07 AM

I have created a separate report for DRM enforcing EEZE although this EEZE is explicitly disabled with meson switch: https://phab.enlightenment.org/T8867

Update 1: I got patch that fixes the EEZE build on FreeBSD thank you! :-)

cederom added a comment.EditedDec 16 2020, 8:10 AM

Replacing [engine_gl_drm] with [gl_deps] does seem to fix the meson issue [1] :-)

Update 1: I have to finally get familiar with your local git environment and see how master builds.. no sense to work 1.25.1 when patches may be already out there :-)

Update 2: ugh, those patches does not seem to be in master yet..

[1] https://www.mail-archive.com/enlightenment-devel@lists.sourceforge.net/msg106626.html

After fixing the EEZE build problems, following linux related problems occur for WL+DRM build on FreeBSD. Are these really necessary? Can they be provided with EFL? Should we add them to FreeBSD?

  1. ../src/lib/elput/elput_private.h:18:11: fatal error: 'linux/vt.h' file not found.
  2. ../src/lib/elput/elput_private.h:19:11: fatal error: 'linux/kd.h' file not found
  3. ../src/lib/elput/elput_private.h:20:11: fatal error: 'linux/major.h' file not found

When I copy-paste those headers build continues.

cederom added a comment.EditedDec 16 2020, 9:24 AM

Now I have this: ../src/modules/ecore_evas/engines/drm/ecore_evas_drm.c:23:11: fatal error: 'Evas_Engine_GL_Drm.h' file not found. I guess that header is part of EFL?

Update 1: From the meson build log:

Message: ecore_wayland disabled!
Message: ecore_drm disabled!

Update 2:
../src/modules/ecore_evas/engines/drm/ecore_evas_drm.c:23:

#ifdef BUILD_ECORE_EVAS_GL_DRM
# include <Evas_Engine_GL_Drm.h>
# include <dlfcn.h>
#endif

Update 3:
This header file is present in within the source code:

find . -iname "evas_engine_gl_drm.h"
./src/modules/evas/engines/gl_drm/Evas_Engine_GL_Drm.h

Updating ../src/modules/ecore_evas/engines/drm/ecore_evas_drm.c:23 to:

#ifdef BUILD_ECORE_EVAS_GL_DRM
# include <src/modules/evas/engines/gl_drm/Evas_Engine_GL_Drm.h>
# include <dlfcn.h>
#endif

Does seems to fix the include problem. Is this some sort of meson configuration issue? :-)

After this one all stuff builds fine. Time to test on a local machine how it works :-)

cederom renamed this task from FreeBSD: EFL-1.25.1 wayland+drm. to FreeBSD: E-0.24.2 + EFL-1.25.1 + wayland + drm..Dec 16 2020, 10:21 AM
cederom added a comment.EditedDec 16 2020, 10:24 AM

Now its time to fight some bugs in Enlightenment :-) It recognizes EFL to have Wayland support which is a great success because that was a blocker. Some new issues shows up when building E with Wayland support :-)

First one is `../src/bin/e_gadget_runner.c:

../src/bin/e_gadget_runner.c:149:4: warning: implicit declaration of function 'unshare' is invalid in C99 [-Wimplicit-function-declaration]
   unshare(CLONE_NEWPID);
   ^
../src/bin/e_gadget_runner.c:149:12: error: use of undeclared identifier 'CLONE_NEWPID'
   unshare(CLONE_NEWPID);
           ^
../src/bin/e_gadget_runner.c:154:4: warning: implicit declaration of function 'setns' is invalid in C99 [-Wimplicit-function-declaration]
   setns(ns_fd, CLONE_NEWPID);
   ^
../src/bin/e_gadget_runner.c:154:17: error: use of undeclared identifier 'CLONE_NEWPID'
   setns(ns_fd, CLONE_NEWPID);
                ^

Update 1: These seems to be Linux only syscalls [1]! Would be really good not to use them at all and use some generic POSIX process management please? :-)

Update 2: So far I have solved that problem by wrapping with #if defined(__linux__) do it only builds on Linux as it is Linux only syscall. I could not find clone() anywhere so probably these two Linux syscalls are only to adjust process parameters on Linux and wihout them all should work fine? PLEASE CONFIRM :-)

#if defined(__linux__)
    unshare(CLONE_NEWPID);
#endif

#if defined(__linux__)
    setns(ns_fd, CLONE_NEWPID);
#endif

[1] https://lists.freebsd.org/pipermail/freebsd-hackers/2010-June/032103.html

cederom added a comment.EditedDec 16 2020, 11:17 AM

Some more problems in src/modules/xwayland/dnd.c:

../src/modules/xwayland/dnd.c:463:20: warning: implicit declaration of function 'socketpair' is invalid in C99 [-Wimplicit-function-declaration]
               if (socketpair(AF_UNIX, (SOCK_STREAM | SOCK_CLOEXEC), 0, fds) != 0)
                   ^
../src/modules/xwayland/dnd.c:463:41: error: use of undeclared identifier 'SOCK_STREAM'
               if (socketpair(AF_UNIX, (SOCK_STREAM | SOCK_CLOEXEC), 0, fds) != 0)
                                        ^
../src/modules/xwayland/dnd.c:463:55: error: use of undeclared identifier 'SOCK_CLOEXEC'
               if (socketpair(AF_UNIX, (SOCK_STREAM | SOCK_CLOEXEC), 0, fds) != 0)
                                                      ^
../src/modules/xwayland/dnd.c:463:31: error: use of undeclared identifier 'AF_UNIX'
               if (socketpair(AF_UNIX, (SOCK_STREAM | SOCK_CLOEXEC), 0, fds) != 0)
                              ^
6 warnings and 3 errors generated.

Update 1: This can be easily fixed by adding:

#if defined(__FreeBSD__)
#include <sys/types.h>
#include <sys/socket.h>
#endif
cederom added a comment.EditedDec 16 2020, 11:20 AM

Then we have src/modules/wl_drm/e_mod_main.c:

../src/modules/wl_drm/e_mod_main.c:786:17: error: use of undeclared identifier 'KEY_F1'
       (code >= KEY_F1) && (code <= KEY_F8))
                ^
../src/modules/wl_drm/e_mod_main.c:786:37: error: use of undeclared identifier 'KEY_F8'
       (code >= KEY_F1) && (code <= KEY_F8))
                                    ^
../src/modules/wl_drm/e_mod_main.c:791:22: error: use of undeclared identifier 'KEY_F1'
        vt = (code - KEY_F1 + 1);
                     ^

Update 1: This can be fixed with:

#if defined(__FreeBSD__)
#include <linux/input-event-codes.h>
#endif

Hello @Peter2121 can you please take a look and give some hints on how to evade clone / unshare / setns which are Linux only syscalls? Details above :-)

Only this seems to be left to run E + EFL on Wayland on FreeBSD :-)

With the changes proposed above the package builds, it contains several modules, but it cannot connect to input and cannot open a device what ends in not being able to create a compositor. As I have mentioned above sway and wayfire works fine here so we need to work more :-)

Any hints welcome :-)

ESTART: 0.00001 [0.00001] - Begin Startup
ESTART: 0.00014 [0.00013] - Signal Trap
ESTART: 0.00019 [0.00006] - Signal Trap Done
ESTART: 0.00020 [0.00000] - Eina Init
ESTART: 0.00150 [0.00131] - Eina Init Done
ESTART: 0.00151 [0.00001] - Determine Prefix
ESTART: 0.00187 [0.00035] - Determine Prefix Done
ESTART: 0.00197 [0.00011] - Environment Variables
ESTART: 0.00202 [0.00005] - Environment Variables Done
ESTART: 0.00203 [0.00001] - Parse Arguments
ESTART: 0.00203 [0.00001] - Parse Arguments Done
ESTART: 0.00204 [0.00000] - Eet Init
ESTART: 0.00210 [0.00006] - Eet Init Done
ESTART: 0.00211 [0.00001] - Ecore Init
ESTART: 0.19513 [0.19302] - Ecore Init Done
ESTART: 0.19514 [0.00001] - E Comp Canvas Intercept Init
ESTART: 0.33647 [0.14134] - E Comp Canvas Intercept Init Done
ESTART: 0.33652 [0.00005] - EFX Init
ESTART: 0.33653 [0.00001] - EFX Init Done
ESTART: 0.33653 [0.00000] - EIO Init
ESTART: 0.38315 [0.04662] - EIO Init Done
ESTART: 0.38317 [0.00003] - Ecore Event Handlers
ESTART: 0.38318 [0.00001] - Ecore Event Handlers Done
ESTART: 0.38318 [0.00000] - Ecore_File Init
ESTART: 0.38319 [0.00001] - Ecore_File Init Done
ESTART: 0.38319 [0.00000] - Ecore_Con Init
ESTART: 0.38320 [0.00000] - Ecore_Con Init Done
ESTART: 0.38320 [0.00000] - Ecore_Ipc Init
ESTART: 0.38320 [0.00000] - Ecore_Ipc Init Done
ESTART: 0.38323 [0.00003] - Ecore_Evas Init
ESTART: 0.38377 [0.00054] - Ecore_Evas Init Done
ESTART: 0.38379 [0.00001] - Elementary Init
ESTART: 0.40077 [0.01698] - Elementary Init Done
ESTART: 0.40078 [0.00002] - Emotion Init
ESTART: 0.40097 [0.00019] - Emotion Init Done
ESTART: 0.40103 [0.00006] - Ecore_Evas Engine Check
ESTART: 0.40105 [0.00001] - Ecore_Evas Engine Check Done
ESTART: 0.40105 [0.00001] - E Intl Init
ESTART: 0.40109 [0.00004] - E Intl Init Done
ESTART: 0.40109 [0.00001] - E_Alert Init
ESTART: 0.40110 [0.00000] - E_Alert Init Done
ESTART: 0.40110 [0.00000] - E Directories Init
ESTART: 0.40124 [0.00014] - E Directories Init Done
ESTART: 0.40125 [0.00001] - E_Filereg Init
ESTART: 0.40125 [0.00000] - E_Filereg Init Done
ESTART: 0.40125 [0.00000] - E_Config Init
ESTART: 0.40301 [0.00175] - E_Config Init Done
ESTART: 0.40302 [0.00002] - E_Env Init
ESTART: 0.40303 [0.00001] - E_Env Init Done
ESTART: 0.40304 [0.00001] - E Paths Init
ESTART: 0.40307 [0.00003] - E Paths Init Done
ESTART: 0.40308 [0.00000] - E_Precache
ESTART: 0.40319 [0.00012] - E_Precache Done
ESTART: 0.40323 [0.00004] - E_Ipc Init
ERR<44132>:e ../src/bin/e_ipc.c:38 e_ipc_init() XDG_RUNTIME_DIR of '/home/cd/.xdg' failed permissions check
## Copy & Paste the below (until EOF) into a terminal, then hit Enter

eina_btlog << EOF
/usr/local/lib/libeina.so.1	 0x800493d70 0x80044a000
/usr/local/lib/libeina.so.1	 0x800495496 0x80044a000
/usr/local/lib/libeina.so.1	 0x800495359 0x80044a000
/usr/local/bin/enlightenment	 0x34450b 0x200000
/usr/local/bin/enlightenment	 0x34b1db 0x200000
EOF

ESTART: 0.40469 [0.00146] - E_Ipc Init Done
ESTART: 0.40474 [0.00005] - E_Font Init
ESTART: 0.40478 [0.00004] - E_Font Init Done
ESTART: 0.40482 [0.00003] - E_Font Apply
ESTART: 0.40485 [0.00003] - E_Font Apply Done
ESTART: 0.40489 [0.00004] - E_Theme Init
ESTART: 0.40494 [0.00005] - E_Theme Init Done
ESTART: 0.40497 [0.00003] - E_Moveresize Init
ESTART: 0.40500 [0.00004] - E_Moveresize Init Done
ESTART: 0.40504 [0.00003] - E_Msgbus Init
ESTART: 0.40662 [0.00158] - E_Msgbus Init Done
ESTART: 0.40668 [0.00006] - Efreet Init
ESTART: 0.40672 [0.00004] - Efreet Init Done
ESTART: 0.40675 [0.00003] - E_Intl Post Init
PRECACHE: [0.00795] [/usr/local/share/elementary/themes/default.edj] DONE
PRECACHE: [0.00017] [XXX] DONE
PRECACHE: TOTAL [0.00824]
PRECACHE: SUM=6c2436d2, READS=3144
ESTART: 0.41154 [0.00479] - E_Intl Post Init Done
ESTART: 0.41158 [0.00004] - E_Configure Init
ESTART: 0.41169 [0.00011] - E_Configure Init Done
ESTART: 0.41170 [0.00001] - E_Actions Init
ESTART: 0.41197 [0.00027] - E_Actions Init Done
ESTART: 0.41200 [0.00004] - E_System Init
ESTART: 0.41444 [0.00243] - E_System Init Done
ESTART: 0.41450 [0.00007] - E_Powersave Init
ESTART: 0.41456 [0.00005] - E_Powersave Init Done
ESTART: 0.41459 [0.00004] - Screens Init
ESTART: 0.41462 [0.00003] - 	screens: client
ESTART: 0.41467 [0.00006] - E_Screensaver Init
ESTART: 0.41472 [0.00004] - 	screens: client volume
ESTART: 0.41475 [0.00004] - 	screens: win
ESTART: 0.41481 [0.00005] - Compositor Init
Enlightenment cannot initialize X Connection...
LOAD WL_WL MODULE
ERR<44132>:eina_safety ../src/lib/ecore_evas/ecore_evas.c:4493 ecore_evas_wayland_egl_new() safety check failed: new == NULL
## Copy & Paste the below (until EOF) into a terminal, then hit Enter

eina_btlog << EOF
/usr/local/lib/libeina.so.1	 0x800493d70 0x80044a000
/usr/local/lib/libeina.so.1	 0x800495496 0x80044a000
/usr/local/lib/libeina.so.1	 0x800495359 0x80044a000
/usr/local/lib/libeina.so.1	 0x8004aa8cc 0x80044a000
/usr/local/lib/libecore_evas.so.1	 0x800e95a66 0x800e75000
/usr/local/lib/libecore_evas.so.1	 0x800e994fa 0x800e75000
/usr/local/lib/enlightenment/modules/wl_wl/freebsd-x86_64-0.24.2/module.so	 0x8054170d2 0x805415000
/usr/local/bin/enlightenment	 0x357d0b 0x200000
/usr/local/bin/enlightenment	 0x2bbe3d 0x200000
/usr/local/bin/enlightenment	 0x34c287 0x200000
EOF

Could not create wayland canvas
LOAD WL_X11 MODULE
X11 connect failed!
LOAD WL_DRM MODULE
ERR<44132>:ecore_drm2 ../src/lib/ecore_drm2/ecore_drm2_device.c:606 ecore_drm2_device_open() Could not connect to input manager
## Copy & Paste the below (until EOF) into a terminal, then hit Enter

eina_btlog << EOF
/usr/local/lib/libeina.so.1	 0x800493d70 0x80044a000
/usr/local/lib/libeina.so.1	 0x800495496 0x80044a000
/usr/local/lib/libeina.so.1	 0x800495359 0x80044a000
/usr/local/lib/libecore_drm2.so.1	 0x80108223d 0x801076000
/usr/local/lib/ecore_evas/engines/drm/v-1.25/module.so	 0x8054643fd 0x805461000
/usr/local/lib/libecore_evas.so.1	 0x800e9633b 0x800e75000
/usr/local/lib/libecore_evas.so.1	 0x800e996b2 0x800e75000
/usr/local/lib/enlightenment/modules/wl_drm/freebsd-x86_64-0.24.2/module.so	 0x80543a258 0x805436000
/usr/local/bin/enlightenment	 0x357d0b 0x200000
/usr/local/bin/enlightenment	 0x2bbe3d 0x200000
/usr/local/bin/enlightenment	 0x34c287 0x200000
EOF

ERR<44132>:ecore_evas ../src/modules/ecore_evas/engines/drm/ecore_evas_drm.c:163 _ecore_evas_drm_init() Failed to open device
## Copy & Paste the below (until EOF) into a terminal, then hit Enter

eina_btlog << EOF
/usr/local/lib/libeina.so.1	 0x800493d70 0x80044a000
/usr/local/lib/libeina.so.1	 0x800495496 0x80044a000
/usr/local/lib/libeina.so.1	 0x800495359 0x80044a000
/usr/local/lib/ecore_evas/engines/drm/v-1.25/module.so	 0x8054646c9 0x805461000
/usr/local/lib/libecore_evas.so.1	 0x800e9633b 0x800e75000
/usr/local/lib/libecore_evas.so.1	 0x800e996b2 0x800e75000
/usr/local/lib/enlightenment/modules/wl_drm/freebsd-x86_64-0.24.2/module.so	 0x80543a258 0x805436000
/usr/local/bin/enlightenment	 0x357d0b 0x200000
/usr/local/bin/enlightenment	 0x2bbe3d 0x200000
/usr/local/bin/enlightenment	 0x34c287 0x200000
EOF

Could not create ecore_evas_drm canvas<<<< Enlightenment Error >>>>
Enlightenment cannot create a compositor.

E: Begin Shutdown Procedure!
ERR<44132>:e ../src/bin/e_msgbus.c:84 _e_msgbus_request_name_cb() Could not request bus name
## Copy & Paste the below (until EOF) into a terminal, then hit Enter

eina_btlog << EOF
/usr/local/lib/libeina.so.1	 0x800493d70 0x80044a000
/usr/local/lib/libeina.so.1	 0x800495496 0x80044a000
/usr/local/lib/libeina.so.1	 0x800495359 0x80044a000
/usr/local/bin/enlightenment	 0x3599af 0x200000
/usr/local/lib/libeldbus.so.1	 0x80099aae9 0x800979000
/usr/local/lib/libeldbus.so.1	 0x800991355 0x800979000
/usr/local/lib/libeldbus.so.1	 0x80098f2ef 0x800979000
/usr/local/lib/libeldbus.so.1	 0x80099247d 0x800979000
/usr/local/lib/libeldbus.so.1	 0x800999c21 0x800979000
/usr/local/lib/libeldbus.so.1	 0x800998556 0x800979000
/usr/local/lib/libeldbus.so.1	 0x80099350d 0x800979000
/usr/local/bin/enlightenment	 0x359a75 0x200000
/usr/local/bin/enlightenment	 0x34c527 0x200000
EOF

E - PID=43720, valgrind=0
WIFSTOPPED=0 WIFEXITED=1 WEXITSTATUS=101 stop_ptrace=0
Explici error exit from enlightenment
cederom added a subscriber: raster.Dec 16 2020, 5:37 PM

Allright it turns out that E/EFL when it comes to Wayland it hardcoded with Linux's systemd/logind/elogind. This sux :-) But there is an alternative called SEATD that is portable by design works already on FreeBSD and Linux and it meant as replacement to elogind.

I have reported as separate task making EFL/E to work with SEATD: https://phab.enlightenment.org/T8868.

elogind has similar DBus interface with one that consolekit2 uses. The latter is present in our ports, so maybe you should try it.

cederom added a comment.EditedDec 17 2020, 4:47 AM

Thank you @arrowdodger for the hint on ConsoleKit2 [ck]. I am a bit confused - is this elogind replacement? I have this installed already but this does not seem to solve my problem with E..

How about using WLROOTS [wl] + seatd that should provide good portability for both X11 and Wayland..?

[ck] https://github.com/ConsoleKit2/ConsoleKit2
[wl] https://github.com/swaywm/wlroots

Currently, the DRM implementation in EFL is coded to use Eeze for discovery of the drm card and other devices. Systemd or elogind is also a requirement currently. As I do not use *BSD, I would be unable to code support for that (as I cannot test it), however if you would like to provide patches then I would be happy to review.

The question is why don't we use WLROOTS and SEATD so the project gets portable and does not contain hard references to Linux only solutions like systemd/logind? If we had that solution Enligthenment would already work using Wayland both on Linux and FreeBSD :-)

Do you know these solutions? Is it a lot of work to add another WL glue (wlroots+seatd)? Any sort of estimate form experienced developer would be nice to know :-)

The question is why don't we use WLROOTS and SEATD so the project gets portable and does not contain hard references to Linux only solutions like systemd/logind? If we had that solution Enligthenment would already work using Wayland both on Linux and FreeBSD :-)

Do you know these solutions? Is it a lot of work to add another WL glue (wlroots+seatd)? Any sort of estimate form experienced developer would be nice to know :-)

We don't use wlroots because at the time of coding all of the EFL/E Wayland stuff, wlroots did not even exist. I have never heard of seatd until now, so unsure on that one.

No, I am not familiar with either of these, but it sounds like wlroots may conflict with the E implementation however I cannot say for sure as I have never looked into it.

we can;'t use wlroots because it also includes a renderer of its own and that would mean we drop our own (evas) and that would essentially kill off all of e as everything u see is rendered by evas. as long as you have your own renderer something like wlroots is pretty much a no-go. i haven't looked in DETAIL though so maybe there is some way to bypass using the wlroots renderer but then this spiders out to other bits we then can't use etc. etc. etc. and eventually we find we use very little of it ans spend a lot of effort in impedance mismatch handling.

Thank you @devilhorns @raster I have asked this question on wlroots github the best place to get quick and reliable answer if we can use wlroots and our own renderer :-)

https://github.com/swaywm/wlroots/issues/2557

After discussion on WLROOTS GitHub [1] is seems that LIBSEAT would be better ELOGIND replacement rather than using whole wlroots :-)

[1] https://github.com/swaywm/wlroots/issues/2557

FYI ... i'm very very very much against adding more dependencies. after decades of users complaining bitterly about needing any dependency.. any new dependency has to come as being totally optional OR a very very very good reason to use it. so basically don't expect existing logind code to change as the only deps it adds are those that are already on the system.

cederom added a comment.EditedDec 18 2020, 12:24 PM

Fully agree - all functions and dependencies should be totally optional - except dependency on systemd is quite the opposite - it is a hard dependency on Linux OS and whole project portability blocker when it comes to Wayland - so anything new that makes E work with Wayland should be optional and portable :-)

I am looking for an alternative solution that would be optional, as we all agree not to destroy what is already out there, and that would allow to run EFL/E on any operating system, including Linux, but not only Linux :-)

I hope the authors of EFL/E are not this kind of people that don't want to see EFL/E working anywhere else but Linux? Porting is welcome, or not?

@raster you helped me a lot to get things done, and I am grateful for that, thank you, I do not want any shitstorm here, sorry, I do not want to destroy anything, no worries, I am just looking for a solution to make things portable as free and optional alternative to existing solution, preferably that could be selected with meson at build time. But existing solution is hardwired to only one OS out there, Linux, that creates its own standards ignoring the rest, thus becoming less and less open, while there are others solutions that make things work for everyone.

New graphics foundation is being made on computer systems and we should make it portable adaptable and open, right? Open in a way that things are not tied to a specific implementation of a specific system, but in a way that people can adapt it to existing solutions with minimal effort without breaking what was already made, right :-)

vtorri added a subscriber: vtorri.Jan 19 2021, 11:16 PM

@cederom what is the status of that task ?

Can't we just still with X11? This may get really messy, and who is going to maintain that? On top of this it breaks other code paths in E by pulling in eeze.

@cederom If you want portable graphics system across Unix-like OS, the only choice, for a long time (in my opinion) is going to be X11. There is no gain introducing wayland support for FreeBSD right now. It makes X11 support elsewhere more work.

Hello @netstar this is fairly old thread and some new things happened in the meantime :-) Both X11 and Wayland works fine on FreeBSD already :-) X11 is considered obsolete and I guess the move towards Wayland is happening now (plus KMOD/DRM graphics acceleration infrastructure). Upcoming 13.0 will improve things a lot and I hope we can move forward with E+W.. It would be nice to have E working on Wayland on FreeBSD. I have managed to build E + EFL with Wayland support but some Linux stuff needs to be added. This is an ongoing work in progress already :-)

@netstar if @cederom wants to maintain Wayland support of EFL on FreeBSD - why not? ;)

IMHO, elogind is the only way to support Wayland as this is a library already used by some systemd-free distribs. So it is not exotic and surely will be supported/updated. I don't know if it could be ported on FreeBSD or it could be replaced by consolekit2. But I think it is the only way to go.

As about Wayland itself - it seems to be a real disaster for Open Source community. The number of hours passed by thousands of developers world wide to support this technology is so huge that they could develop completely new OS during this time. And it is still not finished and cannot be used on everyday basis AFAIK...