Originally posted by: U68G_laurent_NOE
Hi Ayappan,
I do not really agree with your suggestion to use GCC.
I think XLC/C++ is a much better choice to compile softwares for AIX since it's the "native" C compiler for AIX.
And same thing apply to Solaris: the Oracle Developer Studio is a better choice than GCC in my opinion.
The problem here is just to make the whole "configure stuff" correct when XLC/C++ compiler is detected.
Fixing a couple of problems in configure, I've been able to make it work.
I use this XLC/C++ compiler options : -O2 -qlanglvl=extc99 -qro -qroconst -DNDEBUG -D_LINUX_SOURCE_COMPAT -D_LARGE_FILES -D_LARGE_FILE_API -D__PRETTY_FUNCTION__=__func__.
However, there are a lot of other problems in the C code itself (non portable C syntax, GCC specific stuff, missing headers, missing functions, unimplemented peaces of code, bugs, ...).
I have posted on openscap github several patches for AIX and also for Solaris but I still have many patches to publish.
Currently, I've been able to compile the whole code without fatal compiler errors (but still several warnings) on Solaris 10 and AIX 5.3 !
But I know that there are still many places in the code that needs to be fix for both OSes and also some probes that needs to be ported.
BTW, I'm looking for an implementation of the acl_trivial() function (or equivalent) for AIX capable of handling AIXC and NFS4 acl.
I know the entry point to do this is the aclx_get() AIX function but if someone has already written such a function, I would appreciate his help :-)
int acl_trivial(char *path);
DESCRIPTION
The acl_trivial() function is used to determine whether a
file has a trivial ACL. Whether an ACL is trivial depends on
the type of the ACL. A POSIX draft ACL is nontrivial if it
has greater than MIN_ACL_ENTRIES. An NFSv4/ZFS-style ACL is
nontrivial if it either has entries other than owner@,
group@, and everyone@, has inheritance flags set, or is not
ordered in a manner that meets POSIX access control require-
ments.
RETURN VALUES
Upon successful completion, acl_trivial() returns 0 if the
file's ACL is trivial and 1 if the file's ACL is not
trivial. If it could not be determined whether a file's ACL
is trivial, -1 is returned and errno is set to indicate the
error.
I also need an implementation of getifaddrs() function or something equivalent.
Best regards,
Jean-Louis Charton
#AIX-Open-Source-Software#AIXOpenSource