mirror of
https://github.com/sheumann/hush.git
synced 2024-12-24 12:29:47 +00:00
modutils/*: move applet bits into corresponding *.c files
Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
This commit is contained in:
parent
f2710d0221
commit
c15613c975
@ -103,8 +103,6 @@ IF_DD(APPLET_NOEXEC(dd, dd, _BB_DIR_BIN, _BB_SUID_DROP, dd))
|
|||||||
IF_DEALLOCVT(APPLET(deallocvt, _BB_DIR_USR_BIN, _BB_SUID_DROP))
|
IF_DEALLOCVT(APPLET(deallocvt, _BB_DIR_USR_BIN, _BB_SUID_DROP))
|
||||||
IF_DELGROUP(APPLET_ODDNAME(delgroup, deluser, _BB_DIR_BIN, _BB_SUID_DROP, delgroup))
|
IF_DELGROUP(APPLET_ODDNAME(delgroup, deluser, _BB_DIR_BIN, _BB_SUID_DROP, delgroup))
|
||||||
IF_DELUSER(APPLET(deluser, _BB_DIR_BIN, _BB_SUID_DROP))
|
IF_DELUSER(APPLET(deluser, _BB_DIR_BIN, _BB_SUID_DROP))
|
||||||
IF_DEPMOD(APPLET(depmod, _BB_DIR_SBIN, _BB_SUID_DROP))
|
|
||||||
IF_MODPROBE_SMALL(APPLET_ODDNAME(depmod, modprobe, _BB_DIR_SBIN, _BB_SUID_DROP, modprobe))
|
|
||||||
IF_DEVFSD(APPLET(devfsd, _BB_DIR_SBIN, _BB_SUID_DROP))
|
IF_DEVFSD(APPLET(devfsd, _BB_DIR_SBIN, _BB_SUID_DROP))
|
||||||
IF_DEVMEM(APPLET(devmem, _BB_DIR_SBIN, _BB_SUID_DROP))
|
IF_DEVMEM(APPLET(devmem, _BB_DIR_SBIN, _BB_SUID_DROP))
|
||||||
IF_DF(APPLET(df, _BB_DIR_BIN, _BB_SUID_DROP))
|
IF_DF(APPLET(df, _BB_DIR_BIN, _BB_SUID_DROP))
|
||||||
@ -179,8 +177,6 @@ IF_IFPLUGD(APPLET(ifplugd, _BB_DIR_USR_BIN, _BB_SUID_DROP))
|
|||||||
IF_IFUPDOWN(APPLET_ODDNAME(ifup, ifupdown, _BB_DIR_SBIN, _BB_SUID_DROP, ifup))
|
IF_IFUPDOWN(APPLET_ODDNAME(ifup, ifupdown, _BB_DIR_SBIN, _BB_SUID_DROP, ifup))
|
||||||
IF_INETD(APPLET(inetd, _BB_DIR_USR_SBIN, _BB_SUID_DROP))
|
IF_INETD(APPLET(inetd, _BB_DIR_USR_SBIN, _BB_SUID_DROP))
|
||||||
IF_INOTIFYD(APPLET(inotifyd, _BB_DIR_SBIN, _BB_SUID_DROP))
|
IF_INOTIFYD(APPLET(inotifyd, _BB_DIR_SBIN, _BB_SUID_DROP))
|
||||||
IF_INSMOD(APPLET(insmod, _BB_DIR_SBIN, _BB_SUID_DROP))
|
|
||||||
IF_MODPROBE_SMALL(APPLET_ODDNAME(insmod, modprobe, _BB_DIR_SBIN, _BB_SUID_DROP, modprobe))
|
|
||||||
IF_INSTALL(APPLET(install, _BB_DIR_USR_BIN, _BB_SUID_DROP))
|
IF_INSTALL(APPLET(install, _BB_DIR_USR_BIN, _BB_SUID_DROP))
|
||||||
IF_IONICE(APPLET(ionice, _BB_DIR_BIN, _BB_SUID_DROP))
|
IF_IONICE(APPLET(ionice, _BB_DIR_BIN, _BB_SUID_DROP))
|
||||||
#if ENABLE_FEATURE_IP_ADDRESS \
|
#if ENABLE_FEATURE_IP_ADDRESS \
|
||||||
@ -222,8 +218,6 @@ IF_LPQ(APPLET_ODDNAME(lpq, lpqr, _BB_DIR_USR_BIN, _BB_SUID_DROP, lpq))
|
|||||||
IF_LPR(APPLET_ODDNAME(lpr, lpqr, _BB_DIR_USR_BIN, _BB_SUID_DROP, lpr))
|
IF_LPR(APPLET_ODDNAME(lpr, lpqr, _BB_DIR_USR_BIN, _BB_SUID_DROP, lpr))
|
||||||
IF_LS(APPLET_NOEXEC(ls, ls, _BB_DIR_BIN, _BB_SUID_DROP, ls))
|
IF_LS(APPLET_NOEXEC(ls, ls, _BB_DIR_BIN, _BB_SUID_DROP, ls))
|
||||||
IF_LSATTR(APPLET(lsattr, _BB_DIR_BIN, _BB_SUID_DROP))
|
IF_LSATTR(APPLET(lsattr, _BB_DIR_BIN, _BB_SUID_DROP))
|
||||||
IF_LSMOD(APPLET(lsmod, _BB_DIR_SBIN, _BB_SUID_DROP))
|
|
||||||
IF_MODPROBE_SMALL(APPLET_ODDNAME(lsmod, modprobe, _BB_DIR_SBIN, _BB_SUID_DROP, modprobe))
|
|
||||||
IF_LSPCI(APPLET(lspci, _BB_DIR_USR_BIN, _BB_SUID_DROP))
|
IF_LSPCI(APPLET(lspci, _BB_DIR_USR_BIN, _BB_SUID_DROP))
|
||||||
IF_LSUSB(APPLET(lsusb, _BB_DIR_USR_BIN, _BB_SUID_DROP))
|
IF_LSUSB(APPLET(lsusb, _BB_DIR_USR_BIN, _BB_SUID_DROP))
|
||||||
IF_UNLZMA(APPLET_ODDNAME(lzcat, unlzma, _BB_DIR_USR_BIN, _BB_SUID_DROP, lzcat))
|
IF_UNLZMA(APPLET_ODDNAME(lzcat, unlzma, _BB_DIR_USR_BIN, _BB_SUID_DROP, lzcat))
|
||||||
@ -250,8 +244,6 @@ IF_MKNOD(APPLET_NOEXEC(mknod, mknod, _BB_DIR_BIN, _BB_SUID_DROP, mknod))
|
|||||||
IF_CRYPTPW(APPLET_ODDNAME(mkpasswd, cryptpw, _BB_DIR_USR_BIN, _BB_SUID_DROP, mkpasswd))
|
IF_CRYPTPW(APPLET_ODDNAME(mkpasswd, cryptpw, _BB_DIR_USR_BIN, _BB_SUID_DROP, mkpasswd))
|
||||||
IF_MKSWAP(APPLET(mkswap, _BB_DIR_SBIN, _BB_SUID_DROP))
|
IF_MKSWAP(APPLET(mkswap, _BB_DIR_SBIN, _BB_SUID_DROP))
|
||||||
IF_MKTEMP(APPLET(mktemp, _BB_DIR_BIN, _BB_SUID_DROP))
|
IF_MKTEMP(APPLET(mktemp, _BB_DIR_BIN, _BB_SUID_DROP))
|
||||||
IF_MODPROBE(APPLET(modprobe, _BB_DIR_SBIN, _BB_SUID_DROP))
|
|
||||||
IF_MODPROBE_SMALL(APPLET(modprobe, _BB_DIR_SBIN, _BB_SUID_DROP))
|
|
||||||
IF_MORE(APPLET(more, _BB_DIR_BIN, _BB_SUID_DROP))
|
IF_MORE(APPLET(more, _BB_DIR_BIN, _BB_SUID_DROP))
|
||||||
IF_MOUNT(APPLET(mount, _BB_DIR_BIN, IF_DESKTOP(_BB_SUID_MAYBE) IF_NOT_DESKTOP(_BB_SUID_DROP)))
|
IF_MOUNT(APPLET(mount, _BB_DIR_BIN, IF_DESKTOP(_BB_SUID_MAYBE) IF_NOT_DESKTOP(_BB_SUID_DROP)))
|
||||||
IF_MOUNTPOINT(APPLET(mountpoint, _BB_DIR_BIN, _BB_SUID_DROP))
|
IF_MOUNTPOINT(APPLET(mountpoint, _BB_DIR_BIN, _BB_SUID_DROP))
|
||||||
@ -298,8 +290,6 @@ IF_RESTORECON(APPLET_ODDNAME(restorecon, setfiles, _BB_DIR_SBIN, _BB_SUID_DROP,
|
|||||||
IF_RFKILL(APPLET(rfkill, _BB_DIR_USR_SBIN, _BB_SUID_DROP))
|
IF_RFKILL(APPLET(rfkill, _BB_DIR_USR_SBIN, _BB_SUID_DROP))
|
||||||
IF_RM(APPLET_NOFORK(rm, rm, _BB_DIR_BIN, _BB_SUID_DROP, rm))
|
IF_RM(APPLET_NOFORK(rm, rm, _BB_DIR_BIN, _BB_SUID_DROP, rm))
|
||||||
IF_RMDIR(APPLET_NOFORK(rmdir, rmdir, _BB_DIR_BIN, _BB_SUID_DROP, rmdir))
|
IF_RMDIR(APPLET_NOFORK(rmdir, rmdir, _BB_DIR_BIN, _BB_SUID_DROP, rmdir))
|
||||||
IF_RMMOD(APPLET(rmmod, _BB_DIR_SBIN, _BB_SUID_DROP))
|
|
||||||
IF_MODPROBE_SMALL(APPLET_ODDNAME(rmmod, modprobe, _BB_DIR_SBIN, _BB_SUID_DROP, modprobe))
|
|
||||||
IF_ROUTE(APPLET(route, _BB_DIR_SBIN, _BB_SUID_DROP))
|
IF_ROUTE(APPLET(route, _BB_DIR_SBIN, _BB_SUID_DROP))
|
||||||
IF_RPM(APPLET(rpm, _BB_DIR_BIN, _BB_SUID_DROP))
|
IF_RPM(APPLET(rpm, _BB_DIR_BIN, _BB_SUID_DROP))
|
||||||
IF_RPM2CPIO(APPLET(rpm2cpio, _BB_DIR_USR_BIN, _BB_SUID_DROP))
|
IF_RPM2CPIO(APPLET(rpm2cpio, _BB_DIR_USR_BIN, _BB_SUID_DROP))
|
||||||
|
@ -8,6 +8,8 @@
|
|||||||
* Licensed under GPLv2 or later, see file LICENSE in this source tree.
|
* Licensed under GPLv2 or later, see file LICENSE in this source tree.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
//applet:IF_DEPMOD(APPLET(depmod, _BB_DIR_SBIN, _BB_SUID_DROP))
|
||||||
|
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
#include "modutils.h"
|
#include "modutils.h"
|
||||||
#include <sys/utsname.h> /* uname() */
|
#include <sys/utsname.h> /* uname() */
|
||||||
|
@ -7,6 +7,8 @@
|
|||||||
* Licensed under GPLv2 or later, see file LICENSE in this source tree.
|
* Licensed under GPLv2 or later, see file LICENSE in this source tree.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
//applet:IF_INSMOD(APPLET(insmod, _BB_DIR_SBIN, _BB_SUID_DROP))
|
||||||
|
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
#include "modutils.h"
|
#include "modutils.h"
|
||||||
|
|
||||||
|
@ -7,6 +7,9 @@
|
|||||||
*
|
*
|
||||||
* Licensed under GPLv2 or later, see file LICENSE in this source tree.
|
* Licensed under GPLv2 or later, see file LICENSE in this source tree.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
//applet:IF_LSMOD(APPLET(lsmod, _BB_DIR_SBIN, _BB_SUID_DROP))
|
||||||
|
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
#include "unicode.h"
|
#include "unicode.h"
|
||||||
|
|
||||||
|
@ -8,6 +8,12 @@
|
|||||||
* Licensed under GPLv2, see file LICENSE in this source tree.
|
* Licensed under GPLv2, see file LICENSE in this source tree.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
//applet:IF_MODPROBE_SMALL(APPLET(modprobe, _BB_DIR_SBIN, _BB_SUID_DROP))
|
||||||
|
//applet:IF_MODPROBE_SMALL(APPLET_ODDNAME(depmod, modprobe, _BB_DIR_SBIN, _BB_SUID_DROP, modprobe))
|
||||||
|
//applet:IF_MODPROBE_SMALL(APPLET_ODDNAME(insmod, modprobe, _BB_DIR_SBIN, _BB_SUID_DROP, modprobe))
|
||||||
|
//applet:IF_MODPROBE_SMALL(APPLET_ODDNAME(lsmod, modprobe, _BB_DIR_SBIN, _BB_SUID_DROP, modprobe))
|
||||||
|
//applet:IF_MODPROBE_SMALL(APPLET_ODDNAME(rmmod, modprobe, _BB_DIR_SBIN, _BB_SUID_DROP, modprobe))
|
||||||
|
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
/* After libbb.h, since it needs sys/types.h on some systems */
|
/* After libbb.h, since it needs sys/types.h on some systems */
|
||||||
#include <sys/utsname.h> /* uname() */
|
#include <sys/utsname.h> /* uname() */
|
||||||
|
@ -8,17 +8,7 @@
|
|||||||
* Licensed under GPLv2 or later, see file LICENSE in this source tree.
|
* Licensed under GPLv2 or later, see file LICENSE in this source tree.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* Note that unlike older versions of modules.dep/depmod (busybox and m-i-t),
|
//applet:IF_MODPROBE(APPLET(modprobe, _BB_DIR_SBIN, _BB_SUID_DROP))
|
||||||
* we expect the full dependency list to be specified in modules.dep.
|
|
||||||
* Older versions would only export the direct dependency list.
|
|
||||||
*/
|
|
||||||
#include "libbb.h"
|
|
||||||
#include "modutils.h"
|
|
||||||
#include <sys/utsname.h>
|
|
||||||
#include <fnmatch.h>
|
|
||||||
|
|
||||||
//#define DBG(fmt, ...) bb_error_msg("%s: " fmt, __func__, ## __VA_ARGS__)
|
|
||||||
#define DBG(...) ((void)0)
|
|
||||||
|
|
||||||
//usage:#if !ENABLE_MODPROBE_SMALL
|
//usage:#if !ENABLE_MODPROBE_SMALL
|
||||||
//usage:#define modprobe_notes_usage
|
//usage:#define modprobe_notes_usage
|
||||||
@ -98,6 +88,19 @@
|
|||||||
//usage: )
|
//usage: )
|
||||||
//usage:#endif /* !ENABLE_MODPROBE_SMALL */
|
//usage:#endif /* !ENABLE_MODPROBE_SMALL */
|
||||||
|
|
||||||
|
#include "libbb.h"
|
||||||
|
#include "modutils.h"
|
||||||
|
#include <sys/utsname.h>
|
||||||
|
#include <fnmatch.h>
|
||||||
|
|
||||||
|
//#define DBG(fmt, ...) bb_error_msg("%s: " fmt, __func__, ## __VA_ARGS__)
|
||||||
|
#define DBG(...) ((void)0)
|
||||||
|
|
||||||
|
/* Note that unlike older versions of modules.dep/depmod (busybox and m-i-t),
|
||||||
|
* we expect the full dependency list to be specified in modules.dep.
|
||||||
|
* Older versions would only export the direct dependency list.
|
||||||
|
*/
|
||||||
|
|
||||||
/* Note that usage text doesn't document various 2.4 options
|
/* Note that usage text doesn't document various 2.4 options
|
||||||
* we pull in through INSMOD_OPTS define */
|
* we pull in through INSMOD_OPTS define */
|
||||||
|
|
||||||
|
@ -8,6 +8,8 @@
|
|||||||
* Licensed under GPLv2 or later, see file LICENSE in this source tree.
|
* Licensed under GPLv2 or later, see file LICENSE in this source tree.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
//applet:IF_RMMOD(APPLET(rmmod, _BB_DIR_SBIN, _BB_SUID_DROP))
|
||||||
|
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
#include "modutils.h"
|
#include "modutils.h"
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user