aboutsummaryrefslogtreecommitdiff
path: root/tests/zfs-tests/cmd/mmap_seek.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/zfs-tests/cmd/mmap_seek.c')
-rw-r--r--tests/zfs-tests/cmd/mmap_seek.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/tests/zfs-tests/cmd/mmap_seek.c b/tests/zfs-tests/cmd/mmap_seek.c
index bb36527aafee..2d250554a13f 100644
--- a/tests/zfs-tests/cmd/mmap_seek.c
+++ b/tests/zfs-tests/cmd/mmap_seek.c
@@ -6,7 +6,7 @@
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
- * or http://www.opensolaris.org/os/licensing.
+ * or https://opensource.org/licenses/CDDL-1.0.
* See the License for the specific language governing permissions
* and limitations under the License.
*
@@ -35,6 +35,16 @@
#include <linux/fs.h>
#endif
+/* some older uClibc's lack the defines, so we'll manually define them */
+#ifdef __UCLIBC__
+#ifndef SEEK_DATA
+#define SEEK_DATA 3
+#endif
+#ifndef SEEK_HOLE
+#define SEEK_HOLE 4
+#endif
+#endif
+
static void
seek_data(int fd, off_t offset, off_t expected)
{