-# Copyright (C) 2007, 2008, 2009, 2010, 2011 Nicira Networks, Inc.
+# Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012 Nicira Networks, Inc.
#
# Copying and distribution of this file, with or without modification,
# are permitted in any medium without royalty provided the copyright
-e 's,[@]PYTHON[@],$(PYTHON),g' \
-e 's,[@]RUNDIR[@],$(RUNDIR),g' \
-e 's,[@]VERSION[@],$(VERSION),g' \
- -e 's,[@]BUILDNR[@],$(BUILDNR),g' \
-e 's,[@]localstatedir[@],$(localstatedir),g' \
-e 's,[@]pkgdatadir[@],$(pkgdatadir),g' \
-e 's,[@]sysconfdir[@],$(sysconfdir),g' \
-# Copyright (c) 2008, 2009, 2010, 2011 Nicira Networks
+# Copyright (c) 2008, 2009, 2010, 2011, 2012 Nicira Networks
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
AC_PREREQ(2.64)
AC_INIT(openvswitch, 1.6.90, ovs-bugs@openvswitch.org)
-NX_BUILDNR
AC_CONFIG_SRCDIR([datapath/datapath.c])
AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_AUX_DIR([build-aux])
BUILD_BUG_ON(sizeof(struct ovs_skb_cb) > sizeof(dummy_skb->cb));
pr_info("Open vSwitch switching datapath %s, built "__DATE__" "__TIME__"\n",
- VERSION BUILDNR);
+ VERSION);
err = genl_exec_init();
if (err)
export srcdir = @abs_srcdir@
export top_srcdir = @abs_top_srcdir@
export VERSION = @VERSION@
-export BUILDNR = @BUILDNR@
include $(srcdir)/../Modules.mk
include $(srcdir)/Modules.mk
EXTRA_CFLAGS := -DVERSION=\"$(VERSION)\"
EXTRA_CFLAGS += -I$(srcdir)/..
EXTRA_CFLAGS += -I$(builddir)/..
-ifeq '$(BUILDNR)' '0'
-EXTRA_CFLAGS += -DBUILDNR=\"\"
-else
-EXTRA_CFLAGS += -DBUILDNR=\"+build$(BUILDNR)\"
-endif
EXTRA_CFLAGS += -g
EXTRA_CFLAGS += -include $(builddir)/kcompat.h
# Modified to make a template file for a multi-binary package with separated
# build-arch and build-indep targets by Bill Allombert 2001
-# Official build number. Leave set to 0 if not an official build.
-BUILD_NUMBER = 0
-
PACKAGE=openvswitch
pdkms=openvswitch-datapath-dkms
DEB_UPSTREAM_VERSION=$(shell dpkg-parsechangelog | sed -rne 's,^Version: ([0-9]:)*([^-]+).*,\2,p')
CFLAGS += -O2
endif
-ifeq ($(BUILD_NUMBER),0)
-BUILD_NUMBER_OPTION =
-else
-BUILD_NUMBER_OPTION = --with-build-number=$(BUILD_NUMBER)
-endif
-
configure: configure-stamp
configure-stamp:
dh_testdir
cd _debian && ( \
test -e Makefile || \
../configure --prefix=/usr --localstatedir=/var --enable-ssl \
- --sysconfdir=/etc $(BUILD_NUMBER_OPTION) \
- CFLAGS="$(CFLAGS)" $(DATAPATH_CONFIGURE_OPTS))
+ --sysconfdir=/etc CFLAGS="$(CFLAGS)" \
+ $(DATAPATH_CONFIGURE_OPTS))
touch configure-stamp
#Architecture
dh_installdirs -i
$(MAKE) -C _debian DESTDIR=$(CURDIR)/debian/tmp install
dh_install -i
- sed 's/^BUILD_NUMBER = .*/BUILD_NUMBER = $(BUILD_NUMBER)/' \
- < debian/rules.modules \
- > debian/openvswitch-datapath-source/usr/src/modules/openvswitch-datapath/debian/rules
+ cp debian/rules.modules debian/openvswitch-datapath-source/usr/src/modules/openvswitch-datapath/debian/rules
chmod 755 debian/openvswitch-datapath-source/usr/src/modules/openvswitch-datapath/debian/rules
cd debian/openvswitch-datapath-source/usr/src && tar -c modules | bzip2 -9 > openvswitch-datapath.tar.bz2 && rm -rf modules
DATAPATH_CONFIGURE_OPTS =
-# Official build number. Leave set to 0 if not an official build.
-BUILD_NUMBER = 0
-
kdist_clean:
dh_testdir
dh_testroot
dh_testroot
dh_clean -k
tar xzf openvswitch.tar.gz
- cd openvswitch && ./configure --with-linux=$(KSRC) $(DATAPATH_CONFIGURE_OPTS) --with-build-number=$(BUILD_NUMBER)
+ cd openvswitch && ./configure --with-linux=$(KSRC) $(DATAPATH_CONFIGURE_OPTS)
cd openvswitch && $(MAKE) -C datapath/linux
install -d -m755 $(DSTDIR)
install -m644 openvswitch/datapath/linux/*.ko $(DSTDIR)/
-/* Copyright (c) 2009, 2010, 2011 Nicira Networks
+/* Copyright (c) 2009, 2010, 2011, 2012 Nicira Networks
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
ds_put_char(&ds, ')');
}
- ds_put_format(&ds, " (%s %s%s)", program_name, VERSION, BUILDNR);
+ ds_put_format(&ds, " (%s %s)", program_name, VERSION);
if (inner_error) {
char *s = ovsdb_error_to_string(inner_error);
program_name = slash ? slash + 1 : argv0;
free(program_version);
- program_version = xasprintf("%s (Open vSwitch) "VERSION BUILDNR"\n"
+ program_version = xasprintf("%s (Open vSwitch) "VERSION"\n"
"Compiled %s %s\n",
program_name, date, time);
}
+++ /dev/null
-# -*- autoconf -*-
-
-# Copyright (c) 2008 Nicira Networks.
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at:
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-dnl NX_BUILDNR
-dnl
-dnl If --with-build-number=NUMBER is used, substitutes a Makefile
-dnl variable BUILDNR with NUMBER, and sets a C preprocessor variable
-dnl BUILDNR to "+buildNUMBER".
-dnl
-dnl Otherwise, if --with-build-number is not used, substitutes BUILDNR
-dnl with 0 and sets C preprocessor variable BUILDNR to "".
-AC_DEFUN([NX_BUILDNR],
- [AC_ARG_WITH(
- [build-number],
- [AS_HELP_STRING([--with-build-number=NUMBER],
- [Official build number (default is none)])])
- AC_MSG_CHECKING([build number])
- case $with_build_number in # (
- [[0-9]] | \
- [[0-9]][[0-9]] | \
- [[0-9]][[0-9]][[0-9]] | \
- [[0-9]][[0-9]][[0-9]][[0-9]] | \
- [[0-9]][[0-9]][[0-9]][[0-9]][[0-9]])
- BUILDNR=$with_build_number
- buildnr='"+build'$BUILDNR'"'
- AC_MSG_RESULT([$with_build_number])
- ;; # (
- ''|no)
- BUILDNR=0
- buildnr='""'
- AC_MSG_RESULT([none])
- ;; # (
- *)
- AC_MSG_ERROR([invalid build number $with_build_number])
- ;;
- esac
- AC_SUBST([BUILDNR])
- AC_DEFINE_UNQUOTED([BUILDNR], [$buildnr],
- [Official build number as a VERSION suffix string, e.g. "+build123",
- or "" if this is not an official build.])])
#define DEFAULT_MFR_DESC "Nicira Networks, Inc."
#define DEFAULT_HW_DESC "Open vSwitch"
-#define DEFAULT_SW_DESC VERSION BUILDNR
+#define DEFAULT_SW_DESC VERSION
#define DEFAULT_SERIAL_DESC "None"
#define DEFAULT_DP_DESC "None"
/*
- * Copyright (c) 2009, 2010, 2011 Nicira Networks.
+ * Copyright (c) 2009, 2010, 2011, 2012 Nicira Networks.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
const char *db = argc >= 2 ? argv[1] : default_db();
const char *target = argc >= 3 ? argv[2] : NULL;
- compact_or_convert(db, target, NULL,
- "compacted by ovsdb-tool "VERSION BUILDNR);
+ compact_or_convert(db, target, NULL, "compacted by ovsdb-tool "VERSION);
}
static void
check_ovsdb_error(ovsdb_schema_from_file(schema, &new_schema));
compact_or_convert(db, target, new_schema,
- "converted by ovsdb-tool "VERSION BUILDNR);
+ "converted by ovsdb-tool "VERSION);
ovsdb_schema_destroy(new_schema);
}
$(srcdir)/python/ovs/version.py: config.status
$(ro_shell) > $(@F).tmp
echo 'VERSION = "$(VERSION)"' >> $(@F).tmp
- if [ "$(BUILDNR)" != "0" ]; \
- then echo 'BUILDNR = "+build$(BUILDNR)"' >> $(@F).tmp; \
- else echo 'BUILDNR = ""' >> $(@F).tmp; \
- fi
if cmp -s $(@F).tmp $@; then touch $@; rm $(@F).tmp; else mv $(@F).tmp $@; fi
def _unixctl_version(conn, unused_argv, unused_aux):
assert isinstance(conn, UnixctlConnection)
- version = "%s (Open vSwitch) %s%s" % (ovs.util.PROGRAM_NAME,
- ovs.version.VERSION,
- ovs.version.BUILDNR)
+ version = "%s (Open vSwitch) %s" % (ovs.util.PROGRAM_NAME,
+ ovs.version.VERSION)
conn.reply(version)
# Spec file for Open vSwitch on Red Hat Enterprise Linux.
-# Copyright (C) 2009, 2010, 2011 Nicira Networks, Inc.
+# Copyright (C) 2009, 2010, 2011, 2012 Nicira Networks, Inc.
#
# Copying and distribution of this file, with or without modification,
# are permitted in any medium without royalty provided the copyright
%setup -q
%build
-./configure --prefix=/usr --sysconfdir=/etc --localstatedir=%{_localstatedir} --enable-ssl %{?build_number}
+./configure --prefix=/usr --sysconfdir=/etc --localstatedir=%{_localstatedir} --enable-ssl
make %{_smp_mflags}
%install
usage
;;
-V | --version)
- echo "$0 (Open vSwitch) $VERSION$BUILDNR"
+ echo "$0 (Open vSwitch) $VERSION"
exit 0
;;
--external-id=*)
# This is a shell function library sourced by some Open vSwitch scripts.
# It is not intended to be invoked on its own.
-# Copyright (C) 2009, 2010, 2011 Nicira Networks, Inc.
+# Copyright (C) 2009, 2010, 2011, 2012 Nicira Networks, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
sbindir=${OVS_SBINDIR-'@sbindir@'} # /usr/sbin
VERSION='@VERSION@'
-case @BUILDNR@ in
- [1-9]*) BUILDNR='+build@BUILDNR@' ;;
- *) BUILDNR= ;;
-esac
LC_ALL=C; export LC_ALL
<column name="ovs_version">
The Open vSwitch version number, e.g. <code>1.1.0</code>.
- If Open vSwitch was configured with a build number, then it is
- also included, e.g. <code>1.1.0+build6579</code>.
</column>
<column name="db_version">
# without warranty of any kind.
# When building, the rpmbuild command line should define
-# openvswitch_version, kernel_name, kernel_version, kernel_flavor,
-# and build_number using -D arguments.
+# openvswitch_version, kernel_name, kernel_version, and kernel_flavor
+# using -D arguments.
# for example:
#
# rpmbuild -D "openvswitch_version 1.1.0+build123"
# -D "kernel_name NAME-xen"
# -D "kernel_version 2.6.32.12-0.7.1.xs5.6.100.323.170596"
# -D "kernel_flavor xen"
-# -D "build_number --with-build-number=123"
# -bb /usr/src/redhat/SPECS/openvswitch-xen.spec
%if %{?openvswitch_version:0}%{!?openvswitch_version:1}
%setup -q -n openvswitch-%{openvswitch_version}
%build
-./configure --prefix=/usr --sysconfdir=/etc --localstatedir=%{_localstatedir} --with-linux=/lib/modules/%{xen_version}/build --enable-ssl %{?build_number}
+./configure --prefix=/usr --sysconfdir=/etc --localstatedir=%{_localstatedir} --with-linux=/lib/modules/%{xen_version}/build --enable-ssl
make %{_smp_mflags}
%install