Makefile revision 911
5563N/A###############################################################################
5563N/A#
5563N/A# Copyright 2010 Sun Microsystems, Inc. All rights reserved.
5563N/A# Use is subject to license terms.
5563N/A#
5563N/A# Permission is hereby granted, free of charge, to any person obtaining a
5563N/A# copy of this software and associated documentation files (the
5563N/A# "Software"), to deal in the Software without restriction, including
5563N/A# without limitation the rights to use, copy, modify, merge, publish,
5563N/A# distribute, and/or sell copies of the Software, and to permit persons
5563N/A# to whom the Software is furnished to do so, provided that the above
5563N/A# copyright notice(s) and this permission notice appear in all copies of
5563N/A# the Software and that both the above copyright notice(s) and this
5563N/A# permission notice appear in supporting documentation.
5563N/A#
5563N/A# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
5563N/A# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
5563N/A# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
5563N/A# OF THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
5563N/A# HOLDERS INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL
5563N/A# INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING
5563N/A# FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
5563N/A# NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
5563N/A# WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
5563N/A#
5563N/A# Except as contained in this notice, the name of a copyright holder
5563N/A# shall not be used in advertising or otherwise to promote the sale, use
5563N/A# or other dealings in this Software without prior written authorization
5563N/A# of the copyright holder.
5563N/A#
5563N/A
5563N/A# Package name used in tarballs
5563N/AMODULE_NAME=MesaDemos
5563N/A
5563N/A# Version number (used in path names)
5563N/AMODULE_VERSION=7.4.4
5563N/A
5563N/A# Checksums for upstream tarball
5563N/ATARBALL_MD5 = 628142ec9a54cd28cc027e6ce26cff47
5563N/ATARBALL_SHA1 = 190b51dd1e456f12c70cd428ec47ca8de0ed72fe
5563N/A
5563N/A# Directory created by unpacking source
5563N/ASOURCE_DIRNAME=Mesa-$(MODULE_VERSION)
5563N/ASOURCE_DIRNAME_SET=yes
5563N/ASOURCE_DIR=$(BUILD_DIR)/$(SOURCE_DIRNAME)
5563N/A
5563N/A# Source tarball
5563N/ASOURCE_TARBALL_NAME=MesaDemos-$(MODULE_VERSION).tar.bz2
5563N/ASOURCE_TARBALL_NAME_SET=yes
5563N/A
5563N/A# Download site for source
5563N/ASOURCE_URL=$(SF_DOWNLOADS_URL)/mesa3d/$(SOURCE_TARBALL_NAME)
5563N/ASOURCE_URL_SET=yes
5563N/A
5563N/A# Patches to apply to source after unpacking, in order
5563N/ASOURCE_PATCHES= \
5563N/A
5563N/A# Xorg-6.9-changes.patch
5563N/A
5563N/A# Binaries built in tree
5563N/AGLXGEARS_BIN=$(SOURCE_DIR)/progs/xdemos/glxgears
5563N/AGLXINFO_BIN=$(SOURCE_DIR)/progs/xdemos/glxinfo
5563N/A
5563N/A# configure script is run in ../lib/mesa build, just link to results here
5563N/ACONFIGURE_TARGETS= $(SOURCE_DIR)/configs/current
5563N/ACONFIGURE_TARGETS_SET=yes
5563N/A
5563N/A# What to build
5563N/ABUILD_TARGETS= $(GLXGEARS_BIN) $(GLXINFO_BIN)
5563N/ABUILD_TARGETS_SET=yes
5563N/A
5563N/A# What to install
5563N/AINSTALL_TARGETS= install_glxgears install_glxinfo install_man
5563N/AINSTALL_TARGETS_SET=yes
5563N/A
5563N/A### Include common rulesets
5563N/Ainclude ../Makefile.inc
5563N/A
5563N/A### Rules specific to this directory:
5563N/A
5563N/A# Only care about building X demos
5563N/ADEMOS_DIR=$(SOURCE_DIR)/progs/xdemos
5563N/A
5563N/ADEMO_LDFLAGS=$(PROG_LDFLAGS) -L$(PROTODIR)$(X11_LIB_DIR)$(ARCHLIBSUBDIR) \
5563N/A -L$(PROTODIR)$(X11_SERVERLIBS_DIR)$(ARCHLIBSUBDIR)
5563N/A
5563N/A# Flags passed on make command line when building
5563N/AMODULE_BUILD_MAKEFLAGS = LDFLAGS="$(DEMO_LDFLAGS)"
5563N/A
5563N/A# Use configuration generated by Mesa library build
5563N/A$(SOURCE_DIR)/configs/current: $(UNPACK_TARGET)
5563N/A mkdir -p $(SOURCE_DIR)/configs
5563N/A (cd $(SOURCE_DIR)/configs && \
5563N/A $(LNDIR) ../../../../../lib/mesa/$(SOURCE_DIR)/configs)
5563N/A
5563N/A# Build Mesa demos
5563N/A$(GLXGEARS_BIN): $(UNPACK_TARGET) $(CONFIGURE_TARGETS)
5563N/A (cd $(DEMOS_DIR) && \
5563N/A $(MODULE_MAKE) $(MAKEFLAGS) $(DEFAULT_BUILD_MAKEFLAGS) glxgears )
5563N/A
5563N/A$(GLXINFO_BIN): $(UNPACK_TARGET) $(CONFIGURE_TARGETS)
5563N/A (cd $(DEMOS_DIR) && \
5563N/A $(MODULE_MAKE) $(MAKEFLAGS) $(DEFAULT_BUILD_MAKEFLAGS) glxinfo )
5563N/A
5563N/A# For testing - we don't ship the rest of these
5563N/Aall-xdemos_gen: $(UNPACK_TARGET) $(CONFIGURE_TARGETS)
5563N/A (cd $(DEMOS_DIR) && \
5563N/A $(MODULE_MAKE) $(MAKEFLAGS) $(DEFAULT_BUILD_MAKEFLAGS))
5563N/A
5563N/Aall-xdemos:
5563N/A $(MAKE) $(MAKEFLAGS) $(BUILD_32_FLAGS) all-xdemos_gen
5563N/A
5563N/ADESTDIR=$(PROTODIR)
5563N/A
5563N/Ainstall_glxgears: $(GLXGEARS_BIN)
5563N/A mkdir -p $(DESTDIR)$(MODULE_PREFIX)/bin
5563N/A cp -pf $(GLXGEARS_BIN) $(DESTDIR)$(MODULE_PREFIX)/bin
5563N/A
5563N/Ainstall_glxinfo: $(GLXINFO_BIN)
5563N/A mkdir -p $(DESTDIR)$(MODULE_PREFIX)/bin
5563N/A cp -pf $(GLXINFO_BIN) $(DESTDIR)$(MODULE_PREFIX)/bin
5563N/A
5563N/Ainstall_man:
5563N/A mkdir -p $(DESTDIR)$(MODULE_PREFIX)/share/man/man1
5563N/A cp -pf glxgears.1 glxinfo.1 $(DESTDIR)$(MODULE_PREFIX)/share/man/man1
5563N/A
5563N/A
5563N/A