mate-desktop / mate-media

Media tools for MATE
https://mate-desktop.org
GNU General Public License v2.0
19 stars 25 forks source link

add meson build support #206

Closed zhuyaliang closed 10 months ago

zhuyaliang commented 11 months ago

test meson

meson setup _build --prefix=/usr -Din-process=true -Ddefault_library=both

ninja -C _build

DESTDIR=/tmp/meson_dir meson install -C _build

test make

 ./autogen.sh --prefix=/usr --enable-in-process=yes

make

make install DESTDIR=/tmp/make_dir

Compare Build Results

[test@localhost mate-power-manager]$ find /tmp/make_dir/ | wc -l
489
[test@localhost mate-power-manager]$ find /tmp/meson_dir/ | wc -l
488

meson does not provide libmate-volume-control-applet.la, so the total number is one less, which is not a problem

zhuyaliang commented 10 months ago

@lukefromdc Please test again

lukefromdc commented 10 months ago

Still didn't run in-process, this time the problem was .desktop being appended to the filename of /usr/share/mate-panel/applets/org.mate.applets.GvcApplet.mate-panel-applet which was installed as /usr/share/mate-panel/applets/org.mate.applets.GvcApplet.mate-panel-applet.desktop and was thus instantly visible when a known good file dropped in to replace it went in alongside it. With this error, not only would the applet not load, it was not even offered for adding to the panel as a file with the correct name (no .desktop appended to it) did not exist

The file itself was OK, verified by cut and pasting its text into the correctly named file. The applet then worked, tested out of process/on wayland.

Renaming in Caja didn't work, as .desktop got reappended to the file name that way too.

zhuyaliang commented 10 months ago

@lukefromdc The file name has been fixed

lukefromdc commented 10 months ago

Just got a successful out of process build too

raveit65 commented 10 months ago

With in-process build: libmate-volume-control-applet.la is missing in meson build.

[rave@mother ~]$ ls /tmp/make_dir/usr/lib64
libmate-volume-control-applet.a   libmate-volume-control-applet.so
libmate-volume-control-applet.la
[rave@mother ~]$ ls /tmp/meson_dir/usr/lib64
libmate-volume-control-applet.a  libmate-volume-control-applet.so

scalable folder is missing, btw. it is at the wrong place.

[rave@mother ~]$ ls /tmp/make_dir/usr/share/mate-media/icons/hicolor
16x16  22x22  24x24  32x32  48x48  scalable
[rave@mother ~]$ ls /tmp/meson_dir/usr/share/mate-media/icons/hicolor
16x16  22x22  24x24  32x32  48x48
[rave@mother ~]$ ls /tmp/meson_dir/usr/share/mate-media/icons
hicolor  scalable
raveit65 commented 10 months ago

Same problem exists with out-of-process build.

lukefromdc commented 10 months ago

The wrong directory icons I didn't spot, I have another set of icons used from my theme.

Never once have I seen a meson build install .la files, I've been hand-editing and hand packing these back into GTK and Glib for years. This is a problem when and to my knowledge only when when building a package with autotools that depends on a package built with meson and looks for these files.

zhuyaliang commented 10 months ago

@raveit65 The icon issue has been fixed

raveit65 commented 10 months ago

meson does not provide libmate-volume-control-applet.la, so the total number is one less, which is not a problem

Why this isn't a problem? I mean when someone need this static lib than it is a problem, or not?

raveit65 commented 10 months ago

Any way, it seems this is meson specific. I don't mind because i remove the .la and .a files since the beginning form packages during the rpm build process for official fedora.

raveit65 commented 10 months ago

Confirmed that icon dir issue is fixed with latest git push.