blob: 7d2515e075498afe870a45a3beaac5beb2e6337d [file] [log] [blame]
Brad Bishop19323692019-04-05 15:28:33 -04001SUMMARY = "Graph Visualization Tools"
2HOMEPAGE = "http://www.graphviz.org"
3LICENSE = "EPL-1.0"
4LIC_FILES_CHKSUM = "file://COPYING;md5=9109f5fc16cf963fb3cdd32781b3ce04"
5
6DEPENDS = " \
7 intltool-native \
8 bison-native \
9 groff-native \
10 libtool \
11 gdk-pixbuf \
12 librsvg \
13 cairo \
14 pango \
15 expat \
16 freetype \
17"
Patrick Williams213cb262021-08-07 19:21:33 -050018DEPENDS:append:class-target = " ${BPN}-native"
19DEPENDS:append:class-nativesdk = " ${BPN}-native"
Brad Bishop19323692019-04-05 15:28:33 -040020
21inherit autotools-brokensep pkgconfig gettext
22
Andrew Geissler4b7c1152020-11-30 19:55:29 -060023SRC_URI = "https://www2.graphviz.org/Packages/stable/portable_source/${BP}.tar.gz \
Brad Bishop26bdd442019-08-16 17:08:17 -040024 file://0001-plugin-pango-Include-freetype-headers-explicitly.patch \
Brad Bishop19323692019-04-05 15:28:33 -040025"
26# Use native mkdefs
Patrick Williams213cb262021-08-07 19:21:33 -050027SRC_URI:append:class-target = "\
Brad Bishop26bdd442019-08-16 17:08:17 -040028 file://0001-Use-native-mkdefs.patch \
29 file://0001-Set-use_tcl-to-be-empty-string-if-tcl-is-disabled.patch \
30"
Patrick Williams213cb262021-08-07 19:21:33 -050031SRC_URI:append:class-nativesdk = "\
Andrew Geissler89770b02020-06-13 10:40:47 -050032 file://0001-Use-native-mkdefs.patch \
33 file://graphviz-setup.sh \
34"
Andrew Geissler4b7c1152020-11-30 19:55:29 -060035SRC_URI[sha256sum] = "8e1b34763254935243ccdb83c6ce108f531876d7a5dfd443f255e6418b8ea313"
Brad Bishop19323692019-04-05 15:28:33 -040036
Patrick Williams213cb262021-08-07 19:21:33 -050037EXTRA_OECONF:append = " PS2PDF=/bin/echo"
Brad Bishop19323692019-04-05 15:28:33 -040038
Patrick Williams213cb262021-08-07 19:21:33 -050039EXTRA_OECONF:class-target = "\
Brad Bishop19323692019-04-05 15:28:33 -040040 --with-expatincludedir=${STAGING_INCDIR} \
41 --with-expatlibdir=${STAGING_LIBDIR} \
42 --without-included-ltdl \
43 --disable-java \
Brad Bishop26bdd442019-08-16 17:08:17 -040044 --disable-tcl \
Brad Bishop19323692019-04-05 15:28:33 -040045 --disable-r \
46 --disable-sharp \
47 "
Patrick Williams213cb262021-08-07 19:21:33 -050048EXTRA_OECONF:class-nativesdk = "\
Andrew Geissler89770b02020-06-13 10:40:47 -050049 --with-expatincludedir=${STAGING_INCDIR} \
50 --with-expatlibdir=${STAGING_LIBDIR} \
51 --without-included-ltdl \
52 --disable-java \
53 --disable-tcl \
54 --disable-r \
55 --disable-sharp \
56 "
Patrick Williams213cb262021-08-07 19:21:33 -050057CFLAGS:append:class-target = " -D_typ_ssize_t=1 -D_long_double=1"
58CFLAGS:append:class-nativesdk = " -D_typ_ssize_t=1 -D_long_double=1"
59do_configure:prepend() {
Brad Bishop19323692019-04-05 15:28:33 -040060 cd ${S}
61 # create version.m4 and ignore libtoolize errors
62 ./autogen.sh NOCONFIG || true
63}
64
Patrick Williams213cb262021-08-07 19:21:33 -050065do_install:append:class-native() {
Brad Bishop19323692019-04-05 15:28:33 -040066 # install mkdefs for target build
67 install -m755 ${B}/lib/gvpr/mkdefs ${D}${bindir}
68}
69
Patrick Williams213cb262021-08-07 19:21:33 -050070do_install:append:class-nativesdk() {
Andrew Geissler89770b02020-06-13 10:40:47 -050071 # graphviz-setup.sh must be executed at SDK installation
72 install -d ${D}${SDKPATHNATIVE}/post-relocate-setup.d
73 install -m 0755 ${WORKDIR}/graphviz-setup.sh ${D}${SDKPATHNATIVE}/post-relocate-setup.d
74}
Patrick Williams213cb262021-08-07 19:21:33 -050075FILES:${PN}:class-nativesdk += "${SDKPATHNATIVE}"
Andrew Geissler89770b02020-06-13 10:40:47 -050076
Brad Bishop26bdd442019-08-16 17:08:17 -040077PACKAGES =+ "${PN}-python ${PN}-perl ${PN}-demo"
78
Patrick Williams213cb262021-08-07 19:21:33 -050079FILES:${PN}-python += "${libdir}/python*/site-packages/ ${libdir}/graphviz/python/"
80FILES:${PN}-perl += "${libdir}/perl5/*/vendor_perl/ ${libdir}/graphviz/perl/"
81FILES:${PN}-demo += "${datadir}/graphviz/demo/"
Brad Bishop26bdd442019-08-16 17:08:17 -040082
Patrick Williams213cb262021-08-07 19:21:33 -050083RDEPENDS:${PN}-perl += "perl"
84RDEPENDS:${PN}-python += "python3"
85RDEPENDS:${PN}-demo += "python3 perl"
Brad Bishop26bdd442019-08-16 17:08:17 -040086
Patrick Williams213cb262021-08-07 19:21:33 -050087INSANE_SKIP:${PN}-perl = "dev-so"
88INSANE_SKIP:${PN}-python = "dev-so"
Brad Bishop26bdd442019-08-16 17:08:17 -040089
Patrick Williams213cb262021-08-07 19:21:33 -050090FILES_SOLIBSDEV:append = " ${libdir}/graphviz/lib*${SOLIBSDEV}"
Brad Bishop19323692019-04-05 15:28:33 -040091
Andrew Geissler89770b02020-06-13 10:40:47 -050092BBCLASSEXTEND = "native nativesdk"