* details.
*
* You should have received a copy of the GNU Lesser General Public License
- * along with this file; if not, see http://www.gnu.org/licenses/.
+ * along with this file; if not, see https://www.gnu.org/licenses/.
*/
#ifdef HAVE_CONFIG_H
#include "wimlib/error.h"
#include "wimlib/file_io.h"
#include "wimlib/util.h"
-#include "wimlib/win32.h" /* For pread(), pwrite() replacements */
+
+#ifdef _WIN32
+# include "wimlib/win32.h"
+# define read win32_read
+# define write win32_write
+# define pread win32_pread
+# define pwrite win32_pwrite
+#endif
/*
* Wrapper around read() that checks for errors and keeps retrying until all