* images/mibs installed with "make install"
authorAlex Kirhenshtein <alk@netxms.org>
Wed, 25 May 2005 11:02:08 +0000 (11:02 +0000)
committerAlex Kirhenshtein <alk@netxms.org>
Wed, 25 May 2005 11:02:08 +0000 (11:02 +0000)
* pkgdatadir (by default - $prefix/share/netxms/") used as default datadir
* sql filed are installed now as data, not as scripts (w/o +x)

.gitattributes
configure.ac
contrib/Makefile.am
contrib/mibs/Makefile.am [new file with mode: 0644]
images/Makefile.am
sql/Makefile.am
src/server/include/nms_core.h

index 2b2c45d..539db57 100644 (file)
@@ -42,6 +42,7 @@ contrib/mibs/IF-MIB.txt -text
 contrib/mibs/INET-ADDRESS-MIB.txt -text
 contrib/mibs/IP-MIB.txt -text
 contrib/mibs/MTA-MIB.txt -text
+contrib/mibs/Makefile.am -text
 contrib/mibs/NET-SNMP-AGENT-MIB.txt -text
 contrib/mibs/NET-SNMP-MIB.txt -text
 contrib/mibs/NET-SNMP-MONITOR-MIB.txt -text
index 7bd3549..47fe03c 100644 (file)
@@ -1,4 +1,4 @@
-# $Id: configure.ac,v 1.82 2005-05-25 10:12:26 victor Exp $
+# $Id: configure.ac,v 1.83 2005-05-25 11:02:07 alk Exp $
 #
 # Process this file with autoconf to produce a configure script.
 #
@@ -348,6 +348,9 @@ AC_SUBST(PTHREAD_LIBS)
 # Extensions to posix threads
 AC_CHECK_FUNCS([pthread_cond_reltimedwait_np])
 
+# misc
+CPPFLAGS="$CPPFLAGS -DDATADIR=\\\"\${pkgdatadir}\\\""
+
 # --------------------------------------------------------------------------
 
 # shared libs versions
@@ -403,6 +406,7 @@ AC_CONFIG_FILES([
        contrib/dct/Makefile
        contrib/startup/Makefile
        contrib/startup/redhat/Makefile
+       contrib/mibs/Makefile
        doc/Makefile
        images/Makefile
        include/Makefile
index a00fc10..7abee06 100644 (file)
@@ -10,4 +10,4 @@
 
 
 EXTRA_DIST = logo.jpg
-SUBDIRS= config dct startup
+SUBDIRS= config dct startup mibs
diff --git a/contrib/mibs/Makefile.am b/contrib/mibs/Makefile.am
new file mode 100644 (file)
index 0000000..7a31a13
--- /dev/null
@@ -0,0 +1,39 @@
+# Copyright (C) 2004 NetXMS Team <bugs@netxms.org>
+#  
+# This file is free software; as a special exception the author gives
+# unlimited permission to copy and/or distribute it, with or without 
+# modifications, as long as this notice is preserved.
+# 
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
+# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+
+mibsdir=$(pkgdatadir)/mibs
+
+mibs_DATA = \
+                                 CDX-6500-COMMON-MIB.txt CHECKPOINT-NG-MIB.txt \
+                                 CISCO-C2900-MIB.txt CISCO-CDP-MIB.txt \
+                                 CISCO-ENVMON-MIB.txt CISCO-MEMORY-POOL-MIB.txt \
+                                 CISCO-PING-MIB.txt CISCO-PROCESS-MIB.txt \
+                                 CISCO-PRODUCTS-MIB.txt CISCO-SMI.txt \
+                                 CISCO-SYSLOG-MIB.txt CISCO-TCP-MIB.txt \
+                                 CISCO-TC.txt CISCO-VTP-MIB.txt \
+                                 HOST-RESOURCES-MIB.txt HOST-RESOURCES-TYPES.txt \
+                                 IANA-ADDRESS-FAMILY-NUMBERS-MIB.txt IANAifType-MIB.txt \
+                                 IANA-LANGUAGE-MIB.txt IEEE8021-PAE-MIB.txt \
+                                 IF-MIB.txt INET-ADDRESS-MIB.txt \
+                                 IP-MIB.txt MTA-MIB.txt \
+                                 NET-SNMP-AGENT-MIB.txt NET-SNMP-MIB.txt \
+                                 NET-SNMP-MONITOR-MIB.txt NET-SNMP-SYSTEM-MIB.txt \
+                                 NET-SNMP-TC.txt NETWORK-SERVICES-MIB.txt \
+                                 OSPF-MIB.txt RAPID-CITY.txt \
+                                 RFC1155-SMI.txt RFC1213-MIB.txt \
+                                 RFC-1215.txt RMON-MIB.txt \
+                                 SNMPv2-CONF.txt SNMPv2-MIB.txt \
+                                 SNMPv2-SMI.txt SNMPv2-TC.txt \
+                                 SNMPv2-TM.txt SYNOPTICS-ROOT-MIB.txt \
+                                 TCP-MIB.txt TUNNEL-MIB.txt \
+                                 UCD-DISKIO-MIB.txt UCD-DLMOD-MIB.txt \
+                                 UCD-IPFILTER-MIB.txt UCD-IPFWACC-MIB.txt \
+                                 UCD-SNMP-MIB.txt UDP-MIB.txt \
+                                 WF-COM.txt
index 5a53af6..6f77ee2 100644 (file)
@@ -8,7 +8,9 @@
 # WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
 # implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 
-EXTRA_DIST = \
+imagesdir=$(pkgdatadir)/images
+
+images_DATA = \
     generic_printer.ico generic_printer.png \
     interface.ico interface.png \
     network.ico network.png \
index 9e42eb3..388aa56 100644 (file)
@@ -4,7 +4,7 @@
 
 sqldir=$(pkgdatadir)/sql
 
-sql_SCRIPTS = dbinit_mysql.sql dbinit_pgsql.sql dbinit_mssql.sql dbinit_oracle.sql
+sql_DATA = dbinit_mysql.sql dbinit_pgsql.sql dbinit_mssql.sql dbinit_oracle.sql
 
 ROOT_FILE = dbinit.in
 SOURCE = $(ROOT_FILE) schema.in setup.in events.in images.in policy.in
@@ -12,7 +12,7 @@ HEADER_FILES = ../include/netxmsdb.h ../include/nxevent.h ../include/nximage.h .
 COMMAND = $(CPP) -x c -P -Wundef -D_NETXMS_DB_SCHEMA_ -I@top_srcdir@/include -I@top_srcdir@/src/server/include
 SQUEEZE = perl -n -e "if (! /^[\s\t\n]*$$/) { print; }"
 
-all: $(sql_SCRIPTS)
+all: $(sql_DATA)
 
 dbinit_mysql.sql: $(SOURCE) $(HEADER_FILES)
        $(COMMAND) -DDB_MYSQL $(ROOT_FILE) | $(SQUEEZE) > $@
@@ -30,6 +30,6 @@ clean:
        rm -f dbinit_*.sql
 
 EXTRA_DIST = \
-       $(sql_SCRIPTS) \
+       $(sql_DATA) \
        dbinit.in events.in images.in \
        policy.in schema.in setup.in
index 4a0920d..bca2851 100644 (file)
@@ -111,23 +111,28 @@ typedef __console_ctx * CONSOLE_CTX;
 
 #ifdef _WIN32
 
-#define DEFAULT_SHELL         "cmd.exe"
-#define DEFAULT_LOG_FILE      "C:\\NetXMS.log"
-#define DEFAULT_DATA_DIR      "C:\\NetXMS\\var"
+# define DEFAULT_SHELL         "cmd.exe"
+# define DEFAULT_LOG_FILE      "C:\\NetXMS.log"
+# define DEFAULT_DATA_DIR      "C:\\NetXMS\\var"
 
-#define DDIR_MIBS             "\\mibs"
-#define DDIR_IMAGES           "\\images"
-#define DDIR_PACKAGES         "\\packages"
+# define DDIR_MIBS             "\\mibs"
+# define DDIR_IMAGES           "\\images"
+# define DDIR_PACKAGES         "\\packages"
 
 #else    /* _WIN32 */
 
-#define DEFAULT_SHELL         "/bin/sh"
-#define DEFAULT_LOG_FILE      "/var/log/netxmsd.log"
-#define DEFAULT_DATA_DIR      "/var/netxms"
+# define DEFAULT_SHELL         "/bin/sh"
 
-#define DDIR_MIBS             "/mibs"
-#define DDIR_IMAGES           "/images"
-#define DDIR_PACKAGES         "/packages"
+# ifndef DATADIR
+#  define DATADIR              "/var/netxms"
+# endif
+
+# define DEFAULT_LOG_FILE      DATADIR"/log/netxmsd.log"
+# define DEFAULT_DATA_DIR      DATADIR
+
+# define DDIR_MIBS             "/mibs"
+# define DDIR_IMAGES           "/images"
+# define DDIR_PACKAGES         "/packages"
 
 #endif   /* _WIN32 */