Makefile revision 1422
199767f8919635c4928607450d9e0abb932109ceToomas Soome###############################################################################
199767f8919635c4928607450d9e0abb932109ceToomas Soome#
199767f8919635c4928607450d9e0abb932109ceToomas Soome# efb driver for Sun XVR-100 & XVR-300 boards (based on ATI Radeon)
199767f8919635c4928607450d9e0abb932109ceToomas Soome#
199767f8919635c4928607450d9e0abb932109ceToomas Soome# Copyright (c) 2011, 2014, Oracle and/or its affiliates. All rights reserved.
199767f8919635c4928607450d9e0abb932109ceToomas Soome#
199767f8919635c4928607450d9e0abb932109ceToomas Soome# Permission is hereby granted, free of charge, to any person obtaining a
199767f8919635c4928607450d9e0abb932109ceToomas Soome# copy of this software and associated documentation files (the "Software"),
199767f8919635c4928607450d9e0abb932109ceToomas Soome# to deal in the Software without restriction, including without limitation
199767f8919635c4928607450d9e0abb932109ceToomas Soome# the rights to use, copy, modify, merge, publish, distribute, sublicense,
199767f8919635c4928607450d9e0abb932109ceToomas Soome# and/or sell copies of the Software, and to permit persons to whom the
199767f8919635c4928607450d9e0abb932109ceToomas Soome# Software is furnished to do so, subject to the following conditions:
199767f8919635c4928607450d9e0abb932109ceToomas Soome#
199767f8919635c4928607450d9e0abb932109ceToomas Soome# The above copyright notice and this permission notice (including the next
199767f8919635c4928607450d9e0abb932109ceToomas Soome# paragraph) shall be included in all copies or substantial portions of the
199767f8919635c4928607450d9e0abb932109ceToomas Soome# Software.
199767f8919635c4928607450d9e0abb932109ceToomas Soome#
199767f8919635c4928607450d9e0abb932109ceToomas Soome# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
199767f8919635c4928607450d9e0abb932109ceToomas Soome# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
199767f8919635c4928607450d9e0abb932109ceToomas Soome# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
199767f8919635c4928607450d9e0abb932109ceToomas Soome# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
199767f8919635c4928607450d9e0abb932109ceToomas Soome# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
199767f8919635c4928607450d9e0abb932109ceToomas Soome# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
199767f8919635c4928607450d9e0abb932109ceToomas Soome# DEALINGS IN THE SOFTWARE.
199767f8919635c4928607450d9e0abb932109ceToomas Soome#
199767f8919635c4928607450d9e0abb932109ceToomas Soome#
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome# Package name used in tarballs
199767f8919635c4928607450d9e0abb932109ceToomas SoomeMODULE_NAME=xf86-video-ati
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome# Version number (used in path names)
199767f8919635c4928607450d9e0abb932109ceToomas SoomeMODULE_VERSION=6.8.0
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome# Dates to show in Oracle copyright notice in pkg license file
199767f8919635c4928607450d9e0abb932109ceToomas Soome# Earliest & latest of the copyrights in the Oracle files in this pkg
199767f8919635c4928607450d9e0abb932109ceToomas SoomeORACLE_COPYRIGHT_YEARS = 2008, 2009
199767f8919635c4928607450d9e0abb932109ceToomas SoomeMODULE_LICENSE_DESC = portions of the ATI Radeon graphics driver from X.Org
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome# Checksums for upstream tarball
199767f8919635c4928607450d9e0abb932109ceToomas SoomeTARBALL_MD5 = 3c97c7925ebf4162eeb3463e23adc0e3
199767f8919635c4928607450d9e0abb932109ceToomas SoomeTARBALL_SHA1 = b6974237b6ae9b45b32fc37f31a3fee7358230d3
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome# Patches to apply to source after unpacking, in order
199767f8919635c4928607450d9e0abb932109ceToomas SoomeSOURCE_PATCHES = \
199767f8919635c4928607450d9e0abb932109ceToomas Soome RAC-API-removal.patch,-p1 \
199767f8919635c4928607450d9e0abb932109ceToomas Soome no-modes.patch,-p1 \
199767f8919635c4928607450d9e0abb932109ceToomas Soome sparc-efb.patch,-p1 \
199767f8919635c4928607450d9e0abb932109ceToomas Soome pciTag.patch \
199767f8919635c4928607450d9e0abb932109ceToomas Soome disable-xaa.patch \
199767f8919635c4928607450d9e0abb932109ceToomas Soome 15918273.patch
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome# Need to regenerate configure after patching Makefile.am in sparc-efb.patch
199767f8919635c4928607450d9e0abb932109ceToomas SoomeAUTORECONF=yes
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome# pkg(5) name we deliver the files in (override default)
199767f8919635c4928607450d9e0abb932109ceToomas SoomeMODULE_PKGTAIL=xorg-video-efb
199767f8919635c4928607450d9e0abb932109ceToomas SoomeMODULE_PKGTAIL_SET=yes
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome# Man pages to apply Sun footer to & attributes to list
199767f8919635c4928607450d9e0abb932109ceToomas SoomeSUNTOUCHED_MANPAGES=man/*.man
199767f8919635c4928607450d9e0abb932109ceToomas SoomeMODULE_STABILITY=Volatile
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome# Use -KPIC instead of -Kpic because we have too many symbols on SPARC
199767f8919635c4928607450d9e0abb932109ceToomas SoomeDELIBTOOLIZE_FLAGS = -P
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome# Extra flags to pass to configure script
199767f8919635c4928607450d9e0abb932109ceToomas SoomeMODULE_CONFIG_OPTS=--disable-dri
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome# Merge in additional sources from sun-src directory
199767f8919635c4928607450d9e0abb932109ceToomas SoomeADDITIONAL_SOURCE_DIR=sun-src
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome# Extra rules to run when unpacking upstream source
199767f8919635c4928607450d9e0abb932109ceToomas SoomeCLEAN_LINEFEED_TARGET = $(SOURCE_DIR)/.source.clean.done
199767f8919635c4928607450d9e0abb932109ceToomas SoomeMODULE_ADD_SOURCE_TARGETS = $(CLEAN_LINEFEED_TARGET)
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas SoomeXF86_VIDEO_ATI_SRC = $(PWD:efb=xf86-video-ati)
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome# Libraries/modules to link with
199767f8919635c4928607450d9e0abb932109ceToomas SoomeMODULE_LD_OPTIONS= \
199767f8919635c4928607450d9e0abb932109ceToomas Soome -L$(PROTODIR)$(X11_SERVERMODS_DIR) \
199767f8919635c4928607450d9e0abb932109ceToomas Soome -L$(PROTODIR)$(X11_SERVERMODS_DIR)/extensions \
199767f8919635c4928607450d9e0abb932109ceToomas Soome -L$(PROTODIR)$(X11_SERVERLIBS_DIR)$(ARCHLIBSUBDIR) \
199767f8919635c4928607450d9e0abb932109ceToomas Soome -L$(PROTODIR)/usr/lib$(ARCHLIBSUBDIR) \
199767f8919635c4928607450d9e0abb932109ceToomas Soome -R$(X11_SERVERMODS_DIR) \
199767f8919635c4928607450d9e0abb932109ceToomas Soome -R$(X11_SERVERMODS_DIR)/extensions \
199767f8919635c4928607450d9e0abb932109ceToomas Soome -R$(X11_SERVERLIBS_DIR)$(ARCHLIBSUBDIR) \
199767f8919635c4928607450d9e0abb932109ceToomas Soome -R$(PROTODIR)/usr/lib$(ARCHLIBSUBDIR) \
199767f8919635c4928607450d9e0abb932109ceToomas Soome -lexa -lfb -lint10 -lvbe -lvgahw -lshadow \
199767f8919635c4928607450d9e0abb932109ceToomas Soome -lpciaccess -lpixman-1 -ldrm -lglx -lm \
199767f8919635c4928607450d9e0abb932109ceToomas Soome -M $(XF86_VIDEO_ATI_SRC)/mapfile-bt829_drv-external \
199767f8919635c4928607450d9e0abb932109ceToomas Soome -M $(XF86_VIDEO_ATI_SRC)/mapfile-fi1236_drv-external \
199767f8919635c4928607450d9e0abb932109ceToomas Soome -M $(XF86_VIDEO_ATI_SRC)/mapfile-msp3430_drv-external \
199767f8919635c4928607450d9e0abb932109ceToomas Soome -M $(XF86_VIDEO_ATI_SRC)/mapfile-tda9885_drv-external \
199767f8919635c4928607450d9e0abb932109ceToomas Soome -M $(XF86_VIDEO_ATI_SRC)/mapfile-uda1380_drv-external \
199767f8919635c4928607450d9e0abb932109ceToomas Soome -M ../../$(SOURCE_DIR)/src/drv.mapfile
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soomeinclude ../Makefile.inc
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome# ATI's atombios code has ^M's at linefeeds which break Sun compilers
199767f8919635c4928607450d9e0abb932109ceToomas Soomeclean_linefeeds: $(CLEAN_LINEFEED_TARGET)
199767f8919635c4928607450d9e0abb932109ceToomas Soome$(SOURCE_ADD_TARGET): $(CLEAN_LINEFEED_TARGET)
199767f8919635c4928607450d9e0abb932109ceToomas Soome$(PATCHED_TARGET): $(CLEAN_LINEFEED_TARGET)
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome$(CLEAN_LINEFEED_TARGET): $(SOURCE_INIT_TARGET)
199767f8919635c4928607450d9e0abb932109ceToomas Soome find $(SOURCE_DIR) -type f -name '*.[ch]' | \
199767f8919635c4928607450d9e0abb932109ceToomas Soome xargs $(PERL) -i -p -e 's{\r\n}{\n}g'
199767f8919635c4928607450d9e0abb932109ceToomas Soome touch $(CLEAN_LINEFEED_TARGET)
199767f8919635c4928607450d9e0abb932109ceToomas Soome