Commit Graph

17 Commits

Author SHA1 Message Date
Jörg Thalheim
324d5b3ee8
Merge pull request #145709 from winterqt/bazel-md5sum
bazel: replace additional usages of md5sum
2021-11-13 22:51:21 +00:00
Winter
21727e4915 bazel: replace additional usages of md5sum 2021-11-12 21:50:32 -05:00
Uri Baghin
61c121424d
bazel_4: link to issue about aarch64-darwin 2021-11-12 21:58:45 +11:00
Uri Baghin
64144e80df bazel_4: disable install check on aarch64-darwin 2021-11-12 10:32:59 +01:00
Sandro Jäckel
8547db919a
treewide: switch `builtins.fromJSON(builtins.readFile ./file.json)` to lib.importJSON ./file.json 2021-11-03 14:43:52 +01:00
Timothy
4b8c664c7e bazel_4: 4.1.0 -> 4.2.1 2021-08-31 02:23:16 +07:00
Dmitry Ivankov
a15204fcc0 bazel_4: 4.0.0 -> 4.1.0
https://github.com/bazelbuild/bazel/releases/tag/4.1.0

other minor changes:
- grep for /bin/ rather than /bin for blanket substitute
- invoke {pre,post}{Build,Install} hooks
2021-05-22 09:51:22 +02:00
Andrew Childs
7869d16545 llvmPackages: Multuple outputs for everythting
Also begin to start work on cross compilation, though that will have to
be finished later.

The patches are based on the first version of
https://reviews.llvm.org/D99484. It's very annoying to do the
back-porting but the review has uncovered nothing super major so I'm
fine sticking with what I've got.

Beyond making the outputs work, I also strove to re-sync the packages,
as they have been drifting pointlessly apart for some time.

----

Other misc notes, highly incomplete

- lvm-config-native and llvm-config are put in `dev` because they are
  tools just for build time.

- Clang no longer has an lld dep. That was introduced in
  db29857eb3, but if clang needs help
  finding lld when it is used we should just pass it flags / put in the
  resource dir. Providing it at build time increases critical path
  length for no good reason.

----

A note on `nativeCC`:

`stdenv` takes tools from the previous stage, so:

1. `pkgsBuildBuild`: `(?1, x, x)`
2. `pkgsBuildBuild.stdenv.cc`: `(?0, ?1, x)`

while:

1. `pkgsBuildBuild`: `(?1, x, x)`
2. `pkgsBuildBuild.targetPackages`: `(x, x, ?2)`
3. `pkgsBuildBuild.targetPackages.stdenv.cc`: `(?1, x, x)`
2021-04-30 05:41:00 +00:00
Matthieu Coudron
810d22fb35
Merge pull request #111975 from teto/bazel-execlog
bazel: add execlog parser
2021-03-22 10:43:17 +01:00
Matthieu Coudron
ef1045cd64 bazel_4: add bazel-execlog binary
similar to what was done for bazel 3
2021-03-17 00:13:58 +01:00
Ben Siraphob
4f0cdb68d7 treewide: unzip buldInputs to nativeBuildInputs (2) 2021-03-06 15:18:05 +07:00
Dmitry Ivankov
cf1935583e bazel_4: update src-deps after java update 2021-02-04 20:38:08 +01:00
Claudio Bley
b56ac70602 bazel_4: Use jdk11_headless to build bazel
Use the same JDK for building bazel and for its runtime.

Effectively, the former `toolchain_hostjdk8` java toolchain has been deprecated
and should no longer be used (in newer bazel)[1]:

```
default_java_toolchain(
    name = "toolchain_hostjdk8",
    ...
)
```

[1]: 4fc4868065/tools/jdk/BUILD.tools (L384-L387)
2021-02-04 20:33:40 +01:00
Claudio Bley
b461c9e5bc bazel_4: Fix build on darwin
* use default stdenv (clang 7)
* add no-arc.patch to make the xcode_locate tool compile without libarc-lite
* remove the `-mmacosx-version-min=10.9` flag from the bootstrap compile script
2021-02-04 20:31:43 +01:00
Dmitry Ivankov
2751275f1a bazel_4: bump examples repo just in case 2021-02-04 20:24:56 +01:00
Dmitry Ivankov
55a810443d bazel_4: use --verbose_failures for the build 2021-02-04 20:24:55 +01:00
Dmitry Ivankov
0f5783f80a bazel_4: init at 4.0.0
Bazel 4 is going to be a long term support release.

Latest version in NixPkgs so far was 3.3.1
There's a need for more recent version
https://github.com/NixOS/nixpkgs/issues/97497

All versions from 3.5.0 to 3.7.1 had some reproducibility issues
as noted in issue above, but there also seems to be
a working PR for 3.7.1 now at
https://github.com/NixOS/nixpkgs/pull/105439

Notable changes from bazel_3 setup:
- put python to default bash path

  For autodetecting python toolchain
  with strict action_env on and without this change
  bazel would fail to autodetect host python.

  There are some repos that define hermetic python
  toolchains, but they aren't easy to use yet. Also
  telling python paths to bazel isn't a 1-liner it
  seems:
  - action_env=PATH would affect cache
  - declaring toolchain via BUILD&WORKSPACE files
    is not per-user but more like per-repo and
    affects cache too

  Using python from nixpkgs shouldn't be too bad
  in the lack of simpler hermetic python toolchain
  options

- bazel_4.updater is bazel on `bazel query` to support
  new constructs in WORKSPACE (load of vars, transitive
  load etc). This is more robust but requires bazel
  to run the updater, using bazel_3 for now. This is
  only needed to bump package version, doesn't introduce
  bazel_4 build dependency on bazel_3

https://blog.bazel.build/2020/11/10/bazel-4.0-announce.html
https://blog.bazel.build/2020/11/10/long-term-support-release.html
https://github.com/bazelbuild/bazel/issues/12455
https://github.com/bazelbuild/bazel/releases/tag/4.0.0
https://blog.bazel.build/2021/01/19/bazel-4-0.html
2021-02-04 20:24:54 +01:00