1/* 2 * 3 * FreeBSD install - a package for the installation and maintainance 4 * of non-core utilities. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 5 unchanged lines hidden (view full) --- 14 * 15 * Jordan K. Hubbard 16 * 18 July 1993 17 * 18 * This is the add module. 19 */ 20 21#include <sys/cdefs.h> |
22__FBSDID("$FreeBSD: head/usr.sbin/pkg_install/add/main.c 173513 2007-11-10 09:40:39Z krion $"); |
23 24#include <err.h> 25#include <sys/param.h> 26#include <sys/utsname.h> 27#include "lib.h" 28#include "add.h" 29 |
30static char Options[] = "hviIRfFnrp:P:SMt:C:K"; |
31 32char *Prefix = NULL; 33Boolean PrefixRecursive = FALSE; 34char *Chroot = NULL; 35Boolean NoInstall = FALSE; 36Boolean NoRecord = FALSE; 37Boolean Remote = FALSE; 38Boolean KeepPackage = FALSE; 39Boolean FailOnAlreadyInstalled = TRUE; |
40Boolean IgnoreDeps = FALSE; |
41 42char *Mode = NULL; 43char *Owner = NULL; 44char *Group = NULL; 45char *PkgName = NULL; 46char *PkgAddCmd = NULL; 47char *Directory = NULL; 48char FirstPen[FILENAME_MAX]; --- 114 unchanged lines hidden (view full) --- 163 164 case 'M': 165 AddMode = MASTER; 166 break; 167 168 case 'C': 169 Chroot = optarg; 170 break; |
171 case 'i': 172 IgnoreDeps = TRUE; 173 break; |
174 175 case 'h': 176 case '?': 177 default: 178 usage(); 179 break; 180 } 181 } --- 139 unchanged lines hidden (view full) --- 321 return sitepath; 322 323} 324 325static void 326usage() 327{ 328 fprintf(stderr, "%s\n%s\n", |
329 "usage: pkg_add [-viInfFrRMSK] [-t template] [-p prefix] [-P prefix] [-C chrootdir]", |
330 " pkg-name [pkg-name ...]"); 331 exit(1); 332} |