nrelease - Provide default /etc/X11, better rc.conf
authorMatthew Dillon <dillon@apollo.backplane.com>
Mon, 25 Oct 2010 22:12:06 +0000 (15:12 -0700)
committerMatthew Dillon <dillon@apollo.backplane.com>
Mon, 25 Oct 2010 22:12:06 +0000 (15:12 -0700)
* Don't make users agonize over /etc/X11, provide one even if we aren't
  the gui.  Also provide it in /etc.hdd so it gets installed onto the
  HD.

* This also fixes the problem where the gui install was failing to install
  /etc/X11 onto the HD.

* The normal and gui installs were not installing reasonable rc.conf
  defaults.  Do so.

nrelease/Makefile
nrelease/gui/etc.hdd/issue [new file with mode: 0644]
nrelease/gui/etc.hdd/rc.conf [new file with mode: 0644]
nrelease/root/etc.hdd/X11/xorg.conf [new file with mode: 0644]
nrelease/root/etc.hdd/rc.conf [new file with mode: 0644]

index 2fca0d8..ccbc478 100644 (file)
@@ -374,15 +374,21 @@ customizeiso:
        rm -f ${ISOROOT}/etc/resolv.conf
        ${CHROOT_CMD} /etc/periodic/weekly/310.locate
        umount ${ISOROOT}/dev
-
-       # no iso is generated for gui builds, just img.
        #
+       # Recopy files that pkgsrc may have updated in /etc into /etc.hdd
+       #
+       cpdup ${ISOROOT}/etc/shells ${ISOROOT}/etc.hdd/shells
+       cpdup ${ISOROOT}/etc/group ${ISOROOT}/etc.hdd/group
+
+# no iso is generated for gui builds, just img.
+#
 mkiso:
 .if !make(gui)
        ( cd ${ISOROOT}; ${PKGBIN_MKISOFS} -b boot/cdboot -no-emul-boot \
                -R -J -o ${ISOFILE} \
                -V "DragonFly `${.CURDIR}/../tools/gitrev.sh | cut -c -22`" . )
 .endif
+       @exit 0
 
 mkimg:
        if [ ! -d ${IMGMNT} ]; then mkdir -p ${IMGMNT}; fi
diff --git a/nrelease/gui/etc.hdd/issue b/nrelease/gui/etc.hdd/issue
new file mode 100644 (file)
index 0000000..c5e5b62
--- /dev/null
@@ -0,0 +1,3 @@
+Welcome to DragonFly!
+
+Login as root to get a shell prompt, and then run startx to start X.
diff --git a/nrelease/gui/etc.hdd/rc.conf b/nrelease/gui/etc.hdd/rc.conf
new file mode 100644 (file)
index 0000000..e63510f
--- /dev/null
@@ -0,0 +1,16 @@
+# Basic rc.conf, adjust according to your needs
+#
+kern_securelevel_enable="NO"
+nfs_reserved_port_only="YES"
+sshd_enable="YES"
+usbd_enable="YES"
+syslogd_enable="YES"
+nfs_client_enable="YES"
+nfs_server_enable="NO"
+rpc_umntall_enable="NO"
+sendmail_enable="NO"
+cron_enable="YES"
+moused_enable="YES"
+# auto detect if not specified
+#moused_port="/dev/ums1"
+#moused_port="/dev/psm0"
diff --git a/nrelease/root/etc.hdd/X11/xorg.conf b/nrelease/root/etc.hdd/X11/xorg.conf
new file mode 100644 (file)
index 0000000..2af34ca
--- /dev/null
@@ -0,0 +1,60 @@
+# $DragonFly: src/nrelease/gui/etc/X11/xorg.conf,v 1.2 2008/09/01 21:20:30 swildner Exp $
+
+Section "ServerLayout"
+       Identifier      "Layout0"
+       Screen  0       "Screen0"       0       0
+       InputDevice     "Keyboard0"     "CoreKeyboard"
+       InputDevice     "Mouse0"        "CorePointer"
+EndSection
+
+Section "Files"
+       RgbPath      "/usr/pkg/share/X11/rgb"
+       ModulePath   "/usr/pkg/lib/xorg/modules"
+       FontPath     "/usr/pkg/lib/X11/fonts/misc/"
+       FontPath     "/usr/pkg/lib/X11/fonts/TTF/"
+       FontPath     "/usr/pkg/lib/X11/fonts/OTF"
+       FontPath     "/usr/pkg/lib/X11/fonts/Type1/"
+       FontPath     "/usr/pkg/lib/X11/fonts/100dpi/"
+       FontPath     "/usr/pkg/lib/X11/fonts/75dpi/"
+EndSection
+
+Section "Module"
+       Load "dbe"
+       Load "glx"
+       Load "freetype"
+       Load "extmod"
+EndSection
+
+Section "InputDevice"
+       Identifier  "Keyboard0"
+       Driver      "kbd"
+       Option      "XkbOptions" "ctrl:nocaps"
+EndSection
+
+Section "InputDevice"
+       Identifier  "Mouse0"
+       Driver      "mouse"
+       Option      "Protocol" "auto"
+       Option      "Device" "/dev/sysmouse"
+       Option      "ZAxisMapping" "4 5 6 7"
+EndSection
+
+Section "Monitor"
+       Identifier      "Monitor0"
+       Option          "DPMS"
+EndSection
+
+Section "Device"
+       Identifier      "Card0"
+       Driver          "vesa"
+EndSection
+
+Section "Screen"
+       Identifier "Screen0"
+       Device     "Card0"
+       Monitor    "Monitor0"
+       DefaultDepth 24
+       SubSection "Display"
+               Depth     24
+       EndSubSection
+EndSection
diff --git a/nrelease/root/etc.hdd/rc.conf b/nrelease/root/etc.hdd/rc.conf
new file mode 100644 (file)
index 0000000..14bdd6e
--- /dev/null
@@ -0,0 +1,12 @@
+# Basic rc.conf, adjust according to your needs
+#
+kern_securelevel_enable="NO"
+nfs_reserved_port_only="YES"
+sshd_enable="YES"
+usbd_enable="YES"
+syslogd_enable="YES"
+nfs_client_enable="YES"
+nfs_server_enable="NO"
+rpc_umntall_enable="NO"
+sendmail_enable="NO"
+cron_enable="YES"