1*ae115bc7Smrj /* 2*ae115bc7Smrj * CDDL HEADER START 3*ae115bc7Smrj * 4*ae115bc7Smrj * The contents of this file are subject to the terms of the 5*ae115bc7Smrj * Common Development and Distribution License, Version 1.0 only 6*ae115bc7Smrj * (the "License"). You may not use this file except in compliance 7*ae115bc7Smrj * with the License. 8*ae115bc7Smrj * 9*ae115bc7Smrj * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 10*ae115bc7Smrj * or http://www.opensolaris.org/os/licensing. 11*ae115bc7Smrj * See the License for the specific language governing permissions 12*ae115bc7Smrj * and limitations under the License. 13*ae115bc7Smrj * 14*ae115bc7Smrj * When distributing Covered Code, include this CDDL HEADER in each 15*ae115bc7Smrj * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 16*ae115bc7Smrj * If applicable, add the following below this CDDL HEADER, with the 17*ae115bc7Smrj * fields enclosed by brackets "[]" replaced with your own identifying 18*ae115bc7Smrj * information: Portions Copyright [yyyy] [name of copyright owner] 19*ae115bc7Smrj * 20*ae115bc7Smrj * CDDL HEADER END 21*ae115bc7Smrj */ 22*ae115bc7Smrj /* 23*ae115bc7Smrj * Copyright 2004 Sun Microsystems, Inc. All rights reserved. 24*ae115bc7Smrj * Use is subject to license terms. 25*ae115bc7Smrj */ 26*ae115bc7Smrj 27*ae115bc7Smrj #ifndef _BENV_H 28*ae115bc7Smrj #define _BENV_H 29*ae115bc7Smrj 30*ae115bc7Smrj #pragma ident "%Z%%M% %I% %E% SMI" 31*ae115bc7Smrj 32*ae115bc7Smrj #ifdef __cplusplus 33*ae115bc7Smrj extern "C" { 34*ae115bc7Smrj #endif 35*ae115bc7Smrj 36*ae115bc7Smrj #include <errno.h> 37*ae115bc7Smrj #include <fcntl.h> 38*ae115bc7Smrj #include <memory.h> 39*ae115bc7Smrj #include <stdio.h> 40*ae115bc7Smrj #include <stdlib.h> 41*ae115bc7Smrj #include <string.h> 42*ae115bc7Smrj #include <sys/utsname.h> 43*ae115bc7Smrj 44*ae115bc7Smrj #define NO_PERROR 0 45*ae115bc7Smrj #define PERROR 1 46*ae115bc7Smrj 47*ae115bc7Smrj typedef struct eplist { 48*ae115bc7Smrj struct eplist *next; 49*ae115bc7Smrj struct eplist *prev; 50*ae115bc7Smrj void *item; 51*ae115bc7Smrj } eplist_t; 52*ae115bc7Smrj 53*ae115bc7Smrj extern char *progname; 54*ae115bc7Smrj extern char *boottree; 55*ae115bc7Smrj extern struct utsname uts_buf; 56*ae115bc7Smrj extern int _error(int do_perror, char *fmt, ...); 57*ae115bc7Smrj extern char *strcats(char *s, ...); 58*ae115bc7Smrj extern eplist_t *new_list(void); 59*ae115bc7Smrj extern void add_item(void *item, eplist_t *list); 60*ae115bc7Smrj 61*ae115bc7Smrj #ifdef __cplusplus 62*ae115bc7Smrj } 63*ae115bc7Smrj #endif 64*ae115bc7Smrj 65*ae115bc7Smrj #endif /* _BENV_H */ 66