Hello,
I want to add a Meson-based package to OpenWRT build system. Even though the dependencies are built, the following error happens when I try to compile the mpv package:
/home/javad/workspace/kernel/VIA_C7/openwrt/staging_dir/host/bin/python3 /home/javad/workspace/kernel/VIA_C7/openwrt/staging_dir/host/bin/meson.py --buildtype plain --native-file /home/javad/workspace/kernel/VIA_C7/openwrt/build_dir/target-i386_pentium4_musl/mpv-v0.36.0/openwrt-native.txt --cross-file /home/javad/workspace/kernel/VIA_C7/openwrt/build_dir/target-i386_pentium4_musl/mpv-v0.36.0/openwrt-cross.txt /home/javad/workspace/kernel/VIA_C7/openwrt/build_dir/target-i386_pentium4_musl/mpv-v0.36.0/openwrt-build /home/javad/workspace/kernel/VIA_C7/openwrt/build_dir/target-i386_pentium4_musl/mpv-v0.36.0/openwrt-build/..
ERROR: Neither source directory '/home/javad/workspace/kernel/VIA_C7/openwrt/build_dir/target-i386_pentium4_musl/mpv-v0.36.0/openwrt-build' nor build directory '/home/javad/workspace/kernel/VIA_C7/openwrt/build_dir/target-i386_pentium4_musl/mpv-v0.36.0/openwrt-build/..' contain a build file meson.build.
WARNING: Running the setup command as `meson [options]` instead of `meson setup [options]` is ambiguous and deprecated.
make[2]: *** [Makefile:65: /home/javad/workspace/kernel/VIA_C7/openwrt/build_dir/target-i386_pentium4_musl/mpv-v0.36.0/.configured_96b60db60102fa4d1451281d05ca547a] Error 1
make[2]: Leaving directory '/home/javad/workspace/kernel/VIA_C7/mypackages/mpv'
time: package/feeds/mpv/mpv/compile#1.07#0.11#1.17
ERROR: package/feeds/mpv/mpv failed to build.
The Makefie is as follows:
include $(TOPDIR)/rules.mk
PKG_NAME:=mpv
PKG_VERSION:=v0.36.0
PKG_RELEASE:=2
PKG_SOURCE:=$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://github.com/mpv-player/mpv/archive/refs/tags/
PKG_HASH:=29abc44f8ebee013bb2f9fe14d80b30db19b534c679056e4851ceadf5a5e8bf6
PKG_MAINTAINER:=Javad Rahimi <javad321javad@gmail.com>
PKG_LICENSE:=GPL-2.0-or-later
PKG_LICENSE_FILES:=COPYING
PKG_CONFIG_DEPENDS:= \
CONFIG_AUDIO_SUPPORT
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/nls.mk
include $(INCLUDE_DIR)/meson.mk
#MESON_ARGS+=-Diconv=disabled -Ddocumentation=disabled
define Package/mpv/Default
SECTION:=sound
CATEGORY:=Sound
TITLE:=Music Player MPV
URL:=https://www.mpv.io
DEPENDS:= +AUDIO_SUPPORT:alsa-lib +libexpat +libflac +libid3tag +libfaad2 +libopus +autoconf +libffmpeg-full +libffmpeg
USERID:=mpv:mpv
endef
define Package/mpv
SECTION:=sound
CATEGORY:=Sound
DEPENDS:=+autoconf +libffmpeg-full +libffmpeg
TITLE:=Music Player Daemon Console Client
URL:=http://www.musicpd.org/
endef
define Package/mpv/description
TBD
endef
define Package/mpv/install
$(INSTALL_DIR) $(1)/usr/bin
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/mpv $(1)/usr/bin/
$(INSTALL_BIN) ./files/pls-handler.sh $(1)/usr/bin/
endef
$(eval $(call BuildPackage,mpv))