diff options
Diffstat (limited to 'meta-oe/recipes-devtools/tcltk/tk8_8.6.15.bb')
-rw-r--r-- | meta-oe/recipes-devtools/tcltk/tk8_8.6.15.bb | 103 |
1 files changed, 103 insertions, 0 deletions
diff --git a/meta-oe/recipes-devtools/tcltk/tk8_8.6.15.bb b/meta-oe/recipes-devtools/tcltk/tk8_8.6.15.bb new file mode 100644 index 0000000000..8cb9f6cb5e --- /dev/null +++ b/meta-oe/recipes-devtools/tcltk/tk8_8.6.15.bb | |||
@@ -0,0 +1,103 @@ | |||
1 | SUMMARY = "Tool Command Language ToolKit Extension" | ||
2 | HOMEPAGE = "http://tcl.sourceforge.net" | ||
3 | SECTION = "devel/tcltk" | ||
4 | |||
5 | # http://www.tcl.tk/software/tcltk/license.html | ||
6 | LICENSE = "TCL" | ||
7 | LIC_FILES_CHKSUM = "file://license.terms;md5=c88f99decec11afa967ad33d314f87fe \ | ||
8 | file://compat/license.terms;md5=c88f99decec11afa967ad33d314f87fe \ | ||
9 | file://doc/license.terms;md5=c88f99decec11afa967ad33d314f87fe \ | ||
10 | file://library/license.terms;md5=c88f99decec11afa967ad33d314f87fe \ | ||
11 | file://macosx/license.terms;md5=c88f99decec11afa967ad33d314f87fe \ | ||
12 | file://tests/license.terms;md5=c88f99decec11afa967ad33d314f87fe \ | ||
13 | file://unix/license.terms;md5=c88f99decec11afa967ad33d314f87fe \ | ||
14 | file://win/license.terms;md5=c88f99decec11afa967ad33d314f87fe \ | ||
15 | file://xlib/license.terms;md5=c88f99decec11afa967ad33d314f87fe \ | ||
16 | " | ||
17 | |||
18 | DEPENDS = "tcl8 virtual/libx11 libxt" | ||
19 | |||
20 | SRC_URI = "\ | ||
21 | ${SOURCEFORGE_MIRROR}/tcl/tk${PV}-src.tar.gz \ | ||
22 | file://confsearch.diff \ | ||
23 | file://tkprivate.diff \ | ||
24 | file://fix-xft.diff \ | ||
25 | " | ||
26 | |||
27 | SRC_URI[sha256sum] = "550969f35379f952b3020f3ab7b9dd5bfd11c1ef7c9b7c6a75f5c49aca793fec" | ||
28 | |||
29 | UPSTREAM_CHECK_URI = "https://sourceforge.net/projects/tcl/files/Tcl/" | ||
30 | UPSTREAM_CHECK_REGEX = "Tcl/(?P<pver>\d+(\.\d+)+)/" | ||
31 | |||
32 | S = "${UNPACKDIR}/tk${PV}" | ||
33 | |||
34 | # Short version format: "8.6" | ||
35 | VER = "${@os.path.splitext(d.getVar('PV'))[0]}" | ||
36 | |||
37 | LDFLAGS += "-Wl,-rpath,${libdir}/tcltk/${PV}/lib" | ||
38 | CFLAGS += "-I${STAGING_INCDIR}/tcl${VER}" | ||
39 | inherit autotools features_check pkgconfig | ||
40 | |||
41 | AUTOTOOLS_SCRIPT_PATH = "${S}/unix" | ||
42 | EXTRA_AUTORECONF += "--exclude=aclocal" | ||
43 | |||
44 | # depends on virtual/libx11 | ||
45 | REQUIRED_DISTRO_FEATURES = "x11" | ||
46 | |||
47 | EXTRA_OECONF = "\ | ||
48 | --enable-threads \ | ||
49 | --with-x \ | ||
50 | --with-tcl=${STAGING_BINDIR}/crossscripts \ | ||
51 | --libdir=${libdir} \ | ||
52 | " | ||
53 | |||
54 | export TK_LIBRARY = '${libdir}/tk${VER}' | ||
55 | |||
56 | do_install:append() { | ||
57 | ln -sf libtk${VER}.so ${D}${libdir}/libtk${VER}.so.0 | ||
58 | oe_libinstall -so libtk${VER} ${D}${libdir} | ||
59 | ln -sf wish${VER} ${D}${bindir}/wish | ||
60 | |||
61 | sed -i "s;-L${B};-L${STAGING_LIBDIR};g" tkConfig.sh | ||
62 | sed -i "s;'${WORKDIR};'${STAGING_INCDIR};g" tkConfig.sh | ||
63 | install -d ${D}${bindir_crossscripts} | ||
64 | install -m 0755 tkConfig.sh ${D}${bindir_crossscripts} | ||
65 | } | ||
66 | |||
67 | PACKAGECONFIG ??= "xft" | ||
68 | PACKAGECONFIG[xft] = "--enable-xft,--disable-xft,xft" | ||
69 | PACKAGECONFIG[xss] = "--enable-xss,--disable-xss,libxscrnsaver libxext" | ||
70 | |||
71 | PACKAGES =+ "${PN}-lib" | ||
72 | |||
73 | FILES:${PN}-lib = "${libdir}/libtk${VER}.so*" | ||
74 | FILES:${PN} += "${libdir}/tk*" | ||
75 | |||
76 | # isn't getting picked up by shlibs code | ||
77 | RDEPENDS:${PN} += "tk8-lib" | ||
78 | RDEPENDS:${PN}:class-native = "" | ||
79 | |||
80 | BBCLASSEXTEND = "native nativesdk" | ||
81 | |||
82 | # Fix the path in sstate | ||
83 | SSTATE_SCAN_FILES += "*Config.sh" | ||
84 | |||
85 | inherit binconfig | ||
86 | |||
87 | SYSROOT_DIRS += "${bindir_crossscripts}" | ||
88 | |||
89 | # Fix some paths that might be used by Tcl extensions | ||
90 | BINCONFIG_GLOB = "*Config.sh" | ||
91 | |||
92 | # Cleanup host path from ${libdir}/tclConfig.sh and remove the | ||
93 | # ${bindir_crossscripts}/tclConfig.sh from target | ||
94 | PACKAGE_PREPROCESS_FUNCS += "tcl_package_preprocess" | ||
95 | tcl_package_preprocess() { | ||
96 | sed -i -e "s;${DEBUG_PREFIX_MAP};;g" \ | ||
97 | -e "s;-L${STAGING_LIBDIR};-L${libdir};g" \ | ||
98 | -e "s;${STAGING_INCDIR};${includedir};g" \ | ||
99 | -e "s;--sysroot=${RECIPE_SYSROOT};;g" \ | ||
100 | ${PKGD}${libdir}/tkConfig.sh | ||
101 | |||
102 | rm -f ${PKGD}${bindir_crossscripts}/tkConfig.sh | ||
103 | } | ||