Open terminal in VT2 using openvt(1)

Signed-off-by: root <root@test.(none)>
This commit is contained in:
root committed 2008-05-15 17:37:51 -03:00
1 parent 4e18bc3724
commit f21b0a2580
2 files changed
+7 -6

No files matched your search

+4 -5
View File
@@ -49,7 +49,7 @@ THE SOFTWARE.
#ifdef DIST_MDV /* Mandriva */ #ifdef DIST_MDV /* Mandriva */
#define RANDOMSEED "/var/lib/random-seed" #define RANDOMSEED "/var/lib/random-seed"
#define SYSROOT "/sysroot" #define SYSROOT "/sysroot"
#define GETTY "/sbin/mingetty tty3" #define GETTY "/usr/bin/openvt /sbin/mingetty tty2"
#define RUNPARTS "/usr/bin/run-parts" #define RUNPARTS "/usr/bin/run-parts"
#define REMOUNT_ROOTFS_RW #define REMOUNT_ROOTFS_RW
#define MAKE_DEVICES #define MAKE_DEVICES
@@ -57,7 +57,7 @@ THE SOFTWARE.
#else /* original Eeepc distribution */ #else /* original Eeepc distribution */
#define RANDOMSEED "/var/lib/urandom/random-seed" #define RANDOMSEED "/var/lib/urandom/random-seed"
#define SYSROOT "/mnt" #define SYSROOT "/mnt"
#define GETTY "/sbin/getty 38400 tty3" #define GETTY "/usr/bin/openvt /sbin/getty 38400 tty2"
#define RUNPARTS "/bin/run-parts" #define RUNPARTS "/bin/run-parts"
#define TOUCH_ETC_NETWORK_RUN_IFSTATE #define TOUCH_ETC_NETWORK_RUN_IFSTATE
#endif #endif
@@ -240,8 +240,6 @@ int main()
chardev("/dev/mem", 0640, 1, 1); chardev("/dev/mem", 0640, 1, 1);
chmod("/dev/null", 0667); chmod("/dev/null", 0667);
chmod("/dev/mem", 0640); chmod("/dev/mem", 0640);
chardev("/dev/tty", 0666, 5, 0);
chardev("/dev/tty0", 0660, 4, 0);
chardev("/dev/input/mice", 0660, 13, 63); chardev("/dev/input/mice", 0660, 13, 63);
chardev("/dev/input/event0", 0660, 13, 64); chardev("/dev/input/event0", 0660, 13, 64);
chardev("/dev/agpgart", 0660, 10, 175); chardev("/dev/agpgart", 0660, 10, 175);
@@ -339,6 +337,8 @@ int main()
mkdir("/tmp/.ICE-unix", 01777); mkdir("/tmp/.ICE-unix", 01777);
umask(022); umask(022);
system(GETTY "&");
if (!fork()) { if (!fork()) {
/* child process */ /* child process */
@@ -392,7 +392,6 @@ int main()
/* parent process */ /* parent process */
system(GETTY "&");
sleep(1); sleep(1);
system("/usr/sbin/services.sh &>/dev/null&"); system("/usr/sbin/services.sh &>/dev/null&");
+3 -1
View File
@@ -44,6 +44,7 @@ Changelog from the original Eeepc fastinit:
- Use SIG_IGN instead of empty signal handler (by Metalshark) - Use SIG_IGN instead of empty signal handler (by Metalshark)
- Add built-in run-parts option to be used instead of system("run-parts") - Add built-in run-parts option to be used instead of system("run-parts")
- Reuse cmdline buffer as hostname and filename buffers - Reuse cmdline buffer as hostname and filename buffers
- Open terminal in vt2 using openvt
*/ */
@@ -229,6 +230,8 @@ int main()
mkdir("/tmp/.ICE-unix", 01777); mkdir("/tmp/.ICE-unix", 01777);
umask(022); umask(022);
system("/usr/bin/openvt /sbin/getty 38400 tty2&");
if (!fork()) { if (!fork()) {
/* child process */ /* child process */
@@ -265,7 +268,6 @@ int main()
/* parent process */ /* parent process */
system("/sbin/getty 38400 tty3&");
sleep(1); sleep(1);
system("/usr/sbin/services.sh &>/dev/null&"); system("/usr/sbin/services.sh &>/dev/null&");