forked from lix-project/lix
2cd468874f
Because config.h can #define things like _FILE_OFFSET_BITS=64 and not every compilation unit includes config.h, we currently compile half of Nix with _FILE_OFFSET_BITS=64 and other half with _FILE_OFFSET_BITS unset. This causes major havoc with the Settings class on e.g. 32-bit ARM, where different compilation units disagree with the struct layout. E.g.: diff --git a/src/libstore/globals.cc b/src/libstore/globals.cc @@ -166,6 +166,8 @@ void Settings::update() _get(useSubstitutes, "build-use-substitutes"); + fprintf(stderr, "at Settings::update(): &useSubstitutes = %p\n", &nix::settings.useSubstitutes); _get(buildUsersGroup, "build-users-group"); diff --git a/src/libstore/remote-store.cc b/src/libstore/remote-store.cc +++ b/src/libstore/remote-store.cc @@ -138,6 +138,8 @@ void RemoteStore::initConnection(Connection & conn) void RemoteStore::setOptions(Connection & conn) { + fprintf(stderr, "at RemoteStore::setOptions(): &useSubstitutes = %p\n", &nix::settings.useSubstitutes); conn.to << wopSetOptions Gave me: at Settings::update(): &useSubstitutes = 0xb6e5c5cb at RemoteStore::setOptions(): &useSubstitutes = 0xb6e5c5c7 That was not a fun one to debug! |
||
---|---|---|
.. | ||
primops | ||
attr-path.cc | ||
attr-path.hh | ||
attr-set.cc | ||
attr-set.hh | ||
common-opts.cc | ||
common-opts.hh | ||
eval-inline.hh | ||
eval.cc | ||
eval.hh | ||
get-drvs.cc | ||
get-drvs.hh | ||
json-to-value.cc | ||
json-to-value.hh | ||
lexer.l | ||
local.mk | ||
names.cc | ||
names.hh | ||
nix-expr.pc.in | ||
nixexpr.cc | ||
nixexpr.hh | ||
parser.y | ||
primops.cc | ||
primops.hh | ||
symbol-table.hh | ||
value-to-json.cc | ||
value-to-json.hh | ||
value-to-xml.cc | ||
value-to-xml.hh | ||
value.hh |