%define majorver 8.5 %define libname %mklibname %{name} %majorver %define develname %mklibname %{name} -d Summary: Tool Command Language, pronounced tickle Name: tcl Version: 8.5.13 Release: %mkrel 1 Epoch: 1 License: TCL Group: Development/Other URL: http://tcl.sourceforge.net/ Source0: http://downloads.sourceforge.net/tcl/tcl%{version}-src.tar.gz Source1: tcl.macros Patch0: tcl-8.5.1-autopath.patch Patch1: tcl-8.5.10-conf.patch Patch2: tcl-8.5.12-hidden.patch Requires: %{libname} = %{epoch}:%{version} %description The Tcl (Tool Command Language) provides a powerful platform for creating integration applications that tie together diverse applications, protocols, devices, and frameworks. When paired with the Tk toolkit, Tcl provides a fastest and powerful way to create cross-platform GUI applications. Tcl can also be used for a variety of web-related tasks and for creating powerful command languages for applications. %package -n %{libname} Summary: Shared libraries for %{name} Group: System/Libraries %description -n %{libname} The Tcl (Tool Command Language) provides a powerful platform for creating integration applications that tie together diverse applications, protocols, devices, and frameworks. When paired with the Tk toolkit, Tcl provides a fastest and powerful way to create cross-platform GUI applications. Tcl can also be used for a variety of web-related tasks and for creating powerful command languages for applications. If you're installing the tcl package and you want to use Tcl for development, you should also install the tk and tclx packages. %package -n %develname Summary: Tcl scripting language development environment Group: Development/Other Requires: %{name} = %{epoch}:%{version}-%{release} Requires: %{libname} = %{epoch}:%{version}-%{release} Provides: %{name}-devel = %{epoch}:%{version}-%{release} %description -n %develname The Tcl (Tool Command Language) provides a powerful platform for creating integration applications that tie together diverse applications, protocols, devices, and frameworks. When paired with the Tk toolkit, Tcl provides a fastest and powerful way to create cross-platform GUI applications. Tcl can also be used for a variety of web-related tasks and for creating powerful command languages for applications. The package contains the development files and man pages for tcl. %prep %setup -q -n %{name}%{version} chmod -x generic/tclThreadAlloc.c %patch0 -p1 -b .autopath %patch1 -p1 -b .conf %patch2 -p1 -b .hidden %build pushd unix autoconf export CFLAGS="%optflags -DTCL_NO_STACK_CHECK=1" %configure2_5x \ --enable-threads \ --enable-symbols \ --enable-shared %make \ TCL_LIBRARY=%{_datadir}/%{name}%{majorver} %install rm -rf %{buildroot} make install -C unix INSTALL_ROOT=%{buildroot} TCL_LIBRARY=%{_datadir}/%{name}%{majorver} ln -s tclsh%{majorver} %{buildroot}%{_bindir}/tclsh # for linking with -lib%%{name} ln -s lib%{name}%{majorver}.so %{buildroot}%{_libdir}/lib%{name}.so mkdir -p %{buildroot}/%{_libdir}/%{name}%{majorver} # postgresql and maybe other packages too need tclConfig.sh # paths don't look at /usr/lib for efficiency, so we symlink into tcl8.5 for now ln -s %{_libdir}/%{name}Config.sh %{buildroot}/%{_libdir}/%{name}%{majorver}/%{name}Config.sh mkdir -p %{buildroot}/%{_includedir}/%{name}-private/{generic,unix} find generic unix -name "*.h" -exec cp -p '{}' %{buildroot}/%{_includedir}/%{name}-private/'{}' ';' ( cd %{buildroot}/%{_includedir} for i in *.h ; do [ -f %{buildroot}/%{_includedir}/%{name}-private/generic/$i ] && ln -sf ../../$i %{buildroot}/%{_includedir}/%{name}-private/generic ; done ) # remove buildroot traces sed -i -e "s|$PWD/unix|%{_libdir}|; s|$PWD|%{_includedir}/%{name}-private|" %{buildroot}/%{_libdir}/%{name}Config.sh rm -rf %{buildroot}/%{_datadir}/%{name}%{majorver}/ldAix install -m0644 -D %{SOURCE1} %buildroot%_sysconfdir/rpm/macros.d/%name.macros %clean rm -rf %{buildroot} %files %defattr(-,root,root,-) %doc README changes license.terms %{_bindir}/tclsh* %{_datadir}/%{name}%{majorver} %exclude %{_datadir}/%{name}%{majorver}/tclAppInit.c %{_datadir}/%{name}8 %{_mandir}/man1/* %{_mandir}/man3/* %{_mandir}/mann/* %dir %{_libdir}/%{name}%{majorver} %files -n %libname %defattr(-,root,root,-) %{_libdir}/lib%{name}%{majorver}.so %files -n %develname %defattr(-,root,root,-) %_sysconfdir/rpm/macros.d/%name.macros %{_includedir}/* %{_libdir}/lib%{name}stub%{majorver}.a %{_libdir}/lib%{name}.so %{_libdir}/%{name}Config.sh %{_libdir}/%{name}%{majorver}/%{name}Config.sh %{_datadir}/%{name}%{majorver}/tclAppInit.c %changelog * Sat Nov 10 2012 fwang <fwang> 1:8.5.13-1.mga3 + Revision: 316805 - new version 8.5.13 * Sat Sep 08 2012 fwang <fwang> 1:8.5.12-3.mga3 + Revision: 289972 - enable thread for ruby 1.9 * Sun Aug 05 2012 fwang <fwang> 1:8.5.12-2.mga3 + Revision: 278587 - add requires so that correct libs are installed * Sat Jul 28 2012 fwang <fwang> 1:8.5.12-1.mga3 + Revision: 275126 - new version 8.5.12 * Fri Nov 11 2011 fwang <fwang> 1:8.5.11-1.mga2 + Revision: 166816 - new version 8.5.11 * Mon Jul 04 2011 ahmad <ahmad> 1:8.5.10-3.mga2 + Revision: 117971 - Don't ship lib%%{name}%%{majorver}.so in both the main package and libname * Sat Jul 02 2011 fwang <fwang> 1:8.5.10-2.mga2 + Revision: 117283 - add tcl.macros * Fri Jul 01 2011 fwang <fwang> 1:8.5.10-1.mga2 + Revision: 117199 - fix desc - revert to 8.5 stable releases - sync with fedora's patch * Thu May 05 2011 misc <misc> 8.6-0.b1.7.mga1 + Revision: 95192 - rebuild with the system zlib, to avoid crash on scilab + spuhler <spuhler> - removed buildroot definition from .spec * Sat Jan 08 2011 blino <blino> 8.6-0.b1.6.mga1 + Revision: 957 - remove old ldconfig scriptlets - imported package tcl