Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BUG: Use large file fallocate on 32 bit linux platforms #25630

Merged
merged 1 commit into from
Jan 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 3 additions & 0 deletions numpy/core/feature_detection_stdio.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
#define _GNU_SOURCE
#include <stdio.h>
#include <fcntl.h>

#if 0 /* Only for setup_common.py, not the C compiler */
off_t ftello(FILE *stream);
int fseeko(FILE *stream, off_t offset, int whence);
int fallocate(int, int, off_t, off_t);
#endif
5 changes: 3 additions & 2 deletions numpy/core/src/multiarray/convert.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,9 @@
#include "array_coercion.h"
#include "refcount.h"

int
fallocate(int fd, int mode, off_t offset, off_t len);
#if defined(HAVE_FALLOCATE) && defined(__linux__)
#include <fcntl.h>
#endif

/*
* allocate nbytes of diskspace for file fp
Expand Down