CWS-TOOLING: integrate CWS os146
[LibreOffice.git] / canvas / source / directx / makefile.mk
blob9547fef40cc73b61c9e73be2e36505f030ac0c97
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=canvas
31 TARGET=directx9canvas
32 TARGET2=directx5canvas
33 TARGET3=gdipluscanvas
34 ENABLE_EXCEPTIONS=TRUE
37 # --- Settings -----------------------------------------------------------
39 .INCLUDE : settings.mk
40 DLLPRE =
42 # --- Nothing to do if we're compiling with --disable-directx -----------
43 .IF "$(ENABLE_DIRECTX)" == ""
44 @all:
45 @echo "Building without DirectX support..."
46 .ENDIF
49 # --- Common ----------------------------------------------------------
51 .IF "$(verbose)"!="" || "$(VERBOSE)"!=""
52 CDEFS+= -DVERBOSE
53 .ENDIF
55 .IF "$(dx_debug_images)"!="" || "$(DX_DEBUG_IMAGES)"!=""
56 CDEFS+= -DDX_DEBUG_IMAGES
57 .ENDIF
59 # --- This is Windows only! { ----------------------------------------------------------------
61 .IF "$(GUI)" == "WNT"
63 SHARED_SLOFILES = \
64 $(SLO)$/dx_bitmap.obj \
65 $(SLO)$/dx_bitmapcanvashelper.obj \
66 $(SLO)$/dx_canvasbitmap.obj \
67 $(SLO)$/dx_canvasfont.obj \
68 $(SLO)$/dx_canvashelper.obj \
69 $(SLO)$/dx_canvashelper_texturefill.obj \
70 $(SLO)$/dx_devicehelper.obj \
71 $(SLO)$/dx_gdiplususer.obj \
72 $(SLO)$/dx_impltools.obj \
73 $(SLO)$/dx_linepolypolygon.obj \
74 $(SLO)$/dx_textlayout.obj \
75 $(SLO)$/dx_textlayout_drawhelper.obj \
76 $(SLO)$/dx_vcltools.obj
78 DX_SLOFILES = \
79 $(SLO)$/dx_5rm.obj \
80 $(SLO)$/dx_9rm.obj \
81 $(SLO)$/dx_canvascustomsprite.obj \
82 $(SLO)$/dx_config.obj \
83 $(SLO)$/dx_spritecanvas.obj \
84 $(SLO)$/dx_spritecanvashelper.obj \
85 $(SLO)$/dx_spritedevicehelper.obj \
86 $(SLO)$/dx_spritehelper.obj \
87 $(SLO)$/dx_surfacebitmap.obj \
88 $(SLO)$/dx_surfacegraphics.obj
89 DX_SLOFILES += $(SHARED_SLOFILES)
91 GDIPLUS_SLOFILES = \
92 $(SLO)$/dx_canvas.obj
93 GDIPLUS_SLOFILES += $(SHARED_SLOFILES)
95 STDLIBS= $(CPPULIB) $(TKLIB) $(SALLIB) $(COMPHELPERLIB) $(CPPUHELPERLIB) $(BASEGFXLIB) $(CANVASTOOLSLIB) $(VCLLIB) $(TOOLSLIB) $(UNOTOOLSLIB) $(I18NISOLANGLIB)
98 ########################################################
99 # DX9
100 ########################################################
102 # Indicates the source obj files for the dx5 lib
103 LIB1TARGET= $(SLB)$/$(TARGET).lib
104 LIB1OBJFILES = $(DX_SLOFILES)
106 # Indicates the filename of the shared library.
107 SHL1TARGET=$(TARGET).uno
109 # Links import libraries.
110 SHL1STDLIBS= $(STDLIBS)
112 # Specifies an import library to create. For Win32 only.
113 SHL1IMPLIB=i$(TARGET)
115 # Specifies libraries from the same module to put into the shared library.
116 SHL1LIBS=$(SLB)$/$(TARGET).lib
118 SHL1DEF=$(MISC)$/$(SHL1TARGET).def
120 DEF1NAME=$(SHL1TARGET)
121 DEF1EXPORTFILE=exports.dxp
123 CDEFS+=-DDIRECTX_VERSION=0x0900
125 SHL1STDLIBS += $(GDI32LIB)
126 .IF "$(COM)" == "GCC"
127 SHL1STDLIBS += $(DIRECTXSDK_LIB)/d3d9.lib
128 .ELSE
129 SHL1STDLIBS += d3d9.lib
130 .ENDIF
131 SHL1STDLIBS += $(GDIPLUSLIB)
133 .IF "$(dx_debug_images)"!="" || "$(DX_DEBUG_IMAGES)"!=""
134 SHL1STDLIBS += imdebug.lib
135 .ENDIF
138 ########################################################
139 # DX5
140 ########################################################
142 .IF "$(USE_DIRECTX5)" != ""
143 SECOND_BUILD=DX5
144 DX5_SLOFILES=$(DX_SLOFILES)
145 DX5CDEFS += -DDIRECTX_VERSION=0x0500
147 LIB2TARGET= $(SLB)$/$(TARGET2).lib
148 LIB2OBJFILES = $(REAL_DX5_SLOFILES)
150 # Indicates the filename of the shared library.
151 SHL2TARGET=$(TARGET2).uno
153 # Links import libraries.
154 SHL2STDLIBS= $(STDLIBS)
156 # Specifies an import library to create. For Win32 only.
157 SHL2IMPLIB=i$(TARGET2).lib
159 # Specifies libraries from the same module to put into the shared library.
160 SHL2LIBS=$(SLB)$/$(TARGET2).lib
161 SHL2DEF=$(MISC)$/$(SHL2TARGET).def
163 DEF2NAME=$(SHL2TARGET)
164 DEF2EXPORTFILE=exports.dxp
166 SHL2STDLIBS += $(GDI32LIB)
167 SHL2STDLIBS += $(DDRAWLIB)
168 SHL2STDLIBS += $(GDIPLUSLIB)
170 .IF "$(COM)" == "GCC"
171 SHL2STDLIBS += $(DIRECTXSDK_LIB)/d3dx.lib
172 .ELSE
173 SHL2STDLIBS += d3dx.lib
174 .ENDIF
176 .IF "$(dx_debug_images)"!="" || "$(DX_DEBUG_IMAGES)"!=""
177 SHL2STDLIBS += imdebug.lib
178 .ENDIF
179 .ENDIF # IF "$(USE_DIRECTX5)" != ""
182 ########################################################
183 # GDI+
184 ########################################################
186 LIB3TARGET= $(SLB)$/$(TARGET3).lib
187 LIB3OBJFILES = $(GDIPLUS_SLOFILES)
189 # Indicates the filename of the shared library.
190 SHL3TARGET=$(TARGET3).uno
192 # Links import libraries.
193 SHL3STDLIBS= $(CPPULIB) $(TKLIB) $(SALLIB) $(COMPHELPERLIB) $(CPPUHELPERLIB) $(BASEGFXLIB) $(CANVASTOOLSLIB) $(VCLLIB) $(TOOLSLIB) $(UNOTOOLSLIB) $(I18NISOLANGLIB)
195 # Specifies an import library to create. For Win32 only.
196 SHL3IMPLIB=i$(TARGET3).lib
198 # Specifies libraries from the same module to put into the shared library.
199 SHL3LIBS=$(SLB)$/$(TARGET3).lib
200 SHL3DEF=$(MISC)$/$(SHL3TARGET).def
202 DEF3NAME=$(SHL3TARGET)
203 DEF3EXPORTFILE=exports.dxp
205 SHL3STDLIBS += $(GDI32LIB)
206 SHL3STDLIBS += $(GDIPLUSLIB)
208 .IF "$(dx_debug_images)"!="" || "$(DX_DEBUG_IMAGES)"!=""
209 SHL3STDLIBS += imdebug.lib
210 .ENDIF
212 .ENDIF # IF "$(GUI)" == "WNT"
214 # --- This is Windows only! } ----------------------------------------------------------------
216 # ==========================================================================
218 .INCLUDE : target.mk
220 ALLTAR : \
221 $(MISC)/directx5canvas.component \
222 $(MISC)/directx9canvas.component \
223 $(MISC)/gdipluscanvas.component
225 $(MISC)/directx5canvas.component .ERRREMOVE : \
226 $(SOLARENV)/bin/createcomponent.xslt directx5canvas.component
227 $(XSLTPROC) --nonet --stringparam uri \
228 '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL2TARGETN:f)' -o $@ \
229 $(SOLARENV)/bin/createcomponent.xslt directx5canvas.component
231 $(MISC)/directx9canvas.component .ERRREMOVE : \
232 $(SOLARENV)/bin/createcomponent.xslt directx9canvas.component
233 $(XSLTPROC) --nonet --stringparam uri \
234 '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
235 $(SOLARENV)/bin/createcomponent.xslt directx9canvas.component
237 $(MISC)/gdipluscanvas.component .ERRREMOVE : \
238 $(SOLARENV)/bin/createcomponent.xslt gdipluscanvas.component
239 $(XSLTPROC) --nonet --stringparam uri \
240 '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL3TARGETN:f)' -o $@ \
241 $(SOLARENV)/bin/createcomponent.xslt gdipluscanvas.component