Index: /package_tags/sipb-xen-dev/18/README
===================================================================
--- /package_tags/sipb-xen-dev/18/README	(revision 856)
+++ /package_tags/sipb-xen-dev/18/README	(revision 856)
@@ -0,0 +1,7 @@
+Installation:
+
+ - The secret of the gpg key identified in invirt.config.apt.keyid
+   must be in the keyring of the repository user.
+
+   The public key should then be in the apt keyring of systems using
+   the packages.
Index: /package_tags/sipb-xen-dev/18/debian/README
===================================================================
--- /package_tags/sipb-xen-dev/18/debian/README	(revision 856)
+++ /package_tags/sipb-xen-dev/18/debian/README	(revision 856)
@@ -0,0 +1,6 @@
+The Debian Package sipb-xen-dev
+----------------------------
+
+Comments regarding the Package
+
+ -- unknown <hartmans@debian.org>  Fri,  6 Jul 2007 00:52:28 -0400
Index: /package_tags/sipb-xen-dev/18/debian/README.Debian
===================================================================
--- /package_tags/sipb-xen-dev/18/debian/README.Debian	(revision 856)
+++ /package_tags/sipb-xen-dev/18/debian/README.Debian	(revision 856)
@@ -0,0 +1,6 @@
+sipb-xen-dev for Debian
+-----------------------
+
+<possible notes regarding this package - if none, delete this file>
+
+ -- unknown <hartmans@debian.org>  Fri,  6 Jul 2007 00:52:28 -0400
Index: /package_tags/sipb-xen-dev/18/debian/changelog
===================================================================
--- /package_tags/sipb-xen-dev/18/debian/changelog	(revision 856)
+++ /package_tags/sipb-xen-dev/18/debian/changelog	(revision 856)
@@ -0,0 +1,118 @@
+sipb-xen-dev (18) unstable; urgency=low
+
+  * sign the packages, getting keyid from invirt.config
+
+ -- Greg Price <price@mit.edu>  Mon,  4 Aug 2008 00:43:58 -0400
+
+sipb-xen-dev (17) unstable; urgency=low
+
+  * use reprepro more correctly (and include in both stable and unstable)
+
+ -- Greg Price <price@mit.edu>  Sat, 26 Apr 2008 23:47:55 -0400
+
+sipb-xen-dev (16) unstable; urgency=low
+
+  * usage as "sx-build-release <package-name>", no "trunk/packages"
+  * clobber the build-release/<package-name> directory automatically
+
+ -- Greg Price <price@mit.edu>  Sat, 26 Apr 2008 23:12:03 -0400
+
+sipb-xen-dev (15) unstable; urgency=low
+
+  * Stop requiring the current directory to be in the checkout.
+  * Don't do unnecessary write operations
+    (hence prompt less often for a password.)
+
+ -- Greg Price <price@mit.edu>  Sat, 26 Apr 2008 22:45:42 -0400
+
+sipb-xen-dev (14) unstable; urgency=low
+
+  * Use the shallower directory structure.
+
+ -- Eric Price <ecprice@sipb-xen-dev.mit.edu>  Sat, 29 Mar 2008 17:25:20 -0400
+
+sipb-xen-dev (13) unstable; urgency=low
+
+  * Update the svn uri automatically.
+
+ -- Eric Price <ecprice@sipb-xen-dev.mit.edu>  Fri, 28 Mar 2008 21:38:37 -0400
+
+sipb-xen-dev (12) unstable; urgency=low
+
+  * Update the svn uri to point to the new repository
+
+ -- Nelson Elhage <nelhage@mit.edu>  Wed, 15 Aug 2007 22:58:49 -0400
+
+sipb-xen-dev (11) unstable; urgency=low
+
+  * Use svn export not co to avoid installing .svn directories
+
+ -- Sam Hartman <hartmans@debian.org>  Sat,  4 Aug 2007 19:15:58 -0400
+
+sipb-xen-dev (10) unstable; urgency=low
+
+  * Use svn export not svn co so we don't get .svn directories installed
+
+ -- Sam Hartman <hartmans@debian.org>  Sat,  4 Aug 2007 19:14:51 -0400
+
+sipb-xen-dev (9) unstable; urgency=low
+
+  * Add /debian to apache config
+
+ -- Sam Hartman <hartmans@debian.org>  Sat,  4 Aug 2007 18:54:43 -0400
+
+sipb-xen-dev (8) unstable; urgency=low
+
+  * Can't use ..
+
+ -- Sam Hartman <hartmans@debian.org>  Sun, 15 Jul 2007 17:29:54 -0400
+
+sipb-xen-dev (7) unstable; urgency=low
+
+  * Can't use ..
+
+ -- Sam Hartman <hartmans@debian.org>  Sun, 15 Jul 2007 17:27:59 -0400
+
+sipb-xen-dev (6) unstable; urgency=low
+
+  * Can't use ..
+
+ -- Sam Hartman <hartmans@debian.org>  Sun, 15 Jul 2007 17:26:17 -0400
+
+sipb-xen-dev (5) unstable; urgency=low
+
+  * Bug fix
+
+ -- Sam Hartman <hartmans@debian.org>  Sun, 15 Jul 2007 17:25:00 -0400
+
+sipb-xen-dev (4) unstable; urgency=low
+
+  * Blah
+
+ -- Sam Hartman <hartmans@debian.org>  Sun, 15 Jul 2007 17:21:28 -0400
+
+sipb-xen-dev (3) unstable; urgency=low
+
+  * Working sx-build-release
+  
+
+ -- Sam Hartman <hartmans@debian.org>  Sun, 15 Jul 2007 16:58:46 -0400
+
+sipb-xen-dev (2) unstable; urgency=low
+
+  * Add sipb-xen-repository apache config
+
+ -- Sam Hartman <hartmans@debian.org>  Sun, 15 Jul 2007 14:04:03 -0400
+
+sipb-xen-dev (1) unstable; urgency=low
+
+  * Add repository config
+  * update dependencies
+
+ --  Sam Hartman <hartmans@debian.org>  Sun, 15 Jul 2007 13:43:08 -0400
+
+sipb-xen-dev (0) unstable; urgency=low
+
+  * Initial Release.
+
+ -- unknown <hartmans@debian.org>  Fri,  6 Jul 2007 00:52:28 -0400
Index: /package_tags/sipb-xen-dev/18/debian/compat
===================================================================
--- /package_tags/sipb-xen-dev/18/debian/compat	(revision 856)
+++ /package_tags/sipb-xen-dev/18/debian/compat	(revision 856)
@@ -0,0 +1,1 @@
+5
Index: /package_tags/sipb-xen-dev/18/debian/control
===================================================================
--- /package_tags/sipb-xen-dev/18/debian/control	(revision 856)
+++ /package_tags/sipb-xen-dev/18/debian/control	(revision 856)
@@ -0,0 +1,13 @@
+Source: sipb-xen-dev
+Section: servers
+Priority: important
+Maintainer: sipb-xen@mit.edu
+Build-Depends: debhelper (>= 5)
+Standards-Version: 3.7.2
+
+Package: sipb-xen-dev
+Architecture: all
+Depends: ${shlibs:Depends}, ${misc:Depends}, dpkg-dev-el, emacs21, reprepro, apache2, postfix, screen, dh-make, screen, , fakeroot, pbuilder
+Description: SIPB Xen development server 
+ This package  should be installed on sipb-xen-dev
+ It makes sure that necessary tools are available.
Index: /package_tags/sipb-xen-dev/18/debian/copyright
===================================================================
--- /package_tags/sipb-xen-dev/18/debian/copyright	(revision 856)
+++ /package_tags/sipb-xen-dev/18/debian/copyright	(revision 856)
@@ -0,0 +1,25 @@
+This is sipb-xen-dev, written and maintained by sipb-xen@mit.edu
+on Fri,  6 Jul 2007 00:52:28 -0400.
+
+The original source can always be found at:
+
+Copyright Holder:  unknown
+
+License:
+
+  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 package; if not, write to the Free Software
+  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
+
+On Debian systems, the complete text of the GNU General
+Public License can be found in `/usr/share/common-licenses/GPL'.
Index: /package_tags/sipb-xen-dev/18/debian/dirs
===================================================================
--- /package_tags/sipb-xen-dev/18/debian/dirs	(revision 856)
+++ /package_tags/sipb-xen-dev/18/debian/dirs	(revision 856)
@@ -0,0 +1,2 @@
+usr/bin
+usr/sbin
Index: /package_tags/sipb-xen-dev/18/debian/rules
===================================================================
--- /package_tags/sipb-xen-dev/18/debian/rules	(revision 856)
+++ /package_tags/sipb-xen-dev/18/debian/rules	(revision 856)
@@ -0,0 +1,97 @@
+#!/usr/bin/make -f
+# -*- makefile -*-
+# Sample debian/rules that uses debhelper.
+# This file was originally written by Joey Hess and Craig Small.
+# As a special exception, when this file is copied by dh-make into a
+# dh-make output file, you may use that output file without restriction.
+# This special exception was added by Craig Small in version 0.37 of dh-make.
+
+# Uncomment this to turn on verbose mode.
+#export DH_VERBOSE=1
+
+
+
+
+CFLAGS = -Wall -g
+
+ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
+	CFLAGS += -O0
+else
+	CFLAGS += -O2
+endif
+
+configure: configure-stamp
+configure-stamp:
+	dh_testdir
+	# Add here commands to configure the package.
+
+	touch configure-stamp
+
+
+build: build-stamp
+
+build-stamp: configure-stamp 
+	dh_testdir
+
+	# Add here commands to compile the package.
+
+
+	touch $@
+
+clean:
+	dh_testdir
+	dh_testroot
+	rm -f build-stamp configure-stamp
+
+	# Add here commands to clean up after the build process.
+
+
+	dh_clean 
+
+install: build
+	dh_testdir
+	dh_testroot
+	dh_clean -k 
+	dh_installdirs
+
+	# Add here commands to install the package into debian/sipb-xen-dev.
+
+
+
+# Build architecture-independent files here.
+binary-arch: build install
+# We have nothing to do by default.
+
+# Build architecture-dependent files here.
+binary-indep: build install
+	dh_testdir
+	dh_testroot
+	dh_installchangelogs 
+	dh_installdocs
+	dh_installexamples
+	dh_install
+#	dh_installmenu
+#	dh_installdebconf	
+#	dh_installlogrotate
+#	dh_installemacsen
+#	dh_installpam
+#	dh_installmime
+#	dh_python
+#	dh_installinit
+#	dh_installcron
+#	dh_installinfo
+	dh_installman
+	dh_link
+	dh_strip
+	dh_compress
+	dh_fixperms
+#	dh_perl
+#	dh_makeshlibs
+	dh_installdeb
+	dh_shlibdeps
+	dh_gencontrol
+	dh_md5sums
+	dh_builddeb
+
+binary: binary-indep binary-arch
+.PHONY: build clean binary-indep binary-arch binary install configure
Index: /package_tags/sipb-xen-dev/18/debian/sipb-xen-dev.dirs
===================================================================
--- /package_tags/sipb-xen-dev/18/debian/sipb-xen-dev.dirs	(revision 856)
+++ /package_tags/sipb-xen-dev/18/debian/sipb-xen-dev.dirs	(revision 856)
@@ -0,0 +1,1 @@
+srv/repository/conf
Index: /package_tags/sipb-xen-dev/18/debian/sipb-xen-dev.init
===================================================================
--- /package_tags/sipb-xen-dev/18/debian/sipb-xen-dev.init	(revision 856)
+++ /package_tags/sipb-xen-dev/18/debian/sipb-xen-dev.init	(revision 856)
@@ -0,0 +1,25 @@
+#!/bin/sh
+
+PACKAGE=sipb-xen-dev
+
+. /lib/lsb/init-functions
+
+gen_config () {
+    local keyid="$(invirt-getconf apt.keyid)"
+    for f in /srv/repository/conf/{distributions,invirt-uploaders}; do
+	perl -pe "s/@apt.keyid@/$keyid/g" <"$f".in >"$f"
+    done
+}
+
+case "$1" in
+  start|reload|force-reload|restart)
+    log_begin_msg "Reloading config for $PACKAGE"
+    gen_config
+    log_end_msg $?
+    ;;
+  stop)
+    ;;
+  *)
+    log_success_msg "Usage: /etc/init.d/$PACKAGE {start|reload|force-reload|restart|stop}"
+    ;;
+esac
Index: /package_tags/sipb-xen-dev/18/debian/sipb-xen-dev.install
===================================================================
--- /package_tags/sipb-xen-dev/18/debian/sipb-xen-dev.install	(revision 856)
+++ /package_tags/sipb-xen-dev/18/debian/sipb-xen-dev.install	(revision 856)
@@ -0,0 +1,4 @@
+reprepro-env /usr/bin
+repository-config/* srv/repository/conf
+sipb-xen-repository etc/apache2/conf.d
+sx-build-release /usr/bin
Index: /package_tags/sipb-xen-dev/18/repository-config/distributions.in
===================================================================
--- /package_tags/sipb-xen-dev/18/repository-config/distributions.in	(revision 856)
+++ /package_tags/sipb-xen-dev/18/repository-config/distributions.in	(revision 856)
@@ -0,0 +1,18 @@
+CodeName: unstable
+Components: main
+Uploaders: invirt-uploaders
+SignWith: @apt.keyid@
+Architectures: amd64 source
+Origin: sipb
+Notautomatic: yes
+Description: Unreleased sipb-xen software
+
+
+Codename: stable
+Components: main
+Uploaders: invirt-uploaders
+SignWith: @apt.keyid@
+Architectures: amd64 source 
+Origin: sipb
+Description: Released sipb-xen  code
+Contents: 1
Index: /package_tags/sipb-xen-dev/18/repository-config/invirt-uploaders.in
===================================================================
--- /package_tags/sipb-xen-dev/18/repository-config/invirt-uploaders.in	(revision 856)
+++ /package_tags/sipb-xen-dev/18/repository-config/invirt-uploaders.in	(revision 856)
@@ -0,0 +1,1 @@
+allow * by key @apt.keyid@
Index: /package_tags/sipb-xen-dev/18/repository-config/unsigned
===================================================================
--- /package_tags/sipb-xen-dev/18/repository-config/unsigned	(revision 856)
+++ /package_tags/sipb-xen-dev/18/repository-config/unsigned	(revision 856)
@@ -0,0 +1,2 @@
+allow  * by unsigned
+
Index: /package_tags/sipb-xen-dev/18/reprepro-env
===================================================================
--- /package_tags/sipb-xen-dev/18/reprepro-env	(revision 856)
+++ /package_tags/sipb-xen-dev/18/reprepro-env	(revision 856)
@@ -0,0 +1,5 @@
+#!/bin/sh
+set -e
+export HOME=/home/repository
+exec sudo -H -u repository  /usr/bin/reprepro -b /srv/repository "$@"
+
Index: /package_tags/sipb-xen-dev/18/sipb-xen-repository
===================================================================
--- /package_tags/sipb-xen-dev/18/sipb-xen-repository	(revision 856)
+++ /package_tags/sipb-xen-dev/18/sipb-xen-repository	(revision 856)
@@ -0,0 +1,17 @@
+Alias /sipb-xen /srv/repository
+
+Alias /debian/ /debian/
+
+<Directory /srv/repository>
+		Options Indexes FollowSymLinks MultiViews
+		AllowOverride None
+		Order allow,deny
+		allow from all
+</Directory>
+
+<Directory /debian>
+		Options Indexes FollowSymLinks MultiViews
+		AllowOverride None
+		Order allow,deny
+		allow from all
+</Directory>
Index: /package_tags/sipb-xen-dev/18/sx-build-release
===================================================================
--- /package_tags/sipb-xen-dev/18/sx-build-release	(revision 856)
+++ /package_tags/sipb-xen-dev/18/sx-build-release	(revision 856)
@@ -0,0 +1,40 @@
+#!/bin/bash
+svnuri=`svn info /srv/checkout | sed -n 's/^Repository Root: //p'`
+
+set -e
+if  [ $# -ne 1 ] ; then
+	echo " usage: sx-build-release package_name"
+	exit 1
+fi
+
+package=$1
+rm -rf build-release/$package
+svn export $svnuri/trunk/packages/$package build-release/$package
+cd build-release/$package
+
+eval  `perl '-F:\s+' -lane 'print  $F[0]."=".$F[1] if /^Version|^Source|^Distribution/' \
+    <(dpkg-parsechangelog)`
+
+dpkg-buildpackage -k"$(invirt-getconf apt.keyid)" -rfakeroot
+
+if ! svn ls $svnuri/package_tags/$Source >/dev/null 2>&1; then
+  svn mkdir $svnuri/package_tags/$Source \
+      -m "Create package tags directory"
+fi
+if ! svn ls $svnuri/package_tags/$Source/$Version >/dev/null 2>&1; then
+  svn cp $svnuri/trunk/packages/$package $svnuri/package_tags/$Source/$Version \
+      -m "Tag $Version of $Source"
+else
+  echo "$(basename $0): tag already exists, not making again"
+fi
+
+cd ..
+[ $Distribution = 'unstable' ] \
+ || echo "$(basename $0): warning: Distribution is ${Distribution}, script expects unstable"
+changesfile=`pwd`/${Source}_*${Version}*.changes
+reprepro-env include unstable $changesfile
+reprepro-env copy stable unstable ${Source} \
+  $(perl '-F:\s+' -lane 'print $F[1]." " if /^Binary/' <$changesfile)
+
+cd ..
+rm -rf build-release
