Makefile revision 325
843e19887f64dde75055cf8842fc4db2171eff45johnlev# Copyright 2007 Sun Microsystems, Inc. All rights reserved.
843e19887f64dde75055cf8842fc4db2171eff45johnlev# Use subject to license terms.
843e19887f64dde75055cf8842fc4db2171eff45johnlev# Permission is hereby granted, free of charge, to any person obtaining a
843e19887f64dde75055cf8842fc4db2171eff45johnlev# copy of this software and associated documentation files (the
843e19887f64dde75055cf8842fc4db2171eff45johnlev# "Software"), to deal in the Software without restriction, including
843e19887f64dde75055cf8842fc4db2171eff45johnlev# without limitation the rights to use, copy, modify, merge, publish,
843e19887f64dde75055cf8842fc4db2171eff45johnlev# distribute, and/or sell copies of the Software, and to permit persons
843e19887f64dde75055cf8842fc4db2171eff45johnlev# to whom the Software is furnished to do so, provided that the above
843e19887f64dde75055cf8842fc4db2171eff45johnlev# copyright notice(s) and this permission notice appear in all copies of
843e19887f64dde75055cf8842fc4db2171eff45johnlev# the Software and that both the above copyright notice(s) and this
843e19887f64dde75055cf8842fc4db2171eff45johnlev# permission notice appear in supporting documentation.
843e19887f64dde75055cf8842fc4db2171eff45johnlev# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
843e19887f64dde75055cf8842fc4db2171eff45johnlev# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
843e19887f64dde75055cf8842fc4db2171eff45johnlev# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
843e19887f64dde75055cf8842fc4db2171eff45johnlev# OF THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
843e19887f64dde75055cf8842fc4db2171eff45johnlev# HOLDERS INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL
843e19887f64dde75055cf8842fc4db2171eff45johnlev# INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING
843e19887f64dde75055cf8842fc4db2171eff45johnlev# FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
843e19887f64dde75055cf8842fc4db2171eff45johnlev# NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
7f0b8309074a5d8e9f9d8ffe7aad7bb0b1ee6b1fEdward Pilatowicz# WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
843e19887f64dde75055cf8842fc4db2171eff45johnlev# Except as contained in this notice, the name of a copyright holder
843e19887f64dde75055cf8842fc4db2171eff45johnlev# shall not be used in advertising or otherwise to promote the sale, use
843e19887f64dde75055cf8842fc4db2171eff45johnlev# or other dealings in this Software without prior written authorization
843e19887f64dde75055cf8842fc4db2171eff45johnlev# of the copyright holder.
843e19887f64dde75055cf8842fc4db2171eff45johnlev# @(#)Makefile 1.6 07/05/15
843e19887f64dde75055cf8842fc4db2171eff45johnlev# Package name used in tarballs
843e19887f64dde75055cf8842fc4db2171eff45johnlev# Version number (used in path names)
843e19887f64dde75055cf8842fc4db2171eff45johnlev# Library name (used for specfiles/mapfiles)
843e19887f64dde75055cf8842fc4db2171eff45johnlev# Man pages to apply Sun footer to & attributes to list
843e19887f64dde75055cf8842fc4db2171eff45johnlev#SUNTOUCHED_MANPAGES=*.man
843e19887f64dde75055cf8842fc4db2171eff45johnlev#SUN_PACKAGE=SUNWxorg-server
843e19887f64dde75055cf8842fc4db2171eff45johnlev#LIB_STABILITY=Volatile
843e19887f64dde75055cf8842fc4db2171eff45johnlev#LIB_MAN_SUFFIX=3drm
843e19887f64dde75055cf8842fc4db2171eff45johnlev# Library built in tree
551bc2a66868b5cb5be6b70ab9f55515e77a39a9mrj# pkg-config files that need to have -R added
843e19887f64dde75055cf8842fc4db2171eff45johnlev########################################################################
843e19887f64dde75055cf8842fc4db2171eff45johnlev# Source tarball
843e19887f64dde75055cf8842fc4db2171eff45johnlevSOURCE_TARBALL_NAME=$(LIB_MODULE)-$(LIB_VERS).tar.bz2
843e19887f64dde75055cf8842fc4db2171eff45johnlev# Download site for source
843e19887f64dde75055cf8842fc4db2171eff45johnlevSOURCE_URL=http://dri.freedesktop.org/libdrm/$(SOURCE_TARBALL_NAME)
843e19887f64dde75055cf8842fc4db2171eff45johnlev# Directory created by unpacking source
843e19887f64dde75055cf8842fc4db2171eff45johnlev# Patches to apply to source after unpacking, in order
843e19887f64dde75055cf8842fc4db2171eff45johnlev-a '{Availability, $(SUN_PACKAGE)} {Interface Stability, $(LIB_STABILITY)} {MT-Level, See XInitThreads(3X11)}' $(LIB_SUNTOUCH_MAN_FLAGS)
843e19887f64dde75055cf8842fc4db2171eff45johnlev# Where to install files
843e19887f64dde75055cf8842fc4db2171eff45johnlev# Command line options to GNU autoconf configure script
843e19887f64dde75055cf8842fc4db2171eff45johnlevCONFIG_OPTS = --enable-shared=yes --enable-static=no \
843e19887f64dde75055cf8842fc4db2171eff45johnlev --prefix=$(LIB_prefix) --mandir='$${prefix}/share/man' \
843e19887f64dde75055cf8842fc4db2171eff45johnlev --libdir='$${exec_prefix}/lib$(LIB_ADD_SUBDIR)$(LIBSUBDIR)' \
843e19887f64dde75055cf8842fc4db2171eff45johnlev# Environment variable options to GNU autoconf configure script
843e19887f64dde75055cf8842fc4db2171eff45johnlevTHIS_LIB_CFLAGS=$(LIB_CFLAGS) -I$(PROTODIR)/usr/X11/include $(LIB_ADD_CFLAGS)
843e19887f64dde75055cf8842fc4db2171eff45johnlevCONFIG_ENV = CC=gcc CFLAGS="$(DEFAULT_GCC_CFLAGS) $(ARCH_GCC_FLAGS)" \
843e19887f64dde75055cf8842fc4db2171eff45johnlev PKG_CONFIG_PATH=$(PROTODIR)/usr/lib$(ARCHLIBSUBDIR)/pkgconfig:$(TOP)/common/pc-files/$(BUILD_DIR) \
843e19887f64dde75055cf8842fc4db2171eff45johnlev INSTALL="$(TOP)/common/install-sh -c" CPPROG="cp -p" \
843e19887f64dde75055cf8842fc4db2171eff45johnlev# Run configure script
843e19887f64dde75055cf8842fc4db2171eff45johnlev$(SOURCE_DIR)/Makefile: $(UNPACK_TARGET) $(XPROTO_DEP)
843e19887f64dde75055cf8842fc4db2171eff45johnlev$(LIB_BUILT): $(SOURCE_DIR)/Makefile $(LIB_ADD_BUILD_DEPS)
843e19887f64dde75055cf8842fc4db2171eff45johnlev (cd $(SOURCE_DIR) ; LD_OPTIONS="$(LIB_REQUIRED_LDFLAGS) $(LIB_ADD_LD_OPTIONS)" $(MAKE) $(MFLAGS) )
843e19887f64dde75055cf8842fc4db2171eff45johnlev (cd $(SOURCE_DIR) ; $(LIBPATHS) LD_OPTIONS="$(LIB_REQUIRED_LDFLAGS) $(LIB_ADD_LD_OPTIONS)" $(MAKE) $(MFLAGS) -e DESTDIR=$(PROTODIR) libdir=$(LIB_prefix)/lib$(LIB_ADD_SUBDIR)$(ARCHLIBSUBDIR) install pkgconfigdir=/usr/lib$(ARCHLIBSUBDIR)/pkgconfig)