Bernhard Froehlich <[email protected]> writes:

> On Thu, 31 Mar 2011 09:41:48 +0400, Pan Tsu wrote:
>> Mozilla devs recently disabled the option
>> 
>>   https://bugzilla.mozilla.org/show_bug.cgi?id=638755
>> 
>> mozilla-central (aka trunk) still builds fine on FreeBSD but I wonder
>> how long it'll remain so.
>> 
>> So, do you plan to fix IPC port[1], probably using some pieces from
>> www/chromium, or try keep --disable-ipc as long as possible?
>> 
>> [1] it was removed in r430
>> 
>>       http://trillian.chruetertee.ch/freebsd-gecko/changeset/430
>
> Thanks for the hint. We will definitely need to talk to the Mozilla
> guys about that. The IPC code is just not working on FreeBSD in it's
> current state and beat@ created some patch in the firefox 3.6.x days
> that is not stable but hopefully a good starting point.

Hmm, IPC seems stable for me. Tested on

  67597:fb566937c787, PGO build, -Ofast, ports/146231

flash plugin no longer causes rendering glitches with vdpau, not sure if
it's because of IPC or an update.

%% build hacks for r67597
Index: www/firefox/Makefile
===================================================================
RCS file: /a/.cvsup/ports/www/firefox/Makefile,v
retrieving revision 1.239
diff -u -p -r1.239 Makefile
--- www/firefox/Makefile        24 Mar 2011 11:04:17 -0000      1.239
+++ www/firefox/Makefile        7 Apr 2011 20:24:51 -0000
@@ -18,6 +17,7 @@ MAINTAINER=   [email protected]
 COMMENT=       Web browser based on the browser portion of Mozilla
 
 BUILD_DEPENDS= nspr>=4.8.7:${PORTSDIR}/devel/nspr
+LIB_DEPENDS=   execinfo.1:${PORTSDIR}/devel/libexecinfo
 
 USE_AUTOTOOLS= autoconf213
 USE_GECKO=     gecko
@@ -54,5 +52,9 @@ OPTIONS=      DBUS "Enable D-BUS support" on 
                PGO "Enable Profile-Guided Optimization" off \
                SMB "Enable smb:// URI support using gnomevfs" off
 
+# XXX: what is gcc46 specific?
+CXXFLAGS+=     -fpermissive
+MOZ_OPTIONS+=  --disable-warnings-as-errors
+
 .include <bsd.port.pre.mk>
 
@@ -108,6 +112,9 @@ post-extract::
                <${FILESDIR}/firefox.desktop.in >${WRKDIR}/${MOZILLA}.desktop
 
 post-patch:
+       @${GREP} -Flr \"/proc ${WRKSRC}/ipc/chromium/src/base | ${XARGS} 
${REINPLACE_CMD} \
+               -e 's|/proc/self/fd|/dev/fd|' \
+               -e 's|/proc["/]|/compat/linux&|'
        ${REINPLACE_CMD} -e 
's|%%PTHREAD_LIBS%%|${PTHREAD_LIBS:C/-pthread/${GECKO_PTHREAD_LIBS}/}|' \
                ${WRKSRC}/storage/build/Makefile.in \
                ${WRKSRC}/toolkit/library/Makefile.in \
Index: 
www/firefox/files/patch-ipc-chromium-src-base-atomicops_internals_mutex.cc
===================================================================
RCS file: 
www/firefox/files/patch-ipc-chromium-src-base-atomicops_internals_mutex.cc
diff -N 
www/firefox/files/patch-ipc-chromium-src-base-atomicops_internals_mutex.cc
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ www/firefox/files/patch-ipc-chromium-src-base-atomicops_internals_mutex.cc  
7 Apr 2011 15:10:16 -0000
@@ -0,0 +1,10 @@
+--- ipc/chromium/src/base/atomicops_internals_mutex.cc~
++++ ipc/chromium/src/base/atomicops_internals_mutex.cc
+@@ -39,6 +39,7 @@
+  * ***** END LICENSE BLOCK ***** */
+ 
+ #include "base/atomicops.h"
++#include "base/lock.h"
+ 
+ namespace base {
+ namespace subtle {
Index: www/firefox/files/patch-ipc-chromium-src-base-file_util.h
===================================================================
RCS file: www/firefox/files/patch-ipc-chromium-src-base-file_util.h
diff -N www/firefox/files/patch-ipc-chromium-src-base-file_util.h
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ www/firefox/files/patch-ipc-chromium-src-base-file_util.h   7 Apr 2011 
15:10:16 -0000
@@ -0,0 +1,13 @@
+--- ipc/chromium/src/base/file_util.h~
++++ ipc/chromium/src/base/file_util.h
+@@ -15,8 +15,9 @@
+ #elif defined(ANDROID)
+ #include <sys/stat.h>
+ #elif defined(OS_POSIX) 
++#include <sys/types.h>
++#include <sys/stat.h>
+ #include <fts.h>
+-#include <sys/stat.h>
+ #endif
+ 
+ #include <stdio.h>
Index: www/firefox/files/patch-ipc-chromium-src-base-file_util_linux.cc
===================================================================
RCS file: www/firefox/files/patch-ipc-chromium-src-base-file_util_linux.cc
diff -N www/firefox/files/patch-ipc-chromium-src-base-file_util_linux.cc
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ www/firefox/files/patch-ipc-chromium-src-base-file_util_linux.cc    7 Apr 
2011 15:10:16 -0000
@@ -0,0 +1,11 @@
+--- ipc/chromium/src/base/file_util_linux.cc~
++++ ipc/chromium/src/base/file_util_linux.cc
+@@ -28,7 +28,7 @@ bool GetShmemTempDir(FilePath* path) {
+ #ifdef ANDROID
+   return GetTempDir(path);
+ #else
+-  *path = FilePath("/dev/shm");
++  *path = FilePath("/tmp");
+   return true;
+ #endif
+ }
Index: www/firefox/files/patch-ipc-chromium-src-base-file_util_posix.cc
===================================================================
RCS file: www/firefox/files/patch-ipc-chromium-src-base-file_util_posix.cc
diff -N www/firefox/files/patch-ipc-chromium-src-base-file_util_posix.cc
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ www/firefox/files/patch-ipc-chromium-src-base-file_util_posix.cc    7 Apr 
2011 15:10:16 -0000
@@ -0,0 +1,11 @@
+--- ipc/chromium/src/base/file_util_posix.cc~
++++ ipc/chromium/src/base/file_util_posix.cc
+@@ -30,6 +30,8 @@
+ #include "base/string_util.h"
+ #include "base/time.h"
+ 
++#define stat64 stat
++
+ namespace file_util {
+ 
+ #if defined(GOOGLE_CHROME_BUILD)
Index: www/firefox/files/patch-ipc-chromium-src-base-platform_file_posix.cc
===================================================================
RCS file: www/firefox/files/patch-ipc-chromium-src-base-platform_file_posix.cc
diff -N www/firefox/files/patch-ipc-chromium-src-base-platform_file_posix.cc
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ www/firefox/files/patch-ipc-chromium-src-base-platform_file_posix.cc        
7 Apr 2011 15:10:16 -0000
@@ -0,0 +1,10 @@
+--- ipc/chromium/src/base/platform_file_posix.cc~
++++ ipc/chromium/src/base/platform_file_posix.cc
+@@ -9,6 +9,7 @@
+ #ifdef ANDROID
+ #include <linux/stat.h>
+ #endif
++#include <sys/stat.h>
+ 
+ #include "base/logging.h"
+ #include "base/string_util.h"
Index: www/firefox/files/patch-ipc-chromium-src-base-platform_thread_posix.cc
===================================================================
RCS file: www/firefox/files/patch-ipc-chromium-src-base-platform_thread_posix.cc
diff -N www/firefox/files/patch-ipc-chromium-src-base-platform_thread_posix.cc
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ www/firefox/files/patch-ipc-chromium-src-base-platform_thread_posix.cc      
7 Apr 2011 19:56:07 -0000
@@ -0,0 +1,21 @@
+--- ipc/chromium/src/base/platform_thread_posix.cc~
++++ ipc/chromium/src/base/platform_thread_posix.cc
+@@ -10,8 +10,7 @@
+ #if defined(OS_MACOSX)
+ #include <mach/mach.h>
+ #elif defined(OS_LINUX)
+-#include <sys/syscall.h>
+-#include <unistd.h>
++#include <pthread_np.h>
+ #endif
+ 
+ #if defined(OS_MACOSX)
+@@ -34,7 +33,7 @@ PlatformThreadId PlatformThread::Current
+ #if defined(OS_MACOSX)
+   return mach_thread_self();
+ #elif defined(OS_LINUX)
+-  return syscall(__NR_gettid);
++  return pthread_getthreadid_np(); // thr_self(2) ?
+ #endif
+ }
+ 
Index: www/firefox/files/patch-ipc-chromium-src-base-third_party-nspr-prcpucfg.h
===================================================================
RCS file: 
www/firefox/files/patch-ipc-chromium-src-base-third_party-nspr-prcpucfg.h
diff -N 
www/firefox/files/patch-ipc-chromium-src-base-third_party-nspr-prcpucfg.h
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ www/firefox/files/patch-ipc-chromium-src-base-third_party-nspr-prcpucfg.h   
7 Apr 2011 15:10:16 -0000
@@ -0,0 +1,11 @@
+--- ipc/chromium/src/base/third_party/nspr/prcpucfg.h~
++++ ipc/chromium/src/base/third_party/nspr/prcpucfg.h
+@@ -34,7 +34,7 @@
+ #include "base/third_party/nspr/prcpucfg_win.h"
+ #elif defined(__APPLE__)
+ #include "base/third_party/nspr/prcpucfg_mac.h"
+-#elif defined(__linux__) || defined(ANDROID)
++#elif defined(__FreeBSD__) || defined(ANDROID)
+ #include "base/third_party/nspr/prcpucfg_linux.h"
+ #else
+ #error Provide a prcpucfg.h appropriate for your platform
Index: www/firefox/files/patch-ipc-chromium-src-build-build_config.h
===================================================================
RCS file: www/firefox/files/patch-ipc-chromium-src-build-build_config.h
diff -N www/firefox/files/patch-ipc-chromium-src-build-build_config.h
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ www/firefox/files/patch-ipc-chromium-src-build-build_config.h       7 Apr 
2011 15:10:16 -0000
@@ -0,0 +1,11 @@
+--- ipc/chromium/src/build/build_config.h~
++++ ipc/chromium/src/build/build_config.h
+@@ -17,7 +17,7 @@
+ // A set of macros to use for platform detection.
+ #if defined(__APPLE__)
+ #define OS_MACOSX 1
+-#elif defined(__linux__) || defined(ANDROID)
++#elif defined(__FreeBSD__) || defined(ANDROID)
+ #define OS_LINUX 1
+ #elif defined(_WIN32)
+ #define OS_WIN 1
Index: www/firefox/files/patch-toolkit_library_Makefile.in
===================================================================
RCS file: /a/.cvsup/ports/www/firefox/files/patch-toolkit_library_Makefile.in,v
retrieving revision 1.2
diff -u -p -r1.2 patch-toolkit_library_Makefile.in
--- www/firefox/files/patch-toolkit_library_Makefile.in 22 Mar 2011 15:24:49 
-0000      1.2
+++ www/firefox/files/patch-toolkit_library_Makefile.in 7 Apr 2011 15:05:47 
-0000
@@ -5,7 +5,7 @@
        $(INSTALL) $^ .
  
 -EXTRA_DSO_LDOPTS += $(LIBS_DIR) $(EXTRA_DSO_LIBS)
-+EXTRA_DSO_LDOPTS += $(LIBS_DIR) $(EXTRA_DSO_LIBS) %%PTHREAD_LIBS%%
++EXTRA_DSO_LDOPTS += $(LIBS_DIR) $(EXTRA_DSO_LIBS) -lexecinfo %%PTHREAD_LIBS%%
  
  ifdef MOZ_ENABLE_LIBXUL
  include $(srcdir)/libxul-rules.mk
Index: www/firefox/files/patch-xpcom_reflect_xptcall_src_md_unix_Makefile.in
===================================================================
RCS file: 
/a/.cvsup/ports/www/firefox/files/patch-xpcom_reflect_xptcall_src_md_unix_Makefile.in,v
retrieving revision 1.3
diff -u -p -r1.3 patch-xpcom_reflect_xptcall_src_md_unix_Makefile.in
--- www/firefox/files/patch-xpcom_reflect_xptcall_src_md_unix_Makefile.in       
22 Mar 2011 15:24:49 -0000      1.3
+++ www/firefox/files/patch-xpcom_reflect_xptcall_src_md_unix_Makefile.in       
28 Mar 2011 07:48:47 -0000
@@ -29,9 +29,9 @@
 +CPPSRCS               := xptcinvoke_amd64_openbsd.cpp 
xptcstubs_amd64_openbsd.cpp
 +endif
 +#
- # BeOS/Intel (uses the same unixish_x86 code)
+ # Neutrino/Intel (uses the same unixish_x86 code)
  #
- ifeq ($(OS_ARCH)$(OS_TEST),BeOSBePC)
+ ifeq ($(OS_TARGET),NTO)
 @@ -158,9 +167,15 @@
  ASFILES               := xptcinvoke_asm_osf1_alpha.s 
xptcstubs_asm_osf1_alpha.s
  endif
%%
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-gecko
To unsubscribe, send any mail to "[email protected]"

Reply via email to