From 5bdbd74d591e87e327835faf71741eacab3ce00f Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Tue, 21 Jul 2015 11:02:33 +0200 Subject: [PATCH] net: add header Features.hxx For improved portability of the net library to projects without autoconf. --- src/net/Features.hxx | 27 +++++++++++++++++++++++++++ src/net/StaticSocketAddress.hxx | 1 + 2 files changed, 28 insertions(+) create mode 100644 src/net/Features.hxx diff --git a/src/net/Features.hxx b/src/net/Features.hxx new file mode 100644 index 000000000..05dcc5659 --- /dev/null +++ b/src/net/Features.hxx @@ -0,0 +1,27 @@ +/* + * Copyright (C) 2003-2015 The Music Player Daemon Project + * http://www.musicpd.org + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along + * with this program; if not, write to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + */ + +#ifndef NET_FEATURES_HXX +#define NET_FEATURES_HXX + +/* feature macros are defined in config.h, and this header verifies + that it has been included earlier */ +#include "check.h" + +#endif diff --git a/src/net/StaticSocketAddress.hxx b/src/net/StaticSocketAddress.hxx index 475c323e0..4cf294c1e 100644 --- a/src/net/StaticSocketAddress.hxx +++ b/src/net/StaticSocketAddress.hxx @@ -31,6 +31,7 @@ #define STATIC_SOCKET_ADDRESS_HXX #include "SocketAddress.hxx" +#include "Features.hxx" #include "Compiler.h" #include