xref: /aoo42x/main/redland/raptor/makefile.mk (revision cdf0e10c)
1*cdf0e10cSrcweir#*************************************************************************
2*cdf0e10cSrcweir#
3*cdf0e10cSrcweir# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4*cdf0e10cSrcweir#
5*cdf0e10cSrcweir# Copyright 2000, 2010 Oracle and/or its affiliates.
6*cdf0e10cSrcweir#
7*cdf0e10cSrcweir# OpenOffice.org - a multi-platform office productivity suite
8*cdf0e10cSrcweir#
9*cdf0e10cSrcweir# This file is part of OpenOffice.org.
10*cdf0e10cSrcweir#
11*cdf0e10cSrcweir# OpenOffice.org is free software: you can redistribute it and/or modify
12*cdf0e10cSrcweir# it under the terms of the GNU Lesser General Public License version 3
13*cdf0e10cSrcweir# only, as published by the Free Software Foundation.
14*cdf0e10cSrcweir#
15*cdf0e10cSrcweir# OpenOffice.org is distributed in the hope that it will be useful,
16*cdf0e10cSrcweir# but WITHOUT ANY WARRANTY; without even the implied warranty of
17*cdf0e10cSrcweir# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18*cdf0e10cSrcweir# GNU Lesser General Public License version 3 for more details
19*cdf0e10cSrcweir# (a copy is included in the LICENSE file that accompanied this code).
20*cdf0e10cSrcweir#
21*cdf0e10cSrcweir# You should have received a copy of the GNU Lesser General Public License
22*cdf0e10cSrcweir# version 3 along with OpenOffice.org.  If not, see
23*cdf0e10cSrcweir# <http://www.openoffice.org/license.html>
24*cdf0e10cSrcweir# for a copy of the LGPLv3 License.
25*cdf0e10cSrcweir#
26*cdf0e10cSrcweir#*************************************************************************
27*cdf0e10cSrcweir
28*cdf0e10cSrcweirPRJ=..
29*cdf0e10cSrcweir
30*cdf0e10cSrcweirPRJNAME=redland
31*cdf0e10cSrcweirTARGET=so_raptor
32*cdf0e10cSrcweir
33*cdf0e10cSrcweir# --- Settings -----------------------------------------------------
34*cdf0e10cSrcweir
35*cdf0e10cSrcweir.INCLUDE :	settings.mk
36*cdf0e10cSrcweir
37*cdf0e10cSrcweir.IF "$(SYSTEM_REDLAND)" == "YES"
38*cdf0e10cSrcweirall:
39*cdf0e10cSrcweir	@echo "An already available installation of Redland RDF should exist on your system."
40*cdf0e10cSrcweir	@echo "Therefore the version provided here does not need to be built in addition."
41*cdf0e10cSrcweir.ENDIF
42*cdf0e10cSrcweir
43*cdf0e10cSrcweir# --- Files --------------------------------------------------------
44*cdf0e10cSrcweir
45*cdf0e10cSrcweir.INCLUDE :	../redlandversion.mk
46*cdf0e10cSrcweir
47*cdf0e10cSrcweirRAPTORVERSION=$(RAPTOR_MAJOR).4.18
48*cdf0e10cSrcweir
49*cdf0e10cSrcweirTARFILE_NAME=raptor-$(RAPTORVERSION)
50*cdf0e10cSrcweirTARFILE_MD5=284e768eeda0e2898b0d5bf7e26a016e
51*cdf0e10cSrcweir
52*cdf0e10cSrcweirADDITIONAL_FILES=src/makefile.mk src/raptor_config.h
53*cdf0e10cSrcweir
54*cdf0e10cSrcweirOOO_PATCH_FILES= \
55*cdf0e10cSrcweir    $(TARFILE_NAME).patch.legal \
56*cdf0e10cSrcweir    $(TARFILE_NAME).patch.autotools \
57*cdf0e10cSrcweir    $(TARFILE_NAME).patch.ooo_build \
58*cdf0e10cSrcweir    $(TARFILE_NAME).patch.dmake \
59*cdf0e10cSrcweir    $(TARFILE_NAME).patch.win32 \
60*cdf0e10cSrcweir
61*cdf0e10cSrcweir
62*cdf0e10cSrcweirPATCH_FILES=$(OOO_PATCH_FILES)
63*cdf0e10cSrcweir
64*cdf0e10cSrcweir
65*cdf0e10cSrcweir.IF "$(OS)"=="OS2"
66*cdf0e10cSrcweirBUILD_ACTION=dmake
67*cdf0e10cSrcweirBUILD_DIR=$(CONFIGURE_DIR)$/src
68*cdf0e10cSrcweir.ELIF "$(OS)"=="WNT"
69*cdf0e10cSrcweir.IF "$(COM)"=="GCC"
70*cdf0e10cSrcweirOOO_PATCH_FILES+=$(TARFILE_NAME).patch.mingw
71*cdf0e10cSrcweirraptor_CC=$(CC) -mthreads
72*cdf0e10cSrcweir.IF "$(MINGW_SHARED_GCCLIB)"=="YES"
73*cdf0e10cSrcweirraptor_CC+=-shared-libgcc
74*cdf0e10cSrcweir.ENDIF
75*cdf0e10cSrcweirraptor_LIBS=
76*cdf0e10cSrcweir.IF "$(MINGW_SHARED_GXXLIB)"=="YES"
77*cdf0e10cSrcweirraptor_LIBS+=$(MINGW_SHARED_LIBSTDCPP)
78*cdf0e10cSrcweir.ENDIF
79*cdf0e10cSrcweir
80*cdf0e10cSrcweirCONFIGURE_DIR=
81*cdf0e10cSrcweirCONFIGURE_ACTION=.$/configure
82*cdf0e10cSrcweir# do not enable grddl parser (#i93768#)
83*cdf0e10cSrcweirCONFIGURE_FLAGS=--disable-static --disable-gtk-doc --with-openssl-digests --with-xml-parser=libxml --enable-parsers="rdfxml ntriples turtle trig guess rss-tag-soup" --without-bdb --without-sqlite --without-mysql --without-postgresql --without-threestore       --with-regex-library=posix --with-decimal=none --with-www=xml --build=i586-pc-mingw32 --host=i586-pc-mingw32 lt_cv_cc_dll_switch="-shared" CC="$(raptor_CC)" CPPFLAGS="-nostdinc $(INCLUDE)" LDFLAGS="-no-undefined -Wl,--enable-runtime-pseudo-reloc-v2,--export-all-symbols  -L$(ILIB:s/;/ -L/)" LIBS="$(raptor_LIBS)" OBJDUMP="$(WRAPCMD) objdump" LIBXML2LIB=$(LIBXML2LIB) XSLTLIB="$(XSLTLIB)"
84*cdf0e10cSrcweirBUILD_ACTION=$(GNUMAKE)
85*cdf0e10cSrcweirBUILD_FLAGS+= -j$(EXTMAXPROCESS)
86*cdf0e10cSrcweirBUILD_DIR=$(CONFIGURE_DIR)
87*cdf0e10cSrcweir.ELSE
88*cdf0e10cSrcweir# there is no wntmsci build environment in the tarball; we use custom dmakefile
89*cdf0e10cSrcweirBUILD_ACTION=dmake
90*cdf0e10cSrcweirBUILD_DIR=$(CONFIGURE_DIR)$/src
91*cdf0e10cSrcweir.ENDIF
92*cdf0e10cSrcweir
93*cdf0e10cSrcweir.ELSE # "WNT"
94*cdf0e10cSrcweir
95*cdf0e10cSrcweir.IF "$(OS)$(COM)"=="LINUXGCC" || "$(OS)$(COM)"=="FREEBSDGCC"
96*cdf0e10cSrcweirLDFLAGS:=-Wl,-rpath,'$$$$ORIGIN:$$$$ORIGIN/../ure-link/lib' -Wl,-noinhibit-exec
97*cdf0e10cSrcweir.ENDIF                  # "$(OS)$(COM)"=="LINUXGCC"
98*cdf0e10cSrcweir.IF "$(OS)$(COM)"=="SOLARISC52"
99*cdf0e10cSrcweirLDFLAGS:=-Wl,-R'$$$$ORIGIN:$$$$ORIGIN/../ure-link/lib'
100*cdf0e10cSrcweir.ENDIF                  # "$(OS)$(COM)"=="SOLARISC52"
101*cdf0e10cSrcweir
102*cdf0e10cSrcweir.IF "$(COM)"=="C52" && "$(CPU)"=="U"
103*cdf0e10cSrcweirCFLAGS=-m64
104*cdf0e10cSrcweir.EXPORT: CFLAGS
105*cdf0e10cSrcweir.ENDIF
106*cdf0e10cSrcweir
107*cdf0e10cSrcweir# NB: SOLARDIR before SYSBASE, because linux SYSBASE contains obsolete libcrypto
108*cdf0e10cSrcweirCPPFLAGS+:=-I$(SOLARINCDIR)$/external
109*cdf0e10cSrcweirLDFLAGS+:=-L$(SOLARLIBDIR)
110*cdf0e10cSrcweir
111*cdf0e10cSrcweir.IF "$(SYSBASE)"!=""
112*cdf0e10cSrcweirCPPFLAGS+:=-I$(SYSBASE)$/usr$/include
113*cdf0e10cSrcweir.IF "$(OS)"=="SOLARIS" || "$(OS)"=="LINUX"
114*cdf0e10cSrcweirLDFLAGS+:=-L$(SYSBASE)$/lib -L$(SYSBASE)$/usr$/lib -lpthread -ldl
115*cdf0e10cSrcweir.ENDIF
116*cdf0e10cSrcweir.ENDIF			# "$(SYSBASE)"!=""
117*cdf0e10cSrcweir
118*cdf0e10cSrcweirCPPFLAGS+:=$(EXTRA_CDEFS) $(EXTRA_CFLAGS)
119*cdf0e10cSrcweirLDFLAGS+:=$(EXTRA_LINKFLAGS)
120*cdf0e10cSrcweirXSLTLIB!:=$(XSLTLIB) # expand dmake variables for xslt-config
121*cdf0e10cSrcweir
122*cdf0e10cSrcweir.EXPORT: CPPFLAGS
123*cdf0e10cSrcweir.EXPORT: LDFLAGS
124*cdf0e10cSrcweir.EXPORT: LIBXML2LIB
125*cdf0e10cSrcweir.EXPORT: XSLTLIB
126*cdf0e10cSrcweir
127*cdf0e10cSrcweirCONFIGURE_DIR=
128*cdf0e10cSrcweirCONFIGURE_ACTION=.$/configure
129*cdf0e10cSrcweir# do not enable grddl parser (#i93768#)
130*cdf0e10cSrcweirCONFIGURE_FLAGS=--disable-static --disable-gtk-doc --with-threads --with-openssl-digests --with-xml-parser=libxml --enable-parsers="rdfxml ntriples turtle trig guess rss-tag-soup" --without-bdb --without-sqlite --without-mysql --without-postgresql --without-threestore       --with-regex-library=posix --with-decimal=none --with-www=xml
131*cdf0e10cSrcweirBUILD_ACTION=$(GNUMAKE)
132*cdf0e10cSrcweirBUILD_FLAGS+= -j$(EXTMAXPROCESS)
133*cdf0e10cSrcweirBUILD_DIR=$(CONFIGURE_DIR)
134*cdf0e10cSrcweir#INSTALL_ACTION=$(GNUMAKE) install
135*cdf0e10cSrcweir#INSTALL_FLAGS+=DESTDIR=$(PWD)$/$(P_INSTALL_TARGET_DIR)
136*cdf0e10cSrcweir.ENDIF
137*cdf0e10cSrcweir
138*cdf0e10cSrcweir
139*cdf0e10cSrcweirOUT2INC+=src$/raptor.h
140*cdf0e10cSrcweir
141*cdf0e10cSrcweir.IF "$(OS)"=="MACOSX"
142*cdf0e10cSrcweirOUT2LIB+=src$/.libs$/libraptor.$(RAPTOR_MAJOR).dylib src$/.libs$/libraptor.dylib
143*cdf0e10cSrcweirOUT2BIN+=src/raptor-config
144*cdf0e10cSrcweir.ELIF "$(OS)"=="WNT"
145*cdf0e10cSrcweir.IF "$(COM)"=="GCC"
146*cdf0e10cSrcweirOUT2LIB+=src$/.libs$/*.a
147*cdf0e10cSrcweirOUT2BIN+=src$/.libs$/*.dll
148*cdf0e10cSrcweirOUT2BIN+=src/raptor-config
149*cdf0e10cSrcweir.ELSE
150*cdf0e10cSrcweir# if we use dmake, this is done automagically
151*cdf0e10cSrcweir.ENDIF
152*cdf0e10cSrcweir.ELIF "$(GUI)"=="OS2"
153*cdf0e10cSrcweir# if we use dmake, this is done automagically
154*cdf0e10cSrcweir.ELSE
155*cdf0e10cSrcweirOUT2LIB+=src$/.libs$/libraptor.so.$(RAPTOR_MAJOR) src$/.libs$/libraptor.so
156*cdf0e10cSrcweirOUT2BIN+=src/raptor-config
157*cdf0e10cSrcweir.ENDIF
158*cdf0e10cSrcweir
159*cdf0e10cSrcweir# --- Targets ------------------------------------------------------
160*cdf0e10cSrcweir
161*cdf0e10cSrcweir.INCLUDE : set_ext.mk
162*cdf0e10cSrcweir.INCLUDE : target.mk
163*cdf0e10cSrcweir.INCLUDE : tg_ext.mk
164*cdf0e10cSrcweir
165