#iZ 28398
#iZ 11424

http://qa.openoffice.org/issues/show_bug.cgi?id=28398
http://qa.openoffice.org/issues/show_bug.cgi?id=11424

disable freetype2 support since build broken and
this functionality is not used at all.

fix build after /usr/bin/objformat removal

--- moz/extractfiles.mk.org	Sat Oct 30 22:01:49 2004
+++ moz/extractfiles.mk	Sat Oct 30 22:00:21 2004
@@ -269,8 +269,8 @@
 	+$(COPY) /QSZ $(INCLUDE_PATH)* $(INCLUDE_DIR)
 	+$(COPY) /QSZ $(PUBLIC_PATH)* $(INCLUDE_DIR)
 .ELSE
-	+$(GNUCOPY) -pr $(INCLUDE_PATH)* $(INCLUDE_DIR)
-	+$(GNUCOPY) -pr $(PUBLIC_PATH)* $(INCLUDE_DIR)
+	+$(GNUCOPY) -Lr $(INCLUDE_PATH)* $(INCLUDE_DIR)
+	+$(GNUCOPY) -Lr $(PUBLIC_PATH)* $(INCLUDE_DIR)
 .ENDIF
 
 .IF "$(GUI)"=="UNX"

--- moz/mozilla-source-1.0.patch	Thu May  3 09:11:47 2007
+++ moz/mozilla-source-1.0.patch	Thu May  3 09:10:12 2007
@@ -4473,12 +4473,15 @@
 
 --- misc/build/mozilla/.mozconfig	Tue Jul 22 21:52:27 2003
 +++ misc/build/mozilla/.mozconfig	Mon Jul 28 15:07:20 2003
-@@ -0,0 +1,8 @@
+@@ -0,0 +1,11 @@
 +ac_add_options --disable-tests
 +ac_add_options --disable-xprint
 +ac_add_options --without-system-zlib
 +ac_add_options --enable-ldap
 +ac_add_options --disable-debug
++ac_add_options --disable-freetype2
++ac_add_options --enable-default-toolkit=xlib
++ac_add_options --disable-pedantic
 +ac_add_options --enable-optimize
 +ac_add_options --enable-crypto
 +ac_add_options --enable-strip
@@ -4497,3 +4500,233 @@
  endif
  
  # Windows equivalents
+
+--- misc/build/mozilla/xpcom/typelib/xpidl/xpidl.h	Wed Apr 10 12:38:31 2002
++++ misc/build/mozilla/xpcom/typelib/xpidl/xpidl.h	Sat Oct 29 12:34:19 2005
+@@ -71,10 +71,10 @@
+  * parens, e.g. XPIDL_WARNING((foo, bar, "sil"))
+  *
+  * Probably best removed when we leave 6.5.  */
+-#define XPIDL_WARNING(x) IDL_tree_warning##x
++#define XPIDL_WARNING(x) IDL_tree_warning x
+ #else
+ extern void xpidl_tree_warning(IDL_tree p, int level, const char *fmt, ...);
+-#define XPIDL_WARNING(x) xpidl_tree_warning##x
++#define XPIDL_WARNING(x) xpidl_tree_warning x
+ #endif
+ 
+ /*
+*** misc/mozilla/configure	Tue May 28 04:29:00 2002
+--- misc/build/mozilla/configure	Sun Sep 10 11:56:33 2006
+***************
+*** 4565,4571 ****
+      ;;
+  
+  *-freebsd*)
+!     if test `test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` != "elf"; then
+  	DLL_SUFFIX=".so.1.0"
+  	DSO_LDOPTS="-shared"
+      fi
+--- 4565,4571 ----
+      ;;
+  
+  *-freebsd*)
+!     if test `test -x /usr/bin/objformat && /usr/bin/objformat || echo elf` != "elf"; then
+  	DLL_SUFFIX=".so.1.0"
+  	DSO_LDOPTS="-shared"
+      fi
+***************
+*** 6589,6594 ****
+--- 6589,6596 ----
+  case $target in
+  *-hpux11.*)
+  	;;
++ *-freebsd*)
++ 	;;
+  *)
+  	echo $ac_n "checking for gethostbyname_r in -lc_r""... $ac_c" 1>&6
+  echo "configure:6595: checking for gethostbyname_r in -lc_r" >&5
+*** misc/mozilla/configure.in	Tue May 28 04:29:12 2002
+--- misc/build/mozilla/configure.in	Sun Sep 10 11:56:18 2006
+***************
+*** 787,793 ****
+      ;;
+  
+  *-freebsd*)
+!     if test `test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` != "elf"; then
+  	DLL_SUFFIX=".so.1.0"
+  	DSO_LDOPTS="-shared"
+      fi
+--- 787,793 ----
+      ;;
+  
+  *-freebsd*)
+!     if test `test -x /usr/bin/objformat && /usr/bin/objformat || echo elf` != "elf"; then
+  	DLL_SUFFIX=".so.1.0"
+  	DSO_LDOPTS="-shared"
+      fi
+***************
+*** 1606,1611 ****
+--- 1606,1613 ----
+  case $target in
+  *-hpux11.*)
+  	;;
++ *-freebsd*)
++ 	;;
+  *)
+  	AC_CHECK_LIB(c_r, gethostbyname_r)
+  	;;
+*** misc/mozilla/directory/c-sdk/config/FreeBSD.mk	Wed Apr 10 11:31:55 2002
+--- misc/build/mozilla/directory/c-sdk/config/FreeBSD.mk	Thu May  3 07:55:57 2007
+***************
+*** 66,72 ****
+  
+  ARCH			= freebsd
+  
+! MOZ_OBJFORMAT          := $(shell test -x /usr/bin/objformat && /usr/bin/objformat || echo aout)
+  
+  ifeq ($(MOZ_OBJFORMAT),elf)
+  DLL_SUFFIX		= so
+--- 66,72 ----
+  
+  ARCH			= freebsd
+  
+! MOZ_OBJFORMAT          := $(shell test -x /usr/bin/objformat && /usr/bin/objformat || echo elf)
+  
+  ifeq ($(MOZ_OBJFORMAT),elf)
+  DLL_SUFFIX		= so
+*** misc/mozilla/directory/c-sdk/configure	Wed Apr 10 11:31:53 2002
+--- misc/build/mozilla/directory/c-sdk/configure	Thu May  3 07:58:33 2007
+***************
+*** 3410,3416 ****
+  EOF
+  
+      CFLAGS="$CFLAGS $(DSO_CFLAGS) -ansi -Wall"
+!     MOZ_OBJFORMAT=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout`
+      if test "$MOZ_OBJFORMAT" = "elf"; then
+          DLL_SUFFIX=so
+      else
+--- 3410,3416 ----
+  EOF
+  
+      CFLAGS="$CFLAGS $(DSO_CFLAGS) -ansi -Wall"
+!     MOZ_OBJFORMAT=`test -x /usr/bin/objformat && /usr/bin/objformat || echo elf`
+      if test "$MOZ_OBJFORMAT" = "elf"; then
+          DLL_SUFFIX=so
+      else
+*** misc/mozilla/directory/c-sdk/configure.in	Wed Apr 10 11:31:54 2002
+--- misc/build/mozilla/directory/c-sdk/configure.in	Thu May  3 07:58:48 2007
+***************
+*** 900,906 ****
+      AC_DEFINE(FREEBSD)
+      AC_DEFINE(HAVE_BSD_FLOCK)
+      CFLAGS="$CFLAGS $(DSO_CFLAGS) -ansi -Wall"
+!     MOZ_OBJFORMAT=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout`
+      if test "$MOZ_OBJFORMAT" = "elf"; then
+          DLL_SUFFIX=so
+      else
+--- 900,906 ----
+      AC_DEFINE(FREEBSD)
+      AC_DEFINE(HAVE_BSD_FLOCK)
+      CFLAGS="$CFLAGS $(DSO_CFLAGS) -ansi -Wall"
+!     MOZ_OBJFORMAT=`test -x /usr/bin/objformat && /usr/bin/objformat || echo elf`
+      if test "$MOZ_OBJFORMAT" = "elf"; then
+          DLL_SUFFIX=so
+      else
+*** misc/mozilla/nsprpub/configure	Tue Sep 14 17:14:38 2004
+--- misc/build/mozilla/nsprpub/configure	Wed Apr  4 20:56:33 2007
+***************
+*** 3407,3413 ****
+  EOF
+  
+      CFLAGS="$CFLAGS $(DSO_CFLAGS) -ansi -Wall"
+!     MOZ_OBJFORMAT=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout`
+      if test "$MOZ_OBJFORMAT" = "elf"; then
+          DLL_SUFFIX=so
+      else
+--- 3407,3413 ----
+  EOF
+  
+      CFLAGS="$CFLAGS $(DSO_CFLAGS) -ansi -Wall"
+!     MOZ_OBJFORMAT=`test -x /usr/bin/objformat && /usr/bin/objformat || echo elf`
+      if test "$MOZ_OBJFORMAT" = "elf"; then
+          DLL_SUFFIX=so
+      else
+*** misc/mozilla/nsprpub/configure.in	Tue Sep 14 17:14:38 2004
+--- misc/build/mozilla/nsprpub/configure.in	Wed Apr  4 20:56:40 2007
+***************
+*** 922,928 ****
+      AC_DEFINE(HAVE_BSD_FLOCK)
+      AC_DEFINE(HAVE_SOCKLEN_T)
+      CFLAGS="$CFLAGS $(DSO_CFLAGS) -ansi -Wall"
+!     MOZ_OBJFORMAT=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout`
+      if test "$MOZ_OBJFORMAT" = "elf"; then
+          DLL_SUFFIX=so
+      else
+--- 922,928 ----
+      AC_DEFINE(HAVE_BSD_FLOCK)
+      AC_DEFINE(HAVE_SOCKLEN_T)
+      CFLAGS="$CFLAGS $(DSO_CFLAGS) -ansi -Wall"
+!     MOZ_OBJFORMAT=`test -x /usr/bin/objformat && /usr/bin/objformat || echo elf`
+      if test "$MOZ_OBJFORMAT" = "elf"; then
+          DLL_SUFFIX=so
+      else
+
+*** misc/mozilla/security/coreconf/FreeBSD.mk	Wed Mar 26 20:17:25 2003
+--- misc/build/mozilla/security/coreconf/FreeBSD.mk	Wed Apr  4 20:56:48 2007
+***************
+*** 63,69 ****
+  
+  ARCH			= freebsd
+  
+! MOZ_OBJFORMAT		:= $(shell test -x /usr/bin/objformat && /usr/bin/objformat || echo aout)
+  
+  ifeq ($(MOZ_OBJFORMAT),elf)
+  DLL_SUFFIX		= so
+--- 63,69 ----
+  
+  ARCH			= freebsd
+  
+! MOZ_OBJFORMAT		:= $(shell test -x /usr/bin/objformat && /usr/bin/objformat || echo elf)
+  
+  ifeq ($(MOZ_OBJFORMAT),elf)
+  DLL_SUFFIX		= so
+*** misc/mozilla/nsprpub/config/FreeBSD.mk	Wed Apr 10 12:16:03 2002
+--- misc/build/mozilla/nsprpub/config/FreeBSD.mk	Thu May  3 08:07:27 2007
+***************
+*** 66,72 ****
+  
+  ARCH			= freebsd
+  
+! MOZ_OBJFORMAT          := $(shell test -x /usr/bin/objformat && /usr/bin/objformat || echo aout)
+  
+  ifeq ($(MOZ_OBJFORMAT),elf)
+  DLL_SUFFIX		= so
+--- 66,72 ----
+  
+  ARCH			= freebsd
+  
+! MOZ_OBJFORMAT          := $(shell test -x /usr/bin/objformat && /usr/bin/objformat || echo elf)
+  
+  ifeq ($(MOZ_OBJFORMAT),elf)
+  DLL_SUFFIX		= so
+*** misc/mozilla/nsprpub/pr/src/misc/prnetdb.c	Wed Apr 10 12:17:35 2002
+--- misc/build/mozilla/nsprpub/pr/src/misc/prnetdb.c	Sun Sep 10 11:55:27 2006
+***************
+*** 105,111 ****
+  #define _PR_HAVE_GETPROTO_R_INT
+  #endif
+  
+! #if (defined(LINUX) && defined(__GLIBC__) && __GLIBC__ >= 2)
+  #define _PR_HAVE_GETPROTO_R
+  #define _PR_HAVE_5_ARG_GETPROTO_R
+  #endif
+--- 105,112 ----
+  #define _PR_HAVE_GETPROTO_R_INT
+  #endif
+  
+! #if (defined(LINUX) && defined(__GLIBC__) && __GLIBC__ >= 2) ||  \
+!     (defined(__FreeBSD__) && __FreeBSD_version > 601103)
+  #define _PR_HAVE_GETPROTO_R
+  #define _PR_HAVE_5_ARG_GETPROTO_R
+  #endif
