This commit is contained in:
committed by
Git OBS Bridge
parent
4a357dfffb
commit
39e685d0ab
@@ -13,8 +13,8 @@ type -p cmp &> /dev/null || {
|
||||
}
|
||||
|
||||
# Read old values. We will need one for correct updating of
|
||||
if test -f $r/etc/opt/gnome/gdm/gdm_sysconfig.conf ; then
|
||||
. $r/etc/opt/gnome/gdm/gdm_sysconfig.conf
|
||||
if test -f $r/etc/gdm/gdm_sysconfig.conf ; then
|
||||
. $r/etc/gdm/gdm_sysconfig.conf
|
||||
fi
|
||||
export OLD_DISPLAYMANAGER_AUTOLOGIN="$DISPLAYMANAGER_AUTOLOGIN"
|
||||
|
||||
@@ -57,11 +57,11 @@ if test -z "$r" ; then
|
||||
fi
|
||||
|
||||
# Write new set of monitore variables.
|
||||
echo -en "# custom.conf was last time updated with following sysconfig:\\nDISPLAYMANAGER_REMOTE_ACCESS=\"$DISPLAYMANAGER_REMOTE_ACCESS\"\\nDISPLAYMANAGER_ROOT_LOGIN_REMOTE=\"$DISPLAYMANAGER_ROOT_LOGIN_REMOTE\"\\nDISPLAYMANAGER_STARTS_XSERVER=\"$DISPLAYMANAGER_STARTS_XSERVER\"\\nDISPLAYMANAGER_XSERVER_TCP_PORT_6000_OPEN=\"$DISPLAYMANAGER_XSERVER_TCP_PORT_6000_OPEN\"\\nDISPLAYMANAGER_AUTOLOGIN=\"$DISPLAYMANAGER_AUTOLOGIN\"\\nDISPLAYMANAGER_PASSWORD_LESS_LOGIN=\"$DISPLAYMANAGER_PASSWORD_LESS_LOGIN\"\\nDISPLAYMANAGER_AD_INTEGRATION=\"$DISPLAYMANAGER_AD_INTEGRATION\"\\nDISPLAYMANAGER_SHUTDOWN=\"$DISPLAYMANAGER_SHUTDOWN\"\\nPERMISSION_SECURITY=\"$PERMISSION_SECURITY\"\\n" >$r/etc/opt/gnome/gdm/gdm_sysconfig.conf.new
|
||||
echo -en "# custom.conf was last time updated with following sysconfig:\\nDISPLAYMANAGER_REMOTE_ACCESS=\"$DISPLAYMANAGER_REMOTE_ACCESS\"\\nDISPLAYMANAGER_ROOT_LOGIN_REMOTE=\"$DISPLAYMANAGER_ROOT_LOGIN_REMOTE\"\\nDISPLAYMANAGER_STARTS_XSERVER=\"$DISPLAYMANAGER_STARTS_XSERVER\"\\nDISPLAYMANAGER_XSERVER_TCP_PORT_6000_OPEN=\"$DISPLAYMANAGER_XSERVER_TCP_PORT_6000_OPEN\"\\nDISPLAYMANAGER_AUTOLOGIN=\"$DISPLAYMANAGER_AUTOLOGIN\"\\nDISPLAYMANAGER_PASSWORD_LESS_LOGIN=\"$DISPLAYMANAGER_PASSWORD_LESS_LOGIN\"\\nDISPLAYMANAGER_AD_INTEGRATION=\"$DISPLAYMANAGER_AD_INTEGRATION\"\\nDISPLAYMANAGER_SHUTDOWN=\"$DISPLAYMANAGER_SHUTDOWN\"\\nPERMISSION_SECURITY=\"$PERMISSION_SECURITY\"\\n" >$r/etc/gdm/gdm_sysconfig.conf.new
|
||||
|
||||
# Are there any changes in monitored variables?
|
||||
if cmp -s 2>/dev/null $r/etc/opt/gnome/gdm/gdm_sysconfig.conf $r/etc/opt/gnome/gdm/gdm_sysconfig.conf.new ; then
|
||||
rm $r/etc/opt/gnome/gdm/gdm_sysconfig.conf.new
|
||||
if cmp -s 2>/dev/null $r/etc/gdm/gdm_sysconfig.conf $r/etc/gdm/gdm_sysconfig.conf.new ; then
|
||||
rm $r/etc/gdm/gdm_sysconfig.conf.new
|
||||
exit
|
||||
fi
|
||||
|
||||
@@ -152,7 +152,7 @@ unset unset ${!last_of_*} ${!custom_conf_*}
|
||||
|
||||
# Parse configuration file and record all items to environment values.
|
||||
eval "$(
|
||||
awk <$r/etc/opt/gnome/gdm/custom.conf '
|
||||
awk <$r/etc/gdm/custom.conf '
|
||||
BEGIN {
|
||||
section="BEGIN";
|
||||
section_last_line=0;
|
||||
@@ -207,7 +207,7 @@ END {
|
||||
)"
|
||||
|
||||
# And now set what is required.
|
||||
awk <$r/etc/opt/gnome/gdm/custom.conf >$r/etc/opt/gnome/gdm/custom.conf.new '
|
||||
awk <$r/etc/gdm/custom.conf >$r/etc/gdm/custom.conf.new '
|
||||
# Prepare array from variable.
|
||||
function gdm_prepare_var(var) {
|
||||
gdm_conf_var[var]=ENVIRON[var];
|
||||
@@ -220,7 +220,7 @@ function update_item(section, item) {
|
||||
print item"="gdm_conf_var[section"_"item];
|
||||
if (ENVIRON["GDM_IS_RUNNING"] == "true")
|
||||
# FIXME: If gdm is running and no session is active, command is executed too early.
|
||||
system("$r/opt/gnome/bin/gdmflexiserver --command=\"UPDATE_CONFIG "section"/"item"\"")
|
||||
system("$r/usr/bin/gdmflexiserver --command=\"UPDATE_CONFIG "section"/"item"\"")
|
||||
return "DONE";
|
||||
} else
|
||||
return "KEEP_ORIG";
|
||||
@@ -255,7 +255,7 @@ BEGIN {
|
||||
/^enable=/ {
|
||||
if (section == "xdmcp") {
|
||||
# Remove old gdm_sysconfig.conf to force update of custom.conf.
|
||||
system("rm -f $r/etc/opt/gnome/gdm/gdm_sysconfig.conf");
|
||||
system("rm -f $r/etc/gdm/gdm_sysconfig.conf");
|
||||
process_unseen();
|
||||
next;
|
||||
}
|
||||
@@ -302,5 +302,5 @@ BEGIN {
|
||||
next;
|
||||
}
|
||||
'
|
||||
mv $r/etc/opt/gnome/gdm/custom.conf.new $r/etc/opt/gnome/gdm/custom.conf
|
||||
mv $r/etc/opt/gnome/gdm/gdm_sysconfig.conf.new $r/etc/opt/gnome/gdm/gdm_sysconfig.conf
|
||||
mv $r/etc/gdm/custom.conf.new $r/etc/gdm/custom.conf
|
||||
mv $r/etc/gdm/gdm_sysconfig.conf.new $r/etc/gdm/gdm_sysconfig.conf
|
||||
|
Reference in New Issue
Block a user