mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-11-11 15:27:20 +03:00
Merge branch 'master' into staging
This commit is contained in:
commit
8fd5dd89ac
@ -1,5 +1,3 @@
|
||||
# configuration building is commented out until better tested.
|
||||
|
||||
{ config, lib, pkgs, ... }:
|
||||
|
||||
with lib;
|
||||
@ -7,29 +5,189 @@ with lib;
|
||||
let
|
||||
cfg = config.services.rippled;
|
||||
|
||||
rippledStateCfgFile = "/var/lib/rippled/rippled.cfg";
|
||||
b2i = val: if val then "1" else "0";
|
||||
|
||||
dbCfg = db: ''
|
||||
type=${db.type}
|
||||
path=${db.path}
|
||||
${optionalString (db.compression != null) ("compression=${b2i db.compression}") }
|
||||
${optionalString (db.onlineDelete != null) ("online_delete=${toString db.onlineDelete}")}
|
||||
${optionalString (db.advisoryDelete != null) ("advisory_delete=${toString db.advisoryDelete}")}
|
||||
${db.extraOpts}
|
||||
'';
|
||||
|
||||
rippledCfg = ''
|
||||
[server]
|
||||
${concatMapStringsSep "\n" (n: "port_${n}") (attrNames cfg.ports)}
|
||||
|
||||
${concatMapStrings (p: ''
|
||||
[port_${p.name}]
|
||||
ip=${p.ip}
|
||||
port=${toString p.port}
|
||||
protocol=${concatStringsSep "," p.protocol}
|
||||
${optionalString (p.user != "") "user=${p.user}"}
|
||||
${optionalString (p.password != "") "user=${p.password}"}
|
||||
admin=${if p.admin then "allow" else "no"}
|
||||
${optionalString (p.ssl.key != null) "ssl_key=${p.ssl.key}"}
|
||||
${optionalString (p.ssl.cert != null) "ssl_cert=${p.ssl.cert}"}
|
||||
${optionalString (p.ssl.chain != null) "ssl_chain=${p.ssl.chain}"}
|
||||
'') (attrValues cfg.ports)}
|
||||
|
||||
[database_path]
|
||||
${cfg.databasePath}
|
||||
|
||||
[node_db]
|
||||
type=HyperLevelDB
|
||||
path=/var/lib/rippled/db/hyperldb
|
||||
${dbCfg cfg.nodeDb}
|
||||
|
||||
[debug_logfile]
|
||||
/var/log/rippled/debug.log
|
||||
${optionalString (cfg.tempDb != null) ''
|
||||
[temp_db]
|
||||
${dbCfg cfg.tempDb}''}
|
||||
|
||||
''
|
||||
+ optionalString (cfg.peerIp != null) ''
|
||||
[peer_ip]
|
||||
${cfg.peerIp}
|
||||
${optionalString (cfg.importDb != null) ''
|
||||
[import_db]
|
||||
${dbCfg cfg.importDb}''}
|
||||
|
||||
[peer_port]
|
||||
${toString cfg.peerPort}
|
||||
[ips]
|
||||
${concatStringsSep "\n" cfg.ips}
|
||||
|
||||
''
|
||||
+ cfg.extraConfig;
|
||||
[ips_fixed]
|
||||
${concatStringsSep "\n" cfg.ipsFixed}
|
||||
|
||||
[validators]
|
||||
${concatStringsSep "\n" cfg.validators}
|
||||
|
||||
[node_size]
|
||||
${cfg.nodeSize}
|
||||
|
||||
[ledger_history]
|
||||
${toString cfg.ledgerHistory}
|
||||
|
||||
[fetch_depth]
|
||||
${toString cfg.fetchDepth}
|
||||
|
||||
[validation_quorum]
|
||||
${toString cfg.validationQuorum}
|
||||
|
||||
[sntp_servers]
|
||||
${concatStringsSep "\n" cfg.sntpServers}
|
||||
|
||||
[rpc_startup]
|
||||
{ "command": "log_level", "severity": "${cfg.logLevel}" }
|
||||
'' + cfg.extraConfig;
|
||||
|
||||
portOptions = { name, ...}: {
|
||||
options = {
|
||||
name = mkOption {
|
||||
internal = true;
|
||||
default = name;
|
||||
};
|
||||
|
||||
ip = mkOption {
|
||||
default = "127.0.0.1";
|
||||
description = "Ip where rippled listens.";
|
||||
type = types.str;
|
||||
};
|
||||
|
||||
port = mkOption {
|
||||
description = "Port where rippled listens.";
|
||||
type = types.int;
|
||||
};
|
||||
|
||||
protocol = mkOption {
|
||||
description = "Protocols expose by rippled.";
|
||||
type = types.listOf (types.enum ["http" "https" "ws" "wss" "peer"]);
|
||||
};
|
||||
|
||||
user = mkOption {
|
||||
description = "When set, these credentials will be required on HTTP/S requests.";
|
||||
type = types.str;
|
||||
default = "";
|
||||
};
|
||||
|
||||
password = mkOption {
|
||||
description = "When set, these credentials will be required on HTTP/S requests.";
|
||||
type = types.str;
|
||||
default = "";
|
||||
};
|
||||
|
||||
admin = mkOption {
|
||||
description = "Controls whether or not administrative commands are allowed.";
|
||||
type = types.bool;
|
||||
default = false;
|
||||
};
|
||||
|
||||
ssl = {
|
||||
key = mkOption {
|
||||
description = ''
|
||||
Specifies the filename holding the SSL key in PEM format.
|
||||
'';
|
||||
default = null;
|
||||
type = types.nullOr types.path;
|
||||
};
|
||||
|
||||
cert = mkOption {
|
||||
description = ''
|
||||
Specifies the path to the SSL certificate file in PEM format.
|
||||
This is not needed if the chain includes it.
|
||||
'';
|
||||
default = null;
|
||||
type = types.nullOr types.path;
|
||||
};
|
||||
|
||||
chain = mkOption {
|
||||
description = ''
|
||||
If you need a certificate chain, specify the path to the
|
||||
certificate chain here. The chain may include the end certificate.
|
||||
'';
|
||||
default = null;
|
||||
type = types.nullOr types.path;
|
||||
};
|
||||
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
dbOptions = {
|
||||
type = mkOption {
|
||||
description = "Rippled database type.";
|
||||
type = types.enum ["rocksdb" "nudb" "sqlite"];
|
||||
default = "rocksdb";
|
||||
};
|
||||
|
||||
path = mkOption {
|
||||
description = "Location to store the database.";
|
||||
type = types.path;
|
||||
default = cfg.databasePath;
|
||||
};
|
||||
|
||||
compression = mkOption {
|
||||
description = "Whether to enable snappy compression.";
|
||||
type = types.nullOr types.bool;
|
||||
default = null;
|
||||
};
|
||||
|
||||
onlineDelete = mkOption {
|
||||
description = "Enable automatic purging of older ledger information.";
|
||||
type = types.addCheck (types.nullOr types.int) (v: v > 256);
|
||||
default = cfg.ledgerHistory;
|
||||
};
|
||||
|
||||
advisoryDelete = mkOption {
|
||||
description = ''
|
||||
If set, then require administrative RPC call "can_delete"
|
||||
to enable online deletion of ledger records.
|
||||
'';
|
||||
type = types.nullOr types.bool;
|
||||
default = null;
|
||||
};
|
||||
|
||||
extraOpts = mkOption {
|
||||
description = "Extra database options.";
|
||||
type = types.lines;
|
||||
default = "";
|
||||
};
|
||||
};
|
||||
|
||||
rippledCfgFile = pkgs.writeText "rippled.cfg" rippledCfg;
|
||||
|
||||
in
|
||||
|
||||
{
|
||||
@ -37,236 +195,176 @@ in
|
||||
###### interface
|
||||
|
||||
options = {
|
||||
|
||||
services.rippled = {
|
||||
enable = mkEnableOption "Whether to enable rippled";
|
||||
|
||||
enable = mkOption {
|
||||
default = false;
|
||||
description = "Whether to enable rippled";
|
||||
package = mkOption {
|
||||
description = "Which rippled package to use.";
|
||||
type = types.package;
|
||||
default = pkgs.rippled;
|
||||
};
|
||||
|
||||
#
|
||||
# Rippled has a simple configuration file layout that is easy to
|
||||
# build with nix. Many of the options are defined here but are
|
||||
# commented out until the code to append them to the config above
|
||||
# is written and they are tested.
|
||||
#
|
||||
# If you find a yourself implementing more options, please submit a
|
||||
# pull request.
|
||||
#
|
||||
ports = mkOption {
|
||||
description = "Ports exposed by rippled";
|
||||
type = types.attrsOf types.optionSet;
|
||||
options = [portOptions];
|
||||
default = {
|
||||
rpc = {
|
||||
port = 5005;
|
||||
admin = true;
|
||||
protocol = ["http"];
|
||||
};
|
||||
|
||||
peer = {
|
||||
port = 51235;
|
||||
ip = "0.0.0.0";
|
||||
protocol = ["peer"];
|
||||
};
|
||||
|
||||
ws_public = {
|
||||
port = 5006;
|
||||
ip = "0.0.0.0";
|
||||
protocol = ["ws" "wss"];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
nodeDb = mkOption {
|
||||
description = "Rippled main database options.";
|
||||
type = types.nullOr types.optionSet;
|
||||
options = [dbOptions];
|
||||
default = {
|
||||
type = "rocksdb";
|
||||
extraOpts = ''
|
||||
open_files=2000
|
||||
filter_bits=12
|
||||
cache_mb=256
|
||||
file_size_pb=8
|
||||
file_size_mult=2;
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
tempDb = mkOption {
|
||||
description = "Rippled temporary database options.";
|
||||
type = types.nullOr types.optionSet;
|
||||
options = [dbOptions];
|
||||
default = null;
|
||||
};
|
||||
|
||||
importDb = mkOption {
|
||||
description = "Settings for performing a one-time import.";
|
||||
type = types.nullOr types.optionSet;
|
||||
options = [dbOptions];
|
||||
default = null;
|
||||
};
|
||||
|
||||
nodeSize = mkOption {
|
||||
description = ''
|
||||
Rippled size of the node you are running.
|
||||
"tiny", "small", "medium", "large", and "huge"
|
||||
'';
|
||||
type = types.enum ["tiny" "small" "medium" "large" "huge"];
|
||||
default = "small";
|
||||
};
|
||||
|
||||
/*
|
||||
ips = mkOption {
|
||||
default = [ "r.ripple.com 51235" ];
|
||||
example = [ "192.168.0.1" "192.168.0.1 3939" "r.ripple.com 51235" ];
|
||||
description = ''
|
||||
List of hostnames or ips where the Ripple protocol is served.
|
||||
For a starter list, you can either copy entries from:
|
||||
For a starter list, you can either copy entries from:
|
||||
https://ripple.com/ripple.txt or if you prefer you can let it
|
||||
default to r.ripple.com 51235
|
||||
|
||||
A port may optionally be specified after adding a space to the
|
||||
address. By convention, if known, IPs are listed in from most
|
||||
A port may optionally be specified after adding a space to the
|
||||
address. By convention, if known, IPs are listed in from most
|
||||
to least trusted.
|
||||
'';
|
||||
type = types.listOf types.str;
|
||||
default = ["r.ripple.com 51235"];
|
||||
};
|
||||
|
||||
ipsFixed = mkOption {
|
||||
default = null;
|
||||
example = [ "192.168.0.1" "192.168.0.1 3939" "r.ripple.com 51235" ];
|
||||
description = ''
|
||||
List of IP addresses or hostnames to which rippled should always
|
||||
attempt to maintain peer connections with. This is useful for
|
||||
manually forming private networks, for example to configure a
|
||||
validation server that connects to the Ripple network through a
|
||||
List of IP addresses or hostnames to which rippled should always
|
||||
attempt to maintain peer connections with. This is useful for
|
||||
manually forming private networks, for example to configure a
|
||||
validation server that connects to the Ripple network through a
|
||||
public-facing server, or for building a set of cluster peers.
|
||||
|
||||
A port may optionally be specified after adding a space to the address
|
||||
'';
|
||||
};
|
||||
*/
|
||||
|
||||
peerIp = mkOption {
|
||||
default = null;
|
||||
example = "0.0.0.0";
|
||||
description = ''
|
||||
IP address or domain to bind to allow external connections from peers.
|
||||
Defaults to not binding, which disallows external connections from peers.
|
||||
'';
|
||||
type = types.listOf types.str;
|
||||
default = [];
|
||||
};
|
||||
|
||||
peerPort = mkOption {
|
||||
default = 51235;
|
||||
validators = mkOption {
|
||||
description = ''
|
||||
If peerIp is supplied, corresponding port to bind to for peer connections.
|
||||
List of nodes to always accept as validators. Nodes are specified by domain
|
||||
or public key.
|
||||
'';
|
||||
type = types.listOf types.str;
|
||||
default = [
|
||||
"n949f75evCHwgyP4fPVgaHqNHxUVN15PsJEZ3B3HnXPcPjcZAoy7 RL1"
|
||||
"n9MD5h24qrQqiyBC8aeqqCWvpiBiYQ3jxSr91uiDvmrkyHRdYLUj RL2"
|
||||
"n9L81uNCaPgtUJfaHh89gmdvXKAmSt5Gdsw2g1iPWaPkAHW5Nm4C RL3"
|
||||
"n9KiYM9CgngLvtRCQHZwgC2gjpdaZcCcbt3VboxiNFcKuwFVujzS RL4"
|
||||
"n9LdgEtkmGB9E2h3K4Vp7iGUaKuq23Zr32ehxiU8FWY7xoxbWTSA RL5"
|
||||
];
|
||||
};
|
||||
|
||||
/*
|
||||
peerPortProxy = mkOption {
|
||||
type = types.int;
|
||||
example = 51236;
|
||||
databasePath = mkOption {
|
||||
description = ''
|
||||
An optional, additional listening port number for peers. Incoming
|
||||
connections on this port will be required to provide a PROXY Protocol
|
||||
handshake, described in this document (external link):
|
||||
|
||||
http://haproxy.1wt.eu/download/1.5/doc/proxy-protocol.txt
|
||||
|
||||
The PROXY Protocol is a popular method used by elastic load balancing
|
||||
service providers such as Amazon, to identify the true IP address and
|
||||
port number of external incoming connections.
|
||||
|
||||
In addition to enabling this setting, it will also be required to
|
||||
use your provider-specific control panel or administrative web page
|
||||
to configure your server instance to receive PROXY Protocol handshakes,
|
||||
and also to restrict access to your instance to the Elastic Load Balancer.
|
||||
Path to the ripple database.
|
||||
'';
|
||||
type = types.path;
|
||||
default = "/var/lib/rippled/db";
|
||||
};
|
||||
|
||||
peerPrivate = mkOption {
|
||||
default = null;
|
||||
example = 0;
|
||||
validationQuorum = mkOption {
|
||||
description = ''
|
||||
0: Request peers to broadcast your address. Normal outbound peer connections [default]
|
||||
1: Request peers not broadcast your address. Only connect to configured peers.
|
||||
'';
|
||||
};
|
||||
|
||||
peerSslCipherList = mkOption {
|
||||
default = null;
|
||||
example = "ALL:!LOW:!EXP:!MD5:@STRENGTH";
|
||||
description = ''
|
||||
A colon delimited string with the allowed SSL cipher modes for peer. The
|
||||
choices for for ciphers are defined by the OpenSSL API function
|
||||
SSL_CTX_set_cipher_list, documented here (external link):
|
||||
|
||||
http://pic.dhe.ibm.com/infocenter/tpfhelp/current/index.jsp?topic=%2Fcom.ibm.ztpf-ztpfdf.doc_put.cur%2Fgtpc2%2Fcpp_ssl_ctx_set_cipher_list.html
|
||||
|
||||
The default setting of "ALL:!LOW:!EXP:!MD5:@STRENGTH", which allows
|
||||
non-authenticated peer connections (they are, however, secure).
|
||||
'';
|
||||
};
|
||||
|
||||
nodeSeed = mkOption {
|
||||
default = null;
|
||||
example = "RASH BUSH MILK LOOK BAD BRIM AVID GAFF BAIT ROT POD LOVE";
|
||||
description = ''
|
||||
This is used for clustering. To force a particular node seed or key, the
|
||||
key can be set here. The format is the same as the validation_seed field.
|
||||
To obtain a validation seed, use the rippled validation_create command.
|
||||
'';
|
||||
};
|
||||
|
||||
clusterNodes = mkOption {
|
||||
default = null;
|
||||
example = [ "n9KorY8QtTdRx7TVDpwnG9NvyxsDwHUKUEeDLY3AkiGncVaSXZi5" ];
|
||||
description = ''
|
||||
To extend full trust to other nodes, place their node public keys here.
|
||||
Generally, you should only do this for nodes under common administration.
|
||||
Node public keys start with an 'n'. To give a node a name for identification
|
||||
place a space after the public key and then the name.
|
||||
'';
|
||||
};
|
||||
|
||||
sntpServers = mkOption {
|
||||
default = null;
|
||||
example = [ "time.nist.gov" "pool.ntp.org" ];
|
||||
description = ''
|
||||
IP address or domain of NTP servers to use for time synchronization.
|
||||
'';
|
||||
};
|
||||
|
||||
# TODO: websocket options
|
||||
|
||||
rpcAllowRemote = mkOption {
|
||||
default = false;
|
||||
description = ''
|
||||
false: Allow RPC connections only from 127.0.0.1. [default]
|
||||
true: Allow RPC connections from any IP.
|
||||
'';
|
||||
};
|
||||
|
||||
rpcAdminAllow = mkOption {
|
||||
example = [ "10.0.0.4" ];
|
||||
description = ''
|
||||
List of IP addresses allowed to have admin access.
|
||||
'';
|
||||
};
|
||||
|
||||
rpcAdminUser = mkOption {
|
||||
type = types.str;
|
||||
description = ''
|
||||
As a server, require this as the admin user to be specified. Also, require
|
||||
rpc_admin_user and rpc_admin_password to be checked for RPC admin functions.
|
||||
The request must specify these as the admin_user and admin_password in the
|
||||
request object.
|
||||
'';
|
||||
};
|
||||
|
||||
rpcAdminPassword = mkOption {
|
||||
type = types.str;
|
||||
description = ''
|
||||
As a server, require this as the admin pasword to be specified. Also,
|
||||
require rpc_admin_user and rpc_admin_password to be checked for RPC admin
|
||||
functions. The request must specify these as the admin_user and
|
||||
admin_password in the request object.
|
||||
'';
|
||||
};
|
||||
|
||||
rpcIp = mkOption {
|
||||
type = types.str;
|
||||
description = ''
|
||||
IP address or domain to bind to allow insecure RPC connections.
|
||||
Defaults to not binding, which disallows RPC connections.
|
||||
The minimum number of trusted validations a ledger must have before
|
||||
the server considers it fully validated.
|
||||
'';
|
||||
type = types.int;
|
||||
default = 3;
|
||||
};
|
||||
|
||||
rpcPort = mkOption {
|
||||
type = types.int;
|
||||
description = ''
|
||||
If rpcIp is supplied, corresponding port to bind to for peer connections.
|
||||
'';
|
||||
};
|
||||
|
||||
rpcUser = mkOption {
|
||||
type = types.str;
|
||||
ledgerHistory = mkOption {
|
||||
description = ''
|
||||
Require a this user to specified and require rpcPassword to
|
||||
be checked for RPC access via the rpcIp and rpcPort. The user and password
|
||||
must be specified via HTTP's basic authentication method.
|
||||
As a client, supply this to the server via HTTP's basic authentication
|
||||
method.
|
||||
The number of past ledgers to acquire on server startup and the minimum
|
||||
to maintain while running.
|
||||
'';
|
||||
type = types.either types.int (types.enum ["full"]);
|
||||
default = 1296000; # 1 month
|
||||
};
|
||||
|
||||
rpcPassword = mkOption {
|
||||
type = types.str;
|
||||
fetchDepth = mkOption {
|
||||
description = ''
|
||||
Require a this password to specified and require rpc_user to
|
||||
be checked for RPC access via the rpcIp and rpcPort. The user and password
|
||||
must be specified via HTTP's basic authentication method.
|
||||
As a client, supply this to the server via HTTP's basic authentication
|
||||
method.
|
||||
The number of past ledgers to serve to other peers that request historical
|
||||
ledger data (or "full" for no limit).
|
||||
'';
|
||||
type = types.either types.int (types.enum ["full"]);
|
||||
default = "full";
|
||||
};
|
||||
|
||||
rpcStartup = mkOption {
|
||||
example = [ ''"command" : "log_level"'' ''"partition" : "ripplecalc"'' ''"severity" : "trace"'' ];
|
||||
description = "List of RPC commands to run at startup.";
|
||||
};
|
||||
|
||||
rpcSecure = mkOption {
|
||||
default = false;
|
||||
sntpServers = mkOption {
|
||||
description = ''
|
||||
false: Server certificates are not provided for RPC clients using SSL [default]
|
||||
true: Client RPC connections wil be provided with SSL certificates.
|
||||
|
||||
Note that if rpc_secure is enabled, it will also be necessasry to configure the
|
||||
certificate file settings located in rpcSslCert, rpcSslChain, and rpcSslKey
|
||||
IP address or domain of NTP servers to use for time synchronization.;
|
||||
'';
|
||||
type = types.listOf types.str;
|
||||
default = [
|
||||
"time.windows.com"
|
||||
"time.apple.com"
|
||||
"time.nist.gov"
|
||||
"pool.ntp.org"
|
||||
];
|
||||
};
|
||||
|
||||
logLevel = mkOption {
|
||||
description = "Logging verbosity.";
|
||||
type = types.enum ["debug" "error" "info"];
|
||||
default = "error";
|
||||
};
|
||||
*/
|
||||
|
||||
extraConfig = mkOption {
|
||||
default = "";
|
||||
@ -275,8 +373,11 @@ in
|
||||
'';
|
||||
};
|
||||
|
||||
config = mkOption {
|
||||
internal = true;
|
||||
default = pkgs.writeText "rippled.conf" rippledCfg;
|
||||
};
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
|
||||
@ -288,27 +389,21 @@ in
|
||||
{ name = "rippled";
|
||||
description = "Ripple server user";
|
||||
uid = config.ids.uids.rippled;
|
||||
home = "/var/lib/rippled";
|
||||
home = cfg.databasePath;
|
||||
createHome = true;
|
||||
};
|
||||
|
||||
systemd.services.rippled = {
|
||||
path = [ pkgs.rippled ];
|
||||
|
||||
after = [ "network.target" ];
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
|
||||
serviceConfig = {
|
||||
ExecStart = "${pkgs.rippled}/bin/rippled --fg -q --conf ${rippledStateCfgFile}";
|
||||
WorkingDirectory = "/var/lib/rippled";
|
||||
ExecStart = "${cfg.package}/bin/rippled --fg --conf ${cfg.config}";
|
||||
User = "rippled";
|
||||
};
|
||||
};
|
||||
|
||||
networking.firewall.allowedTCPPorts = mkIf (cfg.peerIp != null) [ cfg.peerPort ];
|
||||
environment.systemPackages = [ cfg.package ];
|
||||
|
||||
system.activationScripts.rippled = ''
|
||||
mkdir -p /var/{lib,log}/rippled
|
||||
chown -R rippled /var/{lib,log}/rippled
|
||||
ln -sf ${rippledCfgFile} ${rippledStateCfgFile}
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
@ -9,6 +9,14 @@ let
|
||||
stateDir = "/var/lib/nsd";
|
||||
pidFile = stateDir + "/var/nsd.pid";
|
||||
|
||||
nsdPkg = pkgs.nsd.override {
|
||||
bind8Stats = cfg.bind8Stats;
|
||||
ipv6 = cfg.ipv6;
|
||||
ratelimit = cfg.ratelimit.enable;
|
||||
rootServer = cfg.rootServer;
|
||||
zoneStats = length (collect (x: (x.zoneStats or null) != null) cfg.zones) > 0;
|
||||
};
|
||||
|
||||
zoneFiles = pkgs.stdenv.mkDerivation {
|
||||
preferLocalBuild = true;
|
||||
name = "nsd-env";
|
||||
@ -277,7 +285,7 @@ let
|
||||
default = null;
|
||||
example = "%s";
|
||||
description = ''
|
||||
When config.nsd.zoneStats is set to true NSD is able of collecting
|
||||
When set to something distinct to null NSD is able to collect
|
||||
statistics per zone. All statistics of this zone(s) will be added
|
||||
to the group specified by this given name. Use "%s" to use the zones
|
||||
name as the group. The groups are output from nsd-control stats
|
||||
@ -300,6 +308,15 @@ in
|
||||
'';
|
||||
};
|
||||
|
||||
bind8Stats = mkOption {
|
||||
type = types.bool;
|
||||
default = false;
|
||||
example = true;
|
||||
description = ''
|
||||
Wheter to enable BIND8 like statisics.
|
||||
'';
|
||||
};
|
||||
|
||||
rootServer = mkOption {
|
||||
type = types.bool;
|
||||
default = false;
|
||||
@ -673,13 +690,6 @@ in
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
||||
# this is not working :(
|
||||
nixpkgs.config.nsd = {
|
||||
ipv6 = cfg.ipv6;
|
||||
ratelimit = cfg.ratelimit.enable;
|
||||
rootServer = cfg.rootServer;
|
||||
};
|
||||
|
||||
users.extraGroups = singleton {
|
||||
name = username;
|
||||
gid = config.ids.gids.nsd;
|
||||
@ -702,7 +712,7 @@ in
|
||||
serviceConfig = {
|
||||
PIDFile = pidFile;
|
||||
Restart = "always";
|
||||
ExecStart = "${pkgs.nsd}/sbin/nsd -d -c ${configFile}";
|
||||
ExecStart = "${nsdPkg}/sbin/nsd -d -c ${configFile}";
|
||||
};
|
||||
|
||||
preStart = ''
|
||||
|
@ -218,25 +218,25 @@ in
|
||||
|
||||
idea-community = buildIdea rec {
|
||||
name = "idea-community-${version}";
|
||||
version = "14.0.3";
|
||||
build = "IC-139.1117";
|
||||
version = "14.1";
|
||||
build = "IC-141.177.4";
|
||||
description = "Integrated Development Environment (IDE) by Jetbrains, community edition";
|
||||
license = stdenv.lib.licenses.asl20;
|
||||
src = fetchurl {
|
||||
url = "https://download.jetbrains.com/idea/ideaIC-${version}.tar.gz";
|
||||
sha256 = "01wcpzdahkh3li2l3k2bgirnlp7hdxk9y1kyrxc3d9d1nazq8wqn";
|
||||
sha256 = "05irkxhmx6pisvghjalw8hcf9v3n4wn0n0zc92ahivzxlicylpr6";
|
||||
};
|
||||
};
|
||||
|
||||
idea-ultimate = buildIdea rec {
|
||||
name = "idea-ultimate-${version}";
|
||||
version = "14.0.3";
|
||||
build = "IU-139.1117";
|
||||
version = "14.1";
|
||||
build = "IU-141.177.4";
|
||||
description = "Integrated Development Environment (IDE) by Jetbrains, requires paid license";
|
||||
license = stdenv.lib.licenses.unfree;
|
||||
src = fetchurl {
|
||||
url = "https://download.jetbrains.com/idea/ideaIU-${version}.tar.gz";
|
||||
sha256 = "1zkqigdh9l1f3mjjvxsp7b7vc93v5ylvxa1dfpclzmfbzna7h69s";
|
||||
sha256 = "10zv3m44ci7gl7163yp4wxnjy7c0g5zl34c2ibnx4c6ds6l4di2p";
|
||||
};
|
||||
};
|
||||
|
||||
|
71
pkgs/applications/editors/rstudio/default.nix
Normal file
71
pkgs/applications/editors/rstudio/default.nix
Normal file
@ -0,0 +1,71 @@
|
||||
{ stdenv, fetchurl, cmake, boost155, zlib, openssl, R, qt4, libuuid, hunspellDicts, unzip, ant, jdk }:
|
||||
|
||||
let
|
||||
version = "0.98.110";
|
||||
ginVer = "1.5";
|
||||
gwtVer = "2.5.1";
|
||||
in
|
||||
stdenv.mkDerivation {
|
||||
name = "RStudio-${version}";
|
||||
|
||||
buildInputs = [ cmake boost155 zlib openssl R qt4 libuuid unzip ant jdk ];
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://github.com/rstudio/rstudio/archive/v${version}.tar.gz";
|
||||
sha256 = "0wybbvl5libki8z2ywgcd0hg0py1az484r95lhwh3jbrwfx7ri2z";
|
||||
};
|
||||
|
||||
# Hack RStudio to only use the input R.
|
||||
patches = [ ./r-location.patch ];
|
||||
postPatch = "substituteInPlace src/cpp/core/r_util/REnvironmentPosix.cpp --replace '@R@' ${R}";
|
||||
|
||||
inherit ginVer;
|
||||
ginSrc = fetchurl {
|
||||
url = "https://s3.amazonaws.com/rstudio-buildtools/gin-${ginVer}.zip";
|
||||
sha256 = "155bjrgkf046b8ln6a55x06ryvm8agnnl7l8bkwwzqazbpmz8qgm";
|
||||
};
|
||||
|
||||
inherit gwtVer;
|
||||
gwtSrc = fetchurl {
|
||||
url = "https://s3.amazonaws.com/rstudio-buildtools/gwt-${gwtVer}.zip";
|
||||
sha256 = "0fjr2rcr8lnywj54mzhg9i4xz1b6fh8yv12p5i2q5mgfld2xymy4";
|
||||
};
|
||||
|
||||
hunspellDicts = builtins.attrValues hunspellDicts;
|
||||
|
||||
mathJaxSrc = fetchurl {
|
||||
url = https://s3.amazonaws.com/rstudio-buildtools/mathjax-20.zip;
|
||||
sha256 = "1ikg3fhharsfrh2fv8c53fdawqajj24nif89400l3klw1hyq4zal";
|
||||
};
|
||||
|
||||
preConfigure =
|
||||
''
|
||||
GWT_LIB_DIR=src/gwt/lib
|
||||
|
||||
mkdir -p $GWT_LIB_DIR/gin/$ginVer
|
||||
unzip $ginSrc -d $GWT_LIB_DIR/gin/$ginVer
|
||||
|
||||
unzip $gwtSrc
|
||||
mkdir -p $GWT_LIB_DIR/gwt
|
||||
mv gwt-$gwtVer $GWT_LIB_DIR/gwt/$gwtVer
|
||||
|
||||
mkdir dependencies/common/dictionaries
|
||||
for dict in $hunspellDicts; do
|
||||
for i in $dict/share/hunspell/*
|
||||
do ln -sv $i dependencies/common/dictionaries/
|
||||
done
|
||||
done
|
||||
|
||||
unzip $mathJaxSrc -d dependencies/common/mathjax
|
||||
'';
|
||||
|
||||
cmakeFlags = [ "-DRSTUDIO_TARGET=Desktop" ];
|
||||
|
||||
meta = with stdenv.lib;
|
||||
{ description = "Set of integrated tools for the R language";
|
||||
homepage = http://www.rstudio.com/;
|
||||
license = licenses.agpl3;
|
||||
maintainers = [ maintainers.emery ];
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
@ -5,11 +5,11 @@
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "calibre-2.21.0";
|
||||
name = "calibre-2.22.0";
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/calibre/${name}.tar.xz";
|
||||
sha256 = "1adig2jxwbmsxcs36jaybhc8zdb8mnkc23kabw0c72izrsg4c5gb";
|
||||
sha256 = "19hpm5xzhjr0nfjm6xyqxjx2iwm3iw7y6bbs11337arfrxn16ly0";
|
||||
};
|
||||
|
||||
inherit python;
|
||||
|
@ -1,10 +1,10 @@
|
||||
{ fetchurl, stdenv, jre, glib, libXtst, gtk, makeWrapper }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "davmail-4.5.1";
|
||||
name = "davmail-4.6.1";
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/davmail/davmail-linux-x86_64-4.5.1-2303.tgz";
|
||||
sha256 = "0y9dwxlfrfm6yf010fad1p5vsyz2ddci6vhz4sa1js2fq4rvyx7a";
|
||||
url = "mirror://sourceforge/davmail/davmail-linux-x86_64-4.6.1-2343.tgz";
|
||||
sha256 = "15kpbrmw9pcifxj4k4m3q0azbl95kfgwvgb8bc9aj00q0yi3wgiq";
|
||||
};
|
||||
|
||||
buildInputs = [ makeWrapper ];
|
||||
|
@ -154,7 +154,7 @@ stdenv.mkDerivation rec {
|
||||
${if speexSupport then "--enable-speex" else "--disable-speex"}
|
||||
${if theoraSupport then "--enable-theora" else "--disable-theora"}
|
||||
${if x264Support then "--enable-x264 --disable-x264-lavc" else "--disable-x264 --enable-x264-lavc"}
|
||||
${if jackaudioSupport then "--enable-jack" else "--disable-jack"}
|
||||
${if jackaudioSupport then "" else "--disable-jack"}
|
||||
${if pulseSupport then "--enable-pulse" else "--disable-pulse"}
|
||||
${optionalString (useUnfreeCodecs && codecs != null) "--codecsdir=${codecs}"}
|
||||
${optionalString (stdenv.isi686 || stdenv.isx86_64) "--enable-runtime-cpudetection"}
|
||||
|
@ -1,7 +1,6 @@
|
||||
{ stdenv, fetchurl, pkgconfig, intltool, itstool, makeWrapper
|
||||
, pythonPackages, gst, clutter-gst, clutter-gtk
|
||||
, gobjectIntrospection, clutter, gtk3, librsvg
|
||||
, gnome_icon_theme, gnome_icon_theme_symbolic, gnome3
|
||||
, pythonPackages, gst, clutter-gst, clutter-gtk, hicolor_icon_theme
|
||||
, gobjectIntrospection, clutter, gtk3, librsvg, gnome3, libnotify
|
||||
}:
|
||||
|
||||
let
|
||||
@ -30,27 +29,22 @@ in stdenv.mkDerivation rec {
|
||||
nativeBuildInputs = [ pkgconfig intltool itstool makeWrapper ];
|
||||
|
||||
buildInputs = [
|
||||
gobjectIntrospection clutter-gst clutter-gtk librsvg
|
||||
gobjectIntrospection clutter-gst clutter-gtk librsvg gnome3.gnome_desktop
|
||||
hicolor_icon_theme gnome3.gnome_icon_theme gnome3.gnome_icon_theme_symbolic
|
||||
gnome3.gsettings_desktop_schemas libnotify
|
||||
] ++ (with gst; [
|
||||
gst-python gst-editing-services
|
||||
gstreamer gst-python gst-editing-services
|
||||
gst-plugins-base gst-plugins-good
|
||||
gst-plugins-bad gst-plugins-ugly gst-libav
|
||||
]) ++ (with pythonPackages; [
|
||||
python pygobject3 pyxdg numpy pycairo sqlite3
|
||||
]);
|
||||
|
||||
preFixup = with stdenv.lib; with gst; let
|
||||
libraryPath = makeLibraryPath [
|
||||
gstreamer gst-editing-services
|
||||
clutter-gst clutter-gtk clutter gtk3
|
||||
gnome3.gnome_desktop
|
||||
];
|
||||
in ''
|
||||
preFixup = ''
|
||||
wrapProgram "$out/bin/pitivi" \
|
||||
--set GDK_PIXBUF_MODULE_FILE "$GDK_PIXBUF_MODULE_FILE" \
|
||||
--prefix LD_LIBRARY_PATH : "${libraryPath}" \
|
||||
--prefix GI_TYPELIB_PATH : "$GI_TYPELIB_PATH" \
|
||||
--prefix GST_PLUGIN_SYSTEM_PATH_1_0 : "$GST_PLUGIN_SYSTEM_PATH_1_0" \
|
||||
--prefix XDG_DATA_DIRS : "\$XDG_ICON_DIRS:$out/share:$GSETTINGS_SCHEMAS_PATH"
|
||||
rm $out/share/icons/hicolor/icon-theme.cache
|
||||
--prefix XDG_DATA_DIRS : "$XDG_ICON_DIRS:$out/share:$GSETTINGS_SCHEMAS_PATH"
|
||||
'';
|
||||
}
|
||||
|
@ -642,11 +642,11 @@ self: super: {
|
||||
# Not on Hackage.
|
||||
cabal2nix = self.mkDerivation {
|
||||
pname = "cabal2nix";
|
||||
version = "20150310";
|
||||
version = "20150318";
|
||||
src = pkgs.fetchgit {
|
||||
url = "http://github.com/NixOS/cabal2nix.git";
|
||||
rev = "267d0495209822ad819b58cb472a0da54f5a0b72";
|
||||
sha256 = "1sdsjwf1cda4bpriiv1vfx0pa26087hzw7vviacvgbmn0xh6wm8g";
|
||||
rev = "a8eaadbe6529cabd5088b8ae24fb325fc85a50c1";
|
||||
sha256 = "08q6c6g6syf4qgmgmicq8gf3fmp2cvy9mm6wm0vi7wjll3i2dns1";
|
||||
deepClone = true;
|
||||
};
|
||||
isLibrary = false;
|
||||
|
@ -129,6 +129,6 @@ self: super: {
|
||||
# https://github.com/batterseapower/ansi-wl-pprint/issues/13
|
||||
ansi-wl-pprint = appendPatch super.ansi-wl-pprint (pkgs.fetchpatch {
|
||||
url = "https://github.com/hvr/ansi-wl-pprint/commit/7e489ea6b546899074b1cdccf37d2e49ab313098.patch";
|
||||
sha256 = "111aasm6pb55prldzwzgfffd5zz1npl7akdzcwh2hsri865i1806";
|
||||
sha256 = "0j20cwbph1wg82gfad5a6gfc5gy42cf4vz514jrpfg8d9qvyfhlj";
|
||||
});
|
||||
}
|
||||
|
@ -4,11 +4,11 @@
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "groovy-${version}";
|
||||
version = "2.4.1";
|
||||
version = "2.4.2";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://dl.bintray.com/groovy/maven/groovy-binary-${version}.zip";
|
||||
sha256 = "1bhsv804iik497gflgp0wfhj6j4ylrladp1xndcszlfg576r1zch";
|
||||
sha256 = "02vbg9ywn76rslkinjk1dw3wrj76p5bahbhvz71drlp30cs1r28w";
|
||||
};
|
||||
|
||||
installPhase = ''
|
||||
|
@ -1,42 +1,16 @@
|
||||
x@{builderDefsPackage
|
||||
, readline
|
||||
, ...}:
|
||||
builderDefsPackage
|
||||
(a :
|
||||
let
|
||||
helperArgNames = ["stdenv" "fetchurl" "builderDefsPackage"] ++
|
||||
[];
|
||||
{ stdenv, fetchurl, readline }:
|
||||
|
||||
buildInputs = map (n: builtins.getAttr n x)
|
||||
(builtins.attrNames (builtins.removeAttrs x helperArgNames));
|
||||
sourceInfo = rec {
|
||||
baseName="j";
|
||||
version="701_b";
|
||||
name="${baseName}-${version}";
|
||||
url="http://www.jsoftware.com/download/${baseName}${version}_source.tar.gz";
|
||||
hash="1gmjlpxcd647x690c4dxnf8h6ays8ndir6cib70h3zfnkrc34cys";
|
||||
};
|
||||
in
|
||||
rec {
|
||||
src = a.fetchurl {
|
||||
url = sourceInfo.url;
|
||||
sha256 = sourceInfo.hash;
|
||||
stdenv.mkDerivation rec {
|
||||
name = "j-${version}";
|
||||
version = "701_b";
|
||||
src = fetchurl {
|
||||
url = "http://www.jsoftware.com/download/j${version}_source.tar.gz";
|
||||
sha256 = "1gmjlpxcd647x690c4dxnf8h6ays8ndir6cib70h3zfnkrc34cys";
|
||||
};
|
||||
buildInputs = [ readline ];
|
||||
bits = if stdenv.is64bit then "64" else "32";
|
||||
|
||||
inherit (sourceInfo) name version;
|
||||
inherit buildInputs;
|
||||
|
||||
/* doConfigure should be removed if not needed */
|
||||
phaseNames = ["doUnpack" "doBuildJ" "doDeploy"];
|
||||
|
||||
bits = if a.stdenv.is64bit then
|
||||
"64"
|
||||
else if a.stdenv.isi686 then
|
||||
"32"
|
||||
else
|
||||
builtins.trace "assuming ${a.stdenv.system} is 32 bits" "32";
|
||||
|
||||
doBuildJ = a.fullDepEntry ''
|
||||
buildPhase = ''
|
||||
sed -i bin/jconfig -e '
|
||||
s@bits=32@bits=${bits}@g;
|
||||
s@readline=0@readline=1@;
|
||||
@ -51,36 +25,28 @@ rec {
|
||||
sh -o errexit bin/build_defs
|
||||
sh -o errexit bin/build_tsdll
|
||||
|
||||
sed -i j/bin/profile.ijs -e "s@userx=[.] *'.j'@userx=. '/.j'@;
|
||||
sed -i j/bin/profile.ijs -e "
|
||||
s@userx=[.] *'.j'@userx=. '/.j'@;
|
||||
s@bin,'/profilex.ijs'@user,'/profilex.ijs'@ ;
|
||||
/install=./ainstall=. install,'/share/j'
|
||||
"
|
||||
'' ["doUnpack" "addInputs" "minInit"];
|
||||
"
|
||||
'';
|
||||
|
||||
doDeploy = a.fullDepEntry ''
|
||||
installPhase = ''
|
||||
mkdir -p "$out"
|
||||
cp -r j/bin "$out/bin"
|
||||
rm "$out/bin/profilex_template.ijs"
|
||||
|
||||
|
||||
mkdir -p "$out/share/j"
|
||||
|
||||
cp -r docs j/addons j/system "$out/share/j"
|
||||
'' ["doUnpack" "doBuildJ" "minInit" "defEnsureDir"];
|
||||
|
||||
meta = {
|
||||
description = "J programming language, an ASCII-based APL successor";
|
||||
maintainers = with a.lib.maintainers;
|
||||
[
|
||||
raskin
|
||||
];
|
||||
platforms = with a.lib.platforms;
|
||||
unix;
|
||||
license = a.lib.licenses.gpl3Plus;
|
||||
};
|
||||
passthru = {
|
||||
updateInfo = {
|
||||
downloadPage = "http://jsoftware.com/source.htm";
|
||||
};
|
||||
};
|
||||
}) x
|
||||
'';
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
description = "J programming language, an ASCII-based APL successor";
|
||||
maintainers = with maintainers; [ raskin ];
|
||||
platforms = platforms.unix;
|
||||
license = licenses.gpl3Plus;
|
||||
homepage = http://jsoftware.com/;
|
||||
};
|
||||
}
|
||||
|
@ -2,7 +2,7 @@
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "flann-1.8.4";
|
||||
|
||||
|
||||
src = fetchurl {
|
||||
url = http://people.cs.ubc.ca/~mariusm/uploads/FLANN/flann-1.8.4-src.zip;
|
||||
sha256 = "022w8hph7bli5zbpnk3z1qh1c2sl5hm8fw2ccim651ynn0hr7fyz";
|
||||
@ -10,11 +10,14 @@ stdenv.mkDerivation {
|
||||
|
||||
buildInputs = [ unzip cmake python ];
|
||||
|
||||
# patch out examples in Darwin because they do not compile.
|
||||
patches = stdenv.lib.optionals stdenv.isDarwin [ ./no-examples.patch ];
|
||||
|
||||
meta = {
|
||||
homepage = http://people.cs.ubc.ca/~mariusm/flann/;
|
||||
license = stdenv.lib.licenses.bsd3;
|
||||
description = "Fast approximate nearest neighbor searches in high dimensional spaces";
|
||||
maintainers = with stdenv.lib.maintainers; [viric];
|
||||
platforms = with stdenv.lib.platforms; linux;
|
||||
platforms = with stdenv.lib.platforms; linux ++ darwin;
|
||||
};
|
||||
}
|
||||
|
10
pkgs/development/libraries/flann/no-examples.patch
Normal file
10
pkgs/development/libraries/flann/no-examples.patch
Normal file
@ -0,0 +1,10 @@
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -155,7 +155,7 @@
|
||||
|
||||
add_subdirectory( cmake )
|
||||
add_subdirectory( src )
|
||||
-add_subdirectory( examples )
|
||||
+#add_subdirectory( examples )
|
||||
add_subdirectory( test )
|
||||
add_subdirectory( doc )
|
@ -1,4 +1,4 @@
|
||||
{ stdenv, fetchurl, pkgconfig, python, glib, zlib, libpng }:
|
||||
{ stdenv, fetchurl, pkgconfig, python, glib, zlib, libpng, gnumake3 }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "lensfun-0.2.8";
|
||||
@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
|
||||
|
||||
patchPhase = "sed -e 's@/usr/bin/python@${python}/bin/python@' -i configure";
|
||||
|
||||
buildInputs = [ pkgconfig glib zlib libpng ];
|
||||
buildInputs = [ pkgconfig glib zlib libpng gnumake3 ];
|
||||
|
||||
configureFlags = "-v";
|
||||
|
||||
|
@ -31,6 +31,7 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "0qkx2qfv02igbrmsn6z5a3lbrbwjfh3rb0c2sj54wy0j1f775hbc";
|
||||
} )
|
||||
./ftbfs-libpng15.patch
|
||||
./il_endian.h.patch
|
||||
];
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
|
27
pkgs/development/libraries/libdevil/il_endian.h.patch
Normal file
27
pkgs/development/libraries/libdevil/il_endian.h.patch
Normal file
@ -0,0 +1,27 @@
|
||||
Source: http://sourceforge.net/p/resil/tickets/8/
|
||||
--- devil-1.7.8.orig/src-IL/include/il_endian.h.orig 2009-03-08 01:10:08.000000000 -0600
|
||||
+++ devil-1.7.8/src-IL/include/il_endian.h 2013-11-03 01:52:37.000000000 -0600
|
||||
@@ -19,9 +19,13 @@
|
||||
#ifndef __BIG_ENDIAN__
|
||||
#define __BIG_ENDIAN__ 1
|
||||
#endif
|
||||
+#else
|
||||
+ #ifndef __LITTLE_ENDIAN__
|
||||
+ #define __LITTLE_ENDIAN__ 1
|
||||
+ #endif
|
||||
#endif
|
||||
|
||||
-#if (defined(__BYTE_ORDER__) && __BYTE_ORDER__ == __BIG_ENDIAN__) \
|
||||
+#if (defined(__BYTE_ORDER__) && __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__) \
|
||||
|| (defined(__BIG_ENDIAN__) && !defined(__LITTLE_ENDIAN__))
|
||||
#undef __LITTLE_ENDIAN__
|
||||
#define Short(s) iSwapShort(s)
|
||||
@@ -39,8 +43,6 @@
|
||||
#define BigDouble(d)
|
||||
#else
|
||||
#undef __BIG_ENDIAN__
|
||||
- #undef __LITTLE_ENDIAN__ // Not sure if it's defined by any compiler...
|
||||
- #define __LITTLE_ENDIAN__
|
||||
#define Short(s)
|
||||
#define UShort(s)
|
||||
#define Int(i)
|
@ -13,7 +13,7 @@ let
|
||||
sourceInfo = rec {
|
||||
method="fetchgit";
|
||||
baseName="libfixposix";
|
||||
url="git://gitorious.org/${baseName}/${baseName}";
|
||||
url="https://github.com/sionescu/libfixposix";
|
||||
rev="30b75609d858588ea00b427015940351896867e9";
|
||||
version="git-${rev}";
|
||||
name="${baseName}-${version}";
|
||||
|
@ -51,5 +51,6 @@ stdenv.mkDerivation rec {
|
||||
homepage = http://libguestfs.org/;
|
||||
maintainers = with maintainers; [offline];
|
||||
platforms = with platforms; linux;
|
||||
hydraPlatforms = [];
|
||||
};
|
||||
}
|
||||
|
22
pkgs/development/libraries/libosmpbf/default.nix
Normal file
22
pkgs/development/libraries/libosmpbf/default.nix
Normal file
@ -0,0 +1,22 @@
|
||||
{stdenv, fetchurl, protobuf}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "libosmpbf-1.3.3";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://github.com/scrosby/OSM-binary/archive/v1.3.3.tar.gz";
|
||||
sha256 = "a109f338ce6a8438a8faae4627cd08599d0403b8977c185499de5c17b92d0798";
|
||||
};
|
||||
|
||||
buildInputs = [ protobuf ];
|
||||
|
||||
sourceRoot = "OSM-binary-1.3.3/src";
|
||||
|
||||
installFlags = "PREFIX=$(out)";
|
||||
|
||||
meta = {
|
||||
homepage = https://github.com/scrosby/OSM-binary;
|
||||
description = "C library to read and write OpenStreetMap PBF files.";
|
||||
license = stdenv.lib.licenses.lgpl3;
|
||||
};
|
||||
}
|
@ -0,0 +1,23 @@
|
||||
diff --git a/luabind/object.hpp b/luabind/object.hpp
|
||||
index f7b7ca5..1c18e04 100644
|
||||
--- a/luabind/object.hpp
|
||||
+++ b/luabind/object.hpp
|
||||
@@ -536,6 +536,8 @@ namespace detail
|
||||
handle m_key;
|
||||
};
|
||||
|
||||
+#if BOOST_VERSION < 105700
|
||||
+
|
||||
// Needed because of some strange ADL issues.
|
||||
|
||||
#define LUABIND_OPERATOR_ADL_WKND(op) \
|
||||
@@ -557,7 +559,8 @@ namespace detail
|
||||
LUABIND_OPERATOR_ADL_WKND(!=)
|
||||
|
||||
#undef LUABIND_OPERATOR_ADL_WKND
|
||||
-
|
||||
+
|
||||
+#endif // BOOST_VERSION < 105700
|
||||
} // namespace detail
|
||||
|
||||
namespace adl
|
@ -0,0 +1,22 @@
|
||||
diff --git a/Jamroot b/Jamroot
|
||||
index 94494bf..83dfcbb 100755
|
||||
--- a/Jamroot
|
||||
+++ b/Jamroot
|
||||
@@ -64,7 +64,7 @@ else if [ os.name ] in LINUX MACOSX FREEBSD
|
||||
$(LUA_PATH) $(HOME)/Library/Frameworks /Library/Frameworks /usr /usr/local /opt/local /opt ;
|
||||
|
||||
local possible-suffixes =
|
||||
- include/lua5.1 include/lua51 include/lua include ;
|
||||
+ include/lua5.1 include/lua51 include/lua include include/luajit-2.0 ;
|
||||
|
||||
local includes = [ GLOB $(possible-prefixes)/$(possible-suffixes) : lua.h ] ;
|
||||
|
||||
@@ -83,7 +83,7 @@ else if [ os.name ] in LINUX MACOSX FREEBSD
|
||||
|
||||
local lib = $(prefix)/lib ;
|
||||
|
||||
- local names = liblua5.1 liblua51 liblua ;
|
||||
+ local names = liblua5.1 liblua51 liblua libluajit-5.1 ;
|
||||
local extensions = .a .so ;
|
||||
|
||||
library = [ GLOB $(lib)/lua51 $(lib)/lua5.1 $(lib)/lua $(lib) :
|
@ -0,0 +1,59 @@
|
||||
diff --git luabind-0.9.1/luabind/detail/call_function.hpp luabind-0.9.1-fixed/luabind/detail/call_function.hpp
|
||||
index 1b45ec1..8f5afff 100644
|
||||
--- luabind-0.9.1/luabind/detail/call_function.hpp
|
||||
+++ luabind-0.9.1-fixed/luabind/detail/call_function.hpp
|
||||
@@ -323,7 +323,8 @@ namespace luabind
|
||||
|
||||
#endif // LUABIND_CALL_FUNCTION_HPP_INCLUDED
|
||||
|
||||
-#elif BOOST_PP_ITERATION_FLAGS() == 1
|
||||
+#else
|
||||
+#if BOOST_PP_ITERATION_FLAGS() == 1
|
||||
|
||||
#define LUABIND_TUPLE_PARAMS(z, n, data) const A##n *
|
||||
#define LUABIND_OPERATOR_PARAMS(z, n, data) const A##n & a##n
|
||||
@@ -440,4 +441,5 @@ namespace luabind
|
||||
|
||||
|
||||
#endif
|
||||
+#endif
|
||||
|
||||
diff --git luabind-0.9.1/luabind/detail/call_member.hpp luabind-0.9.1-fixed/luabind/detail/call_member.hpp
|
||||
index de8d563..e63555b 100644
|
||||
--- luabind-0.9.1/luabind/detail/call_member.hpp
|
||||
+++ luabind-0.9.1-fixed/luabind/detail/call_member.hpp
|
||||
@@ -316,7 +316,8 @@ namespace luabind
|
||||
|
||||
#endif // LUABIND_CALL_MEMBER_HPP_INCLUDED
|
||||
|
||||
-#elif BOOST_PP_ITERATION_FLAGS() == 1
|
||||
+#else
|
||||
+#if BOOST_PP_ITERATION_FLAGS() == 1
|
||||
|
||||
#define LUABIND_TUPLE_PARAMS(z, n, data) const A##n *
|
||||
#define LUABIND_OPERATOR_PARAMS(z, n, data) const A##n & a##n
|
||||
@@ -360,4 +361,5 @@ namespace luabind
|
||||
#undef LUABIND_TUPLE_PARAMS
|
||||
|
||||
#endif
|
||||
+#endif
|
||||
|
||||
diff --git luabind-0.9.1/luabind/wrapper_base.hpp luabind-0.9.1-fixed/luabind/wrapper_base.hpp
|
||||
index d54c668..0f88cc5 100755
|
||||
--- luabind-0.9.1/luabind/wrapper_base.hpp
|
||||
+++ luabind-0.9.1-fixed/luabind/wrapper_base.hpp
|
||||
@@ -89,7 +89,8 @@ namespace luabind
|
||||
|
||||
#endif // LUABIND_WRAPPER_BASE_HPP_INCLUDED
|
||||
|
||||
-#elif BOOST_PP_ITERATION_FLAGS() == 1
|
||||
+#else
|
||||
+#if BOOST_PP_ITERATION_FLAGS() == 1
|
||||
|
||||
#define LUABIND_TUPLE_PARAMS(z, n, data) const A##n *
|
||||
#define LUABIND_OPERATOR_PARAMS(z, n, data) const A##n & a##n
|
||||
@@ -188,3 +189,4 @@ namespace luabind
|
||||
#undef N
|
||||
|
||||
#endif
|
||||
+#endif
|
30
pkgs/development/libraries/luabind/default.nix
Normal file
30
pkgs/development/libraries/luabind/default.nix
Normal file
@ -0,0 +1,30 @@
|
||||
{stdenv, fetchurl, boost-build, lua, boost}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "luabind-0.9.1";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://github.com/luabind/luabind/archive/v0.9.1.tar.gz";
|
||||
sha256 = "0e5ead50a07668d29888f2fa6f53220f900c886e46a2c99c7e8656842f05ff2d";
|
||||
};
|
||||
|
||||
patches = [ ./0.9.1_modern_boost_fix.patch ./0.9.1_boost_1.57_fix.patch ./0.9.1_discover_luajit.patch ];
|
||||
|
||||
buildInputs = [ boost-build lua boost ];
|
||||
|
||||
propagatedBuildInputs = [ lua ];
|
||||
|
||||
buildPhase = "LUA_PATH=${lua} bjam release";
|
||||
|
||||
installPhase = "LUA_PATH=${lua} bjam --prefix=$out release install";
|
||||
|
||||
passthru = {
|
||||
inherit lua;
|
||||
};
|
||||
|
||||
meta = {
|
||||
homepage = https://github.com/luabind/luabind;
|
||||
description = "Luabind is a library that helps you create bindings between C++ and Lua.";
|
||||
license = stdenv.lib.licenses.mit;
|
||||
};
|
||||
}
|
24
pkgs/development/libraries/stxxl/default.nix
Normal file
24
pkgs/development/libraries/stxxl/default.nix
Normal file
@ -0,0 +1,24 @@
|
||||
{stdenv, fetchurl, cmake, parallel ? true }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "stxxl-1.4.1";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://github.com/stxxl/stxxl/archive/1.4.1.tar.gz";
|
||||
sha256 = "54006a5fccd1435abc2f3ec201997a4d7dacddb984d2717f62191798e5372f6c";
|
||||
};
|
||||
|
||||
buildInputs = [ cmake ];
|
||||
|
||||
cmakeFlags = let parallel_str = if parallel then "ON" else "OFF"; in "-DUSE_GNU_PARALLEL=${parallel_str}";
|
||||
|
||||
passthru = {
|
||||
inherit parallel;
|
||||
};
|
||||
|
||||
meta = {
|
||||
homepage = https://github.com/stxxl/stxxl;
|
||||
description = "STXXL is an implementation of the C++ standard template library STL for external memory (out-of-core) computations.";
|
||||
license = stdenv.lib.licenses.boost;
|
||||
};
|
||||
}
|
@ -2,11 +2,11 @@
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "sbt-${version}";
|
||||
version = "0.13.7";
|
||||
version = "0.13.8";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://repo.typesafe.com/typesafe/ivy-releases/org.scala-sbt/sbt-launch/${version}/sbt-launch.jar";
|
||||
sha256 = "9673ca4611e6367955ae068d5888f7ae665ab013c3e8435ffe2ca94318c6d607";
|
||||
sha256 = "0n4ivla8s8ygfnf95dj624nhcyganigf7fy0gamgyf31vw1vnw35";
|
||||
};
|
||||
|
||||
phases = [ "installPhase" ];
|
||||
|
@ -14,7 +14,7 @@ stdenv.mkDerivation {
|
||||
passthru = {
|
||||
# A derivation that provides gcc and g++ commands, but that
|
||||
# will end up calling ccache for the given cacheDir
|
||||
links = extraConfig : (runCommand "ccache-links" { }
|
||||
links = extraConfig : (runCommand "ccache-links" { passthru.gcc = gcc; }
|
||||
''
|
||||
mkdir -p $out/bin
|
||||
if [ -x "${gcc.cc}/bin/gcc" ]; then
|
||||
|
@ -1,11 +0,0 @@
|
||||
--- opam-1.2.0/src_ext/Makefile 2014-10-15 21:32:13.000000000 -0400
|
||||
+++ opam-1.2.0/src_ext/Makefile.new 2014-10-29 17:37:00.785365601 -0400
|
||||
@@ -51,7 +51,7 @@ archives: $(SRC_EXTS:=.download)
|
||||
[ -e $(notdir $(URL_$*)) ] || $(FETCH) $(URL_$*)
|
||||
$(MD5CHECK) $(notdir $(URL_$*)) $(MD5_$*)
|
||||
|
||||
-%.stamp: %.download
|
||||
+%.stamp:
|
||||
mkdir -p tmp
|
||||
cd tmp && tar xf$(if $(patsubst %.tar.gz,,$(URL_$*)),j,z) ../$(notdir $(URL_$*))
|
||||
rm -rf $*
|
@ -1,6 +1,5 @@
|
||||
{ stdenv, fetchgit, fetchurl, ocaml, unzip, ncurses, curl }:
|
||||
|
||||
# Opam 1.2.0 only works with ocaml >= 3.12.1 according to ./configure
|
||||
assert stdenv.lib.versionAtLeast (stdenv.lib.getVersion ocaml) "3.12.1";
|
||||
|
||||
let
|
||||
@ -22,12 +21,12 @@ let
|
||||
sha256 = "d167466435a155c779d5ec25b2db83ad851feb42ebc37dca8ffa345ddaefb82f";
|
||||
};
|
||||
dose3 = fetchurl {
|
||||
url = "https://gforge.inria.fr/frs/download.php/file/33677/dose3-3.2.2.tar.gz";
|
||||
sha256 = "a30a189f9f298ed1de96d7098440c951f3df2c8da626f7f37f38cbfddefc909c";
|
||||
url = "https://gforge.inria.fr/frs/download.php/file/34277/dose3-3.3.tar.gz";
|
||||
sha256 = "8dc4dae9b1a81bb3a42abb283df785ba3eb00ade29b13875821c69f03e00680e";
|
||||
};
|
||||
cmdliner = fetchurl {
|
||||
url = "http://erratique.ch/software/cmdliner/releases/cmdliner-0.9.4.tbz";
|
||||
sha256 = "ecb65e2cfd984ec07e97a78f334a80cda41fb8f8bb5e37c41fd33e6a0e2e69ef";
|
||||
url = "http://erratique.ch/software/cmdliner/releases/cmdliner-0.9.7.tbz";
|
||||
sha256 = "9c19893cffb5d3c3469ee0cce85e3eeeba17d309b33b9ace31aba06f68f0bf7a";
|
||||
};
|
||||
uutf = fetchurl {
|
||||
url = "http://erratique.ch/software/uutf/releases/uutf-0.9.3.tbz";
|
||||
@ -38,13 +37,13 @@ let
|
||||
sha256 = "3fd4dca045d82332da847e65e981d8b504883571d299a3f7e71447d46bc65f73";
|
||||
};
|
||||
opam = fetchurl {
|
||||
url = "https://github.com/ocaml/opam/archive/1.2.0.zip";
|
||||
sha256 = "b78bb9570fbd1dae50583792525a3dd612f8f90db367771fabd7bf4571ba25f7";
|
||||
url = "https://github.com/ocaml/opam/archive/1.2.1.zip";
|
||||
sha256 = "1mvsy89l5g9nvwmmls5jf46anh6gk8dk8a1dn42rmnihnb0zjcs4";
|
||||
};
|
||||
};
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
name = "opam-1.2.0";
|
||||
in stdenv.mkDerivation rec {
|
||||
name = "opam-${version}";
|
||||
version = "1.2.1";
|
||||
|
||||
buildInputs = [ unzip curl ncurses ocaml ];
|
||||
|
||||
@ -61,7 +60,9 @@ stdenv.mkDerivation rec {
|
||||
ln -sv ${srcs.jsonm} $sourceRoot/src_ext/${srcs.jsonm.name}
|
||||
'';
|
||||
|
||||
patches = [ ./1.2.0-src_ext-Makefile.patch ];
|
||||
preConfigure = ''
|
||||
substituteInPlace ./src_ext/Makefile --replace "%.stamp: %.download" "%.stamp:"
|
||||
'';
|
||||
|
||||
postConfigure = "make lib-ext";
|
||||
|
||||
@ -70,10 +71,10 @@ stdenv.mkDerivation rec {
|
||||
|
||||
doCheck = false;
|
||||
|
||||
meta = {
|
||||
maintainers = [ stdenv.lib.maintainers.henrytill ];
|
||||
meta = with stdenv.lib; {
|
||||
description = "A package manager for OCaml";
|
||||
homepage = "http://opam.ocamlpro.com/";
|
||||
platforms = stdenv.lib.platforms.all;
|
||||
homepage = http://opam.ocamlpro.com/;
|
||||
maintainers = [ maintainers.henrytill ];
|
||||
platforms = platforms.all;
|
||||
};
|
||||
}
|
@ -3,11 +3,11 @@
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "gradm-${version}";
|
||||
version = "3.1-201502222102";
|
||||
version = "3.1-201503211320";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://grsecurity.net/stable/${name}.tar.gz";
|
||||
sha256 = "1dvzjjyq8phhjcm425j9hw0m0azg34lm02p0yn058jiipx731xrp";
|
||||
sha256 = "17yd307jqva8jqib2xr3i9kmp58f2cb4jd7an5rbk5zr1k48ap9j";
|
||||
};
|
||||
|
||||
buildInputs = [ gcc coreutils findutils binutils pam flex bison bash ];
|
||||
|
@ -1,71 +0,0 @@
|
||||
From 6f0af2643c40b57280796eaa4fe60ce4f678b6dc Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Andr=C3=A9=20Goddard=20Rosa?= <andre.goddard@gmail.com>
|
||||
Date: Thu, 13 Nov 2014 21:33:02 -0800
|
||||
Subject: [PATCH] Fix compilation on Linux kernel >= 3.18.0
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
Since kernel commit 8a9522d2fe compilation fails as kvm_age_page
|
||||
tracepoint had its signature changed, so update it accordingly.
|
||||
|
||||
Tested pointing to kernels:
|
||||
git reset --hard v3.17; make init/version.o
|
||||
git reset --hard v3.18-rc1; make init/version.o
|
||||
|
||||
Signed-off-by: André Goddard Rosa <andre.goddard@gmail.com>
|
||||
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
|
||||
---
|
||||
instrumentation/events/lttng-module/kvm.h | 29 +++++++++++++++++++++++++++++
|
||||
1 file changed, 29 insertions(+)
|
||||
mode change 100644 => 100755 instrumentation/events/lttng-module/kvm.h
|
||||
|
||||
diff --git a/instrumentation/events/lttng-module/kvm.h b/instrumentation/events/lttng-module/kvm.h
|
||||
old mode 100644
|
||||
new mode 100755
|
||||
index c0d42e2..4f95095
|
||||
--- a/instrumentation/events/lttng-module/kvm.h
|
||||
+++ b/instrumentation/events/lttng-module/kvm.h
|
||||
@@ -232,6 +232,34 @@ LTTNG_TRACEPOINT_EVENT(kvm_fpu,
|
||||
TP_printk("%s", __print_symbolic(__entry->load, kvm_fpu_load_symbol))
|
||||
)
|
||||
|
||||
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,18,0))
|
||||
+
|
||||
+LTTNG_TRACEPOINT_EVENT(kvm_age_page,
|
||||
+ TP_PROTO(ulong gfn, int level, struct kvm_memory_slot *slot, int ref),
|
||||
+ TP_ARGS(gfn, level, slot, ref),
|
||||
+
|
||||
+ TP_STRUCT__entry(
|
||||
+ __field( u64, hva )
|
||||
+ __field( u64, gfn )
|
||||
+ __field( u8, level )
|
||||
+ __field( u8, referenced )
|
||||
+ ),
|
||||
+
|
||||
+ TP_fast_assign(
|
||||
+ tp_assign(gfn, gfn)
|
||||
+ tp_assign(level, level)
|
||||
+ tp_assign(hva, ((gfn - slot->base_gfn) <<
|
||||
+ PAGE_SHIFT) + slot->userspace_addr)
|
||||
+ tp_assign(referenced, ref)
|
||||
+ ),
|
||||
+
|
||||
+ TP_printk("hva %llx gfn %llx level %u %s",
|
||||
+ __entry->hva, __entry->gfn, __entry->level,
|
||||
+ __entry->referenced ? "YOUNG" : "OLD")
|
||||
+)
|
||||
+
|
||||
+#else
|
||||
+
|
||||
LTTNG_TRACEPOINT_EVENT(kvm_age_page,
|
||||
TP_PROTO(ulong hva, struct kvm_memory_slot *slot, int ref),
|
||||
TP_ARGS(hva, slot, ref),
|
||||
@@ -254,6 +282,7 @@ LTTNG_TRACEPOINT_EVENT(kvm_age_page,
|
||||
__entry->referenced ? "YOUNG" : "OLD")
|
||||
)
|
||||
#endif
|
||||
+#endif
|
||||
|
||||
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,38))
|
||||
|
@ -1,30 +0,0 @@
|
||||
[PATCH] Update compaction instrumentation for 3.14.x stable kernels
|
||||
|
||||
Conditional compilation introduced by lttng-modules commit
|
||||
|
||||
0007344741ef65259bc52dea72259173dfbf96c0
|
||||
|
||||
needs to be applied to kernels 3.14.25 and up in the 3.14.x branch.
|
||||
|
||||
Signed-off-by: Simon Marchi <simon.marchi at polymtl.ca>
|
||||
Reported-by: Bjørn Forsman <bjorn.forsman at gmail.com>
|
||||
---
|
||||
instrumentation/events/lttng-module/compaction.h | 3 ++-
|
||||
1 file changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/instrumentation/events/lttng-module/compaction.h b/instrumentation/events/lttng-module/compaction.h
|
||||
index ee23aa9..773a6ad 100644
|
||||
--- a/instrumentation/events/lttng-module/compaction.h
|
||||
+++ b/instrumentation/events/lttng-module/compaction.h
|
||||
@@ -46,7 +46,8 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(mm_compaction_isolate_template, mm_compaction_is
|
||||
TP_ARGS(nr_scanned, nr_taken)
|
||||
)
|
||||
|
||||
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,16,0))
|
||||
+#if LTTNG_KERNEL_RANGE(3,14,25, 3,15,0) || \
|
||||
+ (LINUX_VERSION_CODE >= KERNEL_VERSION(3,16,0))
|
||||
LTTNG_TRACEPOINT_EVENT(mm_compaction_migratepages,
|
||||
|
||||
TP_PROTO(unsigned long nr_all,
|
||||
--
|
||||
2.1.3
|
@ -1,21 +1,18 @@
|
||||
{ stdenv, fetchurl, kernel }:
|
||||
{ stdenv, fetchgit, kernel }:
|
||||
|
||||
assert stdenv.lib.versionAtLeast kernel.version "3.4"; # fails on 3.2
|
||||
assert builtins.substring 0 4 kernel.version != "3.12";
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "lttng-modules-${version}";
|
||||
name = "${pname}-${kernel.version}";
|
||||
version = "2.6.0-rc1"; # "git describe bf2ba318fff"
|
||||
version = "2.6.0-5-g1b2a542";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://github.com/lttng/lttng-modules/archive/v${version}.tar.gz";
|
||||
sha256 = "01gha02ybbzr86v6s6bqn649jiw5k89kb363b9s1iv8igrdlzhl1";
|
||||
src = fetchgit {
|
||||
url = "https://github.com/lttng/lttng-modules.git";
|
||||
rev = "1b2a5429de815c95643df2eadf91253909708728";
|
||||
sha256 = "0zccaiadnk0xl6xrqaqlg9rpkwjgbq2fiyc3psylzqimnx0ydxc2";
|
||||
};
|
||||
|
||||
# from upstream ML, should be in the next release
|
||||
patches = [ ./build-fix.patch ./6f0af2643c40b57280796eaa4fe60ce4f678b6dc.patch ];
|
||||
|
||||
preConfigure = ''
|
||||
export KERNELDIR="${kernel.dev}/lib/modules/${kernel.modDirVersion}/build"
|
||||
export INSTALL_MOD_PATH="$out"
|
||||
|
@ -4,11 +4,11 @@
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "slurm-llnl-${version}";
|
||||
version = "14.11.4";
|
||||
version = "14.11.5";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://www.schedmd.com/download/latest/slurm-${version}.tar.bz2";
|
||||
sha256 = "1w454j92j2fnh7xmg63275qcszq8ywiq51sm2rpyf175jrxv6ina";
|
||||
sha256 = "0xx1q9ximsyyipl0xbj8r7ajsz4xrxik8xmhcb1z9nv0aza1rff2";
|
||||
};
|
||||
|
||||
buildInputs = [ python munge perl pam openssl mysql ];
|
||||
|
@ -8,6 +8,7 @@
|
||||
, ratelimit ? false
|
||||
, recvmmsg ? false
|
||||
, rootServer ? false
|
||||
, rrtypes ? false
|
||||
, zoneStats ? false
|
||||
}:
|
||||
|
||||
@ -32,6 +33,7 @@ stdenv.mkDerivation rec {
|
||||
++ edf ratelimit "ratelimit"
|
||||
++ edf recvmmsg "recvmmsg"
|
||||
++ edf rootServer "root-server"
|
||||
++ edf rrtypes "draft-rrtypes"
|
||||
++ edf zoneStats "zone-stats"
|
||||
++ [ "--with-ssl=${openssl}" "--with-libevent=${libevent}" ];
|
||||
|
||||
|
56
pkgs/servers/monitoring/prometheus/alertmanager/default.nix
Normal file
56
pkgs/servers/monitoring/prometheus/alertmanager/default.nix
Normal file
@ -0,0 +1,56 @@
|
||||
{ stdenv, lib, goPackages, fetchFromGitHub, protobuf, vim }:
|
||||
|
||||
with goPackages;
|
||||
|
||||
buildGoPackage rec {
|
||||
name = "prometheus-alertmanager-${version}";
|
||||
version = "0.1.0";
|
||||
goPackagePath = "github.com/prometheus/alertmanager";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "prometheus";
|
||||
repo = "alertmanager";
|
||||
rev = "942cd35dea6dc406b106d7a57ffe7adbb3b978a5";
|
||||
sha256 = "1c14vgn9s0dn322ss8fs5b47blw1g8cxy9w4yjn0f7x2sdwplx1i";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
goPackages.glog
|
||||
goPackages.protobuf
|
||||
goPackages.fsnotify
|
||||
goPackages.httprouter
|
||||
goPackages.prometheus.client_golang
|
||||
goPackages.pushover
|
||||
protobuf
|
||||
vim
|
||||
];
|
||||
|
||||
buildFlagsArray = ''
|
||||
-ldflags=
|
||||
-X main.buildVersion ${version}
|
||||
-X main.buildBranch master
|
||||
-X main.buildUser nix@nixpkgs
|
||||
-X main.buildDate 20150101-00:00:00
|
||||
-X main.goVersion ${lib.getVersion go}
|
||||
'';
|
||||
|
||||
preBuild = ''
|
||||
(
|
||||
cd "go/src/$goPackagePath"
|
||||
protoc --proto_path=./config \
|
||||
--go_out=./config/generated/ \
|
||||
./config/config.proto
|
||||
cd web
|
||||
${stdenv.shell} blob/embed-static.sh static templates \
|
||||
| gofmt > blob/files.go
|
||||
)
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Alerting dispather for the Prometheus monitoring system";
|
||||
homepage = "https://github.com/prometheus/alertmanager";
|
||||
license = licenses.asl20;
|
||||
maintainers = with maintainers; [ benley ];
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
25
pkgs/servers/monitoring/prometheus/cli/default.nix
Normal file
25
pkgs/servers/monitoring/prometheus/cli/default.nix
Normal file
@ -0,0 +1,25 @@
|
||||
{ stdenv, lib, goPackages, fetchFromGitHub }:
|
||||
|
||||
goPackages.buildGoPackage rec {
|
||||
name = "prometheus-cli-0.2.0";
|
||||
goPackagePath = "github.com/prometheus/prometheus_cli";
|
||||
src = fetchFromGitHub {
|
||||
owner = "prometheus";
|
||||
repo = "prometheus_cli";
|
||||
rev = "b36c21d2301cf686bff81953573a29a6d5a0a883";
|
||||
sha256 = "190dlc6fyrfgxab4xj3gaz4jwx33jhzg57d8h36xjx56gbvp7iyk";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
goPackages.prometheus.client_model
|
||||
goPackages.prometheus.client_golang
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Command line tool for querying the Prometheus HTTP API";
|
||||
homepage = https://github.com/prometheus/prometheus_cli;
|
||||
license = licenses.asl20;
|
||||
maintainers = with maintainers; [ benley ];
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
56
pkgs/servers/monitoring/prometheus/default.nix
Normal file
56
pkgs/servers/monitoring/prometheus/default.nix
Normal file
@ -0,0 +1,56 @@
|
||||
{ stdenv, lib, goPackages, fetchFromGitHub, protobuf, vim }:
|
||||
|
||||
with goPackages;
|
||||
|
||||
buildGoPackage rec {
|
||||
name = "prometheus-${version}";
|
||||
version = "0.12.0";
|
||||
goPackagePath = "github.com/prometheus/prometheus";
|
||||
rev = "55dcb55498b43bafe94915a4de7907d6d66b4427";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "prometheus";
|
||||
repo = "prometheus";
|
||||
sha256 = "17bbdk9axr91m2947ddbnzqwaap2vrzsbknbrlpdsmlsjhc8h7cb";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
dns glog goleveldb prometheus.client_golang
|
||||
goPackages.protobuf
|
||||
protobuf # the non-golang package, for protoc
|
||||
vim # for xxd, used in embed-static.sh
|
||||
];
|
||||
|
||||
# Metadata that gets embedded into the binary
|
||||
buildFlagsArray = ''
|
||||
-ldflags=
|
||||
-X main.buildVersion ${version}
|
||||
-X main.buildRevision ${builtins.substring 0 6 rev}
|
||||
-X main.buildBranch master
|
||||
-X main.buildUser nix@nixpkgs
|
||||
-X main.buildDate 20150101-00:00:00
|
||||
-X main.goVersion ${lib.getVersion go}
|
||||
'';
|
||||
|
||||
preBuild = ''
|
||||
(
|
||||
cd "go/src/$goPackagePath"
|
||||
protoc --proto_path=./config \
|
||||
--go_out=./config/generated/ \
|
||||
./config/config.proto
|
||||
|
||||
cd web
|
||||
${stdenv.shell} ../utility/embed-static.sh static templates \
|
||||
| gofmt > blob/files.go
|
||||
)
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Service monitoring system and time series database";
|
||||
homepage = http://prometheus.github.io;
|
||||
license = licenses.asl20;
|
||||
maintainers = with maintainers; [ benley ];
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
@ -0,0 +1,23 @@
|
||||
{ stdenv, lib, goPackages, fetchFromGitHub, }:
|
||||
|
||||
goPackages.buildGoPackage rec {
|
||||
name = "prometheus-haproxy-exporter-0.4.0";
|
||||
goPackagePath = "github.com/prometheus/haproxy_exporter";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "prometheus";
|
||||
repo = "haproxy_exporter";
|
||||
rev = "6ee6d1df3e68ed73df37c9794332b2594e4da45d";
|
||||
sha256 = "0lbwv6jsdfjd9ihiky3lq7d5rkxqjh7xfaziw8i3w34a38japlpr";
|
||||
};
|
||||
|
||||
buildInputs = [ goPackages.prometheus.client_golang ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "HAProxy Exporter for the Prometheus monitoring system";
|
||||
homepage = https://github.com/prometheus/haproxy_exporter;
|
||||
license = licenses.asl20;
|
||||
maintainers = with maintainers; [ benley ];
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
@ -0,0 +1,24 @@
|
||||
{ stdenv, lib, goPackages, fetchFromGitHub }:
|
||||
|
||||
goPackages.buildGoPackage rec {
|
||||
name = "prometheus-mesos-exporter-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
rev = "a4a6638d6db6b5137e130cd4903b30dd82b78e9a";
|
||||
goPackagePath = "github.com/prometheus/mesos_exporter";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "prometheus";
|
||||
repo = "mesos_exporter";
|
||||
sha256 = "1h4yxfcr8l9i2m1s5ygk3slhxdrs4mvmpn3sq8m5s205abvp891q";
|
||||
};
|
||||
|
||||
buildInputs = [ goPackages.mesos-stats ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Export Mesos metrics to Prometheus";
|
||||
homepage = https://github.com/prometheus/mesos_exporter;
|
||||
licenses = licenses.asl20;
|
||||
maintainers = with maintainers; [ benley ];
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
32
pkgs/servers/monitoring/prometheus/node_exporter/default.nix
Normal file
32
pkgs/servers/monitoring/prometheus/node_exporter/default.nix
Normal file
@ -0,0 +1,32 @@
|
||||
{ stdenv, lib, goPackages, fetchFromGitHub }:
|
||||
|
||||
with goPackages;
|
||||
|
||||
buildGoPackage rec {
|
||||
name = "prometheus-node-exporter-0.8.0";
|
||||
goPackagePath = "github.com/prometheus/node_exporter";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "prometheus";
|
||||
repo = "node_exporter";
|
||||
rev = "aaf01e52e25883671fd67234b415df7abd0e4eac";
|
||||
sha256 = "0j1qvgsc2hcv50l9lyfivkzsyjkjp3w1yyqvd1gzfybk7hi59dya";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
glog
|
||||
go-runit
|
||||
ntp
|
||||
prometheus.client_golang
|
||||
prometheus.client_model
|
||||
protobuf
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Prometheus exporter for machine metrics";
|
||||
homepage = https://github.com/prometheus/node_exporter;
|
||||
license = licenses.asl20;
|
||||
maintainers = with maintainers; [ benley ];
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
51
pkgs/servers/monitoring/prometheus/pushgateway/default.nix
Normal file
51
pkgs/servers/monitoring/prometheus/pushgateway/default.nix
Normal file
@ -0,0 +1,51 @@
|
||||
{ stdenv, lib, goPackages, fetchFromGitHub }:
|
||||
|
||||
with goPackages;
|
||||
|
||||
buildGoPackage rec {
|
||||
name = "prometheus-pushgateway-${version}";
|
||||
version = "0.1.0";
|
||||
goPackagePath = "github.com/prometheus/pushgateway";
|
||||
rev = "3f1d42dade342ddb88381607358bae61a0a6b6c7";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "prometheus";
|
||||
repo = "pushgateway";
|
||||
sha256 = "1wqxbl9rlnxszp9ylvdbx6f5lyj2z0if3x099fnjahbqmz8yhnf4";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
go-bindata
|
||||
protobuf
|
||||
httprouter
|
||||
golang_protobuf_extensions
|
||||
prometheus.client_golang
|
||||
];
|
||||
|
||||
buildFlagsArray = ''
|
||||
-ldflags=
|
||||
-X main.buildVersion ${version}
|
||||
-X main.buildRev ${rev}
|
||||
-X main.buildBranch master
|
||||
-X main.buildUser nix@nixpkgs
|
||||
-X main.buildDate 20150101-00:00:00
|
||||
-X main.goVersion ${lib.getVersion go}
|
||||
'';
|
||||
|
||||
preBuild = ''
|
||||
(
|
||||
cd "go/src/$goPackagePath"
|
||||
go-bindata ./resources/
|
||||
)
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description =
|
||||
"Allows ephemeral and batch jobs to expose metrics to Prometheus";
|
||||
homepage = https://github.com/prometheus/pushgateway;
|
||||
license = licenses.asl20;
|
||||
maintainers = with maintainers; [ benley ];
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
27
pkgs/servers/monitoring/prometheus/statsd_bridge/default.nix
Normal file
27
pkgs/servers/monitoring/prometheus/statsd_bridge/default.nix
Normal file
@ -0,0 +1,27 @@
|
||||
{ stdenv, lib, goPackages, fetchFromGitHub }:
|
||||
|
||||
goPackages.buildGoPackage rec {
|
||||
name = "prometheus-statsd-bridge-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
rev = "9715b183150c7bed8a10affb23d33fb55c597180";
|
||||
goPackagePath = "github.com/prometheus/statsd_bridge";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "prometheus";
|
||||
repo = "statsd_bridge";
|
||||
sha256 = "119024xb08qjwbhplpl5d94bjdfhn92w4ffn4kxr7aviri1gynfz";
|
||||
};
|
||||
|
||||
buildInputs = with goPackages; [
|
||||
fsnotify
|
||||
prometheus.client_golang
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Receives StatsD-style metrics and exports them to Prometheus";
|
||||
homepage = https://github.com/prometheus/statsd_bridge;
|
||||
licenses = licenses.asl20;
|
||||
maintainers = with maintainers; [ benley ];
|
||||
platforms = platforms.unix;
|
||||
};
|
||||
}
|
@ -0,0 +1,13 @@
|
||||
diff --git a/extractor/extractor_options.cpp b/extractor/extractor_options.cpp
|
||||
index d14d8d9..c64d7fd 100644
|
||||
--- a/extractor/extractor_options.cpp
|
||||
+++ b/extractor/extractor_options.cpp
|
||||
@@ -50,7 +50,7 @@ bool ExtractorOptions::ParseArguments(int argc, char *argv[], ExtractorConfig &e
|
||||
boost::program_options::options_description config_options("Configuration");
|
||||
config_options.add_options()("profile,p",
|
||||
boost::program_options::value<boost::filesystem::path>(
|
||||
- &extractor_config.profile_path)->default_value("profile.lua"),
|
||||
+ &extractor_config.profile_path)->default_value("@out@/profiles/car.lua"),
|
||||
"Path to LUA routing profile")(
|
||||
"threads,t",
|
||||
boost::program_options::value<unsigned int>(&extractor_config.requested_num_threads)
|
18
pkgs/servers/osrm-backend/4.5.0-openmp.patch
Normal file
18
pkgs/servers/osrm-backend/4.5.0-openmp.patch
Normal file
@ -0,0 +1,18 @@
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index b6a40f9..87ca301 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -261,9 +261,10 @@ target_link_libraries(OSRM ${STXXL_LIBRARY})
|
||||
target_link_libraries(osrm-extract ${STXXL_LIBRARY})
|
||||
target_link_libraries(osrm-prepare ${STXXL_LIBRARY})
|
||||
|
||||
-if(MINGW)
|
||||
- # STXXL needs OpenMP library
|
||||
- target_link_libraries(osrm-extract gomp)
|
||||
+find_package(OpenMP)
|
||||
+if (OPENMP_FOUND)
|
||||
+ set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${OpenMP_C_FLAGS}")
|
||||
+ set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${OpenMP_CXX_FLAGS}")
|
||||
endif()
|
||||
|
||||
find_package( OSMPBF REQUIRED )
|
27
pkgs/servers/osrm-backend/default.nix
Normal file
27
pkgs/servers/osrm-backend/default.nix
Normal file
@ -0,0 +1,27 @@
|
||||
{stdenv, fetchurl, cmake, luabind, libosmpbf, stxxl, tbb, boost, expat, protobuf, bzip2, zlib, substituteAll}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "osrm-backend-4.5.0";
|
||||
|
||||
src = fetchurl {
|
||||
url = "https://github.com/Project-OSRM/osrm-backend/archive/v4.5.0.tar.gz";
|
||||
sha256 = "af61e883051f2ecb73520ace6f17cc6da30edc413208ff7cf3d87992eca0756c";
|
||||
};
|
||||
|
||||
patches = [
|
||||
./4.5.0-openmp.patch
|
||||
(substituteAll {
|
||||
src = ./4.5.0-default-profile-path.template.patch;
|
||||
})
|
||||
];
|
||||
|
||||
buildInputs = [ cmake luabind libosmpbf stxxl tbb boost expat protobuf bzip2 zlib ];
|
||||
|
||||
postInstall = "mkdir -p $out/share/osrm-backend && cp -r ../profiles $out/share/osrm-backend/profiles";
|
||||
|
||||
meta = {
|
||||
homepage = https://github.com/Project-OSRM/osrm-backend/wiki;
|
||||
description = "Open Source Routing Machine computes shortest paths in a graph. It was designed to run well with map data from the Openstreetmap Project.";
|
||||
license = stdenv.lib.licenses.bsd2;
|
||||
};
|
||||
}
|
@ -1,4 +1,4 @@
|
||||
{ stdenv, fetchurl, zlib, ncurses, readline }:
|
||||
{ stdenv, fetchurl, zlib, ncurses, readline, openssl }:
|
||||
|
||||
let version = "8.4.22"; in
|
||||
|
||||
@ -10,10 +10,12 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "09iqr9sldiq7jz1rdnywp2wv36lxy5m8kch3vpchd1s4fz75c7aw";
|
||||
};
|
||||
|
||||
buildInputs = [ zlib ncurses readline ];
|
||||
buildInputs = [ zlib ncurses readline openssl ];
|
||||
|
||||
LC_ALL = "C";
|
||||
|
||||
configureFlags = [ "--with-openssl" ];
|
||||
|
||||
patches = [ ./less-is-more.patch ];
|
||||
|
||||
passthru = { inherit readline; };
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ stdenv, fetchurl, zlib, readline }:
|
||||
{ stdenv, fetchurl, zlib, readline, openssl }:
|
||||
|
||||
let version = "9.0.19"; in
|
||||
|
||||
@ -10,10 +10,12 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "1h45jdbzdcvprdsi9gija81s3ny46h3faf9f007gza4vm6y15bak";
|
||||
};
|
||||
|
||||
buildInputs = [ zlib readline ];
|
||||
buildInputs = [ zlib readline openssl ];
|
||||
|
||||
LC_ALL = "C";
|
||||
|
||||
configureFlags = [ "--with-openssl" ];
|
||||
|
||||
patches = [ ./less-is-more.patch ];
|
||||
|
||||
passthru = {
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ stdenv, fetchurl, zlib, readline }:
|
||||
{ stdenv, fetchurl, zlib, readline, openssl }:
|
||||
|
||||
let version = "9.1.15"; in
|
||||
|
||||
@ -10,12 +10,14 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "0pyyw0cy91z9wkqf8qzkwsy8cyjps0s94c9czz6mzhyd2npxxmk7";
|
||||
};
|
||||
|
||||
buildInputs = [ zlib readline ];
|
||||
buildInputs = [ zlib readline openssl ];
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
LC_ALL = "C";
|
||||
|
||||
configureFlags = [ "--with-openssl" ];
|
||||
|
||||
patches = [ ./less-is-more.patch ];
|
||||
|
||||
postInstall =
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ stdenv, fetchurl, zlib, readline }:
|
||||
{ stdenv, fetchurl, zlib, readline, openssl }:
|
||||
|
||||
let version = "9.2.10"; in
|
||||
|
||||
@ -10,12 +10,14 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "1bbkinqzb3c8i0vfzcy2g7djrq0kxz63jgvzda9p0vylxazmnm1m";
|
||||
};
|
||||
|
||||
buildInputs = [ zlib readline ];
|
||||
buildInputs = [ zlib readline openssl ];
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
makeFlags = [ "world" ];
|
||||
|
||||
configureFlags = [ "--with-openssl" ];
|
||||
|
||||
patches = [ ./disable-resolve_symlinks.patch ./less-is-more.patch ];
|
||||
|
||||
installTargets = [ "install-world" ];
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ stdenv, fetchurl, zlib, readline, libossp_uuid }:
|
||||
{ stdenv, fetchurl, zlib, readline, libossp_uuid, openssl}:
|
||||
|
||||
with stdenv.lib;
|
||||
|
||||
@ -12,16 +12,15 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "056ass7nnfyv7blv02anv795kgpz77gipdpxggd835cdwrhwns13";
|
||||
};
|
||||
|
||||
buildInputs = [ zlib readline ] ++ optionals (!stdenv.isDarwin) [ libossp_uuid ];
|
||||
buildInputs = [ zlib readline openssl ]
|
||||
++ optionals (!stdenv.isDarwin) [ libossp_uuid ];
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
makeFlags = [ "world" ];
|
||||
|
||||
configureFlags = optional (!stdenv.isDarwin)
|
||||
''
|
||||
--with-ossp-uuid
|
||||
'';
|
||||
configureFlags = [ "--with-openssl" ]
|
||||
++ optional (!stdenv.isDarwin) "--with-ossp-uuid";
|
||||
|
||||
patches = [ ./disable-resolve_symlinks.patch ./less-is-more.patch ];
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ stdenv, fetchurl, zlib, readline, libossp_uuid }:
|
||||
{ stdenv, fetchurl, zlib, readline, libossp_uuid, openssl }:
|
||||
|
||||
with stdenv.lib;
|
||||
|
||||
@ -12,16 +12,15 @@ stdenv.mkDerivation rec {
|
||||
sha256 = "19n3i14bhmw8dacd2kl3n1wzj362qv3fjmal5vsvi580h9ybgp99";
|
||||
};
|
||||
|
||||
buildInputs = [ zlib readline ] ++ optionals (!stdenv.isDarwin) [ libossp_uuid ];
|
||||
buildInputs = [ zlib readline openssl ]
|
||||
++ optionals (!stdenv.isDarwin) [ libossp_uuid ];
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
makeFlags = [ "world" ];
|
||||
|
||||
configureFlags = optional (!stdenv.isDarwin)
|
||||
''
|
||||
--with-ossp-uuid
|
||||
'';
|
||||
configureFlags = [ "--with-openssl" ]
|
||||
++ optional (!stdenv.isDarwin) "--with-ossp-uuid";
|
||||
|
||||
patches = [ ./disable-resolve_symlinks-94.patch ./less-is-more.patch ];
|
||||
|
||||
|
@ -1,9 +0,0 @@
|
||||
''
|
||||
dontFixLibtool=1
|
||||
stripAllFlags=" " # the Darwin "strip" command doesn't know "-s"
|
||||
xargsFlags=" "
|
||||
export MACOSX_DEPLOYMENT_TARGET=10.9
|
||||
export SDKROOT=$(/usr/bin/xcrun --sdk macosx10.9 --show-sdk-path 2> /dev/null || true)
|
||||
export NIX_CFLAGS_COMPILE+=" --sysroot=/var/empty -idirafter $SDKROOT/usr/include -F$SDKROOT/System/Library/Frameworks -Wno-multichar -Wno-deprecated-declarations"
|
||||
export NIX_LDFLAGS_AFTER+=" -L$SDKROOT/usr/lib"
|
||||
''
|
@ -18,13 +18,6 @@ rec {
|
||||
export NIX_ENFORCE_PURITY=
|
||||
'';
|
||||
|
||||
prehookDarwin = ''
|
||||
${prehookBase}
|
||||
export NIX_DONT_SET_RPATH=1
|
||||
export NIX_NO_SELF_RPATH=1
|
||||
${import ../darwin/prehook.nix}
|
||||
'';
|
||||
|
||||
prehookFreeBSD = ''
|
||||
${prehookBase}
|
||||
|
||||
@ -77,7 +70,6 @@ rec {
|
||||
|
||||
import ../generic {
|
||||
preHook =
|
||||
if system == "x86_64-darwin" then prehookDarwin else
|
||||
if system == "i686-freebsd" then prehookFreeBSD else
|
||||
if system == "x86_64-freebsd" then prehookFreeBSD else
|
||||
if system == "i686-openbsd" then prehookOpenBSD else
|
||||
|
@ -3,7 +3,7 @@
|
||||
with stdenv.lib;
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "abduco-0.3";
|
||||
name = "abduco-0.4";
|
||||
|
||||
meta = {
|
||||
homepage = http://brain-dump.org/projects/abduco;
|
||||
@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://www.brain-dump.org/projects/abduco/${name}.tar.gz";
|
||||
sha256 = "1m4hafwvpnzz53n15757zrsx3xqv51gpnf3mnxqkzyr5mswz0jwk";
|
||||
sha256 = "1fxwg2s5w183p0rwzsxizy9jdnilv5qqs647l3wl3khny6fp58xx";
|
||||
};
|
||||
|
||||
configFile = optionalString (conf!=null) (writeText "config.def.h" conf);
|
||||
|
@ -1,21 +1,26 @@
|
||||
{ stdenv, fetchurl, makeWrapper, coreutils, openssh, gnupg
|
||||
{ stdenv, fetchFromGitHub, makeWrapper, coreutils, openssh, gnupg
|
||||
, procps, gnugrep, gawk, findutils, gnused }:
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "keychain-2.7.1";
|
||||
stdenv.mkDerivation rec {
|
||||
name = "keychain-${version}";
|
||||
version = "2.8.0";
|
||||
|
||||
src = fetchurl {
|
||||
url = mirror://gentoo/distfiles/keychain-2.7.1.tar.bz2;
|
||||
sha256 = "14ai6wjwnj09xnl81ar2dlr5kwb8y1k5ck6nc549shpng0zzw1qi";
|
||||
src = fetchFromGitHub {
|
||||
owner = "funtoo";
|
||||
repo = "keychain";
|
||||
rev = "1c8eaba53a7788d12d086b66ac3929810510f73a";
|
||||
sha256 = "0ajas58cv8mp5wb6hn1zhsqiwfxvx69p4f91a5j2as299rxgrxlp";
|
||||
};
|
||||
|
||||
phases = [ "unpackPhase" "buildPhase" ];
|
||||
phases = [ "unpackPhase" "patchPhase" "buildPhase" ];
|
||||
|
||||
buildInputs = [ makeWrapper ];
|
||||
|
||||
patchPhase = "sed -i -e 's,version=.*,version=\"${version}\",g' keychain.sh";
|
||||
|
||||
buildPhase = ''
|
||||
mkdir -p $out/bin
|
||||
cp keychain $out/bin
|
||||
cp keychain.sh $out/bin/keychain
|
||||
wrapProgram $out/bin/keychain \
|
||||
--prefix PATH ":" "${coreutils}/bin" \
|
||||
--prefix PATH ":" "${openssh}/bin" \
|
||||
@ -27,9 +32,9 @@ stdenv.mkDerivation {
|
||||
--prefix PATH ":" "${procps}/bin"
|
||||
'';
|
||||
|
||||
meta = {
|
||||
meta = {
|
||||
description = "Keychain management tool";
|
||||
homepage = "http://www.gentoo.org/proj/en/keychain/";
|
||||
homepage = "http://www.funtoo.org/Keychain";
|
||||
license = stdenv.lib.licenses.gpl2;
|
||||
};
|
||||
}
|
||||
|
@ -16,5 +16,6 @@ stdenv.mkDerivation {
|
||||
description = "A client for the WHOIS protocol allowing you to query the owner of a domain name";
|
||||
homepage = http://www.gnu.org/software/jwhois/;
|
||||
license = "GPL";
|
||||
platforms = stdenv.lib.platforms.linux;
|
||||
};
|
||||
}
|
||||
|
@ -5,11 +5,11 @@
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "nix-1.9pre4074_e659978";
|
||||
name = "nix-1.9pre4083_5114a07";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://hydra.nixos.org/build/20175576/download/4/${name}.tar.xz";
|
||||
sha256 = "51cafd9428cce907a735e37e5dd46f36218351175e458d0834b306d257760204";
|
||||
url = "http://hydra.nixos.org/build/20650421/download/4/${name}.tar.xz";
|
||||
sha256 = "971fdd36bcf39c7e6ce9ef12dbfe09c98d2be3275e482ca2dbacb2e668f0dff9";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ perl pkgconfig ];
|
||||
|
19
pkgs/tools/security/afl/README.md
Normal file
19
pkgs/tools/security/afl/README.md
Normal file
@ -0,0 +1,19 @@
|
||||
Updating the QEMU patches
|
||||
=========================
|
||||
|
||||
When updating to the latest American Fuzzy Lop, make sure to check for
|
||||
any new patches to qemu for binary fuzzing support:
|
||||
|
||||
https://github.com/mirrorer/afl/tree/master/qemu_mode
|
||||
|
||||
Be sure to check the build script and make sure it's also using the
|
||||
right QEMU version and options in `qemu.nix`:
|
||||
|
||||
https://github.com/mirrorer/afl/blob/master/qemu_mode/build_qemu_support.sh
|
||||
|
||||
`afl-config.h` and `afl-qemu-cpu-inl.h` are part of the afl source
|
||||
code, and copied from `config.h` and `afl-qemu-cpu-inl.h`
|
||||
appropriately. The QEMU patches need to be slightly adjusted to
|
||||
`#include` these files (the patches try to otherwise include files
|
||||
like `../../config.h` which causes the build to fail). See `qemu.nix`
|
||||
for details.
|
@ -1,16 +1,38 @@
|
||||
{ stdenv, fetchurl, bash }:
|
||||
{ stdenv, fetchurl, bash, callPackage, makeWrapper }:
|
||||
|
||||
let
|
||||
afl-qemu = callPackage ./qemu.nix {};
|
||||
qemu-exe-name = if stdenv.system == "x86_64-linux" then "qemu-x86_64"
|
||||
else if stdenv.system == "i686-linux" then "qemu-i386"
|
||||
else throw "afl: no support for ${stdenv.system}!";
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
name = "afl-${version}";
|
||||
version = "1.56b";
|
||||
version = "1.57b";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://lcamtuf.coredump.cx/afl/releases/${name}.tgz";
|
||||
sha256 = "1nagd9ycj0i1h7kx2pz07fpwy4b528inmc9hj7226qiid0bynsh4";
|
||||
sha256 = "05dwh2kgz31702y339bvbs0b3ffadxgxk8cqqhs2i0ggx5bnl5p4";
|
||||
};
|
||||
|
||||
buildInputs = [ makeWrapper ];
|
||||
|
||||
buildPhase = "make PREFIX=$out";
|
||||
installPhase = "make install PREFIX=$out";
|
||||
installPhase = ''
|
||||
# Do the normal installation
|
||||
make install PREFIX=$out
|
||||
|
||||
# Install the custom QEMU emulator for binary blob fuzzing.
|
||||
cp ${afl-qemu}/bin/${qemu-exe-name} $out/bin/afl-qemu-trace
|
||||
|
||||
# Wrap every program with a custom $AFL_PATH; I believe there is a
|
||||
# bug in afl which causes it to fail to find `afl-qemu-trace`
|
||||
# relative to `afl-fuzz` or `afl-showmap`, so we instead set
|
||||
# $AFL_PATH as a workaround, which allows it to be found.
|
||||
for x in `ls $out/bin/afl-*`; do
|
||||
wrapProgram $x --prefix AFL_PATH : "$out/bin"
|
||||
done
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "Powerful fuzzer via genetic algorithms and instrumentation";
|
||||
|
329
pkgs/tools/security/afl/qemu-patches/afl-config.h
Normal file
329
pkgs/tools/security/afl/qemu-patches/afl-config.h
Normal file
@ -0,0 +1,329 @@
|
||||
/*
|
||||
american fuzzy lop - vaguely configurable bits
|
||||
----------------------------------------------
|
||||
|
||||
Written and maintained by Michal Zalewski <lcamtuf@google.com>
|
||||
|
||||
Copyright 2013, 2014, 2015 Google Inc. All rights reserved.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at:
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
*/
|
||||
|
||||
#ifndef _HAVE_CONFIG_H
|
||||
#define _HAVE_CONFIG_H
|
||||
|
||||
#include "afl-types.h"
|
||||
|
||||
/******************************************************
|
||||
* *
|
||||
* Settings that may be of interest to power users: *
|
||||
* *
|
||||
******************************************************/
|
||||
|
||||
/* Comment out to disable terminal colors: */
|
||||
|
||||
#define USE_COLOR
|
||||
|
||||
/* Comment out to disable fancy ANSI boxes and use poor man's 7-bit UI: */
|
||||
|
||||
#define FANCY_BOXES
|
||||
|
||||
/* Default timeout for fuzzed code (milliseconds): */
|
||||
|
||||
#define EXEC_TIMEOUT 1000
|
||||
|
||||
/* Timeout rounding factor when auto-scaling (milliseconds): */
|
||||
|
||||
#define EXEC_TM_ROUND 20
|
||||
|
||||
/* Default memory limit for child process (MB): */
|
||||
|
||||
#ifndef __x86_64__
|
||||
# define MEM_LIMIT 25
|
||||
#else
|
||||
# define MEM_LIMIT 50
|
||||
#endif /* ^!__x86_64__ */
|
||||
|
||||
/* Default memory limit when running in QEMU mode (MB): */
|
||||
|
||||
#define MEM_LIMIT_QEMU 200
|
||||
|
||||
/* Number of calibration cycles per every new test case (and for test
|
||||
cases that show variable behavior): */
|
||||
|
||||
#define CAL_CYCLES 10
|
||||
#define CAL_CYCLES_LONG 40
|
||||
|
||||
/* The same, but when AFL_NO_VAR_CHECK is set in the environment: */
|
||||
|
||||
#define CAL_CYCLES_NO_VAR 4
|
||||
|
||||
/* Number of subsequent hangs before abandoning an input file: */
|
||||
|
||||
#define HANG_LIMIT 250
|
||||
|
||||
/* Maximum number of unique hangs or crashes to record: */
|
||||
|
||||
#define KEEP_UNIQUE_HANG 500
|
||||
#define KEEP_UNIQUE_CRASH 5000
|
||||
|
||||
/* Baseline number of random tweaks during a single 'havoc' stage: */
|
||||
|
||||
#define HAVOC_CYCLES 5000
|
||||
|
||||
/* Maximum multiplier for the above (should be a power of two, beware
|
||||
of 32-bit int overflows): */
|
||||
|
||||
#define HAVOC_MAX_MULT 16
|
||||
|
||||
/* Absolute minimum number of havoc cycles (after all adjustments): */
|
||||
|
||||
#define HAVOC_MIN 10
|
||||
|
||||
/* Maximum stacking for havoc-stage tweaks. The actual value is calculated
|
||||
like this:
|
||||
|
||||
n = random between 0 and HAVOC_STACK_POW2
|
||||
stacking = 2^n
|
||||
|
||||
In other words, the default (n = 7) produces 1, 2, 4, 8, 16, 32, 64, or
|
||||
128 stacked tweaks: */
|
||||
|
||||
#define HAVOC_STACK_POW2 7
|
||||
|
||||
/* Caps on block sizes for cloning and deletion operations. Each of these
|
||||
ranges has a 33% probability of getting picked, except for the first
|
||||
two cycles where smaller blocks are favored: */
|
||||
|
||||
#define HAVOC_BLK_SMALL 32
|
||||
#define HAVOC_BLK_MEDIUM 128
|
||||
#define HAVOC_BLK_LARGE 1500
|
||||
|
||||
/* Probabilities of skipping non-favored entries in the queue, expressed as
|
||||
percentages: */
|
||||
|
||||
#define SKIP_TO_NEW_PROB 99 /* ...when there are new, pending favorites */
|
||||
#define SKIP_NFAV_OLD_PROB 95 /* ...no new favs, cur entry already fuzzed */
|
||||
#define SKIP_NFAV_NEW_PROB 75 /* ...no new favs, cur entry not fuzzed yet */
|
||||
|
||||
/* Splicing cycle count: */
|
||||
|
||||
#define SPLICE_CYCLES 20
|
||||
|
||||
/* Nominal per-splice havoc cycle length: */
|
||||
|
||||
#define SPLICE_HAVOC 500
|
||||
|
||||
/* Maximum offset for integer addition / subtraction stages: */
|
||||
|
||||
#define ARITH_MAX 35
|
||||
|
||||
/* Limits for the test case trimmer. The absolute minimum chunk size; and
|
||||
the starting and ending divisors for chopping up the input file: */
|
||||
|
||||
#define TRIM_MIN_BYTES 4
|
||||
#define TRIM_START_STEPS 16
|
||||
#define TRIM_END_STEPS 1024
|
||||
|
||||
/* Maximum size of input file, in bytes (keep under 100MB): */
|
||||
|
||||
#define MAX_FILE (1 * 1024 * 1024)
|
||||
|
||||
/* The same, for the test case minimizer: */
|
||||
|
||||
#define TMIN_MAX_FILE (10 * 1024 * 1024)
|
||||
|
||||
/* Maximum dictionary token size (-x), in bytes: */
|
||||
|
||||
#define MAX_DICT_FILE 128
|
||||
|
||||
/* Length limits for auto-detected dictionary tokens: */
|
||||
|
||||
#define MIN_AUTO_EXTRA 3
|
||||
#define MAX_AUTO_EXTRA 32
|
||||
|
||||
/* Maximum number of user-specified dictionary tokens to use in deterministic
|
||||
steps; past this point, the "extras/user" step will be still carried out,
|
||||
but with proportionally lower odds: */
|
||||
|
||||
#define MAX_DET_EXTRAS 200
|
||||
|
||||
/* Maximum number of auto-extracted dictionary tokens to actually use in fuzzing
|
||||
(first value), and to keep in memory as candidates. The latter should be much
|
||||
higher than the former. */
|
||||
|
||||
#define USE_AUTO_EXTRAS 50
|
||||
#define MAX_AUTO_EXTRAS (USE_AUTO_EXTRAS * 10)
|
||||
|
||||
/* Scaling factor for the effector map used to skip some of the more
|
||||
expensive deterministic steps. The actual divisor is set to
|
||||
2^EFF_MAP_SCALE2 bytes: */
|
||||
|
||||
#define EFF_MAP_SCALE2 3
|
||||
|
||||
/* Minimum input file length at which the effector logic kicks in: */
|
||||
|
||||
#define EFF_MIN_LEN 128
|
||||
|
||||
/* Maximum effector density past which everything is just fuzzed
|
||||
unconditionally (%): */
|
||||
|
||||
#define EFF_MAX_PERC 90
|
||||
|
||||
/* UI refresh frequency (Hz): */
|
||||
|
||||
#define UI_TARGET_HZ 5
|
||||
|
||||
/* Fuzzer stats file and plot update intervals (sec): */
|
||||
|
||||
#define STATS_UPDATE_SEC 60
|
||||
#define PLOT_UPDATE_SEC 5
|
||||
|
||||
/* Smoothing divisor for CPU load and exec speed stats (1 - no smoothing). */
|
||||
|
||||
#define AVG_SMOOTHING 16
|
||||
|
||||
/* Sync interval (every n havoc cycles): */
|
||||
|
||||
#define SYNC_INTERVAL 5
|
||||
|
||||
/* Output directory reuse grace period (minutes): */
|
||||
|
||||
#define OUTPUT_GRACE 25
|
||||
|
||||
/* Uncomment to use simple file names (id_NNNNNN): */
|
||||
|
||||
// #define SIMPLE_FILES
|
||||
|
||||
/* List of interesting values to use in fuzzing. */
|
||||
|
||||
#define INTERESTING_8 \
|
||||
-128, /* Overflow signed 8-bit when decremented */ \
|
||||
-1, /* */ \
|
||||
0, /* */ \
|
||||
1, /* */ \
|
||||
16, /* One-off with common buffer size */ \
|
||||
32, /* One-off with common buffer size */ \
|
||||
64, /* One-off with common buffer size */ \
|
||||
100, /* One-off with common buffer size */ \
|
||||
127 /* Overflow signed 8-bit when incremented */
|
||||
|
||||
#define INTERESTING_16 \
|
||||
-32768, /* Overflow signed 16-bit when decremented */ \
|
||||
-129, /* Overflow signed 8-bit */ \
|
||||
128, /* Overflow signed 8-bit */ \
|
||||
255, /* Overflow unsig 8-bit when incremented */ \
|
||||
256, /* Overflow unsig 8-bit */ \
|
||||
512, /* One-off with common buffer size */ \
|
||||
1000, /* One-off with common buffer size */ \
|
||||
1024, /* One-off with common buffer size */ \
|
||||
4096, /* One-off with common buffer size */ \
|
||||
32767 /* Overflow signed 16-bit when incremented */
|
||||
|
||||
#define INTERESTING_32 \
|
||||
-2147483648LL, /* Overflow signed 32-bit when decremented */ \
|
||||
-100663046, /* Large negative number (endian-agnostic) */ \
|
||||
-32769, /* Overflow signed 16-bit */ \
|
||||
32768, /* Overflow signed 16-bit */ \
|
||||
65535, /* Overflow unsig 16-bit when incremented */ \
|
||||
65536, /* Overflow unsig 16 bit */ \
|
||||
100663045, /* Large positive number (endian-agnostic) */ \
|
||||
2147483647 /* Overflow signed 32-bit when incremented */
|
||||
|
||||
/***********************************************************
|
||||
* *
|
||||
* Really exotic stuff you probably don't want to touch: *
|
||||
* *
|
||||
***********************************************************/
|
||||
|
||||
/* Call count interval between reseeding the libc PRNG from /dev/urandom: */
|
||||
|
||||
#define RESEED_RNG 10000
|
||||
|
||||
/* Maximum line length passed from GCC to 'as': */
|
||||
|
||||
#define MAX_AS_LINE 8192
|
||||
|
||||
/* Environment variable used to pass SHM ID to the called program. */
|
||||
|
||||
#define SHM_ENV_VAR "__AFL_SHM_ID"
|
||||
|
||||
/* Other less interesting, internal-only variables. */
|
||||
|
||||
#define CLANG_ENV_VAR "__AFL_CLANG_MODE"
|
||||
#define AS_LOOP_ENV_VAR "__AFL_AS_LOOPCHECK"
|
||||
|
||||
/* Distinctive bitmap signature used to indicate failed execution: */
|
||||
|
||||
#define EXEC_FAIL_SIG 0xfee1dead
|
||||
|
||||
/* Distinctive exit code used to indicate MSAN trip condition: */
|
||||
|
||||
#define MSAN_ERROR 86
|
||||
|
||||
/* Designated file descriptors for forkserver commands (the application will
|
||||
use FORKSRV_FD and FORKSRV_FD + 1): */
|
||||
|
||||
#define FORKSRV_FD 198
|
||||
|
||||
/* Fork server init timeout multiplier: we'll wait the user-selected
|
||||
timeout plus this much for the fork server to spin up. */
|
||||
|
||||
#define FORK_WAIT_MULT 10
|
||||
|
||||
/* Calibration timeout adjustments, to be a bit more generous when resuming
|
||||
fuzzing sessions or trying to calibrate already-added internal finds.
|
||||
The first value is a percentage, the other is in milliseconds: */
|
||||
|
||||
#define CAL_TMOUT_PERC 125
|
||||
#define CAL_TMOUT_ADD 50
|
||||
|
||||
/* Number of chances to calibrate a case before giving up: */
|
||||
|
||||
#define CAL_CHANCES 3
|
||||
|
||||
/* Map size for the traced binary (2^MAP_SIZE_POW2). Must be greater than
|
||||
2; you probably want to keep it under 18 or so for performance reasons
|
||||
(adjusting AFL_INST_RATIO when compiling is probably a better way to solve
|
||||
problems with complex programs). You need to recompile the target binary
|
||||
after changing this - otherwise, SEGVs may ensue. */
|
||||
|
||||
#define MAP_SIZE_POW2 16
|
||||
#define MAP_SIZE (1 << MAP_SIZE_POW2)
|
||||
|
||||
/* Maximum allocator request size (keep well under INT_MAX): */
|
||||
|
||||
#define MAX_ALLOC 0x40000000
|
||||
|
||||
/* A made-up hashing seed: */
|
||||
|
||||
#define HASH_CONST 0xa5b35705
|
||||
|
||||
/* Constants for afl-gotcpu to control busy loop timing: */
|
||||
|
||||
#define CTEST_TARGET_MS 5000
|
||||
#define CTEST_BUSY_CYCLES (10 * 1000 * 1000)
|
||||
|
||||
/* Uncomment this to use inferior block-coverage-based instrumentation. Note
|
||||
that you need to recompile the target binary for this to have any effect: */
|
||||
|
||||
// #define COVERAGE_ONLY
|
||||
|
||||
/* Uncomment this to ignore hit counts and output just one bit per tuple.
|
||||
As with the previous setting, you will need to recompile the target
|
||||
binary: */
|
||||
|
||||
// #define SKIP_COUNTS
|
||||
|
||||
/* Uncomment this to use instrumentation data to record newly discovered paths,
|
||||
but do not use them as seeds for fuzzing. This is useful for conveniently
|
||||
measuring coverage that could be attained by a "dumb" fuzzing algorithm: */
|
||||
|
||||
// #define IGNORE_FINDS
|
||||
|
||||
#endif /* ! _HAVE_CONFIG_H */
|
287
pkgs/tools/security/afl/qemu-patches/afl-qemu-cpu-inl.h
Normal file
287
pkgs/tools/security/afl/qemu-patches/afl-qemu-cpu-inl.h
Normal file
@ -0,0 +1,287 @@
|
||||
/*
|
||||
american fuzzy lop - high-performance binary-only instrumentation
|
||||
-----------------------------------------------------------------
|
||||
|
||||
Written by Andrew Griffiths <agriffiths@google.com> and
|
||||
Michal Zalewski <lcamtuf@google.com>
|
||||
|
||||
Idea & design very much by Andrew Griffiths.
|
||||
|
||||
Copyright 2015 Google Inc. All rights reserved.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at:
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
This code is a shim patched into the separately-distributed source
|
||||
code of QEMU 2.2.0. It leverages the built-in QEMU tracing functionality
|
||||
to implement AFL-style instrumentation and to take care of the remaining
|
||||
parts of the AFL fork server logic.
|
||||
|
||||
The resulting QEMU binary is essentially a standalone instrumentation
|
||||
tool; for an example of how to leverage it for other purposes, you can
|
||||
have a look at afl-showmap.c.
|
||||
|
||||
*/
|
||||
|
||||
#include <sys/shm.h>
|
||||
#include "afl-config.h"
|
||||
|
||||
/***************************
|
||||
* VARIOUS AUXILIARY STUFF *
|
||||
***************************/
|
||||
|
||||
/* A snippet patched into tb_find_slow to inform the parent process that
|
||||
we have hit a new block that hasn't been translated yet, and to tell
|
||||
it to translate within its own context, too (this avoids translation
|
||||
overhead in the next forked-off copy). */
|
||||
|
||||
#define AFL_QEMU_CPU_SNIPPET1 do { \
|
||||
afl_request_tsl(pc, cs_base, flags); \
|
||||
} while (0)
|
||||
|
||||
/* This snippet kicks in when the instruction pointer is positioned at
|
||||
_start and does the usual forkserver stuff, not very different from
|
||||
regular instrumentation injected via afl-as.h. */
|
||||
|
||||
#define AFL_QEMU_CPU_SNIPPET2 do { \
|
||||
if(tb->pc == afl_entry_point) { \
|
||||
afl_setup(); \
|
||||
afl_forkserver(env); \
|
||||
} \
|
||||
afl_maybe_log(tb->pc); \
|
||||
} while (0)
|
||||
|
||||
/* We use one additional file descriptor to relay "needs translation"
|
||||
messages between the child and the fork server. */
|
||||
|
||||
#define TSL_FD (FORKSRV_FD - 1)
|
||||
|
||||
/* This is equivalent to afl-as.h: */
|
||||
|
||||
static unsigned char *afl_area_ptr;
|
||||
|
||||
/* Exported variables populated by the code patched into elfload.c: */
|
||||
|
||||
abi_ulong afl_entry_point, /* ELF entry point (_start) */
|
||||
afl_start_code, /* .text start pointer */
|
||||
afl_end_code; /* .text end pointer */
|
||||
|
||||
/* Set on the child in forkserver mode: */
|
||||
|
||||
static unsigned char afl_fork_child;
|
||||
|
||||
/* Instrumentation ratio: */
|
||||
|
||||
static unsigned int afl_inst_rms = MAP_SIZE;
|
||||
|
||||
/* Function declarations. */
|
||||
|
||||
static void afl_setup(void);
|
||||
static void afl_forkserver(CPUArchState*);
|
||||
static inline void afl_maybe_log(abi_ulong);
|
||||
|
||||
static void afl_wait_tsl(CPUArchState*, int);
|
||||
static void afl_request_tsl(target_ulong, target_ulong, uint64_t);
|
||||
|
||||
static TranslationBlock *tb_find_slow(CPUArchState*, target_ulong,
|
||||
target_ulong, uint64_t);
|
||||
|
||||
|
||||
/* Data structure passed around by the translate handlers: */
|
||||
|
||||
struct afl_tsl {
|
||||
target_ulong pc;
|
||||
target_ulong cs_base;
|
||||
uint64_t flags;
|
||||
};
|
||||
|
||||
|
||||
/*************************
|
||||
* ACTUAL IMPLEMENTATION *
|
||||
*************************/
|
||||
|
||||
|
||||
/* Set up SHM region and initialize other stuff. */
|
||||
|
||||
static void afl_setup(void) {
|
||||
|
||||
char *id_str = getenv(SHM_ENV_VAR),
|
||||
*inst_r = getenv("AFL_INST_RATIO");
|
||||
|
||||
int shm_id;
|
||||
|
||||
if (inst_r) {
|
||||
|
||||
unsigned int r;
|
||||
|
||||
r = atoi(inst_r);
|
||||
|
||||
if (r > 100) r = 100;
|
||||
if (!r) r = 1;
|
||||
|
||||
afl_inst_rms = MAP_SIZE * r / 100;
|
||||
|
||||
}
|
||||
|
||||
if (id_str) {
|
||||
|
||||
shm_id = atoi(id_str);
|
||||
afl_area_ptr = shmat(shm_id, NULL, 0);
|
||||
|
||||
if (afl_area_ptr == (void*)-1) exit(1);
|
||||
|
||||
}
|
||||
|
||||
if (getenv("AFL_INST_LIBS")) {
|
||||
|
||||
afl_start_code = 0;
|
||||
afl_end_code = (abi_ulong)-1;
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
/* Fork server logic, invoked once we hit _start. */
|
||||
|
||||
static void afl_forkserver(CPUArchState *env) {
|
||||
|
||||
static unsigned char tmp[4];
|
||||
|
||||
if (!afl_area_ptr) return;
|
||||
|
||||
/* Tell the parent that we're alive. If the parent doesn't want
|
||||
to talk, assume that we're not running in forkserver mode. */
|
||||
|
||||
if (write(FORKSRV_FD + 1, tmp, 4) != 4) return;
|
||||
|
||||
/* All right, let's await orders... */
|
||||
|
||||
while (1) {
|
||||
|
||||
pid_t child_pid;
|
||||
int status, t_fd[2];
|
||||
|
||||
/* Whoops, parent dead? */
|
||||
|
||||
if (read(FORKSRV_FD, tmp, 4) != 4) exit(2);
|
||||
|
||||
/* Establish a channel with child to grab translation commands. We'll
|
||||
read from t_fd[0], child will write to TSL_FD. */
|
||||
|
||||
if (pipe(t_fd) || dup2(t_fd[1], TSL_FD) < 0) exit(3);
|
||||
close(t_fd[1]);
|
||||
|
||||
child_pid = fork();
|
||||
if (child_pid < 0) exit(4);
|
||||
|
||||
if (!child_pid) {
|
||||
|
||||
/* Child process. Close descriptors and run free. */
|
||||
|
||||
afl_fork_child = 1;
|
||||
close(FORKSRV_FD);
|
||||
close(FORKSRV_FD + 1);
|
||||
close(t_fd[0]);
|
||||
return;
|
||||
|
||||
}
|
||||
|
||||
/* Parent. */
|
||||
|
||||
close(TSL_FD);
|
||||
|
||||
if (write(FORKSRV_FD + 1, &child_pid, 4) != 4) exit(5);
|
||||
|
||||
/* Collect translation requests until child dies and closes the pipe. */
|
||||
|
||||
afl_wait_tsl(env, t_fd[0]);
|
||||
|
||||
/* Get and relay exit status to parent. */
|
||||
|
||||
if (waitpid(child_pid, &status, WUNTRACED) < 0) exit(6);
|
||||
if (write(FORKSRV_FD + 1, &status, 4) != 4) exit(7);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
/* The equivalent of the tuple logging routine from afl-as.h. */
|
||||
|
||||
static inline void afl_maybe_log(abi_ulong cur_loc) {
|
||||
|
||||
static abi_ulong prev_loc;
|
||||
|
||||
/* Optimize for cur_loc > afl_end_code, which is the most likely case on
|
||||
Linux systems. */
|
||||
|
||||
if (cur_loc > afl_end_code || cur_loc < afl_start_code || !afl_area_ptr)
|
||||
return;
|
||||
|
||||
/* Looks like QEMU always maps to fixed locations, so we can skip this:
|
||||
cur_loc -= afl_start_code; */
|
||||
|
||||
/* Instruction addresses may be aligned. Let's mangle the value to get
|
||||
something quasi-uniform. */
|
||||
|
||||
cur_loc = (cur_loc >> 4) ^ (cur_loc << 8);
|
||||
cur_loc &= MAP_SIZE - 1;
|
||||
|
||||
/* Implement probabilistic instrumentation by looking at scrambled block
|
||||
address. This keeps the instrumented locations stable across runs. */
|
||||
|
||||
if (cur_loc >= afl_inst_rms) return;
|
||||
|
||||
afl_area_ptr[cur_loc ^ prev_loc]++;
|
||||
prev_loc = cur_loc >> 1;
|
||||
|
||||
}
|
||||
|
||||
|
||||
/* This code is invoked whenever QEMU decides that it doesn't have a
|
||||
translation of a particular block and needs to compute it. When this happens,
|
||||
we tell the parent to mirror the operation, so that the next fork() has a
|
||||
cached copy. */
|
||||
|
||||
static void afl_request_tsl(target_ulong pc, target_ulong cb, uint64_t flags) {
|
||||
|
||||
struct afl_tsl t;
|
||||
|
||||
if (!afl_fork_child) return;
|
||||
|
||||
t.pc = pc;
|
||||
t.cs_base = cb;
|
||||
t.flags = flags;
|
||||
|
||||
if (write(TSL_FD, &t, sizeof(struct afl_tsl)) != sizeof(struct afl_tsl))
|
||||
return;
|
||||
|
||||
}
|
||||
|
||||
|
||||
/* This is the other side of the same channel. Since timeouts are handled by
|
||||
afl-fuzz simply killing the child, we can just wait until the pipe breaks. */
|
||||
|
||||
static void afl_wait_tsl(CPUArchState *env, int fd) {
|
||||
|
||||
struct afl_tsl t;
|
||||
|
||||
while (1) {
|
||||
|
||||
/* Broken pipe means it's time to return to the fork server routine. */
|
||||
|
||||
if (read(fd, &t, sizeof(struct afl_tsl)) != sizeof(struct afl_tsl))
|
||||
break;
|
||||
|
||||
tb_find_slow(env, t.pc, t.cs_base, t.flags);
|
||||
|
||||
}
|
||||
|
||||
close(fd);
|
||||
|
||||
}
|
||||
|
79
pkgs/tools/security/afl/qemu-patches/afl-types.h
Normal file
79
pkgs/tools/security/afl/qemu-patches/afl-types.h
Normal file
@ -0,0 +1,79 @@
|
||||
/*
|
||||
american fuzzy lop - type definitions and minor macros
|
||||
------------------------------------------------------
|
||||
|
||||
Written and maintained by Michal Zalewski <lcamtuf@google.com>
|
||||
|
||||
Copyright 2013, 2014, 2015 Google Inc. All rights reserved.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at:
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
*/
|
||||
|
||||
#ifndef _HAVE_TYPES_H
|
||||
#define _HAVE_TYPES_H
|
||||
|
||||
#include <stdint.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
typedef uint8_t u8;
|
||||
typedef uint16_t u16;
|
||||
typedef uint32_t u32;
|
||||
|
||||
/*
|
||||
|
||||
Ugh. There is an unintended compiler / glibc #include glitch caused by
|
||||
combining the u64 type an %llu in format strings, necessitating a workaround.
|
||||
|
||||
In essence, the compiler is always looking for 'unsigned long long' for %llu.
|
||||
On 32-bit systems, the u64 type (aliased to uint64_t) is expanded to
|
||||
'unsigned long long' in <bits/types.h>, so everything checks out.
|
||||
|
||||
But on 64-bit systems, it is #ifdef'ed in the same file as 'unsigned long'.
|
||||
Now, it only happens in circumstances where the type happens to have the
|
||||
expected bit width, *but* the compiler does not know that... and complains
|
||||
about 'unsigned long' being unsafe to pass to %llu.
|
||||
|
||||
*/
|
||||
|
||||
#ifdef __x86_64__
|
||||
typedef unsigned long long u64;
|
||||
#else
|
||||
typedef uint64_t u64;
|
||||
#endif /* ^sizeof(...) */
|
||||
|
||||
typedef int8_t s8;
|
||||
typedef int16_t s16;
|
||||
typedef int32_t s32;
|
||||
typedef int64_t s64;
|
||||
|
||||
#ifndef MIN
|
||||
# define MIN(_a,_b) ((_a) > (_b) ? (_b) : (_a))
|
||||
# define MAX(_a,_b) ((_a) > (_b) ? (_a) : (_b))
|
||||
#endif /* !MIN */
|
||||
|
||||
#define SWAP16(_x) ({ \
|
||||
u16 _ret = (_x); \
|
||||
(u16)((_ret << 8) | (_ret >> 8)); \
|
||||
})
|
||||
|
||||
#define SWAP32(_x) ({ \
|
||||
u32 _ret = (_x); \
|
||||
(u32)((_ret << 24) | (_ret >> 24) | \
|
||||
((_ret << 8) & 0x00FF0000) | \
|
||||
((_ret >> 8) & 0x0000FF00)); \
|
||||
})
|
||||
|
||||
#define R(x) (random() % (x))
|
||||
|
||||
#define STRINGIFY_INTERNAL(x) #x
|
||||
#define STRINGIFY(x) STRINGIFY_INTERNAL(x)
|
||||
|
||||
#define MEM_BARRIER() \
|
||||
asm volatile("" ::: "memory")
|
||||
|
||||
#endif /* ! _HAVE_TYPES_H */
|
33
pkgs/tools/security/afl/qemu-patches/cpu-exec.patch
Normal file
33
pkgs/tools/security/afl/qemu-patches/cpu-exec.patch
Normal file
@ -0,0 +1,33 @@
|
||||
--- qemu-2.2.0/cpu-exec.c.orig 2014-12-09 14:45:40.000000000 +0000
|
||||
+++ qemu-2.2.0/cpu-exec.c 2015-02-20 22:07:02.966000000 +0000
|
||||
@@ -25,6 +25,8 @@
|
||||
#include "sysemu/qtest.h"
|
||||
#include "qemu/timer.h"
|
||||
|
||||
+#include "afl-qemu-cpu-inl.h"
|
||||
+
|
||||
/* -icount align implementation. */
|
||||
|
||||
typedef struct SyncClocks {
|
||||
@@ -262,8 +264,11 @@
|
||||
}
|
||||
not_found:
|
||||
/* if no translated code available, then translate it now */
|
||||
+
|
||||
tb = tb_gen_code(cpu, pc, cs_base, flags, 0);
|
||||
|
||||
+ AFL_QEMU_CPU_SNIPPET1;
|
||||
+
|
||||
found:
|
||||
/* Move the last found TB to the head of the list */
|
||||
if (likely(*ptb1)) {
|
||||
@@ -455,6 +460,9 @@
|
||||
next_tb = 0;
|
||||
tcg_ctx.tb_ctx.tb_invalidated_flag = 0;
|
||||
}
|
||||
+
|
||||
+ AFL_QEMU_CPU_SNIPPET2;
|
||||
+
|
||||
if (qemu_loglevel_mask(CPU_LOG_EXEC)) {
|
||||
qemu_log("Trace %p [" TARGET_FMT_lx "] %s\n",
|
||||
tb->tc_ptr, tb->pc, lookup_symbol(tb->pc));
|
32
pkgs/tools/security/afl/qemu-patches/elfload.patch
Normal file
32
pkgs/tools/security/afl/qemu-patches/elfload.patch
Normal file
@ -0,0 +1,32 @@
|
||||
--- qemu-2.2.0/linux-user/elfload.c.orig 2014-12-09 14:45:42.000000000 +0000
|
||||
+++ qemu-2.2.0/linux-user/elfload.c 2015-01-28 02:51:23.719000000 +0000
|
||||
@@ -28,6 +28,8 @@
|
||||
|
||||
#define ELF_OSABI ELFOSABI_SYSV
|
||||
|
||||
+extern abi_ulong afl_entry_point, afl_start_code, afl_end_code;
|
||||
+
|
||||
/* from personality.h */
|
||||
|
||||
/*
|
||||
@@ -1886,6 +1888,8 @@
|
||||
info->brk = 0;
|
||||
info->elf_flags = ehdr->e_flags;
|
||||
|
||||
+ if (!afl_entry_point) afl_entry_point = info->entry;
|
||||
+
|
||||
for (i = 0; i < ehdr->e_phnum; i++) {
|
||||
struct elf_phdr *eppnt = phdr + i;
|
||||
if (eppnt->p_type == PT_LOAD) {
|
||||
@@ -1919,9 +1923,11 @@
|
||||
if (elf_prot & PROT_EXEC) {
|
||||
if (vaddr < info->start_code) {
|
||||
info->start_code = vaddr;
|
||||
+ if (!afl_start_code) afl_start_code = vaddr;
|
||||
}
|
||||
if (vaddr_ef > info->end_code) {
|
||||
info->end_code = vaddr_ef;
|
||||
+ if (!afl_end_code) afl_end_code = vaddr_ef;
|
||||
}
|
||||
}
|
||||
if (elf_prot & PROT_WRITE) {
|
14
pkgs/tools/security/afl/qemu-patches/no-etc-install.patch
Normal file
14
pkgs/tools/security/afl/qemu-patches/no-etc-install.patch
Normal file
@ -0,0 +1,14 @@
|
||||
diff --git a/Makefile b/Makefile
|
||||
index d6b9dc1..ce7c493 100644
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -384,8 +384,7 @@ install-confdir:
|
||||
install-sysconfig: install-datadir install-confdir
|
||||
$(INSTALL_DATA) $(SRC_PATH)/sysconfigs/target/target-x86_64.conf "$(DESTDIR)$(qemu_confdir)"
|
||||
|
||||
-install: all $(if $(BUILD_DOCS),install-doc) install-sysconfig \
|
||||
-install-datadir install-localstatedir
|
||||
+install: all $(if $(BUILD_DOCS),install-doc) install-datadir
|
||||
ifneq ($(TOOLS),)
|
||||
$(call install-prog,$(TOOLS),$(DESTDIR)$(bindir))
|
||||
endif
|
18
pkgs/tools/security/afl/qemu-patches/translate-all.patch
Normal file
18
pkgs/tools/security/afl/qemu-patches/translate-all.patch
Normal file
@ -0,0 +1,18 @@
|
||||
--- qemu-2.2.0/translate-all.c.orig 2014-12-09 14:45:46.000000000 +0000
|
||||
+++ qemu-2.2.0/translate-all.c 2015-01-28 22:37:42.383000000 +0000
|
||||
@@ -387,8 +387,13 @@
|
||||
/* We can't use g_malloc because it may recurse into a locked mutex. */
|
||||
# define ALLOC(P, SIZE) \
|
||||
do { \
|
||||
- P = mmap(NULL, SIZE, PROT_READ | PROT_WRITE, \
|
||||
- MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); \
|
||||
+ void* _tmp = mmap(NULL, SIZE, PROT_READ | PROT_WRITE, \
|
||||
+ MAP_PRIVATE | MAP_ANONYMOUS, -1, 0); \
|
||||
+ if (_tmp == (void*)-1) { \
|
||||
+ qemu_log(">>> Out of memory for stack, bailing out. <<<\n"); \
|
||||
+ exit(1); \
|
||||
+ } \
|
||||
+ (P) = _tmp; \
|
||||
} while (0)
|
||||
#else
|
||||
# define ALLOC(P, SIZE) \
|
72
pkgs/tools/security/afl/qemu.nix
Normal file
72
pkgs/tools/security/afl/qemu.nix
Normal file
@ -0,0 +1,72 @@
|
||||
{ stdenv, fetchurl, python, zlib, pkgconfig, glib, ncurses, perl
|
||||
, attr, libcap, vde2, alsaLib, texinfo, libuuid, flex, bison, lzo, snappy
|
||||
, libaio, libcap_ng, gnutls, pixman, autoconf
|
||||
, writeText
|
||||
}:
|
||||
|
||||
with stdenv.lib;
|
||||
|
||||
let
|
||||
n = "qemu-2.2.0";
|
||||
|
||||
aflHeaderFile = writeText "afl-qemu-cpu-inl.h"
|
||||
(builtins.readFile ./qemu-patches/afl-qemu-cpu-inl.h);
|
||||
aflConfigFile = writeText "afl-config.h"
|
||||
(builtins.readFile ./qemu-patches/afl-config.h);
|
||||
aflTypesFile = writeText "afl-types.h"
|
||||
(builtins.readFile ./qemu-patches/afl-types.h);
|
||||
|
||||
cpuTarget = if stdenv.system == "x86_64-linux" then "x86_64-linux-user"
|
||||
else if stdenv.system == "i686-linux" then "i386-linux-user"
|
||||
else throw "afl: no support for ${stdenv.system}!";
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
name = "afl-${n}";
|
||||
|
||||
src = fetchurl {
|
||||
url = "http://wiki.qemu.org/download/${n}.tar.bz2";
|
||||
sha256 = "1703c3scl5n07gmpilg7g2xzyxnr7jczxgx6nn4m8kv9gin9p35n";
|
||||
};
|
||||
|
||||
buildInputs =
|
||||
[ python zlib pkgconfig glib pixman ncurses perl attr libcap
|
||||
vde2 texinfo libuuid flex bison lzo snappy autoconf
|
||||
libcap_ng gnutls
|
||||
]
|
||||
++ optionals (hasSuffix "linux" stdenv.system) [ libaio ];
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
patches =
|
||||
[ ./qemu-patches/elfload.patch
|
||||
./qemu-patches/cpu-exec.patch
|
||||
./qemu-patches/no-etc-install.patch
|
||||
./qemu-patches/translate-all.patch
|
||||
];
|
||||
|
||||
preConfigure = ''
|
||||
cp ${aflTypesFile} afl-types.h
|
||||
cp ${aflConfigFile} afl-config.h
|
||||
cp ${aflHeaderFile} afl-qemu-cpu-inl.h
|
||||
'';
|
||||
|
||||
configureFlags =
|
||||
[ "--disable-system"
|
||||
"--enable-linux-user"
|
||||
"--enable-guest-base"
|
||||
"--disable-gtk"
|
||||
"--disable-sdl"
|
||||
"--disable-vnc"
|
||||
"--target-list=${cpuTarget}"
|
||||
"--sysconfdir=/etc"
|
||||
"--localstatedir=/var"
|
||||
];
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
homepage = http://www.qemu.org/;
|
||||
description = "Fork of QEMU with American Fuzzy Lop instrumentation support";
|
||||
license = licenses.gpl2Plus;
|
||||
maintainers = with maintainers; [ thoughtpolice ];
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
@ -2293,7 +2293,6 @@ let
|
||||
pitivi = callPackage ../applications/video/pitivi {
|
||||
gst = gst_all_1;
|
||||
clutter-gtk = clutter_gtk;
|
||||
inherit (gnome3) gnome_icon_theme gnome_icon_theme_symbolic;
|
||||
};
|
||||
|
||||
p0f = callPackage ../tools/security/p0f { };
|
||||
@ -4252,8 +4251,7 @@ let
|
||||
opam_1_1 = callPackage ../development/tools/ocaml/opam/1.1.nix {
|
||||
inherit (ocamlPackages_4_01_0) ocaml;
|
||||
};
|
||||
opam_1_2_0 = callPackage ../development/tools/ocaml/opam/1.2.0.nix { };
|
||||
opam = opam_1_2_0;
|
||||
opam = callPackage ../development/tools/ocaml/opam { };
|
||||
|
||||
ocamlnat = let callPackage = newScope pkgs.ocamlPackages_3_12_1; in callPackage ../development/ocaml-modules/ocamlnat { };
|
||||
|
||||
@ -5030,6 +5028,7 @@ let
|
||||
gnumake380 = callPackage ../development/tools/build-managers/gnumake/3.80 { };
|
||||
gnumake381 = callPackage ../development/tools/build-managers/gnumake/3.81 { };
|
||||
gnumake382 = callPackage ../development/tools/build-managers/gnumake/3.82 { };
|
||||
gnumake3 = gnumake382;
|
||||
gnumake40 = callPackage ../development/tools/build-managers/gnumake/4.0 { };
|
||||
gnumake41 = callPackage ../development/tools/build-managers/gnumake/4.1 { };
|
||||
gnumake = gnumake41;
|
||||
@ -6107,7 +6106,9 @@ let
|
||||
python = python2;
|
||||
};
|
||||
|
||||
lensfun = callPackage ../development/libraries/lensfun { };
|
||||
lensfun = callPackage ../development/libraries/lensfun {
|
||||
inherit gnumake3;
|
||||
};
|
||||
|
||||
lesstif = callPackage ../development/libraries/lesstif { };
|
||||
|
||||
@ -6599,6 +6600,8 @@ let
|
||||
|
||||
libosip_3 = callPackage ../development/libraries/osip/3.nix {};
|
||||
|
||||
libosmpbf = callPackage ../development/libraries/libosmpbf {};
|
||||
|
||||
libotr = callPackage ../development/libraries/libotr {
|
||||
libgcrypt = libgcrypt_1_6;
|
||||
};
|
||||
@ -6862,6 +6865,10 @@ let
|
||||
|
||||
loudmouth = callPackage ../development/libraries/loudmouth { };
|
||||
|
||||
luabind = callPackage ../development/libraries/luabind { lua = lua5_1; };
|
||||
|
||||
luabind_luajit = callPackage ../development/libraries/luabind { lua = luajit; };
|
||||
|
||||
lzo = callPackage ../development/libraries/lzo { };
|
||||
|
||||
matio = callPackage ../development/libraries/matio { };
|
||||
@ -7439,6 +7446,8 @@ let
|
||||
|
||||
srtp_linphone = callPackage ../development/libraries/srtp/linphone.nix { };
|
||||
|
||||
stxxl = callPackage ../development/libraries/stxxl { parallel = true; };
|
||||
|
||||
sqlite = lowPrio (callPackage ../development/libraries/sqlite { });
|
||||
|
||||
sqlite-interactive = appendToName "interactive" (sqlite.override { interactive = true; });
|
||||
@ -8242,6 +8251,10 @@ let
|
||||
|
||||
opensmtpd = callPackage ../servers/mail/opensmtpd { };
|
||||
|
||||
osrm-backend = callPackage ../servers/osrm-backend { };
|
||||
|
||||
osrm-backend_luajit = callPackage ../servers/osrm-backend { luabind = luabind_luajit; };
|
||||
|
||||
petidomo = callPackage ../servers/mail/petidomo { };
|
||||
|
||||
popa3d = callPackage ../servers/mail/popa3d { };
|
||||
@ -8361,6 +8374,22 @@ let
|
||||
|
||||
postgresql_jdbc = callPackage ../servers/sql/postgresql/jdbc { };
|
||||
|
||||
prometheus = callPackage ../servers/monitoring/prometheus { };
|
||||
prometheus-alertmanager =
|
||||
callPackage ../servers/monitoring/prometheus/alertmanager { };
|
||||
prometheus-cli =
|
||||
callPackage ../servers/monitoring/prometheus/cli { };
|
||||
prometheus-haproxy-exporter =
|
||||
callPackage ../servers/monitoring/prometheus/haproxy_exporter { };
|
||||
prometheus-mesos-exporter =
|
||||
callPackage ../servers/monitoring/prometheus/mesos_exporter { };
|
||||
prometheus-node-exporter =
|
||||
callPackage ../servers/monitoring/prometheus/node_exporter { };
|
||||
prometheus-pushgateway =
|
||||
callPackage ../servers/monitoring/prometheus/pushgateway { };
|
||||
prometheus-statsd-bridge =
|
||||
callPackage ../servers/monitoring/prometheus/statsd_bridge { };
|
||||
|
||||
psqlodbc = callPackage ../servers/sql/postgresql/psqlodbc { };
|
||||
|
||||
pyIRCt = builderDefsPackage (import ../servers/xmpp/pyIRCt) {
|
||||
@ -11469,6 +11498,8 @@ let
|
||||
automake = automake114x;
|
||||
};
|
||||
|
||||
rstudio = callPackage ../applications/editors/rstudio { };
|
||||
|
||||
rsync = callPackage ../applications/networking/sync/rsync {
|
||||
enableACLs = !(stdenv.isDarwin || stdenv.isSunOS || stdenv.isFreeBSD);
|
||||
enableCopyDevicesPatch = (config.rsync.enableCopyDevicesPatch or false);
|
||||
@ -12796,187 +12827,201 @@ let
|
||||
|
||||
kde4 = recurseIntoAttrs pkgs.kde414;
|
||||
|
||||
kde414 = kdePackagesFor (pkgs.kde414 // {
|
||||
libusb = libusb1;
|
||||
libcanberra = libcanberra_kde;
|
||||
boost = boost156;
|
||||
}) ../desktops/kde-4.14;
|
||||
|
||||
kdePackagesFor = self: dir:
|
||||
let callPackageOrig = newScope {}; in
|
||||
let
|
||||
callPackage = newScope self;
|
||||
kde4 = callPackageOrig dir {
|
||||
inherit callPackage callPackageOrig;
|
||||
kde414 =
|
||||
kdePackagesFor
|
||||
{
|
||||
libusb = libusb1;
|
||||
libcanberra = libcanberra_kde;
|
||||
boost = boost156;
|
||||
kdelibs = kdeApps_stable.kdelibs;
|
||||
};
|
||||
in kde4 // {
|
||||
inherit kde4;
|
||||
}
|
||||
../desktops/kde-4.14;
|
||||
|
||||
wrapper = callPackage ../build-support/kdewrapper {};
|
||||
|
||||
recurseForRelease = true;
|
||||
kdePackagesFor = extra: dir:
|
||||
let
|
||||
# list of extra packages not included in KDE
|
||||
# the real work in this function is done below this list
|
||||
extraPackages = callPackage:
|
||||
rec {
|
||||
amarok = callPackage ../applications/audio/amarok { };
|
||||
|
||||
amarok = callPackage ../applications/audio/amarok { };
|
||||
bangarang = callPackage ../applications/video/bangarang { };
|
||||
|
||||
bangarang = callPackage ../applications/video/bangarang { };
|
||||
basket = callPackage ../applications/office/basket { };
|
||||
|
||||
basket = callPackage ../applications/office/basket { };
|
||||
bluedevil = callPackage ../tools/bluetooth/bluedevil { };
|
||||
|
||||
bluedevil = callPackage ../tools/bluetooth/bluedevil { };
|
||||
calligra = callPackage ../applications/office/calligra { eigen = eigen2; };
|
||||
|
||||
calligra = callPackage ../applications/office/calligra { eigen = eigen2; };
|
||||
choqok = callPackage ../applications/networking/instant-messengers/choqok { };
|
||||
|
||||
choqok = callPackage ../applications/networking/instant-messengers/choqok { };
|
||||
colord-kde = callPackage ../tools/misc/colord-kde { };
|
||||
|
||||
colord-kde = callPackage ../tools/misc/colord-kde { };
|
||||
digikam = if builtins.compareVersions "4.9" kde4.release == 1 then
|
||||
callPackage ../applications/graphics/digikam/2.nix { }
|
||||
else
|
||||
callPackage ../applications/graphics/digikam { };
|
||||
|
||||
digikam = if builtins.compareVersions "4.9" kde4.release == 1 then
|
||||
callPackage ../applications/graphics/digikam/2.nix { }
|
||||
else
|
||||
callPackage ../applications/graphics/digikam { };
|
||||
eventlist = callPackage ../applications/office/eventlist {};
|
||||
|
||||
eventlist = callPackage ../applications/office/eventlist {};
|
||||
k3b = callPackage ../applications/misc/k3b {
|
||||
cdrtools = cdrkit;
|
||||
};
|
||||
|
||||
k3b = callPackage ../applications/misc/k3b {
|
||||
cdrtools = cdrkit;
|
||||
};
|
||||
kadu = callPackage ../applications/networking/instant-messengers/kadu { };
|
||||
|
||||
kadu = callPackage ../applications/networking/instant-messengers/kadu { };
|
||||
kbibtex = callPackage ../applications/office/kbibtex { };
|
||||
|
||||
kbibtex = callPackage ../applications/office/kbibtex { };
|
||||
kde_gtk_config = callPackage ../tools/misc/kde-gtk-config { };
|
||||
|
||||
kde_gtk_config = callPackage ../tools/misc/kde-gtk-config { };
|
||||
kde_wacomtablet = callPackage ../applications/misc/kde-wacomtablet { };
|
||||
|
||||
kde_wacomtablet = callPackage ../applications/misc/kde-wacomtablet { };
|
||||
kdeconnect = callPackage ../applications/misc/kdeconnect { };
|
||||
|
||||
kdeconnect = callPackage ../applications/misc/kdeconnect { };
|
||||
kdenlive = callPackage ../applications/video/kdenlive { mlt = mlt-qt4; };
|
||||
|
||||
kdenlive = callPackage ../applications/video/kdenlive { mlt = mlt-qt4; };
|
||||
kdesvn = callPackage ../applications/version-management/kdesvn { };
|
||||
|
||||
kdesvn = callPackage ../applications/version-management/kdesvn { };
|
||||
kdevelop = callPackage ../applications/editors/kdevelop { };
|
||||
|
||||
kdevelop = callPackage ../applications/editors/kdevelop { };
|
||||
kdevplatform = callPackage ../development/libraries/kdevplatform {
|
||||
boost = boost156;
|
||||
};
|
||||
|
||||
kdevplatform = callPackage ../development/libraries/kdevplatform {
|
||||
boost = boost156;
|
||||
};
|
||||
kdiff3 = callPackage ../tools/text/kdiff3 { };
|
||||
|
||||
kdiff3 = callPackage ../tools/text/kdiff3 { };
|
||||
kgraphviewer = callPackage ../applications/graphics/kgraphviewer { };
|
||||
|
||||
kgraphviewer = callPackage ../applications/graphics/kgraphviewer { };
|
||||
kile = callPackage ../applications/editors/kile { };
|
||||
|
||||
kile = callPackage ../applications/editors/kile { };
|
||||
kmplayer = callPackage ../applications/video/kmplayer { };
|
||||
|
||||
kmplayer = callPackage ../applications/video/kmplayer { };
|
||||
kmymoney = callPackage ../applications/office/kmymoney { };
|
||||
|
||||
kmymoney = callPackage ../applications/office/kmymoney { };
|
||||
kipi_plugins = callPackage ../applications/graphics/kipi-plugins { };
|
||||
|
||||
kipi_plugins = callPackage ../applications/graphics/kipi-plugins { };
|
||||
konversation = callPackage ../applications/networking/irc/konversation { };
|
||||
|
||||
konversation = callPackage ../applications/networking/irc/konversation { };
|
||||
kvirc = callPackage ../applications/networking/irc/kvirc { };
|
||||
|
||||
kvirc = callPackage ../applications/networking/irc/kvirc { };
|
||||
krename = callPackage ../applications/misc/krename { };
|
||||
|
||||
krename = callPackage ../applications/misc/krename { };
|
||||
krusader = callPackage ../applications/misc/krusader { };
|
||||
|
||||
krusader = callPackage ../applications/misc/krusader { };
|
||||
ksshaskpass = callPackage ../tools/security/ksshaskpass {};
|
||||
|
||||
ksshaskpass = callPackage ../tools/security/ksshaskpass {};
|
||||
ktorrent = callPackage ../applications/networking/p2p/ktorrent { };
|
||||
|
||||
ktorrent = callPackage ../applications/networking/p2p/ktorrent { };
|
||||
kuickshow = callPackage ../applications/graphics/kuickshow { };
|
||||
|
||||
kuickshow = callPackage ../applications/graphics/kuickshow { };
|
||||
libalkimia = callPackage ../development/libraries/libalkimia { };
|
||||
|
||||
libalkimia = callPackage ../development/libraries/libalkimia { };
|
||||
libktorrent = callPackage ../development/libraries/libktorrent {
|
||||
boost = boost156;
|
||||
};
|
||||
|
||||
libktorrent = callPackage ../development/libraries/libktorrent {
|
||||
boost = boost156;
|
||||
};
|
||||
libkvkontakte = callPackage ../development/libraries/libkvkontakte { };
|
||||
|
||||
libkvkontakte = callPackage ../development/libraries/libkvkontakte { };
|
||||
liblikeback = callPackage ../development/libraries/liblikeback { };
|
||||
|
||||
liblikeback = callPackage ../development/libraries/liblikeback { };
|
||||
libmm-qt = callPackage ../development/libraries/libmm-qt { };
|
||||
|
||||
libmm-qt = callPackage ../development/libraries/libmm-qt { };
|
||||
libnm-qt = callPackage ../development/libraries/libnm-qt { };
|
||||
|
||||
libnm-qt = callPackage ../development/libraries/libnm-qt { };
|
||||
massif-visualizer = callPackage ../development/tools/analysis/massif-visualizer { };
|
||||
|
||||
massif-visualizer = callPackage ../development/tools/analysis/massif-visualizer { };
|
||||
networkmanagement = callPackage ../tools/networking/networkmanagement { };
|
||||
|
||||
networkmanagement = callPackage ../tools/networking/networkmanagement { };
|
||||
partitionManager = callPackage ../tools/misc/partition-manager { };
|
||||
|
||||
partitionManager = callPackage ../tools/misc/partition-manager { };
|
||||
plasma-nm = callPackage ../tools/networking/plasma-nm { };
|
||||
|
||||
plasma-nm = callPackage ../tools/networking/plasma-nm { };
|
||||
polkit_kde_agent = callPackage ../tools/security/polkit-kde-agent { };
|
||||
|
||||
polkit_kde_agent = callPackage ../tools/security/polkit-kde-agent { };
|
||||
psi = callPackage ../applications/networking/instant-messengers/psi { };
|
||||
|
||||
psi = callPackage ../applications/networking/instant-messengers/psi { };
|
||||
qtcurve = callPackage ../misc/themes/qtcurve { };
|
||||
|
||||
qtcurve = callPackage ../misc/themes/qtcurve { };
|
||||
quassel = callPackage ../applications/networking/irc/quassel rec {
|
||||
monolithic = true;
|
||||
daemon = false;
|
||||
client = false;
|
||||
withKDE = stdenv.isLinux;
|
||||
qt = if withKDE then qt4 else qt5; # KDE supported quassel cannot build with qt5 yet (maybe in 0.12.0)
|
||||
dconf = gnome3.dconf;
|
||||
};
|
||||
|
||||
quassel = callPackage ../applications/networking/irc/quassel rec {
|
||||
monolithic = true;
|
||||
daemon = false;
|
||||
client = false;
|
||||
withKDE = stdenv.isLinux;
|
||||
qt = if withKDE then qt4 else qt5; # KDE supported quassel cannot build with qt5 yet (maybe in 0.12.0)
|
||||
dconf = gnome3.dconf;
|
||||
};
|
||||
quasselWithoutKDE = (quassel.override {
|
||||
monolithic = true;
|
||||
daemon = false;
|
||||
client = false;
|
||||
withKDE = false;
|
||||
#qt = qt5;
|
||||
tag = "-without-kde";
|
||||
});
|
||||
|
||||
quasselWithoutKDE = (self.quassel.override {
|
||||
monolithic = true;
|
||||
daemon = false;
|
||||
client = false;
|
||||
withKDE = false;
|
||||
#qt = qt5;
|
||||
tag = "-without-kde";
|
||||
});
|
||||
quasselDaemon = (quassel.override {
|
||||
monolithic = false;
|
||||
daemon = true;
|
||||
client = false;
|
||||
withKDE = false;
|
||||
#qt = qt5;
|
||||
tag = "-daemon";
|
||||
});
|
||||
|
||||
quasselDaemon = (self.quassel.override {
|
||||
monolithic = false;
|
||||
daemon = true;
|
||||
client = false;
|
||||
withKDE = false;
|
||||
#qt = qt5;
|
||||
tag = "-daemon";
|
||||
});
|
||||
quasselClient = (quassel.override {
|
||||
monolithic = false;
|
||||
daemon = false;
|
||||
client = true;
|
||||
tag = "-client";
|
||||
});
|
||||
|
||||
quasselClient = (self.quassel.override {
|
||||
monolithic = false;
|
||||
daemon = false;
|
||||
client = true;
|
||||
tag = "-client";
|
||||
});
|
||||
quasselClientWithoutKDE = (quasselClient.override {
|
||||
monolithic = false;
|
||||
daemon = false;
|
||||
client = true;
|
||||
withKDE = false;
|
||||
#qt = qt5;
|
||||
tag = "-client-without-kde";
|
||||
});
|
||||
|
||||
quasselClientWithoutKDE = (self.quasselClient.override {
|
||||
monolithic = false;
|
||||
daemon = false;
|
||||
client = true;
|
||||
withKDE = false;
|
||||
#qt = qt5;
|
||||
tag = "-client-without-kde";
|
||||
});
|
||||
rekonq = callPackage ../applications/networking/browsers/rekonq { };
|
||||
|
||||
rekonq = callPackage ../applications/networking/browsers/rekonq { };
|
||||
kwebkitpart = callPackage ../applications/networking/browsers/kwebkitpart { };
|
||||
|
||||
kwebkitpart = callPackage ../applications/networking/browsers/kwebkitpart { };
|
||||
rsibreak = callPackage ../applications/misc/rsibreak { };
|
||||
|
||||
rsibreak = callPackage ../applications/misc/rsibreak { };
|
||||
semnotes = callPackage ../applications/misc/semnotes { };
|
||||
|
||||
semnotes = callPackage ../applications/misc/semnotes { };
|
||||
skrooge = callPackage ../applications/office/skrooge { };
|
||||
|
||||
skrooge = callPackage ../applications/office/skrooge { };
|
||||
telepathy = callPackage ../applications/networking/instant-messengers/telepathy/kde {};
|
||||
|
||||
telepathy = callPackage ../applications/networking/instant-messengers/telepathy/kde {};
|
||||
yakuake = callPackage ../applications/misc/yakuake { };
|
||||
|
||||
yakuake = callPackage ../applications/misc/yakuake { };
|
||||
zanshin = callPackage ../applications/office/zanshin { };
|
||||
|
||||
zanshin = callPackage ../applications/office/zanshin { };
|
||||
kwooty = callPackage ../applications/networking/newsreaders/kwooty { };
|
||||
};
|
||||
|
||||
kwooty = callPackage ../applications/networking/newsreaders/kwooty { };
|
||||
};
|
||||
callPackageOrig = newScope (extra // { cmake = cmake-3_2; });
|
||||
|
||||
makePackages = extra:
|
||||
let
|
||||
callPackage = newScope (extra // { cmake = cmake-3_2; } // self);
|
||||
kde4 = callPackageOrig dir { inherit callPackage callPackageOrig; };
|
||||
self =
|
||||
kde4
|
||||
// extraPackages callPackage
|
||||
// {
|
||||
inherit kde4;
|
||||
wrapper = callPackage ../build-support/kdewrapper {};
|
||||
recurseForRelease = true;
|
||||
};
|
||||
in self;
|
||||
|
||||
in makeOverridable makePackages extra;
|
||||
|
||||
pantheon = recurseIntoAttrs rec {
|
||||
callPackage = newScope pkgs.pantheon;
|
||||
|
@ -21,6 +21,18 @@ let self = _self // overrides; _self = with self; {
|
||||
};
|
||||
};
|
||||
|
||||
glog = buildGoPackage rec {
|
||||
rev = "44145f04b68cf362d9c4df2182967c2275eaefed";
|
||||
name = "glog-${rev}";
|
||||
goPackagePath = "github.com/golang/glog";
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "golang";
|
||||
repo = "glog";
|
||||
sha256 = "1k7sf6qmpgm0iw81gx2dwggf9di6lgw0n54mni7862hihwfrb5rq";
|
||||
};
|
||||
};
|
||||
|
||||
image = buildGoPackage rec {
|
||||
rev = "490b1ad139b3";
|
||||
name = "go.image-${rev}";
|
||||
@ -45,13 +57,14 @@ let self = _self // overrides; _self = with self; {
|
||||
};
|
||||
|
||||
protobuf = buildGoPackage rec {
|
||||
rev = "36be16571e14";
|
||||
name = "goprotobuf-${rev}";
|
||||
goPackagePath = "code.google.com/p/goprotobuf";
|
||||
src = fetchhg {
|
||||
rev = "5677a0e3d5e89854c9974e1256839ee23f8233ca";
|
||||
name = "goprotobuf-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
goPackagePath = "github.com/golang/protobuf";
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
url = "https://code.google.com/p/goprotobuf";
|
||||
sha256 = "14yay2sgfbbs0bx3q03bdqn1kivyvxfdm34rmp2612gvinlll215";
|
||||
owner = "golang";
|
||||
repo = "protobuf";
|
||||
sha256 = "18dzxmy0gfjnwa9x8k3hv9calvmydv0dnz1iibykkzd20gw4l85v";
|
||||
};
|
||||
subPackages = [ "proto" "protoc-gen-go" ];
|
||||
};
|
||||
@ -202,6 +215,18 @@ let self = _self // overrides; _self = with self; {
|
||||
};
|
||||
};
|
||||
|
||||
fsnotify = buildGoPackage rec {
|
||||
rev = "4894fe7efedeeef21891033e1cce3b23b9af7ad2";
|
||||
name = "fsnotify-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
goPackagePath = "github.com/howeyc/fsnotify";
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "howeyc";
|
||||
repo = "fsnotify";
|
||||
sha256 = "09r3h200nbw8a4d3rn9wxxmgma2a8i6ssaplf3zbdc2ykizsq7mn";
|
||||
};
|
||||
};
|
||||
|
||||
g2s = buildGoPackage rec {
|
||||
rev = "ec76db4c1ac16400ac0e17ca9c4840e1d23da5dc";
|
||||
name = "g2s-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
@ -214,6 +239,19 @@ let self = _self // overrides; _self = with self; {
|
||||
};
|
||||
};
|
||||
|
||||
ginkgo = buildGoPackage rec {
|
||||
rev = "5ed93e443a4b7dfe9f5e95ca87e6082e503021d2";
|
||||
name = "ginkgo-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
goPackagePath = "github.com/onsi/ginkgo";
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "onsi";
|
||||
repo = "ginkgo";
|
||||
sha256 = "0ghrx5qmgvgb8cbvsj53v1ir4j9agilg4wyhpk5ikqdv6mmqly4h";
|
||||
};
|
||||
subPackages = [ "./" ]; # don't try to build test fixtures
|
||||
};
|
||||
|
||||
goamz = buildGoPackage rec {
|
||||
rev = "2a8fed5e89ab9e16210fc337d1aac780e8c7bbb7";
|
||||
name = "goamz-${rev}";
|
||||
@ -230,6 +268,18 @@ let self = _self // overrides; _self = with self; {
|
||||
buildInputs = [ sets go-simplejson check-v1 ];
|
||||
};
|
||||
|
||||
goautoneg = buildGoPackage rec {
|
||||
rev = "75cd24fc2f2c2a2088577d12123ddee5f54e0675";
|
||||
name = "goautoneg-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
goPackagePath = "bitbucket.org/ww/goautoneg";
|
||||
|
||||
src = fetchhg {
|
||||
inherit rev;
|
||||
url = "https://${goPackagePath}";
|
||||
sha256 = "19khhn5xhqv1yp7d6k987gh5w5rhrjnp4p0c6fyrd8z6lzz5h9qi";
|
||||
};
|
||||
};
|
||||
|
||||
gocheck = buildGoPackage rec {
|
||||
rev = "87";
|
||||
name = "gocheck-${rev}";
|
||||
@ -254,6 +304,68 @@ let self = _self // overrides; _self = with self; {
|
||||
doCheck = false; # please check again
|
||||
};
|
||||
|
||||
govers = buildGoPackage rec {
|
||||
rev = "3b5f175f65d601d06f48d78fcbdb0add633565b9";
|
||||
name = "govers-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
goPackagePath = "github.com/rogpeppe/govers";
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "rogpeppe";
|
||||
repo = "govers";
|
||||
sha256 = "0din5a7nff6hpc4wg0yad2nwbgy4q1qaazxl8ni49lkkr4hyp8pc";
|
||||
};
|
||||
};
|
||||
|
||||
golang_protobuf_extensions = buildGoPackage rec {
|
||||
rev = "ba7d65ac66e9da93a714ca18f6d1bc7a0c09100c";
|
||||
name = "golang-protobuf-extensions-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
goPackagePath = "github.com/matttproud/golang_protobuf_extensions";
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "matttproud";
|
||||
repo = "golang_protobuf_extensions";
|
||||
sha256 = "1vz6zj94v90x8mv9h6qfp1211kmzn60ri5qh7p9fzpjkhga5k936";
|
||||
};
|
||||
buildInputs = [ protobuf ];
|
||||
};
|
||||
|
||||
goleveldb = buildGoPackage rec {
|
||||
rev = "e9e2c8f6d3b9c313fb4acaac5ab06285bcf30b04";
|
||||
name = "goleveldb-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
goPackagePath = "github.com/syndtr/goleveldb";
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "syndtr";
|
||||
repo = "goleveldb";
|
||||
sha256 = "0vg3pcrbdhbmanwkc5njxagi64f4k2ikfm173allcghxcjamrkwv";
|
||||
};
|
||||
propagatedBuildInputs = [ ginkgo gomega gosnappy ];
|
||||
};
|
||||
|
||||
gomega = buildGoPackage rec {
|
||||
rev = "8adf9e1730c55cdc590de7d49766cb2acc88d8f2";
|
||||
name = "gomega-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
goPackagePath = "github.com/onsi/gomega";
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "onsi";
|
||||
repo = "gomega";
|
||||
sha256 = "1rf6cxn50d1pji3pv4q372s395r5nxwcgp405z2r2mfdkri4v3w4";
|
||||
};
|
||||
};
|
||||
|
||||
gosnappy = buildGoPackage rec {
|
||||
rev = "ce8acff4829e0c2458a67ead32390ac0a381c862";
|
||||
name = "gosnappy-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
goPackagePath = "github.com/syndtr/gosnappy";
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "syndtr";
|
||||
repo = "gosnappy";
|
||||
sha256 = "0ywa52kcii8g2a9lbqcx8ghdf6y56lqq96sl5nl9p6h74rdvmjr7";
|
||||
};
|
||||
};
|
||||
|
||||
gox = buildGoPackage rec {
|
||||
rev = "e8e6fd4fe12510cc46893dff18c5188a6a6dc549";
|
||||
name = "gox-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
@ -437,6 +549,18 @@ let self = _self // overrides; _self = with self; {
|
||||
};
|
||||
};
|
||||
|
||||
go-runit = buildGoPackage rec {
|
||||
rev = "a9148323a615e2e1c93b7a9893914a360b4945c8";
|
||||
name = "go-runit-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
goPackagePath = "github.com/soundcloud/go-runit";
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "soundcloud";
|
||||
repo = "go-runit";
|
||||
sha256 = "00f2rfhsaqj2wjanh5qp73phx7x12a5pwd7lc0rjfv68l6sgpg2v";
|
||||
};
|
||||
};
|
||||
|
||||
go-simplejson = buildGoPackage rec {
|
||||
rev = "1cfceb0e12f47ec02665ef480212d7b531d6f4c5";
|
||||
name = "go-simplejson-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
@ -513,17 +637,34 @@ let self = _self // overrides; _self = with self; {
|
||||
};
|
||||
preBuild = ''
|
||||
cd "go/src/$goPackagePath"
|
||||
|
||||
govers -d -m code.google.com/p/goprotobuf github.com/golang/protobuf
|
||||
|
||||
# Work around `go install` assuming containing directory is the executable name we want
|
||||
for i in */bin; do
|
||||
mv "$i" "$(dirname "$i")/$(dirname "$i")"
|
||||
done
|
||||
|
||||
# Generate protobuf definitions and static assets
|
||||
sed -i '1s|^|SHELL = ${stdenv.shell}\n|' Makefile
|
||||
make protocol/hologram.pb.go
|
||||
make transport/remote/bindata.go
|
||||
'';
|
||||
|
||||
buildInputs = [ pkgs.protobuf crypto protobuf goamz rgbterm go-bindata go-homedir ldap g2s gox ];
|
||||
buildInputs = [ pkgs.protobuf crypto protobuf goamz rgbterm go-bindata
|
||||
go-homedir ldap g2s gox govers ];
|
||||
};
|
||||
|
||||
httprouter = buildGoPackage rec {
|
||||
rev = "bde5c16eb82ff15a1734a3818d9b9547065f65b1";
|
||||
name = "httprouter-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
goPackagePath = "github.com/julienschmidt/httprouter";
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "julienschmidt";
|
||||
repo = "httprouter";
|
||||
sha256 = "1l74pvqqhhval4vfnhca9d6i1ij69qs3ljf41w3m1l2id42rq7r9";
|
||||
};
|
||||
};
|
||||
|
||||
influxdb-go = buildGoPackage rec {
|
||||
@ -641,6 +782,20 @@ let self = _self // overrides; _self = with self; {
|
||||
propagatedBuildInputs = [ go-codec armon.go-metrics ];
|
||||
};
|
||||
|
||||
mesos-stats = buildGoPackage rec {
|
||||
rev = "0c6ea494c19bedc67ebb85ce3d187ec21050e920";
|
||||
name = "mesos-stats-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
goPackagePath = "github.com/antonlindstrom/mesos_stats";
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "antonlindstrom";
|
||||
repo = "mesos_stats";
|
||||
sha256 = "18ggyjf4nyn77gkn16wg9krp4dsphgzdgcr3mdflv6mvbr482ar4";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = [ prometheus.client_golang glog ];
|
||||
};
|
||||
|
||||
mgo = buildGoPackage rec {
|
||||
rev = "2";
|
||||
name = "mgo-${rev}";
|
||||
@ -676,6 +831,18 @@ let self = _self // overrides; _self = with self; {
|
||||
};
|
||||
};
|
||||
|
||||
ntp = buildGoPackage rec {
|
||||
rev = "0a5264e2563429030eb922f258229ae3fee5b5dc";
|
||||
name = "ntp-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
goPackagePath = "github.com/beevik/ntp";
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "beevik";
|
||||
repo = "ntp";
|
||||
sha256 = "03fvgbjf2aprjj1s6wdc35wwa7k1w5phkixzvp5n1j21sf6w4h24";
|
||||
};
|
||||
};
|
||||
|
||||
oglematchers = buildGoPackage rec {
|
||||
rev = "4fc24f97b5b74022c2a3f4ca7eed57ca29083d3e";
|
||||
name = "oglematchers-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
@ -739,6 +906,18 @@ let self = _self // overrides; _self = with self; {
|
||||
};
|
||||
};
|
||||
|
||||
beorn7.perks = buildGoPackage rec {
|
||||
rev = "b965b613227fddccbfffe13eae360ed3fa822f8d";
|
||||
name = "beorn7.perks-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
goPackagePath = "github.com/beorn7/perks";
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "beorn7";
|
||||
repo = "perks";
|
||||
sha256 = "1p8zsj4r0g61q922khfxpwxhdma2dx4xad1m5qx43mfn28kxngqk";
|
||||
};
|
||||
};
|
||||
|
||||
pflag = buildGoPackage rec {
|
||||
date = "20131112";
|
||||
rev = "94e98a55fb412fcbcfc302555cb990f5e1590627";
|
||||
@ -765,6 +944,51 @@ let self = _self // overrides; _self = with self; {
|
||||
propagatedBuildInputs = [ kr.text ];
|
||||
};
|
||||
|
||||
prometheus.client_golang = buildGoPackage rec {
|
||||
name = "prometheus-client-${version}";
|
||||
version = "0.3.2";
|
||||
goPackagePath = "github.com/prometheus/client_golang";
|
||||
src = fetchFromGitHub {
|
||||
owner = "prometheus";
|
||||
repo = "client_golang";
|
||||
rev = "${version}";
|
||||
sha256 = "1fn56zp420hxpm0prr76yyhh62zq3sqj3ppl2r4qxjc78f8ckbj4";
|
||||
};
|
||||
propagatedBuildInputs = [
|
||||
protobuf
|
||||
golang_protobuf_extensions
|
||||
prometheus.client_model
|
||||
prometheus.procfs
|
||||
beorn7.perks
|
||||
goautoneg
|
||||
];
|
||||
};
|
||||
|
||||
prometheus.client_model = buildGoPackage rec {
|
||||
rev = "fa8ad6fec33561be4280a8f0514318c79d7f6cb6";
|
||||
name = "prometheus-client-model-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
goPackagePath = "github.com/prometheus/client_model";
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "prometheus";
|
||||
repo = "client_model";
|
||||
sha256 = "11a7v1fjzhhwsl128znjcf5v7v6129xjgkdpym2lial4lac1dhm9";
|
||||
};
|
||||
buildInputs = [ protobuf ];
|
||||
};
|
||||
|
||||
prometheus.procfs = buildGoPackage rec {
|
||||
rev = "92faa308558161acab0ada1db048e9996ecec160";
|
||||
name = "prometheus-procfs-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
goPackagePath = "github.com/prometheus/procfs";
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "prometheus";
|
||||
repo = "procfs";
|
||||
sha256 = "0kaw81z2yi45f6ll6n2clr2zz60bdgdxzqnxvd74flynz4sr0p1v";
|
||||
};
|
||||
};
|
||||
|
||||
pty = buildGoPackage rec {
|
||||
rev = "67e2db24c831afa6c64fc17b4a143390674365ef";
|
||||
name = "pty-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
@ -777,6 +1001,18 @@ let self = _self // overrides; _self = with self; {
|
||||
};
|
||||
};
|
||||
|
||||
pushover = buildGoPackage rec {
|
||||
rev = "a8420a1935479cc266bda685cee558e86dad4b9f";
|
||||
name = "pushover-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
goPackagePath = "github.com/thorduri/pushover";
|
||||
src = fetchFromGitHub {
|
||||
inherit rev;
|
||||
owner = "thorduri";
|
||||
repo = "pushover";
|
||||
sha256 = "0j4k43ppka20hmixlwhhz5mhv92p6wxbkvdabs4cf7k8jpk5argq";
|
||||
};
|
||||
};
|
||||
|
||||
raw = buildGoPackage rec {
|
||||
rev = "724aedf6e1a5d8971aafec384b6bde3d5608fba4";
|
||||
name = "raw-${stdenv.lib.strings.substring 0 7 rev}";
|
||||
|
@ -1638,7 +1638,7 @@ self : let callPackage = x : y : modifyPrio (newScope self x y); in
|
||||
|
||||
ListZipper = callPackage ../development/libraries/haskell/ListZipper {};
|
||||
|
||||
llvmGeneral = callPackage ../development/libraries/haskell/llvm-general { llvmConfig = pkgs.llvm; };
|
||||
llvmGeneral = callPackage ../development/libraries/haskell/llvm-general { llvmConfig = pkgs.llvmPackages_34.llvm; };
|
||||
|
||||
llvmGeneralPure = callPackage ../development/libraries/haskell/llvm-general-pure {};
|
||||
|
||||
|
@ -7527,10 +7527,10 @@ let
|
||||
|
||||
pgcli = buildPythonPackage rec {
|
||||
name = "pgcli-${version}";
|
||||
version = "0.16.1";
|
||||
version = "0.16.2";
|
||||
|
||||
src = pkgs.fetchFromGitHub {
|
||||
sha256 = "1sysx67inf0fcfa4qhqcii97y59zpg98f4kcvz15rlbnsi357css";
|
||||
sha256 = "1f30f9v2iz2206aqzwc6jjadlxd7snicazrp9bcy5sizpha3r55i";
|
||||
rev = "v${version}";
|
||||
repo = "pgcli";
|
||||
owner = "amjith";
|
||||
@ -9360,11 +9360,12 @@ let
|
||||
|
||||
|
||||
requests2 = buildPythonPackage rec {
|
||||
name = "requests-2.5.1";
|
||||
name = "requests-${version}";
|
||||
version = "2.6.0";
|
||||
|
||||
src = pkgs.fetchurl {
|
||||
url = "http://pypi.python.org/packages/source/r/requests/${name}.tar.gz";
|
||||
sha256 = "0rnyg6164jp7x7slgwnhigqza18d705hdvzwr4yk5qmisgpkaxvv";
|
||||
sha256 = "0xadnw27m257scrhjcc66zm4z3ikg8n9h6g9akpkavr31qgyvnqw";
|
||||
};
|
||||
|
||||
meta = {
|
||||
|
Loading…
Reference in New Issue
Block a user