Impress Remote 1.0.5, tag sdremote-1.0.5
[LibreOffice.git] / moz / makefile.mk
blobe7c8528d65168ce795e9a2e72478b9a918ed22b9
1 #*************************************************************************
3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 #
5 # Copyright 2000, 2010 Oracle and/or its affiliates.
7 # OpenOffice.org - a multi-platform office productivity suite
9 # This file is part of OpenOffice.org.
11 # OpenOffice.org is free software: you can redistribute it and/or modify
12 # it under the terms of the GNU Lesser General Public License version 3
13 # only, as published by the Free Software Foundation.
15 # OpenOffice.org is distributed in the hope that it will be useful,
16 # but WITHOUT ANY WARRANTY; without even the implied warranty of
17 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 # GNU Lesser General Public License version 3 for more details
19 # (a copy is included in the LICENSE file that accompanied this code).
21 # You should have received a copy of the GNU Lesser General Public License
22 # version 3 along with OpenOffice.org. If not, see
23 # <http://www.openoffice.org/license.html>
24 # for a copy of the LGPLv3 License.
26 #*************************************************************************
28 PRJ=.
30 PRJNAME=ooo_mozab
31 TARGET=ooo_mozab
33 # --- Settings -----------------------------------------------------
35 .INCLUDE : settings.mk
37 # --- Files --------------------------------------------------------
39 # ----- pkg-config start -------
40 .INCLUDE .IGNORE : pkgroot.mk
41 .IF "$(PKGCONFIG_ROOT)"!=""
42 PKG_CONFIG:=$(PKGCONFIG_ROOT)$/bin$/pkg-config
43 PKG_CONFIG_PATH:=$(PKGCONFIG_ROOT)$/lib$/pkgconfig
44 .IF "$(LD_LIBRARY_PATH)"=="" # assume empty implies unset
45 LD_LIBRARY_PATH!:=$(PKGCONFIG_ROOT)$/lib
46 .ELSE
47 LD_LIBRARY_PATH!:=$(LD_LIBRARY_PATH)$(PATH_SEPERATOR)$(PKGCONFIG_ROOT)$/lib
48 .ENDIF
49 .EXPORT : PKG_CONFIG_PATH PKG_CONFIG LD_LIBRARY_PATH
50 .ENDIF # "$(PKGCONFIG_ROOT)"!=""
52 # reduce prerequisites by disabling mozilla binary
53 DISABLE_MOZ_EXECUTABLE=TRUE
54 .EXPORT : DISABLE_MOZ_EXECUTABLE
57 # ----- pkg-config end -------
59 MOZILLA_VERSION=1.1.14
60 TARFILE_NAME=seamonkey-$(MOZILLA_VERSION).source
61 TARFILE_MD5=a169ab152209200a7bad29a275cb0333
63 TARFILE_ROOTDIR=mozilla
64 PATCH_FILES = \
65 seamonkey-source-$(MOZILLA_VERSION).patch \
66 patches/dtoa.patch \
67 patches/respect_disable_pango.patch \
68 patches/link_fontconfig.patch \
69 patches/brokenmakefile.patch \
70 patches/libpr0n_build_fix.patch \
71 patches/clang_add_nsCaseInsensitiveStringComparator_default_constructor.patch \
72 patches/clang_missing_this_pointers.patch \
73 patches/seamonkey-1.1.14.source-macosx10.6and7.patch \
75 # This file is needed for the W32 build when BUILD_MOZAB is set
76 # (currently only vc8/vs2005 is supported when BUILD_MOZAB is set)
77 MOZTOOLS_ZIPFILE_NAME*=vc8-moztools.zip
79 ADDITIONAL_FILES=mailnews$/addrbook$/src$/nsAbMD5sum.cpp
81 CONFIGURE_DIR=
83 MOZILLA_CONFIGURE_FLAGS += --disable-tests \
84 --enable-application=suite \
85 --enable-ldap \
86 --enable-crypto \
87 --enable-optimize \
88 --enable-strip \
89 --disable-profilelocking \
90 --disable-activex \
91 --disable-activex-scripting \
92 --disable-gnomevfs \
93 --disable-debug \
94 --disable-xprint \
95 --disable-postscript \
96 --without-system-zlib \
97 --with-system-nss \
98 --with-system-nspr \
99 --disable-installer \
100 --disable-accessibility \
101 --disable-xpfe-components \
102 --disable-mathml \
103 --disable-oji \
104 --disable-profilesharing \
105 --disable-boehm \
106 --disable-jsloader \
107 --disable-canvas \
108 --disable-freetype2 \
109 --disable-gnomeui \
110 --disable-image-encoders \
111 --disable-plugins \
112 --disable-printing \
113 --disable-pango \
114 --enable-extensions="pref"
116 .IF "$(SYSTEM_NSS)"=="NO"
118 MOZILLA_CONFIGURE_FLAGS += \
119 --with-nss-prefix=$(OUTDIR) \
120 --with-nspr-prefix=$(OUTDIR)
121 .ENDIF
123 #disable profilelocking to share profile with mozilla
124 #disable activex and activex-scripting to remove the dependence of Microsoft_SDK\src\mfc\atlbase.h
125 #disable gnomevfs to remove the needed of gnome develop files
126 #disable others to save build times
128 # create a objdir build = build files in a seperate directory, not in the sourcetree directly
129 CONFIGURE_DIR=$(CPU)_objdir
130 BUILD_DIR=$(CONFIGURE_DIR)
131 MOZ_CROSSCOMPILE=CROSS_COMPILE=1 CC="$(CC) -arch $(MOZ_ARCH)" CXX="$(CXX) -arch $(MOZ_ARCH)" AR=ar
133 CONFIGURE_ACTION=$(null,$(MOZ_ARCH) $(NULL) $(MOZ_CROSSCOMPILE)) ../configure $(MOZILLA_CONFIGURE_FLAGS)
135 BUILD_ACTION:=$(GNUMAKE) -j$(EXTMAXPROCESS)
137 MOZDIR=$(MISC)$/build$/seamonkey
138 MOZTARGET=$(OS)$(COM)$(CPU)
140 # "Our" build environment uses "NO" for the environment variable that
141 # indicate if system libraries should be used, the mozilla build uses
142 # "" in this case. This conflicts (at least for W32) with mozilla (1.7b)
143 # because it disables the library checks for msvc so that
144 # --without-system-* is not evaluated. To build the included libraries
145 # the affected variables have to be empty and not NO.
146 .IF "$(SYSTEM_ZLIB)"=="NO"
147 SYSTEM_ZLIB:=
148 .EXPORT : SYSTEM_ZLIB
149 .ENDIF
150 .IF "$(SYSTEM_JPEG)"=="NO"
151 SYSTEM_JPEG:=
152 .EXPORT : SYSTEM_JPEG
153 .ENDIF
155 CC:=cl.exe
156 CXX:=cl.exe
158 # Variables to install/use our own wintools
159 MOZTOOLS_EXTRACT:=$(MISC)$/build$/moztools
160 MOZ_TOOLS_DOS:=$(shell @cygpath -ad "$(MISC)")\build\moztools\vc8-moztools
161 PATH!:=$(shell @cygpath $(MOZ_TOOLS_DOS))/bin:$(PATH)
163 MOZ_TOOLS:=$(subst,\,/ $(MOZ_TOOLS_DOS))
165 .EXPORT : PATH MOZ_TOOLS
167 # --- Targets ------------------------------------------------------
169 .IF "$(BUILD_MOZAB)"==""
170 all:
171 @echo "Never Build Mozilla but copy runtime files $(MSVC80_DLL_DIR) ."
172 @echo "Never Build Mozilla but copy runtime files."
173 @@-$(MKDIR) $(OUT)$/zipped
174 $(COPY) $(TARFILE_LOCATION)$/$(MOZ_ZIP_INC) $(PRJ)$/zipped$/
175 $(COPY) $(TARFILE_LOCATION)$/$(MOZ_ZIP_LIB) $(PRJ)$/zipped$/
176 $(COPY) $(TARFILE_LOCATION)$/$(MOZ_ZIP_RUNTIME) $(PRJ)$/zipped$/
177 .IF "$(EXTMSV80)"!=""
178 $(COPY) $(MSVC80_MNFST) $(EXTMSV80)$/Microsoft.VC80.CRT.manifest
179 $(COPY) $(MSVC80_DLL_DIR)$/msvcp80.dll $(EXTMSV80)$/
180 $(COPY) $(MSVC80_DLL_DIR)$/msvcr80.dll $(EXTMSV80)$/
181 .ENDIF
182 .ENDIF
184 .INCLUDE : set_ext.mk
185 .INCLUDE : target.mk
186 .INCLUDE : tg_ext.mk
188 NEEDWINTOOLSFLAGFILE:=$(MISC)$/build$/moztools.complete
190 ALLTAR: $(NEEDWINTOOLSFLAGFILE) \
191 $(MISC)$/remove_build.flag \
192 extract_mozab_files
194 $(PACKAGE_DIR)$/$(UNTAR_FLAG_FILE) : $(MISC)$/remove_build.flag
196 # Since you never know what will be in a patch (for example, it may already
197 # patch at configure level), we remove the entire package directory if a patch
198 # is newer.
199 $(MISC)$/remove_build.flag : $(PATCH_FILES)
200 $(REMOVE_PACKAGE_COMMAND)
201 $(TOUCH) $(MISC)$/remove_build.flag
203 # Unpack/setup Windows build tools
204 $(PACKAGE_DIR)$/$(UNTAR_FLAG_FILE) : $(MISC)$/build$/moztools.complete
206 $(MISC)$/build$/moztools.unpack : $(PRJ)$/download$/$(MOZTOOLS_ZIPFILE_NAME)
207 -$(RENAME) $(MOZTOOLS_EXTRACT) $(MOZTOOLS_EXTRACT)_removeme
208 -rm -rf $(MOZTOOLS_EXTRACT)_removeme
209 @-$(MKDIRHIER) $(MOZTOOLS_EXTRACT)
210 unzip $(PRJ)$/download$/$(MOZTOOLS_ZIPFILE_NAME) -d $(MOZTOOLS_EXTRACT)
211 # chmod is also needed for W32-4nt build (when cygwin unzip is used)
212 -chmod -R +x $(MOZTOOLS_EXTRACT)$/vc8-moztools$/bin
213 $(TOUCH) $(MISC)$/build$/moztools.unpack
215 $(MISC)$/build$/moztools.complete : $(MISC)$/build$/moztools.unpack
216 $(TOUCH) $(MISC)$/build$/moztools.complete
218 zip: \
219 $(MISC)$/CREATETARBALL
221 .INCLUDE : extractfiles.mk