Skip to content

Commit

Permalink
Merge pull request #12137 from Mic92/windows
Browse files Browse the repository at this point in the history
windows: fix conditional compilation variable
  • Loading branch information
Ericson2314 authored Jan 6, 2025
2 parents 442a262 + 1eba904 commit daab4d1
Show file tree
Hide file tree
Showing 13 changed files with 13 additions and 13 deletions.
2 changes: 1 addition & 1 deletion src/libstore/windows/pathlocks.cc
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#include "signals.hh"
#include "util.hh"

#ifdef WIN32
#ifdef _WIN32
# include <errhandlingapi.h>
# include <fileapi.h>
# include <windows.h>
Expand Down
2 changes: 1 addition & 1 deletion src/libutil/windows/environment-variables.cc
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#include "environment-variables.hh"

#ifdef WIN32
#ifdef _WIN32
# include "processenv.h"

namespace nix {
Expand Down
2 changes: 1 addition & 1 deletion src/libutil/windows/file-descriptor.cc
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
#include "windows-error.hh"
#include "file-path.hh"

#ifdef WIN32
#ifdef _WIN32
#include <fileapi.h>
#include <error.h>
#include <namedpipeapi.h>
Expand Down
2 changes: 1 addition & 1 deletion src/libutil/windows/file-system.cc
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#include "file-system.hh"

#ifdef WIN32
#ifdef _WIN32
namespace nix {

Descriptor openDirectory(const std::filesystem::path & path)
Expand Down
2 changes: 1 addition & 1 deletion src/libutil/windows/muxable-pipe.cc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#ifdef WIN32
#ifdef _WIN32
# include <ioapiset.h>
# include "windows-error.hh"

Expand Down
2 changes: 1 addition & 1 deletion src/libutil/windows/os-string.cc
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
#include "file-path-impl.hh"
#include "util.hh"

#ifdef WIN32
#ifdef _WIN32

namespace nix {

Expand Down
2 changes: 1 addition & 1 deletion src/libutil/windows/processes.cc
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
#include <sys/types.h>
#include <unistd.h>

#ifdef WIN32
#ifdef _WIN32

#define WIN32_LEAN_AND_MEAN
#include <windows.h>
Expand Down
2 changes: 1 addition & 1 deletion src/libutil/windows/users.cc
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#include "file-system.hh"
#include "windows-error.hh"

#ifdef WIN32
#ifdef _WIN32
#define WIN32_LEAN_AND_MEAN
#include <windows.h>

Expand Down
2 changes: 1 addition & 1 deletion src/libutil/windows/windows-async-pipe.cc
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#include "windows-async-pipe.hh"
#include "windows-error.hh"

#ifdef WIN32
#ifdef _WIN32

namespace nix::windows {

Expand Down
2 changes: 1 addition & 1 deletion src/libutil/windows/windows-async-pipe.hh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
///@file

#include "file-descriptor.hh"
#ifdef WIN32
#ifdef _WIN32

namespace nix::windows {

Expand Down
2 changes: 1 addition & 1 deletion src/libutil/windows/windows-error.cc
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#include "windows-error.hh"

#ifdef WIN32
#ifdef _WIN32
#include <error.h>
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
Expand Down
2 changes: 1 addition & 1 deletion src/libutil/windows/windows-error.hh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#pragma once
///@file

#ifdef WIN32
#ifdef _WIN32
#include <errhandlingapi.h>

#include "error.hh"
Expand Down
2 changes: 1 addition & 1 deletion src/nix/flake.cc
Original file line number Diff line number Diff line change
Expand Up @@ -938,7 +938,7 @@ struct CmdFlakeInitCommon : virtual Args, EvalCommand
}
continue;
} else
createSymlink(target, to2);
createSymlink(target, os_string_to_string(PathViewNG { to2 }));
}
else
throw Error("file '%s' has unsupported type", from2);
Expand Down

0 comments on commit daab4d1

Please sign in to comment.