2 # Copyright (c) 2003 Silicon Graphics, Inc. All Rights Reserved.
7 ifndef _BUILDDEFS_INCLUDED_
8 _BUILDDEFS_INCLUDED_ = 1
11 OPTIMIZER = @opt_build@
12 MALLOCLIB = @malloc_lib@
13 LOADERFLAGS = @LDFLAGS@
17 HAVE_LIBXFS = @have_libxfs@
24 LIBTEST = $(TOPDIR)/lib/libtest.la
28 PKG_GROUP = @pkg_group@
29 PKG_RELEASE = @pkg_release@
30 PKG_VERSION = @pkg_version@
31 PKG_PLATFORM = @pkg_platform@
32 PKG_DISTRIBUTION= @pkg_distribution@
33 PKG_SBIN_DIR = @sbindir@
34 # A bit of a hack; by rights only state should probably go here
36 PKG_LIB_DIR = /var/lib/@pkg_name@
48 MAKEDEPEND = @makedepend@
55 RPM_VERSION = @rpm_version@
57 ENABLE_SHARED = @enable_shared@
60 HAVE_DMAPI = @have_dmapi@
61 HAVE_ATTR_LIST = @have_attr_list@
63 GCCFLAGS = -funsigned-char -fno-strict-aliasing -Wall
65 ifeq ($(PKG_PLATFORM),linux)
66 PCFLAGS = -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 $(GCCFLAGS)
67 DEPENDFLAGS = -D__linux__
69 ifeq ($(PKG_PLATFORM),darwin)
70 PCFLAGS = -traditional-cpp $(GCCFLAGS)
71 DEPENDFLAGS = -D__APPLE__
73 ifeq ($(PKG_PLATFORM),irix)
74 PCFLAGS = -nostdinc -I$(ROOT)/usr/include -I$(TOPDIR)/../irix/include
75 DEPENDFLAGS = -D__sgi__
77 ifeq ($(PKG_PLATFORM),freebsd)
78 DEPENDFLAGS = -D__FreeBSD__
81 GCFLAGS = $(OPTIMIZER) $(DEBUG) $(CPPFLAGS) \
82 -I$(TOPDIR)/include -DVERSION=\"$(PKG_VERSION)\"
84 # Global, Platform, Local CFLAGS
85 CFLAGS += $(GCFLAGS) $(PCFLAGS) $(LCFLAGS)
87 include $(TOPDIR)/include/buildmacros
92 # For targets that should always be rebuilt,
93 # define a target that is never up-to-date.
94 # Targets needing this should depend on $(_FORCE)
95 _FORCE = __force_build