summaryrefslogtreecommitdiff
path: root/arscan.c
diff options
context:
space:
mode:
authorPaul Smith <psmith@gnu.org>2000-04-22 02:11:17 +0000
committerPaul Smith <psmith@gnu.org>2000-04-22 02:11:17 +0000
commit5ed9fb46b28be4a703c1d88915fa150f0b74d5f4 (patch)
tree61047b6120465235eb65f70345fb3afd4b8a063b /arscan.c
parentf9c91ec34d9427c35bceec9b025a0bb20c9ec17f (diff)
downloadgunmake-5ed9fb46b28be4a703c1d88915fa150f0b74d5f4.tar.gz
* Various bug fixes.
Diffstat (limited to 'arscan.c')
-rw-r--r--arscan.c20
1 files changed, 19 insertions, 1 deletions
diff --git a/arscan.c b/arscan.c
index 2b90705..5cadbe6 100644
--- a/arscan.c
+++ b/arscan.c
@@ -232,7 +232,25 @@ ar_scan (archive, function, arg)
#endif
#ifndef WINDOWS32
-# include <ar.h>
+# ifndef __BEOS__
+# include <ar.h>
+# else
+ /* BeOS 5 doesn't have <ar.h> but has archives in the same format
+ * as many other Unices. This was taken from GNU binutils for BeOS.
+ */
+# define ARMAG "!<arch>\n" /* String that begins an archive file. */
+# define SARMAG 8 /* Size of that string. */
+# define ARFMAG "`\n" /* String in ar_fmag at end of each header. */
+struct ar_hdr
+ {
+ char ar_name[16]; /* Member file name, sometimes / terminated. */
+ char ar_date[12]; /* File date, decimal seconds since Epoch. */
+ char ar_uid[6], ar_gid[6]; /* User and group IDs, in ASCII decimal. */
+ char ar_mode[8]; /* File mode, in ASCII octal. */
+ char ar_size[10]; /* File size, in ASCII decimal. */
+ char ar_fmag[2]; /* Always contains ARFMAG. */
+ };
+# endif
#else
/* These should allow us to read Windows (VC++) libraries (according to Frank
* Libbrecht <frankl@abzx.belgium.hp.com>)