-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathchange-pathnames.patch
148 lines (127 loc) · 5.1 KB
/
change-pathnames.patch
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
diff --git a/include/pathnames.h b/include/pathnames.h
index 56f64c387..1608e54a2 100644
--- a/include/pathnames.h
+++ b/include/pathnames.h
@@ -20,76 +20,76 @@
#undef _PATH_DEFPATH
#ifdef USE_USRDIR_PATHS_ONLY
-# define _PATH_DEFPATH "/usr/local/bin:/usr/bin"
+# define _PATH_DEFPATH "/data/usr/local/bin:/data/usr/bin:/product/bin:/system_ext/bin:/system/bin:/odm/bin:/vendor/bin"
#else
-# define _PATH_DEFPATH "/usr/local/bin:/bin:/usr/bin"
+# define _PATH_DEFPATH "/data/usr/local/bin:/data/usr/bin:/product/bin:/system_ext/bin:/system/bin:/odm/bin:/vendor/bin"
#endif
#undef _PATH_DEFPATH_ROOT
#ifdef USE_USRDIR_PATHS_ONLY
-# define _PATH_DEFPATH_ROOT "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin"
+# define _PATH_DEFPATH_ROOT "/data/usr/local/bin:/data/usr/bin:/product/bin:/system_ext/bin:/system/bin:/odm/bin:/vendor/bin"
#else
-# define _PATH_DEFPATH_ROOT "/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin"
+# define _PATH_DEFPATH_ROOT "/data/usr/local/bin:/data/usr/bin:/product/bin:/system_ext/bin:/system/bin:/odm/bin:/vendor/bin"
#endif
#define _PATH_HUSHLOGIN ".hushlogin"
-#define _PATH_HUSHLOGINS "/etc/hushlogins"
+#define _PATH_HUSHLOGINS "/data/etc/hushlogins"
-#define _PATH_NOLOGIN_TXT "/etc/nologin.txt"
+#define _PATH_NOLOGIN_TXT "/data/etc/nologin.txt"
#ifndef _PATH_MAILDIR
-# define _PATH_MAILDIR "/var/spool/mail"
+# define _PATH_MAILDIR "/data/var/spool/mail"
#endif
-#define _PATH_MOTDFILE "/usr/share/misc/motd:/run/motd:/etc/motd"
+#define _PATH_MOTDFILE "/data/usr/share/misc/motd:/data/var/run/motd:/data/etc/motd"
#ifndef _PATH_NOLOGIN
-# define _PATH_NOLOGIN "/etc/nologin"
+# define _PATH_NOLOGIN "/data/etc/nologin"
#endif
-#define _PATH_VAR_NOLOGIN "/var/run/nologin"
+#define _PATH_VAR_NOLOGIN "/data/var/run/nologin"
#ifndef _PATH_LOGIN
-# define _PATH_LOGIN "/bin/login"
+# define _PATH_LOGIN "/data/usr/bin/login"
#endif
-#define _PATH_SHUTDOWN "/sbin/shutdown"
-#define _PATH_POWEROFF "/sbin/poweroff"
+#define _PATH_SHUTDOWN "/data/usr/bin/shutdown"
+#define _PATH_POWEROFF "/data/usr/bin/poweroff"
#define _PATH_TERMCOLORS_DIRNAME "terminal-colors.d"
-#define _PATH_TERMCOLORS_DIR "/etc/" _PATH_TERMCOLORS_DIRNAME
+#define _PATH_TERMCOLORS_DIR "/data/etc/" _PATH_TERMCOLORS_DIRNAME
/* login paths */
-#define _PATH_PASSWD "/etc/passwd"
-#define _PATH_GSHADOW "/etc/gshadow"
-#define _PATH_GROUP "/etc/group"
-#define _PATH_SHADOW_PASSWD "/etc/shadow"
-#define _PATH_SHELLS "/etc/shells"
+#define _PATH_PASSWD "/data/etc/passwd"
+#define _PATH_GSHADOW "/data/etc/gshadow"
+#define _PATH_GROUP "/data/etc/group"
+#define _PATH_SHADOW_PASSWD "/data/etc/shadow"
+#define _PATH_SHELLS "/data/etc/shells"
#ifndef _PATH_TMP
-# define _PATH_TMP "/tmp/"
+# define _PATH_TMP "/data/local/tmp/"
#endif
#ifndef _PATH_BTMP
-# define _PATH_BTMP "/var/log/btmp"
+# define _PATH_BTMP "/data/var/log/btmp"
#endif
#define _PATH_ISSUE_FILENAME "issue"
#define _PATH_ISSUE_DIRNAME _PATH_ISSUE_FILENAME ".d"
-#define _PATH_ISSUE "/etc/" _PATH_ISSUE_FILENAME
-#define _PATH_ISSUEDIR "/etc/" _PATH_ISSUE_DIRNAME
+#define _PATH_ISSUE "/data/etc/" _PATH_ISSUE_FILENAME
+#define _PATH_ISSUEDIR "/data/etc/" _PATH_ISSUE_DIRNAME
-#define _PATH_OS_RELEASE_ETC "/etc/os-release"
-#define _PATH_OS_RELEASE_USR "/usr/lib/os-release"
+#define _PATH_OS_RELEASE_ETC "/data/etc/os-release"
+#define _PATH_OS_RELEASE_USR "/data/usr/lib/os-release"
#define _PATH_NUMLOCK_ON _PATH_RUNSTATEDIR "/numlock-on"
-#define _PATH_LOGINDEFS "/etc/login.defs"
+#define _PATH_LOGINDEFS "/data/etc/login.defs"
#define _PATH_SD_UNITSLOAD _PATH_RUNSTATEDIR "/systemd/systemd-units-load"
/* misc paths */
-#define _PATH_WORDS "/usr/share/dict/words"
-#define _PATH_WORDS_ALT "/usr/share/dict/web2"
+#define _PATH_WORDS "/data/usr/share/dict/words"
+#define _PATH_WORDS_ALT "/data/usr/share/dict/web2"
/* mount paths */
-#define _PATH_FILESYSTEMS "/etc/filesystems"
+#define _PATH_FILESYSTEMS "/data/etc/filesystems"
#define _PATH_PROC "/proc"
#define _PATH_PROC_SWAPS "/proc/swaps"
#define _PATH_PROC_FILESYSTEMS "/proc/filesystems"
@@ -101,8 +101,8 @@
#define _PATH_PROC_CDROMINFO "/proc/sys/dev/cdrom/info"
/* unshare paths */
-#define _PATH_SUBUID "/etc/subuid"
-#define _PATH_SUBGID "/etc/subgid"
+#define _PATH_SUBUID "/data/etc/subuid"
+#define _PATH_SUBGID "/data/etc/subgid"
#define _PATH_PROC_UIDMAP "/proc/self/uid_map"
#define _PATH_PROC_GIDMAP "/proc/self/gid_map"
#define _PATH_PROC_SETGROUPS "/proc/self/setgroups"
@@ -129,7 +129,7 @@
# ifdef MOUNTED /* deprecated */
# define _PATH_MOUNTED MOUNTED
# else
-# define _PATH_MOUNTED "/etc/mtab"
+# define _PATH_MOUNTED "/data/etc/mtab"
# endif
#endif
@@ -137,7 +137,7 @@
# ifdef MNTTAB /* deprecated */
# define _PATH_MNTTAB MNTTAB
# else
-# define _PATH_MNTTAB "/etc/fstab"
+# define _PATH_MNTTAB "/data/etc/fstab"
# endif
#endif
@@ -167,7 +167,7 @@
#ifdef CONFIG_ADJTIME_PATH
# define _PATH_ADJTIME CONFIG_ADJTIME_PATH
#else
-# define _PATH_ADJTIME "/etc/adjtime"
+# define _PATH_ADJTIME "/data/etc/adjtime"
#endif
#ifdef __ia64__