x11/cde-devel: Introduce x11/cde-devel

The x11/cde-devel port will track the CDE master development branch.
The cdesktopenv-code git repo on sourceforge is mirrored using my github
account and FreeBSD ports plumbing is used to fetch tarballs from github.

This port uses the x11/cde-25 port/pkg coexistence methodology to allow
it to be installed while a more stable version of x11/cde* is installed,
allowing users to safely use the port with a quick fallback should the
upstream software significanly break.

Users should ensure that their ~/.dt is backed up prior to switching
from a stable version of x11/cde* to x11/cde-devel or back again.
2022Q4
Cy Schubert 2022-08-05 19:40:40 -07:00
parent 529ea102c0
commit dc9eb66aca
14 changed files with 4422 additions and 0 deletions

View File

@ -31,6 +31,7 @@
SUBDIR += cde
SUBDIR += cde-24
SUBDIR += cde-25
SUBDIR += cde-devel
SUBDIR += cinnamon
SUBDIR += cinnamon-desktop
SUBDIR += cinnamon-menus

View File

@ -0,0 +1,127 @@
PORTNAME= cde
PORTVERSION= ${COMMIT_DATE}
CATEGORIES= x11
.if !defined(MASTERDIR)
PKGNAMESUFFIX= -devel
.endif
MAINTAINER= cy@FreeBSD.org
COMMENT= Common Desktop Environment
USE_GITHUB= yes
GH_ACCOUNT= cschuber
GH_PROJECT= cdesktopenv-code
GH_TAGNAME= 47cc5d4a7
COMMIT_DATE= 2022.07.31
LICENSE= LGPL21
BROKEN_mips64= fails to build: ./config/imake/imake: No such file or directory
BROKEN_powerpc64= fails to build: ./config/imake/imake: No such file or directory
BROKEN_i386= cannot bind to a temporary of type va_list
WRKSRC_SUBDIR= ${PORTNAME}
# For concurrent testing purposes only. Define DT_ID in make.conf to build
# a cde-25 pkg which will coexist with cde-24.
.if defined(CDE_CONCURRENT) && !defined(MASTERDIR)
DT_ID= ${PKGNAMESUFFIX}
.else
DT_ID=
.endif
PLIST_SUB= DT_ID=${DT_ID}
BUILD_DEPENDS= ksh93:shells/ksh93 \
bdftopcf:x11-fonts/bdftopcf \
mkfontscale>=0:x11-fonts/mkfontscale \
biconv:converters/iconv \
${LOCALBASE}/libdata/pkgconfig/fontconfig.pc:x11-fonts/fontconfig \
${LOCALBASE}/libdata/pkgconfig/freetype2.pc:print/freetype2 \
onsgmls:textproc/opensp \
xrdb:x11/xrdb
RUN_DEPENDS= ksh93:shells/ksh93 \
${LOCALBASE}/bin/fc-cache:x11-fonts/fontconfig \
${LOCALBASE}/libdata/pkgconfig/freetype2.pc:print/freetype2 \
xrdb:x11/xrdb \
xset:x11/xset
USES= autoreconf:build iconv:wchar_t gmake jpeg libtool motif perl5 \
shebangfix tcl:86 xorg
SHEBANG_LANG= pl
SHEBANG_FILES= programs/dtinfo/tools/bin/ccdate
DT_PREFIX= ${PREFIX}/dt${DT_ID}
USE_LDCONFIG= ${DT_PREFIX}/lib
USE_RC_SUBR= dtcms${DT_ID} dtlogin${DT_ID}
USE_XORG= ice sm x11 xau xdmcp xext xinerama xmu xscrnsaver xt
GNU_CONFIGURE= yes
GNU_CONFIGURE_PREFIX= ${DT_PREFIX}
MANPREFIX= ${DT_PREFIX}/share
INFODIR= ${DT_PREFIX}/share/info
CONFIGURE_ARGS= --with-tcl=${LOCALBASE}/lib/tcl8.6 MAKE="gmake"
MAKE_ARGS+= PERL=${PERL} "LOCAL_LDFLAGS=${LDFLAGS}"
MAKE_JOBS_UNSAFE=yes
MAKE_ENV= MALLOC_CONF=junk:false
SUB_FILES= pkg-message
LDFLAGS+= -z muldefs #--allow-multiple-definition
pre-configure:
@cd ${WRKSRC} && ./autogen.sh
post-patch:
@if [ -f /usr/include/iconv.h ]; then \
${REINPLACE_CMD} -e 's!^[[:space:]]*const char .ip = (const char .) .bp!char *ip = *bp!' \
${WRKSRC}/programs/dtmail/libDtMail/Common/Session.C \
${WRKSRC}/programs/dtmail/libDtMail/RFC/RFCBodyPart.C; \
fi
# From shells/ksh93
@${REINPLACE_CMD} -e 's|SF_FLAGS|SFIO_FLAGS|g' \
${WRKSRC}/programs/dtksh/ksh93/src/lib/libast/include/sfio*.h \
${WRKSRC}/programs/dtksh/ksh93/src/lib/libast/sfio/*.c \
${WRKSRC}/programs/dtksh/ksh93/src/lib/libast/sfio/*.h
# Needed for armv6
@${REINPLACE_CMD} -e 's|__va_copy|va_copy|g' \
${WRKSRC}/programs/dtksh/ksh93/src/lib/libast/hash/*.c \
${WRKSRC}/programs/dtksh/ksh93/src/lib/libast/sfio/*.c \
${WRKSRC}/programs/dtksh/ksh93/src/lib/libast/string/*.c
# Fix all hardcoded path
@${REINPLACE_CMD} -e 's|/usr/bin/perl|${LOCALBASE}/bin/perl|g' \
${WRKSRC}/programs/dtinfo/tools/bin/ccdate
@${FIND} ${WRKSRC} -type f ! -path doc/common | \
${XARGS} ${REINPLACE_CMD} -e \
's|/usr/dt|${DT_PREFIX}|g ; \
s|/etc/dt|${DT_PREFIX}/etc|g'
# we need to remove a few LOCALBASE
@${REINPLACE_CMD} -e 's|${LOCALBASE}/etc/dtsr|/etc/dtsr|g' -e \
's|${LOCALBASE}/etc/dtinfo_start|/etc/dtinfo_start|g' \
${WRKSRC}/programs/tttypes/dtinfo_start.ptype \
${WRKSRC}/programs/tttypes/dtinfo.ptype
# why redefine exit??
@${REINPLACE_CMD} -e '/void exit/d' \
${WRKSRC}/lib/tt/bin/tt_type_comp/frozen.mp_types_lex.C
# (time_t*) NULL is apparently too C-ish
@${REINPLACE_CMD} -e 's,(time_t) *NULL,nullptr,' \
${WRKSRC}/programs/dtmail/libDtMail/Common/FileShare.C \
${WRKSRC}/programs/dtmail/libDtMail/RFC/RFCMailBox.C
# chown is not supported as install as user
@${FIND} ${WRKSRC} -type f -name Makefile.am | ${XARGS} \
${REINPLACE_CMD} -e '/chown /d; /chgrp /d;'
post-install:
@${INSTALL_DATA} ${WRKSRC}/lib/pam/libpam/pam.conf \
${STAGEDIR}${PREFIX}/etc/pam.d/cde${DT_ID}.conf
@${ECHO_CMD} MANPATH /usr/local/dt/share/man > ${STAGEDIR}/${PREFIX}/etc/man.d/cde${DT_ID}.conf
@${FIND} ${STAGEDIR}/${DT_PREFIX} -type f -exec ${SH} -c '${STRIP_CMD} {} > /dev/null 2>&1' \;
@cd ${WRKSRC}/examples && @${FIND} . | ${CPIO} -pd ${STAGEDIR}/${DT_PREFIX}/share
@cd ${STAGEDIR}/${DT_PREFIX}; ${LN} -s share/examples
# Only a problem on armv7 so far
${FIND} ${STAGEDIR}/${DT_PREFIX} -type f -name 'ecp.*' -delete
.include <bsd.port.mk>

View File

@ -0,0 +1,3 @@
TIMESTAMP = 1659742825
SHA256 (cschuber-cdesktopenv-code-2022.07.31-47cc5d4a7_GH0.tar.gz) = 624b96117320ca91d199eec39dd751c71f8675edcdb05f3f4d7cb29be2855c68
SIZE (cschuber-cdesktopenv-code-2022.07.31-47cc5d4a7_GH0.tar.gz) = 57686131

View File

@ -0,0 +1,26 @@
#!/bin/sh
# PROVIDE: dtcms
# REQUIRE: rpcbind
# KEYWORD: shutdown
# Add the following line to /etc/rc.conf to enable dtcms:
#
# dtcms_enable=YES
. /etc/rc.subr
name=dtcms
rcvar=dtcms_enable
desc="CDE calendar manager service daemon"
load_rc_config $name
: ${dtcms_enable:=NO}
start_precmd="force_depend rpcbind || exit 1"
pidfile=/var/run/dtcms.pid
command=/usr/sbin/daemon
command_args="-P $pidfile %%PREFIX%%/dt-devel/bin/rpc.cmsd"
run_rc_command $1

View File

@ -0,0 +1,26 @@
#!/bin/sh
# PROVIDE: dtcms
# REQUIRE: rpcbind
# KEYWORD: shutdown
# Add the following line to /etc/rc.conf to enable dtcms:
#
# dtcms_enable=YES
. /etc/rc.subr
name=dtcms
rcvar=dtcms_enable
desc="CDE calendar manager service daemon"
load_rc_config $name
: ${dtcms_enable:=NO}
start_precmd="force_depend rpcbind || exit 1"
pidfile=/var/run/dtcms.pid
command=/usr/sbin/daemon
command_args="-P $pidfile %%PREFIX%%/dt/bin/rpc.cmsd"
run_rc_command $1

View File

@ -0,0 +1,34 @@
#!/bin/sh
# PROVIDE: dtlogin
# REQUIRE: LOGIN dbus dtspc
# KEYWORD: shutdown
#
# Add the following line to /etc/rc.conf to enable dtlogin:
# dtlogin_enable="YES"
#
. /etc/rc.subr
name=dtlogin
rcvar=dtlogin_enable
desc="Display manager for CDE"
load_rc_config dtlogin
: ${dtlogin_enable:=NO}
command=%%PREFIX%%/dt-devel/bin/dtlogin
command_args=-daemon
start_precmd=dtlogin_prestart
dtlogin_prestart()
{
if ! [ -f "%%PREFIX%%/etc/X11/Xwrapper.config" ]; then
echo "If dtlogin fails to start:"
echo "# echo allowed_users=anybody >> %%PREFIX%%/etc/X11/Xwrapper.config"
fi
}
run_rc_command $1

View File

@ -0,0 +1,34 @@
#!/bin/sh
# PROVIDE: dtlogin
# REQUIRE: LOGIN dbus dtspc
# KEYWORD: shutdown
#
# Add the following line to /etc/rc.conf to enable dtlogin:
# dtlogin_enable="YES"
#
. /etc/rc.subr
name=dtlogin
rcvar=dtlogin_enable
desc="Display manager for CDE"
load_rc_config dtlogin
: ${dtlogin_enable:=NO}
command=%%PREFIX%%/dt/bin/dtlogin
command_args=-daemon
start_precmd=dtlogin_prestart
dtlogin_prestart()
{
if ! [ -f "%%PREFIX%%/etc/X11/Xwrapper.config" ]; then
echo "If dtlogin fails to start:"
echo "# echo allowed_users=anybody >> %%PREFIX%%/etc/X11/Xwrapper.config"
fi
}
run_rc_command $1

View File

@ -0,0 +1,24 @@
--- configure.ac.orig 2021-11-30 19:54:11.356382000 -0800
+++ configure.ac 2021-11-30 20:19:10.923347000 -0800
@@ -305,9 +305,6 @@
AC_PATH_XTRA
dnl check some compiler flags
-C_FLAG_CHECK([-Wno-format-truncation])
-CXX_FLAG_CHECK([-Wno-format-truncation])
-
C_FLAG_CHECK([-fno-strict-aliasing])
CXX_FLAG_CHECK([-fno-strict-aliasing])
@@ -327,9 +324,9 @@
dnl programs with full paths
dnl - KSH, some systems call it as ksh93
-AC_PATH_PROG(KSH, ksh)
+AC_PATH_PROG(KSH, ksh93)
if test -z "$ac_cv_path_KSH"; then
- AC_PATH_PROG(KSH, ksh93)
+ AC_PATH_PROG(KSH, ksh)
if test -z "$ac_cv_path_KSH"; then
MISSING_PROGS="[ksh or ksh93] ${MISSING_PROGS}"
fi

View File

@ -0,0 +1,19 @@
--- lib/DtMmdb/StyleSheet/Makefile.am.orig 2022-02-15 09:36:38.828203000 -0800
+++ lib/DtMmdb/StyleSheet/Makefile.am 2022-02-15 10:20:50.149152000 -0800
@@ -41,14 +41,14 @@
tokenStyle.C
defParser.C: defParser.yy
- $(YACC) $(AM_YFLAGS) -p defParser -b defParser $<
+ $(YACC) $(AM_YFLAGS) -o defParser.tab.c -p defParser -b defParser $<
mv defParser.tab.c $@
defToken.C: defToken.ll
$(LEX) $(AM_LFLAGS) -P defParser -o $@ $<
style.C: style.yy
- $(YACC) $(AM_YFLAGS) -p style -b style $<
+ $(YACC) $(AM_YFLAGS) -o style.tab.c -p style -b style $<
mv style.tab.c style.C
tokenStyle.C: tokenStyle.ll

View File

@ -0,0 +1,11 @@
--- programs/dtcm/dtcm/calendarA.c.orig 2021-07-03 12:35:15.000000000 -0700
+++ programs/dtcm/dtcm/calendarA.c 2021-07-12 13:58:22.306477000 -0700
@@ -2047,7 +2047,7 @@
set_message(c->message_text, buf);
sprintf(buf, "%s\n%s: %s, %s: %s", CATGETS(c->DT_catd, 1, 91,
- "rpc.cmsd is not responding for your user name.\nMake sure the inetd process is running and the entry\nin inetd.conf for rpc.cmsd is correct for your host."),
+ "rpc.cmsd is not responding for your user name.\nMake sure the inetd process is running and the entry\nin /etc/rc.conf for rpc.cmsd is correct for your host."),
nl_user, name,
nl_host, host);

View File

@ -0,0 +1,7 @@
--- programs/dtterm/Makefile.am.orig 2021-11-25 16:40:19.896057000 -0800
+++ programs/dtterm/Makefile.am 2021-11-25 17:19:24.691922000 -0800
@@ -51,4 +51,3 @@
if !HAS_UTEMPTER_LIBRARY
chmod 4755 $(DESTDIR)$(bindir)/dtterm
endif
- @TIC@ dtterm.ti

View File

@ -0,0 +1,36 @@
[
{ type: install
message: <<EOM
This is ancient software that is ported for curiosity purposes. It is
unlikely to be useful in everyday use, and should not be used in untrusted
environments as there are highly likely to be unresolved security issues.
It is also necessary to enable the Subprocess Control Service (and dtcms for
the calendar to work).
# sysrc rpcbind_enable=yes
# sysrc dtcms_enable=yes
# sysrc inetd_enable=yes
# service rpcbind start && service dtcms start
and
Add the following line to /etc/inetd.conf:
dtspc stream tcp nowait root %%PREFIX%%/dt/bin/dtspcd %%PREFIX%%/dt/bin/dtspcd
and to /etc/services:
dtspc 6112/tcp # CDE Subprocess Control Service
To start the Common Desktop Environment,
% ln -s %%PREFIX%%/dt/bin/Xsession ~/.Xsession
% env LANG=C startx
If you want to use dtlogin as well, you'll need to create
%%LOCALBASE%%/etc/X11/Xwrapper.config and add this line:
allowed_users=anybody
EOM
}
]

View File

@ -0,0 +1,6 @@
CDE - The Common Desktop Environment is X Windows desktop environment
that was commonly used on commercial UNIX variants such as Sun Solaris,
HP-UX and IBM AIX. Developed between 1993 and 1999, it has now been
released under an Open Source licence by The Open Group.
WWW: https://sourceforge.net/p/cdesktopenv/wiki/Home/

File diff suppressed because it is too large Load Diff