merge from ghomem

ulab-next
Jay Sorg 12 years ago
commit 214a7b52bc

@ -129,6 +129,8 @@ AC_CONFIG_FILES([Makefile
docs/man/Makefile docs/man/Makefile
instfiles/Makefile instfiles/Makefile
instfiles/pam.d/Makefile instfiles/pam.d/Makefile
instfiles/init.d/Makefile
instfiles/default/Makefile
genkeymap/Makefile genkeymap/Makefile
xrdpapi/Makefile xrdpapi/Makefile
xrdpvr/Makefile xrdpvr/Makefile

@ -0,0 +1 @@
RDP server for Linux

@ -27,5 +27,9 @@ setxkbmap -model pc104 -layout ru
setxkbmap -model pc104 -layout se setxkbmap -model pc104 -layout se
./xrdp-genkeymap ../instfiles/km-041d.ini ./xrdp-genkeymap ../instfiles/km-041d.ini
# Portuguese -PT 'pt-pt' 0x0816
setxkbmap -model pc104 -layout pt
./xrdp-genkeymap ../instfiles/km-0816.ini
# set back to en-us # set back to en-us
setxkbmap -model pc104 -layout us setxkbmap -model pc104 -layout us

@ -1,9 +1,11 @@
EXTRA_DIST = xrdp.sh km-0407.ini km-0409.ini km-040c.ini km-0410.ini km-0419.ini km-041d.ini \ EXTRA_DIST = xrdp.sh km-0407.ini km-0409.ini km-040c.ini km-0410.ini km-0419.ini km-041d.ini km-0816.ini \
xrdp-sesman.service \ xrdp-sesman.service \
xrdp.service xrdp.service
SUBDIRS = \ SUBDIRS = \
pam.d pam.d \
init.d \
default
if HAVE_SYSTEMD if HAVE_SYSTEMD
systemdsystemunit_DATA = \ systemdsystemunit_DATA = \
@ -20,8 +22,10 @@ startscript_DATA = \
km-040c.ini \ km-040c.ini \
km-0410.ini \ km-0410.ini \
km-0419.ini \ km-0419.ini \
km-041d.ini km-041d.ini \
km-0816.ini
# must be tab below # must be tab below
install-data-hook: install-data-hook:
chmod 755 $(DESTDIR)$(sysconfdir)/xrdp/xrdp.sh chmod 755 $(DESTDIR)$(sysconfdir)/xrdp/xrdp.sh
chmod 755 $(DESTDIR)$(sysconfdir)/init.d/xrdp

@ -0,0 +1,3 @@
EXTRA_DIST = xrdp
startscriptdir=$(sysconfdir)/default
startscript_DATA = xrdp

@ -0,0 +1,5 @@
# Do we need to start sesman ?
SESMAN_START=yes
# Do we restart xrdp on upgrade ? If not set to no, any xrdp session will
# be shutdown on upgrade.
# RESTART_ON_UPGRADE=no

@ -0,0 +1,4 @@
EXTRA_DIST = xrdp
startscriptdir=$(sysconfdir)/init.d
startscript_DATA = xrdp

@ -0,0 +1,185 @@
#!/bin/sh -e
#
# start/stop xrdp and sesman daemons
#
### BEGIN INIT INFO
# Provides: xrdp
# Required-Start: $network $remote_fs
# Required-Stop: $network $remote_fs
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Start xrdp and sesman daemons
# Description: XRDP uses the Remote Desktop Protocol to present a
# graphical login to a remote client allowing connection
# to a VNC server or another RDP server.
### END INIT INFO
PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
DAEMON=/usr/sbin/xrdp
PIDDIR=/var/run/xrdp/
SESMAN_START=yes
#USERID=xrdp
# the X11rdp backend only works as root at the moment - GH 20/03/2013
USERID=root
RSAKEYS=/etc/xrdp/rsakeys.ini
NAME=xrdp
DESC="Remote Desktop Protocol server"
test -x $DAEMON || exit 0
. /lib/lsb/init-functions
check_root() {
if [ "$(id -u)" != "0" ]; then
log_failure_msg "You must be root to start, stop or restart $NAME."
exit 4
fi
}
force_stop() {
DELAY=1
PROCLIST="xrdp-sesman xrdp-sessvc xrdp-chansrv X11rdp Xvnc"
for p in $PROCLIST; do
pgrep -x $p >/dev/null && pkill -x $p
sleep $DELAY
pgrep -x $p >/dev/null && pkill -9 -x $p
done
# let's not kill ourselves - the init script is called xrdp as well
pgrep -fx $DAEMON >/dev/null && pkill -fx $DAEMON
sleep $DELAY
pgrep -fx $DAEMON >/dev/null && pkill -9 -fx $DAEMON
rm -f $PIDDIR/xrdp*.pid
}
if [ -r /etc/default/$NAME ]; then
. /etc/default/$NAME
fi
# Tasks that can only be run as root
if [ "$(id -u)" = "0" ]; then
# Check for pid dir
if [ ! -d $PIDDIR ] ; then
mkdir $PIDDIR
fi
chown $USERID:$USERID $PIDDIR
# Check for rsa key
if [ ! -f $RSAKEYS ] ; then
log_action_begin_msg "Generating xrdp RSA keys..."
(umask 077 ; xrdp-keygen xrdp $RSAKEYS)
chown $USERID:$USERID $RSAKEYS
if [ ! -f $RSAKEYS ] ; then
log_action_end_msg 1 "could not create $RSAKEYS"
exit 1
fi
log_action_end_msg 0 "done"
fi
fi
case "$1" in
start)
check_root
exitval=0
log_daemon_msg "Starting $DESC "
if pidofproc -p $PIDDIR/$NAME.pid $DAEMON > /dev/null; then
log_progress_msg "$NAME apparently already running"
log_end_msg 0
exit 0
fi
log_progress_msg $NAME
start-stop-daemon --start --quiet --oknodo --pidfile $PIDDIR/$NAME.pid \
--chuid $USERID:$USERID --exec $DAEMON >/dev/null
exitval=$?
if [ "$SESMAN_START" = "yes" ] ; then
log_progress_msg "sesman"
start-stop-daemon --start --quiet --oknodo --pidfile $PIDDIR/xrdp-sesman.pid \
--exec /usr/sbin/xrdp-sesman >/dev/null
value=$?
[ $value -gt 0 ] && exitval=$value
fi
# Make pidfile readables for all users (for status to work)
[ -e $PIDDIR/xrdp-sesman.pid ] && chmod 0644 $PIDDIR/xrdp-sesman.pid
[ -e $PIDDIR/$NAME.pid ] && chmod 0644 $PIDDIR/$NAME.pid
# Note: Unfortunately, xrdp currently takes too long to create
# the pidffile unless properly patched
log_end_msg $exitval
;;
stop)
check_root
[ -n "$XRDP_UPGRADE" -a "$RESTART_ON_UPGRADE" = "no" ] && {
echo "Upgrade in progress, no restart of xrdp."
exit 0
}
exitval=0
log_daemon_msg "Stopping RDP Session manager "
log_progress_msg "sesman"
if pidofproc -p $PIDDIR/xrdp-sesman.pid /usr/sbin/xrdp-sesman > /dev/null; then
start-stop-daemon --stop --quiet --oknodo --pidfile $PIDDIR/xrdp-sesman.pid \
--chuid $USERID:$USERID --exec /usr/sbin/xrdp-sesman
exitval=$?
else
log_progress_msg "apparently not running"
fi
log_progress_msg $NAME
if pidofproc -p $PIDDIR/$NAME.pid $DAEMON > /dev/null; then
start-stop-daemon --stop --quiet --oknodo --pidfile $PIDDIR/$NAME.pid \
--exec $DAEMON
value=$?
[ $value -gt 0 ] && exitval=$value
else
log_progress_msg "apparently not running"
fi
log_end_msg $exitval
;;
force-stop)
$0 stop
# because it doesn't allways die the right way
force_stop
;;
restart|force-reload)
check_root
$0 stop
# Wait for things to settle down
sleep 1
$0 start
;;
reload)
log_warning_msg "Reloading $NAME daemon: not implemented, as the daemon"
log_warning_msg "cannot re-read the config file (use restart)."
;;
status)
exitval=0
log_daemon_msg "Checking status of $DESC" "$NAME"
if pidofproc -p $PIDDIR/$NAME.pid $DAEMON > /dev/null; then
log_progress_msg "running"
log_end_msg 0
else
log_progress_msg "apparently not running"
log_end_msg 1 || true
exitval=1
fi
if [ "$SESMAN_START" = "yes" ] ; then
log_daemon_msg "Checking status of RDP Session Manager" "sesman"
if pidofproc -p $PIDDIR/xrdp-sesman.pid /usr/sbin/xrdp-sesman > /dev/null; then
log_progress_msg "running"
log_end_msg 0
else
log_progress_msg "apparently not running"
log_end_msg 1 || true
exitval=1
fi
fi
exit $exitval
;;
*)
N=/etc/init.d/$NAME
echo "Usage: $N {start|stop|force-stop|restart|force-reload|status}" >&2
exit 1
;;
esac
exit 0

@ -0,0 +1,659 @@
[noshift]
Key8=0:0
Key9=65307:27
Key10=49:49
Key11=50:50
Key12=51:51
Key13=52:52
Key14=53:53
Key15=54:54
Key16=55:55
Key17=56:56
Key18=57:57
Key19=48:48
Key20=39:39
Key21=171:171
Key22=65288:8
Key23=65289:9
Key24=113:113
Key25=119:119
Key26=101:101
Key27=114:114
Key28=116:116
Key29=121:121
Key30=117:117
Key31=105:105
Key32=111:111
Key33=112:112
Key34=43:43
Key35=65105:180
Key36=65293:13
Key37=65507:0
Key38=97:97
Key39=115:115
Key40=100:100
Key41=102:102
Key42=103:103
Key43=104:104
Key44=106:106
Key45=107:107
Key46=108:108
Key47=231:231
Key48=186:186
Key49=92:92
Key50=65505:0
Key51=65107:126
Key52=122:122
Key53=120:120
Key54=99:99
Key55=118:118
Key56=98:98
Key57=110:110
Key58=109:109
Key59=44:44
Key60=46:46
Key61=45:45
Key62=65506:0
Key63=65450:42
Key64=65513:0
Key65=32:32
Key66=65509:0
Key67=65470:0
Key68=65471:0
Key69=65472:0
Key70=65473:0
Key71=65474:0
Key72=65475:0
Key73=65476:0
Key74=65477:0
Key75=65478:0
Key76=65479:0
Key77=65407:0
Key78=65300:0
Key79=65429:0
Key80=65431:0
Key81=65434:0
Key82=65453:45
Key83=65430:0
Key84=65437:0
Key85=65432:0
Key86=65451:43
Key87=65436:0
Key88=65433:0
Key89=65435:0
Key90=65438:0
Key91=65439:0
Key92=0:0
Key93=65406:0
Key94=60:60
Key95=65480:0
Key96=65481:0
Key97=65360:0
Key98=65362:0
Key99=65365:0
Key100=65361:0
Key101=0:0
Key102=65363:0
Key103=65367:0
Key104=65364:0
Key105=65366:0
Key106=65379:0
Key107=65535:127
Key108=65421:13
Key109=65508:0
Key110=65299:0
Key111=65377:0
Key112=65455:47
Key113=65027:0
Key114=0:0
Key115=65515:0
Key116=65312:0
Key117=65383:0
Key118=0:0
Key119=0:0
Key120=0:0
Key121=0:0
Key122=0:0
Key123=0:0
Key124=65027:0
Key125=0:0
Key126=65469:61
Key127=0:0
Key128=0:0
Key129=269025170:0
Key130=0:0
Key131=0:0
Key132=0:0
Key133=269025166:0
Key134=0:0
Key135=65382:0
Key136=65381:0
Key137=0:0
[shift]
Key8=0:0
Key9=65307:27
Key10=33:33
Key11=34:34
Key12=35:35
Key13=36:36
Key14=37:37
Key15=38:38
Key16=47:47
Key17=40:40
Key18=41:41
Key19=61:61
Key20=63:63
Key21=187:187
Key22=65288:8
Key23=65056:0
Key24=81:81
Key25=87:87
Key26=69:69
Key27=82:82
Key28=84:84
Key29=89:89
Key30=85:85
Key31=73:73
Key32=79:79
Key33=80:80
Key34=42:42
Key35=65104:96
Key36=65293:13
Key37=65507:0
Key38=65:65
Key39=83:83
Key40=68:68
Key41=70:70
Key42=71:71
Key43=72:72
Key44=74:74
Key45=75:75
Key46=76:76
Key47=199:199
Key48=170:170
Key49=124:124
Key50=65505:0
Key51=65106:94
Key52=90:90
Key53=88:88
Key54=67:67
Key55=86:86
Key56=66:66
Key57=78:78
Key58=77:77
Key59=59:59
Key60=58:58
Key61=95:95
Key62=65506:0
Key63=65450:42
Key64=65511:0
Key65=32:32
Key66=65509:0
Key67=65470:0
Key68=65471:0
Key69=65472:0
Key70=65473:0
Key71=65474:0
Key72=65475:0
Key73=65476:0
Key74=65477:0
Key75=65478:0
Key76=65479:0
Key77=65273:0
Key78=65300:0
Key79=65463:55
Key80=65464:56
Key81=65465:57
Key82=65453:45
Key83=65460:52
Key84=65461:53
Key85=65462:54
Key86=65451:43
Key87=65457:49
Key88=65458:50
Key89=65459:51
Key90=65456:48
Key91=65454:46
Key92=0:0
Key93=65406:0
Key94=62:62
Key95=65480:0
Key96=65481:0
Key97=65360:0
Key98=65362:0
Key99=65365:0
Key100=65361:0
Key101=0:0
Key102=65363:0
Key103=65367:0
Key104=65364:0
Key105=65366:0
Key106=65379:0
Key107=65535:127
Key108=65421:13
Key109=65508:0
Key110=65299:0
Key111=65377:0
Key112=65455:47
Key113=65027:0
Key114=0:0
Key115=65515:0
Key116=65312:0
Key117=65383:0
Key118=0:0
Key119=0:0
Key120=0:0
Key121=0:0
Key122=0:0
Key123=0:0
Key124=65027:0
Key125=65513:0
Key126=65469:61
Key127=65515:0
Key128=65517:0
Key129=269025170:0
Key130=0:0
Key131=0:0
Key132=0:0
Key133=269025166:0
Key134=0:0
Key135=65382:0
Key136=65381:0
Key137=0:0
[altgr]
Key8=0:0
Key9=65307:27
Key10=185:185
Key11=64:64
Key12=163:163
Key13=167:167
Key14=189:189
Key15=172:172
Key16=123:123
Key17=91:91
Key18=93:93
Key19=125:125
Key20=92:92
Key21=65115:184
Key22=65288:8
Key23=65289:9
Key24=64:64
Key25=435:322
Key26=8364:8364
Key27=182:182
Key28=956:359
Key29=2299:8592
Key30=2302:8595
Key31=2301:8594
Key32=248:248
Key33=254:254
Key34=65111:168
Key35=65107:126
Key36=65293:13
Key37=65507:0
Key38=230:230
Key39=223:223
Key40=240:240
Key41=496:273
Key42=959:331
Key43=689:295
Key44=106:106
Key45=930:312
Key46=435:322
Key47=65105:180
Key48=65106:94
Key49=172:172
Key50=65505:0
Key51=65104:96
Key52=171:171
Key53=187:187
Key54=162:162
Key55=2770:8220
Key56=2771:8221
Key57=110:110
Key58=181:181
Key59=2211:0
Key60=183:183
Key61=65120:0
Key62=65506:0
Key63=65450:42
Key64=65513:0
Key65=32:32
Key66=65509:0
Key67=65470:0
Key68=65471:0
Key69=65472:0
Key70=65473:0
Key71=65474:0
Key72=65475:0
Key73=65476:0
Key74=65477:0
Key75=65478:0
Key76=65479:0
Key77=65407:0
Key78=65300:0
Key79=65429:0
Key80=65431:0
Key81=65434:0
Key82=65453:45
Key83=65430:0
Key84=65437:0
Key85=65432:0
Key86=65451:43
Key87=65436:0
Key88=65433:0
Key89=65435:0
Key90=65438:0
Key91=65439:0
Key92=0:0
Key93=65406:0
Key94=124:124
Key95=65480:0
Key96=65481:0
Key97=65360:0
Key98=65362:0
Key99=65365:0
Key100=65361:0
Key101=0:0
Key102=65363:0
Key103=65367:0
Key104=65364:0
Key105=65366:0
Key106=65379:0
Key107=65535:127
Key108=65421:13
Key109=65508:0
Key110=65299:0
Key111=65377:0
Key112=65455:47
Key113=65027:0
Key114=0:0
Key115=65515:0
Key116=65312:0
Key117=65383:0
Key118=0:0
Key119=0:0
Key120=0:0
Key121=0:0
Key122=0:0
Key123=0:0
Key124=65027:0
Key125=0:0
Key126=65469:61
Key127=0:0
Key128=0:0
Key129=269025170:0
Key130=0:0
Key131=0:0
Key132=0:0
Key133=269025166:0
Key134=0:0
Key135=65382:0
Key136=65381:0
Key137=0:0
[capslock]
Key8=0:0
Key9=65307:27
Key10=49:49
Key11=50:50
Key12=51:51
Key13=52:52
Key14=53:53
Key15=54:54
Key16=55:55
Key17=56:56
Key18=57:57
Key19=48:48
Key20=39:39
Key21=171:171
Key22=65288:8
Key23=65289:9
Key24=81:81
Key25=87:87
Key26=69:69
Key27=82:82
Key28=84:84
Key29=89:89
Key30=85:85
Key31=73:73
Key32=79:79
Key33=80:80
Key34=43:43
Key35=65105:180
Key36=65293:13
Key37=65507:0
Key38=65:65
Key39=83:83
Key40=68:68
Key41=70:70
Key42=71:71
Key43=72:72
Key44=74:74
Key45=75:75
Key46=76:76
Key47=199:199
Key48=186:186
Key49=92:92
Key50=65505:0
Key51=65107:126
Key52=90:90
Key53=88:88
Key54=67:67
Key55=86:86
Key56=66:66
Key57=78:78
Key58=77:77
Key59=44:44
Key60=46:46
Key61=45:45
Key62=65506:0
Key63=65450:42
Key64=65513:0
Key65=32:32
Key66=65509:0
Key67=65470:0
Key68=65471:0
Key69=65472:0
Key70=65473:0
Key71=65474:0
Key72=65475:0
Key73=65476:0
Key74=65477:0
Key75=65478:0
Key76=65479:0
Key77=65407:0
Key78=65300:0
Key79=65429:0
Key80=65431:0
Key81=65434:0
Key82=65453:45
Key83=65430:0
Key84=65437:0
Key85=65432:0
Key86=65451:43
Key87=65436:0
Key88=65433:0
Key89=65435:0
Key90=65438:0
Key91=65439:0
Key92=0:0
Key93=65406:0
Key94=60:60
Key95=65480:0
Key96=65481:0
Key97=65360:0
Key98=65362:0
Key99=65365:0
Key100=65361:0
Key101=0:0
Key102=65363:0
Key103=65367:0
Key104=65364:0
Key105=65366:0
Key106=65379:0
Key107=65535:127
Key108=65421:13
Key109=65508:0
Key110=65299:0
Key111=65377:0
Key112=65455:47
Key113=65027:0
Key114=0:0
Key115=65515:0
Key116=65312:0
Key117=65383:0
Key118=0:0
Key119=0:0
Key120=0:0
Key121=0:0
Key122=0:0
Key123=0:0
Key124=65027:0
Key125=0:0
Key126=65469:61
Key127=0:0
Key128=0:0
Key129=269025170:0
Key130=0:0
Key131=0:0
Key132=0:0
Key133=269025166:0
Key134=0:0
Key135=65382:0
Key136=65381:0
Key137=0:0
[shiftcapslock]
Key8=0:0
Key9=65307:27
Key10=33:33
Key11=34:34
Key12=35:35
Key13=36:36
Key14=37:37
Key15=38:38
Key16=47:47
Key17=40:40
Key18=41:41
Key19=61:61
Key20=63:63
Key21=187:187
Key22=65288:8
Key23=65056:0
Key24=113:113
Key25=119:119
Key26=101:101
Key27=114:114
Key28=116:116
Key29=121:121
Key30=117:117
Key31=105:105
Key32=111:111
Key33=112:112
Key34=42:42
Key35=65104:96
Key36=65293:13
Key37=65507:0
Key38=97:97
Key39=115:115
Key40=100:100
Key41=102:102
Key42=103:103
Key43=104:104
Key44=106:106
Key45=107:107
Key46=108:108
Key47=231:231
Key48=170:170
Key49=124:124
Key50=65505:0
Key51=65106:94
Key52=122:122
Key53=120:120
Key54=99:99
Key55=118:118
Key56=98:98
Key57=110:110
Key58=109:109
Key59=59:59
Key60=58:58
Key61=95:95
Key62=65506:0
Key63=65450:42
Key64=65511:0
Key65=32:32
Key66=65509:0
Key67=65470:0
Key68=65471:0
Key69=65472:0
Key70=65473:0
Key71=65474:0
Key72=65475:0
Key73=65476:0
Key74=65477:0
Key75=65478:0
Key76=65479:0
Key77=65273:0
Key78=65300:0
Key79=65463:55
Key80=65464:56
Key81=65465:57
Key82=65453:45
Key83=65460:52
Key84=65461:53
Key85=65462:54
Key86=65451:43
Key87=65457:49
Key88=65458:50
Key89=65459:51
Key90=65456:48
Key91=65454:46
Key92=0:0
Key93=65406:0
Key94=62:62
Key95=65480:0
Key96=65481:0
Key97=65360:0
Key98=65362:0
Key99=65365:0
Key100=65361:0
Key101=0:0
Key102=65363:0
Key103=65367:0
Key104=65364:0
Key105=65366:0
Key106=65379:0
Key107=65535:127
Key108=65421:13
Key109=65508:0
Key110=65299:0
Key111=65377:0
Key112=65455:47
Key113=65027:0
Key114=0:0
Key115=65515:0
Key116=65312:0
Key117=65383:0
Key118=0:0
Key119=0:0
Key120=0:0
Key121=0:0
Key122=0:0
Key123=0:0
Key124=65027:0
Key125=65513:0
Key126=65469:61
Key127=65515:0
Key128=65517:0
Key129=269025170:0
Key130=0:0
Key131=0:0
Key132=0:0
Key133=269025166:0
Key134=0:0
Key135=65382:0
Key136=65381:0
Key137=0:0

@ -0,0 +1,21 @@
#!/bin/sh -e
if ! ([ "$1" = "configure" ] || [ "$1" = "reconfigure" ]); then
exit 0
fi
XRDP="xrdp"
ADDUSER="/usr/sbin/adduser"
XRDPLOG="/var/log/xrdp-sesman.log"
SESMANLOG="/var/log/xrdp-sesman.log"
[ -d /var/run/xrdp ] || mkdir -p /var/run/xrdp
$ADDUSER --system --disabled-password --disabled-login --home /var/run/xrdp \
--no-create-home --quiet --group $XRDP
touch $SESMANLOG $XRDPLOG
chown $XRDP:$XRDP $SESMANLOG
chown $XRDP:$XRDP $XRDPLOG
#DEBHELPER#

@ -1,94 +1,6 @@
#!/bin/sh #!/bin/sh
if [ -r /etc/default/locale ]; then
# change the order in line below to run to run whatever window manager you . /etc/default/locale
# want, default to kde export LANG LANGUAGE
#SESSIONS="gnome-session blackbox fluxbox startxfce4 startkde xterm"
SESSIONS="mate-session blackbox fluxbox startxfce4 startkde xterm"
#start the window manager
wm_start()
{
for WindowManager in $SESSIONS
do
which $WindowManager
if test $? -eq 0
then
echo "Starting $WindowManager"
$WindowManager
return 0
fi fi
done . /etc/X11/Xsession
return 0
}
#Execution sequence for interactive login shell
#Following pseudo code explains the sequence of execution of these files.
#execute /etc/profile
#IF ~/.bash_profile exists THEN
# execute ~/.bash_profile
#ELSE
# IF ~/.bash_login exist THEN
# execute ~/.bash_login
# ELSE
# IF ~/.profile exist THEN
# execute ~/.profile
# END IF
# END IF
#END IF
pre_start()
{
if [ -f /etc/profile ]
then
. /etc/profile
fi
if [ -f ~/.bash_profile ]
then
. ~/.bash_profile
else
if [ -f ~/.bash_login ]
then
. ~/.bash_login
else
if [ -f ~/.profile ]
then
. ~/.profile
fi
fi
fi
return 0
}
#When you logout of the interactive shell, following is the
#sequence of execution:
#IF ~/.bash_logout exists THEN
# execute ~/.bash_logout
#END IF
post_start()
{
if [ -f ~/.bash_logout ]
then
. ~/.bash_logout
fi
return 0
}
#. /etc/environment
#export PATH=$PATH
#export LANG=$LANG
# change PATH to be what your environment needs usually what is in
# /etc/environment
#PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games"
#export PATH=$PATH
# for PATH and LANG from /etc/environment
# pam will auto process the environment file if /etc/pam.d/xrdp-sesman
# includes
# auth required pam_env.so readenv=1
pre_start
wm_start
post_start
exit 1

@ -0,0 +1,30 @@
#!/bin/bash
# receives version, release number and source directory as arguments
VERSION=$1
RELEASE=$2
SRCDIR=$3
PKGDEST=$4
PACKDIR=x11rdp-files
DESTDIR=$PACKDIR/opt
NAME=x11rdp
ARCH=$( dpkg --print-architecture )
sed -i -e "s/DUMMYVERINFO/$VERSION-$RELEASE/" $PACKDIR/DEBIAN/control
sed -i -e "s/DUMMYARCHINFO/$ARCH/" $PACKDIR/DEBIAN/control
# need a different delimiter, since it has a path
sed -i -e "s,DUMMYDIRINFO,$SRCDIR," $PACKDIR/DEBIAN/postinst
mkdir -p $DESTDIR
cp -Rf $SRCDIR $DESTDIR
dpkg-deb --build $PACKDIR $PKGDEST/${NAME}_$VERSION-${RELEASE}_${ARCH}.deb
# revert to initial state
rm -rf $DESTDIR
sed -i -e "s/$VERSION-$RELEASE/DUMMYVERINFO/" $PACKDIR/DEBIAN/control
sed -i -e "s/$ARCH/DUMMYARCHINFO/" $PACKDIR/DEBIAN/control
# need a different delimiter, since it has a path
sed -i -e "s,$SRCDIR,DUMMYDIRINFO," $PACKDIR/DEBIAN/postinst

@ -0,0 +1,7 @@
Package: x11rdp
Version: DUMMYVERINFO
Section: unknown
Priority: optional
Architecture: DUMMYARCHINFO
Maintainer: Angulo Solido <packaging@angulosolido.pt>
Description: X11rdp backend for the xrdp remote access server

@ -0,0 +1,18 @@
#!/bin/bash
X11DIR=DUMMYDIRINFO
# make the /usr/bin/X11rdp symbolic link if it doesn't exist...
if [ ! -e /usr/bin/X11rdp ]
then
if [ -e $X11DIR/bin/X11rdp ]
then
ln -s $X11DIR/bin/X11rdp /usr/bin/X11rdp
else
clear
echo "There was a problem... the $X11DIR/bin/X11rdp binary could not be found. Did the compilation complete?"
echo "Stopped. Please investigate what went wrong."
exit
fi
fi

@ -1,4 +1,4 @@
EXTRA_DIST = xrdp.ini rsakeys.ini ad24b.bmp ad256.bmp xrdp24b.bmp xrdp256.bmp sans-10.fv1 cursor0.cur cursor1.cur xrdp.h xrdp_types.h EXTRA_DIST = xrdp.ini ad24b.bmp ad256.bmp xrdp24b.bmp xrdp256.bmp sans-10.fv1 cursor0.cur cursor1.cur xrdp.h xrdp_types.h
if XRDP_DEBUG if XRDP_DEBUG
EXTRA_DEFINES = -DXRDP_DEBUG EXTRA_DEFINES = -DXRDP_DEBUG
@ -43,8 +43,7 @@ xrdp_LDADD = \
xrdpsysconfdir=$(sysconfdir)/xrdp xrdpsysconfdir=$(sysconfdir)/xrdp
xrdpsysconf_DATA = \ xrdpsysconf_DATA = \
xrdp.ini \ xrdp.ini
rsakeys.ini
xrdppkgdatadir=$(datadir)/xrdp xrdppkgdatadir=$(datadir)/xrdp
@ -57,6 +56,3 @@ xrdppkgdata_DATA = \
cursor0.cur \ cursor0.cur \
cursor1.cur cursor1.cur
# must be tab below
install-data-hook:
chmod 600 $(DESTDIR)$(sysconfdir)/xrdp/rsakeys.ini

Loading…
Cancel
Save