blob: 76aea6f41abf451fac6fe64038d49ce7969d9b9b [file] [log] [blame]
Brad Bishope42b3e32020-01-15 22:08:42 -05001SUMMARY = "X.Org X cvt"
2HOMEPAGE = "https://linux.die.net/man/1/cvt"
Andrew Geissler9aee5002022-03-30 16:27:02 +00003LICENSE = "MIT"
Brad Bishope42b3e32020-01-15 22:08:42 -05004LIC_FILES_CHKSUM = "file://COPYING;md5=5df87950af51ac2c5822094553ea1880"
5
6DEPENDS += "pixman-native xorgproto-native libxrandr-native"
7
8XORG_PN = "xorg-server"
9
10SRC_URI = "${XORG_MIRROR}/individual/xserver/${XORG_PN}-${PV}.tar.bz2"
Andrew Geissler72956ed2021-01-08 16:11:14 -060011SRC_URI[md5sum] = "8cf8bd1f33e3736bc8dd279b20a32399"
12SRC_URI[sha256sum] = "977420c082450dc808de301ef56af4856d653eea71519a973c3490a780cb7c99"
Brad Bishope42b3e32020-01-15 22:08:42 -050013
14S = "${WORKDIR}/${XORG_PN}-${PV}"
15B = "${WORKDIR}/build"
16
Andrew Geisslereef63862021-01-29 15:58:13 -060017inherit pkgconfig native
Brad Bishope42b3e32020-01-15 22:08:42 -050018
19do_configure[noexec] = "1"
20
21do_compile() {
22 cd ${S}
23 for header in `find -name '*.h'`; do
24 path=`dirname $header`
25 if ! echo "$incpaths" | grep -q "$path" ; then
26 incpaths="$incpaths -I$path"
27 fi
28 done
29 CFLAGS="${CFLAGS} -DXORG_VERSION_CURRENT=1 $incpaths `pkg-config --cflags pixman-1`"
30 LDFLAGS="${LDFLAGS} -lm `pkg-config --libs pixman-1`"
31 ${CC} $CFLAGS -o ${B}/cvt \
32 ${S}/hw/xfree86/utils/cvt/cvt.c \
33 ${S}/hw/xfree86/modes/xf86cvt.c \
34 ${S}/os/xprintf.c \
35 $LDFLAGS
36}
37
38do_install() {
39 install -d ${D}${bindir}
40 install -m 755 ${B}/cvt ${D}${bindir}
41}