tools: add meson
meson is a next generation build system designed to have good defaults, simpler build files, and fast compilation. It is built upon python and uses ninja for compilation. The latter provides fast by default (parallel) and problem free compilation. There are over 40 packages already successfully using meson. The next commit will convert pkgconf to use meson compilation. Signed-off-by: Rosen Penev <rosenp@gmail.com>
This commit is contained in:
committed by
Paul Spooren
parent
4b898afdd2
commit
c4dfdde2ea
32
tools/meson/Makefile
Normal file
32
tools/meson/Makefile
Normal file
@@ -0,0 +1,32 @@
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=meson
|
||||
PKG_VERSION:=0.59.1
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||
PKG_SOURCE_URL:=https://github.com/mesonbuild/meson/releases/download/$(PKG_VERSION)
|
||||
PKG_HASH:=db586a451650d46bbe10984a87b79d9bcdc1caebf38d8e189f8848f8d502356d
|
||||
|
||||
PKG_MAINTAINER:=Andre Heider <a.heider@gmail.com>
|
||||
PKG_LICENSE:=Apache-2.0
|
||||
PKG_LICENSE_FILES:=COPYING
|
||||
|
||||
include $(INCLUDE_DIR)/host-build.mk
|
||||
|
||||
define Host/Configure
|
||||
endef
|
||||
|
||||
define Host/Compile
|
||||
endef
|
||||
|
||||
define Host/Install
|
||||
$(INSTALL_DIR) $(STAGING_DIR_HOST)/lib/meson
|
||||
$(CP) $(HOST_BUILD_DIR)/* $(STAGING_DIR_HOST)/lib/meson/
|
||||
endef
|
||||
|
||||
define Host/Clean
|
||||
$(call Host/Clean/Default)
|
||||
rm -rf $(STAGING_DIR_HOST)/lib/meson
|
||||
endef
|
||||
|
||||
$(eval $(call HostBuild))
|
||||
23
tools/meson/src/openwrt-cross.txt.in
Normal file
23
tools/meson/src/openwrt-cross.txt.in
Normal file
@@ -0,0 +1,23 @@
|
||||
[binaries]
|
||||
c = [@CC@]
|
||||
cpp = [@CXX@]
|
||||
ar = '@AR@'
|
||||
strip = '@STRIP@'
|
||||
nm = '@NM@'
|
||||
pkgconfig = '@PKGCONFIG@'
|
||||
|
||||
[built-in options]
|
||||
c_args = [@CFLAGS@]
|
||||
c_link_args = [@LDFLAGS@]
|
||||
cpp_args = [@CXXFLAGS@]
|
||||
cpp_link_args = [@LDFLAGS@]
|
||||
prefix = '/usr'
|
||||
|
||||
[host_machine]
|
||||
system = 'linux'
|
||||
cpu_family = '@ARCH@'
|
||||
cpu = '@CPU@'
|
||||
endian = '@ENDIAN@'
|
||||
|
||||
[properties]
|
||||
needs_exe_wrapper = true
|
||||
13
tools/meson/src/openwrt-native.txt.in
Normal file
13
tools/meson/src/openwrt-native.txt.in
Normal file
@@ -0,0 +1,13 @@
|
||||
[binaries]
|
||||
c = [@CC@]
|
||||
cpp = [@CXX@]
|
||||
pkgconfig = '@PKGCONFIG@'
|
||||
|
||||
[built-in options]
|
||||
c_args = [@CFLAGS@]
|
||||
c_link_args = [@LDFLAGS@]
|
||||
cpp_args = [@CXXFLAGS@]
|
||||
cpp_link_args = [@LDFLAGS@]
|
||||
prefix = '@PREFIX@'
|
||||
sbindir = 'bin'
|
||||
libdir = 'lib'
|
||||
Reference in New Issue
Block a user