summaryrefslogtreecommitdiff
path: root/devel
diff options
context:
space:
mode:
authormycroft <mycroft@pkgsrc.org>1999-04-20 15:01:11 +0000
committermycroft <mycroft@pkgsrc.org>1999-04-20 15:01:11 +0000
commit3729b8c84ef0b259e65579037f5efc95937307cd (patch)
tree041e42191e6514c9f53ccb2dd90c76e470098185 /devel
parent783923a805146b5523a7c9885ca446afafdf7958 (diff)
downloadpkgsrc-3729b8c84ef0b259e65579037f5efc95937307cd.tar.gz
Nuke the klugy CVSREADONLY hack, and instead use a modified version of our old
`cvs -u' changes to prevent lock creation.
Diffstat (limited to 'devel')
-rw-r--r--devel/cvs/patches/patch-ag21
-rw-r--r--devel/cvs/patches/patch-ah13
-rw-r--r--devel/cvs/patches/patch-ai32
-rw-r--r--devel/cvs/patches/patch-aj13
-rw-r--r--devel/cvs/patches/patch-ak13
-rw-r--r--devel/cvs/patches/patch-al21
-rw-r--r--devel/cvs/patches/patch-am12
-rw-r--r--devel/cvs/patches/patch-an13
-rw-r--r--devel/cvs/patches/patch-ao22
-rw-r--r--devel/cvs/patches/patch-ap47
-rw-r--r--devel/cvs/patches/patch-aq22
-rw-r--r--devel/cvs/patches/patch-ar72
-rw-r--r--devel/cvs/patches/patch-as13
13 files changed, 235 insertions, 79 deletions
diff --git a/devel/cvs/patches/patch-ag b/devel/cvs/patches/patch-ag
deleted file mode 100644
index 174140d04cd..00000000000
--- a/devel/cvs/patches/patch-ag
+++ /dev/null
@@ -1,21 +0,0 @@
-$NetBSD: patch-ag,v 1.1 1999/03/11 09:48:43 tron Exp $
-
---- src/cvs.h.orig Mon Jul 27 04:54:11 1998
-+++ src/cvs.h Thu Mar 11 10:39:14 1999
-@@ -256,6 +256,8 @@
- #define CVSREAD_ENV "CVSREAD" /* make files read-only */
- #define CVSREAD_DFLT 0 /* writable files by default */
-
-+#define CVSREADONLYFS_ENV "CVSREADONLYFS" /* repository is read-only */
-+
- #define TMPDIR_ENV "TMPDIR" /* Temporary directory */
- /* #define TMPDIR_DFLT Set by options.h */
-
-@@ -383,6 +385,7 @@
-
- extern int trace; /* Show all commands */
- extern int noexec; /* Don't modify disk anywhere */
-+extern int readonlyfs; /* fail on all write locks; succeed all read locks */
- extern int logoff; /* Don't write history entry */
-
- extern int top_level_admin;
diff --git a/devel/cvs/patches/patch-ah b/devel/cvs/patches/patch-ah
deleted file mode 100644
index e3311b55049..00000000000
--- a/devel/cvs/patches/patch-ah
+++ /dev/null
@@ -1,13 +0,0 @@
-$NetBSD: patch-ah,v 1.1 1999/03/11 09:48:43 tron Exp $
-
---- src/lock.c.orig Wed Mar 4 06:41:50 1998
-+++ src/lock.c Thu Mar 11 10:40:35 1999
-@@ -243,7 +243,7 @@
- FILE *fp;
- char *tmp;
-
-- if (noexec)
-+ if (noexec|| readonlyfs)
- return (0);
-
- /* we only do one directory at a time for read locks! */
diff --git a/devel/cvs/patches/patch-ai b/devel/cvs/patches/patch-ai
deleted file mode 100644
index f22ab5610a2..00000000000
--- a/devel/cvs/patches/patch-ai
+++ /dev/null
@@ -1,32 +0,0 @@
-$NetBSD: patch-ai,v 1.1 1999/03/11 09:48:43 tron Exp $
-
---- src/main.c.orig Thu Aug 13 00:39:33 1998
-+++ src/main.c Thu Mar 11 10:38:24 1999
-@@ -40,6 +40,7 @@
- int quiet = 0;
- int trace = 0;
- int noexec = 0;
-+int readonlyfs = 1;
- int logoff = 0;
-
- /* Set if we should be writing CVSADM directories at top level. At
-@@ -456,6 +457,10 @@
- }
- if (getenv (CVSREAD_ENV) != NULL)
- cvswrite = 0;
-+ if (getenv (CVSREADONLYFS_ENV)) {
-+ readonlyfs = 1;
-+ logoff = 1;
-+ }
-
- /* Set this to 0 to force getopt initialization. getopt() sets
- this to 1 internally. */
-@@ -823,7 +828,7 @@
- }
- (void) strcat (path, "/");
- (void) strcat (path, CVSROOTADM_HISTORY);
-- if (isfile (path) && !isaccessible (path, R_OK | W_OK))
-+ if (!readonlyfs && isfile (path) && !isaccessible (path, R_OK | W_OK))
- {
- save_errno = errno;
- error (0, 0, "Sorry, you don't have read/write access to the history file");
diff --git a/devel/cvs/patches/patch-aj b/devel/cvs/patches/patch-aj
deleted file mode 100644
index 921f2b753b9..00000000000
--- a/devel/cvs/patches/patch-aj
+++ /dev/null
@@ -1,13 +0,0 @@
-$NetBSD: patch-aj,v 1.1 1999/03/11 09:48:43 tron Exp $
-
---- src/server.c.orig Fri Aug 7 02:46:38 1998
-+++ src/server.c Thu Mar 11 10:41:30 1999
-@@ -612,7 +612,7 @@
- }
- (void) strcat (path, "/");
- (void) strcat (path, CVSROOTADM_HISTORY);
-- if (isfile (path) && !isaccessible (path, R_OK | W_OK))
-+ if (!readonlyfs && isfile (path) && !isaccessible (path, R_OK | W_OK))
- {
- save_errno = errno;
- pending_error_text = malloc (80 + strlen (path));
diff --git a/devel/cvs/patches/patch-ak b/devel/cvs/patches/patch-ak
new file mode 100644
index 00000000000..1916021629b
--- /dev/null
+++ b/devel/cvs/patches/patch-ak
@@ -0,0 +1,13 @@
+$NetBSD: patch-ak,v 1.1 1999/04/20 15:01:11 mycroft Exp $
+
+--- src/checkout.c.orig Sun Jul 26 22:54:04 1998
++++ src/checkout.c Tue Apr 20 10:15:03 1999
+@@ -180,7 +180,7 @@
+ case 'p':
+ pipeout = 1;
+ run_module_prog = 0; /* don't run module prog when piping */
+- noexec = 1; /* so no locks will be created */
++ nolock = 1; /* so no locks will be created */
+ break;
+ case 'c':
+ cat = 1;
diff --git a/devel/cvs/patches/patch-al b/devel/cvs/patches/patch-al
new file mode 100644
index 00000000000..ad1a6067995
--- /dev/null
+++ b/devel/cvs/patches/patch-al
@@ -0,0 +1,21 @@
+$NetBSD: patch-al,v 1.1 1999/04/20 15:01:11 mycroft Exp $
+
+--- src/client.c.orig Sun Jul 26 22:54:06 1998
++++ src/client.c Tue Apr 20 10:15:03 1999
+@@ -4172,6 +4172,16 @@
+ error (1, 0,
+ "This server does not support the global -n option.");
+ }
++ if (nolock)
++ {
++ if (have_global)
++ {
++ send_to_server ("Global_option -u\012", 0);
++ }
++ else
++ error (1, 0,
++ "This server does not support the global -u option.");
++ }
+ if (quiet)
+ {
+ if (have_global)
diff --git a/devel/cvs/patches/patch-am b/devel/cvs/patches/patch-am
new file mode 100644
index 00000000000..cc3cb1d2487
--- /dev/null
+++ b/devel/cvs/patches/patch-am
@@ -0,0 +1,12 @@
+$NetBSD: patch-am,v 1.1 1999/04/20 15:01:11 mycroft Exp $
+
+--- src/cvs.h.orig Sun Jul 26 22:54:11 1998
++++ src/cvs.h Tue Apr 20 10:15:03 1999
+@@ -383,6 +383,7 @@
+
+ extern int trace; /* Show all commands */
+ extern int noexec; /* Don't modify disk anywhere */
++extern int nolock; /* Don't create locks */
+ extern int logoff; /* Don't write history entry */
+
+ extern int top_level_admin;
diff --git a/devel/cvs/patches/patch-an b/devel/cvs/patches/patch-an
new file mode 100644
index 00000000000..d990dc54a2d
--- /dev/null
+++ b/devel/cvs/patches/patch-an
@@ -0,0 +1,13 @@
+$NetBSD: patch-an,v 1.1 1999/04/20 15:01:11 mycroft Exp $
+
+--- src/history.c.orig Sat Apr 11 12:29:49 1998
++++ src/history.c Tue Apr 20 10:15:03 1999
+@@ -725,7 +725,7 @@
+ #else
+ fprintf (stderr, "-> fopen(%s,a)\n", fname);
+ #endif
+- if (noexec)
++ if (nolock)
+ goto out;
+ fd = CVS_OPEN (fname, O_WRONLY | O_APPEND | O_CREAT | OPEN_BINARY, 0666);
+ if (fd < 0)
diff --git a/devel/cvs/patches/patch-ao b/devel/cvs/patches/patch-ao
new file mode 100644
index 00000000000..8f7f5005f69
--- /dev/null
+++ b/devel/cvs/patches/patch-ao
@@ -0,0 +1,22 @@
+$NetBSD: patch-ao,v 1.1 1999/04/20 15:01:11 mycroft Exp $
+
+--- src/lock.c.orig Wed Mar 4 00:41:50 1998
++++ src/lock.c Tue Apr 20 10:15:04 1999
+@@ -243,7 +243,7 @@
+ FILE *fp;
+ char *tmp;
+
+- if (noexec)
++ if (nolock)
+ return (0);
+
+ /* we only do one directory at a time for read locks! */
+@@ -316,7 +316,7 @@
+ {
+ char *wait_repos;
+
+- if (noexec)
++ if (nolock)
+ return (0);
+
+ /* We only know how to do one list at a time */
diff --git a/devel/cvs/patches/patch-ap b/devel/cvs/patches/patch-ap
new file mode 100644
index 00000000000..dc64af7f09d
--- /dev/null
+++ b/devel/cvs/patches/patch-ap
@@ -0,0 +1,47 @@
+$NetBSD: patch-ap,v 1.1 1999/04/20 15:01:11 mycroft Exp $
+
+--- src/main.c.orig Wed Aug 12 18:39:33 1998
++++ src/main.c Tue Apr 20 10:20:12 1999
+@@ -40,6 +40,7 @@
+ int quiet = 0;
+ int trace = 0;
+ int noexec = 0;
++int nolock = 0;
+ int logoff = 0;
+
+ /* Set if we should be writing CVSADM directories at top level. At
+@@ -217,6 +218,7 @@
+ " -w Make checked-out files read-write (default).\n",
+ " -l Turn history logging off.\n",
+ " -n Do not execute anything that will change the disk.\n",
++ " -u Don't create locks (implies -l).\n",
+ " -t Show trace of program execution -- try with -n.\n",
+ " -v CVS version and copyright.\n",
+ " -b bindir Find RCS programs in 'bindir'.\n",
+@@ -485,7 +487,7 @@
+ opterr = 1;
+
+ while ((c = getopt_long
+- (argc, argv, "+Qqrwtnlvb:T:e:d:Hfz:s:xa", long_options, &option_index))
++ (argc, argv, "+Qqrwtnulvb:T:e:d:Hfz:s:xa", long_options, &option_index))
+ != EOF)
+ {
+ switch (c)
+@@ -523,6 +525,8 @@
+ break;
+ case 'n':
+ noexec = 1;
++ case 'u': /* Fall through */
++ nolock = 1;
+ case 'l': /* Fall through */
+ logoff = 1;
+ break;
+@@ -802,7 +806,7 @@
+ * BUT, only if the history file exists.
+ */
+
+- if (!client_active)
++ if (!client_active && !nolock)
+ {
+ char *path;
+ int save_errno;
diff --git a/devel/cvs/patches/patch-aq b/devel/cvs/patches/patch-aq
new file mode 100644
index 00000000000..9b2a30b6f9b
--- /dev/null
+++ b/devel/cvs/patches/patch-aq
@@ -0,0 +1,22 @@
+$NetBSD: patch-aq,v 1.1 1999/04/20 15:01:11 mycroft Exp $
+
+--- src/recurse.c.orig Sun Jul 26 22:54:14 1998
++++ src/recurse.c Tue Apr 20 10:15:04 1999
+@@ -364,7 +364,7 @@
+ if (frame->flags == R_SKIP_ALL)
+ return (0);
+
+- should_readlock = noexec ? 0 : frame->readlock;
++ should_readlock = nolock ? 0 : frame->readlock;
+
+ /* The fact that locks are not active here is what makes us fail to have
+ the
+@@ -406,7 +406,7 @@
+ */
+ if (server_active
+ /* If there are writelocks around, we cannot pause here. */
+- && (should_readlock || noexec))
++ && (should_readlock || nolock))
+ server_pause_check();
+ #endif
+
diff --git a/devel/cvs/patches/patch-ar b/devel/cvs/patches/patch-ar
new file mode 100644
index 00000000000..eacf6161cb9
--- /dev/null
+++ b/devel/cvs/patches/patch-ar
@@ -0,0 +1,72 @@
+$NetBSD: patch-ar,v 1.1 1999/04/20 15:01:12 mycroft Exp $
+
+--- src/server.c.orig Thu Aug 6 20:46:38 1998
++++ src/server.c Tue Apr 20 10:28:06 1999
+@@ -597,31 +597,34 @@
+ nothing. But for rsh, we need to do it now. */
+ parse_config (CVSroot_directory);
+
+- path = xmalloc (strlen (CVSroot_directory)
+- + sizeof (CVSROOTADM)
+- + sizeof (CVSROOTADM_HISTORY)
+- + 10);
+- (void) sprintf (path, "%s/%s", CVSroot_directory, CVSROOTADM);
+- if (!isaccessible (path, R_OK | X_OK))
+- {
+- save_errno = errno;
+- pending_error_text = malloc (80 + strlen (path));
+- if (pending_error_text != NULL)
+- sprintf (pending_error_text, "E Cannot access %s", path);
+- pending_error = save_errno;
+- }
+- (void) strcat (path, "/");
+- (void) strcat (path, CVSROOTADM_HISTORY);
+- if (isfile (path) && !isaccessible (path, R_OK | W_OK))
+- {
+- save_errno = errno;
+- pending_error_text = malloc (80 + strlen (path));
+- if (pending_error_text != NULL)
+- sprintf (pending_error_text, "E \
++ if (!nolock)
++ {
++ path = xmalloc (strlen (CVSroot_directory)
++ + sizeof (CVSROOTADM)
++ + sizeof (CVSROOTADM_HISTORY)
++ + 10);
++ (void) sprintf (path, "%s/%s", CVSroot_directory, CVSROOTADM);
++ if (!isaccessible (path, R_OK | X_OK))
++ {
++ save_errno = errno;
++ pending_error_text = malloc (80 + strlen (path));
++ if (pending_error_text != NULL)
++ sprintf (pending_error_text, "E Cannot access %s", path);
++ pending_error = save_errno;
++ }
++ (void) strcat (path, "/");
++ (void) strcat (path, CVSROOTADM_HISTORY);
++ if (isfile (path) && !isaccessible (path, R_OK | W_OK))
++ {
++ save_errno = errno;
++ pending_error_text = malloc (80 + strlen (path));
++ if (pending_error_text != NULL)
++ sprintf (pending_error_text, "E \
+ Sorry, you don't have read/write access to the history file %s", path);
+- pending_error = save_errno;
++ pending_error = save_errno;
++ }
++ free (path);
+ }
+- free (path);
+
+ #ifdef HAVE_PUTENV
+ env = malloc (strlen (CVSROOT_ENV) + strlen (CVSroot_directory) + 1 + 1);
+@@ -1759,6 +1762,9 @@
+ {
+ case 'n':
+ noexec = 1;
++ break;
++ case 'u':
++ nolock = 1;
+ break;
+ case 'q':
+ quiet = 1;
diff --git a/devel/cvs/patches/patch-as b/devel/cvs/patches/patch-as
new file mode 100644
index 00000000000..cd24bb8e858
--- /dev/null
+++ b/devel/cvs/patches/patch-as
@@ -0,0 +1,13 @@
+$NetBSD: patch-as,v 1.1 1999/04/20 15:01:12 mycroft Exp $
+
+--- src/tag.c.orig Tue Jul 14 21:59:02 1998
++++ src/tag.c Tue Apr 20 10:15:05 1999
+@@ -851,7 +851,7 @@
+ /* The tags is valid but not mentioned in val-tags. Add it. */
+ datum value;
+
+- if (noexec)
++ if (nolock)
+ {
+ if (db != NULL)
+ dbm_close (db);