%define tclvers 8.4 %define tclfullvers 8.4.7 %define expvers 5.42 %define expfullvers 5.42.1 Summary: A Tcl/Tk development environment: tcl and tk Name: tcltk Version: %{tclfullvers} Release: 4 %ifnos aix6.1 Source0: ftp://ftp.scriptics.com/pub/tcl/tcl8_4/tcl%{tclfullvers}-src.tar.gz Source1: ftp://ftp.scriptics.com/pub/tcl/tcl8_4/tk%{tclfullvers}-src.tar.gz Source2: http://expect.nist.gov/old/expect-%{expfullvers}.tar.gz Source3: IBM_ILA Source4: expect.txt Patch0: tcl%{tclfullvers}-aix5.patch Patch1: expect-%{expfullvers}-aix.patch Requires: AIX-rpm < 6.1.0.0 %endif License: IBM_ILA Group: Development/Languages Prefix: %{_prefix} Buildroot: /var/tmp/%{name}-root %define DEFCC cc %description Tcl is a simple scripting language designed to be embedded into other applications. Tcl is designed to be used with Tk, a widget set. %package -n tcl Summary: An embeddable scripting language. Group: Development/Languages URL: http://www.tcl.tk %description -n tcl Tcl is a simple scripting language designed to be embedded into other applications. Tcl is designed to be used with Tk, a widget set, which is provided in the tk package. This package also includes tclsh, a simple example of a Tcl application. If you're installing the tcl package and you want to use Tcl for development, you should also install the tk package. %ifos aix6.1 Note that this package is only a placeholder to satisfy RPM requisites. Starting in AIX 6.1, tcl is provided by tcl.base. %endif %package -n tk #Version: 8.0.3 Summary: The Tk GUI toolkit for Tcl, with shared libraries. Group: Development/Languages URL: http://www.tcl.tk %description -n tk Tk is a widget set for the X Window System that is designed to work closely with the Tcl scripting language. It allows you to write simple programs with full featured GUI's in only a little more time then it takes to write a text based interface. Tcl/Tk applications can also be run on Windows and Macintosh platforms. %ifos aix6.1 Note that this package is only a placeholder to satisfy RPM requisites. Starting in AIX 6.1, tk is provided by tk.base. %endif %package -n expect Version: %{expfullvers} Summary: A tcl extension for simplifying program-script interaction. Group: Development/Languages URL: http://expect.nist.gov %description -n expect Expect is a tcl extension for automating interactive applications such as telnet, ftp, passwd, fsck, rlogin, tip, etc. Expect is also useful for testing those applications. Expect makes it easy for a script to control another program and interact with it. Install the expect package if you'd like to develop scripts which interact with interactive applications. You'll also need to install the tcl package. %ifos aix6.1 Note that this package is only a placeholder to satisfy RPM requisites. Starting in AIX 6.1, expect is provided by expect.base. %endif %ifnos aix6.1 %prep %setup -q -c -a 1 -a 2 cd tk%{tclfullvers} # Add license info cat $RPM_SOURCE_DIR/IBM_ILA > LICENSE cat license.terms >> LICENSE cd ../tcl%{tclfullvers} %patch0 -b .aix5 # Add license info cat $RPM_SOURCE_DIR/IBM_ILA > LICENSE cat license.terms >> LICENSE cd ../expect-%{expvers} %patch1 -b .aix # Add license info cat $RPM_SOURCE_DIR/IBM_ILA > LICENSE cat $RPM_SOURCE_DIR/expect.txt >> LICENSE #========================================== %build # Use the default compiler for this platform - gcc otherwise if [[ -z "$CC" ]] then if test "X`type %{DEFCC} 2>/dev/null`" != 'X'; then export CC=%{DEFCC} else export CC=gcc fi fi if test "X$CC" != "Xgcc" then export RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS | sed 's:-fsigned-char::'` export CFLAGS="$RPM_OPT_FLAGS" fi export NO_OPT_FLAGS=`echo $RPM_OPT_FLAGS | sed 's:-O2::'` # make the libraries reentrant RPM_OPT_FLAGS="$RPM_OPT_FLAGS -D_REENTRANT" #------------------------------------------ # Tcl # cd tcl%{tclfullvers}/unix #libtoolize --copy --force CFLAGS="$RPM_OPT_FLAGS" ./configure --prefix=%{_prefix} --enable-shared #--enable-gcc make cd ../.. #------------------------------------------ # Tk # cd tk%{tclfullvers}/unix #libtoolize --copy --force CFLAGS="$RPM_OPT_FLAGS" ./configure --prefix=%{_prefix} --enable-shared #--enable-gcc make cd ../.. #------------------------------------------ # Expect # cd expect-%{expvers} CFLAGS="-O2 -D_REENTRANT -DSETPGRP_VOID" ./configure -prefix=/opt/freeware --enable-shared make cd .. #========================================== %install rm -rf $RPM_BUILD_ROOT rm -fv *.files* mkdir -p $RPM_BUILD_ROOT%{_prefix} #------------------------------------------ # Tcl # cd tcl%{tclfullvers}/unix make INSTALL_ROOT=$RPM_BUILD_ROOT install ln -sf libtcl%{tclvers}.so $RPM_BUILD_ROOT%{_prefix}/lib/libtcl.so ln -sf tclsh%{tclvers} $RPM_BUILD_ROOT%{_prefix}/bin/tclsh cd .. mkdir -p $RPM_BUILD_ROOT%{_prefix}/doc/tcl-%{tclfullvers} cp LICENSE README $RPM_BUILD_ROOT%{_prefix}/doc/tcl-%{tclfullvers} cd .. ( cd $RPM_BUILD_ROOT for dir in bin include do mkdir -p usr/$dir cd usr/$dir ln -sf ../..%{prefix}/$dir/* . cd - done mkdir -p usr/lib cd usr/lib ln -sf ../..%{prefix}/lib/* . ) (cd $RPM_BUILD_ROOT; find .%{_prefix}/bin .%{_prefix}/include \ .%{_prefix}/man \ .%{_prefix}/doc \ ./usr/bin \ ./usr/include \ ./usr/lib \ .%{_prefix}/lib/* \ -type f -o -type l | sed 's/^\.//'; find .%{_prefix}/lib/* -type d | sed 's/^\./%dir /' ) | sort > tcl.files #------------------------------------------ # Tk # cd tk%{tclfullvers}/unix make INSTALL_ROOT=$RPM_BUILD_ROOT install ln -sf libtk%{tclvers}.so $RPM_BUILD_ROOT%{_prefix}/lib/libtk.so ln -sf wish%{tclvers} $RPM_BUILD_ROOT%{_prefix}/bin/wish cd .. mkdir -p $RPM_BUILD_ROOT%{_prefix}/doc/tk-%{tclfullvers} cp LICENSE README $RPM_BUILD_ROOT%{_prefix}/doc/tk-%{tclfullvers} cd .. ( cd $RPM_BUILD_ROOT for dir in bin include do mkdir -p usr/$dir cd usr/$dir ln -sf ../..%{prefix}/$dir/* . cd - done mkdir -p usr/lib cd usr/lib ln -sf ../..%{prefix}/lib/* . ) (cd $RPM_BUILD_ROOT; find .%{_prefix}/bin .%{_prefix}/include \ .%{_prefix}/man \ .%{_prefix}/doc \ ./usr/bin \ ./usr/include \ ./usr/lib \ .%{_prefix}/lib/* \ -type f -o -type l | sed 's/^\.//'; find .%{_prefix}/lib/* -type d | sed 's/^\./%dir /' ) | \ cat - tcl.files | sort | uniq -u > tk.files #------------------------------------------ # Expect # cd expect-%{expvers} make INSTALL_ROOT=$RPM_BUILD_ROOT install mkdir -p $RPM_BUILD_ROOT%{_prefix}/doc/expect-%{expvers} cp LICENSE NEWS README FAQ INSTALL HISTORY \ $RPM_BUILD_ROOT%{_prefix}/doc/expect-%{expvers} cd .. ( cd $RPM_BUILD_ROOT for dir in bin include do mkdir -p usr/$dir cd usr/$dir ln -sf ../..%{prefix}/$dir/* . cd - done # don't want to install over pre-existing /usr/bin/mkpasswd rm usr/bin/mkpasswd mkdir -p usr/linux/bin cd usr/linux/bin ln -sf ../../..%{prefix}/bin/mkpasswd . cd - mkdir -p usr/lib cd usr/lib ln -sf ../..%{prefix}/lib/* . ) (cd $RPM_BUILD_ROOT; find .%{_prefix}/bin .%{_prefix}/include \ .%{_prefix}/man \ .%{_prefix}/doc \ ./usr/bin \ ./usr/linux/bin \ ./usr/include \ ./usr/lib \ .%{_prefix}/lib/* \ -type f -o -type l | sed 's/^\.//'; find .%{_prefix}/lib/* -type d | sed 's/^\./%dir /' ) | \ cat - tcl.files tk.files | sort | uniq -u > expect.files #Strip the binaries /usr/bin/strip $RPM_BUILD_ROOT%{_prefix}/bin/* || : #========================================== %clean rm -rf $RPM_BUILD_ROOT rm -f *.files* %files -f tcl.files -n tcl %defattr(-,root,system) %files -f tk.files -n tk %defattr(-,root,system) %files -f expect.files -n expect %defattr(-,root,system) %else #os aix5.3 %files -n tcl %files -n tk %files -n expect %endif %changelog * Thu Jul 23 2009 Reza Arbab 8.4.7-4 - Split into a normal package for AIX < 6.1.0.0 and a dummy placeholder package for AIX >= 6.1.0.0. The base OS now delivers tcl.base, tk.base, and expect.base installp packages. * Mon Oct 2 2006 Reza Arbab 8.4.7-3 - Add %%defattr. * Wed Sep 6 2006 Reza Arbab 8.4.7-2 - Fix broken symlinks for tclsh, wish, libtcl.so, and libtk.so. * Thu Jul 13 2006 Reza Arbab 8.4.7-1 - Update to Tcl/Tk 8.4.7 and expect 5.42.1. * Tue Mar 22 2005 David Clissold 8.3.3-9 - Add patch for Unix write of 0 bytes. * Fri Nov 22 2002 David Clissold - Add IBM ILA license. * Thu Feb 14 2002 Marc Stephenson - Fix configure bugs for AIX 5 * Fri Feb 08 2002 Marc Stephenson - New version * Wed Jun 06 2001 Marc Stephenson - Version 8.3.3 * Fri Apr 06 2001 David Clissold - Modifications required to build on AIX5.1 on IA64 * Thu Apr 05 2001 David Clissold - Add sections for Expect to build - Add patch for configure & m4 files (so tcl will build on AIX/ia64) * Fri Mar 09 2001 Marc Stephenson - Add logic for default compiler - Rebuild against new shared objects * Tue Feb 20 2001 aixtoolbox - Account for different standard lib location in IA64 32-bit ABI * Tue Mar 7 2000 Jeff Johnson - rebuild for sparc baud rates > 38400. * Mon Feb 7 2000 Bill Nottingham - handle compressed manpages * Thu Feb 03 2000 Elliot Lee - Make changes from bug number 7602 - Apply patch from bug number 7537 - Apply fix from bug number 7157 - Add fixes from bug #7601 to the runtcl patch * Wed Feb 02 2000 Cristian Gafton - fix descriptions - man pages are compressed (whatapain) * Tue Nov 30 1999 Jakub Jelinek - fix tclX symlinks. - compile on systems where SIGPWR == SIGLOST. * Sat May 1 1999 Jeff Johnson - update tcl/tk to 8.0.5. - avoid "containing" in Tix (#2332). * Thu Apr 8 1999 Jeff Johnson - use /usr/bin/write in kibitz (#1320). - use cirrus.sprl.umich.edu in weather (#1926). * Sun Mar 21 1999 Cristian Gafton - auto rebuild in the new build environment (release 28) * Mon Mar 08 1999 Preston Brown - whoops, exec-prefix for itcl was set to '/foo', changed to '/usr'. * Tue Feb 16 1999 Jeff Johnson - expect does unaligned access on alpha (#989) - upgrade tcl/tk/tclX to 8.0.4 - upgrade expect to 5.28. - add itcl 3.0.1 * Tue Jan 12 1999 Cristian Gafton - call libtoolize to allow building on the arm - build for glibc 2.1 - strip binaries * Thu Sep 10 1998 Jeff Johnson - update tcl/tk/tclX to 8.0.3, expect is updated also. * Mon Jun 29 1998 Jeff Johnson - expect: mkpasswd needs delay before sending password (problem #576) * Thu May 07 1998 Prospector System - translations modified for de, fr, tr * Sat May 02 1998 Cristian Gafton - fixed expect binaries exec permissions * Thu Apr 09 1998 Erik Troan - updated to Tix 4.1.0.006 - updated version numbers of tcl/tk to relflect includsion of p2 * Wed Mar 25 1998 Cristian Gafton - updated tcl/tk to patch level 2 - updated tclX to 8.0.2 * Thu Oct 30 1997 Otto Hammersmith - fixed filelist for tix... replacing path to the expect binary in scripts was leaving junk files around. * Wed Oct 22 1997 Otto Hammersmith - added patch to remove libieee test in configure.in for tcl and tk. Shoudln't be needed anymore for glibc systems, but this isn't the "proper" solution for all systems - fixed src urls * Mon Oct 06 1997 Erik Troan - removed version numbers from descriptions * Mon Sep 22 1997 Erik Troan - updated to tcl/tk 8.0 and related versions of packages * Tue Jun 17 1997 Erik Troan - built against glibc - fixed dangling tclx/tkx symlinks