update dev300-m58
[ooovba.git] / libxslt / makefile.mk
blobba335eed7e19eb0592205f15573ef608b327b730
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.16 $
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=libxslt
35 TARGET=so_libxslt
37 # --- Settings -----------------------------------------------------
39 .INCLUDE : settings.mk
41 .IF "$(SYSTEM_LIBXSLT)" == "YES"
42 all:
43 @echo "An already available installation of libxslt should exist on your system."
44 @echo "Therefore the version provided here does not need to be built in addition."
45 .ENDIF
47 # --- Files --------------------------------------------------------
49 .INCLUDE : libxsltversion.mk
51 LIBXSLTVERSION=$(LIBXSLT_MAJOR).$(LIBXSLT_MINOR).$(LIBXSLT_MICRO)
53 TARFILE_NAME=$(PRJNAME)-$(LIBXSLTVERSION)
54 PATCH_FILES=$(TARFILE_NAME).patch $(TARFILE_NAME)_win_manifest.patch
56 # This is only for UNX environment now
58 .IF "$(OS)"=="WNT"
59 .IF "$(COM)"=="GCC"
60 xslt_CC=$(CC)
61 .IF "$(MINGW_SHARED_GCCLIB)"=="YES"
62 xslt_CC+=-shared-libgcc
63 .ENDIF
64 xslt_LIBS=-lmingwthrd
65 .IF "$(MINGW_SHARED_GXXLIB)"=="YES"
66 xslt_LIBS+=-lstdc++_s
67 .ENDIF
68 CONFIGURE_DIR=
69 CONFIGURE_ACTION=.$/configure
70 CONFIGURE_FLAGS=--enable-ipv6=no --without-crypto --without-python --enable-static=no --with-sax1=yes --build=i586-pc-mingw32 --host=i586-pc-mingw32 CC="$(xslt_CC)" CFLAGS="$(xslt_CFLAGS) -D_MT" LDFLAGS="-no-undefined -L$(ILIB:s/;/ -L/)" LIBS="$(xslt_LIBS)" LIBXML2LIB=$(LIBXML2LIB) OBJDUMP="$(WRAPCMD) objdump"
71 BUILD_ACTION=chmod 777 xslt-config && $(GNUMAKE)
72 BUILD_FLAGS+= -j$(EXTMAXPROCESS)
73 BUILD_DIR=$(CONFIGURE_DIR)
74 .IF "$(GUI)$(COM)"=="WNTGCC"
75 .EXPORT : PWD
76 .ENDIF
77 .ELSE
78 CONFIGURE_DIR=win32
79 CONFIGURE_ACTION=cscript configure.js
80 #CONFIGURE_FLAGS=iconv=no sax1=yes
81 .IF "$(debug)"!=""
82 CONFIGURE_FLAGS+=debug=yes
83 .ENDIF
84 BUILD_ACTION=nmake
85 BUILD_DIR=$(CONFIGURE_DIR)
86 .ENDIF
87 .ELSE
89 .IF "$(OS)$(COM)"=="LINUXGCC" || "$(OS)$(COM)"=="FREEBSDGCC"
90 LDFLAGS:=-Wl,-rpath,'$$$$ORIGIN:$$$$ORIGIN/../ure-link/lib' -Wl,-noinhibit-exec -Wl,-z,noexecstack
91 .ENDIF # "$(OS)$(COM)"=="LINUXGCC"
92 .IF "$(OS)$(COM)"=="SOLARISC52"
93 LDFLAGS:=-Wl,-R'$$$$ORIGIN:$$$$ORIGIN/../ure-link/lib'
94 .ENDIF # "$(OS)$(COM)"=="SOLARISC52"
96 .IF "$(SYSBASE)"!=""
97 CPPFLAGS+:=-I$(SOLARINCDIR)$/external -I$(SYSBASE)$/usr$/include $(EXTRA_CFLAGS)
98 .IF "$(OS)"=="SOLARIS" || "$(OS)"=="LINUX"
99 LDFLAGS+:=-L$(SOLARLIBDIR) -L$(SYSBASE)$/lib -L$(SYSBASE)$/usr$/lib -lpthread -ldl
100 .ENDIF
101 .ENDIF # "$(SYSBASE)"!=""
103 .EXPORT: CPPFLAGS
104 .EXPORT: LDFLAGS
105 .EXPORT: LIBXML2LIB
106 .EXPORT: ZLIB3RDLIB
108 .IF "$(COMNAME)"=="sunpro5"
109 CPPFLAGS+:=$(ARCH_FLAGS) -xc99=none
110 .ENDIF # "$(COMNAME)"=="sunpro5"
111 CONFIGURE_DIR=
112 CONFIGURE_ACTION=.$/configure
113 CONFIGURE_FLAGS=--enable-ipv6=no --without-crypto --without-python --enable-static=no --with-sax1=yes
114 BUILD_ACTION=chmod 777 xslt-config && $(GNUMAKE)
115 BUILD_FLAGS+= -j$(EXTMAXPROCESS)
116 BUILD_DIR=$(CONFIGURE_DIR)
117 .ENDIF
119 OUT2INC=libxslt$/*.h
121 .IF "$(OS)"=="MACOSX"
122 OUT2LIB+=libxslt$/.libs$/libxslt.*.dylib
123 OUT2LIB+=libexslt$/.libs$/libexslt.*.dylib
124 OUT2BIN+=xsltproc$/.libs$/xsltproc
125 OUT2BIN+=xslt-config
126 .ELIF "$(OS)"=="WNT"
127 .IF "$(COM)"=="GCC"
128 OUT2LIB+=libxslt$/.libs$/*.a
129 OUT2LIB+=libexslt$/.libs$/*.a
130 OUT2BIN+=libxslt$/.libs$/*.dll
131 OUT2BIN+=libexslt$/.libs$/*.dll
132 OUT2BIN+=xsltproc$/.libs$/*.exe*
133 OUT2BIN+=xslt-config
134 .ELSE
135 OUT2LIB+=win32$/bin.msvc$/*.lib
136 OUT2BIN+=win32$/bin.msvc$/*.dll
137 OUT2BIN+=win32$/bin.msvc$/*.exe
138 .ENDIF
139 .ELSE
140 OUT2LIB+=libxslt$/.libs$/libxslt.so*
141 OUT2LIB+=libexslt$/.libs$/libexslt.so*
142 OUT2BIN+=xsltproc$/.libs$/xsltproc
143 OUT2BIN+=xslt-config
144 .ENDIF
146 # --- Targets ------------------------------------------------------
148 .INCLUDE : set_ext.mk
149 .INCLUDE : target.mk
150 .INCLUDE : tg_ext.mk