xref: /trunk/ext_libraries/hunspell/makefile.mk (revision 9ef65f0e)
1#*************************************************************************
2#
3# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4#
5# Copyright 2000, 2010 Oracle and/or its affiliates.
6#
7# OpenOffice.org - a multi-platform office productivity suite
8#
9# This file is part of OpenOffice.org.
10#
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.
14#
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).
20#
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.
25#
26#*************************************************************************
27
28PRJ=.
29
30PRJNAME=hunspell
31TARGET=hunspell
32
33# --- Settings -----------------------------------------------------
34
35.INCLUDE :	settings.mk
36
37# --- Files --------------------------------------------------------
38
39.IF "$(ENABLE_HUNSPELL)" != "YES"
40
41all:
42	@echo "hunspell is disabled"
43
44.ELSE
45
46TARFILE_NAME=hunspell-1.2.9
47TARFILE_MD5=68dd2e8253d9a7930e9fd50e2d7220d0
48ADDITIONAL_FILES+=config.h
49
50PATCH_FILES=\
51    hunspell-wntconfig.patch \
52    hunspell-solaris.patch \
53    hunspell-stacksmash.patch \
54    hunspell.patch
55
56.IF "$(GUI)"=="UNX"
57
58#relative to CONFIGURE_DIR
59CONFIGURE_ACTION=$(AUGMENT_LIBRARY_PATH) configure
60CONFIGURE_FLAGS= --disable-shared --with-pic
61.IF "$(COMNAME)"=="sunpro5"
62CONFIGURE_FLAGS+= CFLAGS=-xc99=none
63.ENDIF                  # "$(COMNAME)"=="sunpro5"
64
65.IF "$(SYSBASE)"!=""
66.IF "$(EXTRA_CFLAGS)"!=""
67CONFIGURE_FLAGS+= CFLAGS="$(EXTRA_CFLAGS)" CXXFLAGS="$(EXTRA_CFLAGS)"
68.ENDIF # "$(EXTRA_CFLAGS)"!=""
69.ELIF "$(OS)"=="MACOSX" # "$(SYSBASE)"!=""
70CONFIGURE_FLAGS+=CPPFLAGS="$(EXTRA_CDEFS)"
71.ELIF "$(OS)"=="FREEBSD" # "$(SYSBASE)"!=""
72CONFIGURE_FLAGS+=CPPFLAGS="-I$(LIBINTL_PREFIX)/include" --with-libintl-prefix="$(LIBINTL_PREFIX)"
73.ENDIF
74
75BUILD_ACTION=$(GNUMAKE) -j$(EXTMAXPROCESS)
76
77OUT2LIB=$(BUILD_DIR)$/src$/hunspell$/.libs$/libhunspell-1.2.a
78
79.ENDIF # "$(GUI)"=="UNX"
80
81
82.IF "$(GUI)"=="WNT"
83.IF "$(COM)"=="GCC"
84PATCH_FILES=\
85    hunspell-mingw.patch
86
87CONFIGURE_ACTION=configure
88CONFIGURE_FLAGS= --disable-shared --with-pic LDFLAGS=-Wl,--enable-runtime-pseudo-reloc-v2
89BUILD_ACTION=make
90OUT2LIB=$(BUILD_DIR)$/src$/hunspell$/.libs$/libhunspell-1.2.a
91.ELSE
92BUILD_ACTION=cd src/hunspell && dmake
93.ENDIF
94.ENDIF # "$(GUI)"=="WNT"
95
96.IF "$(GUI)"=="OS2"
97BUILD_ACTION=cd src/hunspell && dmake
98.ENDIF # "$(GUI)"=="OS2"
99
100OUT2INC= \
101	$(BUILD_DIR)$/src$/hunspell$/*.hxx
102
103# --- Targets ------------------------------------------------------
104
105.INCLUDE : set_ext.mk
106.INCLUDE : target.mk
107.INCLUDE : tg_ext.mk
108.ENDIF
109