summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 75ecb11)
raw | patch | inline | side by side (parent: 75ecb11)
author | oetiker <oetiker@a5681a0c-68f1-0310-ab6d-d61299d08faa> | |
Sat, 6 Sep 2008 10:43:07 +0000 (10:43 +0000) | ||
committer | oetiker <oetiker@a5681a0c-68f1-0310-ab6d-d61299d08faa> | |
Sat, 6 Sep 2008 10:43:07 +0000 (10:43 +0000) |
by the os ... this should also fix problems for solaris 2.8 and other
non getopt_long oses who were not taken care of anymore after the intriduction of librrd.sym
git-svn-id: svn://svn.oetiker.ch/rrdtool/trunk@1481 a5681a0c-68f1-0310-ab6d-d61299d08faa
non getopt_long oses who were not taken care of anymore after the intriduction of librrd.sym
git-svn-id: svn://svn.oetiker.ch/rrdtool/trunk@1481 a5681a0c-68f1-0310-ab6d-d61299d08faa
program/bindings/perl-piped/RRDp.pm | patch | blob | history | |
program/configure.ac | patch | blob | history | |
program/src/Makefile.am | patch | blob | history | |
program/src/librrd.sym | [deleted file] | patch | blob | history |
program/src/librrd.sym.in | [new file with mode: 0644] | patch | blob |
program/src/rrd_tool.h | patch | blob | history |
index 0a28506c28fe8533a1d03a1746a5faa6105cb658..9f577744a10fbc6fd45b9a064d1c227bc8d05b55 100644 (file)
Tobias Oetiker <tobi@oetiker.ch>
=cut
+
#' this is to make cperl.el happy
use strict;
diff --git a/program/configure.ac b/program/configure.ac
index 9089742050c6c8f7385e8f00f91581d4578d7420..7bd2913f37ccd32f959b50bf616f1e1c4837dce0 100644 (file)
--- a/program/configure.ac
+++ b/program/configure.ac
dnl the official version number is
dnl a.b.c
-AC_INIT([rrdtool],[1.3.1])
+AC_INIT([rrdtool],[1.3.2])
dnl for testing a numberical version number comes handy
dnl the released version are
dnl a.bccc
dnl the devel versions will be something like
dnl a.b999yymmddhh
-NUMVERS=1.3001
+NUMVERS=1.3002
AC_SUBST(NUMVERS)
-dnl for the linker to understand which version the library is compatible with
-dnl we must keep a separate library version cout of the format c:r:a if any
-dnl if only implementation changed but all interfaces are kept, do r++
-dnl when only functionality was added do c++,r=0,a++
-dnl if any functionality was removed do c++,r=0,a=0.
+dnl for the linker to understand which versions the library are compatible with
+dnl each other we must keep a separate library version cout of the format c:r:a.
+dnl - if only implementation changed but all interfaces are kept, do r++
+dnl - if only functionality was added do c++,r=0,a++
+dnl - if any functionality was removed do c++,r=0,a=0.
dnl
dnl see http://sourceware.org/autobook/autobook/autobook_91.html
dnl
-LIBVERS=4:0:0
+LIBVERS=4:1:0
AC_SUBST(LIBVERS)
AC_CANONICAL_TARGET
AC_CHECK_FUNC(acos, , AC_CHECK_LIB(m, acos))
-
dnl add pic flag in any case this makes sure all our code is relocatable
eval `./libtool --config | grep pic_flag`
CFLAGS="$CFLAGS $pic_flag"
have_broken_isfinite=no],have_broken_isfinite=yes,[
case "${target}" in
hppa*-*-hpux*) have_broken_isfinite=yes ;;
- sparc-sun-solaris2.8) have_broken_isfinite=yes ;;
+ *-sun-solaris2.8) have_broken_isfinite=yes ;;
*) have_broken_isfinite=no ;;
esac])
])
CONFIGURE_PART(Resolve Portability Issues)
+dnl Do we need getopt_long
+
+build_getopt=no
+RRD_GETOPT_LONG="#"
+AC_CHECK_FUNC(getopt_long,[],[
+RRD_GETOPT_LONG="getopt_long"
+build_getopt=yes
+])
+AC_SUBST(RRD_GETOPT_LONG)
+AM_CONDITIONAL(BUILD_GETOPT,[test $build_getopt = yes])
+
dnl what does realloc do if it gets called with a NULL pointer
AC_CACHE_CHECK([if realloc can deal with NULL], rd_cv_null_realloc,
AC_CONFIG_FILES([doc/Makefile])
AC_CONFIG_FILES([po/Makefile.in])
AC_CONFIG_FILES([src/Makefile])
+AC_CONFIG_FILES([src/librrd.sym])
AC_CONFIG_FILES([bindings/Makefile])
AC_CONFIG_FILES([bindings/tcl/Makefile])
AC_CONFIG_FILES([bindings/tcl/ifOctets.tcl])
echo "Config is DONE!"
echo
echo " With MMAP IO: $enable_mmap"
+echo " Build rrd_getopt: $build_getopt"
echo " Static programs: $staticprogs"
echo " Perl Modules: $COMP_PERL"
echo " Perl Binary: $PERL"
index c567679469fa42f4b4bc603230ad8988615b4588..a88eef31592c959ea36ef5b3638193cda468e117 100644 (file)
--- a/program/src/Makefile.am
+++ b/program/src/Makefile.am
AM_CPPFLAGS = -DRRD_DEFAULT_FONT=\"$(RRD_DEFAULT_FONT)\" -DNUMVERS=@NUMVERS@
UPD_C_FILES = \
- rrd_getopt.c \
- rrd_getopt1.c \
rrd_parsetime.c \
rrd_hw.c \
rrd_hw_math.c \
fnv.h rrd_graph.h \
rrd_is_thread_safe.h
+if BUILD_GETOPT
+noinst_HEADERS += rrd_getopt.h
+UPD_C_FILES += rrd_getopt.c rrd_getopt1.c
+endif
+
noinst_LTLIBRARIES = librrdupd.la
lib_LTLIBRARIES = librrd.la
# strftime is here because we do not usually need it. unices have propper
# iso date support
-EXTRA_DIST= strftime.c strftime.h \
+EXTRA_DIST= strftime.c strftime.h rrd_getopt.c rrd_getopt1.c rrd_getopt.h \
win32comp.c rrd_thread_safe_nt.c get_ver.awk librrd.sym
diff --git a/program/src/librrd.sym b/program/src/librrd.sym
--- a/program/src/librrd.sym
+++ /dev/null
@@ -1,50 +0,0 @@
-rrd_clear_error
-rrd_close
-rrd_create
-rrd_create_r
-rrd_dontneed
-rrd_dump
-rrd_dump_r
-rrd_fetch
-rrd_fetch_r
-rrd_first
-rrd_first_r
-rrd_flush
-rrd_free
-rrd_free_context
-rrd_freemem
-rrd_get_context
-rrd_get_error
-rrd_graph
-rrd_graph_v
-rrd_info
-rrd_info_free
-rrd_info_print
-rrd_info_push
-rrd_init
-rrd_last
-rrd_last_r
-rrd_lastupdate
-rrd_lock
-rrd_new_context
-rrd_open
-rrd_parsetime
-rrd_proc_start_end
-rrd_read
-rrd_resize
-rrd_restore
-rrd_seek
-rrd_set_error
-rrd_set_to_DINF
-rrd_set_to_DNAN
-rrd_strerror
-rrd_strversion
-rrd_tell
-rrd_test_error
-rrd_tune
-rrd_update
-rrd_update_r
-rrd_update_v
-rrd_version
-rrd_write
-rrd_xport
diff --git a/program/src/librrd.sym.in b/program/src/librrd.sym.in
--- /dev/null
@@ -0,0 +1,51 @@
+rrd_clear_error
+rrd_close
+rrd_create
+rrd_create_r
+rrd_dontneed
+rrd_dump
+rrd_dump_r
+rrd_fetch
+rrd_fetch_r
+rrd_first
+rrd_first_r
+rrd_flush
+rrd_free
+rrd_free_context
+rrd_freemem
+rrd_get_context
+rrd_get_error
+rrd_graph
+rrd_graph_v
+rrd_info
+rrd_info_free
+rrd_info_print
+rrd_info_push
+rrd_init
+rrd_last
+rrd_last_r
+rrd_lastupdate
+rrd_lock
+rrd_new_context
+rrd_open
+rrd_parsetime
+rrd_proc_start_end
+rrd_read
+rrd_resize
+rrd_restore
+rrd_seek
+rrd_set_error
+rrd_set_to_DINF
+rrd_set_to_DNAN
+rrd_strerror
+rrd_strversion
+rrd_tell
+rrd_test_error
+rrd_tune
+rrd_update
+rrd_update_r
+rrd_update_v
+rrd_version
+rrd_write
+rrd_xport
+@RRD_GETOPT_LONG@
diff --git a/program/src/rrd_tool.h b/program/src/rrd_tool.h
index 8f0e3c392a9b5eefc97b506934328ab630b340dc..131dcbb97e86fd570a8a97647fb96c72fc1d49ef 100644 (file)
--- a/program/src/rrd_tool.h
+++ b/program/src/rrd_tool.h
#endif
/* local include files -- need to be after the system ones */
+#ifdef HAVE_GETOPT_LONG
+#define _GNU_SOURCE
+#include <getopt.h>
+#else
#include "rrd_getopt.h"
-#include "rrd_format.h"
+#endif
#ifndef max
#define max(a,b) ((a) > (b) ? (a) : (b))