summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichele Calgaro <michele.calgaro@yahoo.it>2026-01-16 13:17:11 +0900
committerMichele Calgaro <michele.calgaro@yahoo.it>2026-01-16 13:17:11 +0900
commite98c9c2111efec7c3639035652443760a0ed98e2 (patch)
tree4badc712846ddb2b407bef9536f60b34b827502f
parent199ef1ce1fb4b0c7e8fff9777df54a8c9cb6c684 (diff)
downloadfilelight-drop/hpux-support.tar.gz
filelight-drop/hpux-support.zip
Remove support for HPUX, which is discontinued and does not provide a c++17 complaint compiler.drop/hpux-support
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
-rw-r--r--src/part/localLister.cpp24
1 files changed, 8 insertions, 16 deletions
diff --git a/src/part/localLister.cpp b/src/part/localLister.cpp
index 7e0fb8a..94f6cf0 100644
--- a/src/part/localLister.cpp
+++ b/src/part/localLister.cpp
@@ -81,26 +81,18 @@ namespace Filelight
#endif /* !_POSIX_SOURCE && BSIZE */
#else /* HAVE_STRUCT_STAT_ST_BLOCKS */
/* Some systems, like Sequents, return st_blksize of 0 on pipes.
- Also, when running `rsh hpux11-system cat any-file', cat would
- determine that the output stream had an st_blksize of 2147421096.
So here we arbitrarily limit the `optimal' block size to 4MB.
If anyone knows of a system for which the legitimate value for
st_blksize can exceed 4MB, please report it as a bug in this code. */
#define ST_BLKSIZE(statbuf) ((0 < (statbuf).st_blksize && (statbuf).st_blksize <= (1 << 22)) /* 4MiB */ ? (statbuf).st_blksize : DEV_BSIZE)
- #if defined hpux || defined __hpux__ || defined __hpux
- /* HP-UX counts st_blocks in 1024-byte units.
- This loses when mixing HP-UX and BSD filesystems with NFS. */
- #define ST_NBLOCKSIZE 1024
- #else /* !hpux */
- #if defined _AIX && defined _I386
- /* AIX PS/2 counts st_blocks in 4K units. */
- #define ST_NBLOCKSIZE (4 * 1024)
- #else /* not AIX PS/2 */
- #if defined _CRAY
- #define ST_NBLOCKS(statbuf) (S_ISREG ((statbuf).st_mode) || S_ISDIR ((statbuf).st_mode) ? (statbuf).st_blocks * ST_BLKSIZE(statbuf)/ST_NBLOCKSIZE : 0)
- #endif /* _CRAY */
- #endif /* not AIX PS/2 */
- #endif /* !hpux */
+ #if defined _AIX && defined _I386
+ /* AIX PS/2 counts st_blocks in 4K units. */
+ #define ST_NBLOCKSIZE (4 * 1024)
+ #else /* not AIX PS/2 */
+ #if defined _CRAY
+ #define ST_NBLOCKS(statbuf) (S_ISREG ((statbuf).st_mode) || S_ISDIR ((statbuf).st_mode) ? (statbuf).st_blocks * ST_BLKSIZE(statbuf)/ST_NBLOCKSIZE : 0)
+ #endif /* _CRAY */
+ #endif /* not AIX PS/2 */
#endif /* HAVE_STRUCT_STAT_ST_BLOCKS */
#ifndef ST_NBLOCKS