pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/misc/openoffice2 - Fix mutex handling in patch-ck.



details:   https://anonhg.NetBSD.org/pkgsrc/rev/b1086d0684c7
branches:  trunk
changeset: 529749:b1086d0684c7
user:      hira <hira%pkgsrc.org@localhost>
date:      Sun Jun 10 04:55:06 2007 +0000

description:
- Fix mutex handling in patch-ck.
 - Set PTHREAD_DIAGASSERT to "AEL" in startup script.
 - Remove PTHREAD_DIAGASSERT from build environment.

This should fix PR pkg/36364.  Bump PKGREVISION.

diffstat:

 misc/openoffice2/Makefile         |   6 ++--
 misc/openoffice2/distinfo         |   6 ++-
 misc/openoffice2/patches/patch-ck |  53 ++++++++++++++++++++++++++++++--------
 misc/openoffice2/patches/patch-cm |  13 +++++++++
 misc/openoffice2/patches/patch-cn |  17 ++++++++++++
 5 files changed, 78 insertions(+), 17 deletions(-)

diffs (139 lines):

diff -r 0be66e20af6d -r b1086d0684c7 misc/openoffice2/Makefile
--- a/misc/openoffice2/Makefile Sun Jun 10 04:44:35 2007 +0000
+++ b/misc/openoffice2/Makefile Sun Jun 10 04:55:06 2007 +0000
@@ -1,8 +1,8 @@
-# $NetBSD: Makefile,v 1.18 2007/06/05 05:42:58 wiz Exp $
+# $NetBSD: Makefile,v 1.19 2007/06/10 04:55:06 hira Exp $
 #
 
 OO_VER=                        2.2.0
-PKGREVISION=           3
+PKGREVISION=           4
 DISTNAME=              openoffice-${OO_VER}
 PKGNAME=               openoffice2-${OO_VER}
 CATEGORIES=            misc
@@ -89,7 +89,7 @@
                ${WRKSRC}/bridges/inc/bridges/cpp_uno/
 
 do-build:
-       ${_ULIMIT_CMD} ${SETENV} ${MAKE_ENV} bash -c "export PTHREAD_DIAGASSERT=Ael && cd ${WRKSRC} && ./bootstrap && source ${OPENOFFICE_SETFILE}Env.Set.sh && dmake build_all"
+       ${_ULIMIT_CMD} ${SETENV} ${MAKE_ENV} bash -c "cd ${WRKSRC} && ./bootstrap && source ${OPENOFFICE_SETFILE}Env.Set.sh && dmake build_all"
 
 post-build:
        cd ${WRKDIR} &&                                         \
diff -r 0be66e20af6d -r b1086d0684c7 misc/openoffice2/distinfo
--- a/misc/openoffice2/distinfo Sun Jun 10 04:44:35 2007 +0000
+++ b/misc/openoffice2/distinfo Sun Jun 10 04:55:06 2007 +0000
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.16 2007/04/22 23:15:24 hira Exp $
+$NetBSD: distinfo,v 1.17 2007/06/10 04:55:06 hira Exp $
 
 SHA1 (openoffice-2.2.0/OOo_2.2.0_src_binfilter.tar.bz2) = d1fa827e2c08d7e3d67b2588b1136ed9e774ef42
 RMD160 (openoffice-2.2.0/OOo_2.2.0_src_binfilter.tar.bz2) = 1bb07f01e872ed003dbac3e11bc5732904076ae1
@@ -60,5 +60,7 @@
 SHA1 (patch-ch) = bcfeb99318a16e83f2e54fb94d275224c67182fb
 SHA1 (patch-ci) = 2861e8a4b21977cbc8abeabe4581093e966cdfa7
 SHA1 (patch-cj) = c54fd98e5302a86ec849b90c617ebfcf339c936d
-SHA1 (patch-ck) = e7d9f3043ac975c7e13937b1d47650a5de7a3d36
+SHA1 (patch-ck) = aa283e89aa3139d560da6382c73a57987319472f
 SHA1 (patch-cl) = cf405103c2adc7df68d148ed58e8f5700ae16524
+SHA1 (patch-cm) = e39bf825affbd9c5a19c68f783cb95e52eb56994
+SHA1 (patch-cn) = 67afccde1d7bfa42ec4082067189da23ada97190
diff -r 0be66e20af6d -r b1086d0684c7 misc/openoffice2/patches/patch-ck
--- a/misc/openoffice2/patches/patch-ck Sun Jun 10 04:44:35 2007 +0000
+++ b/misc/openoffice2/patches/patch-ck Sun Jun 10 04:55:06 2007 +0000
@@ -1,15 +1,44 @@
-$NetBSD: patch-ck,v 1.1 2007/04/22 23:15:25 hira Exp $
+$NetBSD: patch-ck,v 1.2 2007/06/10 04:55:06 hira Exp $
 
---- vcl/unx/gtk/app/gtkinst.cxx.orig   2007-04-23 05:50:27.000000000 +0900
-+++ vcl/unx/gtk/app/gtkinst.cxx        2007-04-23 05:51:07.000000000 +0900
-@@ -329,7 +329,9 @@
-     // that locked the mutex with Grab()
+--- vcl/unx/gtk/app/gtkinst.cxx.orig   2006-09-17 21:29:23.000000000 +0900
++++ vcl/unx/gtk/app/gtkinst.cxx        2007-06-10 11:50:10.000000000 +0900
+@@ -221,6 +221,7 @@
+ 
+ GtkYieldMutex::GtkYieldMutex()
+ {
++      mutex_locked = 0;
+ }
+ 
+ void GtkYieldMutex::acquire()
+@@ -237,7 +238,10 @@
+     OMutex::release();
+     
+     // obtain gdk mutex
+-    gdk_threads_enter();
++    // gdk_threads_enter();
++    /* XXX: With systray quickstarter, the mutex is already locking. */
++    if( g_mutex_trylock( gdk_threads_mutex ) )
++      mutex_locked = 1;
+ 
+     // obtained gdk mutex, now lock count is one by definition
      OMutex::acquire();
-     mnCount = nGrabs;
--    if( mnCount == 0 )
-+    if( mnCount == 0 ) {
-+        gdk_threads_leave();
-         mnThreadId = 0;
-+    }
+@@ -257,7 +261,10 @@
+         mnCount--;
+         if( mnCount == 0 )
+         {
+-            gdk_threads_leave();
++          if (mutex_locked) {
++                gdk_threads_leave();
++              mutex_locked = 0;
++            }
+             mnThreadId = 0;
+         }
+     }
+@@ -292,6 +299,7 @@
+     
+     // obtained gdk mutex, now lock count is one by definition
+     OMutex::acquire();
++    mutex_locked = 1;
+     mnCount = 1;
+     mnThreadId = aCurrentThread;
      OMutex::release();
- }
diff -r 0be66e20af6d -r b1086d0684c7 misc/openoffice2/patches/patch-cm
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/misc/openoffice2/patches/patch-cm Sun Jun 10 04:55:06 2007 +0000
@@ -0,0 +1,13 @@
+$NetBSD: patch-cm,v 1.1 2007/06/10 04:55:06 hira Exp $
+
+--- vcl/unx/inc/plugins/gtk/gtkinst.hxx.orig   2007-06-09 19:42:20.000000000 +0900
++++ vcl/unx/inc/plugins/gtk/gtkinst.hxx        2007-06-09 19:42:49.000000000 +0900
+@@ -47,6 +47,8 @@
+       virtual void                                                            release();
+       virtual sal_Bool                                                        tryToAcquire();
+ 
++    int mutex_locked;
++
+     virtual int Grab();
+     virtual void Ungrab( int );
+ 
diff -r 0be66e20af6d -r b1086d0684c7 misc/openoffice2/patches/patch-cn
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/misc/openoffice2/patches/patch-cn Sun Jun 10 04:55:06 2007 +0000
@@ -0,0 +1,17 @@
+$NetBSD: patch-cn,v 1.1 2007/06/10 04:55:06 hira Exp $
+
+--- desktop/scripts/soffice.sh.orig    2007-06-10 11:44:31.000000000 +0900
++++ desktop/scripts/soffice.sh 2007-06-10 11:45:05.000000000 +0900
+@@ -55,6 +55,12 @@
+     export JITC_PROCESSOR_TYPE
+ fi
+ 
++# XXX: Ignore "unlocking unlocked mutex" error.
++if [ $sd_platform = "NetBSD" ]; then
++    PTHREAD_DIAGASSERT=AEL
++    export PTHREAD_DIAGASSERT
++fi
++
+ # set -x
+ 
+ # resolve installation directory



Home | Main Index | Thread Index | Old Index