CROSS_HOST="x86_64-w64-mingw32" inherit cross NAME="mingw64-x86_64-tcl" VERSION=8.6.10 RELEASE=1 CATEGORY="Devel" SUMMARY="Tcl interpreter for Win64 toolchain" DEPEND="mingw64-x86_64-zlib" DESCRIPTION="This package does NOT contain cygwin binaries. Instead, it contains msvcrt-linked binaries (aka 'mingw'). It is for use with the mingw64-x86_64-gcc cross compiler, and installs into the /usr/x86_64-w64-mingw32/sys-root/mingw/{lib,include} directories." HOMEPAGE="https://www.tcl.tk/" SRC_URI="mirror://sourceforge/tcl/tcl-core${VERSION}-src.tar.gz" SRC_DIR="tcl${VERSION}" #http://pkgs.fedoraproject.org/cgit/rpms/mingw-tcl.git/plain/tcl-8.6.3-autopath.patch # http://pkgs.fedoraproject.org/cgit/rpms/mingw-tcl.git/plain/tcl-8.6.5-hidden.patch # http://pkgs.fedoraproject.org/cgit/rpms/mingw-tcl.git/plain/tcl-8.6.5-parallel-make-fix.patch # http://pkgs.fedoraproject.org/cgit/rpms/mingw-tcl.git/plain/tcl-8.5.6-mingw.patch # http://pkgs.fedoraproject.org/cgit/rpms/mingw-tcl.git/plain/tcl-nativetclsh.patch # http://pkgs.fedoraproject.org/cgit/rpms/mingw-tcl.git/plain/tcl-mingw-w64-compatibility.patch PATCH_URI=" http://pkgs.fedoraproject.org/cgit/rpms/mingw-tcl.git/plain/tcl-8.6.1-nativezlib.patch " DIFF_EXCLUDES="Makefile tcl.hpj tclConfig.sh" slot=${PV_MAJ_MIN} src_compile() { lndirs cd ${B}/win cygautoreconf cygconf --enable-64bit --host=x86_64-w64-mingw32 cygmake -j1 CYGPATH=echo } src_install() { cd ${B}/win USE_DESTDIR=0 cyginstall rm -f ${D}${CROSS_BINDIR}/zlib1.dll sed -i \ -e "s|^\(TCL_BUILD_LIB_SPEC\)='.*|\1='-Wl,${CROSS_LIBDIR}/libtcl${slot//.}.a'|" \ -e "s|^\(TCL_SRC_DIR\)='.*'|\1='${CROSS_INCLUDEDIR}/tcl${slot}'|" \ -e "s|^\(TCL_BUILD_STUB_LIB_SPEC\)='.*|\1='-Wl,${CROSS_LIBDIR}/libtclstub${slot//.}.a'|" \ -e "s|^\(TCL_BUILD_STUB_LIB_PATH\)='.*/win|\1='${CROSS_LIBDIR}|" \ -e "s|^\(TCL_STUB_LIB_SPEC\)='.*|\1='-Wl,-ltclstub${slot//.}'|" \ ${D}${CROSS_LIBDIR}/tclConfig.sh || error # install private headers includeinto tcl${slot}/win doinclude ${S}/win/*.h includeinto tcl${slot}/generic doinclude ${S}/generic/*.h }