fixed. Support buulding in 1 binary
This commit is contained in:
parent
f8dd7660ae
commit
7d0207ace2
58 changed files with 251 additions and 434 deletions
60
configs/config.h
Normal file
60
configs/config.h
Normal file
|
@ -0,0 +1,60 @@
|
|||
#ifndef _CONFIG_H
|
||||
#define _CONFIG_H
|
||||
|
||||
/* (cat tee wc xargs rev split cp) text buffer */
|
||||
#define BUF_SIZE 32000
|
||||
|
||||
#ifdef _SHRED_C
|
||||
/* source of random (shred) */
|
||||
#define RAND_SOURCE "/dev/urandom"
|
||||
#endif
|
||||
|
||||
#ifdef _HEAD_C
|
||||
/* format for printf (head) */
|
||||
#define HEAD_FMT "==> %s <==\n"
|
||||
#endif
|
||||
|
||||
#ifdef _PW_CHECK_H
|
||||
/* Pw_check. Salt for crypt() */
|
||||
int MU_SALT_ENC[] = {'s', 'a', 'l', 't'};
|
||||
char MU_SALT_BUF[sizeof(MU_SALT_ENC) + 1];
|
||||
#endif
|
||||
|
||||
#ifdef _MOUNT_C
|
||||
/* mount config */
|
||||
#define MOUNT_CFG "/etc/fstab"
|
||||
#define MOUNT_DEF_FS "ext4"
|
||||
#define MOUNT_LIST "/proc/mounts"
|
||||
#define MOUNT_OPT_SIZE 512
|
||||
#endif
|
||||
|
||||
#ifdef _LS_C
|
||||
/* colors for ls */
|
||||
#define LS_DIR_COLOR "\033[1;34m"
|
||||
#define LS_LINK_COLOR "\033[1;35m"
|
||||
#define LS_SOCK_COLOR "\033[35m"
|
||||
#define LS_FIFO_COLOR "\033[1;35m"
|
||||
#define LS_BLOCK_COLOR "\033[1;33m"
|
||||
#define LS_EXE_COLOR "\033[1;32m"
|
||||
#endif
|
||||
|
||||
#ifdef INIT
|
||||
/* Init scripts */
|
||||
char *INIT_POWEROFF[] = {"/etc/rc.poweroff", NULL};
|
||||
char *INIT_START[] = {"/etc/rc.init", NULL};
|
||||
#define INIT_MSG "Starting micro-init..."
|
||||
#endif
|
||||
|
||||
#ifdef _UNAME_C
|
||||
/* Os name for uname */
|
||||
/* #define OS_NAME "unknow" */
|
||||
#endif
|
||||
|
||||
/* Options: To disable, comment line */
|
||||
|
||||
/* getloadavg() unavailable in android */
|
||||
#ifndef __ANDROID__
|
||||
#define UPTIME_LOADAVG
|
||||
#endif
|
||||
|
||||
#endif
|
|
@ -1,4 +0,0 @@
|
|||
NAME="Plain Os"
|
||||
ID=plainos
|
||||
VERSION_ID=0.1
|
||||
PRETTY_NAME="PlainOs/Linux 0.1 "
|
|
@ -1,9 +0,0 @@
|
|||
#!/bin/sh
|
||||
echo "[*] Mounting..."
|
||||
mount -a
|
||||
|
||||
echo "[*] Hostname..."
|
||||
hostname -c /etc/hostname
|
||||
|
||||
cat /etc/motd
|
||||
env TERM="linux" login
|
|
@ -1,14 +0,0 @@
|
|||
#!/bin/sh
|
||||
#FIXME!!!
|
||||
|
||||
echo "[*] Umounting..."
|
||||
umount -a
|
||||
|
||||
echo "[*] Syncing..."
|
||||
sync
|
||||
|
||||
echo "[*] Closing processes..."
|
||||
kill -a -s TERM
|
||||
sleep 5
|
||||
|
||||
echo "[*] Poweroff..."
|
Loading…
Add table
Add a link
Reference in a new issue