Forum: Cfengine Help Subject: Successful 3.1.4 build on HP-UX 11.11 Author: mvpel Link to topic: https://cfengine.com/forum/read.php?3,21894,21894#msg-21894
I was able to build Cfengine 3.1.4 on HP-UX 11i v1 (11.11) with only a couple of minor adjustments. Mainly, this older version of HP-UX doesn't have the "setlinebuf()" call, so it had to be turned into a macro. I put this text at the end of the src/conf.h.in file: /* HP-UX 11i v1 (B.11.11) does not have setlinebuf, so use setvbuf instead */ #ifdef HPuUX #define setlinebuf(_STREAM_) (void)setvbuf(_STREAM_, NULL, _IOLBF, BUFSIZ) #endif This is not ideal, since HP-UX 11.31 does have setlinebuf() as I understand it, so the best solution would be to add a "HAVE_SETLINEBUF" in Configure and activate this macro on HP-UX only if the system doesn't have it. I haven't done much of anything with autoconf before, so I'm not sure of the proper approach to making the change in that way at the moment. I'll post if I come up with something, or someone else can feel free. In addtion, during the compile it looked for the "libcomp.sl" library, which is bundled as part of the HP-UX commercial compiler in /opt/langtools/lib/libcomp.sl, but this does not appear to be a runtime dependency. I was fortunate to have a copy of the HP ANSI C compiler here, as it's used by our engineering teams, but I'm not sure where someone would get it otherwise. It may be a side-effect of this gcc package I'm using, since I don't see any reference to -lcomp in the source tree. It also needed the HP OpenSSL bundle for the libcrypto.sl library; as well as a suitable database library, of course, and the PCRE library, which are available from the HP Porting & Archive Centre for HP-UX: PCRE package at PARC ... Berkeley DB at PARC I'm mulling possibilities for packaging it in such a way that it can be a standalone single-package installation including all dependencies but at the same time not interfere with the installation of, or any installed, dependent packages, preferably without resorting to static linking. Maybe library filesets within the cfengine PSF which have exrequisites for the full product they come from, or something like that. _______________________________________________ Help-cfengine mailing list Help-cfengine@cfengine.org https://cfengine.org/mailman/listinfo/help-cfengine