78 lines
2.0 KiB
Makefile
78 lines
2.0 KiB
Makefile
#
|
|
# File: Makefile.macosx
|
|
# Author: Chuck Wooters
|
|
# Date: Mon July 29, 2002
|
|
#
|
|
# Description:
|
|
# Machine dependent compilation options and variable definitions
|
|
# for Mac (PowerPCs) running Mac OS X 10.x
|
|
#
|
|
|
|
# Use the GNU C compiler.
|
|
GCC_FLAGS = -Wall -Wno-unused-variable -Wno-uninitialized -Wno-overloaded-virtual
|
|
CC = cc $(GCC_FLAGS)
|
|
CXX = c++ $(GCC_FLAGS) -DINSTANTIATE_TEMPLATES
|
|
|
|
ARCHIVE = ar cru
|
|
RANLIB = ranlib -s
|
|
|
|
# Optional compilation flags.
|
|
OPTIMIZE_FLAGS = -g -O2 -fno-common
|
|
DEBUG_FLAGS = -g -DDEBUG
|
|
PROFILE_FLAGS = -pg -g -O2
|
|
|
|
# Optional linking flags.
|
|
EXPORT_LDFLAGS =
|
|
|
|
# Shared compilation flags.
|
|
CFLAGS = $(ADDITIONAL_CFLAGS) $(INCLUDES) -DHAVE_ZOPEN
|
|
CXXFLAGS = $(ADDITIONAL_CXXFLAGS) $(INCLUDES) -DHAVE_ZOPEN
|
|
|
|
# Shared linking flags.
|
|
LDFLAGS = $(ADDITIONAL_LDFLAGS) -L$(SRILM_LIBDIR)
|
|
|
|
# Other useful compilation flags.
|
|
ADDITIONAL_CFLAGS =
|
|
ADDITIONAL_CXXFLAGS =
|
|
|
|
# Other useful include directories.
|
|
ADDITIONAL_INCLUDES =
|
|
|
|
# Other useful linking flags.
|
|
ADDITIONAL_LDFLAGS =
|
|
|
|
# Other useful libraries.
|
|
ADDITIONAL_LIBRARIES =
|
|
|
|
# UTF16 conversion needs libiconv but can avoid iconv routines
|
|
# by building with "make NO_ICONV=anything"
|
|
ifeq ($(NO_ICONV), )
|
|
SYS_LIBRARIES = -liconv
|
|
endif
|
|
|
|
# Tcl support (as per Chuck Wooters):
|
|
# As of OS X 10.4, MacOS includes Tcl and you can use
|
|
TCL_INCLUDE = -I/usr/include
|
|
TCL_LIBRARY = -L/usr/lib -ltcl
|
|
# However, older OS versions might require that you install tcltk and
|
|
# tcltk-dev using 'fink' as in:
|
|
# fink install tcltk
|
|
# fink install tcltk-dev
|
|
# and then use
|
|
#TCL_INCLUDE = -I/sw/include
|
|
#TCL_LIBRARY = -L/sw/lib -ltcl
|
|
|
|
SYMBOL_PREFIX = _
|
|
|
|
# Generate dependencies from source files.
|
|
GEN_DEP = $(CC) $(CFLAGS) -MM
|
|
GEN_DEP.cc = $(CXX) $(CXXFLAGS) -MM
|
|
|
|
# Run lint.
|
|
LINT = lint
|
|
LINT_FLAGS = -DDEBUG $(CFLAGS)
|
|
|
|
# MacOSX awk is sufficiently compatible with gawk
|
|
GAWK = /usr/bin/awk
|
|
|