commit
77ee91f1d3
@ -0,0 +1,104 @@ |
||||
{ lib |
||||
, stdenv |
||||
, fetchFromGitHub |
||||
, autoreconfHook |
||||
, bash |
||||
, docbook_xml_dtd_42 |
||||
, docbook-xsl-nons |
||||
, glib |
||||
, gobject-introspection |
||||
, gtk3 |
||||
, intltool |
||||
, libnotify |
||||
, libxml2 |
||||
, libxslt |
||||
, networkmanagerapplet |
||||
, pkg-config |
||||
, python3 |
||||
, wrapGAppsNoGuiHook |
||||
, withGui ? false |
||||
}: |
||||
|
||||
let |
||||
pythonPath = python3.withPackages (ps: with ps; [ |
||||
dbus-python |
||||
nftables |
||||
pygobject3 |
||||
] ++ lib.optionals withGui [ |
||||
pyqt5 |
||||
pyqt5_sip |
||||
]); |
||||
in |
||||
stdenv.mkDerivation rec { |
||||
pname = "firewalld"; |
||||
version = "1.1.1"; |
||||
|
||||
src = fetchFromGitHub { |
||||
owner = "firewalld"; |
||||
repo = "firewalld"; |
||||
rev = "v${version}"; |
||||
sha256 = "sha256-w8TbovIhOhJAUZWbKdBd/+db8Hro/ttlxWZDcrCXX4Q="; |
||||
}; |
||||
|
||||
patches = [ |
||||
./respect-xml-catalog-files-var.patch |
||||
]; |
||||
|
||||
postPatch = '' |
||||
substituteInPlace src/firewall/config/__init__.py.in \ |
||||
--replace "/usr/share" "$out/share" |
||||
|
||||
for file in config/firewall-{applet,config}.desktop.in; do |
||||
substituteInPlace $file \ |
||||
--replace "/usr/bin/" "$out/bin/" |
||||
done |
||||
'' + lib.optionalString withGui '' |
||||
substituteInPlace src/firewall-applet.in \ |
||||
--replace "/usr/bin/nm-connection-editor" "${networkmanagerapplet}/bin/nm-conenction-editor" |
||||
''; |
||||
|
||||
nativeBuildInputs = [ |
||||
autoreconfHook |
||||
docbook_xml_dtd_42 |
||||
docbook-xsl-nons |
||||
glib |
||||
intltool |
||||
libxml2 |
||||
libxslt |
||||
pkg-config |
||||
python3 |
||||
python3.pkgs.wrapPython |
||||
] ++ lib.optionals withGui [ |
||||
gobject-introspection |
||||
wrapGAppsNoGuiHook |
||||
]; |
||||
|
||||
buildInputs = [ |
||||
bash |
||||
glib |
||||
] ++ lib.optionals withGui [ |
||||
gtk3 |
||||
libnotify |
||||
pythonPath |
||||
]; |
||||
|
||||
dontWrapGApps = true; |
||||
|
||||
preFixup = lib.optionalString withGui '' |
||||
makeWrapperArgs+=("''${gappsWrapperArgs[@]}") |
||||
''; |
||||
|
||||
postFixup = '' |
||||
chmod +x $out/share/firewalld/*.py $out/share/firewalld/testsuite/python/*.py $out/share/firewalld/testsuite/{,integration/}testsuite |
||||
patchShebangs --host $out/share/firewalld/testsuite/{,integration/}testsuite $out/share/firewalld/*.py |
||||
wrapPythonProgramsIn "$out/bin" "$out ${pythonPath}" |
||||
wrapPythonProgramsIn "$out/share/firewalld/testsuite/python" "$out ${pythonPath}" |
||||
''; |
||||
|
||||
meta = with lib; { |
||||
description = "Firewall daemon with D-Bus interface"; |
||||
homepage = "https://github.com/firewalld/firewalld"; |
||||
license = licenses.gpl2Plus; |
||||
maintainers = with maintainers; [ SuperSandro2000 ]; |
||||
}; |
||||
} |
@ -0,0 +1,13 @@ |
||||
--- a/m4/jh_path_xml_catalog.m4
|
||||
+++ b/m4/jh_path_xml_catalog.m4
|
||||
@@ -40,8 +40,8 @@ AC_DEFUN([JH_CHECK_XML_CATALOG],
|
||||
[
|
||||
AC_REQUIRE([JH_PATH_XML_CATALOG],[JH_PATH_XML_CATALOG(,[:])])dnl
|
||||
AC_MSG_CHECKING([for ifelse([$2],,[$1],[$2]) in XML catalog])
|
||||
- if $jh_found_xmlcatalog && \
|
||||
- AC_RUN_LOG([$XMLCATALOG --noout "$XML_CATALOG_FILE" "$1" >&2]); then
|
||||
+ # empty argument forces libxml to use XML_CATALOG_FILES variable
|
||||
+ if AC_RUN_LOG([$XMLCATALOG --noout "" "$1" >&2]); then
|
||||
AC_MSG_RESULT([found])
|
||||
ifelse([$3],,,[$3
|
||||
])dnl
|
@ -1,94 +0,0 @@ |
||||
{ lib, stdenv, fetchFromGitHub, fetchurl, python2, makeWrapper, pkg-config, gcc, |
||||
pypy, libffi, libedit, libuv, boost, zlib, |
||||
variant ? "jit", buildWithPypy ? false }: |
||||
|
||||
let |
||||
commit-count = "1364"; |
||||
common-flags = "--thread --gcrootfinder=shadowstack --continuation"; |
||||
variants = { |
||||
jit = { flags = "--opt=jit"; target = "target.py"; }; |
||||
jit-preload = { flags = "--opt=jit"; target = "target_preload.py"; }; |
||||
no-jit = { flags = ""; target = "target.py"; }; |
||||
no-jit-preload = { flags = ""; target = "target_preload.py"; }; |
||||
}; |
||||
pixie-src = fetchFromGitHub { |
||||
owner = "pixie-lang"; |
||||
repo = "pixie"; |
||||
rev = "5eb0ccbe8b0087d3a5f2d0bbbc6998d624d3cd62"; |
||||
sha256 = "sha256-dQ8ncH0IqU42WYxwBgjH6QQfvMIo7RZpv81UAUsPw10="; |
||||
}; |
||||
pypy-tag = "91db1a9"; |
||||
pypy-src = fetchurl { |
||||
name = "pypy-src-${pypy-tag}"; |
||||
url = "https://bitbucket.org/pypy/pypy/get/${pypy-tag}.tar.bz2"; |
||||
sha256 = "0ylbqvhbcp5m09l15i2q2h3a0vjd055x2r37cq71lkhgmmaxrwbq"; |
||||
}; |
||||
libs = [ libffi libedit libuv boost.dev boost.out zlib ]; |
||||
include-path = lib.concatStringsSep ":" |
||||
(map (p: "${p}/include") libs); |
||||
library-path = lib.concatStringsSep ":" |
||||
(map (p: "${p}/lib") libs); |
||||
bin-path = lib.concatStringsSep ":" |
||||
(map (p: "${p}/bin") [ gcc ]); |
||||
build = {flags, target}: stdenv.mkDerivation rec { |
||||
pname = "pixie"; |
||||
version = "0-r${commit-count}-${variant}"; |
||||
nativeBuildInputs = [ makeWrapper pkg-config ]; |
||||
buildInputs = libs; |
||||
PYTHON = if buildWithPypy |
||||
then "${pypy}/pypy-c/pypy-c" |
||||
else python2.interpreter; |
||||
unpackPhase = '' |
||||
cp -R ${pixie-src} pixie-src |
||||
mkdir pypy-src |
||||
(cd pypy-src |
||||
tar --strip-components=1 -xjf ${pypy-src}) |
||||
chmod -R +w pypy-src pixie-src |
||||
''; |
||||
patchPhase = '' |
||||
(cd pixie-src |
||||
patch -p1 < ${./load_paths.patch} |
||||
libraryPaths='["${libuv}" "${libedit}" "${libffi.dev}" "${boost.dev}" "${boost.out}" "${zlib.dev}"]' |
||||
export libraryPaths |
||||
substituteAllInPlace ./pixie/ffi-infer.pxi) |
||||
''; |
||||
buildPhase = ''( |
||||
PYTHONPATH="`pwd`/pypy-src:$PYTHONPATH"; |
||||
RPYTHON="`pwd`/pypy-src/rpython/bin/rpython"; |
||||
cd pixie-src |
||||
$PYTHON $RPYTHON ${common-flags} ${target} |
||||
find pixie -name "*.pxi" -exec ./pixie-vm -c {} \; |
||||
)''; |
||||
LD_LIBRARY_PATH = library-path; |
||||
C_INCLUDE_PATH = include-path; |
||||
LIBRARY_PATH = library-path; |
||||
PATH = bin-path; |
||||
installPhase = '' |
||||
mkdir -p $out/share $out/bin |
||||
cp pixie-src/pixie-vm $out/share/pixie-vm |
||||
cp -R pixie-src/pixie $out/share/pixie |
||||
makeWrapper $out/share/pixie-vm $out/bin/pixie \ |
||||
--prefix LD_LIBRARY_PATH : ${LD_LIBRARY_PATH} \ |
||||
--prefix C_INCLUDE_PATH : ${C_INCLUDE_PATH} \ |
||||
--prefix LIBRARY_PATH : ${LIBRARY_PATH} \ |
||||
--prefix PATH : ${PATH} |
||||
''; |
||||
doCheck = true; |
||||
checkPhase = '' |
||||
RES=$(./pixie-src/pixie-vm -e "(print :ok)") |
||||
if [ "$RES" != ":ok" ]; then |
||||
echo "ERROR Unexpected output: '$RES'" |
||||
return 1 |
||||
else |
||||
echo "$RES" |
||||
fi |
||||
''; |
||||
meta = { |
||||
description = "A clojure-like lisp, built with the pypy vm toolkit"; |
||||
homepage = "https://github.com/pixie-lang/pixie"; |
||||
license = lib.licenses.lgpl3; |
||||
platforms = ["x86_64-linux" "i686-linux" "x86_64-darwin"]; |
||||
maintainers = with lib.maintainers; [ bendlas ]; |
||||
}; |
||||
}; |
||||
in build (builtins.getAttr variant variants) |
@ -1,46 +0,0 @@ |
||||
{ lib, stdenv, fetchFromGitHub |
||||
, pixie, rlwrap |
||||
}: |
||||
|
||||
stdenv.mkDerivation rec { |
||||
pname = "dust"; |
||||
version = "0-91"; |
||||
|
||||
src = fetchFromGitHub { |
||||
owner = "pixie-lang"; |
||||
repo = "dust"; |
||||
rev = "efe469661e749a71e86858fd006f61464810575a"; |
||||
sha256 = "09n57b6haxwask9m8vimv42ikczf7lgfc7m9izjrcqgs0padvfzc"; |
||||
}; |
||||
|
||||
buildInputs = [ pixie ]; |
||||
|
||||
patches = [ ./make-paths-configurable.patch ]; |
||||
|
||||
configurePhase = '' |
||||
pixiePath="${pixie}/bin/pixie" \ |
||||
basePath="$out/share/dust" \ |
||||
rlwrapPath="${rlwrap}/bin/rlwrap" \ |
||||
substituteAll dust.in dust |
||||
chmod +x dust |
||||
''; |
||||
|
||||
# FIXME: AOT for dust |
||||
# buildPhase = '' |
||||
# find . -name "*.pxi" -exec pixie-vm -c {} \; |
||||
# ''; |
||||
|
||||
installPhase = '' |
||||
mkdir -p $out/bin $out/share/dust |
||||
cp -a src/ run.pxi $out/share/dust |
||||
mv dust $out/bin/dust |
||||
''; |
||||
|
||||
meta = with lib; { |
||||
description = "Provides tooling around pixie, e.g. a nicer repl, running tests and fetching dependencies"; |
||||
homepage = src.meta.homepage; |
||||
maintainers = with maintainers; [ ]; |
||||
license = licenses.lgpl3; |
||||
platforms = platforms.unix; |
||||
}; |
||||
} |
@ -1,25 +0,0 @@ |
||||
diff --git a/pixie/ffi-infer.pxi b/pixie/ffi-infer.pxi
|
||||
index 9f13ac7..74301c2 100644
|
||||
--- a/pixie/ffi-infer.pxi
|
||||
+++ b/pixie/ffi-infer.pxi
|
||||
@@ -1,15 +1,12 @@
|
||||
(ns pixie.ffi-infer
|
||||
(:require [pixie.io-blocking :as io]))
|
||||
|
||||
+(defn -add-library-path [p]
|
||||
+ (swap! load-paths conj (str p "/include"))
|
||||
+ (swap! load-paths conj (str p "/lib")))
|
||||
|
||||
-(defn -add-rel-path [rel]
|
||||
- (swap! load-paths conj (str (first @load-paths) "/" rel)))
|
||||
-
|
||||
-(-add-rel-path "lib")
|
||||
-(-add-rel-path "include")
|
||||
-(-add-rel-path "../lib")
|
||||
-(-add-rel-path "../include")
|
||||
-
|
||||
+(doseq [lp @libraryPaths@]
|
||||
+ (-add-library-path lp))
|
||||
|
||||
(def *config* nil)
|
||||
(set-dynamic! (var *config*))
|
@ -1,119 +0,0 @@ |
||||
From 0cbb82e606610d36e52c70d888995fbbf9b0d7c8 Mon Sep 17 00:00:00 2001
|
||||
From: Herwig Hochleitner <herwig@bendlas.net>
|
||||
Date: Sun, 28 Feb 2016 16:34:14 +0100
|
||||
Subject: [PATCH] make paths configurable
|
||||
|
||||
---
|
||||
dust | 52 ----------------------------------------------------
|
||||
dust.in | 43 +++++++++++++++++++++++++++++++++++++++++++
|
||||
2 files changed, 43 insertions(+), 52 deletions(-)
|
||||
delete mode 100755 dust
|
||||
create mode 100755 dust.in
|
||||
|
||||
diff --git a/dust b/dust
|
||||
deleted file mode 100755
|
||||
index ffced9b..0000000
|
||||
--- a/dust
|
||||
+++ /dev/null
|
||||
@@ -1,52 +0,0 @@
|
||||
-#!/usr/bin/env bash
|
||||
-
|
||||
-base_path=$0
|
||||
-if [ -L "$base_path" ]; then
|
||||
- base_path=`readlink $base_path`
|
||||
-fi
|
||||
-base_path=`dirname $base_path`
|
||||
-
|
||||
-pixie_path=`which pixie-vm`
|
||||
-if [ -z "$pixie_path" ]; then
|
||||
- echo "Error: 'pixie-vm' must be on your PATH"
|
||||
- exit 1
|
||||
-fi
|
||||
-
|
||||
-function set_load_path() {
|
||||
- load_path=""
|
||||
- if ([ -f "project.edn" ] || [ -f "project.pxi" ]) && [ -f ".load-path" ]; then
|
||||
- load_path="`cat .load-path`"
|
||||
- fi
|
||||
-}
|
||||
-
|
||||
-if [ ! -f "project.edn" ] && [ -f "project.pxi" ]; then
|
||||
- echo "Warning: 'project.pxi' is deprecated, please use 'project.edn'."
|
||||
- echo "To start you can run the following command:"
|
||||
- echo " pixie-vm -l $base_path/src -e '(require dust.project :as p) (p/load-project!) (prn (dissoc @p/*project* :path))'"
|
||||
- echo
|
||||
-fi
|
||||
-
|
||||
-set_load_path
|
||||
-run_dust="$pixie_path -l $base_path/src $load_path $base_path/run.pxi"
|
||||
-
|
||||
-case $1 in
|
||||
- ""|"repl")
|
||||
- rlwrap_cmd=""
|
||||
- if [ -n "`which rlwrap`" ]; then
|
||||
- rlwrap_cmd="rlwrap -aignored -n"
|
||||
- fi
|
||||
- $rlwrap_cmd $pixie_path $load_path
|
||||
- ;;
|
||||
- "run")
|
||||
- shift
|
||||
- file=$1
|
||||
- shift
|
||||
- $pixie_path $load_path $file $@
|
||||
- ;;
|
||||
- -h|--help)
|
||||
- $run_dust help
|
||||
- ;;
|
||||
- *)
|
||||
- $run_dust $@
|
||||
- ;;
|
||||
-esac
|
||||
diff --git a/dust.in b/dust.in
|
||||
new file mode 100755
|
||||
index 0000000..44a7fbd
|
||||
--- /dev/null
|
||||
+++ b/dust.in
|
||||
@@ -0,0 +1,40 @@
|
||||
+#!/usr/bin/env bash
|
||||
+
|
||||
+base_path=@basePath@
|
||||
+pixie_path=@pixiePath@
|
||||
+rlwrap_cmd=@rlwrapPath@
|
||||
+
|
||||
+function set_load_path() {
|
||||
+ load_path=""
|
||||
+ if ([ -f "project.edn" ] || [ -f "project.pxi" ]) && [ -f ".load-path" ]; then
|
||||
+ load_path="`cat .load-path`"
|
||||
+ fi
|
||||
+}
|
||||
+
|
||||
+if [ ! -f "project.edn" ] && [ -f "project.pxi" ]; then
|
||||
+ echo "Warning: 'project.pxi' is deprecated, please use 'project.edn'."
|
||||
+ echo "To start you can run the following command:"
|
||||
+ echo " pixie-vm -l $base_path/src -e '(require dust.project :as p) (p/load-project!) (prn (dissoc @p/*project* :path))'"
|
||||
+ echo
|
||||
+fi
|
||||
+
|
||||
+set_load_path
|
||||
+run_dust="$pixie_path -l $base_path/src $load_path $base_path/run.pxi"
|
||||
+
|
||||
+case $1 in
|
||||
+ ""|"repl")
|
||||
+ $rlwrap_cmd -aignored -n $pixie_path $load_path
|
||||
+ ;;
|
||||
+ "run")
|
||||
+ shift
|
||||
+ file=$1
|
||||
+ shift
|
||||
+ $pixie_path $load_path $file $@
|
||||
+ ;;
|
||||
+ -h|--help)
|
||||
+ $run_dust help
|
||||
+ ;;
|
||||
+ *)
|
||||
+ $run_dust $@
|
||||
+ ;;
|
||||
+esac
|
||||
--
|
||||
2.7.1
|
||||
|
@ -0,0 +1,26 @@ |
||||
{ lib, buildPythonPackage, fetchPypi, python, cython }: |
||||
|
||||
buildPythonPackage rec { |
||||
pname = "fastbencode"; |
||||
version = "0.0.7"; |
||||
|
||||
src = fetchPypi { |
||||
inherit pname version; |
||||
sha256 = "sha256-tryavlQtBmN5NSlXb0m6iJFQhVT4XQm11tXtevfgxuQ="; |
||||
}; |
||||
|
||||
nativeBuildInputs = [ cython ]; |
||||
|
||||
pythonImportsCheck = [ "fastbencode" ]; |
||||
|
||||
checkPhase = '' |
||||
${python.interpreter} -m unittest fastbencode.tests.test_suite |
||||
''; |
||||
|
||||
meta = with lib; { |
||||
description = "Fast implementation of bencode"; |
||||
homepage = "https://github.com/breezy-team/fastbencode"; |
||||
license = licenses.gpl2Only; |
||||
maintainers = [ maintainers.marsam ]; |
||||
}; |
||||
} |
@ -0,0 +1,28 @@ |
||||
{ lib, buildGoModule, fetchFromGitHub }: |
||||
|
||||
buildGoModule rec { |
||||
pname = "protoc-gen-entgrpc"; |
||||
version = "0.2.0"; |
||||
|
||||
src = fetchFromGitHub { |
||||
owner = "ent"; |
||||
repo = "contrib"; |
||||
rev = "v${version}"; |
||||
sha256 = "sha256-cpk8yRDBsupI277NWYFaLCvi3ltQDLgCrcpJ/FUVi9o="; |
||||
}; |
||||
|
||||
vendorSha256 = "sha256-RwwGFBiasxMmtKMLSyAqvkozqoyzzYuslMq+HnzZUhw="; |
||||
|
||||
subPackages = [ "entproto/cmd/protoc-gen-entgrpc" ]; |
||||
|
||||
ldflags = [ "-s" "-w" ]; |
||||
|
||||
meta = with lib; { |
||||
description = "Generator of an implementation of the service interface for ent protobuff"; |
||||
downloadPage = "https://github.com/ent/contrib/"; |
||||
license = licenses.asl20; |
||||
homepage = "https://entgo.io/"; |
||||
maintainers = with maintainers; [ superherointj ]; |
||||
}; |
||||
} |
||||
|
Loading…
Reference in new issue