Skip to content
This repository has been archived by the owner on Jan 12, 2021. It is now read-only.

Commit

Permalink
using uml utilities src from ubuntu repo insted of the sourceforge CVS
Browse files Browse the repository at this point in the history
  • Loading branch information
kartoch committed May 20, 2011
1 parent 79d7a84 commit abcc50f
Show file tree
Hide file tree
Showing 160 changed files with 2,898 additions and 2,419 deletions.
1 change: 1 addition & 0 deletions src/tools-20070815/.pc/.version
@@ -0,0 +1 @@
2
1 change: 1 addition & 0 deletions src/tools-20070815/.pc/applied-patches
@@ -0,0 +1 @@
tunctl-setgroup
Empty file.
File renamed without changes.
21 changes: 21 additions & 0 deletions src/tools-20070815/CVS/Entries
@@ -0,0 +1,21 @@
/COPYING/1.1/Tue Oct 9 02:22:36 2001//
D/gdbbot////
D/mconsole////
D/moo////
D/net////
D/redhat////
D/rpm////
D/test////
D/transformiix////
D/uml_net////
D/uml_router////
D/umn////
D/port-helper////
D/jailtest////
D/tunctl////
D/umlgdb////
D/watchdog////
D/jail////
D/honeypot////
/Makefile/1.13/Sat Feb 8 04:01:52 2003//
/uml_util.spec.in/1.4/Wed Jan 14 09:56:31 2004//
1 change: 1 addition & 0 deletions src/tools-20070815/CVS/Repository
@@ -0,0 +1 @@
tools
1 change: 1 addition & 0 deletions src/tools-20070815/CVS/Root
@@ -0,0 +1 @@
jdike@cvs.user-mode-linux.sourceforge.net:/cvsroot/user-mode-linux
32 changes: 32 additions & 0 deletions src/tools-20070815/Changelog
@@ -0,0 +1,32 @@
BB -
shebangs added where needed
fixed the command line handling in honeypot.pl
the jail Makefile installs things now
jail_uml handles user names as well as uids and sets its group
CFLAGS is now settable at the top level
cleanups in uml_mconsole
64-bit fixes, fixing of broken 64-bit COW files, and other
cleanups in uml_moo
bug fix in uml_net's handling of a SLIP interface going down
moved the uml_router directory to uml_switch
cleanups in uml_switch
added a spec file

Me -
BB's tarball contained a tools-$DATE with a tools subdirectory - the
subdirectory had newer stuff, so I started with that.

Cleaned up the honeypot.pl changes

Spurious tab in jail/Makefile

Ignored BB's redeclaration of jailtest main - I prefer correct
declarations even when the arguments aren't used.

Removed uml_util.spec, which is generated

Added a lib directory which contains send_fd()

Added umlfs and umlfs support to uml_mconsole

From dgraves - mconsole int
21 changes: 16 additions & 5 deletions src/uml-tools/Makefile → src/tools-20070815/Makefile
@@ -1,19 +1,30 @@
TUNCTL = $(shell [ -e /usr/include/linux/if_tun.h ] && echo tunctl)

SUBDIRS = jail jailtest humfsify mconsole moo port-helper $(TUNCTL) uml_net \
uml_router watchdog
SUBDIRS = lib jail jailtest humfsify mconsole moo port-helper $(TUNCTL) \
uml_net uml_switch watchdog umlfs
UMLVER = $(shell date +%Y%m%d)
TARBALL = uml_utilities_$(UMLVER).tar
TARBALL = uml_utilities_$(UMLVER).tar.bz2
BIN_DIR = /usr/bin

ifeq ($(shell uname -m),x86_64)
LIB_DIR = /usr/lib64/uml
else
LIB_DIR = /usr/lib/uml
endif

CFLAGS = -g -Wall
#CFLAGS = -g -O2 -Wall

export BIN_DIR LIB_DIR
export BIN_DIR LIB_DIR CFLAGS

all install:
set -e ; for dir in $(SUBDIRS); do $(MAKE) -C $$dir $@; done

tarball : clean spec
cd .. ; tar cf $(TARBALL) tools ; bzip2 -f $(TARBALL)
cd .. ; \
mv tools tools-$(UMLVER); \
tar cjf $(TARBALL) tools-$(UMLVER); \
mv tools-$(UMLVER) tools

clean:
rm -rf *~
Expand Down
35 changes: 35 additions & 0 deletions src/tools-20070815/Makefile.orig
@@ -0,0 +1,35 @@
TUNCTL = $(shell [ -e /usr/include/linux/if_tun.h ] && echo tunctl)

SUBDIRS = lib jail jailtest humfsify mconsole moo port-helper $(TUNCTL) \
uml_net uml_switch watchdog umlfs
UMLVER = $(shell date +%Y%m%d)
TARBALL = uml_utilities_$(UMLVER).tar.bz2
BIN_DIR = /usr/bin

ifeq ($(shell uname -m),x86_64)
LIB_DIR = /usr/lib64/uml
else
LIB_DIR = /usr/lib/uml
endif

CFLAGS = -g -Wall
#CFLAGS = -g -O2 -Wall

export BIN_DIR LIB_DIR CFLAGS

all install:
set -e ; for dir in $(SUBDIRS); do $(MAKE) -C $$dir $@; done

tarball : clean spec
cd .. ; \
mv tools tools-$(UMLVER); \
tar cjf $(TARBALL) tools-$(UMLVER); \
mv tools-$(UMLVER) tools

clean:
rm -rf *~
rm -f uml_util.spec
set -e ; for dir in $(SUBDIRS); do $(MAKE) -C $$dir $@; done

spec:
sed -e 's/__UMLVER__/$(UMLVER)/' < uml_util.spec.in > uml_util.spec
11 changes: 11 additions & 0 deletions src/tools-20070815/Makefile.rej
@@ -0,0 +1,11 @@
--- Makefile 2004-04-08 03:42:59.000000000 +0200
+++ Makefile 2009-05-01 23:31:00.106571852 +0200
@@ -1,7 +1,7 @@
TUNCTL = $(shell [ -e /usr/include/linux/if_tun.h ] && echo tunctl)

SUBDIRS = jail jailtest humfsify mconsole moo port-helper $(TUNCTL) uml_net \
- uml_router watchdog
+ uml_router watchdog uml_dump
UMLVER = $(shell date +%Y%m%d)
TARBALL = uml_utilities_$(UMLVER).tar
BIN_DIR = /usr/bin
File renamed without changes.
2 changes: 2 additions & 0 deletions src/tools-20070815/gdbbot/CVS/Entries
@@ -0,0 +1,2 @@
/gdbbot.pl/1.3/Thu Jul 5 19:18:58 2001//
D
1 change: 1 addition & 0 deletions src/tools-20070815/gdbbot/CVS/Repository
@@ -0,0 +1 @@
tools/gdbbot
1 change: 1 addition & 0 deletions src/tools-20070815/gdbbot/CVS/Root
@@ -0,0 +1 @@
jdike@cvs.user-mode-linux.sourceforge.net:/cvsroot/user-mode-linux
File renamed without changes.
1 change: 1 addition & 0 deletions src/tools-20070815/honeypot/CVS/CVS/Entries
@@ -0,0 +1 @@
D
1 change: 1 addition & 0 deletions src/tools-20070815/honeypot/CVS/CVS/Repository
@@ -0,0 +1 @@
tools/honeypot/CVS
1 change: 1 addition & 0 deletions src/tools-20070815/honeypot/CVS/CVS/Root
@@ -0,0 +1 @@
jdike@cvs.user-mode-linux.sourceforge.net:/cvsroot/user-mode-linux
4 changes: 4 additions & 0 deletions src/tools-20070815/honeypot/CVS/Entries
@@ -0,0 +1,4 @@
D/CVS////
/hppfs.pm/1.3/Wed Jan 22 20:40:26 2003//
/honeypot.pl/1.6/Thu Jul 31 18:10:52 2003//
/hppfslib.pm/1.4/Thu Jul 31 18:12:39 2003//
1 change: 1 addition & 0 deletions src/tools-20070815/honeypot/CVS/Repository
@@ -0,0 +1 @@
tools/honeypot
1 change: 1 addition & 0 deletions src/tools-20070815/honeypot/CVS/Root
@@ -0,0 +1 @@
jdike@cvs.user-mode-linux.sourceforge.net:/cvsroot/user-mode-linux
@@ -1,3 +1,4 @@
#!/usr/bin/perl
#
# Copyright (C) 2002, 2003 Jeff Dike (jdike@karaya.com)
# Licensed under the GPL
Expand All @@ -9,7 +10,10 @@

my $dir;

@ARGV and $dir = $ARGV[0];
@ARGV and $dir = $ARGV[0] or die "Not enough arguments - pass dir where UML will be running";

# !mkdir $dir and warn "Couldn't create '$dir' : $!";
!mkdir "$dir/proc" and warn "Couldn't create '$dir/proc' : $!";

my $hppfs = hppfs->new($dir);

Expand All @@ -19,20 +23,20 @@
# partitions needs work
# slabinfo if UML ever uses the slab cache for anything

$hppfs->add("cmdline" => proc("cmdline"),
"cpuinfo" => proc("cpuinfo"),
"dma" => proc("dma"),
$hppfs->add("cmdline" => host_proc("cmdline"),
"cpuinfo" => host_proc("cpuinfo"),
"dma" => host_proc("dma"),
"devices" => remove_lines("ubd"),
"exitcode" => "remove",
"filesystems" => $remove_filesystems,
"interrupts" => proc("interrupts"),
"iomem" => proc("iomem"),
"ioports" => proc("ioports"),
"interrupts" => host_proc("interrupts"),
"iomem" => host_proc("iomem"),
"ioports" => host_proc("ioports"),
"mounts" => $remove_filesystems,
"pid/mounts" => $remove_filesystems,
"stat" => proc("stat"),
"uptime" => proc("uptime"),
"version" => proc("version"),
"stat" => host_proc("stat"),
"uptime" => host_proc("uptime"),
"version" => host_proc("version"),
dup_proc_dir("bus", $dir) );

$hppfs->handler();
File renamed without changes.
Expand Up @@ -11,7 +11,7 @@ use vars qw(@ISA @EXPORT);
use strict;

@ISA = qw(Exporter);
@EXPORT = qw(&remove_lines &host &proc &dup_proc_dir);
@EXPORT = qw(&remove_lines &host &host_proc &dup_proc_dir);

sub remove_lines {
my @remove = @_;
Expand All @@ -32,7 +32,7 @@ sub host {
"r" ] );
}

sub proc {
sub host_proc {
my $file = shift;

return(host("/proc/$file"));
Expand All @@ -41,7 +41,7 @@ sub proc {
sub dup_proc_dir {
my $to = shift;
my $root = shift;
my $new = "$root/$to";
my $new = "$root/proc/$to";

-e $new and `rm -rf $new`;
!mkdir $new and warn "Couldn't create '$new' : $!";
Expand All @@ -58,7 +58,7 @@ sub dup_proc_dir {
my @files = `cd /proc ; find $to -type f -print`;
chomp @files;

return(map { $_ => proc($_) } @files);
return(map { $_ => host_proc($_) } @files);
}

1;
10 changes: 10 additions & 0 deletions src/tools-20070815/humfsify/Makefile
@@ -0,0 +1,10 @@
BIN = humfsify

all:

install:
install -d $(DESTDIR)$(BIN_DIR)
install -o 0755 $(BIN) $(DESTDIR)$(BIN_DIR)

clean:
rm -f *~

0 comments on commit abcc50f

Please sign in to comment.