summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorge Lebl <jirka@5z.com>2003-09-22 22:17:25 +0000
committerGeorge Lebl <jirka@src.gnome.org>2003-09-22 22:17:25 +0000
commit54f3f813a7e97b1280c882390fc294556abe1587 (patch)
tree0125785bad16f7534311667b1b66dafa01b948df
parentfc62f724c83c8cedbaccdb8d5435fedfa08fd41a (diff)
downloadgdm-54f3f813a7e97b1280c882390fc294556abe1587.tar.gz
in the old location where we're not replacing the files, move them rather
Mon Sep 22 15:16:05 2003 George Lebl <jirka@5z.com> * config/Makefile.am: in the old location where we're not replacing the files, move them rather then just copy them to avoid duplicate copies. Also just append the .orig extension, we handle that now * gui/gdmlogin.c, gui/greeter/greeter_session.c: Fix the extension handling checking and default.desktop.rpmorig and such won't be treated as .desktop files anymore
-rw-r--r--ChangeLog11
-rw-r--r--config/Makefile.am12
-rw-r--r--gui/gdmlogin.c5
-rw-r--r--gui/greeter/greeter_session.c6
4 files changed, 25 insertions, 9 deletions
diff --git a/ChangeLog b/ChangeLog
index 953f9019..d321b58d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,14 @@
+Mon Sep 22 15:16:05 2003 George Lebl <jirka@5z.com>
+
+ * config/Makefile.am: in the old location where we're not replacing
+ the files, move them rather then just copy them to avoid duplicate
+ copies. Also just append the .orig extension, we handle that
+ now
+
+ * gui/gdmlogin.c, gui/greeter/greeter_session.c: Fix the extension
+ handling checking and default.desktop.rpmorig and such won't be
+ treated as .desktop files anymore
+
Mon Sep 22 15:01:41 2003 George Lebl <jirka@5z.com>
* daemon/gdm.h, config/gdm.conf.in: use $datadir/xsessions instead of
diff --git a/config/Makefile.am b/config/Makefile.am
index 97ea835c..fed62fc3 100644
--- a/config/Makefile.am
+++ b/config/Makefile.am
@@ -74,27 +74,27 @@ install-data-hook: gdm.conf Xsession gnome.desktop default.desktop CDE.desktop D
fi
-if test -f $(DESTDIR)$(bisessdir)/Default.desktop; then \
- cp -f $(DESTDIR)$(bisessdir)/Default.desktop $(DESTDIR)$(bisessdir)/Default.orig; \
+ mv -f $(DESTDIR)$(bisessdir)/Default.desktop $(DESTDIR)$(bisessdir)/Default.desktop.orig; \
fi
-if test -f $(DESTDIR)$(bisessdir)/default.desktop; then \
- cp -f $(DESTDIR)$(bisessdir)/default.desktop $(DESTDIR)$(bisessdir)/default.orig; \
+ cp -f $(DESTDIR)$(bisessdir)/default.desktop $(DESTDIR)$(bisessdir)/default.desktop.orig; \
fi
$(INSTALL_SCRIPT) default.desktop $(DESTDIR)$(bisessdir)/default.desktop
-if test -f $(DESTDIR)$(bisessdir)/gnome.desktop; then \
- cp -f $(DESTDIR)$(bisessdir)/gnome.desktop $(DESTDIR)$(bisessdir)/gnome.orig; \
+ mv -f $(DESTDIR)$(bisessdir)/gnome.desktop $(DESTDIR)$(bisessdir)/gnome.desktop.orig; \
fi
-if test -f $(DESTDIR)$(instsessdir)/gnome.desktop; then \
- cp -f $(DESTDIR)$(instsessdir)/gnome.desktop $(DESTDIR)$(instsessdir)/gnome.orig; \
+ cp -f $(DESTDIR)$(instsessdir)/gnome.desktop $(DESTDIR)$(instsessdir)/gnome.desktop.orig; \
fi
$(INSTALL_SCRIPT) gnome.desktop $(DESTDIR)$(instsessdir)/gnome.desktop
-if test -f /usr/dt/bin/Xsession; then \
if test -f $(DESTDIR)$(bisessdir)/CDE.desktop; then \
- cp -f $(DESTDIR)$(bisessdir)/CDE.desktop $(DESTDIR)$(bisessdir)/CDE.orig; \
+ mv -f $(DESTDIR)$(bisessdir)/CDE.desktop $(DESTDIR)$(bisessdir)/CDE.desktop.orig; \
fi; \
if test -f $(DESTDIR)$(instsessdir)/CDE.desktop; then \
- cp -f $(DESTDIR)$(instsessdir)/CDE.desktop $(DESTDIR)$(instsessdir)/CDE.orig; \
+ cp -f $(DESTDIR)$(instsessdir)/CDE.desktop $(DESTDIR)$(instsessdir)/CDE.desktop.orig; \
fi; \
$(INSTALL_SCRIPT) CDE.desktop $(DESTDIR)$(instsessdir)/CDE.desktop; \
fi
diff --git a/gui/gdmlogin.c b/gui/gdmlogin.c
index 65bd15a1..2a65f28c 100644
--- a/gui/gdmlogin.c
+++ b/gui/gdmlogin.c
@@ -1257,9 +1257,12 @@ gdm_login_session_init (GtkWidget *menu)
char *s;
char *label;
char *tryexec;
+ char *ext;
/* ignore everything but the .desktop files */
- if (strstr (dent->d_name, ".desktop") == NULL) {
+ ext = strstr (dent->d_name, ".desktop");
+ if (ext == NULL ||
+ strcmp (ext, ".desktop") != 0) {
dent = readdir (sessdir);
continue;
}
diff --git a/gui/greeter/greeter_session.c b/gui/greeter/greeter_session.c
index f0bf77a4..7dd7565e 100644
--- a/gui/greeter/greeter_session.c
+++ b/gui/greeter/greeter_session.c
@@ -306,9 +306,12 @@ greeter_session_init (void)
char *comment;
char *label;
char *tryexec;
+ char *ext;
/* ignore everything bug the .desktop files */
- if (strstr (dent->d_name, ".desktop") == NULL) {
+ ext = strstr (dent->d_name, ".desktop");
+ if (ext == NULL ||
+ strcmp (ext, ".desktop") != 0) {
dent = readdir (sessdir);
continue;
}
@@ -319,7 +322,6 @@ greeter_session_init (void)
continue;
}
-
s = g_strconcat (dir, "/", dent->d_name, NULL);
cfg = ve_config_new (s);
g_free (s);