From 0b0e5d82dcff6509511502ea436713b6c4488227 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jaroslav=20=C5=A0karvada?= Date: Thu, 15 Aug 2013 17:19:12 +0200 Subject: [PATCH 1/3] New version Resolves: rhbz#889201 - Removed seg_input patch (upstreamed) - Minor cleanups --- tk-8.5.14-conf.patch | 19 ------------ tk-8.5.14-fix-xft.patch | 15 --------- tk-seg_input.patch | 68 ----------------------------------------- tk.spec | 50 +++++++++++++++--------------- tk8.5-make.patch | 13 -------- 5 files changed, 25 insertions(+), 140 deletions(-) delete mode 100644 tk-8.5.14-conf.patch delete mode 100644 tk-8.5.14-fix-xft.patch delete mode 100644 tk-seg_input.patch delete mode 100644 tk8.5-make.patch diff --git a/tk-8.5.14-conf.patch b/tk-8.5.14-conf.patch deleted file mode 100644 index 7ca73ed..0000000 --- a/tk-8.5.14-conf.patch +++ /dev/null @@ -1,19 +0,0 @@ -diff --git a/unix/tcl.m4 b/unix/tcl.m4 -index 668fa2f..9d30b33 100644 ---- a/unix/tcl.m4 -+++ b/unix/tcl.m4 -@@ -1420,12 +1420,12 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [ - # get rid of the warnings. - #CFLAGS_OPTIMIZE="${CFLAGS_OPTIMIZE} -D__NO_STRING_INLINES -D__NO_MATH_INLINES" - -- SHLIB_LD='${CC} -shared ${CFLAGS} ${LDFLAGS}' -+ SHLIB_LD='${CC} -shared ${CFLAGS} ${LDFLAGS} -Wl,-soname,${@}' - DL_OBJS="tclLoadDl.o" - DL_LIBS="-ldl" - LDFLAGS="$LDFLAGS -Wl,--export-dynamic" - AS_IF([test $doRpath = yes], [ -- CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}']) -+ CC_SEARCH_FLAGS='']) - LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} - AS_IF([test "`uname -m`" = "alpha"], [CFLAGS="$CFLAGS -mieee"]) - AS_IF([test $do64bit = yes], [ diff --git a/tk-8.5.14-fix-xft.patch b/tk-8.5.14-fix-xft.patch deleted file mode 100644 index c2cb8e1..0000000 --- a/tk-8.5.14-fix-xft.patch +++ /dev/null @@ -1,15 +0,0 @@ -diff --git a/unix/configure.in b/unix/configure.in -index 85f0a1a..013fed0 100755 ---- a/unix/configure.in -+++ b/unix/configure.in -@@ -478,8 +478,8 @@ if test $tk_aqua = no; then - XFT_LIBS=`xft-config --libs 2>/dev/null` || found_xft="no" - if test "$found_xft" = "no" ; then - found_xft=yes -- XFT_CFLAGS=`pkg-config --cflags xft 2>/dev/null` || found_xft="no" -- XFT_LIBS=`pkg-config --libs xft 2>/dev/null` || found_xft="no" -+ XFT_CFLAGS=`pkg-config --cflags xft freetype2 2>/dev/null` || found_xft="no" -+ XFT_LIBS=`pkg-config --libs xft freetype2 2>/dev/null` || found_xft="no" - fi - AC_MSG_RESULT([$found_xft]) - dnl make sure that compiling against Xft header file doesn't bomb diff --git a/tk-seg_input.patch b/tk-seg_input.patch deleted file mode 100644 index 45e82f6..0000000 --- a/tk-seg_input.patch +++ /dev/null @@ -1,68 +0,0 @@ -diff --git a/generic/tkEvent.c b/generic/tkEvent.c -index 03e7283..25bc504 100644 ---- a/generic/tkEvent.c -+++ b/generic/tkEvent.c -@@ -245,16 +245,10 @@ InvokeFocusHandlers( - } - - /* -- * MouseWheel events are not focus specific on Mac OS X. -+ * Only key-related events are directed according to the focus. - */ - --#ifdef MAC_OSX_TK --#define FOCUS_DIRECTED_EVENT_MASK (KeyPressMask|KeyReleaseMask) --#else --#define FOCUS_DIRECTED_EVENT_MASK (KeyPressMask|KeyReleaseMask|MouseWheelMask) --#endif -- -- if (mask & FOCUS_DIRECTED_EVENT_MASK) { -+ if (mask & (KeyPressMask|KeyReleaseMask)) { - (*winPtrPtr)->dispPtr->lastEventTime = eventPtr->xkey.time; - *winPtrPtr = TkFocusKeyEvent(*winPtrPtr, eventPtr); - if (*winPtrPtr == NULL) { -@@ -738,7 +732,7 @@ InvokeGenericHandlers( - int done; - - tsdPtr->handlersActive++; -- done = (*curPtr->proc)(curPtr->clientData, eventPtr); -+ done = curPtr->proc(curPtr->clientData, eventPtr); - tsdPtr->handlersActive--; - if (done) { - return done; -@@ -1346,7 +1340,7 @@ Tk_HandleEvent( - for (handlerPtr = winPtr->handlerList; handlerPtr != NULL; ) { - if ((handlerPtr->mask & mask) != 0) { - ip.nextHandler = handlerPtr->nextPtr; -- (*(handlerPtr->proc))(handlerPtr->clientData, eventPtr); -+ handlerPtr->proc(handlerPtr->clientData, eventPtr); - handlerPtr = ip.nextHandler; - } else { - handlerPtr = handlerPtr->nextPtr; -@@ -1743,7 +1737,7 @@ WindowEventProc( - return 0; - } - if (tsdPtr->restrictProc != NULL) { -- result = (*tsdPtr->restrictProc)(tsdPtr->restrictArg, &wevPtr->event); -+ result = tsdPtr->restrictProc(tsdPtr->restrictArg, &wevPtr->event); - if (result != TK_PROCESS_EVENT) { - if (result == TK_DEFER_EVENT) { - return 0; -@@ -2059,7 +2053,7 @@ TkFinalize( - - firstExitPtr = exitPtr->nextPtr; - Tcl_MutexUnlock(&exitMutex); -- (*exitPtr->proc)(exitPtr->clientData); -+ exitPtr->proc(exitPtr->clientData); - ckfree((char *) exitPtr); - Tcl_MutexLock(&exitMutex); - } -@@ -2109,7 +2103,7 @@ TkFinalizeThread( - */ - - tsdPtr->firstExitPtr = exitPtr->nextPtr; -- (*exitPtr->proc)(exitPtr->clientData); -+ exitPtr->proc(exitPtr->clientData); - ckfree((char *) exitPtr); - } - } diff --git a/tk.spec b/tk.spec index e2ec3b9..3b4e7c8 100644 --- a/tk.spec +++ b/tk.spec @@ -1,5 +1,5 @@ -%define majorver 8.5 -%define vers %{majorver}.14 +%define majorver 8.6 +%define vers %{majorver}.0 Summary: The graphical toolkit for the Tcl scripting language Name: tk @@ -21,12 +21,10 @@ BuildRequires: libXft-devel Conflicts: itcl <= 3.2 Obsoletes: tile <= 0.8.2 Provides: tile = 0.8.2 -Patch1: tk8.5-make.patch -Patch2: tk-8.5.14-conf.patch -# this patch isn't needed since tk8.6b1 -Patch3: tk-seg_input.patch +Patch1: tk8.6-make.patch +Patch2: tk-8.6.0-conf.patch # fix implicit linkage of freetype that breaks xft detection (#677692) -Patch4: tk-8.5.14-fix-xft.patch +Patch3: tk-8.6.0-fix-xft.patch %description When paired with the Tcl scripting language, Tk provides a fast and powerful @@ -50,14 +48,13 @@ The package contains the development files and man pages for tk. %patch1 -p1 -b .make %patch2 -p1 -b .conf -%patch3 -p1 -b .seg -%patch4 -p1 -b .fix-xft +%patch3 -p1 -b .fix-xft %build cd unix autoconf %configure -make %{?_smp_mflags} TK_LIBRARY=%{_datadir}/%{name}%{majorver} +make %{?_smp_mflags} CFLAGS="%{optflags}" TK_LIBRARY=%{_datadir}/%{name}%{majorver} %check # do not run "make test" by default since it requires an X display @@ -69,27 +66,23 @@ make %{?_smp_mflags} TK_LIBRARY=%{_datadir}/%{name}%{majorver} %endif %install -rm -rf $RPM_BUILD_ROOT -make install -C unix INSTALL_ROOT=$RPM_BUILD_ROOT TK_LIBRARY=%{_datadir}/%{name}%{majorver} +make install -C unix INSTALL_ROOT=%{buildroot} TK_LIBRARY=%{_datadir}/%{name}%{majorver} -ln -s wish%{majorver} $RPM_BUILD_ROOT%{_bindir}/wish +ln -s wish%{majorver} %{buildroot}%{_bindir}/wish # for linking with -l%%{name} -ln -s lib%{name}%{majorver}.so $RPM_BUILD_ROOT%{_libdir}/lib%{name}.so +ln -s lib%{name}%{majorver}.so %{buildroot}%{_libdir}/lib%{name}.so -mkdir -p $RPM_BUILD_ROOT/%{_includedir}/%{name}-private/{generic/ttk,unix} -find generic unix -name "*.h" -exec cp -p '{}' $RPM_BUILD_ROOT/%{_includedir}/%{name}-private/'{}' ';' -( cd $RPM_BUILD_ROOT/%{_includedir} +mkdir -p %{buildroot}/%{_includedir}/%{name}-private/{generic/ttk,unix} +find generic unix -name "*.h" -exec cp -p '{}' %{buildroot}/%{_includedir}/%{name}-private/'{}' ';' +( cd %{buildroot}/%{_includedir} for i in *.h ; do - [ -f $RPM_BUILD_ROOT/%{_includedir}/%{name}-private/generic/$i ] && ln -sf ../../$i $RPM_BUILD_ROOT/%{_includedir}/%{name}-private/generic ; + [ -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|" $RPM_BUILD_ROOT/%{_libdir}/%{name}Config.sh - -%clean -rm -rf $RPM_BUILD_ROOT +sed -i -e "s|$PWD/unix|%{_libdir}|; s|$PWD|%{_includedir}/%{name}-private|" %{buildroot}/%{_libdir}/%{name}Config.sh %pre [ ! -h %{_prefix}/%{_lib}/%{name}%{majorver} ] || rm %{_prefix}/%{_lib}/%{name}%{majorver} @@ -115,10 +108,17 @@ rm -rf $RPM_BUILD_ROOT %{_libdir}/lib%{name}.so %{_libdir}/lib%{name}stub%{majorver}.a %{_libdir}/%{name}Config.sh +%{_libdir}/pkgconfig/tk.pc %{_mandir}/man3/* %{_datadir}/%{name}%{majorver}/tkAppInit.c %changelog +* Thu Aug 15 2013 Jaroslav Škarvada - 1:8.6.0-1 +- New version + Resolves: rhbz#889201 +- Removed seg_input patch (upstreamed) +- Minor cleanups + * Thu Aug 15 2013 Jaroslav Škarvada - 1:8.5.14-1 - New version @@ -260,10 +260,10 @@ rm -rf $RPM_BUILD_ROOT * Tue Jul 31 2007 Marcela Maslanova - 1:8.4.15-1 - Update tk8.4.15 -* Thu Feb 20 2007 Marcela Maslanova - 1:8.4.13-5 +* Tue Feb 20 2007 Marcela Maslanova - 1:8.4.13-5 - rhbz#226494 review again -* Thu Feb 14 2007 Marcela Maslanova - 1:8.4.13-4 +* Wed Feb 14 2007 Marcela Maslanova - 1:8.4.13-4 - rhbz#226494 review * Sat Feb 10 2007 David Cantrell - 1:8.4.13-3 @@ -456,7 +456,7 @@ rm -rf $RPM_BUILD_ROOT * Mon Jan 07 2002 Florian La Roche - fix config.guess and config.sub to newer versions -* Mon Aug 29 2001 Adrian Havill +* Wed Aug 29 2001 Adrian Havill * Mon Aug 8 2001 Adrian Havill - re-enable glibc string and math inlines; recent gcc is a-ok. diff --git a/tk8.5-make.patch b/tk8.5-make.patch deleted file mode 100644 index ae4e938..0000000 --- a/tk8.5-make.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/unix/Makefile.in b/unix/Makefile.in -index 1da2d72..6e925d8 100644 ---- a/unix/Makefile.in -+++ b/unix/Makefile.in -@@ -715,7 +715,7 @@ install-binaries: $(TK_LIB_FILE) $(TK_STUB_LIB_FILE) ${WISH_EXE} - fi - @echo "Installing $(LIB_FILE) to $(DLL_INSTALL_DIR)/" - @@INSTALL_LIB@ -- @chmod 555 "$(DLL_INSTALL_DIR)/$(LIB_FILE)" -+ @chmod 755 "$(DLL_INSTALL_DIR)/$(LIB_FILE)" - @if test -f "tk${MAJOR_VERSION}${MINOR_VERSION}.dll"; then \ - $(INSTALL_LIBRARY) "tk${MAJOR_VERSION}${MINOR_VERSION}.dll" "$(DLL_INSTALL_DIR)";\ - chmod 555 "$(DLL_INSTALL_DIR)/tk${MAJOR_VERSION}${MINOR_VERSION}.dll";\ From d3ba33b555d2c043861a97c98fc119ae4632635b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jaroslav=20=C5=A0karvada?= Date: Thu, 15 Aug 2013 17:26:25 +0200 Subject: [PATCH 2/3] Added patches --- tk-8.6.0-conf.patch | 19 +++++++++++++++++++ tk-8.6.0-fix-xft.patch | 15 +++++++++++++++ tk8.6-make.patch | 13 +++++++++++++ 3 files changed, 47 insertions(+) create mode 100644 tk-8.6.0-conf.patch create mode 100644 tk-8.6.0-fix-xft.patch create mode 100644 tk8.6-make.patch diff --git a/tk-8.6.0-conf.patch b/tk-8.6.0-conf.patch new file mode 100644 index 0000000..7ba9752 --- /dev/null +++ b/tk-8.6.0-conf.patch @@ -0,0 +1,19 @@ +diff --git a/unix/tcl.m4 b/unix/tcl.m4 +index b13fddd..cd9607f 100644 +--- a/unix/tcl.m4 ++++ b/unix/tcl.m4 +@@ -1408,12 +1408,12 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [ + # get rid of the warnings. + #CFLAGS_OPTIMIZE="${CFLAGS_OPTIMIZE} -D__NO_STRING_INLINES -D__NO_MATH_INLINES" + +- SHLIB_LD='${CC} -shared ${CFLAGS} ${LDFLAGS}' ++ SHLIB_LD='${CC} -shared ${CFLAGS} ${LDFLAGS} -Wl,-soname,${@}' + DL_OBJS="tclLoadDl.o" + DL_LIBS="-ldl" + LDFLAGS="$LDFLAGS -Wl,--export-dynamic" + AS_IF([test $doRpath = yes], [ +- CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}']) ++ CC_SEARCH_FLAGS='']) + LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} + AS_IF([test "`uname -m`" = "alpha"], [CFLAGS="$CFLAGS -mieee"]) + AS_IF([test $do64bit = yes], [ diff --git a/tk-8.6.0-fix-xft.patch b/tk-8.6.0-fix-xft.patch new file mode 100644 index 0000000..bc7dbf6 --- /dev/null +++ b/tk-8.6.0-fix-xft.patch @@ -0,0 +1,15 @@ +diff --git a/unix/configure.in b/unix/configure.in +index abc8a1d..065a6c2 100755 +--- a/unix/configure.in ++++ b/unix/configure.in +@@ -557,8 +557,8 @@ if test $tk_aqua = no; then + XFT_LIBS=`xft-config --libs 2>/dev/null` || found_xft="no" + if test "$found_xft" = "no" ; then + found_xft=yes +- XFT_CFLAGS=`pkg-config --cflags xft 2>/dev/null` || found_xft="no" +- XFT_LIBS=`pkg-config --libs xft 2>/dev/null` || found_xft="no" ++ XFT_CFLAGS=`pkg-config --cflags xft freetype2 2>/dev/null` || found_xft="no" ++ XFT_LIBS=`pkg-config --libs xft freetype2 2>/dev/null` || found_xft="no" + fi + AC_MSG_RESULT([$found_xft]) + dnl make sure that compiling against Xft header file doesn't bomb diff --git a/tk8.6-make.patch b/tk8.6-make.patch new file mode 100644 index 0000000..708bb62 --- /dev/null +++ b/tk8.6-make.patch @@ -0,0 +1,13 @@ +diff --git a/unix/Makefile.in b/unix/Makefile.in +index 1df6721..08017a4 100644 +--- a/unix/Makefile.in ++++ b/unix/Makefile.in +@@ -744,7 +744,7 @@ install-binaries: $(TK_LIB_FILE) $(TK_STUB_LIB_FILE) ${WISH_EXE} + fi + @echo "Installing $(LIB_FILE) to $(DLL_INSTALL_DIR)/" + @@INSTALL_LIB@ +- @chmod 555 "$(DLL_INSTALL_DIR)/$(LIB_FILE)" ++ @chmod 755 "$(DLL_INSTALL_DIR)/$(LIB_FILE)" + @if test -f "tk${MAJOR_VERSION}${MINOR_VERSION}.dll"; then \ + $(INSTALL_LIBRARY) "tk${MAJOR_VERSION}${MINOR_VERSION}.dll" "$(DLL_INSTALL_DIR)";\ + chmod 555 "$(DLL_INSTALL_DIR)/tk${MAJOR_VERSION}${MINOR_VERSION}.dll";\ From e94131cd5e10c9343aec2d5814cb1b2a87b29d13 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jaroslav=20=C5=A0karvada?= Date: Thu, 24 Apr 2014 17:17:50 +0200 Subject: [PATCH 3/3] New version - Defuzzified patches --- tk-8.6.0-conf.patch => tk-8.6.1-conf.patch | 4 ++-- tk-8.6.0-fix-xft.patch => tk-8.6.1-fix-xft.patch | 4 ++-- tk8.6-make.patch => tk-8.6.1-make.patch | 4 ++-- tk.spec | 12 ++++++++---- 4 files changed, 14 insertions(+), 10 deletions(-) rename tk-8.6.0-conf.patch => tk-8.6.1-conf.patch (88%) rename tk-8.6.0-fix-xft.patch => tk-8.6.1-fix-xft.patch (88%) rename tk8.6-make.patch => tk-8.6.1-make.patch (84%) diff --git a/tk-8.6.0-conf.patch b/tk-8.6.1-conf.patch similarity index 88% rename from tk-8.6.0-conf.patch rename to tk-8.6.1-conf.patch index 7ba9752..77af588 100644 --- a/tk-8.6.0-conf.patch +++ b/tk-8.6.1-conf.patch @@ -1,8 +1,8 @@ diff --git a/unix/tcl.m4 b/unix/tcl.m4 -index b13fddd..cd9607f 100644 +index 194cf90..c470e36 100644 --- a/unix/tcl.m4 +++ b/unix/tcl.m4 -@@ -1408,12 +1408,12 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [ +@@ -1415,12 +1415,12 @@ AC_DEFUN([SC_CONFIG_CFLAGS], [ # get rid of the warnings. #CFLAGS_OPTIMIZE="${CFLAGS_OPTIMIZE} -D__NO_STRING_INLINES -D__NO_MATH_INLINES" diff --git a/tk-8.6.0-fix-xft.patch b/tk-8.6.1-fix-xft.patch similarity index 88% rename from tk-8.6.0-fix-xft.patch rename to tk-8.6.1-fix-xft.patch index bc7dbf6..fbe6596 100644 --- a/tk-8.6.0-fix-xft.patch +++ b/tk-8.6.1-fix-xft.patch @@ -1,8 +1,8 @@ diff --git a/unix/configure.in b/unix/configure.in -index abc8a1d..065a6c2 100755 +index e7bf023..7d12f41 100755 --- a/unix/configure.in +++ b/unix/configure.in -@@ -557,8 +557,8 @@ if test $tk_aqua = no; then +@@ -485,8 +485,8 @@ if test $tk_aqua = no; then XFT_LIBS=`xft-config --libs 2>/dev/null` || found_xft="no" if test "$found_xft" = "no" ; then found_xft=yes diff --git a/tk8.6-make.patch b/tk-8.6.1-make.patch similarity index 84% rename from tk8.6-make.patch rename to tk-8.6.1-make.patch index 708bb62..e9ec18f 100644 --- a/tk8.6-make.patch +++ b/tk-8.6.1-make.patch @@ -1,8 +1,8 @@ diff --git a/unix/Makefile.in b/unix/Makefile.in -index 1df6721..08017a4 100644 +index 3914940..a69df0e 100644 --- a/unix/Makefile.in +++ b/unix/Makefile.in -@@ -744,7 +744,7 @@ install-binaries: $(TK_LIB_FILE) $(TK_STUB_LIB_FILE) ${WISH_EXE} +@@ -743,7 +743,7 @@ install-binaries: $(TK_LIB_FILE) $(TK_STUB_LIB_FILE) ${WISH_EXE} fi @echo "Installing $(LIB_FILE) to $(DLL_INSTALL_DIR)/" @@INSTALL_LIB@ diff --git a/tk.spec b/tk.spec index 3b4e7c8..61b5333 100644 --- a/tk.spec +++ b/tk.spec @@ -1,5 +1,5 @@ %define majorver 8.6 -%define vers %{majorver}.0 +%define vers %{majorver}.1 Summary: The graphical toolkit for the Tcl scripting language Name: tk @@ -21,10 +21,10 @@ BuildRequires: libXft-devel Conflicts: itcl <= 3.2 Obsoletes: tile <= 0.8.2 Provides: tile = 0.8.2 -Patch1: tk8.6-make.patch -Patch2: tk-8.6.0-conf.patch +Patch1: tk-8.6.1-make.patch +Patch2: tk-8.6.1-conf.patch # fix implicit linkage of freetype that breaks xft detection (#677692) -Patch3: tk-8.6.0-fix-xft.patch +Patch3: tk-8.6.1-fix-xft.patch %description When paired with the Tcl scripting language, Tk provides a fast and powerful @@ -113,6 +113,10 @@ sed -i -e "s|$PWD/unix|%{_libdir}|; s|$PWD|%{_includedir}/%{name}-private|" %{bu %{_datadir}/%{name}%{majorver}/tkAppInit.c %changelog +* Thu Apr 24 2014 Jaroslav Škarvada - 1:8.6.1-1 +- New version +- Defuzzified patches + * Thu Aug 15 2013 Jaroslav Škarvada - 1:8.6.0-1 - New version Resolves: rhbz#889201