Makefile revision 969
577N/A###############################################################################
577N/A#
577N/A# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
577N/A#
935N/A# Permission is hereby granted, free of charge, to any person obtaining a
577N/A# copy of this software and associated documentation files (the "Software"),
577N/A# to deal in the Software without restriction, including without limitation
919N/A# the rights to use, copy, modify, merge, publish, distribute, sublicense,
919N/A# and/or sell copies of the Software, and to permit persons to whom the
919N/A# Software is furnished to do so, subject to the following conditions:
919N/A#
919N/A# The above copyright notice and this permission notice (including the next
919N/A# paragraph) shall be included in all copies or substantial portions of the
919N/A# Software.
919N/A#
919N/A# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
919N/A# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
919N/A# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
919N/A# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
919N/A# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
919N/A# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
919N/A# DEALINGS IN THE SOFTWARE.
919N/A#
919N/A
577N/A# Package name used in tarballs
577N/AMODULE_NAME=MesaDemos
577N/A
577N/A# Version number (used in path names)
577N/AMODULE_VERSION=7.4.4
577N/A
851N/A# Checksums for upstream tarball
577N/ATARBALL_MD5 = 628142ec9a54cd28cc027e6ce26cff47
911N/ATARBALL_SHA1 = 190b51dd1e456f12c70cd428ec47ca8de0ed72fe
911N/A
911N/A# Directory created by unpacking source
911N/ASOURCE_DIRNAME=Mesa-$(MODULE_VERSION)
577N/ASOURCE_DIRNAME_SET=yes
606N/ASOURCE_DIR=$(BUILD_DIR)/$(SOURCE_DIRNAME)
829N/A
829N/A# Source tarball
829N/ASOURCE_TARBALL_NAME=MesaDemos-$(MODULE_VERSION).tar.bz2
577N/ASOURCE_TARBALL_NAME_SET=yes
577N/A
577N/A# Download site for source
577N/ASOURCE_URL=$(SF_DOWNLOADS_URL)/mesa3d/$(SOURCE_TARBALL_NAME)
577N/ASOURCE_URL_SET=yes
577N/A
577N/A# Patches to apply to source after unpacking, in order
577N/ASOURCE_PATCHES= \
970N/A
970N/A# Xorg-6.9-changes.patch
970N/A
970N/A# Binaries built in tree
970N/AGLXGEARS_BIN=$(SOURCE_DIR)/progs/xdemos/glxgears
970N/AGLXINFO_BIN=$(SOURCE_DIR)/progs/xdemos/glxinfo
970N/A
970N/A# configure script is run in ../lib/mesa build, just link to results here
970N/ACONFIGURE_TARGETS= $(SOURCE_DIR)/configs/current
970N/ACONFIGURE_TARGETS_SET=yes
970N/A
970N/A# What to build
577N/ABUILD_TARGETS= $(GLXGEARS_BIN) $(GLXINFO_BIN)
577N/ABUILD_TARGETS_SET=yes
577N/A
577N/A# What to install
577N/AINSTALL_TARGETS= install_glxgears install_glxinfo install_man
577N/AINSTALL_TARGETS_SET=yes
577N/A
577N/A### Include common rulesets
615N/Ainclude ../Makefile.inc
615N/A
615N/A### Rules specific to this directory:
810N/A
810N/A# Only care about building X demos
935N/ADEMOS_DIR=$(SOURCE_DIR)/progs/xdemos
935N/A
810N/ADEMO_LDFLAGS=$(PROG_LDFLAGS) -L$(PROTODIR)$(X11_LIB_DIR)$(ARCHLIBSUBDIR) \
970N/A -L$(PROTODIR)$(X11_SERVERLIBS_DIR)$(ARCHLIBSUBDIR)
970N/A
970N/A# Flags passed on make command line when building
577N/AMODULE_BUILD_MAKEFLAGS = LDFLAGS="$(DEMO_LDFLAGS)"
577N/A
577N/A# Use configuration generated by Mesa library build
935N/A$(SOURCE_DIR)/configs/current: $(UNPACK_TARGET)
935N/A mkdir -p $(SOURCE_DIR)/configs
935N/A (cd $(SOURCE_DIR)/configs && \
935N/A $(LNDIR) ../../../../../lib/mesa/$(SOURCE_DIR)/configs)
935N/A
935N/A# Build Mesa demos
935N/A$(GLXGEARS_BIN): $(UNPACK_TARGET) $(CONFIGURE_TARGETS)
935N/A (cd $(DEMOS_DIR) && \
577N/A $(MODULE_MAKE) $(MAKEFLAGS) $(DEFAULT_BUILD_MAKEFLAGS) glxgears )
967N/A
935N/A$(GLXINFO_BIN): $(UNPACK_TARGET) $(CONFIGURE_TARGETS)
577N/A (cd $(DEMOS_DIR) && \
1003N/A $(MODULE_MAKE) $(MAKEFLAGS) $(DEFAULT_BUILD_MAKEFLAGS) glxinfo )
1003N/A
577N/A# For testing - we don't ship the rest of these
1003N/Aall-xdemos_gen: $(UNPACK_TARGET) $(CONFIGURE_TARGETS)
577N/A (cd $(DEMOS_DIR) && \
577N/A $(MODULE_MAKE) $(MAKEFLAGS) $(DEFAULT_BUILD_MAKEFLAGS))
935N/A
577N/Aall-xdemos:
970N/A $(MAKE) $(MAKEFLAGS) $(BUILD_32_FLAGS) all-xdemos_gen
577N/A
577N/ADESTDIR=$(PROTODIR)
577N/A
577N/Ainstall_glxgears: $(GLXGEARS_BIN)
577N/A mkdir -p $(DESTDIR)$(MODULE_PREFIX)/bin
970N/A cp -pf $(GLXGEARS_BIN) $(DESTDIR)$(MODULE_PREFIX)/bin
970N/A
install_glxinfo: $(GLXINFO_BIN)
mkdir -p $(DESTDIR)$(MODULE_PREFIX)/bin
cp -pf $(GLXINFO_BIN) $(DESTDIR)$(MODULE_PREFIX)/bin
install_man:
mkdir -p $(DESTDIR)$(MODULE_PREFIX)/share/man/man1
cp -pf glxgears.1 glxinfo.1 $(DESTDIR)$(MODULE_PREFIX)/share/man/man1