Commit graph

16823 commits

Author SHA1 Message Date
Vincent Ambo
7114876693 * limiting amount of queries with couchDB's limit parameter 2012-03-03 04:02:30 +01:00
Vincent Ambo
65a5443e2d * getMonthCount now takes a BlogLang, as is obviously required 2012-03-03 03:47:11 +01:00
Vincent Ambo
9e4b35613c * removed an unnecessary tempVar 2012-03-03 03:42:44 +01:00
Vincent Ambo
907eecf8c7 * getMonthCount function added 2012-03-03 03:35:20 +01:00
Vincent Ambo
da8833bf34 * changes D: 2012-03-02 09:12:09 +01:00
Vincent Ambo
fed422f872 *updated .hgignore for geany files 2012-03-01 18:10:34 +01:00
Eelco Dolstra
8afd28a922 Remove dependency on sqlite3_table_column_metadata
Not all SQLite builds have the function sqlite3_table_column_metadata.
We were only using it in a schema upgrade check for compatibility with
databases that were probably never seen in the wild.  So remove it.
2012-03-01 16:06:49 +01:00
Eelco Dolstra
1c94524458 Fix an uninitialised variable
The variable ‘useChroot’ was not initialised properly.  This caused
random failures if using the build hook.  Seen on Mac OS X 10.7 with Clang.
Thanks to KolibriFX for finding this :-)
2012-03-01 16:06:49 +01:00
"Vincent Ambo ext:(%22)
0f0d874aa7 * entries by month 2012-02-24 17:01:36 +01:00
"Vincent Ambo ext:(%22)
35a5557e17 * localization moved to Locales.hs 2012-02-24 16:06:33 +01:00
"Vincent Ambo ext:(%22)
a29a34d41f * I fixed the front page 2012-02-24 05:20:36 +01:00
"Vincent Ambo ext:(%22)
066762051a * rendering comments 2012-02-24 00:03:16 +01:00
"Vincent Ambo ext:(%22)
d04d693eb9 * comment parsing 2012-02-23 14:46:51 +01:00
"Vincent Ambo ext:(%22)
a4119e1cfd * displaying blog entries
* changed convertDB for BlogLang JSON representation
2012-02-23 13:20:29 +01:00
"Vincent Ambo ext:(%22)
47dbfe900e * removing .DS_Store files 2012-02-23 03:32:40 +01:00
"Vincent Ambo ext:(%22)
2fa129e7e3 * blog footer, language handling, emptyTest 2012-02-23 03:30:14 +01:00
"Vincent Ambo ext:(%22)
47c8d9a96d * .hgignore file 2012-02-22 22:07:28 +01:00
"Vincent Ambo ext:(%22)
fd9dc7e706 * removing binaries 2012-02-22 22:05:11 +01:00
"Vincent Ambo ext:(%22)
b951faa6b4 * initial checkin 2012-02-22 22:03:31 +01:00
Eelco Dolstra
6fe13e6aba Fix chroots builds
Chroots are initialised by hard-linking inputs from the Nix store to
the chroot.  This doesn't work if the input has its immutable bit set,
because it's forbidden to create hard links to immutable files.  So
temporarily clear the immutable bit when creating and destroying the
chroot.

Note that making regular files in the Nix store immutable isn't very
reliable, since the bit can easily become cleared: for instance, if we
run the garbage collector after running ‘nix-store --optimise’.  So
maybe we should only make directories immutable.
2012-02-18 01:23:52 +01:00
Eelco Dolstra
bd013b6f98 On Linux, make the Nix store really read-only by using the immutable bit
I was bitten one time too many by Python modifying the Nix store by
creating *.pyc files when run as root.  On Linux, we can prevent this
by setting the immutable bit on files and directories (as in ‘chattr
+i’).  This isn't supported by all filesystems, so it's not an error
if setting the bit fails.  The immutable bit is cleared by the garbage
collector before deleting a path.  The only tricky aspect is in
optimiseStore(), since it's forbidden to create hard links to an
immutable file.  Thus optimiseStore() temporarily clears the immutable
bit before creating the link.
2012-02-15 01:31:56 +01:00
Eelco Dolstra
5e57047d87 Fix a broken guard around utime()
Because of an outdated check for a timestamp of 0, we were calling
utime() even when it wasn't necessary.
2012-02-15 01:00:30 +01:00
Eelco Dolstra
58ac7a17a4 Don't use deletePath() to delete a single file 2012-02-15 00:28:01 +01:00
Eelco Dolstra
e9fc91df45 Fix error message
This fixes the error message

  error: file `' was not found in the Nix search path (add it using $NIX_PATH or -I)
2012-02-09 18:56:48 +01:00
Eelco Dolstra
d5a5a83ad4 Use data() instead of c_str() where appropriate 2012-02-09 18:27:45 +01:00
Eelco Dolstra
ec2827f5fc Update .gitignore 2012-02-08 19:25:43 +01:00
Eelco Dolstra
4055a3b19c Remove empty ChangeLog file 2012-02-08 13:22:08 +01:00
Eelco Dolstra
fb95455c02 Set the versionSuffix to include the Git shortrev 2012-02-08 12:31:14 +01:00
Eelco Dolstra
67444f5e54 * Build Nix for the latest Fedora and Ubuntu releases (and drop some
old ones).
2012-02-07 13:18:20 +00:00
Eelco Dolstra
f491ae97d4 * Inline some functions and get rid of the indirection through
EvalState::eval().  This gives a 12% speedup on ‘nix-instantiate
  /etc/nixos/nixos/ -A system --readonly-mode’ (from 1.01s to 0.89s).
2012-02-04 13:50:25 +00:00
Eelco Dolstra
2bda12ef3b * Print elapsed evaluation time. 2012-02-04 13:27:11 +00:00
Eelco Dolstra
ce86a9a0ae * nix-channel: fail if we don't have write permission to the manifests
directory.  Previously in this situation we did add the Nix
  expressions from the channel to allow installation from source, but
  this doesn't work for binary-only channels and leads to confusing
  error messages.
2012-02-02 12:25:56 +00:00
Eelco Dolstra
baa0501cc1 * Fix importing a derivation. This gave a segfault. 2012-01-26 13:13:00 +00:00
Eelco Dolstra
4c9fdd2cd6 * Add a test for importing derivations. 2012-01-26 13:04:50 +00:00
Eelco Dolstra
330df4b4db * Allow comparisons between derivations by comparing the outPath
attributes.
2012-01-19 23:08:47 +00:00
Eelco Dolstra
18047d4625 * Add some debug output to print the derivation name once it's known.
This makes it easier to pinpoint the source of a crash.
2012-01-19 23:07:42 +00:00
Eelco Dolstra
126c7317bc * Add a test case for comparing derivations. 2012-01-19 22:10:24 +00:00
Eelco Dolstra
ddd0ce534a * Don't distribute Store.cc, it's generated automatically by xsubpp. 2012-01-18 16:43:48 +00:00
Eelco Dolstra
02f1363e19 * Pass the appropriate flags to GCC when building the Perl bindings.
Without these, Nix fails on 32-bit Linux with Perl 5.14, with a
  rather unhelpful error message:

    Not a CODE reference at /nix/store/n6kpbacn6nn7i3i735v8j3di8aqyl07v-perl-5.14.2/lib/perl5/5.14.2/i686-linux-thread-multi/DynaLoader.pm

  This is likely because the lack of -D_FILE_OFFSET_BITS=64 causes
  various Perl structures to not match what the Perl interpreter
  expects.
2012-01-18 16:39:54 +00:00
Eelco Dolstra
4e624849b6 * Added a command ‘nix-store --print-env $drvpath’ that prints out the
environment of the given derivation in a format that can be sourced
  by the shell, e.g.

  $ eval "$(nix-store --print-env $(nix-instantiate /etc/nixos/nixpkgs -A pkg))"
  $ NIX_BUILD_TOP=/tmp
  $ source $stdenv/setup

  This is especially useful to reproduce the environment used to build
  a package outside of its builder for development purposes.

  TODO: add a nix-build option to do the above and fetch the
  dependencies of the derivation as well.
2012-01-17 23:07:22 +00:00
Eelco Dolstra
2a3f4110c5 * nix-build: put the temporary derivation symlink in a temporary
directory rather than the current directory.
* nix-build: --drv-link now implies --add-drv-link.
2012-01-13 23:35:07 +00:00
Eelco Dolstra
7ae763e16b * ‘-module’ causes the generated library to have an .so extension on
Mac OS X instead of .dylib, so don't do that.
2012-01-12 14:16:25 +00:00
Ludovic Courtès
6245f0d529 tests: Run `download-using-manifests' via libtool so that dlopening works. 2012-01-11 16:58:49 +00:00
Ludovic Courtès
c5d9ccd810 perl: Build libNixStore.la with `-module'. 2012-01-11 16:44:42 +00:00
Eelco Dolstra
f86fca9b70 * Figure out the extension of dynamic libraries; don't hard-code .so. 2012-01-11 15:41:42 +00:00
Eelco Dolstra
9fe24c5a0d * Don't create thunks for simple constants (integers, strings, paths)
and allocate them only once.
* Move Value and related functions into value.hh.
2012-01-07 17:26:33 +00:00
Eelco Dolstra
d4e6b9f2d6 * Doh! 2012-01-05 21:07:12 +00:00
Eelco Dolstra
a7366a764a * Add a -I flag to the Perl bindings to nix-build and some other
scripts.
* Include the version and architecture in the -I flag so that there is
  at least a chance that a Nix binary built for one Perl version will
  run on another version.
2012-01-05 20:33:46 +00:00
Eelco Dolstra
b52966e821 * Remove dead code. 2012-01-04 21:47:48 +00:00
Eelco Dolstra
35f2a6ba82 * Don't use dynamic_cast, it's very slow. "nix-instantiate
/etc/nixos/nixos -A system" spent about 10% of its time in
  dynamic_cast.
2012-01-04 21:24:11 +00:00