From 1f098efb7370a0b28306d10681e21883fb1c1507 Mon Sep 17 00:00:00 2001 From: Russ Cox Date: Sat, 15 Aug 2020 20:46:23 -0400 Subject: all: a few more #define tricks for AIX This should make the AIX build finally work. Fixes #400. --- src/cmd/sam/sam.h | 3 +++ src/libdiskfs/hfs.h | 33 +++++++++++++++++++++++++++++++++ 2 files changed, 36 insertions(+) (limited to 'src') diff --git a/src/cmd/sam/sam.h b/src/cmd/sam/sam.h index c11163ef..aae39b4a 100644 --- a/src/cmd/sam/sam.h +++ b/src/cmd/sam/sam.h @@ -9,6 +9,9 @@ #undef warn #define warn samwarn +#undef class +#define class samclass + /* * BLOCKSIZE is relatively small to keep memory consumption down. */ diff --git a/src/libdiskfs/hfs.h b/src/libdiskfs/hfs.h index bf5ebc9f..dc30aeed 100644 --- a/src/libdiskfs/hfs.h +++ b/src/libdiskfs/hfs.h @@ -75,6 +75,39 @@ enum /* catalog record types */ Folder = 1, File, FolderThread, FileThread, + /* some systems have these defined */ + #undef IEXEC + #undef IWRITE + #undef IREAD + #undef ISVTX + #undef ISGID + #undef ISUID + #undef IFMT + #undef IFIFO + #undef IFCHR + #undef IFDIR + #undef IFBLK + #undef IFREG + #undef IFLNK + #undef IFSOCK + #undef IFWHT + + #define IEXEC HFS_IEXEC + #define IWRITE HFS_IWRITE + #define IREAD HFS_IREAD + #define ISVTX HFS_ISVTX + #define ISGID HFS_ISGID + #define ISUID HFS_ISUID + #define IFMT HFS_IFMT + #define IFIFO HFS_IFIFO + #define IFCHR HFS_IFCHR + #define IFDIR HFS_IFDIR + #define IFBLK HFS_IFBLK + #define IFREG HFS_IFREG + #define IFLNK HFS_IFLNK + #define IFSOCK HFS_IFSOCK + #define IFWHT HFS_IFWHT + /* permissions in Inode.mode */ IEXEC = 00100, IWRITE = 0200, -- cgit v1.2.3