Makefile revision 837
ac4e70ff8955669341f435bc0a734a17c01af124Mark Andrews###############################################################################
205c10066a0acfeac52d1a135671f41d207b8557Automatic Updater# Copyright 2009 Sun Microsystems, Inc. All rights reserved.
1167fc7904c5f0a472f8df207ac46dd52c7f1ec8Automatic Updater# Use is subject to license terms.
46da3117812814a29432a8d9a9ccf8acdbfdadceAutomatic Updater# Permission is hereby granted, free of charge, to any person obtaining a
2bb3422dc683c013db7042f5736240de6b86f182Automatic Updater# copy of this software and associated documentation files (the
cd0aa2d941d1438fabb5337f1f38c49478edf71dAutomatic Updater# "Software"), to deal in the Software without restriction, including
2ec4ab21838e218863d052ebfa3e106e04f50820Evan Hunt# without limitation the rights to use, copy, modify, merge, publish,
ea854b585041ad19f70f7af15e08144ef2c2bd1bMark Andrews# distribute, and/or sell copies of the Software, and to permit persons
78cb74fab4665da2e2641ba909c6f59f74cc4193Automatic Updater# to whom the Software is furnished to do so, provided that the above
cd0aa2d941d1438fabb5337f1f38c49478edf71dAutomatic Updater# copyright notice(s) and this permission notice appear in all copies of
90ff38a0d8deaf5f9c2aa5916d99b2e572d28738Automatic Updater# the Software and that both the above copyright notice(s) and this
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington# permission notice appear in supporting documentation.
6c6a121295b30772cbf3dd75a51fb9d883051a0eAutomatic Updater# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
9cd5eb6fe0f26d65724b99216cb31dcdd12e4afdAutomatic Updater# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
bc0a53583d92309bebcf93c408e2f3247ebd3d3cAutomatic Updater# OF THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
56874aef380a64a2c183b7c282c3e7a361d67fa1Automatic Updater# HOLDERS INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING
58be84825d7f5de30e50eb7206b37227ecd8055bAutomatic Updater# FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
3cc98b8ecedcbc8465f1cf2740b966b315662430Automatic Updater# NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
96713299d08c0735c18ebe8772dd2cc1ecd4356aAutomatic Updater# Except as contained in this notice, the name of a copyright holder
831f79c4310a7d38fc3475ccfff531b2b2535641Automatic Updater# shall not be used in advertising or otherwise to promote the sale, use
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# or other dealings in this Software without prior written authorization
f2770f6b39a9b2a98afb7a11ed105f73f1570c1eAutomatic Updater# of the copyright holder.
f2770f6b39a9b2a98afb7a11ed105f73f1570c1eAutomatic Updater# @(#)Makefile 1.25 09/10/19
f2770f6b39a9b2a98afb7a11ed105f73f1570c1eAutomatic Updater# Package name used in tarballs
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic Updater# Version number (used in path names)
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic Updater# Source tarball
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic UpdaterSOURCE_TARBALL_NAME=MesaLib-$(MODULE_VERSION).tar.bz2
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic Updater# Download site for source
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic UpdaterSOURCE_URL=$(SF_DOWNLOADS_URL)/mesa3d/$(SOURCE_TARBALL_NAME)
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic Updater# Directory created by unpacking source
9513a2a6670951f5cf5477fcfec9f933fcaff628Automatic UpdaterSOURCE_DIR = $(BUILD_DIR)/$(SOURCE_DIRNAME)
cdfc81e048bd34c1d628380247bda6b80a89e20eAutomatic Updater# Patches to apply to source after unpacking, in order
eabc9c3c07cd956d3c436bd7614cb162dabdda76Mark Andrews# File created by running configure script
129090f0f6f91753b4a085ab635e28549fd018adAutomatic UpdaterDRI_DRIVER_LIST_i386=i915 i965 r200 r300 radeon
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark AndrewsDRI_DRIVER_LIST= $(DRI_DRIVER_LIST_$(MACH)) swrast
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# Command line options to GNU autoconf configure script
80faf1588895fd26490f82f95a7a1b771df1c324Automatic Updater --with-dri-driverdir='$(X11_SERVERMODS_DIR)/dri$(SERVERMOD_subdir)' \
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# Override LDFLAGS passed to configure to not include CFLAGS, since that
db5b7e2cdf150c46e8242d3e2e3ad3f5c7300258Automatic Updater# breaks building libGLU with Sun Studio C++ compiler
693c4232dfdffaff672197d4b9fea944c64cf80aAutomatic UpdaterMODULE_CONFIG_ENV = LDFLAGS="$(DEFAULT_CONFIG_LDFLAGS) $(ARCH_FLAGS) $(MODTYPE_LDFLAGS) $(MODULE_CFLAGS) $(MODULE_LDFLAGS)"
f2770f6b39a9b2a98afb7a11ed105f73f1570c1eAutomatic Updater# Need to use GNU Make to build
efb0e886f18894a1d2489f1ad74ad14b579e11c7Mark Andrews# To build with gcc, uncomment these lines and comment out the MODULE_CFLAGS
f2770f6b39a9b2a98afb7a11ed105f73f1570c1eAutomatic Updater# MODULE_COMPILER=gcc
91216cff91b34c9ff6e846dc23f248219cafe660Andreas Gustafsson# MODULE_COMPILER_SET=yes
f2770f6b39a9b2a98afb7a11ed105f73f1570c1eAutomatic Updater# Tell Sun compiler to not apply optimizations that increase binary sizes
91216cff91b34c9ff6e846dc23f248219cafe660Andreas Gustafsson# Without this flag, Studio 12 binaries are almost 2x bigger (CR 6808868)
dd65eb1efb40b1c47d57963192bfc54873b219beAutomatic Updater# Add include paths and linker paths needed for DRM modules
78f3ed4bc2fcd3d270bfd599804f3b27a1db4d91Mark AndrewsMODULE_CPPFLAGS = -I$(PROTODIR)$(X11_INCLUDES_DIR)/drm
9174e44c14b1cb91a651fa1dc29470438c246ab9Automatic UpdaterMODULE_LDFLAGS= -L$(PROTODIR)$(X11_SERVERLIBS_DIR)$(ARCHLIBSUBDIR) \
0c39b3ed9409ecb277d5e32fa763a4e4d6598df8Automatic Updater# Merge in additional sources from sun-src directory
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# pkg-config files that need to have -R added
f9119ad8f6114b2255e7545bf5cd187f4db0a89bAutomatic UpdaterFIX_PC_FILES=src/*/*.pc.in src/mesa/drivers/dri/dri.pc.in
78f3ed4bc2fcd3d270bfd599804f3b27a1db4d91Mark Andrews### Include common rulesets
78f3ed4bc2fcd3d270bfd599804f3b27a1db4d91Mark Andrews# Mesa makefiles use a different variable name/method for pkgconfig path
b29e5c56eb74a6de1a84c29879afc90ffc6b1436Automatic Updater echo 'INSTALL_PC_DIR=$(PKGCONFIG_DIR)' >> $(AUTOCONF_TARGET)