- Add patch to use setusercontext(3) to setup user environment, so it respects login.conf among other things [1] - Use autoreconf, since patch requires regenerating configure script to check for setusercontext(3) [2] - Explicitly disable libaudit support, not supported in FreeBSD [3] - Add QT5 options, disabled by default, to control linking against qt5 [4] - Import patch adding option to enable alternative location for .xsession-errors file [5] - Correctly define runtime dependencies - Forcibly disable installation of apparmor files - Install PAM configuration files as samples, so in the future they are not overwritten if customized - Pet portclippy/portfmt - Regenerate patches Upstreaming: [1] https://github.com/canonical/lightdm/pull/334 [5] https://github.com/canonical/lightdm/pull/335 Many thanks to all people involved! PR: 266532 [1] [2], 273720 [1], 275885 [3] [4] [5] Tested by: Ivan Rozhuk <rozhuk.im@gmail.com>, Daniel Tameling <tamelingdaniel@gmail.com> (provided setusercontext patch), Anton Saietskii <vsasjason@gmail.com>
90 lines
2.9 KiB
Makefile
90 lines
2.9 KiB
Makefile
PORTNAME= lightdm
|
|
PORTVERSION= 1.32.0
|
|
PORTREVISION= 2
|
|
CATEGORIES= x11
|
|
MASTER_SITES= https://github.com/canonical/${PORTNAME}/releases/download/${DISTVERSIONPREFIX}${DISTVERSION}/
|
|
|
|
MAINTAINER= desktop@FreeBSD.org
|
|
COMMENT= Lightweight Display Manager
|
|
WWW= https://github.com/canonical/lightdm
|
|
|
|
# library/bindings are LGPLv2 or LGPLv3, the rest GPLv3+
|
|
LICENSE= GPLv3 LGPL20 LGPL3
|
|
LICENSE_COMB= multi
|
|
LICENSE_FILE_GPLv3= ${WRKSRC}/COPYING.GPL3
|
|
LICENSE_FILE_LGPL20= ${WRKSRC}/COPYING.LGPL2
|
|
LICENSE_FILE_LGPL3= ${WRKSRC}/COPYING.LGPL3
|
|
|
|
BUILD_DEPENDS= itstool:textproc/itstool
|
|
LIB_DEPENDS= libgcrypt.so:security/libgcrypt \
|
|
libxklavier.so:x11/libxklavier
|
|
RUN_DEPENDS= accountsservice>=0:sysutils/accountsservice \
|
|
ck-launch-session:sysutils/consolekit2
|
|
|
|
USES= autoreconf compiler:c++11-lang cpe gettext gmake gnome \
|
|
libtool localbase pathfix pkgconfig tar:xz xorg
|
|
CPE_VENDOR= ${PORTNAME}_project
|
|
USE_CXXSTD= c++11
|
|
USE_GNOME= glib20 intltool
|
|
USE_LDCONFIG= yes
|
|
USE_RC_SUBR= lightdm
|
|
USE_XORG= x11 xcb xdmcp
|
|
|
|
GNU_CONFIGURE= yes
|
|
# tests causes PAM errors
|
|
CONFIGURE_ARGS= --disable-libaudit \
|
|
--disable-tests
|
|
INSTALL_TARGET= install-strip
|
|
LIBS= -lutil
|
|
CONFLICTS_INSTALL= sddm
|
|
PORTSCOUT= limitw:1,even
|
|
SUB_FILES= Xsession
|
|
USERS= lightdm
|
|
GROUPS= lightdm video
|
|
|
|
OPTIONS_DEFINE= DOCS QT5 VAPI
|
|
OPTIONS_DEFAULT= VAPI
|
|
OPTIONS_SUB= yes
|
|
|
|
DOCS_BUILD_DEPENDS= ${LOCALBASE}/share/aclocal/yelp.m4:textproc/yelp-tools \
|
|
gtkdoc-check:textproc/gtk-doc
|
|
DOCS_CONFIGURE_ON= --enable-gtk-doc
|
|
|
|
QT5_USES= qt:5
|
|
QT5_USE= QT=buildtools,core,dbus,gui
|
|
QT5_CONFIGURE_ENABLE= liblightdm-qt5
|
|
|
|
VAPI_USES= vala:build
|
|
VAPI_USE= GNOME=introspection:build
|
|
VAPI_CONFIGURE_ENABLE= vala
|
|
|
|
post-patch:
|
|
@${REINPLACE_CMD} -e 's,%%PREFIX%%,${PREFIX},' \
|
|
${WRKSRC}/data/lightdm.conf
|
|
|
|
post-patch-DOCS-off:
|
|
@${REINPLACE_CMD} -e '/^GTK_DOC_CHECK/d' \
|
|
-e '/^YELP_HELP_INIT/d' \
|
|
-e '/^doc\/Makefile/d' \
|
|
-e '/^help\/Makefile/d' \
|
|
${WRKSRC}/configure.ac
|
|
@${REINPLACE_CMD} -e '/^SUBDIRS/s/ doc help//' \
|
|
${WRKSRC}/Makefile.am
|
|
|
|
post-install:
|
|
${RM} -r ${STAGEDIR}${PREFIX}/etc/init
|
|
${INSTALL_SCRIPT} ${WRKDIR}/Xsession ${STAGEDIR}${ETCDIR}
|
|
${MV} ${STAGEDIR}${ETCDIR}/keys.conf ${STAGEDIR}${ETCDIR}/keys.conf.sample
|
|
${MV} ${STAGEDIR}${ETCDIR}/lightdm.conf ${STAGEDIR}${ETCDIR}/lightdm.conf.sample
|
|
${MV} ${STAGEDIR}${ETCDIR}/users.conf ${STAGEDIR}${ETCDIR}/users.conf.sample
|
|
${MV} ${STAGEDIR}${PREFIX}/etc/pam.d/lightdm ${STAGEDIR}${PREFIX}/etc/pam.d/lightdm.sample
|
|
${MV} ${STAGEDIR}${PREFIX}/etc/pam.d/lightdm-autologin ${STAGEDIR}${PREFIX}/etc/pam.d/lightdm-autologin.sample
|
|
${MV} ${STAGEDIR}${PREFIX}/etc/pam.d/lightdm-greeter ${STAGEDIR}${PREFIX}/etc/pam.d/lightdm-greeter.sample
|
|
${MKDIR} ${STAGEDIR}/var/cache/lightdm \
|
|
${STAGEDIR}/var/log/lightdm \
|
|
${STAGEDIR}/var/run/lightdm
|
|
${MKDIR} ${STAGEDIR}${PREFIX}/share/xgreeters
|
|
@(cd ${STAGEDIR}${PREFIX}/share/xgreeters && \
|
|
${LN} -sf lightdm-gtk-greeter.desktop default.desktop)
|
|
|
|
.include <bsd.port.mk>
|