10 |
10 |
|
11 |
11 |
if [[ ${PV} != 9999 ]] ; then
|
12 |
12 |
SRC_URI="mirror://gnu/${PN}/${P}.tar.gz"
|
13 |
|
KEYWORDS="~alpha amd64 arm arm64 hppa ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris"
|
|
13 |
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris"
|
14 |
14 |
else
|
15 |
15 |
inherit git-r3
|
16 |
16 |
EGIT_REPO_URI="https://git.savannah.gnu.org/git/screen.git"
|
... | ... | |
20 |
20 |
|
21 |
21 |
LICENSE="GPL-3+"
|
22 |
22 |
SLOT="0"
|
23 |
|
IUSE="debug nethack pam selinux multiuser"
|
|
23 |
IUSE="debug nethack pam selinux utempter multiuser"
|
|
24 |
# bug #956963
|
|
25 |
RESTRICT="test"
|
24 |
26 |
|
25 |
27 |
DEPEND=">=sys-libs/ncurses-5.2:=
|
26 |
28 |
virtual/libcrypt:=
|
27 |
29 |
pam? ( sys-libs/pam )"
|
28 |
30 |
RDEPEND="${DEPEND}
|
29 |
31 |
acct-group/utmp
|
30 |
|
selinux? ( sec-policy/selinux-screen )"
|
|
32 |
selinux? ( sec-policy/selinux-screen )
|
|
33 |
utempter? ( sys-libs/libutempter:= )"
|
31 |
34 |
BDEPEND="sys-apps/texinfo"
|
32 |
35 |
|
33 |
36 |
PATCHES=(
|
34 |
|
# Don't use utempter even if it is found on the system.
|
35 |
|
"${FILESDIR}"/${PN}-4.3.0-no-utempter.patch
|
36 |
|
"${FILESDIR}"/${PN}-4.9.1-utmp-exit.patch
|
37 |
|
"${FILESDIR}"/${PN}-4.9.1-add-missing-pty.h-header.patch
|
|
37 |
"${FILESDIR}"/${PN}-5.0.0-utmp-musl.patch
|
|
38 |
"${FILESDIR}"/${PN}-5.0.1-texi.patch
|
38 |
39 |
)
|
39 |
40 |
|
40 |
41 |
src_prepare() {
|
... | ... | |
42 |
43 |
|
43 |
44 |
# sched.h is a system header and causes problems with some C libraries
|
44 |
45 |
mv sched.h _sched.h || die
|
45 |
|
sed -i '/include/ s:sched.h:_sched.h:' screen.h || die
|
|
46 |
sed -i '/include/ s:sched.h:_sched.h:' canvas.h sched.c screen.h window.h winmsg.c || die
|
|
47 |
sed -i 's:sched.h:_sched.h:' Makefile.in || die
|
46 |
48 |
|
47 |
49 |
# Fix manpage
|
48 |
50 |
sed -i \
|
... | ... | |
53 |
55 |
-e "s:/local/screens/S\\\-:${EPREFIX}/tmp/screen/S\\\-:g" \
|
54 |
56 |
doc/screen.1 || die
|
55 |
57 |
|
56 |
|
if [[ ${CHOST} == *-darwin* ]] || use elibc_musl; then
|
57 |
|
sed -i -e '/^#define UTMPOK/s/define/undef/' acconfig.h || die
|
58 |
|
fi
|
59 |
|
|
60 |
|
# disable musl dummy headers for utmp[x]
|
61 |
|
use elibc_musl && append-cppflags "-D_UTMP_H -D_UTMPX_H"
|
62 |
|
|
63 |
58 |
# reconfigure
|
64 |
59 |
eautoreconf
|
65 |
60 |
}
|
66 |
61 |
|
67 |
62 |
src_configure() {
|
68 |
|
# bug #944429 (revisit this on >= 5.0.0)
|
69 |
|
append-cflags -std=gnu17
|
70 |
63 |
append-lfs-flags
|
71 |
64 |
append-cppflags "-DMAXWIN=${MAX_SCREEN_WINDOWS:-100}"
|
72 |
65 |
|
... | ... | |
80 |
73 |
use debug && append-cppflags "-DDEBUG"
|
81 |
74 |
|
82 |
75 |
local myeconfargs=(
|
83 |
|
--with-socket-dir="${EPREFIX}/tmp/${PN}"
|
84 |
|
--with-sys-screenrc="${EPREFIX}/etc/screenrc"
|
|
76 |
--enable-socket-dir="${EPREFIX}/tmp/${PN}"
|
|
77 |
--with-system-screenrc="${EPREFIX}/etc/screenrc"
|
85 |
78 |
--with-pty-mode=0620
|
86 |
79 |
--with-pty-group=5
|
87 |
|
--enable-rxvt_osc
|
88 |
80 |
--enable-telnet
|
89 |
|
--enable-colors256
|
90 |
81 |
$(use_enable pam)
|
|
82 |
$(use_enable utempter utmp)
|
91 |
83 |
)
|
|
84 |
|
92 |
85 |
econf "${myeconfargs[@]}"
|
93 |
86 |
}
|
94 |
87 |
|
95 |
88 |
src_compile() {
|
96 |
89 |
LC_ALL=POSIX emake comm.h term.h
|
97 |
|
emake osdef.h
|
98 |
90 |
|
99 |
91 |
emake -C doc screen.info
|
100 |
92 |
default
|
... | ... | |
102 |
94 |
|
103 |
95 |
src_install() {
|
104 |
96 |
local DOCS=(
|
105 |
|
README ChangeLog INSTALL TODO NEWS* patchlevel.h
|
|
97 |
README ChangeLog INSTALL TODO NEWS*
|
106 |
98 |
doc/{FAQ,README.DOTSCREEN,fdpat.ps,window_to_display.ps}
|
107 |
99 |
)
|
108 |
100 |
|