Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
dcdb
dcdb
Commits
69ab2999
Commit
69ab2999
authored
Jan 05, 2015
by
Axel Auweter
Browse files
Fixup for Yosemite. Probably breaks Linux builds. :-(
parent
8fb86e4a
Changes
3
Hide whitespace changes
Inline
Side-by-side
DCDBLib/Makefile
View file @
69ab2999
...
...
@@ -86,6 +86,8 @@ cassandra/Cassandra.h:
@
sed
-e
's/#include "cassandra_types.h"/#include "cassandra_types.h"$$#undef VERSION/'
cassandra/cassandra_constants.h
>
cassandra/cassandra_constants.h_newline
@
cat
cassandra/cassandra_constants.h_newline |
tr
$$
'\n'
>
cassandra/cassandra_constants.h
@
rm
cassandra/cassandra_constants.h_newline
@
# And more fixes needed since clang complains about the thrift generated code's use of namespaces
@
sed
-i
-e
's/using apache/using ::apache/g'
cassandra/cassandra_types.cpp
# Build the documentation
docs
:
$(PUBHEADERS) $(PRIVHEADERS) $(SRC)
...
...
Makefile
View file @
69ab2999
...
...
@@ -4,10 +4,12 @@ LIBRARIES = DCDBLib
PROJECTS
=
FilePusher SysFsPusher CollectAgent ParastationProvider IPMIPusher MontBlancPusher SNMPPusher
CASSANDRA_VERSION
=
1.2.19
THRIFT_VERSION
=
0.9.
1
THRIFT_VERSION
=
0.9.
2
MOSQUITTO_VERSION
=
1.3.5
BOOST_VERSION
=
1.56.0
SNMP_VERSION
=
5.7.2.1
OPENSSL_VERSION
=
1.0.1j
LIBEVENT_VERSION
=
2.0.21-stable
BOOST_VERSION_U
=
$(
subst
.,_,
$(BOOST_VERSION)
)
DISTFILES
=
thrift-
$(THRIFT_VERSION)
.tar.gz
;
https://dist.apache.org/repos/dist/release/thrift/
$(THRIFT_VERSION)
/thrift-
$(THRIFT_VERSION)
.tar.gz
\
...
...
@@ -16,10 +18,14 @@ DISTFILES = thrift-$(THRIFT_VERSION).tar.gz;https://dist.apache.org/repos/dist/r
rudeconfig-5.0.5.tar.gz
;
http://rudeserver.com/config/download/rudeconfig-5.0.5.tar.gz
\
OpenIPMI-2.0.19.tar.gz
;
http://optimate.dl.sourceforge.net/project/openipmi/OpenIPMI%202.0%20Library/OpenIPMI-2.0.19.tar.gz
\
boost_
$(BOOST_VERSION_U)
.tar.gz
;
http://netcologne.dl.sourceforge.net/project/boost/boost/
$(BOOST_VERSION)
/boost_
$(BOOST_VERSION_U)
.tar.gz
\
net-snmp-
$(SNMP_VERSION)
.zip
;
http://netcologne.dl.sourceforge.net/project/net-snmp/net-snmp/
$(SNMP_VERSION)
/net-snmp-
$(SNMP_VERSION)
.zip
net-snmp-
$(SNMP_VERSION)
.zip
;
http://netcologne.dl.sourceforge.net/project/net-snmp/net-snmp/
$(SNMP_VERSION)
/net-snmp-
$(SNMP_VERSION)
.zip
\
openssl-
$(OPENSSL_VERSION)
.tar.gz
;
https://www.openssl.org/source/openssl-
$(OPENSSL_VERSION)
.tar.gz
\
libevent-
$(LIBEVENT_VERSION)
.tar.gz
;
https://cloud.github.com/downloads/libevent/libevent/libevent-
$(LIBEVENT_VERSION)
.tar.gz
FETCH
=
wget
-c
--no-check-certificate
-O
-
OPENSSL_TARGET
=
$(
if
$(
findstring
$(
shell
uname
)
,Darwin
)
,
"darwin64-x86_64-cc"
,
)
MAKETHREADS
?=
$(
if
$(
findstring
$(
shell
uname
)
,Darwin
)
,
$(
shell
sysctl machdep.cpu.thread_count |
cut
-b
27-
)
,
\
$(
if
$(
findstring
$(
shell
uname
)
,Linux
)
,
$(
shell
cat
/proc/cpuinfo |
grep
processor |
wc
-l
)
,4
))
...
...
@@ -63,6 +69,7 @@ info:
@
echo
""
@
echo
"To start, please type:"
@
echo
" make all"
@
echo
$(OPENSSLPREFIX)
clean
:
@
$(
foreach
l,
$(LIBRARIES)
,echo
"Cleaning
$(l)
..."
&&
make
-C
$(l)
clean
&&
echo
;
)
...
...
@@ -92,6 +99,28 @@ $(DCDBDEPSPATH)/.prerequesites: $(DCDBDEPSPATH)/.extract-distfiles
@
echo
""
@
echo
"Preparing patches..."
@
cp
-a
patches
$(DCDBDEPSPATH)
/
$(
eval
S :
=
$(
shell
echo
"
$(DISTFILESPATHS)
"
|
sed
's/.*openssl/openssl/'
|
sed
's/\ .*//'
))
@
if
[
!
-e
$(DCDBDEPSPATH)
/
$(S)
/.installed
]
;
then
\
echo
""
;
\
echo
"Building OpenSSL library..."
;
\
cd
$(DCDBDEPSPATH)
/
$(S)
&&
./Configure
--prefix
=
$(DCDBDEPLOYPATH)
$(OPENSSL_TARGET)
;
\
cd
$(DCDBDEPSPATH)
/
$(S)
&&
make
&&
make install_sw
&&
touch
$(DCDBDEPSPATH)
/
$(S)
/.installed
;
\
else
\
echo
"Skipping OpenSSL library (already built)..."
;
\
fi
$(eval L
:
= $(shell echo "$(DISTFILESPATHS)" | sed 's/.*libevent/libevent/' | sed 's/
\
.*//'))
@
if
[
!
-e
$(DCDBDEPSPATH)
/
$(L)
/.installed
]
;
then
\
echo
""
;
\
echo
"Building libevent library..."
;
\
cd
$(DCDBDEPSPATH)
/
$(L)
&&
./configure
--prefix
=
$(DCDBDEPLOYPATH)
&&
\
make
-j
$(MAKETHREADS)
&&
\
make
install
&&
\
touch
$(DCDBDEPSPATH)
/
$(L)
/.installed
;
\
else
\
echo
"Skipping libevent library (already built)..."
;
\
fi
$(eval M
:
= $(shell echo "$(DISTFILESPATHS)" | sed 's/.*mosquitto/mosquitto/' | sed 's/
\
.*//'))
@
if
[
!
-e
$(DCDBDEPSPATH)
/
$(M)
/.installed
]
;
then
\
...
...
@@ -168,7 +197,7 @@ $(DCDBDEPSPATH)/.prerequesites: $(DCDBDEPSPATH)/.extract-distfiles
cd
$(DCDBDEPSPATH)
/
$(T)
&&
env
CXXFLAGS
=
"
$(CXX11FLAGS)
"
./configure
--prefix
=
$(DCDBDEPLOYPATH)
--without-qt4
--without-csharp
\
--without-java
--without-erlang
--without-python
--without-perl
--without-php
--without-php_extension
\
--without-ruby
--without-haskell
--without-go
--without-d
--without-c_glib
--with-cpp
--with-boost
=
$(DCDBDEPLOYPATH)
\
--enable-libtool-lock
--without-tests
&&
\
--enable-libtool-lock
--without-tests
--disable-tests
--with-openssl
=
$(DCDBDEPLOTPATH)
&&
\
env
CXXFLAGS
=
"
$(CXX11FLAGS)
"
make
-j
$(MAKETHREADS)
&&
\
env
CXXFLAGS
=
"
$(CXX11FLAGS)
"
make
install
&&
touch
$(DCDBDEPSPATH)
/
$(T)
/.installed
;
\
else
\
...
...
patches/net-snmp-5.7.2.1.patch
View file @
69ab2999
...
...
@@ -163,3 +163,168 @@ diff -ruN old/darwin13.h new/darwin13.h
+ */
+#define OPENSSL_NO_SHA256 1
+#define OPENSSL_NO_SHA512 1
diff -ruN old/darwin14.h new/darwin1xi43.h
--- old/include/net-snmp/system/darwin14.h 1970-01-01 01:00:00.000000000 +0100
+++ new/include/net-snmp/system/darwin14.h 2014-10-29 10:03:45.000000000 +0100
@@ -0,0 +1,161 @@
+/*
+ * While Darwin 10 (aka, Mac OS X 10.6 Snow Leopard) is "BSD-like", it differs
+ * substantially enough to not warrant pretending it is a BSD flavor.
+ * This first section are the vestigal BSD remnants.
+ */
+/* Portions of this file are subject to the following copyright(s). See
+ * the Net-SNMP's COPYING file for more details and other copyrights
+ * that may apply:
+ */
+/*
+ * Portions of this file are copyrighted by:
+ * Copyright (C) 2007 Apple, Inc. All rights reserved.
+ * Use is subject to license terms specified in the COPYING file
+ * distributed with the Net-SNMP package.
+ */
+
+/*
+ * BSD systems use a different method of looking up sockaddr_in values
+ */
+/* #define NEED_KLGETSA 1 */
+
+/*
+ * ARP_Scan_Next needs a 4th ifIndex argument
+ */
+#define ARP_SCAN_FOUR_ARGUMENTS 1
+
+#define CHECK_RT_FLAGS 1
+
+/*
+ * this is not good enough before freebsd3!
+ */
+/* #undef HAVE_NET_IF_MIB_H */
+
+/*
+ * This section adds the relevant definitions from generic.h
+ * (a file we don't include here)
+ */
+
+/*
+ * udp_inpcb list symbol, e.g. for mibII/udpTable.c
+ */
+#define INP_NEXT_SYMBOL inp_next
+
+/*
+ * This section defines Mac OS X 10.5 (and later) specific additions.
+ */
+#define darwin 13
+#ifndef darwin13
+# define darwin13 darwin
+#endif
+
+/*
+ * Mac OS X should only use the modern API and definitions.
+ */
+#ifndef NETSNMP_NO_LEGACY_DEFINITIONS
+#define NETSNMP_NO_LEGACY_DEFINITIONS 1
+#endif
+
+/*
+ * looks like the IFTable stuff works better than the mibII versions
+ */
+
+#define NETSNMP_INCLUDE_IFTABLE_REWRITES
+
+/*
+ * use new host resources files as well
+ */
+#define NETSNMP_INCLUDE_HRSWINST_REWRITES
+#define NETSNMP_INCLUDE_HRSWRUN_REWRITES
+#undef NETSNMP_INCLUDE_HRSWRUN_WRITE_SUPPORT
+#define NETSNMP_CAN_GET_DISK_LABEL 1
+
+/*
+ * Enabling this restricts the compiler to mostly public APIs.
+ */
+#ifndef __APPLE_API_STRICT_CONFORMANCE
+#define __APPLE_API_STRICT_CONFORMANCE 1
+#endif
+#ifndef __APPLE_API_UNSTABLE
+#define __APPLE_API_UNSTABLE 1
+#endif
+
+/*
+ * Darwin's tools are capable of building multiple architectures in one pass.
+ * As a result, platform definitions should be deferred until compile time.
+ */
+#ifdef BYTE_ORDER
+# undef WORDS_BIGENDIAN
+# if BYTE_ORDER == BIG_ENDIAN
+# define WORDS_BIGENDIAN 1
+# endif
+#endif
+
+/*
+ * Darwin's tools are capable of building multiple architectures in one pass.
+ * As a result, platform definitions should be deferred until compile time.
+ */
+#ifdef BYTE_ORDER
+# undef WORDS_BIGENDIAN
+# if BYTE_ORDER == BIG_ENDIAN
+# define WORDS_BIGENDIAN 1
+# endif
+#endif
+
+/*
+ * Although Darwin does have a kvm.h file, kvm_openfiles etc. always
+ * return null because /dev/kmem was removed completely in OS X 10.5.
+ */
+#undef HAVE_KVM_H
+#undef HAVE_KVM_GETPROCS
+#undef HAVE_KVM_OPENFILES
+
+/*
+ * Although Darwin does have an fstab.h file, getfsfile etc. always return null.
+ * At least, as of 5.3.
+ */
+#undef HAVE_FSTAB_H
+
+#define SWAPFILE_DIR "/private/var/vm"
+#define SWAPFILE_PREFIX "swapfile"
+
+/*
+ * These apparently used to be in netinet/tcp_timers.h, but went away in
+ * 10.4.2. Define them here til we find out a way to get the real values.
+ */
+#define TCPTV_MIN ( 1*PR_SLOWHZ) /* minimum allowable value */
+#define TCPTV_REXMTMAX ( 64*PR_SLOWHZ) /* max allowable REXMT value */
+
+/*
+ * Because Mac OS X is built on Mach, it does not provide a BSD-compatible
+ * VM statistics API.
+ */
+#define USE_MACH_HOST_STATISTICS 1
+
+/*
+ * This tells code that manipulates IPv6 that the structures are unified,
+ * i.e., IPv4 and IPv6 use the same structs.
+ * This should eventually be replaced with a configure directive.
+ */
+/* #define USE_UNIFIED_IPV6_STRUCTS 1 */
+#undef STRUCT_in6pcb_HAS_inp_vflag
+
+/*
+ * utility macro used in several darwin specific files
+ */
+#define SNMP_CFRelease(x) do { if (x) { CFRelease(x); x = NULL; } } while(0)
+
+/*
+ * Mac OS X runs on both PPC and Intel hardware,
+ * which handle udpTable index values differently
+ */
+#include <TargetConditionals.h>
+#ifdef TARGET_RT_LITTLE_ENDIAN
+#define UDP_ADDRESSES_IN_HOST_ORDER 1
+#endif
+
+/*
+ * as of 7/2010, openssl on darwin does not have sha256
+ */
+#define OPENSSL_NO_SHA256 1
+#define OPENSSL_NO_SHA512 1
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment