98N/A# -*- Makefile -*- rules common to all X.Org drivers 1466N/A# Copyright (c) 2006, 2014, Oracle and/or its affiliates. All rights reserved. 98N/A# Permission is hereby granted, free of charge, to any person obtaining a 919N/A# copy of this software and associated documentation files (the "Software"), 919N/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# 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# 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. 493N/A### Include common definitions 967N/Ainclude $(TOP)/open-src/common/Makefile.init 957N/A# Determine from MODULE_NAME if this is a video or input driver 957N/ADRIVER_CLASS_V=$(MODULE_NAME:xf86-video-%=video) 957N/ADRIVER_CLASS=$(DRIVER_CLASS_V:xf86-input-%=input) 957N/ADRIVER_NAME=$(MODULE_NAME:xf86-$(DRIVER_CLASS)-%=%) 970N/A# Hierarchical parent for pkg names in this area 970N/AMODTYPE_PKGHIER=x11/server/xorg/driver 970N/A# Default pkg names for drivers - map xf86- to xorg- in names 970N/AMODULE_PKGTAIL_DEFAULT = $(MODULE_PKGTAIL_SET:yes=$(POUND_SIGN)) 970N/A$(MODULE_PKGTAIL_DEFAULT) MODULE_PKGTAIL=$(MODULE_NAME:xf86-%=xorg-%) 970N/A$(MODULE_PKGTAIL_DEFAULT) MODULE_PKGTAIL_SET=yes 970N/A# Package classification - must be a valid value recognized by pkg gui 970N/AMODULE_PKGCLASS_input = Drivers/Other Peripherals 970N/AMODULE_PKGCLASS_video = Drivers/Display 970N/AMODULE_PKGCLASS_DEFAULT = $(MODULE_PKGCLASS_SET:yes=$(POUND_SIGN)) 970N/A$(MODULE_PKGCLASS_DEFAULT) MODULE_PKGCLASS=$(MODULE_PKGCLASS_$(DRIVER_CLASS)) 970N/A$(MODULE_PKGCLASS_DEFAULT) MODULE_PKGCLASS_SET=yes 1356N/A# Default module description for packages in this area 1356N/AMODTYPE_DESC = the $(MODULE_NAME) driver 493N/A# Additional command line options to GNU autoconf configure script 591N/A# Set comments in ELF binaries to help identify versions/builds 591N/AMODTYPE_ADD_BUILD_TARGETS=set-elf-comments 1095N/AMODTYPE_CPPFLAGS= $(PROG_CPPFLAGS) \ 493N/AMODTYPE_CFLAGS=$(PROG_CFLAGS) 851N/A# Replaces @symbol_visibilty@ in xorg-server.pc, since that fails when 851N/A# some drivers are compiled with a different compiler than the server 851N/AMODTYPE_CFLAGS_suncc_common = -xldscope=hidden 1422N/AMODTYPE_CFLAGS_gcc_common = -fvisibility=hidden 851N/AMODTYPE_CFLAGS += $(MODTYPE_CFLAGS_$(MODULE_COMPILER)_common) 1425N/A# Many drivers fail to list -lc in their dependencies upstream, but not 1425N/A# all shared objects need it, so add it, but discard if not useful. 1425N/AMODTYPE_LD_SHARED_OPTIONS = $(ZDISCARD_UNUSED_DEP) -lc 1425N/A# Resolve calls to functions in Xorg against the Xorg binary 1318N/AXORG_EXTERNS_FLAG = -z parent=$(PROTODIR)$(X11_BIN_DIR)/Xorg 1425N/A# added to shared flags by default, but can be overridden if building 1425N/A# non-driver shared objects in a driver module 1425N/A$(XORG_EXTERNS_IN_LD_SHARED_OPTIONS:no=$(POUND_SIGN)) \ 1425N/A# Debug builds may leave references to pixman functions from inline function 1425N/A# calls in headers that normally get optimized out in non-debug builds. 1183N/A$(BUILD_DEBUG:yes=) MODTYPE_DEBUG_LD_OPTIONS = -lpixman-1 1183N/A$(BUILD_DEBUG:yes=$(POUND_SIGN)) MODTYPE_DEBUG_LD_OPTIONS = 1183N/AMODTYPE_LD_OPTIONS += $(MODTYPE_DEBUG_LD_OPTIONS) 493N/A# Need to fix libtool interference with our linker flags 1190N/A# Mark packages as only compatible with the current Xorg minor release series, 1190N/A# since Xorg tends to break ABI's in each minor release train (1.8, 1.9, etc.) 1190N/AMODTYPE_ATTRDATA_COMMANDS = @$(START_CMD_ECHO) ; \ 493N/A### Include common rules 967N/Ainclude $(TOP)/open-src/common/Makefile.inc