1/* $NetBSD: create.h,v 1.14 2009/11/05 16:22:32 joerg Exp $ */
2
3/* from FreeBSD Id: create.h,v 1.13 1997/10/08 07:46:19 charnier Exp */
4
5/*
6 * FreeBSD install - a package for the installation and maintainance
7 * of non-core utilities.
8 *
9 * Redistribution and use in source and binary forms, with or without
10 * modification, are permitted provided that the following conditions
11 * are met:
12 * 1. Redistributions of source code must retain the above copyright
13 *    notice, this list of conditions and the following disclaimer.
14 * 2. Redistributions in binary form must reproduce the above copyright
15 *    notice, this list of conditions and the following disclaimer in the
16 *    documentation and/or other materials provided with the distribution.
17 *
18 * Jordan K. Hubbard
19 * 18 July 1993
20 *
21 * Include and define various things wanted by the create command.
22 *
23 */
24
25#ifndef _INST_CREATE_H_INCLUDE
26#define _INST_CREATE_H_INCLUDE
27
28struct memory_file {
29	struct stat st;
30	const char *name;
31	const char *owner;
32	const char *group;
33	mode_t mode;
34
35	char *data;
36	size_t len;
37};
38
39extern char *Prefix;
40extern char *Comment;
41extern char *Desc;
42extern char *Display;
43extern char *Install;
44extern char *DeInstall;
45extern char *Contents;
46extern char *Pkgdeps;
47extern char *BuildPkgdeps;
48extern char *Pkgcfl;
49extern char *BuildVersion;
50extern char *BuildInfo;
51extern char *SizePkg;
52extern char *SizeAll;
53extern char *Preserve;
54extern char *realprefix;
55extern char *DefaultOwner;
56extern char *DefaultGroup;
57extern const char *CompressionType;
58extern int PlistOnly;
59extern int RelativeLinks;
60extern int update_pkgdb;
61extern int create_views;
62
63void    check_list(package_t *, const char *);
64void    copy_plist(char *, package_t *);
65
66struct memory_file
67	*load_memory_file(const char *, const char *,
68			  const char *, const char *, mode_t);
69struct memory_file
70	*make_memory_file(const char *, void *, size_t,
71			  const char *, const char *, mode_t);
72void	free_memory_file(struct memory_file *);
73
74int	pkg_perform(const char *);
75int	pkg_build(const char *, const char *, const char *, package_t *plist);
76
77#endif				/* _INST_CREATE_H_INCLUDE */
78