{"thread":{"id":"6052","subject":"[PATCH] Define -D__BSD_VISIBLE for FreeBSD","startedAt":"2006-12-21T09:00:58Z","lastAt":"2006-12-21T10:09:52Z","messageCount":3,"participants":["Rocco Rutte","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"29917","messageId":"11666916581935-git-send-email-pdmef@gmx.net","threadId":"6052","inReplyTo":null,"subject":"[PATCH] Define -D__BSD_VISIBLE for FreeBSD","fromName":"Rocco Rutte","fromEmail":"pdmef@gmx.net","sentAt":"2006-12-21T09:00:58Z","receivedAt":"2006-12-21T09:00:58Z","isPatch":true,"sender":{"key":"pdmef@gmx.net","avatar":null},"body":"FreeBSD (6-STABLE) \"hides\" many declarations (like fchmod(), IPPROTO_IPV6,\netc.) within '#ifdef __BSD_VISIBLE' blocks. Without this flag, compilation\nwill produce lots of warnings and will even fail to compile daemon.c\nsince IPPROTO_IPV6 isn't available without it.\n\n>From looking at some include files of OpenBSD and NetBSD (via cvsweb)\nthey don't seem to need this flag.\n\nSigned-off-by: Rocco Rutte <pdmef@gmx.net>\n---\n Makefile |    2 +-\n 1 files changed, 1 insertions(+), 1 deletions(-)\n\ndiff --git a/Makefile b/Makefile\nindex 7651104..46c49e0 100644\n--- a/Makefile\n+++ b/Makefile\n@@ -366,7 +366,7 @@ ifeq ($(uname_O),Cygwin)\n endif\n ifeq ($(uname_S),FreeBSD)\n \tNEEDS_LIBICONV = YesPlease\n-\tBASIC_CFLAGS += -I/usr/local/include\n+\tBASIC_CFLAGS += -I/usr/local/include -D__BSD_VISIBLE\n \tBASIC_LDFLAGS += -L/usr/local/lib\n endif\n ifeq ($(uname_S),OpenBSD)\n-- \n1.4.4.2.g9474f\n"},{"id":"29923","messageId":"7vk60lbnvj.fsf@assigned-by-dhcp.cox.net","threadId":"6052","inReplyTo":"11666916581935-git-send-email-pdmef@gmx.net","subject":"Re: [PATCH] Define -D__BSD_VISIBLE for FreeBSD","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2006-12-21T09:26:56Z","receivedAt":"2006-12-21T09:26:56Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Rocco Rutte <pdmef@gmx.net> writes:\n\n> FreeBSD (6-STABLE) \"hides\" many declarations (like fchmod(), IPPROTO_IPV6,\n> etc.) within '#ifdef __BSD_VISIBLE' blocks. Without this flag, compilation\n> will produce lots of warnings and will even fail to compile daemon.c\n> since IPPROTO_IPV6 isn't available without it.\n\nI've looked at OpenBSD header files and my impression was that\nthe symbol __BSD_VISIBLE was pretty much internal to the\nimplementation, and the programs are not expected to set it\nexcept by defining more public feature macros, such as\n_BSD_SOURCE.  So I feel a bit uneasy about your approach.\n\nWe've changed this exact area quite heavily during the last\n24-hours (not in Makefile but in git-compat-util.h).  Do you\nsee the problem with the latest 'master'?\n"},{"id":"29927","messageId":"20061221100952.GA15424@peter.daprodeges.fqdn.th-h.de","threadId":"6052","inReplyTo":"7vk60lbnvj.fsf@assigned-by-dhcp.cox.net","subject":"Re: [PATCH] Define -D__BSD_VISIBLE for FreeBSD","fromName":"Rocco Rutte","fromEmail":"pdmef@gmx.net","sentAt":"2006-12-21T10:09:52Z","receivedAt":"2006-12-21T10:09:52Z","isPatch":true,"sender":{"key":"pdmef@gmx.net","avatar":null},"body":"Hi,\n\n* Junio C Hamano [06-12-21 01:26:56 -0800] wrote:\n\n>We've changed this exact area quite heavily during the last\n>24-hours (not in Makefile but in git-compat-util.h).  Do you\n>see the problem with the latest 'master'?\n\nNow when looking at sys/cdefs.h, the \n85023577a8f4b540aa64aa37f6f44578c0c305a3 commit seems to have broken \nthings. So the patch should be ignored and I'll try to come up with a \nbetter one not using implementation-defined __-macros...\n\n   bye, Rocco\n-- \n:wq!\n"}]}