2018-07-14 08:16:55 +00:00
|
|
|
# Created by: Johannes Dieterich <jmd@FreeBSD.org>
|
|
|
|
|
2018-12-10 03:02:11 +00:00
|
|
|
PORTNAME= drm-current-kmod
|
2021-09-09 11:06:30 +00:00
|
|
|
PORTVERSION= 5.4.144.g20210908
|
2018-07-14 08:16:55 +00:00
|
|
|
CATEGORIES= graphics kld
|
|
|
|
|
2019-07-09 20:20:28 +00:00
|
|
|
MAINTAINER= x11@FreeBSD.org
|
2019-01-30 07:58:00 +00:00
|
|
|
COMMENT= DRM modules for the linuxkpi-based KMS components
|
2018-07-14 08:16:55 +00:00
|
|
|
|
|
|
|
LICENSE= BSD2CLAUSE MIT GPLv2
|
|
|
|
LICENSE_COMB= multi
|
|
|
|
|
2020-09-24 21:25:31 +00:00
|
|
|
ONLY_FOR_ARCHS= aarch64 amd64 i386 powerpc64 powerpc64le
|
2020-09-10 15:36:13 +00:00
|
|
|
ONLY_FOR_ARCHS_REASON= the new KMS components are only supported on amd64, i386, aarch64 and powerpc64
|
2018-07-14 08:16:55 +00:00
|
|
|
|
2020-09-14 09:46:36 +00:00
|
|
|
RUN_DEPENDS= gpu-firmware-kmod>=g20200914:graphics/gpu-firmware-kmod
|
2018-07-14 08:16:55 +00:00
|
|
|
|
2021-01-28 16:56:52 +00:00
|
|
|
CONFLICTS_INSTALL= drm-devel-kmod
|
2018-07-14 08:16:55 +00:00
|
|
|
|
2019-08-13 21:51:22 +00:00
|
|
|
OPTIONS_DEFINE= DEBUG SOURCE
|
|
|
|
|
|
|
|
SOURCE_DESC= Install kernel module sources
|
|
|
|
|
|
|
|
OPTIONS_SUB= yes
|
2018-07-14 08:16:55 +00:00
|
|
|
|
2018-11-20 02:20:31 +00:00
|
|
|
USES= kmod uidfix compiler:c++11-lang
|
2018-07-14 08:16:55 +00:00
|
|
|
|
|
|
|
USE_GITHUB= yes
|
2020-09-10 15:36:13 +00:00
|
|
|
GH_ACCOUNT= freebsd
|
|
|
|
GH_PROJECT= drm-kmod
|
2021-09-09 11:06:30 +00:00
|
|
|
GH_TAGNAME= drm_v5.4.144
|
2018-07-14 08:16:55 +00:00
|
|
|
|
|
|
|
.include <bsd.port.options.mk>
|
|
|
|
|
2021-01-28 22:20:02 +00:00
|
|
|
.if ${OPSYS} == FreeBSD && ${OSVERSION} < 1400000
|
|
|
|
IGNORE= not supported on older CURRENT, no kernel support
|
|
|
|
.endif
|
2018-07-14 08:16:55 +00:00
|
|
|
.if ${OPSYS} != FreeBSD
|
|
|
|
IGNORE= not supported on anything but FreeBSD (missing linuxkpi functionality)
|
|
|
|
.endif
|
|
|
|
|
2018-11-13 03:27:51 +00:00
|
|
|
.if ${ARCH} == "amd64"
|
2018-11-21 13:50:55 +00:00
|
|
|
PLIST_SUB+= AMDGPU=""
|
2018-11-20 02:20:31 +00:00
|
|
|
PLIST_SUB+= I915=""
|
|
|
|
.elif ${ARCH} == "i386"
|
2018-11-21 13:50:55 +00:00
|
|
|
PLIST_SUB+= AMDGPU="@comment "
|
2018-11-20 02:20:31 +00:00
|
|
|
PLIST_SUB+= I915=""
|
2020-09-24 21:25:31 +00:00
|
|
|
.elif ${ARCH} == "aarch64" || ${ARCH:Mpowerpc*}
|
2018-11-21 13:50:55 +00:00
|
|
|
PLIST_SUB+= AMDGPU=""
|
2018-11-20 02:20:31 +00:00
|
|
|
PLIST_SUB+= I915="@comment "
|
2018-11-13 03:27:51 +00:00
|
|
|
.else
|
2018-11-21 13:50:55 +00:00
|
|
|
PLIST_SUB+= AMDGPU="@comment "
|
2018-11-20 02:20:31 +00:00
|
|
|
PLIST_SUB+= I915="@comment "
|
2018-11-13 03:27:51 +00:00
|
|
|
.endif
|
|
|
|
|
2019-08-13 21:51:22 +00:00
|
|
|
KMODSRC= ${STAGEDIR}${PREFIX}/sys/modules/${PORTNAME}
|
2020-09-10 15:36:13 +00:00
|
|
|
SRCDIRS= amd drivers drm i915 include linuxkpi radeon ttm vmwgfx vboxvideo
|
2019-08-13 21:51:22 +00:00
|
|
|
|
|
|
|
PLIST_SUB+= KMODSRC="sys/modules/${PORTNAME}"
|
|
|
|
|
|
|
|
MAKE_ENV+= MAKEOBJDIRPREFIX=${WRKSRC}/obj
|
|
|
|
|
|
|
|
pre-build:
|
|
|
|
${MKDIR} ${WRKSRC}/obj
|
|
|
|
(cd ${WRKSRC} ; ${SETENV} ${MAKE_ENV} ${MAKE_CMD} obj)
|
|
|
|
|
|
|
|
post-install-SOURCE-on:
|
|
|
|
${MKDIR} ${KMODSRC}
|
|
|
|
${INSTALL_DATA} ${WRKSRC}/Makefile ${KMODSRC}
|
2020-09-10 16:09:32 +00:00
|
|
|
${INSTALL_DATA} ${WRKSRC}/kconfig.mk ${KMODSRC}
|
2019-08-13 21:51:22 +00:00
|
|
|
.for dir in ${SRCDIRS}
|
|
|
|
cd ${WRKSRC} && ${COPYTREE_SHARE} ${dir} ${KMODSRC}
|
|
|
|
.endfor
|
|
|
|
|
2018-07-14 08:16:55 +00:00
|
|
|
.include <bsd.port.mk>
|