1bpkg-cfg-create(1)          General Commands Manual         bpkg-cfg-create(1)
2
3
4

NAME

6       bpkg-cfg-create - create configuration
7

SYNOPSIS

9       bpkg cfg-create|create [options] [cfg-args]
10       bpkg cfg-create|create [options] --existing|-e
11
12       cfg-args = (module | cfg-var)...
13

DESCRIPTION

15       The cfg-create command creates a new bpkg configuration with the speci‐
16       fied build2 modules and configuration variables  (the  first  form)  or
17       initializes  one  based  on an existing build system configuration (the
18       second form). The bpkg configuration itself is a build system  configu‐
19       ration;  see  build  system driver (b(1)) create meta-operation for de‐
20       tails.
21
22       Unless the --existing|-e or --wipe option is specified, cfg-create  ex‐
23       pects the configuration directory to be empty or to not exist (in which
24       case it will be created).
25
26       By default, the configuration created with the  first  form  loads  the
27       config,  test,  dist,  and install modules. However, additional modules
28       and, if required, their configuration variables can be specified as the
29       cfg-create arguments. For example:
30
31       bpkg create cxx config.cxx=clang++ config.install.root=/usr/local
32
33       By  default,  bpkg appends .config to the names of the modules that you
34       specify so that only their configurations are loaded. You can  override
35       this  behavior  by specifying the period (.) after the module name. You
36       can also instruct bpkg to use the optional module load by prefixing the
37       module name with the question mark (?). For example:
38
39       bpkg create cxx. "?cli"
40
41       Configurations  can  be linked with each other to allow a package to be
42       built in one configuration while its dependencies in one or more linked
43       configurations.  This can be used to create a "base" configuration with
44       common dependencies that are shared  between  multiple  configurations.
45       This  mechanism  is  also  used to provide a host configuration that is
46       used to build build-time dependencies.
47
48       Each configuration is assigned an automatically-generated  UUID  unless
49       one is specified with the --uuid option. This UUID is used to check the
50       integrity of configuration  links.  For  convenience  of  referring  to
51       linked configurations, a configuration can also be assigned a name with
52       the --name option.
53
54       A configuration also has a type specified with the --type option. Three
55       predefined types are target, host, and build2. If the type is not spec‐
56       ified explicitly, then target is assumed. When satisfying a  dependency
57       of  one package on another, a linked configuration will only be consid‐
58       ered if (1) it has the same type as the other  configuration  for  run-
59       time  dependencies, (2) it has the host type for regular build-time de‐
60       pendencies, and (3) it has the build2  type  for  build  system  module
61       build-time  dependencies.  Note  that  a host configuration is a target
62       configuration for the host machine. So to create a self-hosted configu‐
63       ration, use type host.
64
65       To  link  a  configuration  we  use  the bpkg-cfg-link(1) command. As a
66       shortcut, host and build  system  module  configurations  can  also  be
67       linked  during  the  configuration  creation with the --host-config and
68       --build2-config options, respectively. If a  build-time  dependency  is
69       encountered  in  a  configuration that has no linked configuration of a
70       suitable type (host or build2, nor is itself of a suitable type),  then
71       a  private  host  or  build  system  module configuration named host or
72       build2, respectively, is created automatically  inside  the  configura‐
73       tion's .bpkg/ subdirectory.
74

CFG-CREATE OPTIONS

76       --directory|-d dir
77              Create the configuration in dir rather than in the current work‐
78              ing directory.
79
80       --existing|-e
81              Initialize a bpkg configuration based on an existing build  sys‐
82              tem configuration.
83
84       --wipe Wipe  the  configuration directory clean before creating the new
85              configuration.  For safety, this option requires that you  spec‐
86              ify the configuration directory explicitly with --directory|-d.
87
88       --host-config dir
89              Link the specified host configuration with the configuration be‐
90              ing created as if by running the bpkg-cfg-link(1) command.
91
92       --no-host-config
93              Ignore any specified --host-config options.
94
95       --build2-config dir
96              Link the specified build system module  configuration  with  the
97              configuration  being  created  as  if  by  running the bpkg-cfg-
98              link(1) command.
99
100       --no-build2-config
101              Ignore any specified --build2-config options.
102
103       --name name
104              The name of the configuration being created. If this  configura‐
105              tion  is  linked  with  another  configuration  using  bpkg-cfg-
106              link(1), this name will be used as the link name unless overrid‐
107              den. By default the configuration is created unnamed.
108
109       --type type
110              The type of the configuration being created. By default, config‐
111              uration of type target is created.
112
113       --uuid uuid
114              Use the specified UUID as the configuration id instead of gener‐
115              ating one automatically.
116

COMMON OPTIONS

118       The  common  options are summarized below with a more detailed descrip‐
119       tion available in bpkg-common-options(1).
120
121       -v     Print essential underlying commands being executed.
122
123       -V     Print all underlying commands being executed.
124
125       --quiet|-q
126              Run quietly, only printing error messages.
127
128       --verbose level
129              Set the diagnostics verbosity to level between 0 and 6.
130
131       --jobs|-j num
132              Number of jobs to perform in parallel.
133
134       --no-result
135              Don't print informational messages about the outcome of perform‐
136              ing a command or some of its parts.
137
138       --no-progress
139              Suppress  progress  indicators for long-lasting operations, such
140              as network transfers, building, etc.
141
142       --build path
143              The build program to be used to build packages.
144
145       --build-option opt
146              Additional option to be passed to the build program.
147
148       --fetch path
149              The fetch program to be used to download resources.
150
151       --fetch-option opt
152              Additional option to be passed to the fetch program.
153
154       --fetch-timeout sec
155              The fetch and fetch-like (for example, git) program timeout.
156
157       --pkg-proxy url
158              HTTP proxy server to use when fetching package manifests and ar‐
159              chives from remote pkg repositories.
160
161       --git path
162              The git program to be used to fetch git repositories.
163
164       --git-option opt
165              Additional common option to be passed to the git program.
166
167       --sha256 path
168              The sha256 program to be used to calculate SHA256 sums.
169
170       --sha256-option opt
171              Additional option to be passed to the sha256 program.
172
173       --tar path
174              The tar program to be used to extract package archives.
175
176       --tar-option opt
177              Additional option to be passed to the tar program.
178
179       --openssl path
180              The openssl program to be used for crypto operations.
181
182       --openssl-option opt
183              Additional option to be passed to the openssl program.
184
185       --auth type
186              Types of repositories to authenticate.
187
188       --trust fingerprint
189              Trust repository certificate with a SHA256 fingerprint.
190
191       --trust-yes
192              Assume the answer to all authentication prompts is yes.
193
194       --trust-no
195              Assume the answer to all authentication prompts is no.
196
197       --pager path
198              The pager program to be used to show long text.
199
200       --pager-option opt
201              Additional option to be passed to the pager program.
202
203       --options-file file
204              Read additional options from file.
205
206       --default-options dir
207              The directory to load additional default options files from.
208
209       --no-default-options
210              Don't load default options files.
211

DEFAULT OPTIONS FILES

213       See  bpkg-default-options-files(1)  for  an overview of the default op‐
214       tions files. For the cfg-create command the search start  directory  is
215       the  parent  directory  of the new configuration. The following options
216       files are searched for in each directory and, if found, loaded  in  the
217       order listed:
218
219       bpkg.options
220       bpkg-cfg-create.options
221
222       The following cfg-create command options cannot be specified in the de‐
223       fault options files:
224
225       --directory|-d
226       --wipe
227

BUGS

229       Send bug reports to the users@build2.org mailing list.
230
232       Copyright (c) 2014-2021 the build2 authors.
233
234       Permission is granted to copy, distribute and/or modify  this  document
235       under the terms of the MIT License.
236
237
238
239bpkg 0.14.0                      October 2021               bpkg-cfg-create(1)
Impressum