xref: /OK3568_Linux_fs/yocto/meta-openembedded/meta-oe/recipes-support/mg/mg_20210609.bb (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1SUMMARY = "A portable version of the mg maintained by the OpenBSD team"
2HOMEPAGE = "http://homepage.boetes.org/software/mg/"
3LICENSE = "PD"
4LIC_FILES_CHKSUM = "file://version.c;md5=1895eb37bf6bd79cdc5c89d8166fabfb"
5DEPENDS = "ncurses libbsd"
6SECTION = "console/editors"
7
8SRCREV = "688f49cd67ab30dfa6482c74815e117cbf7af63a"
9SRC_URI = "git://github.com/hboetes/mg;branch=master;protocol=https \
10           file://0001-fileio-Include-sys-param.h-for-MAXNAMLEN.patch \
11           file://0002-fileio-Define-DEFFILEMODE-if-platform-is-missing.patch \
12           "
13SRC_URI:append:libc-musl = "\
14           file://0001-Undefine-REGEX-for-musl-based-systems.patch \
15           "
16
17S = "${WORKDIR}/git"
18
19# CFLAGS isn't in EXTRA_OEMAKE, as the makefile picks it up via ?=
20EXTRA_OEMAKE = "\
21    'CC=${CC}' \
22    'LDFLAGS=${LDFLAGS}' \
23    \
24    'prefix=${prefix}' \
25    'bindir=${bindir}' \
26    'libdir=${libdir}' \
27    'includedir=${includedir}' \
28    'mandir=${mandir}' \
29    'PKG_CONFIG=pkg-config' \
30"
31
32CFLAGS += "-I${STAGING_INCDIR}/bsd"
33
34do_install () {
35    oe_runmake install DESTDIR=${D}
36}
37
38inherit pkgconfig
39