Merge staging-next into staging
This commit is contained in:
commit
9dbe8733d5
69
pkgs/build-support/make-pkgconfigitem/default.nix
Normal file
69
pkgs/build-support/make-pkgconfigitem/default.nix
Normal file
@ -0,0 +1,69 @@
|
||||
{ lib, writeTextFile, buildPackages }:
|
||||
|
||||
# See https://people.freedesktop.org/~dbn/pkg-config-guide.html#concepts
|
||||
{ name # The name of the pc file
|
||||
# keywords
|
||||
# provide a default description for convenience. it's not important but still required by pkg-config.
|
||||
, description ? "A pkg-config file for ${name}"
|
||||
, url ? ""
|
||||
, version ? ""
|
||||
, requires ? [ ]
|
||||
, requiresPrivate ? [ ]
|
||||
, conflicts ? [ ]
|
||||
, cflags ? [ ]
|
||||
, libs ? [ ]
|
||||
, libsPrivate ? [ ]
|
||||
, variables ? { }
|
||||
}:
|
||||
|
||||
let
|
||||
# only 'out' has to be changed, otherwise it would be replaced by the out of the writeTextFile
|
||||
placeholderToSubstVar = builtins.replaceStrings [ "${placeholder "out"}" ] [ "@out@" ];
|
||||
|
||||
replacePlaceholderAndListToString = x:
|
||||
if builtins.isList x
|
||||
then placeholderToSubstVar (builtins.concatStringsSep " " x)
|
||||
else placeholderToSubstVar x;
|
||||
|
||||
keywordsSection =
|
||||
let
|
||||
mustBeAList = attr: attrName: lib.throwIfNot (lib.isList attr) "'${attrName}' must be a list" attr;
|
||||
in
|
||||
{
|
||||
"Name" = name;
|
||||
"Description" = description;
|
||||
"URL" = url;
|
||||
"Version" = version;
|
||||
"Requires" = mustBeAList requires "requires";
|
||||
"Requires.private" = mustBeAList requiresPrivate "requiresPrivate";
|
||||
"Conflicts" = mustBeAList conflicts "conflicts";
|
||||
"Cflags" = mustBeAList cflags "cflags";
|
||||
"Libs" = mustBeAList libs "libs";
|
||||
"Libs.private" = mustBeAList libsPrivate "libsPrivate";
|
||||
};
|
||||
|
||||
renderVariable = name: value:
|
||||
lib.optionalString (value != "" && value != [ ]) "${name}=${replacePlaceholderAndListToString value}";
|
||||
renderKeyword = name: value:
|
||||
lib.optionalString (value != "" && value != [ ]) "${name}: ${replacePlaceholderAndListToString value}";
|
||||
|
||||
renderSomething = renderFunc: attrs:
|
||||
lib.pipe attrs [
|
||||
(lib.mapAttrsToList renderFunc)
|
||||
(builtins.filter (v: v != ""))
|
||||
(builtins.concatStringsSep "\n")
|
||||
(section: ''${section}
|
||||
'')
|
||||
];
|
||||
|
||||
variablesSectionRendered = renderSomething renderVariable variables;
|
||||
keywordsSectionRendered = renderSomething renderKeyword keywordsSection;
|
||||
|
||||
content = [ variablesSectionRendered keywordsSectionRendered ];
|
||||
in
|
||||
writeTextFile {
|
||||
name = "${name}.pc";
|
||||
destination = "/lib/pkgconfig/${name}.pc";
|
||||
text = builtins.concatStringsSep "\n" content;
|
||||
checkPhase = ''${buildPackages.pkg-config}/bin/pkg-config --validate "$target"'';
|
||||
}
|
46
pkgs/build-support/setup-hooks/copy-pkgconfig-items.sh
Normal file
46
pkgs/build-support/setup-hooks/copy-pkgconfig-items.sh
Normal file
@ -0,0 +1,46 @@
|
||||
# shellcheck shell=bash
|
||||
|
||||
# Setup hook that installs specified pkgconfig items.
|
||||
#
|
||||
# Example usage in a derivation:
|
||||
#
|
||||
# { …, makePkgconfigItem, copyPkgconfigItems, … }:
|
||||
#
|
||||
# let pkgconfigItem = makePkgconfigItem { … }; in
|
||||
# stdenv.mkDerivation {
|
||||
# …
|
||||
# nativeBuildInputs = [ copyPkgconfigItems ];
|
||||
#
|
||||
# pkgconfigItems = [ pkgconfigItem ];
|
||||
# …
|
||||
# }
|
||||
#
|
||||
# This hook will copy files which are either given by full path
|
||||
# or all '*.pc' files placed inside the 'lib/pkgconfig'
|
||||
# folder of each `pkgconfigItems` argument.
|
||||
|
||||
postInstallHooks+=(copyPkgconfigItems)
|
||||
|
||||
copyPkgconfigItems() {
|
||||
if [ "${dontCopyPkgconfigItems-}" = 1 ]; then return; fi
|
||||
|
||||
if [ -z "$pkgconfigItems" ]; then
|
||||
return
|
||||
fi
|
||||
|
||||
pkgconfigdir="${!outputDev}/lib/pkgconfig"
|
||||
for pkgconfigItem in $pkgconfigItems; do
|
||||
if [[ -f "$pkgconfigItem" ]]; then
|
||||
substituteAllInPlace "$pkgconfigItem"
|
||||
echo "Copying '$pkgconfigItem' into '${pkgconfigdir}'"
|
||||
install -D -m 444 -t "${pkgconfigdir}" "$pkgconfigItem"
|
||||
substituteAllInPlace "${pkgconfigdir}"/*
|
||||
else
|
||||
for f in "$pkgconfigItem"/lib/pkgconfig/*.pc; do
|
||||
echo "Copying '$f' into '${pkgconfigdir}'"
|
||||
install -D -m 444 -t "${pkgconfigdir}" "$f"
|
||||
substituteAllInPlace "${pkgconfigdir}"/*
|
||||
done
|
||||
fi
|
||||
done
|
||||
}
|
@ -1,5 +1,22 @@
|
||||
{ lib, stdenv, fetchurl, gcc, makeWrapper
|
||||
, db, gmp, ncurses }:
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchurl
|
||||
, autoconf269
|
||||
, automake
|
||||
, libtool
|
||||
# libs
|
||||
, cjson
|
||||
, db
|
||||
, gmp
|
||||
, libxml2
|
||||
, ncurses
|
||||
# docs
|
||||
, help2man
|
||||
, texinfo
|
||||
, texlive
|
||||
# test
|
||||
, writeText
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "gnu-cobol";
|
||||
@ -10,27 +27,76 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "0x15ybfm63g7c9340fc6712h9v59spnbyaz4rf85pmnp3zbhaw2r";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ makeWrapper ];
|
||||
nativeBuildInputs = [
|
||||
autoconf269
|
||||
automake
|
||||
libtool
|
||||
help2man
|
||||
texinfo
|
||||
texlive.combined.scheme-basic
|
||||
];
|
||||
|
||||
buildInputs = [ db gmp ncurses ];
|
||||
buildInputs = [
|
||||
cjson
|
||||
db
|
||||
gmp
|
||||
libxml2
|
||||
ncurses
|
||||
];
|
||||
|
||||
cflags = lib.concatMapStringsSep " " (p: "-L" + (lib.getLib p) + "/lib ") buildInputs;
|
||||
ldflags = lib.concatMapStringsSep " " (p: "-I" + (lib.getDev p) + "/include ") buildInputs;
|
||||
outputs = [ "bin" "dev" "lib" "out" ];
|
||||
# XXX: Without this, we get a cycle between bin and dev
|
||||
propagatedBuildOutputs = [];
|
||||
|
||||
cobolCCFlags = "-I$out/include ${ldflags} -L$out/lib ${cflags}";
|
||||
# Skips a broken test
|
||||
postPatch = ''
|
||||
sed -i '/^AT_CHECK.*crud\.cob/i AT_SKIP_IF([true])' tests/testsuite.src/listings.at
|
||||
'';
|
||||
|
||||
postInstall = with lib; ''
|
||||
wrapProgram "$out/bin/cobc" \
|
||||
--set COB_CC "${gcc}/bin/gcc" \
|
||||
--prefix COB_LDFLAGS " " "${cobolCCFlags}" \
|
||||
--prefix COB_CFLAGS " " "${cobolCCFlags}"
|
||||
preConfigure = ''
|
||||
autoconf
|
||||
aclocal
|
||||
automake
|
||||
'';
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
installFlags = [ "install-pdf" "install-html" "localedir=$out/share/locale" ];
|
||||
|
||||
# Tests must run after install.
|
||||
doCheck = false;
|
||||
|
||||
doInstallCheck = true;
|
||||
installCheckPhase = ''
|
||||
runHook preInstallCheck
|
||||
|
||||
# Run tests
|
||||
make -j$NIX_BUILD_CORES check
|
||||
|
||||
# Sanity check
|
||||
message="Hello, COBOL!"
|
||||
# XXX: Don't for a second think you can just get rid of these spaces, they
|
||||
# are load bearing.
|
||||
tee hello.cbl <<EOF
|
||||
IDENTIFICATION DIVISION.
|
||||
PROGRAM-ID. HELLO.
|
||||
|
||||
PROCEDURE DIVISION.
|
||||
DISPLAY "$message".
|
||||
STOP RUN.
|
||||
EOF
|
||||
$bin/bin/cobc -x -o hello-cobol "hello.cbl"
|
||||
hello="$(./hello-cobol | tee >(cat >&2))"
|
||||
[[ "$hello" == "$message" ]] || exit 1
|
||||
|
||||
runHook postInstallCheck
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "An open-source COBOL compiler";
|
||||
homepage = "https://sourceforge.net/projects/gnucobol/";
|
||||
license = with licenses; [ gpl3Only lgpl3Only ];
|
||||
maintainers = with maintainers; [ ericsagnes ];
|
||||
maintainers = with maintainers; [ ericsagnes lovesegfault ];
|
||||
platforms = platforms.all;
|
||||
};
|
||||
}
|
||||
|
@ -1,6 +1,8 @@
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchFromRepoOrCz
|
||||
, copyPkgconfigItems
|
||||
, makePkgconfigItem
|
||||
, perl
|
||||
, texinfo
|
||||
, which
|
||||
@ -17,11 +19,32 @@ stdenv.mkDerivation rec {
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
copyPkgconfigItems
|
||||
perl
|
||||
texinfo
|
||||
which
|
||||
];
|
||||
|
||||
pkgconfigItems = [
|
||||
(makePkgconfigItem rec {
|
||||
name = "libtcc";
|
||||
inherit version;
|
||||
cflags = [ "-I${variables.includedir}" ];
|
||||
libs = [
|
||||
"-L${variables.libdir}"
|
||||
"-Wl,--rpath ${variables.libdir}"
|
||||
"-ltcc"
|
||||
"-ldl"
|
||||
];
|
||||
variables = rec {
|
||||
prefix = "${placeholder "out"}";
|
||||
includedir = "${prefix}/include";
|
||||
libdir = "${prefix}/lib";
|
||||
};
|
||||
description = "Tiny C compiler backend";
|
||||
})
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
patchShebangs texi2pod.pl
|
||||
'';
|
||||
@ -43,17 +66,6 @@ stdenv.mkDerivation rec {
|
||||
configureFlagsArray+=("--elfinterp=$(< $NIX_CC/nix-support/dynamic-linker)")
|
||||
'';
|
||||
|
||||
postFixup = ''
|
||||
cat >libtcc.pc <<EOF
|
||||
Name: libtcc
|
||||
Description: Tiny C compiler backend
|
||||
Version: ${version}
|
||||
Libs: -L$out/lib -Wl,--rpath $out/lib -ltcc -ldl
|
||||
Cflags: -I$out/include
|
||||
EOF
|
||||
install -Dt $out/lib/pkgconfig libtcc.pc -m 444
|
||||
'';
|
||||
|
||||
outputs = [ "out" "info" "man" ];
|
||||
|
||||
doCheck = true;
|
||||
|
@ -239,6 +239,7 @@ stdenv.mkDerivation rec {
|
||||
'';
|
||||
license = licenses.gpl3;
|
||||
maintainers = with maintainers; [ ];
|
||||
platforms = platforms.all;
|
||||
inherit branch knownVulnerabilities;
|
||||
};
|
||||
}
|
||||
|
@ -1,8 +1,8 @@
|
||||
diff --git c/configure.ac w/configure.ac
|
||||
index 09cb310..30c0e2a 100644
|
||||
--- c/configure.ac
|
||||
+++ w/configure.ac
|
||||
@@ -110,7 +110,7 @@ AS_CASE([$host_os],
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index 5b6d22b..98c449b 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -145,7 +145,7 @@ AS_CASE([$host_os],
|
||||
AM_CONDITIONAL([OS_WINDOWS], [test "x$is_windows" = "xyes"])
|
||||
|
||||
# Checks for header files.
|
||||
@ -11,20 +11,51 @@ index 09cb310..30c0e2a 100644
|
||||
|
||||
# Checks for typedefs, structures, and compiler characteristics.
|
||||
AC_C_INLINE
|
||||
@@ -210,7 +210,8 @@ AC_LINK_IFELSE(
|
||||
@@ -245,7 +245,9 @@ AC_LINK_IFELSE(
|
||||
|
||||
AC_CHECK_FUNCS([clearenv dirfd fopencookie __fpurge \
|
||||
getauxval getentropy getexecname getline \
|
||||
- pstat_getproc sysconf])
|
||||
+ pstat_getproc sysconf \
|
||||
+ strlcpy strlcat strnstr strmode fpurge])
|
||||
+ strlcpy strlcat strnstr strmode fpurge \
|
||||
+ user_from_uid group_from_gid])
|
||||
AM_CONDITIONAL([HAVE_GETENTROPY], [test "x$ac_cv_func_getentropy" = "xtrue"])
|
||||
|
||||
AC_SUBST([LIBBSD_LIBS])
|
||||
diff --git c/include/bsd/string.h w/include/bsd/string.h
|
||||
AC_SUBST([MD5_LIBS])
|
||||
diff --git a/include/bsd/grp.h b/include/bsd/grp.h
|
||||
index b2705e5..c9423a2 100644
|
||||
--- a/include/bsd/grp.h
|
||||
+++ b/include/bsd/grp.h
|
||||
@@ -44,8 +44,10 @@
|
||||
__BEGIN_DECLS
|
||||
int
|
||||
gid_from_group(const char *, gid_t *);
|
||||
+#if !HAVE_GROUP_FROM_GID
|
||||
const char *
|
||||
group_from_gid(gid_t, int);
|
||||
+#endif
|
||||
__END_DECLS
|
||||
|
||||
#endif
|
||||
diff --git a/include/bsd/pwd.h b/include/bsd/pwd.h
|
||||
index 798af4b..6ae5244 100644
|
||||
--- a/include/bsd/pwd.h
|
||||
+++ b/include/bsd/pwd.h
|
||||
@@ -44,8 +44,10 @@
|
||||
__BEGIN_DECLS
|
||||
int
|
||||
uid_from_user(const char *, uid_t *);
|
||||
+#if !HAVE_USER_FROM_UID
|
||||
const char *
|
||||
user_from_uid(uid_t, int);
|
||||
+#endif
|
||||
__END_DECLS
|
||||
|
||||
#endif
|
||||
diff --git a/include/bsd/string.h b/include/bsd/string.h
|
||||
index f987fee..a1e17ed 100644
|
||||
--- c/include/bsd/string.h
|
||||
+++ w/include/bsd/string.h
|
||||
--- a/include/bsd/string.h
|
||||
+++ b/include/bsd/string.h
|
||||
@@ -41,10 +41,21 @@
|
||||
#include <sys/types.h>
|
||||
|
||||
@ -47,10 +78,10 @@ index f987fee..a1e17ed 100644
|
||||
|
||||
#if !defined(__GLIBC__) || \
|
||||
(defined(__GLIBC__) && (!__GLIBC_PREREQ(2, 25) || !defined(_GNU_SOURCE)))
|
||||
diff --git c/src/fpurge.c w/src/fpurge.c
|
||||
index 462535a..a8941db 100644
|
||||
--- c/src/fpurge.c
|
||||
+++ w/src/fpurge.c
|
||||
diff --git a/src/fpurge.c b/src/fpurge.c
|
||||
index 350f364..ff7f01e 100644
|
||||
--- a/src/fpurge.c
|
||||
+++ b/src/fpurge.c
|
||||
@@ -26,9 +26,10 @@
|
||||
|
||||
#include <errno.h>
|
||||
@ -100,10 +131,10 @@ index 462535a..a8941db 100644
|
||||
#else
|
||||
#error "Function fpurge() needs to be ported."
|
||||
#endif
|
||||
diff --git c/src/funopen.c w/src/funopen.c
|
||||
diff --git a/src/funopen.c b/src/funopen.c
|
||||
index 1e6f43a..3a3af6a 100644
|
||||
--- c/src/funopen.c
|
||||
+++ w/src/funopen.c
|
||||
--- a/src/funopen.c
|
||||
+++ b/src/funopen.c
|
||||
@@ -143,6 +143,7 @@ funopen(const void *cookie,
|
||||
* they will not add the needed support to implement it. Just ignore this
|
||||
* interface there, as it has never been provided anyway.
|
||||
@ -112,31 +143,32 @@ index 1e6f43a..3a3af6a 100644
|
||||
#else
|
||||
#error "Function funopen() needs to be ported or disabled."
|
||||
#endif
|
||||
diff --git c/src/local-link.h w/src/local-link.h
|
||||
index 0d4351a..fc520af 100644
|
||||
--- c/src/local-link.h
|
||||
+++ w/src/local-link.h
|
||||
@@ -27,6 +27,11 @@
|
||||
#ifndef LIBBSD_LOCAL_LINK_H
|
||||
#define LIBBSD_LOCAL_LINK_H
|
||||
diff --git a/src/local-link.h b/src/local-link.h
|
||||
index 6782d9a..fb76098 100644
|
||||
--- a/src/local-link.h
|
||||
+++ b/src/local-link.h
|
||||
@@ -29,6 +29,12 @@
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
|
||||
+#ifdef __MACH__
|
||||
+#define libbsd_link_warning(symbol, msg)
|
||||
+#define libbsd_symver_default(alias, symbol, version)
|
||||
+#define libbsd_symver_variant(alias, symbol, version)
|
||||
+#define libbsd_symver_weak(alias, symbol, version)
|
||||
+#else
|
||||
#define libbsd_link_warning(symbol, msg) \
|
||||
static const char libbsd_emit_link_warning_##symbol[] \
|
||||
__attribute__((__used__,__section__(".gnu.warning." #symbol))) = msg;
|
||||
@@ -45,3 +50,4 @@
|
||||
__attribute__((__used__,__section__(".gnu.warning." #symbol))) = msg
|
||||
@@ -68,3 +74,4 @@
|
||||
#endif
|
||||
|
||||
#endif
|
||||
+#endif
|
||||
diff --git c/src/nlist.c w/src/nlist.c
|
||||
index d22fa19..f41333f 100644
|
||||
--- c/src/nlist.c
|
||||
+++ w/src/nlist.c
|
||||
diff --git a/src/nlist.c b/src/nlist.c
|
||||
index 1cb9d18..b476f1e 100644
|
||||
--- a/src/nlist.c
|
||||
+++ b/src/nlist.c
|
||||
@@ -41,6 +41,7 @@
|
||||
#include <unistd.h>
|
||||
#include <nlist.h>
|
||||
@ -144,16 +176,46 @@ index d22fa19..f41333f 100644
|
||||
+#if !HAVE_NLIST_H
|
||||
#include "local-elf.h"
|
||||
|
||||
#ifndef SIZE_T_MAX
|
||||
@@ -282,3 +283,4 @@ nlist(const char *name, struct nlist *list)
|
||||
/* Note: This function is used by libkvm0, so we need to export it.
|
||||
@@ -277,3 +278,4 @@ nlist(const char *name, struct nlist *list)
|
||||
(void)close(fd);
|
||||
return (n);
|
||||
}
|
||||
+#endif
|
||||
diff --git c/src/readpassphrase.c w/src/readpassphrase.c
|
||||
diff --git a/src/pwcache.c b/src/pwcache.c
|
||||
index d54daa0..74fde9f 100644
|
||||
--- a/src/pwcache.c
|
||||
+++ b/src/pwcache.c
|
||||
@@ -191,6 +191,7 @@ grptb_start(void)
|
||||
return 0;
|
||||
}
|
||||
|
||||
+#if !HAVE_USER_FROM_UID
|
||||
/*
|
||||
* user_from_uid()
|
||||
* caches the name (if any) for the uid. If noname clear, we always
|
||||
@@ -251,7 +252,9 @@ user_from_uid(uid_t uid, int noname)
|
||||
}
|
||||
return ptr->name;
|
||||
}
|
||||
+#endif
|
||||
|
||||
+#if !HAVE_USER_FROM_UID
|
||||
/*
|
||||
* group_from_gid()
|
||||
* caches the name (if any) for the gid. If noname clear, we always
|
||||
@@ -312,6 +315,7 @@ group_from_gid(gid_t gid, int noname)
|
||||
}
|
||||
return ptr->name;
|
||||
}
|
||||
+#endif
|
||||
|
||||
/*
|
||||
* uid_from_user()
|
||||
diff --git a/src/readpassphrase.c b/src/readpassphrase.c
|
||||
index f9f6195..2bc5fb4 100644
|
||||
--- c/src/readpassphrase.c
|
||||
+++ w/src/readpassphrase.c
|
||||
--- a/src/readpassphrase.c
|
||||
+++ b/src/readpassphrase.c
|
||||
@@ -36,6 +36,14 @@
|
||||
#define TCSASOFT 0
|
||||
#endif
|
||||
@ -169,10 +231,10 @@ index f9f6195..2bc5fb4 100644
|
||||
static volatile sig_atomic_t signo[_NSIG];
|
||||
|
||||
static void handler(int);
|
||||
diff --git c/src/setproctitle.c w/src/setproctitle.c
|
||||
index ff32aa3..51ed833 100644
|
||||
--- c/src/setproctitle.c
|
||||
+++ w/src/setproctitle.c
|
||||
diff --git a/src/setproctitle.c b/src/setproctitle.c
|
||||
index d3e1087..0e5f64c 100644
|
||||
--- a/src/setproctitle.c
|
||||
+++ b/src/setproctitle.c
|
||||
@@ -33,6 +33,10 @@
|
||||
#include <string.h>
|
||||
#include "local-link.h"
|
||||
@ -184,7 +246,7 @@ index ff32aa3..51ed833 100644
|
||||
static struct {
|
||||
/* Original value. */
|
||||
const char *arg0;
|
||||
@@ -287,7 +291,8 @@ libbsd_symver_default(setproctitle, setproctitle_impl, LIBBSD_0.5);
|
||||
@@ -291,7 +295,8 @@ libbsd_symver_default(setproctitle, setproctitle_impl, LIBBSD_0.5);
|
||||
* in 0.5, make the implementation available in the old version as an alias
|
||||
* for code linking against that version, and change the default to use the
|
||||
* new version, so that new code depends on the implemented version. */
|
||||
@ -194,10 +256,10 @@ index ff32aa3..51ed833 100644
|
||||
extern __typeof__(setproctitle_impl)
|
||||
setproctitle_stub
|
||||
__attribute__((__alias__("setproctitle_impl")));
|
||||
diff --git c/src/strlcat.c w/src/strlcat.c
|
||||
diff --git a/src/strlcat.c b/src/strlcat.c
|
||||
index 14c53a1..5961c17 100644
|
||||
--- c/src/strlcat.c
|
||||
+++ w/src/strlcat.c
|
||||
--- a/src/strlcat.c
|
||||
+++ b/src/strlcat.c
|
||||
@@ -26,6 +26,7 @@
|
||||
* Returns strlen(src) + MIN(dsize, strlen(initial dst)).
|
||||
* If retval >= dsize, truncation occurred.
|
||||
@ -211,10 +273,10 @@ index 14c53a1..5961c17 100644
|
||||
return(dlen + (src - osrc)); /* count does not include NUL */
|
||||
}
|
||||
+#endif
|
||||
diff --git c/src/strlcpy.c w/src/strlcpy.c
|
||||
diff --git a/src/strlcpy.c b/src/strlcpy.c
|
||||
index e9a7fe4..5137acb 100644
|
||||
--- c/src/strlcpy.c
|
||||
+++ w/src/strlcpy.c
|
||||
--- a/src/strlcpy.c
|
||||
+++ b/src/strlcpy.c
|
||||
@@ -24,6 +24,7 @@
|
||||
* chars will be copied. Always NUL terminates (unless dsize == 0).
|
||||
* Returns strlen(src); if retval >= dsize, truncation occurred.
|
||||
@ -228,10 +290,10 @@ index e9a7fe4..5137acb 100644
|
||||
return(src - osrc - 1); /* count does not include NUL */
|
||||
}
|
||||
+#endif
|
||||
diff --git c/src/strmode.c w/src/strmode.c
|
||||
diff --git a/src/strmode.c b/src/strmode.c
|
||||
index e6afde5..da680c9 100644
|
||||
--- c/src/strmode.c
|
||||
+++ w/src/strmode.c
|
||||
--- a/src/strmode.c
|
||||
+++ b/src/strmode.c
|
||||
@@ -32,6 +32,7 @@
|
||||
#include <sys/stat.h>
|
||||
#include <string.h>
|
||||
|
@ -1,6 +1,6 @@
|
||||
{ lib, stdenv, fetchFromGitHub }:
|
||||
{ lib, stdenv, fetchFromGitHub, copyPkgconfigItems, makePkgconfigItem }:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "stb";
|
||||
version = "unstable-2021-09-10";
|
||||
|
||||
@ -11,11 +11,28 @@ stdenv.mkDerivation {
|
||||
sha256 = "0qq35cd747lll4s7bmnxb3pqvyp2hgcr9kyf758fax9lx76iwjhr";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ copyPkgconfigItems ];
|
||||
|
||||
pkgconfigItems = [
|
||||
(makePkgconfigItem rec {
|
||||
name = "stb";
|
||||
version = "1";
|
||||
cflags = [ "-I${variables.includedir}/stb" ];
|
||||
variables = rec {
|
||||
prefix = "${placeholder "out"}";
|
||||
includedir = "${prefix}/include";
|
||||
};
|
||||
inherit (meta) description;
|
||||
})
|
||||
];
|
||||
|
||||
dontBuild = true;
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
mkdir -p $out/include/stb
|
||||
cp *.h $out/include/stb/
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
|
@ -30,7 +30,7 @@ buildPythonPackage rec {
|
||||
description = ''
|
||||
Eval nix code from python.
|
||||
'';
|
||||
maintainers = [ maintainers.mic92 ];
|
||||
maintainers = [ ];
|
||||
license = licenses.mit;
|
||||
};
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "metals";
|
||||
version = "0.11.6";
|
||||
version = "0.11.7";
|
||||
|
||||
deps = stdenv.mkDerivation {
|
||||
name = "${pname}-deps-${version}";
|
||||
@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
|
||||
'';
|
||||
outputHashMode = "recursive";
|
||||
outputHashAlgo = "sha256";
|
||||
outputHash = "sha256-/tFc7xAuUtx2JgEMLhGaq2FXpt7KQNMi82ODr/gTfhM=";
|
||||
outputHash = "sha256-Zc/0kod3JM58WpyxwXiyQdixBHOJV7UDGg1YZtHJ3hw=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ makeWrapper setJavaClassPath ];
|
||||
@ -29,23 +29,8 @@ stdenv.mkDerivation rec {
|
||||
installPhase = ''
|
||||
mkdir -p $out/bin
|
||||
|
||||
# This variant is not targeted at any particular client, clients are
|
||||
# expected to declare their supported features in initialization options.
|
||||
makeWrapper ${jre}/bin/java $out/bin/metals \
|
||||
--add-flags "${extraJavaOpts} -cp $CLASSPATH scala.meta.metals.Main"
|
||||
|
||||
# Further variants targeted at clients with featuresets pre-set.
|
||||
makeWrapper ${jre}/bin/java $out/bin/metals-emacs \
|
||||
--add-flags "${extraJavaOpts} -Dmetals.client=emacs -cp $CLASSPATH scala.meta.metals.Main"
|
||||
|
||||
makeWrapper ${jre}/bin/java $out/bin/metals-vim \
|
||||
--add-flags "${extraJavaOpts} -Dmetals.client=coc.nvim -cp $CLASSPATH scala.meta.metals.Main"
|
||||
|
||||
makeWrapper ${jre}/bin/java $out/bin/metals-vim-lsc \
|
||||
--add-flags "${extraJavaOpts} -Dmetals.client=vim-lsc -cp $CLASSPATH scala.meta.metals.Main"
|
||||
|
||||
makeWrapper ${jre}/bin/java $out/bin/metals-sublime \
|
||||
--add-flags "${extraJavaOpts} -Dmetals.client=sublime -cp $CLASSPATH scala.meta.metals.Main"
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "lemmy-ui",
|
||||
"description": "An isomorphic UI for lemmy",
|
||||
"version": "0.16.4",
|
||||
"version": "0.16.6",
|
||||
"author": "Dessalines <tyhou13@gmx.com>",
|
||||
"license": "AGPL-3.0",
|
||||
"scripts": {
|
||||
@ -34,7 +34,7 @@
|
||||
"inferno-server": "^7.4.11",
|
||||
"isomorphic-cookie": "^1.2.4",
|
||||
"jwt-decode": "^3.1.2",
|
||||
"markdown-it": "^13.0.0",
|
||||
"markdown-it": "^13.0.1",
|
||||
"markdown-it-container": "^3.0.0",
|
||||
"markdown-it-footnote": "^3.0.3",
|
||||
"markdown-it-html5-embed": "^1.0.0",
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"version": "0.16.4",
|
||||
"serverSha256": "sha256-xbxavlmRm7QTbrAjw6IMgQq8rEgyEHdcj11EhsOY+j0=",
|
||||
"serverCargoSha256": "sha256-vDIaLpw0C6fnv0quH20qRN0I38Br338+MS9YzVfNizU=",
|
||||
"uiSha256": "sha256-GZH/fSYLbxwigrr5LwAzxH4ElDVjTs8Tqqq+xYDFNCU",
|
||||
"uiYarnDepsSha256": "sha256-BQs9UXUT/CcxJ7CdLksYGvGPGAaW7FLUAShLsbPC0jw="
|
||||
"version": "0.16.6",
|
||||
"serverSha256": "sha256-nDmwn3moDFJtYNx/FY3uSpxCwE4Ni4udqF3MX3MNyYM=",
|
||||
"serverCargoSha256": "sha256-f86UE7aVciHaTsK/jzABHEXBh2Pn6ErRBb52lW/f+1E=",
|
||||
"uiSha256": "sha256-ZfD9QaycvjlFlbZNcMEf2bcrszYn8TWuPDYEhW+gITE=",
|
||||
"uiYarnDepsSha256": "sha256-2NiDuqAyZeNn3c3XDeP2m5hHej4w4/gcabxfHgC8PV4="
|
||||
}
|
||||
|
@ -47,7 +47,7 @@ rustPlatform.buildRustPackage rec {
|
||||
description = "🐀 Building a federated alternative to reddit in rust";
|
||||
homepage = "https://join-lemmy.org/";
|
||||
license = licenses.agpl3Only;
|
||||
maintainers = with maintainers; [ happysalada ];
|
||||
maintainers = with maintainers; [ happysalada billewanick ];
|
||||
mainProgram = "lemmy_server";
|
||||
};
|
||||
}
|
||||
|
@ -828,6 +828,10 @@ with pkgs;
|
||||
|
||||
makeDesktopItem = callPackage ../build-support/make-desktopitem { };
|
||||
|
||||
copyPkgconfigItems = makeSetupHook { } ../build-support/setup-hooks/copy-pkgconfig-items.sh;
|
||||
|
||||
makePkgconfigItem = callPackage ../build-support/make-pkgconfigitem { };
|
||||
|
||||
makeDarwinBundle = callPackage ../build-support/make-darwin-bundle { };
|
||||
|
||||
makeAutostartItem = callPackage ../build-support/make-startupitem { };
|
||||
|
Loading…
Reference in New Issue
Block a user