pgx had been renamed to pgrx in April 2023 already [1]. Newer versions
are already in nixpkgs as pgrx. Since the previous commit removed
the only remaining instance of a package still depending on
pgx 0.6.1, we can now remove all of buildPgxExtension and cargo-pgx.
[1]: https://github.com/pgcentralfoundation/pgrx/issues/1106
postgresql14Packages.promscale_extension breaks with:
Error:
0: `pgx-0.6.1` shouldn't be used with `cargo-pgx-0.7.4`,
please use `pgx = "~0.7.4"` in your `Cargo.toml`.
However, pinning cargo-pgx to 0_6_1 via the following
buildPgxExtension.override { cargo-pgx = cargo-pgx_0_6_1; }
does not work either, because the build then fails with:
thread 'main' panicked at /build/promscale_extension-0.8.0-vendor.tar.gz/proc-macro2/src/fallback.rs:756:9:
"__mbstate_t_union_(unnamed_at_/nix/store/ij144ma6vs8acil8r9hgr8xkb1dp9azg-glibc-2_39-5-dev/include/bits/types/__mbstate_t_h_16_3)" is not a valid Ident
This seems to be related to [1], which indicates that this is a
problem with newer LLVM / clang toolchains.
At the same time th upstream package is deprecated / archived since
the 2nd of April 2024 [2]. Additionally this package is unfree and
thus very unlikely to be forked. Since we can't expect this to be
fixed, the only sensible thing to do is to remove the package.
[1]: https://github.com/rust-lang/rust-bindgen/issues/2312
[2]: https://github.com/timescale/promscale/issues/1836
This was introduced in #228349, but doesn't seem necessary to build for pkgsMusl.
In fact the patch itself seems to be very specific about a stripped down icu
package in Alpine Linux, which does not apply to nixpkgs.
This was disabled to fix#51093. The related discussion upstream revealed that this
has been fixed in [1] for v12+. Since v12 is our oldest supported version right now,
we should be able to safely enable parallel building on darwin again.
Furthermore, it seems that this kind of issue was also fixed in #51221 and #51408
for the general case.
[1]: 826eff57c4
This was introduced in #44083 to fix cross building, where xml2-config
wouldn't run on the host platform. This was fixed upstream two years
later [1], so that from v13 on pkg-config is used before xml2-config is.
Once v12 is EOL, we can remove this entirely.
[1]: 0bc8cebdb8
This was introduced in 65fd8f3f48 around 20 years
ago as LANG=en_US, later changed to LC_ALL=en_US and LC_ALL=C to avoid bash
warnings. This might have been relevant to run initdb during the check phase, but
the PostgreSQL docs [1] say this today:
For implementation reasons, setting LC_ALL does not work for this purpose
Therefore it can be removed safely.
[1]: https://www.postgresql.org/docs/current/regress-run.html#REGRESS-RUN-LOCALE
Trying to understand what each patch does made me come up with some more
descriptive names:
- Renaming the two disable-xxx patches to a common names makes it immediately
clear that one replaces the other depending on version number.
- findstring was really not descriptive at all.
- hardcode-pgxs-path will be extended with more paths for split outputs in
a later commit. Renaming here already to allow git to better track renames.
Finally replacing HARDCODED_PGXS_PATH with $out/lib in the last patch, makes
it easier to understand what the end result will look like when reading the
patch.
More cosmetic than anything else. The description in findstring.patch was
duplicated, postgresql-9.6.1 references confusing. Timestamps are not
needed, that's what git blame is for.
Previously, it was not possible to run tests on an overridden derivation, because
the derivation under test was always pulled from pkgs.
With this change, the following will return the same test:
postgresql_jit.tests
and
(postgresql.override { jitSupport = true; }).tests
pg_safeupdate was updated to 1.5 in #269755. v1.5 is not compatible with
PostgreSQL 12 and 13 anymore, so those were marked as broken.
However, this blocks anyone using PostgreSQL 12 or 13 with pg_safeupdate
from updating nixpkgs.
Instead, the old version should have been kept for PG 12 and 13.
Previously the entire `meta` section from `pg-dump-anon` was copied
over including `mainProgram` which doesn't belong here. To avoid similar
issues, fields from the meta section of pg-dump-anon are copied over
explicitly.
The nixpkgs-unstable channel's programs.sqlite was used to identify
packages producing exactly one binary, and these automatically added
to their package definitions wherever possible.
We have gssSupport, jitSupport and pythonSupport - but enableSystemd?
Across nixpkgs there are currently three styles commonly used, about equally
often: withX, xSupport and enableX.
Let's at least use one consistent style in this package.
This was proposed by abbradar in #150801, but left out of the follow up PR
#221851 by Ma27 to reduce the size of the diff. Compared to the initial
proposal this includes the callPackage call in the recursion, which avoids
breaking the withJIT/withoutJIT helpers.
In terms of nixpkgs, this is a pure refactor, no derivations change. However,
this makes downstream expressions like the following possible:
(postgresql.override { jitSupport = true; }).pkgs.postgis
This would have not worked before without passing another "this" argument,
which is error prone as can be seen in this example:
https://github.com/PostgREST/postgrest/pull/3222/files
This makes it less error-prone to use the llvm package in extensions, because
it will always match the package used by the postgresql derivation itself.
Previously, you could've accidentally used llvm instead of postgresql.llvm
with a different result.
This makes it obvious that the required argument muslPatches must be passed when
creating a new version file.
Pure refactor, not changing any derivations.
This seems to have been introduced 20 years ago in 5863d4f - but
seems to have been a copy&paste mistake from the beginning.
AFAICT, it's not used anywhere.
Refactors some low hanging fruit in default.nix to make it easier to add new
versions later on.
Pure refactor, not changing any derivations.
This change makes it easier to add new versions in default.nix without messing
up - and also prevents us from adding version-specific arguments in default.nix
by accident in the future. Those should be put in the versioned .nix files
instead.
The recommended [1] structure for a package regarding versioning is to have each
version in a separate file. This commit just mechanically copies code around
without any changes.
Pure refactor, not changing any derivations.
[1]: pkgs/README.md
This just renames default.nix to generic.nix, because the biggest chunk
of code should move that way in the next commit. This gives us a much
better diff for the next commit and makes rebasing **much** easier in
case of changes. This commit does not stand on its own and needs to go
in with the next commit (2/2).
This commit is split up into two commits to allow git to detect renames,
make rebasing easier and allow a working entry in .git-blame-ignore-revs.
To allow bisecting we allow evaluation on every commit by moving the extensions
into ext/ext/ first and back to ext/ with the next commit.
This is a Go program inside the sources of `postgresql_anonymizer` that
allows to perform database dumps, but with anonymized data. I figured
that it's a little awkward to have a client program to be part of the
extension package.
So I decided to create a second package called `pg-dump-anon`. Since
it's one repository, both share `version` & `src`.
Also extended the VM test to make sure we're getting properly anonymized
data when dumping with `pg_dump_anon`.
- merge libcxxabi into libcxx for LLVM 12, 13, 14, 15, 16, 17, and git.
- remove the link time workaround `-lc++ -lc++abi` from 58 packages as it is no longer required.
- fixes https://github.com/NixOS/nixpkgs/issues/166205
- provides alternative fixes for. https://github.com/NixOS/nixpkgs/issues/269548https://github.com/NixOS/nix/issues/9640
- pkgsCross.x86_64-freebsd builds work again
This change can be represented in 3 stages
1. merge libcxxabi into libcxx -- files: pkgs/development/compilers/llvm/[12, git]/{libcxx, libcxxabi}
2. update stdenv to account for merge -- files: stdenv.{adapters, cc.wrapper, darwin}
3. remove all references to libcxxabi outside of llvm (about 58 packages modified)
### merging libcxxabi into libcxx
- take the union of the libcxxabi and libcxx cmake flags
- eliminate the libcxx-headers-only package - it was only needed to break libcxx <-> libcxxabi circular dependency
- libcxx.cxxabi is removed. external cxxabi (freebsd) will symlink headers / libs into libcxx.
- darwin will re-export the libcxxabi symbols into libcxx so linking `-lc++` is sufficient.
- linux/freebsd `libc++.so` is a linker script `LINK(libc++.so.1, -lc++abi)` making `-lc++` sufficient.
- libcxx/default.nix [12, 17] are identical except for patches and `LIBCXX_ADDITIONAL_LIBRARIES` (only used in 16+)
- git/libcxx/defaul.nix does not link with -nostdlib when useLLVM is true so flag is removed. this is not much different than before as libcxxabi used -nostdlib where libcxx did not, so libc was linked in anyway.
### stdenv changes
- darwin bootstrap, remove references to libcxxabi and cxxabi
- cc-wrapper: remove c++ link workaround when libcxx.cxxabi doesn't exist (still exists for LLVM pre 12)
- adapter: update overrideLibcxx to account for a pkgs.stdenv that only has libcxx
### 58 package updates
- remove `NIX_LDFLAGS = "-l${stdenv.cc.libcxx.cxxabi.libName}` as no longer needed
- swift, nodejs_v8 remove libcxxabi references in the clang override
https://github.com/NixOS/nixpkgs/pull/292043
https://github.com/plv8/plv8/blob/v3.1.10/Changes
3.1.10 is currently not the latest version - 3.2.2 is. However, the 3.2 branch needs
more changes to build successfully. The update to 3.1.10 makes this package build
with postgresql_16 for now.
This failed because libpam, which postgresql is now linked against, was missing as a
build input. In general, this is an indication that this extension needs the same
build inputs that postgresql was built with - so we just pass those instead.
This makes similar build failures less likely in the future.
This failed because libpam, which postgresql is now linked against, was missing as a
build input. In general, this is an indication that this extension needs the same
build inputs that postgresql was built with - so we just pass those instead.
This makes similar build failures less likely in the future.
This failed because libxcrypt, which pg12 is linked against, was missing as a
build input. In general, this is an indication that this extension needs the
same build inputs that postgresql was built with - so we just pass those instead.
This makes similar build failures less likely in the future.