sync master with lastest vba changes
[ooovba.git] / cairo / pixman / makefile.mk
blob09d8ff4e2bb40fdf1beaf5cb44370057ae82a259
1 #*************************************************************************
3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 #
5 # Copyright 2008 by Sun Microsystems, Inc.
7 # OpenOffice.org - a multi-platform office productivity suite
9 # $RCSfile: makefile.mk,v $
11 # $Revision: 1.1.2.2 $
13 # This file is part of OpenOffice.org.
15 # OpenOffice.org is free software: you can redistribute it and/or modify
16 # it under the terms of the GNU Lesser General Public License version 3
17 # only, as published by the Free Software Foundation.
19 # OpenOffice.org is distributed in the hope that it will be useful,
20 # but WITHOUT ANY WARRANTY; without even the implied warranty of
21 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22 # GNU Lesser General Public License version 3 for more details
23 # (a copy is included in the LICENSE file that accompanied this code).
25 # You should have received a copy of the GNU Lesser General Public License
26 # version 3 along with OpenOffice.org. If not, see
27 # <http://www.openoffice.org/license.html>
28 # for a copy of the LGPLv3 License.
30 #*************************************************************************
32 PRJ=..
34 PRJNAME=cairo
35 TARGET=so_pixman
36 EXTERNAL_WARNINGS_NOT_ERRORS := TRUE
38 # --- Settings -----------------------------------------------------
40 .INCLUDE : settings.mk
42 .IF "$(ENABLE_CAIRO)" == ""
43 all:
44 @echo "Nothing to do (Cairo not enabled)."
46 .ELIF "$(BUILD_PIXMAN)" == ""
47 all:
48 @echo "Not building pixman."
50 .ENDIF
52 # --- Files --------------------------------------------------------
54 PIXMANVERSION=0.12.0
56 TARFILE_NAME=pixman-$(PIXMANVERSION)
57 PATCH_FILE_NAME=..$/$(TARFILE_NAME).patch
59 # Note: we are building static pixman library to avoid linking problems.
60 # However, for Unix dynamic library must be used (especially due to 64bit issues)
62 .IF "$(OS)"=="WNT"
63 # --------- Windows -------------------------------------------------
64 .IF "$(COM)"=="GCC"
65 CONFIGURE_DIR=
66 CONFIGURE_ACTION=.$/configure
67 CONFIGURE_FLAGS=--enable-static=yes --enable-shared=no --build=i586-pc-mingw32 --host=i586-pc-mingw32 CFLAGS="$(pixman_CFLAGS) -D_MT" LDFLAGS="$(pixman_LDFLAGS) -no-undefined -L$(ILIB:s/;/ -L/)" LIBS="-lmingwthrd" OBJDUMP="$(WRAPCMD) objdump"
68 BUILD_ACTION=$(GNUMAKE)
69 BUILD_FLAGS+= -j$(EXTMAXPROCESS)
70 BUILD_DIR=$(CONFIGURE_DIR)
71 .IF "$(GUI)$(COM)"=="WNTGCC"
72 .EXPORT : PWD
73 .ENDIF
75 .ELSE # WNT, not GCC
76 BUILD_DIR=pixman
77 BUILD_ACTION=$(GNUMAKE) -f Makefile.win32
78 .ENDIF
80 .ELIF "$(GUIBASE)"=="aqua"
81 # ----------- Native Mac OS X (Aqua/Quartz) --------------------------------
82 CONFIGURE_DIR=
83 CONFIGURE_ACTION=.$/configure
84 CONFIGURE_FLAGS=--enable-static=yes --enable-shared=no
85 BUILD_ACTION=$(GNUMAKE)
86 BUILD_FLAGS+= -j$(EXTMAXPROCESS)
87 BUILD_DIR=$(CONFIGURE_DIR)
89 .ELSE
90 # ----------- Unix ---------------------------------------------------------
91 .IF "$(OS)$(COM)"=="LINUXGCC" || "$(OS)$(COM)"=="FREEBSDGCC"
92 LDFLAGS:=-Wl,-rpath,'$$$$ORIGIN:$$$$ORIGIN/../ure-link/lib' -Wl,-z,noexecstack
93 .ENDIF # "$(OS)$(COM)"=="LINUXGCC"
95 .IF "$(OS)$(COM)"=="SOLARISC52"
96 LDFLAGS:=-Wl,-R'$$$$ORIGIN:$$$$ORIGIN/../ure-link/lib'
97 .ENDIF # "$(OS)$(COM)"=="SOLARISC52"
99 .IF "$(SYSBASE)"!=""
100 pixman_CFLAGS+=-I$(SYSBASE)$/usr$/include -I$(SOLARINCDIR)$/external $(EXTRA_CFLAGS)
101 .IF "$(OS)"=="SOLARIS" || "$(OS)"=="LINUX"
102 LDFLAGS+=-L$(SYSBASE)$/lib -L$(SYSBASE)$/usr$/lib -L$(SOLARLIBDIR) -lpthread -ldl
103 .ENDIF
104 .ENDIF # "$(SYSBASE)"!=""
106 .EXPORT: LDFLAGS
108 .IF "$(COMNAME)"=="sunpro5"
109 pixman_CFLAGS+=-xc99=none
110 .ENDIF
112 pixman_CFLAGS+=-fPIC
114 CONFIGURE_DIR=
115 CONFIGURE_ACTION=.$/configure
116 CONFIGURE_FLAGS=--enable-static=no --enable-shared=yes CFLAGS="$(pixman_CFLAGS)"
117 BUILD_ACTION=$(GNUMAKE)
118 BUILD_FLAGS+= -j$(EXTMAXPROCESS)
119 BUILD_DIR=$(CONFIGURE_DIR)
120 .ENDIF
124 # -------- All platforms --------------------------------------------
126 OUT2INC=pixman$/pixman-version.h \
127 pixman$/pixman.h
129 .IF "$(OS)"=="MACOSX"
130 OUT2LIB+=pixman$/.libs$/libpixman-1.a
131 .ELIF "$(OS)"=="WNT"
132 .IF "$(COM)"=="GCC"
133 OUT2LIB+=pixman$/.libs$/*.a
134 .ELSE
135 OUT2LIB+=pixman$/release$/*.lib
136 .ENDIF
137 .ELSE
138 OUT2LIB+=pixman$/.libs$/libpixman-1.so*
139 .ENDIF
141 # --- Targets ------------------------------------------------------
143 .INCLUDE : set_ext.mk
144 .INCLUDE : target.mk
145 .INCLUDE : tg_ext.mk