]>
Commit | Line | Data |
---|---|---|
2bd0ea18 | 1 | # |
82805b60 | 2 | # Copyright (c) 2004-2006 Silicon Graphics, Inc. |
f302e9e4 | 3 | # All Rights Reserved. |
dfc130f3 | 4 | # |
f302e9e4 NS |
5 | # This program is free software; you can redistribute it and/or |
6 | # modify it under the terms of the GNU General Public License as | |
2bd0ea18 | 7 | # published by the Free Software Foundation. |
dfc130f3 | 8 | # |
2bd0ea18 NS |
9 | # This program is distributed in the hope that it would be useful, but |
10 | # WITHOUT ANY WARRANTY; without even the implied warranty of | |
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. | |
dfc130f3 | 12 | # |
f302e9e4 NS |
13 | # You should have received a copy of the GNU General Public License |
14 | # along with this program; if not, write the Free Software Foundation, | |
15 | # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA | |
2bd0ea18 NS |
16 | # |
17 | # @configure_input@ | |
18 | # | |
19 | ||
6c6508ec NS |
20 | ifndef _BUILDDEFS_INCLUDED_ |
21 | _BUILDDEFS_INCLUDED_ = 1 | |
286ceebb | 22 | |
2bd0ea18 NS |
23 | DEBUG = @debug_build@ |
24 | OPTIMIZER = @opt_build@ | |
25 | MALLOCLIB = @malloc_lib@ | |
4d32d744 | 26 | LOADERFLAGS = @LDFLAGS@ |
717e6142 | 27 | LTLDFLAGS = @LDFLAGS@ |
c121166e | 28 | CFLAGS = @CFLAGS@ |
2bd0ea18 | 29 | |
6ec3f6ba | 30 | LIBRT = @librt@ |
639231be | 31 | LIBUUID = @libuuid@ |
949c0f10 | 32 | LIBPTHREAD = @libpthread@ |
541a1d4f | 33 | LIBTERMCAP = @libtermcap@ |
d4b9ebda | 34 | LIBEDITLINE = @libeditline@ |
e246ba5f | 35 | LIBREADLINE = @libreadline@ |
e4da9941 | 36 | LIBBLKID = @libblkid@ |
f937adac | 37 | LIBXFS = $(TOPDIR)/libxfs/libxfs.la |
3d93ccb7 | 38 | LIBXCMD = $(TOPDIR)/libxcmd/libxcmd.la |
d321ceac | 39 | LIBXLOG = $(TOPDIR)/libxlog/libxlog.la |
f937adac | 40 | LIBHANDLE = $(TOPDIR)/libhandle/libhandle.la |
fc49813f | 41 | |
9440d84d | 42 | PKG_NAME = @pkg_name@ |
93d9f139 NS |
43 | PKG_USER = @pkg_user@ |
44 | PKG_GROUP = @pkg_group@ | |
9440d84d NS |
45 | PKG_RELEASE = @pkg_release@ |
46 | PKG_VERSION = @pkg_version@ | |
47 | PKG_PLATFORM = @pkg_platform@ | |
48 | PKG_DISTRIBUTION= @pkg_distribution@ | |
595e27db CH |
49 | |
50 | prefix = @prefix@ | |
51 | exec_prefix = @exec_prefix@ | |
52 | datarootdir = @datarootdir@ | |
53 | top_builddir = @top_builddir@ | |
54 | ||
9440d84d | 55 | PKG_SBIN_DIR = @sbindir@ |
595e27db CH |
56 | PKG_ROOT_SBIN_DIR = @root_sbindir@ |
57 | PKG_ROOT_LIB_DIR= @root_libdir@@libdirsuffix@ | |
82805b60 | 58 | PKG_LIB_DIR = @libdir@@libdirsuffix@ |
9440d84d | 59 | PKG_INC_DIR = @includedir@/xfs |
595e27db | 60 | DK_INC_DIR = @includedir@/disk |
9440d84d NS |
61 | PKG_MAN_DIR = @mandir@ |
62 | PKG_DOC_DIR = @datadir@/doc/@pkg_name@ | |
63 | PKG_LOCALE_DIR = @datadir@/locale | |
2bd0ea18 | 64 | |
9440d84d | 65 | CC = @cc@ |
e14913c1 | 66 | BUILD_CC = @BUILD_CC@ |
9440d84d NS |
67 | AWK = @awk@ |
68 | SED = @sed@ | |
69 | TAR = @tar@ | |
70 | ZIP = @zip@ | |
71 | MAKE = @make@ | |
72 | ECHO = @echo@ | |
16c44ed2 | 73 | SORT = @sort@ |
9440d84d | 74 | LN_S = @LN_S@ |
6abbfed5 | 75 | SHELL = @SHELL@ |
9440d84d NS |
76 | LIBTOOL = @LIBTOOL@ |
77 | MAKEDEPEND = @makedepend@ | |
78 | ||
79 | MSGFMT = @msgfmt@ | |
80 | MSGMERGE = @msgmerge@ | |
1b758ea9 | 81 | XGETTEXT = @xgettext@ |
8c053393 | 82 | LOCALIZED_FILES = @LOCALIZED_FILES@ |
9440d84d NS |
83 | |
84 | RPM = @rpm@ | |
85 | RPMBUILD = @rpmbuild@ | |
86 | RPM_VERSION = @rpm_version@ | |
f937adac | 87 | |
82805b60 TS |
88 | ENABLE_SHARED = @enable_shared@ |
89 | ENABLE_GETTEXT = @enable_gettext@ | |
90 | ENABLE_EDITLINE = @enable_editline@ | |
91 | ENABLE_READLINE = @enable_readline@ | |
92 | ||
9440d84d NS |
93 | HAVE_ZIPPED_MANPAGES = @have_zipped_manpages@ |
94 | ||
0bba1a49 NS |
95 | HAVE_FADVISE = @have_fadvise@ |
96 | HAVE_MADVISE = @have_madvise@ | |
97 | HAVE_MINCORE = @have_mincore@ | |
98 | HAVE_SENDFILE = @have_sendfile@ | |
cfe6e3f0 NS |
99 | HAVE_GETMNTENT = @have_getmntent@ |
100 | HAVE_GETMNTINFO = @have_getmntinfo@ | |
c0b5232a | 101 | HAVE_FALLOCATE = @have_fallocate@ |
8f0e0912 | 102 | HAVE_FIEMAP = @have_fiemap@ |
197d5828 ES |
103 | HAVE_PREADV = @have_preadv@ |
104 | HAVE_SYNC_FILE_RANGE = @have_sync_file_range@ | |
3bc05641 | 105 | HAVE_READDIR = @have_readdir@ |
5ae294ea | 106 | HAVE_MNTENT = @have_mntent@ |
5121281b | 107 | HAVE_FLS = @have_fls@ |
0bba1a49 | 108 | |
5e656dbb BN |
109 | GCCFLAGS = -funsigned-char -fno-strict-aliasing -Wall |
110 | # -Wbitwise -Wno-transparent-union -Wno-old-initializer -Wno-decl | |
d3a8db8a | 111 | |
9440d84d | 112 | ifeq ($(PKG_PLATFORM),linux) |
52b83345 | 113 | PCFLAGS = -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 $(GCCFLAGS) |
cd960ece MS |
114 | ifeq ($(HAVE_UMODE_T),yes) |
115 | PCFLAGS += -DHAVE_UMODE_T | |
116 | endif | |
d931d17e | 117 | DEPENDFLAGS = -D__linux__ |
93d9f139 | 118 | endif |
2ee06c8d PS |
119 | ifeq ($(PKG_PLATFORM),gnukfreebsd) |
120 | PCFLAGS = -D_GNU_SOURCE $(GCCFLAGS) | |
121 | endif | |
93d9f139 | 122 | ifeq ($(PKG_PLATFORM),darwin) |
96f2cfb2 | 123 | PCFLAGS = $(GCCFLAGS) |
d931d17e | 124 | DEPENDFLAGS = -D__APPLE__ |
9440d84d | 125 | endif |
93d9f139 NS |
126 | ifeq ($(PKG_PLATFORM),irix) |
127 | PLDLIBS = -ldisk -lgen | |
d931d17e | 128 | DEPENDFLAGS = -D__sgi__ |
93d9f139 | 129 | endif |
4f1631ae RC |
130 | ifeq ($(PKG_PLATFORM),freebsd) |
131 | PLDLIBS = -L/usr/local/lib -lintl | |
d3a8db8a | 132 | PCFLAGS = -I/usr/local/include $(GCCFLAGS) |
d931d17e | 133 | DEPENDFLAGS = -D__FreeBSD__ |
4f1631ae | 134 | endif |
5121281b JT |
135 | ifeq ($(HAVE_FLS),yes) |
136 | LCFLAGS+= -DHAVE_FLS | |
137 | endif | |
5ae294ea JT |
138 | ifeq ($(HAVE_MNTENT),yes) |
139 | PCFLAGS+= -DHAVE_MNTENT | |
140 | endif | |
9440d84d | 141 | |
d3a8db8a | 142 | GCFLAGS = $(OPTIMIZER) $(DEBUG) \ |
062998e3 | 143 | -DVERSION=\"$(PKG_VERSION)\" -DLOCALEDIR=\"$(PKG_LOCALE_DIR)\" \ |
6b803e5a | 144 | -DPACKAGE=\"$(PKG_NAME)\" -I$(TOPDIR)/include -I$(TOPDIR)/libxfs |
f937adac | 145 | |
e84ec15d AM |
146 | ifeq ($(ENABLE_GETTEXT),yes) |
147 | GCFLAGS += -DENABLE_GETTEXT | |
148 | endif | |
149 | ||
1bdd986b NS |
150 | # First, Global, Platform, Local CFLAGS |
151 | CFLAGS += $(FCFLAGS) $(GCFLAGS) $(PCFLAGS) $(LCFLAGS) | |
2bd0ea18 | 152 | |
3ded4129 | 153 | include $(TOPDIR)/include/buildmacros |
286ceebb NS |
154 | |
155 | endif | |
156 | ||
157 | # | |
158 | # For targets that should always be rebuilt, | |
159 | # define a target that is never up-to-date. | |
160 | # Targets needing this should depend on $(_FORCE) | |
161 | _FORCE = __force_build |