This commit is contained in:
parent
0d653ca0d3
commit
ad84bc50cd
14
macros.tcl
Normal file
14
macros.tcl
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
# RPM macros for Tcl
|
||||||
|
|
||||||
|
# The minor version of Tcl
|
||||||
|
%tcl_version %(echo 'puts [info tclversion]'|tclsh)
|
||||||
|
|
||||||
|
# compiled packges should go here
|
||||||
|
%tcl_archdir %(echo 'puts [lindex $tcl_pkgPath 0]'|tclsh)
|
||||||
|
|
||||||
|
# script-only packages should go here
|
||||||
|
%tcl_noarchdir %(echo 'puts [lindex $tcl_pkgPath 1]'|tclsh)
|
||||||
|
|
||||||
|
# tclscriptdir is deprecated, please use tcl_archdir or
|
||||||
|
# tcl_noarchdir instead, depending on the type of your package
|
||||||
|
%tclscriptdir %tcl_noarchdir
|
38
tcl-format.patch
Normal file
38
tcl-format.patch
Normal file
@ -0,0 +1,38 @@
|
|||||||
|
Index: generic/tclStringObj.c
|
||||||
|
===================================================================
|
||||||
|
RCS file: /cvsroot/tcl/tcl/generic/tclStringObj.c,v
|
||||||
|
retrieving revision 1.70
|
||||||
|
diff -u -r1.70 tclStringObj.c
|
||||||
|
--- generic/tclStringObj.c 28 Feb 2008 17:36:49 -0000 1.70
|
||||||
|
+++ generic/tclStringObj.c 7 Apr 2008 15:12:36 -0000
|
||||||
|
@@ -2003,8 +2003,8 @@
|
||||||
|
allocSegment = 1;
|
||||||
|
Tcl_IncrRefCount(segment);
|
||||||
|
|
||||||
|
- if ((isNegative || gotPlus) && (useBig || (ch == 'd'))) {
|
||||||
|
- Tcl_AppendToObj(segment, (isNegative ? "-" : "+"), 1);
|
||||||
|
+ if ((isNegative || gotPlus || gotSpace) && (useBig || (ch == 'd'))) {
|
||||||
|
+ Tcl_AppendToObj(segment, (isNegative ? "-" : gotPlus ? "+" : " "), 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (gotHash) {
|
||||||
|
Index: tests/format.test
|
||||||
|
===================================================================
|
||||||
|
RCS file: /cvsroot/tcl/tcl/tests/format.test,v
|
||||||
|
retrieving revision 1.25
|
||||||
|
diff -u -r1.25 format.test
|
||||||
|
--- tests/format.test 10 Jan 2008 16:09:23 -0000 1.25
|
||||||
|
+++ tests/format.test 7 Apr 2008 15:12:36 -0000
|
||||||
|
@@ -496,6 +496,12 @@
|
||||||
|
test format-15.4 {testing %0..s 0 padding for chars/strings} {
|
||||||
|
format %05c 61
|
||||||
|
} {0000=}
|
||||||
|
+test format-15.5 {testing %d space padding for integers} {
|
||||||
|
+ format "(% 1d) (% 1d)" 10 -10
|
||||||
|
+} {( 10) (-10)}
|
||||||
|
+test format-15.6 {testing %d plus padding for integers} {
|
||||||
|
+ format "(%+1d) (%+1d)" 10 -10
|
||||||
|
+} {(+10) (-10)}
|
||||||
|
|
||||||
|
set a "0123456789"
|
||||||
|
set b ""
|
@ -1,3 +1,9 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Mon Apr 7 21:15:17 CEST 2008 - max@suse.de
|
||||||
|
|
||||||
|
- Added /etc/rpm/macros.tcl
|
||||||
|
- Fixed behaviour of "% d" format string.
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Wed Apr 2 18:04:42 CEST 2008 - max@suse.de
|
Wed Apr 2 18:04:42 CEST 2008 - max@suse.de
|
||||||
|
|
||||||
|
10
tcl.spec
10
tcl.spec
@ -14,7 +14,7 @@
|
|||||||
Name: tcl
|
Name: tcl
|
||||||
Url: http://www.tcl.tk
|
Url: http://www.tcl.tk
|
||||||
Version: 8.5.2
|
Version: 8.5.2
|
||||||
Release: 2
|
Release: 4
|
||||||
%define TCL_MINOR %(echo %version | cut -c1-3)
|
%define TCL_MINOR %(echo %version | cut -c1-3)
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
Summary: The Tcl Programming Language
|
Summary: The Tcl Programming Language
|
||||||
@ -26,7 +26,9 @@ PreReq: /bin/rm
|
|||||||
Source0: %name%{version}-src.tar.bz2
|
Source0: %name%{version}-src.tar.bz2
|
||||||
Source1: tcl-rpmlintrc
|
Source1: tcl-rpmlintrc
|
||||||
Source2: baselibs.conf
|
Source2: baselibs.conf
|
||||||
|
Source3: macros.tcl
|
||||||
Patch0: tcl.patch
|
Patch0: tcl.patch
|
||||||
|
Patch1: tcl-format.patch
|
||||||
|
|
||||||
%description
|
%description
|
||||||
Tcl (Tool Command Language) is a very powerful but easy to learn
|
Tcl (Tool Command Language) is a very powerful but easy to learn
|
||||||
@ -68,6 +70,7 @@ Authors:
|
|||||||
%prep
|
%prep
|
||||||
%setup -q -n %name%version
|
%setup -q -n %name%version
|
||||||
%patch0
|
%patch0
|
||||||
|
%patch1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
cd unix
|
cd unix
|
||||||
@ -110,6 +113,7 @@ make -C unix install install-private-headers \
|
|||||||
rm -f %buildroot%scriptdir/tcl%TCL_MINOR/ldAix
|
rm -f %buildroot%scriptdir/tcl%TCL_MINOR/ldAix
|
||||||
ln -sf tclsh%TCL_MINOR %buildroot%_prefix/bin/tclsh
|
ln -sf tclsh%TCL_MINOR %buildroot%_prefix/bin/tclsh
|
||||||
mkdir -p %buildroot%_datadir/tcl
|
mkdir -p %buildroot%_datadir/tcl
|
||||||
|
install -D %{S:3} %buildroot/etc/rpm/macros.tcl
|
||||||
|
|
||||||
%clean
|
%clean
|
||||||
rm -rf %buildroot
|
rm -rf %buildroot
|
||||||
@ -131,6 +135,7 @@ exit 0
|
|||||||
%_datadir/tcl
|
%_datadir/tcl
|
||||||
%scriptdir
|
%scriptdir
|
||||||
%exclude %scriptdir/*/tclAppInit.c
|
%exclude %scriptdir/*/tclAppInit.c
|
||||||
|
/etc/rpm/macros.tcl
|
||||||
|
|
||||||
%files devel
|
%files devel
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
@ -141,6 +146,9 @@ exit 0
|
|||||||
%_libdir/tclConfig.sh
|
%_libdir/tclConfig.sh
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Apr 07 2008 max@suse.de
|
||||||
|
- Added /etc/rpm/macros.tcl
|
||||||
|
- Fixed behaviour of "%% d" format string.
|
||||||
* Wed Apr 02 2008 max@suse.de
|
* Wed Apr 02 2008 max@suse.de
|
||||||
- New release: 8.5.2:
|
- New release: 8.5.2:
|
||||||
* Speed: 8.5 now runs 10%% faster than 8.4 with bytecode
|
* Speed: 8.5 now runs 10%% faster than 8.4 with bytecode
|
||||||
|
Loading…
Reference in New Issue
Block a user