Andrew Dunham
3a918014b2
Fix library ordering in Makefiles
...
The existing ordering linked `libutil` before `libstore`, which causes
link failures when building statically. This is due to `libstore` using
functions from `libutil`, and the fact that symbol resolution works
"forward" - i.e. if you pass `-lfoo -lbar -lbaz`, any symbols that
`libbar` uses from `libbaz` will be resolved, but symbols from `libfoo`
will not since it comes first in the command line.
All this to say: this commit reorders the libraries which fixes the link
errors.
2018-04-21 21:10:52 -07:00
Peter Simons
040acdcee2
Merge pull request #1707 from dtzWill/fix/issue-1692
...
ignore "interrupted" exception in progress callback
2018-04-21 16:51:19 +02:00
Will Dietz
6d9129014d
build.cc: fix bind-mount of /dev/{pts,ptmx} fallback
...
Don't bind-mount these to themselves,
mount them into the chroot directory.
Fixes pty issues when using sandbox on CentOS 7.4.
(build of perlPackages.IOTty fails before this change)
2018-04-20 12:24:23 -05:00
Daniel Poelzleithner
b712d4674b
Allow multiple search experssions in nix search
...
The common use case is to search for packages containing multiple words
like a "git" "frontend". Having only one expressions makes this simple regular
use case very complicated. Instead, search accepts multiple regular epressions
which all need to match.
nix search git 'gui|frontend'
returns a list of all git uis for example
2018-04-18 21:08:35 +02:00
Shea Levy
b37f5ae31d
isFunction: True on primops.
...
Fixes #2073
2018-04-17 14:33:12 -04:00
Eelco Dolstra
a4aac7f88c
Handle arguments in $EDITOR
...
Fixes #2079 .
2018-04-17 12:16:04 +02:00
Eelco Dolstra
c74f838620
exportReferences: Check whether the path is in the input closure
...
Fixes #2082 .
2018-04-17 12:03:27 +02:00
Félix Baylac-Jacqué
a91fb422fe
nix repl: Fix multiline SIGINT handling.
...
Fixes #2076
2018-04-16 16:09:30 +02:00
Eelco Dolstra
d34fa2bcc3
Fix #1921
2018-04-13 15:42:35 +02:00
Shea Levy
dc0a542c9f
initPlugins: Fix dlopen error message.
2018-04-11 21:02:50 -04:00
Eelco Dolstra
1839a5542a
Fix #2057
2018-04-11 11:42:17 +02:00
Eelco Dolstra
d6aaa35478
Fix perl-bindings
...
https://hydra.nixos.org/build/72636781
2018-04-10 13:11:43 +02:00
Shea Levy
a38fe5c1a8
Export required C++ version in pkgconfig.
2018-04-09 11:32:43 -04:00
Shea Levy
7459388448
Merge branch 'fix/ruby-shebang' of git://github.com/samueldr/nix
2018-04-09 10:54:39 -04:00
Shea Levy
fd98fca7bb
Make prim_exec and prim_importNative available to plugins
2018-04-09 10:26:50 -04:00
Shea Levy
346c0ac361
nix-daemon: Exit successfully when interrupted.
...
Fixes #2058 .
2018-04-09 08:05:54 -04:00
Samuel Dionne-Riel
399f43c3d5
nix-shell: Fixes use with ruby shebangs.
...
The ported code in 80ebc553ec
was incorrectly ported.
```
- $envCommand = "exec $execArgs $interpreter -e 'load(\"$script\")' -- ${\(join ' ', (map shellEscape, @savedArgs))}";
...
+ envCommand = (format("exec %1% %2% -e 'load(\"%3%\") -- %4%") % execArgs % interpreter % script % joined.str()).str();
```
The single-quote finishing the small ruby snippet was lost in
translation.
2018-04-07 22:38:45 -04:00
AmineChikhaoui
62d75ad3e1
rename the options to mention it's a narinfo TTL as disk cache is used all over the place for other operations
2018-04-06 11:05:15 +01:00
AmineChikhaoui
86930ed414
add documentation for the local disk cache TTL config
2018-04-06 10:51:18 +01:00
AmineChikhaoui
2855c3d965
Make the TTL for disk cache configurable, we can now completely disable
...
disk cache lookup for example by doing:
nix copy --from <binary-cahe> <store-path> --option \
positive-disk-cache-ttl 0
Issues: #1885 #2035
2018-04-06 10:51:18 +01:00
Eelco Dolstra
1d9742b95f
<nix/buildenv.nix>: Ignore dangling symlinks
...
Fixes
error: getting status of '/nix/store/j8p0vv89k1pf0cn7kmfsdcs7bshwga1i-firefox-52.7.2esr/share/icons/hicolor/48x48/apps/firefox.png': No such file or directory
https://github.com/NixOS/nix/issues/1934
Also improve error message on directory/non-directory collisions.
2018-04-05 20:04:42 +02:00
Eelco Dolstra
5c904e10eb
<nix/buildenv.nix>: Skip non-directory top-level paths
...
Fixes https://github.com/NixOS/nix/issues/1934 (at least the "error:
opening directory '/nix/store/...-linux-config-4.4.14': Not a
directory" issue).
2018-04-05 19:34:56 +02:00
zimbatm
865ca2402f
nix copy: add an example with S3
...
I couldn't find a good example how to use it with non-us-east-1 buckets.
2018-03-30 02:31:14 +01:00
Eelco Dolstra
446bb88f13
Remove reference to non-existent manpages
2018-03-29 12:29:10 +02:00
Eelco Dolstra
2b61c74922
Process --option use-case-hack properly
...
Fixes https://github.com/NixOS/nix/issues/2009 .
2018-03-29 12:28:29 +02:00
Eelco Dolstra
9d1220a01d
ValidPathInfo::isContentAddressed(): Ensure there are no references
2018-03-29 12:27:42 +02:00
Will Dietz
74da813912
download: improve error for hash mismatch ("store mismatch")
...
Fixes #1905
2018-03-22 15:22:06 -05:00
Will Dietz
59b32403f2
download.cc: fix path for cached files
2018-03-22 15:05:46 -05:00
Eelco Dolstra
28eb9621cc
Fix build
2018-03-22 13:46:19 +01:00
Eelco Dolstra
dce8af59a6
Tweak
2018-03-22 13:32:18 +01:00
Eelco Dolstra
f87e286e82
Merge branch 'fix/avoid-large-stack-buffers' of https://github.com/dtzWill/nix
2018-03-22 13:19:25 +01:00
Shea Levy
c24e0439b2
Merge branch 'fix/execl-null-sentinel' of git://github.com/dtzWill/nix
2018-03-21 23:25:53 -04:00
Eelco Dolstra
ec91840e70
Also make the backwards compatible case of RemoteStore::addToStore run in constant memory
...
Just because we can.
2018-03-21 23:46:03 +01:00
Eelco Dolstra
97002b684c
Make 'nix copy --to daemon' run in constant memory
2018-03-21 23:42:52 +01:00
Will Dietz
f66ae22288
shared.cc: style: prefer "nullptr" over '(char *)NULL'
2018-03-21 17:17:37 -05:00
Eelco Dolstra
11898d6a37
Make 'nix copy --to ssh://...' run in constant memory
2018-03-21 23:13:06 +01:00
Eelco Dolstra
47f7e5585b
Make 'nix copy --from ssh://...' run in constant memory
...
For instance, this reduced the memory consumption of
$ nix copy --from ssh://localhost --to ~/my-nix /nix/store/1n7x0yv8vq6zi90hfmian84vdhd04bgp-blender-2.79a
from 632 MiB to 16 MiB.
2018-03-21 23:10:40 +01:00
Eelco Dolstra
8615cfb130
LegacySSHStore: Allow overriding the path to nix-store
2018-03-21 15:10:46 +01:00
Will Dietz
02d36fdab7
execl: cast NULL sentinel to (char *), per man page and compiler warning
...
From exec(3):
> The list of arguments must be terminated by a null pointer, and, since these
> are variadic functions, this pointer must be cast (char *) NULL
2018-03-20 13:31:58 -05:00
Eelco Dolstra
03d8136b02
Remove unused channel-cache directory
2018-03-20 18:22:49 +01:00
Eelco Dolstra
e0c1597910
Style fix
2018-03-20 17:33:45 +01:00
Eelco Dolstra
668ac3ea2c
Make <nix/buildenv.nix> a builtin builder
...
This avoids sandbox annoyances.
2018-03-20 17:28:09 +01:00
Eelco Dolstra
9d40787938
Move builtinFetchurl to its own file
2018-03-20 17:01:36 +01:00
Eelco Dolstra
5df427f35b
Slight simplification
2018-03-20 16:32:59 +01:00
Eelco Dolstra
21ebf6a160
SSHMaster: Optionally pass -v to ssh
2018-03-20 15:30:55 +01:00
Eelco Dolstra
1aca195e52
Hack to get SSH error messages from build-remote
...
E.g.
cannot build on 'ssh://mac1': cannot connect to 'mac1': bash: nix-store: command not found
cannot build on 'ssh://mac2': cannot connect to 'mac2': Host key verification failed.
cannot build on 'ssh://mac3': cannot connect to 'mac3': Received disconnect from 213... port 6001:2: Too many authentication failures
Authentication failed.
2018-03-20 15:25:26 +01:00
Will Dietz
f5a2136a40
serialise.cc: remove pessimising move
...
from clang6:
src/libutil/serialise.cc:189:23: warning: moving a temporary object prevents copy elision [-Wpessimizing-move]
2018-03-19 19:18:47 -05:00
Will Dietz
9b33201e72
util: rename stdout/stdin members to avoid conflicts w/standard macro
...
(cherry picked from commit c389a7fb617ed7bcd617efa68c6a48c00405310d)
2018-03-19 11:18:56 -05:00
Eelco Dolstra
138af2e554
Shut up signedness warning
2018-03-19 11:57:15 +01:00
Linus Heckemann
12913ccf45
nix-shell: allow symlinks to .drvs
...
This makes persistent shell environments easier to use.
2018-03-16 22:15:24 +00:00