annotate src/create-install-dirs.pl @ 9:a0c0ccd22ca5

progress on setuid wrapper script.
author Robert McIntyre <rlm@mit.edu>
date Wed, 09 Jan 2013 04:53:59 +0000
parents fe56b4698cf8
children
rev   line source
rlm@4 1 #!/usr/bin/env perl
rlm@4 2
rlm@4 3 @create_install_cmd =
rlm@4 4 ("groupadd", "--force", "install");
rlm@4 5 print "@create_install_cmd\n";
rlm@4 6 system(@create_install_cmd) and die $!;
rlm@4 7
rlm@4 8 sub create_install_dir{
rlm@4 9 @install_cmd =
rlm@4 10 ("install", "-d", "-m",
rlm@4 11 "775", "-o", "root", "-g",
rlm@4 12 "install", $_[0]);
rlm@4 13 print "@install_cmd\n";
rlm@4 14 system(@install_cmd) and die $!;}
rlm@4 15
rlm@4 16 @install_dirs = qw(
rlm@4 17 /usr/bin
rlm@4 18 /usr/sbin
rlm@4 19 /usr/include
rlm@4 20 /usr/lib
rlm@4 21 /usr/man/man1
rlm@4 22 /usr/man/man2
rlm@4 23 /usr/man/man3
rlm@4 24 /usr/man/man4
rlm@4 25 /usr/man/man5
rlm@4 26 /usr/man/man6
rlm@4 27 /usr/man/man7
rlm@4 28 /usr/man/man8
rlm@4 29 /usr/doc
rlm@4 30 /usr/info
rlm@4 31 /usr/local/man/man1
rlm@4 32 /usr/local/man/man2
rlm@4 33 /usr/local/man/man3
rlm@4 34 /usr/local/man/man4
rlm@4 35 /usr/local/man/man5
rlm@4 36 /usr/local/man/man6
rlm@4 37 /usr/local/man/man7
rlm@4 38 /usr/local/man/man8
rlm@4 39 /usr/local/doc
rlm@4 40 /usr/local/info
rlm@4 41 /usr/share
rlm@4 42 /usr/share/dict
rlm@4 43 /usr/share/doc
rlm@4 44 /usr/share/info
rlm@4 45 /usr/share/locale
rlm@4 46 /usr/share/man/man1
rlm@4 47 /usr/share/man/man2
rlm@4 48 /usr/share/man/man3
rlm@4 49 /usr/share/man/man4
rlm@4 50 /usr/share/man/man5
rlm@4 51 /usr/share/man/man6
rlm@4 52 /usr/share/man/man7
rlm@4 53 /usr/share/man/man8
rlm@4 54 /usr/share/nls
rlm@4 55 /usr/share/misc
rlm@4 56 /usr/share/terminfo
rlm@4 57 /usr/share/zoneinfo
rlm@4 58 /usr/share/i18n
rlm@4 59 /usr/share/aclocal
rlm@4 60 /usr/local/bin
rlm@4 61 /usr/local/etc
rlm@4 62 /usr/local/include
rlm@4 63 /usr/local/lib
rlm@4 64 /usr/local/sbin
rlm@4 65 /usr/local/share
rlm@4 66 /usr/local/share/dict
rlm@4 67 /usr/local/share/doc
rlm@4 68 /usr/local/share/info
rlm@4 69 /usr/local/share/locale
rlm@4 70 /usr/local/share/man/man1
rlm@4 71 /usr/local/share/man/man2
rlm@4 72 /usr/local/share/man/man3
rlm@4 73 /usr/local/share/man/man4
rlm@4 74 /usr/local/share/man/man5
rlm@4 75 /usr/local/share/man/man6
rlm@4 76 /usr/local/share/man/man7
rlm@4 77 /usr/local/share/man/man8
rlm@4 78 /usr/local/share/nls
rlm@4 79 /usr/local/share/misc
rlm@4 80 /usr/local/share/terminfo
rlm@4 81 /usr/local/share/zoneinfo
rlm@4 82 /opt
rlm@4 83 /opt/doc
rlm@4 84 /opt/info
rlm@4 85 /opt/bin
rlm@4 86 /opt/include
rlm@4 87 /opt/lib
rlm@4 88 /opt/man/man1
rlm@4 89 /opt/man/man2
rlm@4 90 /opt/man/man3
rlm@4 91 /opt/man/man4
rlm@4 92 /opt/man/man5
rlm@4 93 /opt/man/man6
rlm@4 94 /opt/man/man7
rlm@4 95 /opt/man/man8
rlm@4 96 /var/lib
rlm@4 97 /var/opt
rlm@4 98 /etc
rlm@4 99 /etc/opt
rlm@4 100 /sbin
rlm@4 101 /bin
rlm@4 102 /lib);
rlm@4 103
rlm@4 104 foreach $install_dir(@install_dirs){
rlm@4 105 create_install_dir($install_dir);}
rlm@4 106