tcl: bump version to 8.6.6
[buildroot-gz.git] / package / tcl / tcl.mk
blobffef9cf8bdae6c08f00abe038b4c27bdf2caf266
1 ################################################################################
3 # tcl
5 ################################################################################
7 TCL_VERSION_MAJOR = 8.6
8 TCL_VERSION = $(TCL_VERSION_MAJOR).6
9 TCL_SOURCE = tcl$(TCL_VERSION)-src.tar.gz
10 TCL_SITE = http://downloads.sourceforge.net/project/tcl/Tcl/$(TCL_VERSION)
11 TCL_LICENSE = tcl license
12 TCL_LICENSE_FILES = license.terms
13 TCL_SUBDIR = unix
14 TCL_INSTALL_STAGING = YES
15 TCL_AUTORECONF = YES
17 TCL_CONF_OPTS = \
18 --disable-symbols \
19 --disable-langinfo \
20 --disable-framework
22 HOST_TCL_CONF_OPTS = \
23 --disable-symbols \
24 --disable-langinfo \
25 --disable-framework
27 # I haven't found a good way to force pkgs to not build
28 # or configure without just removing the entire pkg directory.
29 define HOST_TCL_REMOVE_PACKAGES
30 rm -fr $(@D)/pkgs/sqlite3* $(@D)/pkgs/tdbc*
31 endef
32 HOST_TCL_PRE_CONFIGURE_HOOKS += HOST_TCL_REMOVE_PACKAGES
34 # We remove the bundled sqlite as we prefer to not use bundled stuff at all.
35 define TCL_REMOVE_PACKAGES
36 rm -fr $(@D)/pkgs/sqlite3* \
37 $(if $(BR2_PACKAGE_MYSQL),,$(@D)/pkgs/tdbcmysql*) \
38 $(@D)/pkgs/tdbcodbc* \
39 $(if $(BR2_PACKAGE_POSTGRESQL),,$(@D)/pkgs/tdbcpostgres*) \
40 $(if $(BR2_PACKAGE_SQLITE),,$(@D)/pkgs/tdbcsqlite3*)
41 endef
42 TCL_PRE_CONFIGURE_HOOKS += TCL_REMOVE_PACKAGES
44 ifeq ($(BR2_PACKAGE_TCL_DEL_ENCODINGS),y)
45 define TCL_REMOVE_ENCODINGS
46 rm -rf $(TARGET_DIR)/usr/lib/tcl$(TCL_VERSION_MAJOR)/encoding/*
47 endef
48 TCL_POST_INSTALL_TARGET_HOOKS += TCL_REMOVE_ENCODINGS
49 endif
51 ifeq ($(BR2_PACKAGE_TCL_SHLIB_ONLY),y)
52 define TCL_REMOVE_TCLSH
53 rm -f $(TARGET_DIR)/usr/bin/tclsh$(TCL_VERSION_MAJOR)
54 endef
55 TCL_POST_INSTALL_TARGET_HOOKS += TCL_REMOVE_TCLSH
56 else
57 define TCL_SYMLINK_TCLSH
58 ln -sf tclsh$(TCL_VERSION_MAJOR) $(TARGET_DIR)/usr/bin/tclsh
59 endef
60 TCL_POST_INSTALL_TARGET_HOOKS += TCL_SYMLINK_TCLSH
61 endif
63 # Until someone needs it, we don't handle locale installation. tcl has
64 # a complicated method of translating LANG-style locale names into its internal
65 # .msg name which makes it difficult to save the correct locales per the
66 # configured whitelist.
67 define TCL_REMOVE_EXTRA
68 rm -fr $(TARGET_DIR)/usr/lib/tclConfig.sh \
69 $(TARGET_DIR)/usr/lib/tclooConfig.sh \
70 $(TARGET_DIR)/usr/lib/tcl$(TCL_VERSION_MAJOR)/tclAppInit.c \
71 $(TARGET_DIR)/usr/lib/tcl$(TCL_VERSION_MAJOR)/msgs
72 endef
73 TCL_POST_INSTALL_TARGET_HOOKS += TCL_REMOVE_EXTRA
75 TCL_DEPENDENCIES = $(if $(BR2_PACKAGE_SQLITE),sqlite) \
76 $(if $(BR2_PACKAGE_MYSQL),mysql) \
77 $(if $(BR2_PACKAGE_POSTGRESQL),postgresql)
79 $(eval $(autotools-package))
80 $(eval $(host-autotools-package))