History log of /haiku/build/jam/RepositoryRules
Revision Date Author Comments
# 8830782a 15-Jun-2019 Augustin Cavalier <waddlesplash@gmail.com>

RepositoryRules: Error when the just-built package does not exist.

This will make version mismatches between the bootstrap repository
and the haikuports.cross repository more apparent.


# 0788d17a 06-Apr-2019 PulkoMandy <pulkomandy@pulkomandy.tk>

Fix missing absolute dir.

The variable is used after a "cd" so it must be absolute.

Change-Id: I8d591b8642179603249ac56a1fcac082f29c870c
Reviewed-on: https://review.haiku-os.org/c/1387
Reviewed-by: waddlesplash <waddlesplash@gmail.com>


# fcffcb15 24-Feb-2019 PulkoMandy <pulkomandy@pulkomandy.tk>

RepositoryRules: fix typo

This went through review too fast, the wrong variable name was used so
the package name was not listed...

Change-Id: I81d4aa57fdb65297ae9f63ebf123d7a6395a99b6
Reviewed-on: https://review.haiku-os.org/c/1109
Reviewed-by: waddlesplash <waddlesplash@gmail.com>


# e1248069 20-Feb-2019 PulkoMandy <pulkomandy@pulkomandy.tk>

bootstrap: a little more explicit error if things are wrong

There seems to be a problem with the way we set the gcc_bootstrap
package build to depend on the bootstrap package with haiku headers.
If said package cannot be built (for example some definitions are
missing for a new architecture), we end up passing an empty string as
the package to use to haikuporter.

The error message given by Haikuporter is confusing, and not easy to
investigate. So, intercept the error earlier to save time for the next
person to hit this problem.

Change-Id: I64f326e5cb3bb0d44632864ad38ad10bb88d0c7b
Reviewed-on: https://review.haiku-os.org/c/1082
Reviewed-by: waddlesplash <waddlesplash@gmail.com>


# 69bd151d 16-Nov-2018 waddlesplash <waddlesplash@gmail.com>

build: Fix paths of tools for bootstrap builds.

The paths to tools are relative to cwd, and HAIKU_ABSOLUTE_OUTPUT_DIR is
not necessarily the same as that, in the case where jam is invoked from
the repository root instead of a "generated" directory.

HOST_OBJECT_BASE_DIR is relative to pwd also, so just make it absolute.

Change-Id: I2aef83804be31c3c03c8577d56372f2dc6cb77f8
Reviewed-on: https://review.haiku-os.org/718
Reviewed-by: waddlesplash <waddlesplash@gmail.com>


# 53ce162d 16-Nov-2018 Alexander von Gluck IV <kallisti5@unixzen.com>

Revert "RepositoryRules: Use absolute output path for bootstrap package,mimeset,mimedb"

* Nope. Double generated directories when bootstrap run from HAIKU_TOP
* Third time's a charm?

This reverts commit 3db452372c187ff50208c380d2184fd813cec23a.


# 3db45237 16-Nov-2018 Alexander von Gluck IV <kallisti5@unixzen.com>

RepositoryRules: Use absolute output path for bootstrap package,mimeset,mimedb

* First re-fix of what was reverted in 85f8e7001
* haikuporter calls these during bootstrap and needs absolute paths

Change-Id: I40f1b15ffd474d3286356f3151eacd9a4a09add2


# 85f8e700 04-Nov-2018 Augustin Cavalier <waddlesplash@gmail.com>

Revert "jam: Fix bootstrap via absolutes in LD_LIBRARY_PATH"

This reverts commit 030d0eb58f0fae4201afcb83a38ac70038393b8d.

It is absolutely not correct to assume PWD is the generated dir;
it may also be the repository root.

Fixes jam putting some build artifacts in the source tree.


# 030d0eb5 04-Nov-2018 Alexander von Gluck IV <kallisti5@unixzen.com>

jam: Fix bootstrap via absolutes in LD_LIBRARY_PATH

* The PWD's are live based on jam run location which means
they shouldn't bind the generated directory to a fixed path
as before.
* We also need an absolute LD_LIBRARY PATH since haikuporter
loses the context invoking host tools.
* I don't think we can run jam from outside of the generated
directory anymore... but I don't think that was a thing.

Change-Id: I020f902ce5235bf268c9075d6e2ae85296a4ad20


# 657081f3 03-Nov-2018 Alexander von Gluck IV <kallisti5@unixzen.com>

bootstrap: Fix bootstrap after HAIKU_TOP changes

* haikuporter's cwd is the haikuporter path during execution
(haikuporter/HaikuPorter)
* We have to pass the full working path and can't use a relative
path here
* Seems to fix the bootstrap build

Change-Id: Ibb139f164c5e08eda3a08136c4e9ea2c9eaeae9e


# 6de4d8fc 22-Jul-2018 Jérôme Duval <jerome.duval@gmail.com>

RepositoryRules: correctly handle multiple secondary archs.


# e33d3563 02-Dec-2017 Augustin Cavalier <waddlesplash@gmail.com>

RepositoryRules: Restore mistakenly deleted local variable.


# 8dcb910a 02-Dec-2017 Augustin Cavalier <waddlesplash@gmail.com>

RepositoryRules: Do not use the downloaded repo.info.

Instead build the one in-tree from src/data/package_infos/. Fixes the
"HaikuPorts repos have wrong URL" problem that has occured since the
switch to buildmaster repos.


# a992fe6a 02-Dec-2017 Augustin Cavalier <waddlesplash@gmail.com>

RepositoryRules: RepositoryConfig does not need/use URL now.


# 08965a65 24-Nov-2017 Augustin Cavalier <waddlesplash@gmail.com>

build: Remove now-defunct jam commands.


# 5f8613a2 24-Nov-2017 Augustin Cavalier <waddlesplash@gmail.com>

build: Cleanup and fixes following previous commits.

* Hashing semantics for the new build repositories are different than
the old ones, so update those (if the x86 build was not broken before
it is now...)
* OptionalPackages has been updated slightly (removed libtool and git_cvs
from the default images, as they are rarely used nowadays and would pull
in a bunch of dependencies we don't really care for either)
* Removed lib:libqrencode from Haiku package requires (qrencode_kdl is a
static library, the userland libqrencode is not used anywhere in the tree,
as far as I can tell)
* Fix build of JPEG2000 translator after update
* Decouple fluidsynth build machinery and remove from image now that it
is no longer used
* Update repository URL in Repositories preflet


# 50c89183 02-Jul-2017 Alexander von Gluck IV <kallisti5@unixzen.com>

bootstrap: Fix behaviour after default haikuporter mode change


# fda0bf77 09-Dec-2016 Adrien Destugues <pulkomandy@pulkomandy.tk>

Revert "repo rework: Re-add compatibility url field"
Revert "repo rework: Remove stubs; Breaks repo compat."
Revert "repo rework: Remove need for repos to be self-aware"

This reverts commit a2b2f4d6427914cdcdb59943dd8e4a0bfdcd53ee.
This reverts commit 602076ef82647a48fd10f4d1ec830bb4242f9eb6.
This reverts commit 5ffaf72c8a74a7eb6827e4d2b1f47c9360ddaefe.

These changes break the build on Haiku and the ability to create repo
mirrors, for the lack of a replacement for the URL (an UUID was evoked
on the mailing lists, but not implemented).

We are due for a release soon, please don't break the build.


# 5ffaf72c 01-Dec-2016 Alexander von Gluck IV <kallisti5@unixzen.com>

repo rework: Remove need for repos to be self-aware

* See #12917 for details.
* Squashed to one commit to make revert easy if we
run into any issues.
* pkgman is now pre-attached to the 'current' repo
version within nightly images so they can be updated
by default.
* This shouldn't impact us keeping older sets of package
versions by commit hash for building older hrevs.
* There are XXX stubs with "Kill me". These will need
to be dropped after users are given sufficent time to
upgrade. We're dropping a previously required field (url)
so making this a slowish roll out.
* Makes the repos a lot less restrictive which should
help PM package building automation be a bit easier.
* Once this stuff smooths out, we'll add UUID's to the
repo definitions for duplicate repo detection.


# c9dd05ff 26-Oct-2014 Jonathan Schleifer <js@webkeks.org>

configure: Add variable to see if we're bootstrapping


# 5399d1df 14-Sep-2014 Oliver Tappe <zooey@hirschkaefer.de>

Fix (hopefully) bootstrap build with HAIKU_NO_DOWNLOADS=1

* With HAIKU_NO_DOWNLOADS=1, the check against existing package files
in the download folder should only be done in the phase that is
adding packages to be put onto the resulting target image, not in the
phase that is adding the bootstrap packages (as here those packages
will be *built*, not downloaded).


# e29a6c4c 11-Aug-2014 Oliver Tappe <zooey@hirschkaefer.de>

Introduce stage0 into the bootstrap process.

* This stage builds the gcc packages to get the shared syslibs, which
only requires the Haiku glue code.
* Add separate declaration section for stage0 packages to
HaikuPortsCross repository files.
* For the bootstrap_stage0 platform, fall back to the gcc headers
provided by the cross-compiler.


# 2e477cf6 12-Aug-2014 Oliver Tappe <zooey@hirschkaefer.de>

Simplify handling of package names.

* No longer apply somewhat crude mechanism for converting a package name
into a corresponding port name - haikuporter by now supports package
names directly.

This fixes a problem when trying to pass 'gcc_syslibs_devel' to
haikuporter, which only ever saw 'gcc_syslibs'.


# 938bf9fa 31-Jul-2014 Oliver Tappe <zooey@hirschkaefer.de>

Add more missing 'local's to variable declarations.


# 2ae3c649 24-Jul-2014 Oliver Tappe <zooey@hirschkaefer.de>

Improve IsPackageAvailable()

* When adjusting the package name for the secondary architecture,
it is unclear where exactly in the package name the architecture
specifier is. To remedy, we try all possible positions until
we find the package (or there are no other possibilities).


# 1b4510ee 25-Jul-2014 Oliver Tappe <zooey@hirschkaefer.de>

Put haiku repository onto image.

* Now that system updates seem to work properly, put the haiku
repository config and cache file onto the image automatically.
* Adjust URL of haiku repository (it is currently redirected
to some other URL at download.haiku-os.org, but that will be
changed later).


# 6f32bafa 03-Jul-2014 Oliver Tappe <zooey@hirschkaefer.de>

Use a specific packager for continuous integration builds.


# 4e37addd 23-Jun-2014 Oliver Tappe <zooey@hirschkaefer.de>

Add HAIKU_PORTER_EXTRA_OPTIONS variable.

* This can be used to add arbitrary options to invocations of
haikuporter.


# d1b21b4a 01-May-2014 Oliver Tappe <zooey@hirschkaefer.de>

Improve build feature handling with HAIKU_NO_DOWNLOADS=1

* Adjust the respective rules such that with disabled downloads, only
packages already available in the downloads folder will be considered
as available build features.

This way, the build system will not for instance try to build
<kdebug>qrencode after a bootstrap, as that package is not yet
available.


# aa2e5eca 30-Apr-2014 Oliver Tappe <zooey@hirschkaefer.de>

Add new configuration option --no-downloads.

* If --no-downloads has been given, Haiku will be built without
trying to download anything, all required packages need to be put
into the download folder manually (the build will stop on missing
packages).
* As the required HaikuPorts repository can't be downloaded in this
mode, a local repository is created during the build, which only
contains the packages available in the downloads folder.

This is useful for building Haiku completely from source.


# 8c54af56 30-Apr-2014 Oliver Tappe <zooey@hirschkaefer.de>

Whitespace cleanup in root and 'build' folder.

* Removed trailing whitespace and empty lines at top of files.


# fe7d7c27 03-Apr-2014 Jonathan Schleifer <js@webkeks.org>

RepositoryRules: Add option to now download any packages

This is useful if Haiku should be built using self-built packages.


# a8c098a3 22-Mar-2014 Oliver Tappe <zooey@hirschkaefer.de>

Replace HAIKU_{BOOTSTRAP,MINIMUM}_BUILD with HAIKU_BUILD_TYPE.

* Instead of separate variables, HAIKU_BUILD_TYPE is set to one of
'bootstrap', 'minimum' or 'regular'.
* Adjust uses of HAIKU_BOOTSTRAP_BUILD accordingly.


# 1d50d90f 16-Mar-2014 Oliver Tappe <zooey@hirschkaefer.de>

Drop extra packages and note which no longer applies.

* now that haikuporter resolves the dependencies correctly, there's no
need to add texi2html and htmldoc explicitly


# 72e67791 15-Mar-2014 Oliver Tappe <zooey@hirschkaefer.de>

Make set of source packages for bootstrap-image configurable.

* Add new build profile 'minimum', which defines a minimum set of
packages.
* Introduce HAIKU_BOOTSTRAP_SOURCES_PROFILE and let it default to
'@minimum-raw'. This can be overruled in UserBuildConfig, setting
it to '@release-raw' will cause all source packages required for a
full release to be put onto the bootstrap-image.
* Add new image HaikuImageMinimum, which is meant to define the minimum
useful Haiku image (yeah, I know that's vague).
* Add HAIKU_MINIMUM_BUILD, which indicates that HaikuImageMinimum should
be used (it would be better to merge this with HAIKU_BOOTSTRAP_BUILD
into something like HAIKU_BUILD_TYPE)
* Cleanup duplicate references to basic packages - those are now added
by the topmost Jamfile (no longer referenced by the build profiles).


# 5c9657b7 23-Feb-2014 Oliver Tappe <zooey@hirschkaefer.de>

Fix creation of haikuports.conf for bootstrap image.

* comments in here-documents don't work (the shell filters them out),
so we echo the comment line explicitly


# 68f8b94e 22-Jan-2014 Oliver Tappe <zooey@hirschkaefer.de>

Drop --remote-user configuration option again.

* as Ingo has pointed out, the remote user settings doesn't
relate to the build configuration at all, so setting the
remote user via HAIKU_REMOTE_USER in UserBuildConfig or
via shell environment is the way to go
* additionally: drop debug output


# 86d7e283 22-Jan-2014 Oliver Tappe <zooey@hirschkaefer.de>

Add support for specifying remote ssh login user.

* add option --remote-user to configure, which sets HAIKU_REMOTE_USER
* add evaluation of HAIKU_REMOTE_USER variable when ssh-ing
into git.haiku-os.org


# be5e6fef 18-Jan-2014 Ingo Weinhold <ingo_weinhold@gmx.de>

Add repository config for the Haiku repository to the image

* HaikuRepository rule: Create the repository config.
* HaikuImage: Add the repository config for the Haiku image. The
repository cache is not added, though (it would only be available, if
the repository had been built before).

Implements #10287. The Haiku repository is now available in Haiku by
default.


# f0b99b54 18-Jan-2014 Ingo Weinhold <ingo_weinhold@gmx.de>

RepositoryConfig rule: Make a bit more generic

Instead of the repository the URL can now be passed. It can use the
"$version" placeholder, which will be replaced by the content of the
given version file. If the URL is not given, the one from the repository
info will be used.


# 12c19e63 18-Jan-2014 Ingo Weinhold <ingo_weinhold@gmx.de>

Move creating the Haiku repo info to jam

* PreprocessPackageInfo rule: Pull out new rule
PreprocessPackageOrRepositoryInfo which does the sed substituation and
optionally the filtering through the C preprocessor.
* HaikuRepository rule: Generate the repository info file (from the
given template). No longer do that in the build_haiku_repository
script.


# a1c42e71 23-Nov-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Replace missed alpha-raw release build profile occurrences


# d85bab41 22-Nov-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Add target for building a Haiku package repository

* Add rule HaikuRepository to build a repository from a repository info
file and a list of package files. It calls a build_haiku_repository
script which does all the work.
* Add target <repository>haiku for building the Haiku package
repository.
It should be built via "jam -q @alpha-raw build <repository>haiku";
the build profile is only needed to activate all build features.


# b2806f31 22-Nov-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

RepositoryRules: Automatic whitespace cleanup


# 49b970d9 14-Nov-2013 Oliver Tappe <zooey@hirschkaefer.de>

Reintroduce jam rule for creating remote repository for testing.

* 'jam build-remote-test-repository' can now be used to create a
remote repository which will then be used by the build system,
such that the resulting package set can be tested.


# e4bd712d 03-Nov-2013 Oliver Tappe <zooey@hirschkaefer.de>

Replace jam build-remote-repository with jam upload-packages

* We are moving the HaikuPorts repositories over from haiku-files.org
to packages.haiku-os.org, and we will be creating new repositories
during a push hook from now on. As a result, only a small helper for
uploading new packages into the appropriate upload folder is required.


# 40b9ac78 10-Oct-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Bootstrap image haikuports.config: Comment out PACKAGER

The developer building the packages should enter their own address
instead. I just noticed that a lot of the HaikuPorts package have a
packager attribute with the dummy address "The Haiku build system
<build-system@haiku-os.org>" due to the previous default value.


# 4d07fb53 01-Oct-2013 Jérôme Duval <jerome.duval@gmail.com>

added a check for HOST_EXTENDED_REGEX_SED presence


# 4d65f429 28-Sep-2013 François Revol <revol@free.fr>

Fix bashisms

Besides, at least one test was probably incorrect,
trying to match /* with a single = in [[.


# af8587ce 14-Sep-2013 Oliver Tappe <zooey@hirschkaefer.de>

Added new jam command 'build-remote-repository'.

* build-remote-repository <packages> uploads the given set of packages
to the server and builds the remote repository


# fb99605f 01-Sep-2013 Oliver Tappe <zooey@hirschkaefer.de>

Handle rigged source packages when determining port name.

* I'm not sure this makes much of a difference, but I thought it's
better to play it safe.


# 24796718 17-Aug-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Bootstrap Haiku image: add source for more required packages

* Introduce build variable HAIKU_IMAGE_ADDITIONAL_PACKAGES which can be
set to add additional packages to the image.
* Use HAIKU_IMAGE_ADDITIONAL_PACKAGES to support specifying a list of
additional packages via the build-package-list build profile action.
* Add htmldoc and texi2html when building the list of the packages for
which we need source packages when building the bootstrap Haiku image.
We don't want them on the regular image, but they are needed to build
some packages that are on it.


# 13f2fbbd 17-Aug-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Add build variable HAIKU_PORTER_CONCURRENT_JOBS

It can be set to the number of jobs specified on the haikuporter
command line. Speeds up the bootstrap build quite a bit.


# f81fbb0b 07-Aug-2013 Oliver Tappe <zooey@hirschkaefer.de>

Adjust to renamed option of haikuporter.


# c965ee60 06-Aug-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

bootstrap image: build needed source packages and add them

* IsPackageAvailable, FetchPackage: Add flags parameter. The only
flag supported ATM is nameResolved, indicating that the specified
package name does not need to be resolved with respect to a secondary
architecture anymore.
* Add build profile action "build-package-list". As an argument the
file to which the list of all packages needed for the image is
written. The rule BuildHaikuImagePackageList implements the action.
* BuildBootstrapRepositoryConfig: Does now require the variable
HAIKU_REPOSITORY_TREE_PATH to be set on the config file target instead
of hard-coding the path. Allows reuse of the actions.
* Add rules BuildHaikuPortsSourcePackageDirectory and
BuildHaikuPortsRepositoryConfig. The former builds all HaikuPorts
source packages needed to build the packages for an alpha image. The
latter generates a haikuports.conf file for use on the bootstrap
Haiku.
* HaikuImageBootstrap: Add directory /boot/home/haikuports which
contains a subdirectory with the source packages and a
haikuports.conf.


# 0b171ae4 05-Aug-2013 Oliver Tappe <zooey@hirschkaefer.de>

Fix two problems when building without secondary architecture.


# 93cfb722 04-Aug-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

build features/bootstrap repo: support secondary arch

* Add rule FSplitPackageName. It splits a package name into port name
and package suffix.
* FSetConditionsHold: Rename to FConditionsHold and replace the set
parameter by a predicate rule parameter, thus adding more flexibility.
* FIsBuildFeatureEnabled: Use the faster check.
* Add rule FQualifiedBuildFeatureName. Given a build feature name, it
prepends the current packaging architecture to yield a qualified
feature name. Is used by the other build feature rules so that the
same build feature can be configured differently for each arch.
* ExtractBuildFeatureArchives: The supplied list is now filtered via
FFilterByBuildFeatures, allowing for build feature conditions in the
list.
* Add rule InitArchitectureBuildFeatures. It is called early for each
configured architecture, setting up some basic build features for it.
"primary" is set for the primary architecture and a "secondary_<arch>"
is set for each secondary architecture.
* BuildFeatures: Add secondary architecture support: Use the correct
paths for libraries and headers (subdir for secondary architecture)
and configure the icu and zlib sources only for the primary
architecture.
* BootstrapPackageRepository: The package lists are now filtered via
FFilterByBuildFeatures, allowing for build feature conditions in the
lists.
* IsPackageAvailable, FetchPackage: Add secondary architecture support.
* HaikuPortsCross/x86_gcc2: Add icu and zlib x86 secondary packages.

The second stage Haiku cross devel package for the secondary
architecture can now be built.


# b0944c78 01-Aug-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

More work towards hybrid support

* All packaging architecture dependent variables do now have a
respective suffix and are set up for each configured packaging
architecture, save for the kernel and boot loader variables, which
are still only set up for the primary architecture.
For convenience TARGET_PACKAGING_ARCH, TARGET_ARCH, TARGET_LIBSUPC++,
and TARGET_LIBSTDC++ are set to the respective values for the primary
packaging architecture by default.
* Introduce a set of MultiArch* rules to help with building targets for
multiple packaging architectures. Generally the respective targets are
(additionally) gristed with the packaging architecture. For libraries
the additional grist is usually omitted for the primary architecture
(e.g. libroot.so and <x86>libroot.so for x86_gcc2/x86 hybrid), so that
Jamfiles for targets built only for the primary architecture don't
need to be changed.
* Add multi-arch build support for all targets needed for the stage 1
cross devel package as well as for libbe (untested).


# 7b2174a2 21-Jul-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

BootstrapPackageRepository: serialize package creation

Since haikuporter uses a common directory for building the ports, we
can't build them concurrently. This makes jamming with multiple jobs
safe again.


# e173a1ec 20-Jul-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Integrate building the HaikuPorts bootstrap packages

* Add configure option --bootstrap which allows specifying the
haikuporter and HaikuPorts repository paths.
* Add rules for supporting a second repository type. The
PackageRepository rule is now private and RemotePackageRepository is
used for remote repositories. The new BootstrapPackageRepository rule
is for defining a bootstrap repository (there will probably be only
the HaikuPorts cross repository) whose packages can be built as needed
via haikuporter.
* Rename DownloadPackage to FetchPackage.
* Define repository HaikuPortsCross.
* HaikuCrossDevel package(s): There are now two sets of packages: A
"stage1" set with the same content as before and a final set
additionally containing the libraries libbe, libnetwork, libpackage.
Those are needed for building the libsolv bootstrap package while for
building them we need other bootstrap packages (ICU, libz).

This is basically all that's required to build a bootstrap Haiku
completely from sources, with a few caveats:
* There's no ICU bootstrap recipe yet (so one has to cheat and use the
prebuilt package ATM).
* Probably doesn't work on Haiku yet (tested on Linux only).
* A 32 bit environment must be used (otherwise building the gcc 2
bootstrap package fails).
* Building with multiple jobs doesn't work yet, since haikuporter uses
common directories for building different packages and there's no
explicit serialization yet.
* Haven't tested the resulting image save for booting it. So it probably
needs a bit more work before it can actually build the final
HaikuPorts packages.


# 38f07871 12-Jul-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

rule AddRepositoryPackages: add debugInfoPackage parameter

It works just like the sourcePackages parameter.


# 014eed80 06-Jul-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Change repository directory layout

* Under the base URL there are supposed to be the repository files and a
subdirectory "packages".
* Fix the repository URL related confusion introduced earlier. The URL
in
the repository info (and thus in the repository file) is supposed to
be the base URL for the repository. It is not a (potentially)
different base URL for the package files. Package and repository
files were supposed to live in the same directory. Now, by requiring
the package files to live in a subdirectory -- which can also be a
symlink -- we gain some flexibility.
The URL in the repository config is usually the same as the in the
repository info, unless it refers to a mirror site. This allows for
mirrors to copy the original repository verbatim.
* Remove the PackageURL rule and introduce a DownloadPackage rule
instead. The URL for a package file cannot be computed in the jam
parsing phase anymore, as it contains the hash value of the package
list.
* BRepositoryConfig: Add PackagesURL() for convenience.


# d72ce066 05-Jul-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Adjust to changed HaikuPorts repository layout

The package kit actually requires the files "repo", "repo.info",
"repo.sha256" to be located under the repository base URL, so the
approach to name the repository file "repo-<hash>" doesn't work.
Now there's a directory "<hash>" which contains the files.

This commit moves the computation of the hash and downloading the
repository file from the build_haiku_image script to the jam build
system. The repo.info is also downloaded and a repository config file
is generated.


# 627626af 05-Jul-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

GeneratedRepositoryPackageList: defeat localization

Set LC_ALL=C, so "sort" produces useful results.


# 98c6dfa4 05-Jul-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Switch build system from optional package to repositories

* Build libsolv and the dependency solver part of the package kit for
the build platform.
* Add build tool get_package_dependencies. Given a list of package files
and a list of repository files it determines the additional packages
that need to be retrieved from the repositories and prints their URLs.
* Add rules to work with external repositories in the build system
(build/jam/RepositoryRules):
- PackageRepository declares an external repository with all its
packages. The URL of the repository file isn't specified. It is
computed from a given base URL and the SHA256 hash of the list of
package files.
- GeneratedRepositoryPackageList generates a file containing the file
names of all packages in a repository.
- IsPackageAvailable returns whether a package is available in any
repository.
- PackageURL returns the URL for a package.
* Declare the HaikuPorts repository for x86_gcc2
(build/jam/repositories/HaikuPorts/x86_gcc2).
* Add rule AddHaikuImagePackages to add a package to the image and rule
IsHaikuImagePackageAdded to determine whether a package has been
added.
* OptionalPackages: Remove all entries that just downloaded and
installed an external package. AddHaikuImagePackages can be used
instead and is used in the remaining entries. Also move the remaining
optional package dependency declarations from
OptionalPackageDependencies here.
* ExtractBuildFeatureArchives: Instead of the URL parameter a package
name must be specified now. This allows to simplify BuildFeatures
significantly, since there's no dealing with URLs anymore. "if" out
the entries that aren't supported yet.
* build_haiku_image: For the packages installed in system and common
resolve their dependencies and download and install them as well.


# c9dd05ff400733baf569ee023c05d48fdbcf4ef1 26-Oct-2014 Jonathan Schleifer <js@webkeks.org>

configure: Add variable to see if we're bootstrapping


# 5399d1df38d48f970eea4927375edade30d2b636 14-Sep-2014 Oliver Tappe <zooey@hirschkaefer.de>

Fix (hopefully) bootstrap build with HAIKU_NO_DOWNLOADS=1

* With HAIKU_NO_DOWNLOADS=1, the check against existing package files
in the download folder should only be done in the phase that is
adding packages to be put onto the resulting target image, not in the
phase that is adding the bootstrap packages (as here those packages
will be *built*, not downloaded).


# e29a6c4cd44f1b189b4938beea2b7ef1d0ce65f0 11-Aug-2014 Oliver Tappe <zooey@hirschkaefer.de>

Introduce stage0 into the bootstrap process.

* This stage builds the gcc packages to get the shared syslibs, which
only requires the Haiku glue code.
* Add separate declaration section for stage0 packages to
HaikuPortsCross repository files.
* For the bootstrap_stage0 platform, fall back to the gcc headers
provided by the cross-compiler.


# 2e477cf688115e832d27a6019b7cf4263ba9e036 12-Aug-2014 Oliver Tappe <zooey@hirschkaefer.de>

Simplify handling of package names.

* No longer apply somewhat crude mechanism for converting a package name
into a corresponding port name - haikuporter by now supports package
names directly.

This fixes a problem when trying to pass 'gcc_syslibs_devel' to
haikuporter, which only ever saw 'gcc_syslibs'.


# 938bf9fad2fa70a2fd7dba661464068133bf9b73 31-Jul-2014 Oliver Tappe <zooey@hirschkaefer.de>

Add more missing 'local's to variable declarations.


# 2ae3c649431bf5888b98d8b7b8712e1a7c7b59b5 24-Jul-2014 Oliver Tappe <zooey@hirschkaefer.de>

Improve IsPackageAvailable()

* When adjusting the package name for the secondary architecture,
it is unclear where exactly in the package name the architecture
specifier is. To remedy, we try all possible positions until
we find the package (or there are no other possibilities).


# 1b4510eebfb4aa1975fef0c46f90f4a1dfd71159 25-Jul-2014 Oliver Tappe <zooey@hirschkaefer.de>

Put haiku repository onto image.

* Now that system updates seem to work properly, put the haiku
repository config and cache file onto the image automatically.
* Adjust URL of haiku repository (it is currently redirected
to some other URL at download.haiku-os.org, but that will be
changed later).


# 6f32bafa70f2b5ef12a14d4c772be17d85e1c74b 03-Jul-2014 Oliver Tappe <zooey@hirschkaefer.de>

Use a specific packager for continuous integration builds.


# 4e37addd2fe73546b2477bf3f0029e2ab91751de 23-Jun-2014 Oliver Tappe <zooey@hirschkaefer.de>

Add HAIKU_PORTER_EXTRA_OPTIONS variable.

* This can be used to add arbitrary options to invocations of
haikuporter.


# d1b21b4ad3a5df40d5837c1a62775dcac699fe9c 01-May-2014 Oliver Tappe <zooey@hirschkaefer.de>

Improve build feature handling with HAIKU_NO_DOWNLOADS=1

* Adjust the respective rules such that with disabled downloads, only
packages already available in the downloads folder will be considered
as available build features.

This way, the build system will not for instance try to build
<kdebug>qrencode after a bootstrap, as that package is not yet
available.


# aa2e5eca78d747234a7557c86d4f104a8301d88a 30-Apr-2014 Oliver Tappe <zooey@hirschkaefer.de>

Add new configuration option --no-downloads.

* If --no-downloads has been given, Haiku will be built without
trying to download anything, all required packages need to be put
into the download folder manually (the build will stop on missing
packages).
* As the required HaikuPorts repository can't be downloaded in this
mode, a local repository is created during the build, which only
contains the packages available in the downloads folder.

This is useful for building Haiku completely from source.


# 8c54af563ce823c0e5b029716b2a020896c90ff4 30-Apr-2014 Oliver Tappe <zooey@hirschkaefer.de>

Whitespace cleanup in root and 'build' folder.

* Removed trailing whitespace and empty lines at top of files.


# fe7d7c27fc7d9294333ca0a4b82270a36560352e 03-Apr-2014 Jonathan Schleifer <js@webkeks.org>

RepositoryRules: Add option to now download any packages

This is useful if Haiku should be built using self-built packages.


# a8c098a3ba81542b73c5be4e90ae01a4fc47507b 22-Mar-2014 Oliver Tappe <zooey@hirschkaefer.de>

Replace HAIKU_{BOOTSTRAP,MINIMUM}_BUILD with HAIKU_BUILD_TYPE.

* Instead of separate variables, HAIKU_BUILD_TYPE is set to one of
'bootstrap', 'minimum' or 'regular'.
* Adjust uses of HAIKU_BOOTSTRAP_BUILD accordingly.


# 1d50d90fbeecd11160bfe42668caf2d7b9349a00 16-Mar-2014 Oliver Tappe <zooey@hirschkaefer.de>

Drop extra packages and note which no longer applies.

* now that haikuporter resolves the dependencies correctly, there's no
need to add texi2html and htmldoc explicitly


# 72e677911f70c9b191fa5ea2f1c0e76cb00ea2b7 15-Mar-2014 Oliver Tappe <zooey@hirschkaefer.de>

Make set of source packages for bootstrap-image configurable.

* Add new build profile 'minimum', which defines a minimum set of
packages.
* Introduce HAIKU_BOOTSTRAP_SOURCES_PROFILE and let it default to
'@minimum-raw'. This can be overruled in UserBuildConfig, setting
it to '@release-raw' will cause all source packages required for a
full release to be put onto the bootstrap-image.
* Add new image HaikuImageMinimum, which is meant to define the minimum
useful Haiku image (yeah, I know that's vague).
* Add HAIKU_MINIMUM_BUILD, which indicates that HaikuImageMinimum should
be used (it would be better to merge this with HAIKU_BOOTSTRAP_BUILD
into something like HAIKU_BUILD_TYPE)
* Cleanup duplicate references to basic packages - those are now added
by the topmost Jamfile (no longer referenced by the build profiles).


# 5c9657b7e5c0c678b90efe90f48b3e9d8375b3d1 23-Feb-2014 Oliver Tappe <zooey@hirschkaefer.de>

Fix creation of haikuports.conf for bootstrap image.

* comments in here-documents don't work (the shell filters them out),
so we echo the comment line explicitly


# 68f8b94e2a287c970e2d92a8b51842c155bf51eb 22-Jan-2014 Oliver Tappe <zooey@hirschkaefer.de>

Drop --remote-user configuration option again.

* as Ingo has pointed out, the remote user settings doesn't
relate to the build configuration at all, so setting the
remote user via HAIKU_REMOTE_USER in UserBuildConfig or
via shell environment is the way to go
* additionally: drop debug output


# 86d7e28306626756a5d31a3903b7d123500ac6eb 22-Jan-2014 Oliver Tappe <zooey@hirschkaefer.de>

Add support for specifying remote ssh login user.

* add option --remote-user to configure, which sets HAIKU_REMOTE_USER
* add evaluation of HAIKU_REMOTE_USER variable when ssh-ing
into git.haiku-os.org


# be5e6fefdfbc9f98011e65f4acf1efb635d35f8c 18-Jan-2014 Ingo Weinhold <ingo_weinhold@gmx.de>

Add repository config for the Haiku repository to the image

* HaikuRepository rule: Create the repository config.
* HaikuImage: Add the repository config for the Haiku image. The
repository cache is not added, though (it would only be available, if
the repository had been built before).

Implements #10287. The Haiku repository is now available in Haiku by
default.


# f0b99b54bba82e7ba56fa778961ea39f7297b57c 18-Jan-2014 Ingo Weinhold <ingo_weinhold@gmx.de>

RepositoryConfig rule: Make a bit more generic

Instead of the repository the URL can now be passed. It can use the
"$version" placeholder, which will be replaced by the content of the
given version file. If the URL is not given, the one from the repository
info will be used.


# 12c19e6362e4e7b0c3f93e0f7a2dbd8e50bde03a 18-Jan-2014 Ingo Weinhold <ingo_weinhold@gmx.de>

Move creating the Haiku repo info to jam

* PreprocessPackageInfo rule: Pull out new rule
PreprocessPackageOrRepositoryInfo which does the sed substituation and
optionally the filtering through the C preprocessor.
* HaikuRepository rule: Generate the repository info file (from the
given template). No longer do that in the build_haiku_repository
script.


# a1c42e71897707830584b24a9cc396ae12565167 23-Nov-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Replace missed alpha-raw release build profile occurrences


# d85bab41bd6873ef4b0cfc02c3b0bb5f224317d2 22-Nov-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Add target for building a Haiku package repository

* Add rule HaikuRepository to build a repository from a repository info
file and a list of package files. It calls a build_haiku_repository
script which does all the work.
* Add target <repository>haiku for building the Haiku package
repository.
It should be built via "jam -q @alpha-raw build <repository>haiku";
the build profile is only needed to activate all build features.


# b2806f310e99fce2c65e68ab78cd753dfdf73b1a 22-Nov-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

RepositoryRules: Automatic whitespace cleanup


# 49b970d9c2103f621ed27d6b5e2207857ea2b2d2 14-Nov-2013 Oliver Tappe <zooey@hirschkaefer.de>

Reintroduce jam rule for creating remote repository for testing.

* 'jam build-remote-test-repository' can now be used to create a
remote repository which will then be used by the build system,
such that the resulting package set can be tested.


# e4bd712d11c4882e19b2145d257f0dbc498f6f79 03-Nov-2013 Oliver Tappe <zooey@hirschkaefer.de>

Replace jam build-remote-repository with jam upload-packages

* We are moving the HaikuPorts repositories over from haiku-files.org
to packages.haiku-os.org, and we will be creating new repositories
during a push hook from now on. As a result, only a small helper for
uploading new packages into the appropriate upload folder is required.


# 40b9ac787c692d8ef51806c1f14ad419955500e2 10-Oct-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Bootstrap image haikuports.config: Comment out PACKAGER

The developer building the packages should enter their own address
instead. I just noticed that a lot of the HaikuPorts package have a
packager attribute with the dummy address "The Haiku build system
<build-system@haiku-os.org>" due to the previous default value.


# 4d07fb53d0080d836eeb86c88d4147cc053f58f1 01-Oct-2013 Jérôme Duval <jerome.duval@gmail.com>

added a check for HOST_EXTENDED_REGEX_SED presence


# 4d65f429d0b486504be7ae31033e5ad215e3f809 28-Sep-2013 François Revol <revol@free.fr>

Fix bashisms

Besides, at least one test was probably incorrect,
trying to match /* with a single = in [[.


# af8587ce40c2a181ab9e00ab83aee70bf9e54883 14-Sep-2013 Oliver Tappe <zooey@hirschkaefer.de>

Added new jam command 'build-remote-repository'.

* build-remote-repository <packages> uploads the given set of packages
to the server and builds the remote repository


# fb99605f490abbeeaff4373193e5cccd619025a6 01-Sep-2013 Oliver Tappe <zooey@hirschkaefer.de>

Handle rigged source packages when determining port name.

* I'm not sure this makes much of a difference, but I thought it's
better to play it safe.


# 24796718b99aff208846310dd982c5c41d5e7eff 17-Aug-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Bootstrap Haiku image: add source for more required packages

* Introduce build variable HAIKU_IMAGE_ADDITIONAL_PACKAGES which can be
set to add additional packages to the image.
* Use HAIKU_IMAGE_ADDITIONAL_PACKAGES to support specifying a list of
additional packages via the build-package-list build profile action.
* Add htmldoc and texi2html when building the list of the packages for
which we need source packages when building the bootstrap Haiku image.
We don't want them on the regular image, but they are needed to build
some packages that are on it.


# 13f2fbbd9ef7a7b6cc8f3257e3840bc6911a2e39 17-Aug-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Add build variable HAIKU_PORTER_CONCURRENT_JOBS

It can be set to the number of jobs specified on the haikuporter
command line. Speeds up the bootstrap build quite a bit.


# f81fbb0b59c775851241b42040f2642fb0a02e78 07-Aug-2013 Oliver Tappe <zooey@hirschkaefer.de>

Adjust to renamed option of haikuporter.


# c965ee60b5656a5ef749adfdacd64918adee6cf5 06-Aug-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

bootstrap image: build needed source packages and add them

* IsPackageAvailable, FetchPackage: Add flags parameter. The only
flag supported ATM is nameResolved, indicating that the specified
package name does not need to be resolved with respect to a secondary
architecture anymore.
* Add build profile action "build-package-list". As an argument the
file to which the list of all packages needed for the image is
written. The rule BuildHaikuImagePackageList implements the action.
* BuildBootstrapRepositoryConfig: Does now require the variable
HAIKU_REPOSITORY_TREE_PATH to be set on the config file target instead
of hard-coding the path. Allows reuse of the actions.
* Add rules BuildHaikuPortsSourcePackageDirectory and
BuildHaikuPortsRepositoryConfig. The former builds all HaikuPorts
source packages needed to build the packages for an alpha image. The
latter generates a haikuports.conf file for use on the bootstrap
Haiku.
* HaikuImageBootstrap: Add directory /boot/home/haikuports which
contains a subdirectory with the source packages and a
haikuports.conf.


# 0b171ae44a83e009f91b5e769acfffaeb73767a1 05-Aug-2013 Oliver Tappe <zooey@hirschkaefer.de>

Fix two problems when building without secondary architecture.


# 93cfb722707a5870dc99fefe0c05dff0ca4e966f 04-Aug-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

build features/bootstrap repo: support secondary arch

* Add rule FSplitPackageName. It splits a package name into port name
and package suffix.
* FSetConditionsHold: Rename to FConditionsHold and replace the set
parameter by a predicate rule parameter, thus adding more flexibility.
* FIsBuildFeatureEnabled: Use the faster check.
* Add rule FQualifiedBuildFeatureName. Given a build feature name, it
prepends the current packaging architecture to yield a qualified
feature name. Is used by the other build feature rules so that the
same build feature can be configured differently for each arch.
* ExtractBuildFeatureArchives: The supplied list is now filtered via
FFilterByBuildFeatures, allowing for build feature conditions in the
list.
* Add rule InitArchitectureBuildFeatures. It is called early for each
configured architecture, setting up some basic build features for it.
"primary" is set for the primary architecture and a "secondary_<arch>"
is set for each secondary architecture.
* BuildFeatures: Add secondary architecture support: Use the correct
paths for libraries and headers (subdir for secondary architecture)
and configure the icu and zlib sources only for the primary
architecture.
* BootstrapPackageRepository: The package lists are now filtered via
FFilterByBuildFeatures, allowing for build feature conditions in the
lists.
* IsPackageAvailable, FetchPackage: Add secondary architecture support.
* HaikuPortsCross/x86_gcc2: Add icu and zlib x86 secondary packages.

The second stage Haiku cross devel package for the secondary
architecture can now be built.


# b0944c78b074a8110bd98e060415d0e8f38a7f65 01-Aug-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

More work towards hybrid support

* All packaging architecture dependent variables do now have a
respective suffix and are set up for each configured packaging
architecture, save for the kernel and boot loader variables, which
are still only set up for the primary architecture.
For convenience TARGET_PACKAGING_ARCH, TARGET_ARCH, TARGET_LIBSUPC++,
and TARGET_LIBSTDC++ are set to the respective values for the primary
packaging architecture by default.
* Introduce a set of MultiArch* rules to help with building targets for
multiple packaging architectures. Generally the respective targets are
(additionally) gristed with the packaging architecture. For libraries
the additional grist is usually omitted for the primary architecture
(e.g. libroot.so and <x86>libroot.so for x86_gcc2/x86 hybrid), so that
Jamfiles for targets built only for the primary architecture don't
need to be changed.
* Add multi-arch build support for all targets needed for the stage 1
cross devel package as well as for libbe (untested).


# 7b2174a27d37d8f688af54e482fc906d019aa50a 21-Jul-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

BootstrapPackageRepository: serialize package creation

Since haikuporter uses a common directory for building the ports, we
can't build them concurrently. This makes jamming with multiple jobs
safe again.


# e173a1ec1c0c1f48e355f3cbc34c0114e336ff88 20-Jul-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Integrate building the HaikuPorts bootstrap packages

* Add configure option --bootstrap which allows specifying the
haikuporter and HaikuPorts repository paths.
* Add rules for supporting a second repository type. The
PackageRepository rule is now private and RemotePackageRepository is
used for remote repositories. The new BootstrapPackageRepository rule
is for defining a bootstrap repository (there will probably be only
the HaikuPorts cross repository) whose packages can be built as needed
via haikuporter.
* Rename DownloadPackage to FetchPackage.
* Define repository HaikuPortsCross.
* HaikuCrossDevel package(s): There are now two sets of packages: A
"stage1" set with the same content as before and a final set
additionally containing the libraries libbe, libnetwork, libpackage.
Those are needed for building the libsolv bootstrap package while for
building them we need other bootstrap packages (ICU, libz).

This is basically all that's required to build a bootstrap Haiku
completely from sources, with a few caveats:
* There's no ICU bootstrap recipe yet (so one has to cheat and use the
prebuilt package ATM).
* Probably doesn't work on Haiku yet (tested on Linux only).
* A 32 bit environment must be used (otherwise building the gcc 2
bootstrap package fails).
* Building with multiple jobs doesn't work yet, since haikuporter uses
common directories for building different packages and there's no
explicit serialization yet.
* Haven't tested the resulting image save for booting it. So it probably
needs a bit more work before it can actually build the final
HaikuPorts packages.


# 38f07871cec91f100c3cfa75f89b7daf05d2cf43 12-Jul-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

rule AddRepositoryPackages: add debugInfoPackage parameter

It works just like the sourcePackages parameter.


# 014eed80e289c2bbc187ac91bb7b3a35560a971f 06-Jul-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Change repository directory layout

* Under the base URL there are supposed to be the repository files and a
subdirectory "packages".
* Fix the repository URL related confusion introduced earlier. The URL
in
the repository info (and thus in the repository file) is supposed to
be the base URL for the repository. It is not a (potentially)
different base URL for the package files. Package and repository
files were supposed to live in the same directory. Now, by requiring
the package files to live in a subdirectory -- which can also be a
symlink -- we gain some flexibility.
The URL in the repository config is usually the same as the in the
repository info, unless it refers to a mirror site. This allows for
mirrors to copy the original repository verbatim.
* Remove the PackageURL rule and introduce a DownloadPackage rule
instead. The URL for a package file cannot be computed in the jam
parsing phase anymore, as it contains the hash value of the package
list.
* BRepositoryConfig: Add PackagesURL() for convenience.


# d72ce06673197dbd21336ca8f5618d98487001c8 05-Jul-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Adjust to changed HaikuPorts repository layout

The package kit actually requires the files "repo", "repo.info",
"repo.sha256" to be located under the repository base URL, so the
approach to name the repository file "repo-<hash>" doesn't work.
Now there's a directory "<hash>" which contains the files.

This commit moves the computation of the hash and downloading the
repository file from the build_haiku_image script to the jam build
system. The repo.info is also downloaded and a repository config file
is generated.


# 627626afd42f920d0330655d967ce712e4706396 05-Jul-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

GeneratedRepositoryPackageList: defeat localization

Set LC_ALL=C, so "sort" produces useful results.


# 98c6dfa41e20c57edf426197a8d9aab6223a59fd 05-Jul-2013 Ingo Weinhold <ingo_weinhold@gmx.de>

Switch build system from optional package to repositories

* Build libsolv and the dependency solver part of the package kit for
the build platform.
* Add build tool get_package_dependencies. Given a list of package files
and a list of repository files it determines the additional packages
that need to be retrieved from the repositories and prints their URLs.
* Add rules to work with external repositories in the build system
(build/jam/RepositoryRules):
- PackageRepository declares an external repository with all its
packages. The URL of the repository file isn't specified. It is
computed from a given base URL and the SHA256 hash of the list of
package files.
- GeneratedRepositoryPackageList generates a file containing the file
names of all packages in a repository.
- IsPackageAvailable returns whether a package is available in any
repository.
- PackageURL returns the URL for a package.
* Declare the HaikuPorts repository for x86_gcc2
(build/jam/repositories/HaikuPorts/x86_gcc2).
* Add rule AddHaikuImagePackages to add a package to the image and rule
IsHaikuImagePackageAdded to determine whether a package has been
added.
* OptionalPackages: Remove all entries that just downloaded and
installed an external package. AddHaikuImagePackages can be used
instead and is used in the remaining entries. Also move the remaining
optional package dependency declarations from
OptionalPackageDependencies here.
* ExtractBuildFeatureArchives: Instead of the URL parameter a package
name must be specified now. This allows to simplify BuildFeatures
significantly, since there's no dealing with URLs anymore. "if" out
the entries that aren't supported yet.
* build_haiku_image: For the packages installed in system and common
resolve their dependencies and download and install them as well.