1 #*************************************************************************
3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
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 #*************************************************************************
33 # --- Settings -----------------------------------------------------
35 .INCLUDE
: settings.mk
37 # --- Files --------------------------------------------------------
39 .IF
"$(PREBUILD_MOZAB)" == "" ||
"$(SYSTEM_MOZILLA)" == "YES" ||
"$(WITH_MOZILLA)" == "NO"
42 @echo
"No need to unpack the prebuilt mozab packages"
44 .ELSE
# unpack mozab zips
47 .IF
"$(BUILD_MOZAB)"=="TRUE"
49 @echo
"Does not need build mozab zipped!"
52 $(MISC
)$/unpacked_
$(TARGET
)_inc \
53 $(MISC
)$/unpacked_
$(TARGET
)_lib \
54 $(BIN
)$/mozruntime.zip \
55 $(MISC
)$/replace_old_nss_libs
59 $(MISC
)$/unpacked_
%_lib
: $(OS
)$(COM
)$(CPU
)lib.zip
'$(OS)$(COM)$(CPU)runtime.zip'
60 unzip
-o
-d
$(LB
) $(OS
)$(COM
)$(CPU
)lib.zip
&& unzip
-o
-d
$(LB
) $(OS
)$(COM
)$(CPU
)runtime.zip
&& $(TOUCH
) $@
63 $(MISC
)$/unpacked_
%_inc
: $(OS
)$(COM
)$(CPU
)inc.zip
64 unzip
-o
-d
$(INCCOM
) $(OS
)$(COM
)$(CPU
)inc.zip
&& $(TOUCH
) $@
65 chmod
-R
775 $(INCCOM
)
69 $(MISC
)$/unpacked_
$(TARGET
)_lib
: $(OS
)$(COM
)$(CPU
)lib.zip
70 unzip
-o
-d
$(LB
) $(OS
)$(COM
)$(CPU
)lib.zip
&& \
73 $(MISC
)$/unpacked_
$(TARGET
)_inc
: $(OS
)$(COM
)$(CPU
)inc.zip
74 unzip
-o
-d
$(INCCOM
) $(OS
)$(COM
)$(CPU
)inc.zip
&& $(TOUCH
) $@
78 $(BIN
)$/mozruntime
%zip
: $(OS
)$(COM
)$(CPU
)runtime.zip
79 $(COPY
) $(OS
)$(COM
)$(CPU
)runtime.zip
$(BIN
)$/mozruntime.zip
81 # add alternative rules for universal binary moz-zips
82 .IF
"$(GUIBASE)" == "aqua"
83 $(MISC
)$/unpacked_
%_lib
: $(OS
)$(COM
)UBlib.zip
'$(OS)$(COM)UBruntime.zip'
84 unzip
-o
-d
$(LB
) $(OS
)$(COM
)UBlib.zip
&& unzip
-o
-d
$(LB
) $(OS
)$(COM
)UBruntime.zip
&& $(TOUCH
) $@
87 $(MISC
)$/unpacked_
%_inc
: $(OS
)$(COM
)UBinc.zip
88 unzip
-o
-d
$(INCCOM
) $(OS
)$(COM
)UBinc.zip
&& $(TOUCH
) $@
89 chmod
-R
775 $(INCCOM
)
91 $(BIN
)$/mozruntime
%zip
: $(OS
)$(COM
)UBruntime.zip
92 $(COPY
) $(OS
)$(COM
)UBruntime.zip
$(BIN
)$/mozruntime.zip
94 .ENDIF
# "$(GUIBASE)"=="aqua"
99 NSS_MODULE_RUNTIME_LIST
=
101 # The prebuilt moz files include all the old NSS stuff from moz and not the new
102 # NSS libs, headers, etc, from the separate nss module. If we use the nss module
103 # then we must take care not to deliver the old NSS stuff from the "prebuilts"
104 .IF
"$(GUI)" == "WNT"
105 FREEBL_LIB_OLD
=freebl3
106 .ELSE
# "$(GUI)" == "WNT"
107 .IF
"$(OS)$(CPUNAME)" == "SOLARISSPARC"
108 FREEBL_LIB_OLD
=freebl_32fpu_3
109 .ELSE
# "$(OS)$(CPUNAME)" == "SOLARISSPARC"
110 FREEBL_LIB_OLD
=freebl3
111 .ENDIF
# "$(OS)$(CPUNAME)" == "SOLARISSPARC"
112 .ENDIF
# "$(GUI)" == "WNT"
143 .ELSE
#"$(GUI)"=="WNT"
145 lib
$(FREEBL_LIB_OLD
)$(DLLPOST
) \
147 libsoftokn3
$(DLLPOST
) \
154 .ENDIF
# .IF "$(GUI)"=="WNT"
160 .IF
"$(OS)" == "SOLARIS"
161 .IF
"$(CPU)" == "S" #32bit
162 FREEBL
=freebl_32fpu_3 freebl_32int64_3 freebl_32int_3
163 .ELIF
"$(CPU)" == "U" #64bit unxsolu4
164 FREEBL
=freebl_64int_3 freebl_64fpu_3
167 .ENDIF
#"$(CPU)" == "S"
169 .ELSE
# "$(OS)" == "SOLARIS"
171 .ENDIF
# "$(OS)" == "SOLARIS"
174 #On Linux/Unix sqlite is delivered to $(SOLARLIBDIR)/sqlite/libsqlite3.so
175 #See readme.txt in module nss
176 NSS_MODULE_RUNTIME_LIST
:= \
190 # Remove the nss libs build in moz and those build in the nss module
191 $(MISC
)$/replace_old_nss_libs
: $(MISC
)$/unpacked_
$(TARGET
)_lib \
192 $(MISC
)$/unpacked_
$(TARGET
)_inc
$(BIN
)$/mozruntime.zip
193 +$(foreach,dir,$(NSS_INCLUDE_LIST
) $(RENAME
:s
/+//) $(INCCOM
)$/$(dir) \
194 $(INCCOM
)$/$(dir)_remove_me
&&) echo
>& $(NULLDEV
)
195 $(foreach,dir,$(NSS_INCLUDE_LIST
) rm -r
-f
$(INCCOM
)$/$(dir)_remove_me
&&) \
197 $(foreach,lib
,$(LIBLIST
) rm -f
$(LB
)$/$(lib
) &&) \
199 $(foreach,lib
,$(BIN_RUNTIMELIST
) zip
-d
$(BIN
)$/mozruntime.zip
$(DLLPRE
)$(lib
:f
)$(DLLPOST
) &&) \
202 +$(foreach,lib
,$(NSS_MODULE_RUNTIME_LIST
) zip
-g
-j
$(BIN
)$/mozruntime.zip
$(SOLARBINDIR
)$/$(DLLPRE
)$(lib
:f
)$(DLLPOST
) &&) \
205 +$(foreach,lib
,$(NSS_MODULE_RUNTIME_LIST
) zip
-g
-j
$(BIN
)$/mozruntime.zip
$(SOLARLIBDIR
)$/$(lib
:d
)$(DLLPRE
)$(lib
:f
)$(DLLPOST
) &&) \
210 .ENDIF
# unpack mozab zips