1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-28 13:41:15 +02:00

Remove static variable name clashes

This was useful for an experiment with building Nix as a single
compilation unit. It's not very useful otherwise but also doesn't
hurt...
This commit is contained in:
Eelco Dolstra 2020-10-06 13:36:55 +02:00
parent 0419cd2695
commit 85c8be6286
63 changed files with 97 additions and 92 deletions

View file

@ -24,6 +24,9 @@
#endif
namespace nix_store {
using namespace nix;
using std::cin;
using std::cout;
@ -1025,7 +1028,7 @@ static void opVersion(Strings opFlags, Strings opArgs)
/* Scan the arguments; find the operation, set global flags, put all
other flags in a list, and put all other arguments in another
list. */
static int _main(int argc, char * * argv)
static int main_nix_store(int argc, char * * argv)
{
{
Strings opFlags, opArgs;
@ -1121,4 +1124,6 @@ static int _main(int argc, char * * argv)
}
}
static RegisterLegacyCommand s1("nix-store", _main);
static RegisterLegacyCommand r_nix_store("nix-store", main_nix_store);
}