Merge master into staging-next
This commit is contained in:
commit
4d374190e7
|
@ -158,6 +158,8 @@ In addition to numerous new and upgraded packages, this release has the followin
|
|||
|
||||
- [ivpn](https://www.ivpn.net/), a secure, private VPN with fast WireGuard connections. Available as [services.ivpn](#opt-services.ivpn.enable).
|
||||
|
||||
- [openvscode-server](https://github.com/gitpod-io/openvscode-server), run VS Code on a remote machine with access through a modern web browser from any device, anywhere. Available as [services.openvscode-server](#opt-services.openvscode-server.enable).
|
||||
|
||||
## Backward Incompatibilities {#sec-release-23.05-incompatibilities}
|
||||
|
||||
<!-- To avoid merge conflicts, consider adding your item at an arbitrary place in the list instead. -->
|
||||
|
|
|
@ -1214,6 +1214,7 @@
|
|||
./services/web-apps/nifi.nix
|
||||
./services/web-apps/node-red.nix
|
||||
./services/web-apps/onlyoffice.nix
|
||||
./services/web-apps/openvscode-server.nix
|
||||
./services/web-apps/openwebrx.nix
|
||||
./services/web-apps/outline.nix
|
||||
./services/web-apps/peering-manager.nix
|
||||
|
|
211
nixos/modules/services/web-apps/openvscode-server.nix
Normal file
211
nixos/modules/services/web-apps/openvscode-server.nix
Normal file
|
@ -0,0 +1,211 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
let
|
||||
cfg = config.services.openvscode-server;
|
||||
defaultUser = "openvscode-server";
|
||||
defaultGroup = defaultUser;
|
||||
in {
|
||||
options = {
|
||||
services.openvscode-server = {
|
||||
enable = lib.mkEnableOption (lib.mdDoc "openvscode-server");
|
||||
|
||||
package = lib.mkPackageOptionMD pkgs "openvscode-server" { };
|
||||
|
||||
extraPackages = lib.mkOption {
|
||||
default = [ ];
|
||||
description = lib.mdDoc ''
|
||||
Additional packages to add to the openvscode-server {env}`PATH`.
|
||||
'';
|
||||
example = lib.literalExpression "[ pkgs.go ]";
|
||||
type = lib.types.listOf lib.types.package;
|
||||
};
|
||||
|
||||
extraEnvironment = lib.mkOption {
|
||||
type = lib.types.attrsOf lib.types.str;
|
||||
description = lib.mdDoc ''
|
||||
Additional environment variables to pass to openvscode-server.
|
||||
'';
|
||||
default = { };
|
||||
example = { PKG_CONFIG_PATH = "/run/current-system/sw/lib/pkgconfig"; };
|
||||
};
|
||||
|
||||
extraArguments = lib.mkOption {
|
||||
default = [ ];
|
||||
description = lib.mdDoc ''
|
||||
Additional arguments to pass to openvscode-server.
|
||||
'';
|
||||
example = lib.literalExpression ''[ "--log=info" ]'';
|
||||
type = lib.types.listOf lib.types.str;
|
||||
};
|
||||
|
||||
host = lib.mkOption {
|
||||
default = "localhost";
|
||||
description = lib.mdDoc ''
|
||||
The host name or IP address the server should listen to.
|
||||
'';
|
||||
type = lib.types.str;
|
||||
};
|
||||
|
||||
port = lib.mkOption {
|
||||
default = 3000;
|
||||
description = lib.mdDoc ''
|
||||
The port the server should listen to. If 0 is passed a random free port is picked. If a range in the format num-num is passed, a free port from the range (end inclusive) is selected.
|
||||
'';
|
||||
type = lib.types.port;
|
||||
};
|
||||
|
||||
user = lib.mkOption {
|
||||
default = defaultUser;
|
||||
example = "yourUser";
|
||||
description = lib.mdDoc ''
|
||||
The user to run openvscode-server as.
|
||||
By default, a user named `${defaultUser}` will be created.
|
||||
'';
|
||||
type = lib.types.str;
|
||||
};
|
||||
|
||||
group = lib.mkOption {
|
||||
default = defaultGroup;
|
||||
example = "yourGroup";
|
||||
description = lib.mdDoc ''
|
||||
The group to run openvscode-server under.
|
||||
By default, a group named `${defaultGroup}` will be created.
|
||||
'';
|
||||
type = lib.types.str;
|
||||
};
|
||||
|
||||
extraGroups = lib.mkOption {
|
||||
default = [ ];
|
||||
description = lib.mdDoc ''
|
||||
An array of additional groups for the `${defaultUser}` user.
|
||||
'';
|
||||
example = [ "docker" ];
|
||||
type = lib.types.listOf lib.types.str;
|
||||
};
|
||||
|
||||
withoutConnectionToken = lib.mkOption {
|
||||
default = false;
|
||||
description = lib.mdDoc ''
|
||||
Run without a connection token. Only use this if the connection is secured by other means.
|
||||
'';
|
||||
example = true;
|
||||
type = lib.types.bool;
|
||||
};
|
||||
|
||||
socketPath = lib.mkOption {
|
||||
default = null;
|
||||
example = "/run/openvscode/socket";
|
||||
description = lib.mdDoc ''
|
||||
The path to a socket file for the server to listen to.
|
||||
'';
|
||||
type = lib.types.nullOr lib.types.str;
|
||||
};
|
||||
|
||||
userDataDir = lib.mkOption {
|
||||
default = null;
|
||||
description = lib.mdDoc ''
|
||||
Specifies the directory that user data is kept in. Can be used to open multiple distinct instances of Code.
|
||||
'';
|
||||
type = lib.types.nullOr lib.types.str;
|
||||
};
|
||||
|
||||
serverDataDir = lib.mkOption {
|
||||
default = null;
|
||||
description = lib.mdDoc ''
|
||||
Specifies the directory that server data is kept in.
|
||||
'';
|
||||
type = lib.types.nullOr lib.types.str;
|
||||
};
|
||||
|
||||
extensionsDir = lib.mkOption {
|
||||
default = null;
|
||||
description = lib.mdDoc ''
|
||||
Set the root path for extensions.
|
||||
'';
|
||||
type = lib.types.nullOr lib.types.str;
|
||||
};
|
||||
|
||||
telemetryLevel = lib.mkOption {
|
||||
default = "off";
|
||||
example = "crash";
|
||||
description = lib.mdDoc ''
|
||||
Sets the initial telemetry level. Valid levels are: 'off', 'crash', 'error' and 'all'.
|
||||
'';
|
||||
type = lib.types.str;
|
||||
};
|
||||
|
||||
connectionToken = lib.mkOption {
|
||||
default = null;
|
||||
example = "secret-token";
|
||||
description = lib.mdDoc ''
|
||||
A secret that must be included with all requests.
|
||||
'';
|
||||
type = lib.types.nullOr lib.types.str;
|
||||
};
|
||||
|
||||
connectionTokenFile = lib.mkOption {
|
||||
default = null;
|
||||
description = lib.mdDoc ''
|
||||
Path to a file that contains the connection token.
|
||||
'';
|
||||
type = lib.types.nullOr lib.types.str;
|
||||
};
|
||||
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
systemd.services.openvscode-server = {
|
||||
description = "OpenVSCode server";
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
after = [ "network-online.target" ];
|
||||
path = cfg.extraPackages;
|
||||
environment = cfg.extraEnvironment;
|
||||
serviceConfig = {
|
||||
ExecStart = ''
|
||||
${lib.getExe cfg.package} \
|
||||
--accept-server-license-terms \
|
||||
--host=${cfg.host} \
|
||||
--port=${toString cfg.port} \
|
||||
'' + lib.optionalString (cfg.telemetryLevel == true) ''
|
||||
--telemetry-level=${cfg.telemetryLevel} \
|
||||
'' + lib.optionalString (cfg.withoutConnectionToken == true) ''
|
||||
--without-connection-token \
|
||||
'' + lib.optionalString (cfg.socketPath != null) ''
|
||||
--socket-path=${cfg.socketPath} \
|
||||
'' + lib.optionalString (cfg.userDataDir != null) ''
|
||||
--user-data-dir=${cfg.userDataDir} \
|
||||
'' + lib.optionalString (cfg.serverDataDir != null) ''
|
||||
--server-data-dir=${cfg.serverDataDir} \
|
||||
'' + lib.optionalString (cfg.extensionsDir != null) ''
|
||||
--extensions-dir=${cfg.extensionsDir} \
|
||||
'' + lib.optionalString (cfg.connectionToken != null) ''
|
||||
--connection-token=${cfg.connectionToken} \
|
||||
'' + lib.optionalString (cfg.connectionTokenFile != null) ''
|
||||
--connection-token-file=${cfg.connectionTokenFile} \
|
||||
'' + lib.escapeShellArgs cfg.extraArguments;
|
||||
ExecReload = "${pkgs.coreutils}/bin/kill -HUP $MAINPID";
|
||||
RuntimeDirectory = cfg.user;
|
||||
User = cfg.user;
|
||||
Group = cfg.group;
|
||||
Restart = "on-failure";
|
||||
};
|
||||
};
|
||||
|
||||
users.users."${cfg.user}" = lib.mkMerge [
|
||||
(lib.mkIf (cfg.user == defaultUser) {
|
||||
isNormalUser = true;
|
||||
description = "openvscode-server user";
|
||||
inherit (cfg) group;
|
||||
})
|
||||
{
|
||||
packages = cfg.extraPackages;
|
||||
inherit (cfg) extraGroups;
|
||||
}
|
||||
];
|
||||
|
||||
users.groups."${defaultGroup}" = lib.mkIf (cfg.group == defaultGroup) { };
|
||||
};
|
||||
|
||||
meta.maintainers = [ lib.maintainers.drupol ];
|
||||
}
|
|
@ -554,6 +554,7 @@ in {
|
|||
opentabletdriver = handleTest ./opentabletdriver.nix {};
|
||||
owncast = handleTest ./owncast.nix {};
|
||||
image-contents = handleTest ./image-contents.nix {};
|
||||
openvscode-server = handleTest ./openvscode-server.nix {};
|
||||
orangefs = handleTest ./orangefs.nix {};
|
||||
os-prober = handleTestOn ["x86_64-linux"] ./os-prober.nix {};
|
||||
osrm-backend = handleTest ./osrm-backend.nix {};
|
||||
|
|
22
nixos/tests/openvscode-server.nix
Normal file
22
nixos/tests/openvscode-server.nix
Normal file
|
@ -0,0 +1,22 @@
|
|||
import ./make-test-python.nix ({pkgs, lib, ...}:
|
||||
{
|
||||
name = "openvscode-server";
|
||||
|
||||
nodes = {
|
||||
machine = {pkgs, ...}: {
|
||||
services.openvscode-server = {
|
||||
enable = true;
|
||||
withoutConnectionToken = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
testScript = ''
|
||||
start_all()
|
||||
machine.wait_for_unit("openvscode-server.service")
|
||||
machine.wait_for_open_port(3000)
|
||||
machine.succeed("curl -k --fail http://localhost:3000", timeout=10)
|
||||
'';
|
||||
|
||||
meta.maintainers = [ lib.maintainers.drupol ];
|
||||
})
|
|
@ -2,13 +2,13 @@
|
|||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "wolf-shaper";
|
||||
version = "1.0.1";
|
||||
version = "1.0.2";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "pdesaulniers";
|
||||
repo = "wolf-shaper";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-xy6ZebabTRLo/Xk2OMoR4xtxmZsqYXaUHUebuDrHOvA=";
|
||||
sha256 = "sha256-4oi1wnex6eNRHUWXZHnvrmqp4veFuPJqD0YuOhDepg4=";
|
||||
fetchSubmodules = true;
|
||||
};
|
||||
|
||||
|
|
|
@ -5,23 +5,13 @@
|
|||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "icon-library";
|
||||
version = "0.0.11";
|
||||
version = "0.0.16";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://gitlab.gnome.org/World/design/icon-library/uploads/93d183b17d216bbed7b03b2f3698059c/icon-library-${version}.tar.xz";
|
||||
sha256 = "1zrcnc5dn5fgcl3vklfpbp3m0qzi2n2viw59vw5fhwkysvp670y7";
|
||||
url = "https://gitlab.gnome.org/World/design/icon-library/uploads/5dd3d97acfdbaf69c7dc6b2f7bbf4cae/icon-library-${version}.tar.xz";
|
||||
hash = "sha256-EO67foD/uRoeF+zmJyEia5Nr3eW+Se9bVjDxipMw75E=";
|
||||
};
|
||||
|
||||
patches = [
|
||||
# Fix build with meson 0.61
|
||||
# data/meson.build:85:0: ERROR: gnome.compile_resources takes exactly 2 arguments, but got 3.
|
||||
# https://gitlab.gnome.org/World/design/icon-library/-/merge_requests/54
|
||||
(fetchpatch {
|
||||
url = "https://gitlab.gnome.org/World/design/icon-library/-/commit/c629dbf6670f9bb0b98ff21c17110489b58f5c85.patch";
|
||||
sha256 = "UKC1CPaM58/z0zINN794luWZdoFx1zGxETPb8VtbO3E=";
|
||||
})
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
cargo desktop-file-utils meson ninja pkg-config rustc wrapGAppsHook4
|
||||
];
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
, spaceNavSupport ? stdenv.isLinux, libspnav
|
||||
, makeWrapper
|
||||
, pugixml, llvmPackages, SDL, Cocoa, CoreGraphics, ForceFeedback, OpenAL, OpenGL
|
||||
, waylandSupport ? stdenv.isLinux, pkg-config, wayland, wayland-protocols, libffi, libdecor, libxkbcommon, dbus
|
||||
, potrace
|
||||
, openxr-loader
|
||||
, embree, gmp, libharu
|
||||
|
@ -36,8 +37,11 @@ stdenv.mkDerivation rec {
|
|||
|
||||
patches = lib.optional stdenv.isDarwin ./darwin.patch;
|
||||
|
||||
nativeBuildInputs = [ cmake makeWrapper python310Packages.wrapPython llvmPackages.llvm.dev ]
|
||||
++ lib.optionals cudaSupport [ addOpenGLRunpath ];
|
||||
nativeBuildInputs =
|
||||
[ cmake makeWrapper python310Packages.wrapPython llvmPackages.llvm.dev
|
||||
]
|
||||
++ lib.optionals cudaSupport [ addOpenGLRunpath ]
|
||||
++ lib.optionals waylandSupport [ pkg-config ];
|
||||
buildInputs =
|
||||
[ boost ffmpeg gettext glew ilmbase
|
||||
freetype libjpeg libpng libsamplerate libsndfile libtiff libwebp
|
||||
|
@ -51,6 +55,9 @@ stdenv.mkDerivation rec {
|
|||
libharu
|
||||
libepoxy
|
||||
]
|
||||
++ lib.optionals waylandSupport [
|
||||
wayland wayland-protocols libffi libdecor libxkbcommon dbus
|
||||
]
|
||||
++ lib.optionals (!stdenv.isAarch64) [
|
||||
openimagedenoise
|
||||
embree
|
||||
|
@ -124,6 +131,12 @@ stdenv.mkDerivation rec {
|
|||
"-DWITH_IMAGE_OPENJPEG=ON"
|
||||
"-DWITH_OPENCOLLADA=${if colladaSupport then "ON" else "OFF"}"
|
||||
]
|
||||
++ lib.optionals waylandSupport [
|
||||
"-DWITH_GHOST_WAYLAND=ON"
|
||||
"-DWITH_GHOST_WAYLAND_DBUS=ON"
|
||||
"-DWITH_GHOST_WAYLAND_DYNLOAD=OFF"
|
||||
"-DWITH_GHOST_WAYLAND_LIBDECOR=ON"
|
||||
]
|
||||
++ lib.optionals stdenv.hostPlatform.isAarch64 [
|
||||
"-DWITH_CYCLES_EMBREE=OFF"
|
||||
]
|
||||
|
|
|
@ -8,16 +8,16 @@
|
|||
|
||||
rustPlatform.buildRustPackage rec {
|
||||
pname = "cotp";
|
||||
version = "1.2.3";
|
||||
version = "1.2.4";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "replydev";
|
||||
repo = "cotp";
|
||||
rev = "v${version}";
|
||||
hash = "sha256-Pg07iq2jj8cUA4iQsY52cujmUZLYrbTG5Zj+lITxpls=";
|
||||
hash = "sha256-OrtVUQikEmrLBrP8ZLbi/+dDi/6FXYC5MOYt3WWU77Y=";
|
||||
};
|
||||
|
||||
cargoHash = "sha256-9jOrDFLnzjxqN2h6e1/qKRn5RQKlfyeKKmjZthQX3jM=";
|
||||
cargoHash = "sha256-TFX5Q9wI5w38wlDSP+peNTbp+cdL6oCOUZ2FFPCOUnM=";
|
||||
|
||||
buildInputs = lib.optionals stdenv.isLinux [ libxcb ]
|
||||
++ lib.optionals stdenv.isDarwin [ AppKit ];
|
||||
|
|
|
@ -2,13 +2,13 @@
|
|||
|
||||
buildGoModule rec {
|
||||
pname = "nova";
|
||||
version = "3.6.3";
|
||||
version = "3.6.4";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "FairwindsOps";
|
||||
repo = pname;
|
||||
rev = version;
|
||||
hash = "sha256-bu0iIhoRRi2dzBGGjWy9YJVSHtdO3T1NkLpGMseyK/E=";
|
||||
hash = "sha256-6gTrBogMvM7X6PFthG+c8N9wXoNHwp0wHjGVKjiHJJY=";
|
||||
};
|
||||
|
||||
vendorHash = "sha256-YvYfSb2ZC86S2osFRG7Ep9nrgYJV0tB8fBgZQZ07t2U=";
|
||||
|
|
|
@ -2,16 +2,16 @@
|
|||
|
||||
buildGoModule rec {
|
||||
pname = "talosctl";
|
||||
version = "1.4.1";
|
||||
version = "1.4.4";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "siderolabs";
|
||||
repo = "talos";
|
||||
rev = "v${version}";
|
||||
hash = "sha256-ZnVqpJ62X6JlL/yAjpdh8e3U6Lvs/GncCkKU42GRI/Q=";
|
||||
hash = "sha256-BjNJIHPFAytiZIrHPcEuxYCXlp35kMR3OA3KXOdBj8w=";
|
||||
};
|
||||
|
||||
vendorHash = "sha256-1YHYDC22yvtADOIuYxzonV7yaLsQOFELwEEXvu77JdE=";
|
||||
vendorHash = "sha256-btZHQ0sqgbMm0WWswY9ChNNtXX/xedv/d0BrO03MBns=";
|
||||
|
||||
ldflags = [ "-s" "-w" ];
|
||||
|
||||
|
|
|
@ -14,11 +14,11 @@
|
|||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "mate-media";
|
||||
version = "1.26.0";
|
||||
version = "1.26.1";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://pub.mate-desktop.org/releases/${lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
|
||||
sha256 = "0fiwzsir8i1bqz7g7b20g5zs28qq63j41v9c5z69q8fq7wh1nwwb";
|
||||
sha256 = "KLKiGiltkVx8BtnSFvSahUHNPOyJWzJZvKBoqF4m6ws=";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
|
|
|
@ -17,11 +17,11 @@
|
|||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "mate-screensaver";
|
||||
version = "1.26.1";
|
||||
version = "1.26.2";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://pub.mate-desktop.org/releases/${lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
|
||||
sha256 = "T72yHqSlnqjeM+qb93bYaXU+SSlWBGZMMOIg4JZZuLw=";
|
||||
sha256 = "2pcAziQUW9VdJJJ+7P5tMdClLq6G5WOyxlBUs1al/34=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
|
|
|
@ -15,11 +15,11 @@
|
|||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "mate-themes";
|
||||
version = "3.22.23";
|
||||
version = "3.22.24";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://pub.mate-desktop.org/releases/themes/${lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
|
||||
sha256 = "1avgzccdmr7y18rnp3xrhwk82alv2dlig3wh7ivgahcqdiiavrb1";
|
||||
sha256 = "PYs6KihTMd4kxM9djJ3YRtqhFpXyBnZdjxaT68rPbko=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
|
|
|
@ -2,12 +2,29 @@
|
|||
|
||||
let
|
||||
version = "weekly.2023.19";
|
||||
ptraceSubstitution = ''
|
||||
#include <sys/types.h>
|
||||
#include <sys/ptrace.h>
|
||||
'';
|
||||
# Required for bootstrap.
|
||||
vc = fetchFromGitHub {
|
||||
owner = "vlang";
|
||||
repo = "vc";
|
||||
rev = "f7c2b5f2a0738d0d236161c9de9f31dd0280ac86";
|
||||
sha256 = "sha256-xU3TvyNgc0o4RCsHtoC6cZTNaue2yuAiolEOvP37TKA=";
|
||||
vc = stdenv.mkDerivation {
|
||||
pname = "v.c";
|
||||
version = "unstable-2023-05-14";
|
||||
src = fetchFromGitHub {
|
||||
owner = "vlang";
|
||||
repo = "vc";
|
||||
rev = "f7c2b5f2a0738d0d236161c9de9f31dd0280ac86";
|
||||
sha256 = "sha256-xU3TvyNgc0o4RCsHtoC6cZTNaue2yuAiolEOvP37TKA=";
|
||||
};
|
||||
|
||||
# patch the ptrace reference for darwin
|
||||
installPhase = lib.optionalString stdenv.isDarwin ''
|
||||
substituteInPlace v.c \
|
||||
--replace "#include <sys/ptrace.h>" "${ptraceSubstitution}"
|
||||
'' + ''
|
||||
mkdir -p $out
|
||||
cp v.c $out/
|
||||
'';
|
||||
};
|
||||
# Required for vdoc.
|
||||
markdown = fetchFromGitHub {
|
||||
|
@ -38,11 +55,15 @@ stdenv.mkDerivation {
|
|||
];
|
||||
|
||||
env.VC = vc;
|
||||
# libX11.dev and xorg.xorgproto are needed because of
|
||||
# builder error: Header file <X11/Xlib.h>, needed for module `clipboard.x11` was not found. Please install a package with the X11 development headers, for example: `apt-get install libx11-dev`.
|
||||
# libXau, libxcb, libXdmcp need to be static if you use static gcc otherwise
|
||||
# /nix/store/xnk2z26fqy86xahiz3q797dzqx96sidk-glibc-2.37-8/lib/libc.so.6: undefined reference to `_rtld_glob al_ro@GLIBC_PRIVATE'
|
||||
env.VFLAGS = "-cc ${pkgsStatic.gcc}/bin/gcc -no-retry-compilation -cflags -I${xorg.libX11.dev}/include -cflags -I${xorg.xorgproto}/include -ldflags -L${binaryen}/lib -ldflags -L${pkgsStatic.xorg.libX11}/lib -ldflags -L${pkgsStatic.xorg.libxcb}/lib -ldflags -lxcb -ldflags -L${pkgsStatic.xorg.libXau}/lib -ldflags -lXau -ldflags -L${pkgsStatic.xorg.libXdmcp}/lib -ldflags -lXdmcp";
|
||||
env.VFLAGS = if stdenv.isDarwin then
|
||||
# on darwin we need to add a manual link to libgc since it doesn't have a libgc.a
|
||||
"-cg -cc ${pkgsStatic.clang}/bin/clang -no-retry-compilation -ldflags -L${pkgsStatic.boehmgc}/lib -ldflags -lgc -ldflags -L${binaryen}/lib"
|
||||
else
|
||||
# libX11.dev and xorg.xorgproto are needed because of
|
||||
# builder error: Header file <X11/Xlib.h>, needed for module `clipboard.x11` was not found. Please install a package with the X11 development headers, for example: `apt-get install libx11-dev`.
|
||||
# libXau, libxcb, libXdmcp need to be static if you use static gcc otherwise
|
||||
# /nix/store/xnk2z26fqy86xahiz3q797dzqx96sidk-glibc-2.37-8/lib/libc.so.6: undefined reference to `_rtld_glob al_ro@GLIBC_PRIVATE'
|
||||
"-cc ${pkgsStatic.gcc}/bin/gcc -no-retry-compilation -cflags -I${xorg.libX11.dev}/include -cflags -I${xorg.xorgproto}/include -ldflags -L${binaryen}/lib -ldflags -L${pkgsStatic.xorg.libX11}/lib -ldflags -L${pkgsStatic.xorg.libxcb}/lib -ldflags -lxcb -ldflags -L${pkgsStatic.xorg.libXau}/lib -ldflags -lXau -ldflags -L${pkgsStatic.xorg.libXdmcp}/lib -ldflags -lXdmcp";
|
||||
|
||||
preBuild = ''
|
||||
export HOME=$(mktemp -d)
|
||||
|
@ -51,6 +72,11 @@ stdenv.mkDerivation {
|
|||
# we don't use tcc at all since it fails on a missing libatomic
|
||||
ln -s ${pkgsStatic.tinycc}/bin/tcc ./thirdparty/tcc/tcc.exe
|
||||
cp -r ${pkgsStatic.boehmgc}/lib/* ./thirdparty/tcc/lib
|
||||
'' + lib.optionalString stdenv.isDarwin ''
|
||||
# this file isn't used by clang, but it's just to silence a warning
|
||||
# the compiler complains on an empty file, so this makes it "close" to real
|
||||
substituteInPlace vlib/builtin/builtin_d_gcboehm.c.v \
|
||||
--replace "libgc.a" "libgc.la"
|
||||
'';
|
||||
|
||||
# vcreate_test.v requires git, so we must remove it when building the tools.
|
||||
|
|
|
@ -11,13 +11,13 @@
|
|||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "libspng";
|
||||
version = "0.7.3";
|
||||
version = "0.7.4";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "randy408";
|
||||
repo = pname;
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-t5qVhRxepl1rOQk/F5GhcvU1nk9oGb+kWXmybP+iAfY=";
|
||||
sha256 = "sha256-BiRuPQEKVJYYgfUsglIuxrBoJBFiQ0ygQmAFrVvCz4Q=";
|
||||
};
|
||||
|
||||
doCheck = true;
|
||||
|
|
|
@ -217,8 +217,8 @@ let
|
|||
pname = "facts";
|
||||
version = "0.1-632217602";
|
||||
src = pkgs.fetchzip {
|
||||
url = "https://github.com/facts-db/cl-lessp/archive/632217602b85b679e8d420654a0aa39e798ca3b5.tar.gz";
|
||||
sha256 = "09z1vwzjm7hlb529jl3hcjnfd11gh128lmdg51im7ar4jv4746iw";
|
||||
url = "https://beta.quicklisp.org/archive/cl-facts/2022-11-06/cl-facts-20221106-git.tgz";
|
||||
sha256 = "sha256-PBpyyJYkq1NjKK9VikSAL4TmrGRwUJlEWRSeKj/f4Sc=";
|
||||
};
|
||||
lispLibs = [ self.lessp self.rollback ] ++ [ super.local-time ];
|
||||
};
|
||||
|
|
|
@ -4,11 +4,11 @@ buildDunePackage rec {
|
|||
minimalOCamlVersion = "4.08";
|
||||
|
||||
pname = "ounit2";
|
||||
version = "2.2.6";
|
||||
version = "2.2.7";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://github.com/gildor478/ounit/releases/download/v${version}/ounit-${version}.tbz";
|
||||
hash = "sha256-BpD7Hg6QoY7tXDVms8wYJdmLDox9UbtrhGyVxFphWRM=";
|
||||
hash = "sha256-kPbmO9EkClHYubL3IgWb15zgC1J2vdYji49cYTwOc4g=";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = [ seq stdlib-shims ];
|
||||
|
|
|
@ -24,11 +24,11 @@
|
|||
|
||||
buildPythonPackage rec {
|
||||
pname = "ansible-core";
|
||||
version = "2.14.2";
|
||||
version = "2.15.0";
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
hash = "sha256-R/DUtBJbWO26ZDWkfzfL5qGNpUWU0Y+BKVi7DLWNTmU=";
|
||||
hash = "sha256-z2kP1Ou0BZDgDFrNwGJHWMpMWNHksrAuwCagNAcOv00=";
|
||||
};
|
||||
|
||||
# ansible_connection is already wrapped, so don't pass it through
|
||||
|
|
|
@ -0,0 +1,21 @@
|
|||
From: Jochen Sprickerhof <jspricke@debian.org>
|
||||
Date: Thu, 15 Dec 2022 07:44:54 +0100
|
||||
Subject: Don't mock list subclass
|
||||
|
||||
---
|
||||
tests/unit/ec2/test_volume.py | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/tests/unit/ec2/test_volume.py b/tests/unit/ec2/test_volume.py
|
||||
index 81d7f55..d4d8e4f 100644
|
||||
--- a/tests/unit/ec2/test_volume.py
|
||||
+++ b/tests/unit/ec2/test_volume.py
|
||||
@@ -55,7 +55,7 @@ class VolumeTests(unittest.TestCase):
|
||||
@mock.patch("boto.resultset.ResultSet")
|
||||
def test_startElement_with_name_tagSet_calls_ResultSet(self, ResultSet, startElement):
|
||||
startElement.return_value = None
|
||||
- result_set = mock.Mock(ResultSet([("item", Tag)]))
|
||||
+ result_set = ResultSet([("item", Tag)])
|
||||
volume = Volume()
|
||||
volume.tags = result_set
|
||||
retval = volume.startElement("tagSet", None, None)
|
|
@ -22,6 +22,9 @@ buildPythonPackage rec {
|
|||
# fixes hmac tests
|
||||
# https://sources.debian.org/src/python-boto/2.49.0-4/debian/patches/bug-953970_python3.8-compat.patch/
|
||||
./bug-953970_python3.8-compat.patch
|
||||
# fixes test_startElement_with_name_tagSet_calls_ResultSet
|
||||
# https://sources.debian.org/src/python-boto/2.49.0-4.1/debian/patches/0005-Don-t-mock-list-subclass.patch/
|
||||
./0005-Don-t-mock-list-subclass.patch
|
||||
];
|
||||
|
||||
# boto is deprecated by upstream as of 2021-05-27 (https://github.com/boto/boto/commit/4980ac58764c3d401cb0b9552101f9c61c18f445)
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
|
||||
buildPythonPackage rec {
|
||||
pname = "dvc-data";
|
||||
version = "0.50.0";
|
||||
version = "0.51.0";
|
||||
format = "pyproject";
|
||||
|
||||
disabled = pythonOlder "3.8";
|
||||
|
@ -24,7 +24,7 @@ buildPythonPackage rec {
|
|||
owner = "iterative";
|
||||
repo = pname;
|
||||
rev = "refs/tags/${version}";
|
||||
hash = "sha256-TWn+9u+m9CwRoJRcFvRT45TXq7U08nc/3NLDKshNcJc=";
|
||||
hash = "sha256-kLxwBFDoGEZ8w3PHEh8IVDEbmlbwazhZBAoBAUQFDEo=";
|
||||
};
|
||||
|
||||
SETUPTOOLS_SCM_PRETEND_VERSION = version;
|
||||
|
|
|
@ -1,25 +1,76 @@
|
|||
{ buildPythonPackage, lib, libffi, isPy3k, pyasn1, clint, ndg-httpsclient
|
||||
, protobuf, requests, args, matlink-gpapi, pyaxmlparser, setuptools, fetchFromGitHub
|
||||
{ lib
|
||||
, args
|
||||
, buildPythonPackage
|
||||
, clint
|
||||
, fetchFromGitHub
|
||||
, libffi
|
||||
, matlink-gpapi
|
||||
, ndg-httpsclient
|
||||
, protobuf
|
||||
, pyasn1
|
||||
, pyaxmlparser
|
||||
, pytestCheckHook
|
||||
, pythonOlder
|
||||
, requests
|
||||
, setuptools
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "gplaycli";
|
||||
version = "3.29";
|
||||
format = "setuptools";
|
||||
|
||||
disabled = pythonOlder "3.6";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "matlink";
|
||||
repo = "gplaycli";
|
||||
rev = version;
|
||||
sha256 = "10gc1wr259z5hxyk834wyyggvyh82agfq0zp711s4jf334inp45r";
|
||||
rev = "refs/tags/${version}";
|
||||
hash = "sha256-uZBrIxnDSaJDOPcD7J4SCPr9nvecDDR9h+WnIjIP7IE=";
|
||||
};
|
||||
|
||||
disabled = !isPy3k;
|
||||
propagatedBuildInputs = [
|
||||
libffi
|
||||
pyasn1
|
||||
clint
|
||||
ndg-httpsclient
|
||||
protobuf
|
||||
requests
|
||||
args
|
||||
matlink-gpapi
|
||||
pyaxmlparser
|
||||
setuptools
|
||||
];
|
||||
|
||||
propagatedBuildInputs = [ libffi pyasn1 clint ndg-httpsclient protobuf requests args matlink-gpapi pyaxmlparser setuptools ];
|
||||
nativeCheckInputs = [
|
||||
pytestCheckHook
|
||||
];
|
||||
|
||||
pythonImportsCheck = [
|
||||
"gplaycli"
|
||||
];
|
||||
|
||||
preCheck = ''
|
||||
export PATH="$PATH:$out/bin";
|
||||
'';
|
||||
|
||||
disabledTests = [
|
||||
"test_alter_token"
|
||||
"test_another_device"
|
||||
"test_connection_credentials"
|
||||
"test_connection_token"
|
||||
"test_download_additional_files"
|
||||
"test_download_focus"
|
||||
"test_download_version"
|
||||
"test_download"
|
||||
"test_search"
|
||||
"test_update"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://github.com/matlink/gplaycli";
|
||||
description = "Google Play Downloader via Command line";
|
||||
homepage = "https://github.com/matlink/gplaycli";
|
||||
changelog = "https://github.com/matlink/gplaycli/releases/tag/${version}";
|
||||
license = licenses.agpl3Plus;
|
||||
maintainers = with maintainers; [ ];
|
||||
};
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
, buildPythonPackage
|
||||
, fetchFromGitHub
|
||||
, pytestCheckHook
|
||||
, pythonAtLeast
|
||||
, pythonOlder
|
||||
, setuptools
|
||||
, setuptools-scm
|
||||
|
@ -36,6 +37,11 @@ buildPythonPackage rec {
|
|||
"pegen"
|
||||
];
|
||||
|
||||
disabledTests = lib.optionals (pythonAtLeast "3.11") [
|
||||
# https://github.com/we-like-parsers/pegen/issues/89
|
||||
"test_invalid_def_stmt"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Library to generate PEG parsers";
|
||||
homepage = "https://github.com/we-like-parsers/pegen";
|
||||
|
|
|
@ -1,13 +1,17 @@
|
|||
{ lib, buildPythonPackage, fetchFromGitHub }:
|
||||
|
||||
buildPythonPackage rec {
|
||||
let
|
||||
tagVersion = "2.2019-12-21";
|
||||
in
|
||||
buildPythonPackage {
|
||||
pname = "publicsuffix2";
|
||||
version = "2.2019-12-21";
|
||||
# tags have dashes, while the library version does not
|
||||
# see https://github.com/nexB/python-publicsuffix2/issues/12
|
||||
version = lib.replaceStrings ["-"] [""] tagVersion;
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "nexB";
|
||||
repo = "python-publicsuffix2";
|
||||
rev = "release-${version}";
|
||||
rev = "release-${tagVersion}";
|
||||
sha256 = "1dkvfvl0izq9hqzilnw8ipkbgjs9xyad9p21i3864hzinbh0wp9r";
|
||||
};
|
||||
|
||||
|
|
|
@ -69,6 +69,8 @@ buildPythonPackage rec {
|
|||
"textual"
|
||||
];
|
||||
|
||||
__darwinAllowLocalNetworking = true;
|
||||
|
||||
meta = with lib; {
|
||||
description = "TUI framework for Python inspired by modern web development";
|
||||
homepage = "https://github.com/Textualize/textual";
|
||||
|
|
|
@ -1,22 +1,17 @@
|
|||
{ lib
|
||||
, buildPythonPackage
|
||||
, pythonOlder
|
||||
, cxxfilt
|
||||
, fetchPypi
|
||||
, wrapQtAppsHook
|
||||
|
||||
# propagates
|
||||
, msgpack
|
||||
, pyasn1
|
||||
, pyasn1-modules
|
||||
, cxxfilt
|
||||
, msgpack
|
||||
, pycparser
|
||||
|
||||
# extras: gui
|
||||
, pyqt5
|
||||
, pythonRelaxDepsHook
|
||||
, pyqtwebengine
|
||||
|
||||
# knobs
|
||||
, pythonOlder
|
||||
, withGui ? false
|
||||
, wrapQtAppsHook
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
|
@ -31,12 +26,14 @@ buildPythonPackage rec {
|
|||
hash = "sha256-tAIhsHFds3qwPngfOsR1+xDKgi29ACnvFAYoklRnCAI=";
|
||||
};
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace setup.py \
|
||||
--replace 'cxxfilt>=0.2.1,<0.3.0' 'cxxfilt'
|
||||
'';
|
||||
pythonRelaxDeps = [
|
||||
"cxxfilt"
|
||||
"pyasn1"
|
||||
"pyasn1-modules"
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
pythonRelaxDepsHook
|
||||
wrapQtAppsHook
|
||||
];
|
||||
|
||||
|
@ -65,7 +62,7 @@ buildPythonPackage rec {
|
|||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Pure python disassembler, debugger, emulator, and static analysis framework";
|
||||
description = "Python disassembler, debugger, emulator, and static analysis framework";
|
||||
homepage = "https://github.com/vivisect/vivisect";
|
||||
changelog = "https://github.com/vivisect/vivisect/blob/v${version}/CHANGELOG.rst";
|
||||
license = licenses.asl20;
|
||||
|
|
|
@ -1,21 +1,21 @@
|
|||
{
|
||||
"version": "1.0.0-RC1",
|
||||
"version": "1.0.0-RC2",
|
||||
"assets": {
|
||||
"aarch64-darwin": {
|
||||
"asset": "scala-cli-aarch64-apple-darwin.gz",
|
||||
"sha256": "154yw2dfppsa29zhbmngzzhvs69sidfd0j0qraapm1i23k5lz3j6"
|
||||
"sha256": "1wrr1s3dhymvcz5j0vbd038p3yd2d5q3bgb0590wing04hc4hl6s"
|
||||
},
|
||||
"aarch64-linux": {
|
||||
"asset": "scala-cli-aarch64-pc-linux.gz",
|
||||
"sha256": "0ig14zwcbj4grmas7in94bcr3kpmi0jrc0wb3dhfaiakjwvrfkp1"
|
||||
"sha256": "008g95srb34286akk2cbnz1qf5pw9qaws1cppynxzbzpcj3jx5mk"
|
||||
},
|
||||
"x86_64-darwin": {
|
||||
"asset": "scala-cli-x86_64-apple-darwin.gz",
|
||||
"sha256": "05jjzqyflvwhyqray0871y6xp840qwxncz9flvj7icyhhli4sd85"
|
||||
"sha256": "00ifbdp6lxpbwk3yjqy6scywarl44rn1f54jds4xfvh6i22bga1g"
|
||||
},
|
||||
"x86_64-linux": {
|
||||
"asset": "scala-cli-x86_64-pc-linux.gz",
|
||||
"sha256": "1ga7sh8sc5i7rl73yhdfhk73qi0ncwkxx8iwzwrwnv7a2lizky4w"
|
||||
"sha256": "14kk1z7fx8j3kwlhnadhvclnccbnwr97xiw8w2g6nd19b95hnfnf"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
7604
pkgs/development/tools/rust/cargo-shuttle/Cargo.lock
generated
Normal file
7604
pkgs/development/tools/rust/cargo-shuttle/Cargo.lock
generated
Normal file
File diff suppressed because it is too large
Load diff
73
pkgs/development/tools/rust/cargo-shuttle/default.nix
Normal file
73
pkgs/development/tools/rust/cargo-shuttle/default.nix
Normal file
|
@ -0,0 +1,73 @@
|
|||
{ lib
|
||||
, rustPlatform
|
||||
, fetchFromGitHub
|
||||
, fetchpatch
|
||||
, pkg-config
|
||||
, curl
|
||||
, libgit2_1_5
|
||||
, openssl
|
||||
, zlib
|
||||
, stdenv
|
||||
, darwin
|
||||
}:
|
||||
|
||||
rustPlatform.buildRustPackage rec {
|
||||
pname = "shuttle";
|
||||
version = "0.16.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "shuttle-hq";
|
||||
repo = "shuttle";
|
||||
rev = "v${version}";
|
||||
hash = "sha256-lDRT3M6LfQrts9X2erRVyqTFWVqOwWQ/JFB1ZlK6Lo8=";
|
||||
};
|
||||
|
||||
cargoLock = {
|
||||
lockFile = ./Cargo.lock;
|
||||
outputHashes = {
|
||||
"hyper-reverse-proxy-0.5.2-dev" = "sha256-R1ZXGgWvwHWRHmKX823QLqM6ZJW+tzWUXigKkAyI5OE=";
|
||||
"tokiotest-httpserver-0.2.1" = "sha256-IPUaglIDwCUoczCCnX+R1IBqtc0s8b8toKEL8zN3/i8=";
|
||||
};
|
||||
};
|
||||
|
||||
patches = [
|
||||
# make sure to have only one revision of hyper-reverse-proxy
|
||||
# necessary to make `importCargoLock` work
|
||||
# https://github.com/shuttle-hq/shuttle/pull/921
|
||||
(fetchpatch {
|
||||
name = "chore-promote-hyper-reverse-proxy-to-a-workspace-dependency.patch";
|
||||
url = "https://github.com/shuttle-hq/shuttle/commit/5c398427229f1358bd26ec81a2a22d01adf11b3d.patch";
|
||||
hash = "sha256-fJBz/0StMALtJYh/Ec/KGCwCGLtch+HH/oYlibE8xcw=";
|
||||
})
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
curl
|
||||
pkg-config
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
curl
|
||||
libgit2_1_5
|
||||
openssl
|
||||
zlib
|
||||
] ++ lib.optionals stdenv.isDarwin [
|
||||
darwin.apple_sdk.frameworks.CoreServices
|
||||
darwin.apple_sdk.frameworks.SystemConfiguration
|
||||
];
|
||||
|
||||
cargoBuildFlags = [ "-p" "cargo-shuttle" ];
|
||||
|
||||
cargoTestFlags = cargoBuildFlags ++ [
|
||||
# other tests are failing for different reasons
|
||||
"init::shuttle_init_tests::"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "A cargo command for the shuttle platform";
|
||||
homepage = "https://shuttle.rs";
|
||||
changelog = "https://github.com/shuttle-hq/shuttle/releases/tag/${src.rev}";
|
||||
license = licenses.asl20;
|
||||
maintainers = with maintainers; [ figsoda ];
|
||||
};
|
||||
}
|
|
@ -2,13 +2,13 @@
|
|||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "cpustat";
|
||||
version = "0.02.17";
|
||||
version = "0.02.19";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "ColinIanKing";
|
||||
repo = pname;
|
||||
rev = "V${version}";
|
||||
hash = "sha256-4HDXRtklzQSsywCGCTKdz6AtZta9R1mx7qkT7skX6Kc=";
|
||||
hash = "sha256-MujdgA+rFLrRc/N9yN7udnarA1TCzX//95hoXTUHG8Q=";
|
||||
};
|
||||
|
||||
buildInputs = [ ncurses ];
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# This file is autogenerated! Run ./update.sh to regenerate.
|
||||
{
|
||||
version = "20230310";
|
||||
sourceHash = "sha256-a0Or/ov+YDbDbyUy65j95wgW1ZBo2LIxYWR7L6z6Usw=";
|
||||
outputHash = "sha256-BL1dSTAjg5F1JWhoVYelMJRv+lMZNA8S7FbGIQWemMo=";
|
||||
version = "20230515";
|
||||
sourceHash = "sha256-VcA873r9jVYqDqEcvz/PVGfCAhLXr0sMXQincWNLEIs=";
|
||||
outputHash = "sha256-h3KDK3KiD88dvTvLlLL2XczY1ZeEVnYEzh9sqbo1dZ8=";
|
||||
}
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
with lib;
|
||||
|
||||
buildLinux (args // rec {
|
||||
version = "6.4-rc1";
|
||||
version = "6.4-rc2";
|
||||
extraMeta.branch = lib.versions.majorMinor version;
|
||||
|
||||
# modDirVersion needs to be x.y.z, will always add .0
|
||||
|
@ -11,7 +11,7 @@ buildLinux (args // rec {
|
|||
|
||||
src = fetchzip {
|
||||
url = "https://git.kernel.org/torvalds/t/linux-${version}.tar.gz";
|
||||
hash = "sha256-ayKzQNYfm8UjGZc8fy6sJF8xnkTxCCKpDv2TwdtKuKo=";
|
||||
hash = "sha256-CQwSN5LQxGO900QLMAXcjGhB2o+6rZgXHQ+gCJtVaeU=";
|
||||
};
|
||||
|
||||
# Should the testing kernels ever be built on Hydra?
|
||||
|
|
|
@ -20,11 +20,18 @@ lib.makeScope
|
|||
mes = callPackage ./mes { };
|
||||
mes-libc = callPackage ./mes/libc.nix { };
|
||||
|
||||
inherit (callPackage ./stage0-posix { }) kaem m2libc mescc-tools mescc-tools-extra;
|
||||
stage0-posix = callPackage ./stage0-posix { };
|
||||
|
||||
inherit (self.stage0-posix) kaem m2libc mescc-tools mescc-tools-extra;
|
||||
|
||||
tinycc-bootstrappable = callPackage ./tinycc/bootstrappable.nix { };
|
||||
tinycc-mes = callPackage ./tinycc/mes.nix { };
|
||||
|
||||
inherit (callPackage ./utils.nix { }) fetchurl derivationWithMeta writeTextFile writeText;
|
||||
|
||||
test = kaem.runCommand "minimal-bootstrap-test" {} ''
|
||||
echo ${mes.compiler.tests.get-version}
|
||||
echo ${tinycc-mes.compiler.tests.chain}
|
||||
mkdir ''${out}
|
||||
'';
|
||||
})
|
||||
|
|
|
@ -45,7 +45,7 @@ let
|
|||
./configure \
|
||||
--build i686-pc-linux-gnu \
|
||||
--host i686-pc-linux-gnu \
|
||||
CC="${tinycc-mes}/bin/tcc -static" \
|
||||
CC="${tinycc.compiler}/bin/tcc -B ${tinycc.libs}/lib -static" \
|
||||
ac_cv_func_dup=no
|
||||
- `ac_cv_func_dup` disabled as mes-libc doesn't implement tmpfile()
|
||||
|
||||
|
@ -148,7 +148,7 @@ in
|
|||
kaem.runCommand "${pname}-${version}" {
|
||||
inherit pname version;
|
||||
|
||||
nativeBuildInputs = [ tinycc gnupatch ];
|
||||
nativeBuildInputs = [ tinycc.compiler gnupatch ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "A tool to control the generation of non-source files from sources";
|
||||
|
@ -174,7 +174,7 @@ kaem.runCommand "${pname}-${version}" {
|
|||
cp lib/fnmatch.in.h lib/fnmatch.h
|
||||
|
||||
# Compile
|
||||
alias CC="tcc ${lib.concatStringsSep " " CFLAGS}"
|
||||
alias CC="tcc -B ${tinycc.libs}/lib ${lib.concatStringsSep " " CFLAGS}"
|
||||
${lib.concatMapStringsSep "\n" (f: "CC -c ${f}") sources}
|
||||
|
||||
# Link
|
||||
|
|
|
@ -70,7 +70,7 @@ in
|
|||
kaem.runCommand "${pname}-${version}" {
|
||||
inherit pname version;
|
||||
|
||||
nativeBuildInputs = [ tinycc ];
|
||||
nativeBuildInputs = [ tinycc.compiler ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "GNU Patch, a program to apply differences to files";
|
||||
|
@ -91,7 +91,7 @@ kaem.runCommand "${pname}-${version}" {
|
|||
catm config.h
|
||||
|
||||
# Build
|
||||
alias CC="tcc ${lib.concatStringsSep " " CFLAGS}"
|
||||
alias CC="tcc -B ${tinycc.libs}/lib ${lib.concatStringsSep " " CFLAGS}"
|
||||
${lib.concatMapStringsSep "\n" (f: "CC -c ${f}") sources}
|
||||
|
||||
# Link
|
||||
|
|
|
@ -20,7 +20,8 @@ kaem.runCommand "${pname}-${version}" {
|
|||
};
|
||||
} ''
|
||||
mkdir -p ''${out}/bin
|
||||
${mes}/bin/mes --no-auto-compile -e main ${mes}/bin/mescc.scm -- \
|
||||
${mes.compiler}/bin/mes --no-auto-compile -e main ${mes.srcPost.bin}/bin/mescc.scm -- \
|
||||
-L ${mes.libs}/lib \
|
||||
-lc+tcc \
|
||||
-o ''${out}/bin/ln \
|
||||
${src}
|
||||
|
|
|
@ -6,6 +6,12 @@
|
|||
, m2libc
|
||||
, mescc-tools
|
||||
}:
|
||||
|
||||
# Maintenance note:
|
||||
# Build steps have been adapted from build-aux/bootstrap.sh.in
|
||||
# as well as the live-bootstrap project
|
||||
# https://github.com/fosslinux/live-bootstrap/blob/1bc4296091c51f53a5598050c8956d16e945b0f5/sysa/mes-0.24.2/mes-0.24.2.kaem
|
||||
|
||||
let
|
||||
pname = "mes";
|
||||
version = "0.24.2";
|
||||
|
@ -28,26 +34,6 @@ let
|
|||
# add symlink() to libc+tcc so we can use it in ln-boot
|
||||
libc_tcc_SOURCES = sources.libc_tcc_SOURCES ++ [ "lib/linux/symlink.c" ];
|
||||
|
||||
compile = sources:
|
||||
lib.concatMapStringsSep
|
||||
"\n"
|
||||
(f: ''CC -c ''${MES_PREFIX}/${f}'')
|
||||
sources;
|
||||
replaceExt = ext: source:
|
||||
lib.replaceStrings
|
||||
[ ".c" ]
|
||||
[ ext ]
|
||||
(builtins.baseNameOf source);
|
||||
archive = out: sources:
|
||||
"catm ${out} ${lib.concatMapStringsSep " " (replaceExt ".o") sources}";
|
||||
sourceArchive = out: sources:
|
||||
"catm ${out} ${lib.concatMapStringsSep " " (replaceExt ".s") sources}";
|
||||
in
|
||||
kaem.runCommand "${pname}-${version}" {
|
||||
inherit pname version;
|
||||
|
||||
passthru = { inherit src nyacc; };
|
||||
|
||||
meta = with lib; {
|
||||
description = "Scheme interpreter and C compiler for bootstrapping";
|
||||
homepage = "https://www.gnu.org/software/mes";
|
||||
|
@ -55,135 +41,199 @@ kaem.runCommand "${pname}-${version}" {
|
|||
maintainers = with maintainers; [ emilytrau ];
|
||||
platforms = [ "i686-linux" ];
|
||||
};
|
||||
}
|
||||
# Maintenance note:
|
||||
# Build steps have been adapted from build-aux/bootstrap.sh.in
|
||||
# as well as the live-bootstrap project
|
||||
# https://github.com/fosslinux/live-bootstrap/blob/1bc4296091c51f53a5598050c8956d16e945b0f5/sysa/mes-0.24.2/mes-0.24.2.kaem
|
||||
''
|
||||
# Unpack source
|
||||
ungz --file ${src} --output mes.tar
|
||||
mkdir ''${out} ''${out}/bin ''${out}/share
|
||||
cd ''${out}/share
|
||||
untar --non-strict --file ''${NIX_BUILD_TOP}/mes.tar # ignore symlinks
|
||||
|
||||
MES_PREFIX=''${out}/share/mes-${version}
|
||||
LIBDIR=''${MES_PREFIX}/lib
|
||||
srcPost = kaem.runCommand "${pname}-src-${version}" {
|
||||
outputs = [ "out" "bin" ];
|
||||
inherit meta;
|
||||
} ''
|
||||
# Unpack source
|
||||
ungz --file ${src} --output mes.tar
|
||||
mkdir ''${out}
|
||||
cd ''${out}
|
||||
untar --non-strict --file ''${NIX_BUILD_TOP}/mes.tar # ignore symlinks
|
||||
|
||||
cd ''${MES_PREFIX}
|
||||
MES_PREFIX=''${out}/mes-${version}
|
||||
|
||||
cp ${config_h} include/mes/config.h
|
||||
cd ''${MES_PREFIX}
|
||||
|
||||
mkdir include/arch
|
||||
cp include/linux/x86/syscall.h include/arch/syscall.h
|
||||
cp include/linux/x86/kernel-stat.h include/arch/kernel-stat.h
|
||||
cp ${config_h} include/mes/config.h
|
||||
|
||||
# Remove pregenerated files
|
||||
rm mes/module/mes/psyntax.pp mes/module/mes/psyntax.pp.header
|
||||
mkdir include/arch
|
||||
cp include/linux/x86/syscall.h include/arch/syscall.h
|
||||
cp include/linux/x86/kernel-stat.h include/arch/kernel-stat.h
|
||||
|
||||
# These files are symlinked in the repo
|
||||
cp mes/module/srfi/srfi-9-struct.mes mes/module/srfi/srfi-9.mes
|
||||
cp mes/module/srfi/srfi-9/gnu-struct.mes mes/module/srfi/srfi-9/gnu.mes
|
||||
# Remove pregenerated files
|
||||
rm mes/module/mes/psyntax.pp mes/module/mes/psyntax.pp.header
|
||||
|
||||
# Fixes to support newer M2-Planet
|
||||
catm x86_defs.M1 ${m2libc}/x86/x86_defs.M1 lib/m2/x86/x86_defs.M1
|
||||
cp x86_defs.M1 lib/m2/x86/x86_defs.M1
|
||||
rm x86_defs.M1
|
||||
# These files are symlinked in the repo
|
||||
cp mes/module/srfi/srfi-9-struct.mes mes/module/srfi/srfi-9.mes
|
||||
cp mes/module/srfi/srfi-9/gnu-struct.mes mes/module/srfi/srfi-9/gnu.mes
|
||||
|
||||
# Remove environment impurities
|
||||
__GUILE_LOAD_PATH="\"''${MES_PREFIX}/mes/module:''${MES_PREFIX}/module:${nyacc.guilePath}\""
|
||||
boot0_scm=mes/module/mes/boot-0.scm
|
||||
guile_mes=mes/module/mes/guile.mes
|
||||
replace --file ''${boot0_scm} --output ''${boot0_scm} --match-on "(getenv \"GUILE_LOAD_PATH\")" --replace-with ''${__GUILE_LOAD_PATH}
|
||||
replace --file ''${guile_mes} --output ''${guile_mes} --match-on "(getenv \"GUILE_LOAD_PATH\")" --replace-with ''${__GUILE_LOAD_PATH}
|
||||
# Fixes to support newer M2-Planet
|
||||
catm x86_defs.M1 ${m2libc}/x86/x86_defs.M1 lib/m2/x86/x86_defs.M1
|
||||
cp x86_defs.M1 lib/m2/x86/x86_defs.M1
|
||||
rm x86_defs.M1
|
||||
|
||||
module_mescc_scm=module/mescc/mescc.scm
|
||||
replace --file ''${module_mescc_scm} --output ''${module_mescc_scm} --match-on "(getenv \"M1\")" --replace-with "\"${mescc-tools}/bin/M1\""
|
||||
replace --file ''${module_mescc_scm} --output ''${module_mescc_scm} --match-on "(getenv \"HEX2\")" --replace-with "\"${mescc-tools}/bin/hex2\""
|
||||
replace --file ''${module_mescc_scm} --output ''${module_mescc_scm} --match-on "(getenv \"BLOOD_ELF\")" --replace-with "\"${mescc-tools}/bin/blood-elf\""
|
||||
replace --file ''${module_mescc_scm} --output ''${module_mescc_scm} --match-on "(getenv \"srcdest\")" --replace-with "\"''${MES_PREFIX}\""
|
||||
# Remove environment impurities
|
||||
__GUILE_LOAD_PATH="\"''${MES_PREFIX}/mes/module:''${MES_PREFIX}/module:${nyacc.guilePath}\""
|
||||
boot0_scm=mes/module/mes/boot-0.scm
|
||||
guile_mes=mes/module/mes/guile.mes
|
||||
replace --file ''${boot0_scm} --output ''${boot0_scm} --match-on "(getenv \"GUILE_LOAD_PATH\")" --replace-with ''${__GUILE_LOAD_PATH}
|
||||
replace --file ''${guile_mes} --output ''${guile_mes} --match-on "(getenv \"GUILE_LOAD_PATH\")" --replace-with ''${__GUILE_LOAD_PATH}
|
||||
|
||||
mes_c=src/mes.c
|
||||
replace --file ''${mes_c} --output ''${mes_c} --match-on "getenv (\"MES_PREFIX\")" --replace-with "\"''${MES_PREFIX}\""
|
||||
replace --file ''${mes_c} --output ''${mes_c} --match-on "getenv (\"srcdest\")" --replace-with "\"''${MES_PREFIX}\""
|
||||
module_mescc_scm=module/mescc/mescc.scm
|
||||
replace --file ''${module_mescc_scm} --output ''${module_mescc_scm} --match-on "(getenv \"M1\")" --replace-with "\"${mescc-tools}/bin/M1\""
|
||||
replace --file ''${module_mescc_scm} --output ''${module_mescc_scm} --match-on "(getenv \"HEX2\")" --replace-with "\"${mescc-tools}/bin/hex2\""
|
||||
replace --file ''${module_mescc_scm} --output ''${module_mescc_scm} --match-on "(getenv \"BLOOD_ELF\")" --replace-with "\"${mescc-tools}/bin/blood-elf\""
|
||||
replace --file ''${module_mescc_scm} --output ''${module_mescc_scm} --match-on "(getenv \"srcdest\")" --replace-with "\"''${MES_PREFIX}\""
|
||||
|
||||
# Increase runtime resource limits
|
||||
gc_c=src/gc.c
|
||||
replace --file ''${gc_c} --output ''${gc_c} --match-on "getenv (\"MES_ARENA\")" --replace-with "\"100000000\""
|
||||
replace --file ''${gc_c} --output ''${gc_c} --match-on "getenv (\"MES_MAX_ARENA\")" --replace-with "\"100000000\""
|
||||
replace --file ''${gc_c} --output ''${gc_c} --match-on "getenv (\"MES_STACK\")" --replace-with "\"6000000\""
|
||||
mes_c=src/mes.c
|
||||
replace --file ''${mes_c} --output ''${mes_c} --match-on "getenv (\"MES_PREFIX\")" --replace-with "\"''${MES_PREFIX}\""
|
||||
replace --file ''${mes_c} --output ''${mes_c} --match-on "getenv (\"srcdest\")" --replace-with "\"''${MES_PREFIX}\""
|
||||
|
||||
# Create mescc.scm
|
||||
mescc_in=scripts/mescc.scm.in
|
||||
replace --file ''${mescc_in} --output ''${mescc_in} --match-on "(getenv \"MES_PREFIX\")" --replace-with "\"''${MES_PREFIX}\""
|
||||
replace --file ''${mescc_in} --output ''${mescc_in} --match-on "(getenv \"includedir\")" --replace-with "\"''${MES_PREFIX}/include\""
|
||||
replace --file ''${mescc_in} --output ''${mescc_in} --match-on "(getenv \"libdir\")" --replace-with "\"''${MES_PREFIX}/lib\""
|
||||
replace --file ''${mescc_in} --output ''${mescc_in} --match-on @prefix@ --replace-with ''${MES_PREFIX}
|
||||
replace --file ''${mescc_in} --output ''${mescc_in} --match-on @VERSION@ --replace-with ${version}
|
||||
replace --file ''${mescc_in} --output ''${mescc_in} --match-on @mes_cpu@ --replace-with x86
|
||||
replace --file ''${mescc_in} --output ''${mescc_in} --match-on @mes_kernel@ --replace-with linux
|
||||
cp ''${mescc_in} ''${out}/bin/mescc.scm
|
||||
# Increase runtime resource limits
|
||||
gc_c=src/gc.c
|
||||
replace --file ''${gc_c} --output ''${gc_c} --match-on "getenv (\"MES_ARENA\")" --replace-with "\"100000000\""
|
||||
replace --file ''${gc_c} --output ''${gc_c} --match-on "getenv (\"MES_MAX_ARENA\")" --replace-with "\"100000000\""
|
||||
replace --file ''${gc_c} --output ''${gc_c} --match-on "getenv (\"MES_STACK\")" --replace-with "\"6000000\""
|
||||
|
||||
# Build mes-m2
|
||||
mes_cpu=x86
|
||||
stage0_cpu=x86
|
||||
kaem --verbose --strict --file kaem.run
|
||||
cp bin/mes-m2 ''${out}/bin/mes-m2
|
||||
chmod 555 ''${out}/bin/mes-m2
|
||||
# Create mescc.scm
|
||||
mescc_in=scripts/mescc.scm.in
|
||||
replace --file ''${mescc_in} --output ''${mescc_in} --match-on "(getenv \"MES_PREFIX\")" --replace-with "\"''${MES_PREFIX}\""
|
||||
replace --file ''${mescc_in} --output ''${mescc_in} --match-on "(getenv \"includedir\")" --replace-with "\"''${MES_PREFIX}/include\""
|
||||
replace --file ''${mescc_in} --output ''${mescc_in} --match-on "(getenv \"libdir\")" --replace-with "\"''${MES_PREFIX}/lib\""
|
||||
replace --file ''${mescc_in} --output ''${mescc_in} --match-on @prefix@ --replace-with ''${MES_PREFIX}
|
||||
replace --file ''${mescc_in} --output ''${mescc_in} --match-on @VERSION@ --replace-with ${version}
|
||||
replace --file ''${mescc_in} --output ''${mescc_in} --match-on @mes_cpu@ --replace-with x86
|
||||
replace --file ''${mescc_in} --output ''${mescc_in} --match-on @mes_kernel@ --replace-with linux
|
||||
mkdir -p ''${bin}/bin
|
||||
cp ''${mescc_in} ''${bin}/bin/mescc.scm
|
||||
|
||||
# Build mes-m2
|
||||
mes_cpu=x86
|
||||
stage0_cpu=x86
|
||||
kaem --verbose --strict --file kaem.run
|
||||
cp bin/mes-m2 ''${bin}/bin/mes-m2
|
||||
chmod 555 ''${bin}/bin/mes-m2
|
||||
'';
|
||||
|
||||
srcPrefix = "${srcPost.out}/mes-${version}";
|
||||
|
||||
cc = "${srcPost.bin}/bin/mes-m2";
|
||||
ccArgs = [
|
||||
"-e" "main"
|
||||
"${srcPost.bin}/bin/mescc.scm"
|
||||
"--"
|
||||
"-D" "HAVE_CONFIG_H=1"
|
||||
"-I" "${srcPrefix}/include"
|
||||
"-I" "${srcPrefix}/include/linux/x86"
|
||||
];
|
||||
|
||||
CC = toString ([ cc ] ++ ccArgs);
|
||||
|
||||
stripExt = source:
|
||||
lib.replaceStrings
|
||||
[ ".c" ]
|
||||
[ "" ]
|
||||
(builtins.baseNameOf source);
|
||||
|
||||
compile = source: kaem.runCommand (stripExt source) {} ''
|
||||
mkdir ''${out}
|
||||
cd ''${out}
|
||||
${CC} -c ${srcPrefix}/${source}
|
||||
'';
|
||||
|
||||
crt1 = compile "/lib/linux/x86-mes-mescc/crt1.c";
|
||||
|
||||
getRes = suffix: res: "${res}/${res.name}${suffix}";
|
||||
|
||||
archive = out: sources:
|
||||
"catm ${out} ${lib.concatMapStringsSep " " (getRes ".o") sources}";
|
||||
sourceArchive = out: sources:
|
||||
"catm ${out} ${lib.concatMapStringsSep " " (getRes ".s") sources}";
|
||||
|
||||
mkLib = libname: sources: let
|
||||
os = map compile sources;
|
||||
in kaem.runCommand "${pname}-${libname}-${version}" {
|
||||
inherit meta;
|
||||
} ''
|
||||
LIBDIR=''${out}/lib
|
||||
mkdir -p ''${LIBDIR}
|
||||
cd ''${LIBDIR}
|
||||
|
||||
${archive "${libname}.a" os}
|
||||
${sourceArchive "${libname}.s" os}
|
||||
'';
|
||||
|
||||
libc-mini = mkLib "libc-mini" libc_mini_SOURCES;
|
||||
libmescc = mkLib "libmescc" libmescc_SOURCES;
|
||||
libc = mkLib "libc" libc_SOURCES;
|
||||
libc_tcc = mkLib "libc+tcc" libc_tcc_SOURCES;
|
||||
|
||||
# Recompile Mes and Mes C library using mes-m2 bootstrapped Mes
|
||||
cd ''${NIX_BUILD_TOP}
|
||||
alias CC="''${out}/bin/mes-m2 -e main ''${out}/bin/mescc.scm -- -D HAVE_CONFIG_H=1 -I ''${MES_PREFIX}/include -I ''${MES_PREFIX}/include/linux/x86"
|
||||
mkdir -p ''${LIBDIR}/x86-mes
|
||||
libs = kaem.runCommand "${pname}-m2-libs-${version}" {
|
||||
inherit pname version;
|
||||
|
||||
# crt1.o
|
||||
CC -c ''${MES_PREFIX}/lib/linux/x86-mes-mescc/crt1.c
|
||||
cp crt1.o ''${LIBDIR}/x86-mes
|
||||
cp crt1.s ''${LIBDIR}/x86-mes
|
||||
passthru.tests.get-version = result: kaem.runCommand "${pname}-get-version-${version}" {} ''
|
||||
${result}/bin/mes --version
|
||||
mkdir ''${out}
|
||||
'';
|
||||
|
||||
# libc-mini.a
|
||||
${compile libc_mini_SOURCES}
|
||||
${archive "libc-mini.a" libc_mini_SOURCES}
|
||||
${sourceArchive "libc-mini.s" libc_mini_SOURCES}
|
||||
cp libc-mini.a ''${LIBDIR}/x86-mes
|
||||
cp libc-mini.s ''${LIBDIR}/x86-mes
|
||||
inherit meta;
|
||||
}
|
||||
''
|
||||
LIBDIR=''${out}/lib
|
||||
mkdir -p ''${out} ''${LIBDIR}
|
||||
|
||||
# libmescc.a
|
||||
${compile libmescc_SOURCES}
|
||||
${archive "libmescc.a" libmescc_SOURCES}
|
||||
${sourceArchive "libmescc.s" libmescc_SOURCES}
|
||||
cp libmescc.a ''${LIBDIR}/x86-mes
|
||||
cp libmescc.s ''${LIBDIR}/x86-mes
|
||||
mkdir -p ''${LIBDIR}/x86-mes
|
||||
|
||||
# libc.a
|
||||
${compile libc_SOURCES}
|
||||
${archive "libc.a" libc_SOURCES}
|
||||
${sourceArchive "libc.s" libc_SOURCES}
|
||||
cp libc.a ''${LIBDIR}/x86-mes
|
||||
cp libc.s ''${LIBDIR}/x86-mes
|
||||
# crt1.o
|
||||
cp ${crt1}/crt1.o ''${LIBDIR}/x86-mes
|
||||
cp ${crt1}/crt1.s ''${LIBDIR}/x86-mes
|
||||
|
||||
# libc+tcc.a
|
||||
# optimisation: don't recompile common libc sources
|
||||
${compile (lib.subtractLists libc_SOURCES libc_tcc_SOURCES)}
|
||||
${archive "libc+tcc.a" libc_tcc_SOURCES}
|
||||
${sourceArchive "libc+tcc.s" libc_tcc_SOURCES}
|
||||
cp libc+tcc.a ''${LIBDIR}/x86-mes
|
||||
cp libc+tcc.s ''${LIBDIR}/x86-mes
|
||||
# libc-mini.a
|
||||
cp ${libc-mini}/lib/libc-mini.a ''${LIBDIR}/x86-mes
|
||||
cp ${libc-mini}/lib/libc-mini.s ''${LIBDIR}/x86-mes
|
||||
|
||||
# libmescc.a
|
||||
cp ${libmescc}/lib/libmescc.a ''${LIBDIR}/x86-mes
|
||||
cp ${libmescc}/lib/libmescc.s ''${LIBDIR}/x86-mes
|
||||
|
||||
# libc.a
|
||||
cp ${libc}/lib/libc.a ''${LIBDIR}/x86-mes
|
||||
cp ${libc}/lib/libc.s ''${LIBDIR}/x86-mes
|
||||
|
||||
# libc+tcc.a
|
||||
cp ${libc_tcc}/lib/libc+tcc.a ''${LIBDIR}/x86-mes
|
||||
cp ${libc_tcc}/lib/libc+tcc.s ''${LIBDIR}/x86-mes
|
||||
'';
|
||||
|
||||
# Build mes itself
|
||||
${compile mes_SOURCES}
|
||||
''${out}/bin/mes-m2 -e main ''${out}/bin/mescc.scm -- \
|
||||
--base-address 0x08048000 \
|
||||
-L ''${MES_PREFIX}/lib \
|
||||
-L . \
|
||||
-lc \
|
||||
-lmescc \
|
||||
-nostdlib \
|
||||
-o ''${out}/bin/mes \
|
||||
crt1.o \
|
||||
${lib.concatMapStringsSep " " (replaceExt ".o") mes_SOURCES}
|
||||
compiler = kaem.runCommand "${pname}-${version}" {
|
||||
inherit pname version;
|
||||
|
||||
# Check
|
||||
''${out}/bin/mes --version
|
||||
''
|
||||
passthru.tests.get-version = result: kaem.runCommand "${pname}-get-version-${version}" {} ''
|
||||
${result}/bin/mes --version
|
||||
mkdir ''${out}
|
||||
'';
|
||||
|
||||
inherit meta;
|
||||
}
|
||||
''
|
||||
mkdir -p ''${out}/bin
|
||||
|
||||
${srcPost.bin}/bin/mes-m2 -e main ${srcPost.bin}/bin/mescc.scm -- \
|
||||
--base-address 0x08048000 \
|
||||
-L ''${srcPrefix}/lib \
|
||||
-L ${libs}/lib \
|
||||
-lc \
|
||||
-lmescc \
|
||||
-nostdlib \
|
||||
-o ''${out}/bin/mes \
|
||||
${libs}/lib/x86-mes/crt1.o \
|
||||
${lib.concatMapStringsSep " " (getRes ".o") (map compile mes_SOURCES)}
|
||||
'';
|
||||
in {
|
||||
inherit srcPost srcPrefix nyacc;
|
||||
inherit compiler libs;
|
||||
}
|
||||
|
|
|
@ -6,13 +6,11 @@
|
|||
}:
|
||||
let
|
||||
pname = "mes-libc";
|
||||
inherit (mes) version;
|
||||
inherit (mes.compiler) version;
|
||||
|
||||
sources = (import ./sources.nix).x86.linux.gcc;
|
||||
inherit (sources) libtcc1_SOURCES libc_gnu_SOURCES;
|
||||
|
||||
prefix = "${mes}/share/mes-${version}";
|
||||
|
||||
# Concatenate all source files into a convenient bundle
|
||||
# "gcc" variants of source files (eg. "lib/linux/x86-mes-gcc") can also be
|
||||
# compiled by tinycc
|
||||
|
@ -37,11 +35,10 @@ kaem.runCommand "${pname}-${version}" {
|
|||
platforms = [ "i686-linux" ];
|
||||
};
|
||||
} ''
|
||||
cd ${prefix}
|
||||
cd ${mes.srcPrefix}
|
||||
|
||||
# mescc compiled libc.a
|
||||
mkdir -p ''${out}/lib/x86-mes
|
||||
cp lib/x86-mes/libc.a ''${out}/lib/x86-mes
|
||||
|
||||
# libc.c
|
||||
catm ''${TMPDIR}/first.c ${lib.concatStringsSep " " firstLibc}
|
||||
|
@ -59,5 +56,5 @@ kaem.runCommand "${pname}-${version}" {
|
|||
cp lib/posix/getopt.c ''${out}/lib/libgetopt.c
|
||||
|
||||
# Install headers
|
||||
ln -s ${prefix}/include ''${out}/include
|
||||
ln -s ${mes.srcPrefix}/include ''${out}/include
|
||||
''
|
||||
|
|
|
@ -12,7 +12,9 @@ lib.makeScope newScope (self: with self; {
|
|||
kaem = callPackage ./kaem { };
|
||||
kaem-minimal = callPackage ./kaem/minimal.nix { };
|
||||
|
||||
inherit (callPackage ./stage0-posix-x86.nix { }) blood-elf-0 hex2 kaem-unwrapped M1 M2;
|
||||
stage0-posix-x86 = callPackage ./stage0-posix-x86.nix { };
|
||||
|
||||
inherit (self.stage0-posix-x86) blood-elf-0 hex2 kaem-unwrapped M1 M2;
|
||||
|
||||
mescc-tools = callPackage ./mescc-tools { };
|
||||
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
, mes-libc
|
||||
}:
|
||||
let
|
||||
inherit (callPackage ./common.nix { }) buildTinyccMes;
|
||||
inherit (callPackage ./common.nix { }) buildTinyccMes recompileLibc;
|
||||
|
||||
version = "unstable-2023-04-20";
|
||||
rev = "80114c4da6b17fbaabb399cc29f427e368309bc8";
|
||||
|
@ -39,50 +39,54 @@ let
|
|||
platforms = [ "i686-linux" ];
|
||||
};
|
||||
|
||||
tinycc-boot-mes = kaem.runCommand "tinycc-boot-mes-${version}" {} ''
|
||||
catm config.h
|
||||
${mes}/bin/mes --no-auto-compile -e main ${mes}/bin/mescc.scm -- \
|
||||
-S \
|
||||
-o tcc.s \
|
||||
-I . \
|
||||
-D BOOTSTRAP=1 \
|
||||
-I ${src} \
|
||||
-D TCC_TARGET_I386=1 \
|
||||
-D inline= \
|
||||
-D CONFIG_TCCDIR=\"''${out}/lib\" \
|
||||
-D CONFIG_SYSROOT=\"\" \
|
||||
-D CONFIG_TCC_CRTPREFIX=\"''${out}/lib\" \
|
||||
-D CONFIG_TCC_ELFINTERP=\"/mes/loader\" \
|
||||
-D CONFIG_TCC_SYSINCLUDEPATHS=\"${mes-libc}/include\" \
|
||||
-D TCC_LIBGCC=\"${mes-libc}/lib/x86-mes/libc.a\" \
|
||||
-D CONFIG_TCC_LIBTCC1_MES=0 \
|
||||
-D CONFIG_TCCBOOT=1 \
|
||||
-D CONFIG_TCC_STATIC=1 \
|
||||
-D CONFIG_USE_LIBGCC=1 \
|
||||
-D TCC_MES_LIBC=1 \
|
||||
-D TCC_VERSION=\"${version}\" \
|
||||
-D ONE_SOURCE=1 \
|
||||
${src}/tcc.c
|
||||
mkdir -p ''${out}/bin
|
||||
${mes}/bin/mes --no-auto-compile -e main ${mes}/bin/mescc.scm -- \
|
||||
-l c+tcc \
|
||||
-o ''${out}/bin/tcc \
|
||||
tcc.s
|
||||
pname = "tinycc-boot-mes";
|
||||
|
||||
''${out}/bin/tcc -version
|
||||
tinycc-boot-mes = rec {
|
||||
compiler = kaem.runCommand "${pname}-${version}" {
|
||||
passthru.tests.get-version = result: kaem.runCommand "${pname}-get-version-${version}" {} ''
|
||||
${result}/bin/tcc -version
|
||||
mkdir ''${out}
|
||||
'';
|
||||
} ''
|
||||
catm config.h
|
||||
${mes.compiler}/bin/mes --no-auto-compile -e main ${mes.srcPost.bin}/bin/mescc.scm -- \
|
||||
-S \
|
||||
-o tcc.s \
|
||||
-I . \
|
||||
-D BOOTSTRAP=1 \
|
||||
-I ${src} \
|
||||
-D TCC_TARGET_I386=1 \
|
||||
-D inline= \
|
||||
-D CONFIG_TCCDIR=\"\" \
|
||||
-D CONFIG_SYSROOT=\"\" \
|
||||
-D CONFIG_TCC_CRTPREFIX=\"{B}\" \
|
||||
-D CONFIG_TCC_ELFINTERP=\"/mes/loader\" \
|
||||
-D CONFIG_TCC_LIBPATHS=\"{B}\" \
|
||||
-D CONFIG_TCC_SYSINCLUDEPATHS=\"${mes-libc}/include\" \
|
||||
-D TCC_LIBGCC=\"${mes-libc}/lib/x86-mes/libc.a\" \
|
||||
-D CONFIG_TCC_LIBTCC1_MES=0 \
|
||||
-D CONFIG_TCCBOOT=1 \
|
||||
-D CONFIG_TCC_STATIC=1 \
|
||||
-D CONFIG_USE_LIBGCC=1 \
|
||||
-D TCC_MES_LIBC=1 \
|
||||
-D TCC_VERSION=\"${version}\" \
|
||||
-D ONE_SOURCE=1 \
|
||||
${src}/tcc.c
|
||||
mkdir -p ''${out}/bin
|
||||
${mes.compiler}/bin/mes --no-auto-compile -e main ${mes.srcPost.bin}/bin/mescc.scm -- \
|
||||
-L ${mes.libs}/lib \
|
||||
-l c+tcc \
|
||||
-o ''${out}/bin/tcc \
|
||||
tcc.s
|
||||
'';
|
||||
|
||||
# Recompile libc: crt{1,n,i}, libtcc.a, libc.a, libgetopt.a
|
||||
mkdir -p ''${out}/lib
|
||||
''${out}/bin/tcc ${mes-libc.CFLAGS} -c -o ''${out}/lib/crt1.o ${mes-libc}/lib/crt1.c
|
||||
''${out}/bin/tcc ${mes-libc.CFLAGS} -c -o ''${out}/lib/crtn.o ${mes-libc}/lib/crtn.c
|
||||
''${out}/bin/tcc ${mes-libc.CFLAGS} -c -o ''${out}/lib/crti.o ${mes-libc}/lib/crti.c
|
||||
''${out}/bin/tcc ${mes-libc.CFLAGS} -c -o libc.o ${mes-libc}/lib/libc.c
|
||||
''${out}/bin/tcc -ar cr ''${out}/lib/libc.a libc.o
|
||||
''${out}/bin/tcc ${mes-libc.CFLAGS} -c -o libtcc1.o ${mes-libc}/lib/libtcc1.c
|
||||
''${out}/bin/tcc -ar cr ''${out}/lib/libtcc1.a libtcc1.o
|
||||
''${out}/bin/tcc ${mes-libc.CFLAGS} -c -o libgetopt.o ${mes-libc}/lib/libgetopt.c
|
||||
''${out}/bin/tcc -ar cr ''${out}/lib/libgetopt.a libgetopt.o
|
||||
'';
|
||||
libs = recompileLibc {
|
||||
inherit pname version;
|
||||
tcc = compiler;
|
||||
src = mes-libc;
|
||||
libtccOptions = mes-libc.CFLAGS;
|
||||
};
|
||||
};
|
||||
|
||||
# Bootstrap stage build flags obtained from
|
||||
# https://gitlab.com/janneke/tinycc/-/blob/80114c4da6b17fbaabb399cc29f427e368309bc8/boot.sh
|
||||
|
|
|
@ -3,67 +3,105 @@
|
|||
, mes-libc
|
||||
, ln-boot
|
||||
}:
|
||||
{
|
||||
buildTinyccMes = {
|
||||
pname,
|
||||
version,
|
||||
src,
|
||||
prev,
|
||||
buildOptions,
|
||||
libtccBuildOptions,
|
||||
meta
|
||||
}:
|
||||
|
||||
rec {
|
||||
|
||||
# Recompile libc: crt{1,n,i}, libtcc.a, libc.a, libgetopt.a
|
||||
recompileLibc =
|
||||
{ tcc
|
||||
, pname
|
||||
, version
|
||||
, src
|
||||
, libtccOptions
|
||||
}:
|
||||
let
|
||||
|
||||
crt = kaem.runCommand "crt" {} ''
|
||||
mkdir -p ''${out}/lib
|
||||
${tcc}/bin/tcc ${mes-libc.CFLAGS} -c -o ''${out}/lib/crt1.o ${mes-libc}/lib/crt1.c
|
||||
${tcc}/bin/tcc ${mes-libc.CFLAGS} -c -o ''${out}/lib/crtn.o ${mes-libc}/lib/crtn.c
|
||||
${tcc}/bin/tcc ${mes-libc.CFLAGS} -c -o ''${out}/lib/crti.o ${mes-libc}/lib/crti.c
|
||||
'';
|
||||
|
||||
library = lib: options: source: kaem.runCommand "${lib}.a" {} ''
|
||||
${tcc}/bin/tcc ${options} -c -o ${lib}.o ${source}
|
||||
${tcc}/bin/tcc -ar cr ''${out} ${lib}.o
|
||||
'';
|
||||
|
||||
libtcc1 = library "libtcc1" libtccOptions "${src}/lib/libtcc1.c";
|
||||
libc = library "libc" mes-libc.CFLAGS "${mes-libc}/lib/libc.c";
|
||||
libgetopt = library "libgetopt" mes-libc.CFLAGS "${mes-libc}/lib/libgetopt.c";
|
||||
in
|
||||
kaem.runCommand "${pname}-libs-${version}" {} ''
|
||||
mkdir -p ''${out}/lib
|
||||
cp ${crt}/lib/crt1.o ''${out}/lib
|
||||
cp ${crt}/lib/crtn.o ''${out}/lib
|
||||
cp ${crt}/lib/crti.o ''${out}/lib
|
||||
cp ${libtcc1} ''${out}/lib/libtcc1.a
|
||||
cp ${libc} ''${out}/lib/libc.a
|
||||
cp ${libgetopt} ''${out}/lib/libgetopt.a
|
||||
'';
|
||||
|
||||
buildTinyccMes =
|
||||
{ pname
|
||||
, version
|
||||
, src
|
||||
, prev
|
||||
, buildOptions
|
||||
, libtccBuildOptions
|
||||
, meta
|
||||
}:
|
||||
let
|
||||
options = lib.strings.concatStringsSep " " buildOptions;
|
||||
libtccOptions = lib.strings.concatStringsSep " " libtccBuildOptions;
|
||||
in
|
||||
kaem.runCommand "${pname}-${version}" {
|
||||
inherit pname version meta;
|
||||
nativeBuildInputs = [ ln-boot ];
|
||||
} ''
|
||||
catm config.h
|
||||
mkdir -p ''${out}/bin
|
||||
${prev}/bin/tcc \
|
||||
-g \
|
||||
-v \
|
||||
-static \
|
||||
-o ''${out}/bin/tcc \
|
||||
-D BOOTSTRAP=1 \
|
||||
${options} \
|
||||
-I . \
|
||||
-I ${src} \
|
||||
-D TCC_TARGET_I386=1 \
|
||||
-D CONFIG_TCCDIR=\"''${out}/lib\" \
|
||||
-D CONFIG_TCC_CRTPREFIX=\"''${out}/lib\" \
|
||||
-D CONFIG_TCC_ELFINTERP=\"\" \
|
||||
-D CONFIG_TCC_LIBPATHS=\"''${out}/lib\" \
|
||||
-D CONFIG_TCC_SYSINCLUDEPATHS=\"${mes-libc}/include:${src}/include\" \
|
||||
-D TCC_LIBGCC=\"libc.a\" \
|
||||
-D TCC_LIBTCC1=\"libtcc1.a\" \
|
||||
-D CONFIG_TCCBOOT=1 \
|
||||
-D CONFIG_TCC_STATIC=1 \
|
||||
-D CONFIG_USE_LIBGCC=1 \
|
||||
-D TCC_MES_LIBC=1 \
|
||||
-D TCC_VERSION=\"${version}\" \
|
||||
-D ONE_SOURCE=1 \
|
||||
-L ${prev}/lib \
|
||||
${src}/tcc.c
|
||||
|
||||
''${out}/bin/tcc -v
|
||||
|
||||
# Recompile libc: crt{1,n,i}, libtcc.a, libc.a, libgetopt.a
|
||||
mkdir -p ''${out}/lib
|
||||
''${out}/bin/tcc ${mes-libc.CFLAGS} -c -o ''${out}/lib/crt1.o ${mes-libc}/lib/crt1.c
|
||||
''${out}/bin/tcc ${mes-libc.CFLAGS} -c -o ''${out}/lib/crtn.o ${mes-libc}/lib/crtn.c
|
||||
''${out}/bin/tcc ${mes-libc.CFLAGS} -c -o ''${out}/lib/crti.o ${mes-libc}/lib/crti.c
|
||||
''${out}/bin/tcc -c -D TCC_TARGET_I386=1 ${libtccOptions} -o libtcc1.o ${src}/lib/libtcc1.c
|
||||
''${out}/bin/tcc -ar cr ''${out}/lib/libtcc1.a libtcc1.o
|
||||
''${out}/bin/tcc ${mes-libc.CFLAGS} -c -o libc.o ${mes-libc}/lib/libc.c
|
||||
''${out}/bin/tcc -ar cr ''${out}/lib/libc.a libc.o
|
||||
''${out}/bin/tcc ${mes-libc.CFLAGS} -c -o libgetopt.o ${mes-libc}/lib/libgetopt.c
|
||||
''${out}/bin/tcc -ar cr ''${out}/lib/libgetopt.a libgetopt.o
|
||||
|
||||
# Install headers
|
||||
ln -s ${mes-libc}/include ''${out}/include
|
||||
'';
|
||||
libtccOptions = lib.strings.concatStringsSep " "
|
||||
(["-c" "-D" "TCC_TARGET_I386=1" ] ++ libtccBuildOptions);
|
||||
compiler = kaem.runCommand "${pname}-${version}" {
|
||||
inherit pname version meta;
|
||||
nativeBuildInputs = [ ln-boot ];
|
||||
passthru.tests = rec {
|
||||
get-version = result: kaem.runCommand "${pname}-get-version-${version}" {} ''
|
||||
${result}/bin/tcc -version
|
||||
mkdir ''${out}
|
||||
'';
|
||||
chain = result: kaem.runCommand "${pname}-chain-${version}" {} ''
|
||||
echo ${prev.compiler.tests.chain or prev.compiler.tests.get-version};
|
||||
${result}/bin/tcc -version
|
||||
mkdir ''${out}
|
||||
'';
|
||||
};
|
||||
} ''
|
||||
catm config.h
|
||||
mkdir -p ''${out}/bin
|
||||
${prev.compiler}/bin/tcc \
|
||||
-B ${prev.libs}/lib \
|
||||
-g \
|
||||
-v \
|
||||
-static \
|
||||
-o ''${out}/bin/tcc \
|
||||
-D BOOTSTRAP=1 \
|
||||
${options} \
|
||||
-I . \
|
||||
-I ${src} \
|
||||
-D TCC_TARGET_I386=1 \
|
||||
-D CONFIG_TCCDIR=\"\" \
|
||||
-D CONFIG_SYSROOT=\"\" \
|
||||
-D CONFIG_TCC_CRTPREFIX=\"{B}\" \
|
||||
-D CONFIG_TCC_ELFINTERP=\"\" \
|
||||
-D CONFIG_TCC_LIBPATHS=\"{B}\" \
|
||||
-D CONFIG_TCC_SYSINCLUDEPATHS=\"${mes-libc}/include\" \
|
||||
-D TCC_LIBGCC=\"libc.a\" \
|
||||
-D TCC_LIBTCC1=\"libtcc1.a\" \
|
||||
-D CONFIG_TCCBOOT=1 \
|
||||
-D CONFIG_TCC_STATIC=1 \
|
||||
-D CONFIG_USE_LIBGCC=1 \
|
||||
-D TCC_MES_LIBC=1 \
|
||||
-D TCC_VERSION=\"${version}\" \
|
||||
-D ONE_SOURCE=1 \
|
||||
${src}/tcc.c
|
||||
'';
|
||||
libs = recompileLibc {
|
||||
inherit pname version src libtccOptions;
|
||||
tcc = compiler;
|
||||
};
|
||||
in { inherit prev compiler libs; };
|
||||
}
|
||||
|
|
|
@ -37,7 +37,12 @@ let
|
|||
|
||||
tccdefs = kaem.runCommand "tccdefs-${version}" {} ''
|
||||
mkdir ''${out}
|
||||
${tinycc-bootstrappable}/bin/tcc -static -DC2STR -o c2str ${src}/conftest.c
|
||||
${tinycc-bootstrappable.compiler}/bin/tcc \
|
||||
-B ${tinycc-bootstrappable.libs}/lib \
|
||||
-static \
|
||||
-DC2STR \
|
||||
-o c2str \
|
||||
${src}/conftest.c
|
||||
./c2str ${src}/include/tccdefs.h ''${out}/tccdefs_.h
|
||||
'';
|
||||
|
||||
|
|
|
@ -18,14 +18,18 @@ rec {
|
|||
passthru = attrs.passthru or {};
|
||||
validity = checkMeta.assertValidity { inherit meta attrs; };
|
||||
meta = checkMeta.commonMeta { inherit validity attrs; };
|
||||
baseDrv = derivation ({
|
||||
inherit (buildPlatform) system;
|
||||
inherit (meta) name;
|
||||
} // (builtins.removeAttrs attrs [ "meta" "passthru" ]));
|
||||
passthru' = passthru // lib.optionalAttrs (passthru ? tests) {
|
||||
tests = lib.mapAttrs (_: f: f baseDrv) passthru.tests;
|
||||
};
|
||||
in
|
||||
lib.extendDerivation
|
||||
validity.handled
|
||||
({ inherit meta passthru; } // passthru)
|
||||
(derivation ({
|
||||
inherit (buildPlatform) system;
|
||||
inherit (meta) name;
|
||||
} // (builtins.removeAttrs attrs [ "meta" "passthru" ])));
|
||||
({ inherit meta; passthru = passthru'; } // passthru')
|
||||
baseDrv;
|
||||
|
||||
writeTextFile =
|
||||
{ name # the name of the derivation
|
||||
|
@ -36,7 +40,7 @@ rec {
|
|||
, preferLocalBuild ? true
|
||||
}:
|
||||
derivationWithMeta {
|
||||
inherit name text executable allowSubstitutes preferLocalBuild;
|
||||
inherit name text allowSubstitutes preferLocalBuild;
|
||||
passAsFile = [ "text" ];
|
||||
|
||||
builder = "${kaem}/bin/kaem";
|
||||
|
@ -44,20 +48,18 @@ rec {
|
|||
"--verbose"
|
||||
"--strict"
|
||||
"--file"
|
||||
(builtins.toFile "write-text-file.kaem" ''
|
||||
(builtins.toFile "write-text-file.kaem" (''
|
||||
target=''${out}''${destination}
|
||||
if match x''${mkdirDestination} x1; then
|
||||
mkdir -p ''${out}''${destinationDir}
|
||||
fi
|
||||
'' + lib.optionalString (builtins.dirOf destination == ".") ''
|
||||
mkdir -p ''${out}''${destinationDir}
|
||||
'' + ''
|
||||
cp ''${textPath} ''${target}
|
||||
if match x''${executable} x1; then
|
||||
chmod 555 ''${target}
|
||||
fi
|
||||
'')
|
||||
'' + lib.optionalString executable ''
|
||||
chmod 555 ''${target}
|
||||
''))
|
||||
];
|
||||
|
||||
PATH = lib.makeBinPath [ mescc-tools-extra ];
|
||||
mkdirDestination = if builtins.dirOf destination == "." then "0" else "1";
|
||||
destinationDir = builtins.dirOf destination;
|
||||
inherit destination;
|
||||
};
|
||||
|
|
|
@ -42,6 +42,15 @@ rec {
|
|||
openSha256 = "sha256-etbtw6LMRUcFoZC9EDDRrTDekV8JFRYmkp3idLaMk5g=";
|
||||
settingsSha256 = "sha256-8KB6T9f+gWl8Ni+uOyrJKiiH5mNx9eyfCcW/RjPTQQA=";
|
||||
persistencedSha256 = "sha256-zrstlt/0YVGnsPGUuBbR9ULutywi2wNDVxh7OhJM7tM=";
|
||||
|
||||
patchFlags = [ "-p1" "-d" "kernel" ];
|
||||
patches = [
|
||||
# source: https://gist.github.com/joanbm/77f0650d45747b9a4dc8e330ade2bf5c
|
||||
(fetchpatch {
|
||||
url = "https://gist.github.com/joanbm/77f0650d45747b9a4dc8e330ade2bf5c/raw/688b612624945926676de28059fe749203b4b549/nvidia-470xx-fix-linux-6.4.patch";
|
||||
hash = "sha256-OyRmezyzqAi7mSJHDjsWQVocSsgJPTW5DvHDFVNX7Dk=";
|
||||
})
|
||||
];
|
||||
});
|
||||
|
||||
beta = selectHighestVersion latest (generic {
|
||||
|
@ -78,15 +87,18 @@ rec {
|
|||
settingsSha256 = "sha256-TRKQ4brLnCbBZt1smGSIHTfwW+wEFPWWPEwDxjVXN7s=";
|
||||
persistencedSha256 = "sha256-fSJMx49z9trdNxx0iPI45oG57smvvhaqVNxsRnfXKCI=";
|
||||
|
||||
prePatch = "pushd kernel";
|
||||
postPatch = "popd";
|
||||
|
||||
patchFlags = [ "-p1" "-d" "kernel" ];
|
||||
patches = [
|
||||
# source: https://gist.github.com/joanbm/d10e9cbbbb8e245b6e7e27b2db338faf
|
||||
(fetchpatch {
|
||||
url = "https://gist.github.com/joanbm/d10e9cbbbb8e245b6e7e27b2db338faf/raw/f5d5238bdbaa16cd4008658a0f82b9dd84f1b38f/nvidia-470xx-fix-linux-6.3.patch";
|
||||
hash = "sha256-mR+vXDHgVhWC0JeLgGlbNVCH8XTs7XnhEJS6BV75tI8=";
|
||||
})
|
||||
# source: https://gist.github.com/joanbm/77f0650d45747b9a4dc8e330ade2bf5c
|
||||
(fetchpatch {
|
||||
url = "https://gist.github.com/joanbm/77f0650d45747b9a4dc8e330ade2bf5c/raw/688b612624945926676de28059fe749203b4b549/nvidia-470xx-fix-linux-6.4.patch";
|
||||
hash = "sha256-OyRmezyzqAi7mSJHDjsWQVocSsgJPTW5DvHDFVNX7Dk=";
|
||||
})
|
||||
];
|
||||
};
|
||||
|
||||
|
@ -97,6 +109,8 @@ rec {
|
|||
sha256_64bit = "sha256-W+u8puj+1da52BBw+541HxjtxTSVJVPL3HHo/QubMoo=";
|
||||
settingsSha256 = "sha256-uJZO4ak/w/yeTQ9QdXJSiaURDLkevlI81de0q4PpFpw=";
|
||||
persistencedSha256 = "sha256-NuqUQbVt80gYTXgIcu0crAORfsj9BCRooyH3Gp1y1ns=";
|
||||
|
||||
broken = kernel.kernelAtLeast "6.2";
|
||||
};
|
||||
|
||||
legacy_340 = let
|
||||
|
@ -104,8 +118,8 @@ rec {
|
|||
aurPatches = fetchFromGitHub {
|
||||
owner = "archlinux-jerry";
|
||||
repo = "nvidia-340xx";
|
||||
rev = "fe2b38e66f2199777bcede6eb35c5df0210f15dc";
|
||||
hash = "sha256-hPFfzWGo2jF/DLm1OkP+BBnRY69N8kKUZ1EGkoHJlKA=";
|
||||
rev = "f472f9297fe2ae285b954cd3f88abd8e2e255e4f";
|
||||
hash = "sha256-tMA69Wlhi14DMS3O3nfwMX3EiT8pKa6McLxFpAayoEI=";
|
||||
};
|
||||
patchset = [
|
||||
"0001-kernel-5.7.patch"
|
||||
|
@ -119,6 +133,8 @@ rec {
|
|||
"0009-kernel-5.17.patch"
|
||||
"0010-kernel-5.18.patch"
|
||||
"0011-kernel-6.0.patch"
|
||||
"0012-kernel-6.2.patch"
|
||||
"0013-kernel-6.3.patch"
|
||||
];
|
||||
in generic {
|
||||
version = "340.108";
|
||||
|
@ -128,7 +144,7 @@ rec {
|
|||
persistencedSha256 = "1ax4xn3nmxg1y6immq933cqzw6cj04x93saiasdc0kjlv0pvvnkn";
|
||||
useGLVND = false;
|
||||
|
||||
broken = kernel.kernelAtLeast "6.2";
|
||||
broken = kernel.kernelAtLeast "6.4";
|
||||
patches = map (patch: "${aurPatches}/${patch}") patchset;
|
||||
};
|
||||
}
|
||||
|
|
|
@ -16,6 +16,7 @@
|
|||
|
||||
, prePatch ? ""
|
||||
, postPatch ? null
|
||||
, patchFlags ? null
|
||||
, patches ? []
|
||||
, broken ? false
|
||||
, brokenOpen ? broken
|
||||
|
@ -85,7 +86,7 @@ let
|
|||
else throw "nvidia-x11 does not support platform ${stdenv.hostPlatform.system}";
|
||||
|
||||
patches = if libsOnly then null else patches;
|
||||
inherit prePatch postPatch;
|
||||
inherit prePatch postPatch patchFlags;
|
||||
inherit version useGLVND useProfiles;
|
||||
inherit (stdenv.hostPlatform) system;
|
||||
inherit i686bundled;
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{ lib, stdenv, fetchFromGitHub, buildGoModule, makeWrapper
|
||||
, cacert, moreutils, jq, git, pkg-config, yarn, python3
|
||||
, esbuild, nodejs_16, libsecret, xorg, ripgrep
|
||||
, AppKit, Cocoa, Security, cctools }:
|
||||
, AppKit, Cocoa, Security, cctools, nixosTests }:
|
||||
|
||||
let
|
||||
system = stdenv.hostPlatform.system;
|
||||
|
@ -164,6 +164,10 @@ in stdenv.mkDerivation rec {
|
|||
ln -s ${nodejs}/bin/node $out
|
||||
'';
|
||||
|
||||
passthru.tests = {
|
||||
inherit (nixosTests) openvscode-server;
|
||||
};
|
||||
|
||||
meta = with lib; {
|
||||
description = "Run VS Code on a remote machine";
|
||||
longDescription = ''
|
||||
|
|
|
@ -5,6 +5,7 @@
|
|||
, gawk
|
||||
, python3
|
||||
, installShellFiles
|
||||
, bash
|
||||
}:
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "amazon-ec2-utils";
|
||||
|
@ -22,6 +23,7 @@ stdenv.mkDerivation rec {
|
|||
strictDeps = true;
|
||||
buildInputs = [
|
||||
python3
|
||||
bash
|
||||
];
|
||||
nativeBuildInputs = [
|
||||
installShellFiles
|
||||
|
|
43
pkgs/tools/text/frogmouth/default.nix
Normal file
43
pkgs/tools/text/frogmouth/default.nix
Normal file
|
@ -0,0 +1,43 @@
|
|||
{ lib
|
||||
, python3
|
||||
, fetchFromGitHub
|
||||
}:
|
||||
|
||||
python3.pkgs.buildPythonApplication rec {
|
||||
pname = "frogmouth";
|
||||
version = "0.5.0";
|
||||
format = "pyproject";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "Textualize";
|
||||
repo = "frogmouth";
|
||||
rev = "v${version}";
|
||||
hash = "sha256-5MNQ78zwjtenHDjy2g1rjiq4HvFie7uUSlMwZu6RmXg=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
python3.pkgs.poetry-core
|
||||
python3.pkgs.pythonRelaxDepsHook
|
||||
];
|
||||
|
||||
propagatedBuildInputs = with python3.pkgs; [
|
||||
httpx
|
||||
textual
|
||||
typing-extensions
|
||||
xdg
|
||||
];
|
||||
|
||||
pythonRelaxDeps = [
|
||||
"xdg"
|
||||
];
|
||||
|
||||
pythonImportsCheck = [ "frogmouth" ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "A Markdown browser for your terminal";
|
||||
homepage = "https://github.com/Textualize/frogmouth";
|
||||
changelog = "https://github.com/Textualize/frogmouth/blob/${src.rev}/ChangeLog.md";
|
||||
license = licenses.mit;
|
||||
maintainers = with maintainers; [ figsoda ];
|
||||
};
|
||||
}
|
|
@ -2,16 +2,16 @@
|
|||
|
||||
buildGoModule rec {
|
||||
pname = "goawk";
|
||||
version = "1.22.0";
|
||||
version = "1.23.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "benhoyt";
|
||||
repo = "goawk";
|
||||
rev = "v${version}";
|
||||
sha256 = "sha256-8UoYGAmYmC0hcxLfkNac3flKyPBT/xsykuy+TvVosBI=";
|
||||
sha256 = "sha256-uqr4edYPe29YbUm52werxPa/eo1HkR2K34FI43itzVY=";
|
||||
};
|
||||
|
||||
vendorSha256 = null;
|
||||
vendorHash = null;
|
||||
|
||||
nativeCheckInputs = [ gawk ];
|
||||
|
||||
|
|
|
@ -80,6 +80,7 @@ mapAliases ({
|
|||
amuleGui = throw "amuleGui was renamed to amule-gui"; # Added 2022-02-11
|
||||
amsn = throw "amsn has been removed due to being unmaintained"; # Added 2020-12-09
|
||||
angelfish = libsForQt5.kdeGear.angelfish; # Added 2021-10-06
|
||||
ansible_2_12 = throw "Ansible 2.12 goes end of life in 2023/05 and can't be supported throughout the 23.05 release cycle"; # Added 2023-05-16
|
||||
ansible_2_11 = throw "Ansible 2.11 goes end of life in 2022/11 and can't be supported throughout the 22.05 release cycle"; # Added 2022-03-30
|
||||
ansible_2_10 = throw "Ansible 2.10 went end of life in 2022/05 and has subsequently been dropped"; # Added 2022-03-30
|
||||
ansible_2_9 = throw "Ansible 2.9 went end of life in 2022/05 and has subsequently been dropped"; # Added 2022-03-30
|
||||
|
|
|
@ -4843,6 +4843,8 @@ with pkgs;
|
|||
|
||||
frei = callPackage ../tools/misc/frei { };
|
||||
|
||||
frogmouth = callPackage ../tools/text/frogmouth { };
|
||||
|
||||
fselect = callPackage ../tools/misc/fselect { };
|
||||
|
||||
fsmon = callPackage ../tools/misc/fsmon { };
|
||||
|
@ -16379,6 +16381,7 @@ with pkgs;
|
|||
cargo-semver-checks = callPackage ../development/tools/rust/cargo-semver-checks { };
|
||||
|
||||
cargo-show-asm = callPackage ../development/tools/rust/cargo-show-asm { };
|
||||
cargo-shuttle = callPackage ../development/tools/rust/cargo-shuttle { };
|
||||
|
||||
cargo-sort = callPackage ../development/tools/rust/cargo-sort { };
|
||||
cargo-spellcheck = callPackage ../development/tools/rust/cargo-spellcheck {
|
||||
|
@ -17495,22 +17498,21 @@ with pkgs;
|
|||
|
||||
autoadb = callPackage ../misc/autoadb { };
|
||||
|
||||
ansible = ansible_2_14;
|
||||
ansible_2_14 = python3Packages.toPythonApplication python3Packages.ansible-core;
|
||||
ansible_2_13 = python3Packages.toPythonApplication (python3Packages.ansible-core.overridePythonAttrs (oldAttrs: rec {
|
||||
version = "2.13.6";
|
||||
ansible = ansible_2_15;
|
||||
ansible_2_15 = python3Packages.toPythonApplication python3Packages.ansible-core;
|
||||
ansible_2_14 = python3Packages.toPythonApplication (python3Packages.ansible-core.overridePythonAttrs (oldAttrs: rec {
|
||||
version = "2.14.5";
|
||||
src = oldAttrs.src.override {
|
||||
inherit version;
|
||||
hash = "sha256-Mf4yK2MpBnSo9zhhEN9QHwBEqkSJC+OrMTpuIluaKc8=";
|
||||
hash = "sha256-jE7tds5Fi0o3M0oIAt8pSI7Pn4rzjDERBpyWsXsgVTA=";
|
||||
};
|
||||
}));
|
||||
ansible_2_12 = python3Packages.toPythonApplication (python3Packages.ansible-core.overridePythonAttrs (oldAttrs: rec {
|
||||
version = "2.12.10";
|
||||
ansible_2_13 = python3Packages.toPythonApplication (python3Packages.ansible-core.overridePythonAttrs (oldAttrs: rec {
|
||||
version = "2.13.9";
|
||||
src = oldAttrs.src.override {
|
||||
inherit version;
|
||||
hash = "sha256-/rHfYXOM/B9eiTtCouwafeMpd9Z+hnB7Retj0MXDwjY=";
|
||||
hash = "sha256-nDGeygqcU83m8XSBLd1xFO2x5dDrXh30e9DY/v7ax2w=";
|
||||
};
|
||||
meta.changelog = "https://github.com/ansible/ansible/blob/v${version}/changelogs/CHANGELOG-v${lib.versions.majorMinor version}.rst";
|
||||
}));
|
||||
|
||||
ansible-doctor = callPackage ../tools/admin/ansible/doctor.nix { };
|
||||
|
|
Loading…
Reference in a new issue