All of lore.kernel.org
 help / color / mirror / Atom feed
* problem with def of inet_ntop() in git-compat-util.h as well as other places
@ 2014-08-27 19:15 dev
  2014-08-27 19:28 ` Jeff King
  2014-08-27 19:31 ` Jonathan Nieder
  0 siblings, 2 replies; 11+ messages in thread
From: dev @ 2014-08-27 19:15 UTC (permalink / raw)
  To: git



per :


  http://pubs.opengroup.org/onlinepubs/009695399/functions/inet_ntop.html


The last parameter is not unsigned long but socklen_t size.

This causes a problem on things like Solaris :

 * new build flags
    CC credential-store.o
"git-compat-util.h", line 516: error: identifier redeclared: inet_ntop
        current : function(int, pointer to const void, pointer to char,
unsigned long) returning pointer to const char
        previous: function(int, pointer to const void, pointer to char,
unsigned int) returning pointer to const char :
"/usr/include/arpa/inet.h", line 68
cc: acomp failed for credential-store.c
gmake: *** [credential-store.o] Error 2



Therefore I hacked around it with a #ifdef __SunOS_5_10 for the sake of
getting the build done.


However ran into a problem, again, with compat/inet_ntop.c which seems
to be not needed at all since inet_ntop() handles both IPv6 and IPv4
just fine.   Really I don't see why this file gets carted around so much
as it is even in the Apache svn codebase as well.

Not needed.

Therefore I commented out the inet_ntop() function entirely therein.

Also the Makefile's generated are all borked full of GCCism "CFLAGS = -g
-O2 -Wall"  which means very little on some OS wherein the gcc compiler
is not the default.  Love GCC. I bootstrap it all the time. However this
is Solaris and am using ORacle Studio 12.3 compilers and therefore the
CFLAGS in the Makefiles are just silly.  Lastly, the linkage to libintl
should look in /usr/local/lib if the LD_LIBRARY_PATH and other env vars
are setup correctly. However the Makefile's seem to miss this fact and
-lintl needs to be manually hacked into place.

Still doesn't "just build" yet.  Getting there :-\

dev

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2014-08-30 15:26 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-08-27 19:15 problem with def of inet_ntop() in git-compat-util.h as well as other places dev
2014-08-27 19:28 ` Jeff King
2014-08-27 19:48   ` dev
2014-08-27 20:06     ` Jeff King
2014-08-27 21:00       ` dev
2014-08-27 22:28         ` Jonathan Nieder
2014-08-28  4:54           ` dev
2014-08-29  0:05             ` brian m. carlson
2014-08-30 15:25               ` dev
2014-08-28  6:51           ` dev
2014-08-27 19:31 ` Jonathan Nieder

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.