Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 04 Nov 2001 14:09:47 +0900
From:      SASAKI Katuhiro <sahiro@crest.ocn.ne.jp>
To:        Alan Eldridge <alane@geeksrus.net>
Cc:        ports@freebsd.org
Subject:   Re: ports/31595: kdebase2(2.2.1): $PREFIX/share/config/kdm/X* should not be in pkg-plist
Message-ID:  <3be4cd83.6480%sahiro@crest.ocn.ne.jp>
In-Reply-To: <20011103001020.A32545@wwweasel.geeksrus.net>
References:  <200110301347.f9UDlDJ77915@freefall.freebsd.org> <3be36dc4.6478%sahiro@crest.ocn.ne.jp> <20011103001020.A32545@wwweasel.geeksrus.net>

next in thread | previous in thread | raw e-mail | index | archive | help
Hi.

>If you can rework that into a patch against genkdmconf.c so it's
>possible to tell what's actually going to happen to the source file,
>then I can make a better assessment. 
>
After aplying patch included in previous mail, 
kdebase2/files/patch-kdm::kfrontend::genkdmconf.c becomes as 
shown below. Main changes in kdm/kfrontend/genkdmconf.c are 

i) Replacing line 
"#exec sessreg -a -l $DISPLAY $USER" in Xstartup and Xreset with
"#exec sessreg -a -l $DISPLAY -x /usr/local/share/config/kdm/Xservers $USER".
When lines are uncommented, the former will not work well. 
This part is already contained present port skeleton.

ii) Changing file names created by running ./genkdmconf, for 
example, "kdmrc" to "kdmrc.sample". Without this change, 
"./genkdmconf --no-old --in $(DESTDIR)$(kde_confdir)/kdm" will 
destroy configuration files (Xaccess, Xreset, Xservers, 
Xsession, Xsetup, Xstartup, Xwilling and kdmrc) already 
existing by overwriting them.

I wish this explanation to be useful for you.
Thank you. 


% cat kdebase2/files/patch-kdm::kfrontend::genkdmconf.c
--- kdm/kfrontend/genkdmconf.c.orig	Wed Sep  5 08:15:47 2001
+++ kdm/kfrontend/genkdmconf.c	Wed Oct 31 03:31:51 2001
@@ -212,7 +212,7 @@
  */
 
 #ifndef HALT_CMD
-# ifdef BSD
+# if defined(BSD) || defined(__FreeBSD__)
 #  define HALT_CMD	"/sbin/shutdown -h now"
 #  define REBOOT_CMD	"/sbin/shutdown -r now"
 # elif defined(__SVR4)
@@ -1481,7 +1481,7 @@
 static void
 genSuppFiles (void)
 {
-    writeFile ("%s/Xaccess", 0644, "%s",
+    writeFile ("%s/Xaccess.sample", 0644, "%s",
 "# Xaccess - Access control file for XDMCP connections\n"
 "#\n"
 "# To control Direct and Broadcast access:\n"
@@ -1549,7 +1549,7 @@
 "\n"
 "#*		CHOOSER %hostlist	#\n"
 );
-    writeFile ("%s/Xservers", 0644, "%s",
+    writeFile ("%s/Xservers.sample", 0644, "%s",
 "# Xservers - local X-server list\n"
 "#\n"
 "# This file should contain an entry to start the server on the\n"
@@ -1572,7 +1572,7 @@
 ":0 local " XBINDIR "/X"
 #endif
 "\n\n");
-    writeFile ("%s/Xwilling", 0755, "%s",
+    writeFile ("%s/Xwilling.sample", 0755, "%s",
 "#!/bin/sh\n"
 "# The output of this script is displayed in the chooser window.\n"
 "# (instead of \"Willing to manage\")\n"
@@ -1583,13 +1583,13 @@
 "\n"
 "echo \"${nrusers} user${s}, load: ${load}\"\n"
 );
-    writeFile ("%s/Xsetup", 0755, "%s",
+    writeFile ("%s/Xsetup.sample", 0755, "%s",
 "#!/bin/sh\n"
 "# Xsetup - run as root before the login dialog appears\n"
 "\n"
 KDE_BINDIR "/kdmdesktop &\n"
 );
-    writeFile ("%s/Xstartup", 0755, "%s",
+    writeFile ("%s/Xstartup.sample", 0755, "%s",
 "#!/bin/sh\n"
 "# Xstartup - run as root before session starts\n"
 "\n"
@@ -1606,12 +1606,12 @@
 #endif
 "\n"
 "#exec sessreg -a -l $DISPLAY "
-#ifdef BSD
+#if defined(BSD) || defined(__FreeBSD__)
 "-x " KDMCONF "/Xservers "
 #endif
 "$USER\n"
 );
-    writeFile ("%s/Xreset", 0755, "%s",
+    writeFile ("%s/Xreset.sample", 0755, "%s",
 "#!/bin/sh\n"
 "# Xreset - run as root after session exits\n"
 "\n"
@@ -1628,12 +1628,12 @@
 #endif
 "\n"
 "#exec sessreg -d -l $DISPLAY "
-#ifdef BSD
+#if defined(BSD) || defined(__FreeBSD__)
 "-x " KDMCONF "/Xservers "
 #endif
 "$USER\n"
 );
-    writeFile ("%s/Xsession", 0755, "%s",
+    writeFile ("%s/Xsession.sample", 0755, "%s",
 "#!/bin/sh\n"
 "# Xsession - run as user\n"
 "\n"
@@ -1781,7 +1781,7 @@
     }
     addKdePath ("UserPath", DEF_USER_PATH);
     addKdePath ("SystemPath", DEF_SYSTEM_PATH);
-    ASPrintf (&newkdmrc, "%s/kdmrc", newdir);
+    ASPrintf (&newkdmrc, "%s/kdmrc.sample", newdir);
     f = Create (newkdmrc, kdmrcmode);
     wrconf (f);
     fclose (f);


================================================================
                       SASAKI Katuhiro

                mailto: sahiro@crest.ocn.ne.jp
================================================================

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-ports" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3be4cd83.6480%sahiro>