mirror of
https://git.freebsd.org/ports.git
synced 2025-05-29 17:36:28 -04:00
This Ada05 library contains various utility packages for building Ada05 applications. This includes: o A logging framework close to Java log4j framework o Support for properties o A serialization/deserialization framework for XML, JSON, CSV o Ada beans framework o Encoding/decoding framework (Base16, Base64, SHA, HMAC-SHA) o A composing stream framework (raw, files, buffers, pipes, sockets) o Several concurrency tools (reference counters, counters, pools, fifos, arrays) o Process creation and pipes o Support for loading shared libraries (on Windows or Unix) o HTTP client library on top of CURL or AWS Ada Util also provides a small test utility library on top of Ahven to help in writing unit tests.
50 lines
1.9 KiB
C
50 lines
1.9 KiB
C
--- support/utilgen.c.orig 2015-10-11 18:41:42 UTC
|
|
+++ support/utilgen.c
|
|
@@ -18,6 +18,7 @@
|
|
# define _LARGEFILE64_SOURCE
|
|
#endif
|
|
#include <stdio.h>
|
|
+#include <string.h>
|
|
#include <unistd.h>
|
|
#include <fcntl.h>
|
|
#include <sys/types.h>
|
|
@@ -181,6 +182,39 @@ void gen_stat(void)
|
|
printf(" end record;\n");
|
|
printf(" pragma Convention (C_Pass_By_Copy, Stat_Type);\n");
|
|
printf("\n");
|
|
+#elif defined(__DragonFly__)
|
|
+ struct stat st;
|
|
+
|
|
+ gen_type("uint16_t", UNSIGNED, sizeof(uint16_t));
|
|
+ gen_type("u_int32_t", UNSIGNED, sizeof(u_int32_t));
|
|
+ gen_type("int32_t", SIGNED, sizeof(int32_t));
|
|
+ gen_type("int64_t", SIGNED, sizeof(int64_t));
|
|
+
|
|
+ printf(" STAT_NAME : constant String := \"stat\";\n");
|
|
+ printf(" FSTAT_NAME : constant String := \"fstat\";\n");
|
|
+ printf(" type Stat_Type is record\n");
|
|
+ printf(" st_ino : ino_t;\n");
|
|
+ printf(" st_nlink : nlink_t;\n");
|
|
+ printf(" st_dev : dev_t;\n");
|
|
+ printf(" st_mode : mode_t;\n");
|
|
+ printf(" st_padding1 : uint16_t;\n");
|
|
+ printf(" st_uid : uid_t;\n");
|
|
+ printf(" st_gid : gid_t;\n");
|
|
+ printf(" st_rdev : dev_t;\n");
|
|
+ printf(" st_atim : Timespec;\n");
|
|
+ printf(" st_mtim : Timespec;\n");
|
|
+ printf(" st_ctim : Timespec;\n");
|
|
+ printf(" st_size : off_t;\n");
|
|
+ printf(" st_blocks : int64_t;\n");
|
|
+ printf(" st_blksize : u_int32_t;\n");
|
|
+ printf(" st_flags : u_int32_t;\n");
|
|
+ printf(" st_gen : u_int32_t;\n");
|
|
+ printf(" st_lspare : int32_t;\n");
|
|
+ printf(" st_qspare1 : int64_t;\n");
|
|
+ printf(" st_qspare2 : int64_t;\n");
|
|
+ printf(" end record;\n");
|
|
+ printf(" pragma Convention (C_Pass_By_Copy, Stat_Type);\n");
|
|
+ printf("\n");
|
|
#elif defined(__FreeBSD__)
|
|
struct stat st;
|
|
|