2007-12-04 15:20:01 -07:00
|
|
|
/* imake template for radeonhd driver -*- makefile -*- */
|
|
|
|
|
2008-04-19 07:41:45 -06:00
|
|
|
/* Copyright (c) 2007 Hans Ulrich Niedermann <hun@n-dimensional.de>
|
|
|
|
*
|
|
|
|
* This Makefile fragment is free software; the author(s) give(s)
|
|
|
|
* unlimited permission to copy, distribute and modify it.
|
|
|
|
*/
|
|
|
|
|
2007-12-04 15:20:01 -07:00
|
|
|
VER_GREP = grep -A 4 AC_INIT $(TOP)/configure.ac
|
|
|
|
VER_SED = sed -n '2s/[^0-9]*\([0-9][^,]*\).*/\1/p'
|
|
|
|
VER_CUT = cut -d . -f
|
|
|
|
PACKAGE_VERSION = `$(VER_GREP) | $(VER_SED)`
|
|
|
|
PACKAGE_VERSION_MAJOR = `$(VER_GREP) | $(VER_SED) | $(VER_CUT) 1`
|
|
|
|
PACKAGE_VERSION_MINOR = `$(VER_GREP) | $(VER_SED) | $(VER_CUT) 2`
|
|
|
|
PACKAGE_VERSION_PATCHLEVEL = `$(VER_GREP) | $(VER_SED) | $(VER_CUT) 3`
|
|
|
|
|
|
|
|
PACKAGE_NAME = xf86-video-radeonhd
|
|
|
|
|
|
|
|
RHD_VERSION_DEFINES = \
|
|
|
|
-DPACKAGE_VERSION="\"$(PACKAGE_VERSION)\"" \
|
|
|
|
-DPACKAGE_VERSION_MAJOR="$(PACKAGE_VERSION_MAJOR)" \
|
|
|
|
-DPACKAGE_VERSION_MINOR="$(PACKAGE_VERSION_MINOR)" \
|
|
|
|
-DPACKAGE_VERSION_PATCHLEVEL="$(PACKAGE_VERSION_PATCHLEVEL)"
|
|
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
* The only way to make sure the git version check is run and git_version.h is
|
|
|
|
* updated before a compile. Creating a normal make rule cannot do that.
|
|
|
|
*/
|
|
|
|
GIT_VERSION_CMD = $(SHELL) $(TOP)/git_version.sh
|
|
|
|
RHD_GIT_DEFINES = \
|
|
|
|
`$(GIT_VERSION_CMD) -q -k -s $(TOP) -o git_version.h`
|
|
|
|
|
|
|
|
clean::
|
|
|
|
RemoveFile(git_version.h)
|
2008-01-05 10:28:11 -07:00
|
|
|
RemoveFile(git_version.h.new)
|
2007-12-04 15:20:01 -07:00
|
|
|
|
|
|
|
/* vim: syntax=make
|
|
|
|
*/
|