Browse code

- install-man will automatically "fix" the path of the files referred in the man pages - switched to /dev/urandom instead of /dev/random (/dev/random blocks if it haven't gathered enough entropy and is is not present on all the systems) - minor man pages fixes

Andrei Pelinescu-Onciul authored on 02/09/2004 13:42:28
Showing 5 changed files
... ...
@@ -27,6 +27,8 @@
27 27
 #  2003-08-29  install-modules-doc split from install-doc, added 
28 28
 #               install-modules-all, removed README.cfg (andrei)
29 29
 #              added skip_cfg_install (andrei)
30
+#  2004-09-02  install-man will automatically "fix" the path of the files
31
+#               referred in the man pages
30 32
 #
31 33
 
32 34
 auto_gen=lex.yy.c cfg.tab.c   #lexx, yacc etc
... ...
@@ -328,8 +330,15 @@ install-modules-doc: $(doc-prefix)/$(doc-dir)
328 328
 
329 329
 
330 330
 install-man: $(man-prefix)/$(man-dir)/man8 $(man-prefix)/$(man-dir)/man5
331
-	$(INSTALL-TOUCH)  $(man-prefix)/$(man-dir)/man8/ser.8 
332
-	$(INSTALL-MAN)  ser.8 $(man-prefix)/$(man-dir)/man8/
333
-	$(INSTALL-TOUCH)  $(man-prefix)/$(man-dir)/man5/ser.cfg.5 
334
-	$(INSTALL-MAN)  ser.cfg.5 $(man-prefix)/$(man-dir)/man5
335
-
331
+		sed -e "s#/etc/ser/ser\.cfg#$(cfg-target)ser.cfg#g" \
332
+			-e "s#/usr/sbin/#$(bin-target)#g" \
333
+			-e "s#/usr/lib/ser/modules/#$(modules-target)#g" \
334
+			-e "s#/usr/share/doc/ser/#$(doc-target)#g" \
335
+			< ser.8 >  $(man-prefix)/$(man-dir)/man8/ser.8
336
+		chmod 644  $(man-prefix)/$(man-dir)/man8/ser.8
337
+		sed -e "s#/etc/ser/ser\.cfg#$(cfg-target)ser.cfg#g" \
338
+			-e "s#/usr/sbin/#$(bin-target)#g" \
339
+			-e "s#/usr/lib/ser/modules/#$(modules-target)#g" \
340
+			-e "s#/usr/share/doc/ser/#$(doc-target)#g" \
341
+			< ser.cfg.5 >  $(man-prefix)/$(man-dir)/man5/ser.cfg.5
342
+		chmod 644  $(man-prefix)/$(man-dir)/man5/ser.cfg.5
... ...
@@ -118,7 +118,9 @@ endif
118 118
 ut-prefix = bin/
119 119
 # target dirs for various stuff
120 120
 cfg-target = $(prefix)/$(cfg-dir)
121
+bin-target = $(prefix)/$(bin-dir)
121 122
 modules-target = $(prefix)/$(modules-dir)
123
+doc-target = $(prefix)/$(doc-dir)
122 124
 
123 125
 
124 126
 ifeq ($(OS), solaris)
... ...
@@ -1287,19 +1287,19 @@ int main(int argc, char** argv)
1287 1287
 	}
1288 1288
 
1289 1289
 	/* seed the prng */
1290
-	/* try to use /dev/random if possible */
1290
+	/* try to use /dev/urandom if possible */
1291 1291
 	seed=0;
1292
-	if ((rfd=open("/dev/random", O_RDONLY))!=-1){
1292
+	if ((rfd=open("/dev/urandom", O_RDONLY))!=-1){
1293 1293
 try_again:
1294 1294
 		if (read(rfd, (void*)&seed, sizeof(seed))==-1){
1295 1295
 			if (errno==EINTR) goto try_again; /* interrupted by signal */
1296
-			LOG(L_WARN, "WARNING: could not read from /dev/random (%d)\n",
1296
+			LOG(L_WARN, "WARNING: could not read from /dev/urandom (%d)\n",
1297 1297
 						errno);
1298 1298
 		}
1299
-		DBG("read %u from /dev/random\n", seed);
1299
+		DBG("read %u from /dev/urandom\n", seed);
1300 1300
 			close(rfd);
1301 1301
 	}else{
1302
-		LOG(L_WARN, "WARNING: could not open /dev/random (%d)\n", errno);
1302
+		LOG(L_WARN, "WARNING: could not open /dev/urandom (%d)\n", errno);
1303 1303
 	}
1304 1304
 	seed+=getpid()+time(0);
1305 1305
 	DBG("seeding PRNG with %u\n", seed);
... ...
@@ -86,7 +86,7 @@ Displays the version number.
86 86
 Reads the configuration from 
87 87
 .B " config\-file" 
88 88
 (default
89
-.I  ./ser.cfg
89
+.I  /etc/ser/ser.cfg
90 90
 ).
91 91
 .TP
92 92
 .BI \-l " address"
... ...
@@ -154,31 +154,9 @@ status.
154 154
 .B /usr/lib/ser/modules/*
155 155
 .PD
156 156
 .SH AUTHORS
157
-Andrei Pelinescu - Onciul, <pelinescu-onciul@fokus.gmd.de>
158
-.br
159
-Bogdan Andrei Iancu
160
-.br
161
-Daniel-Constantin Mierla
162
-.br 
163
-Jan Janak
164
-.br
165
-Jiri Kuthan
166
-.br
167
-Juha Heinanen
168
-.br
169
-Maxim Sobolev
170
-.br
171
-Miklos Tirpak
172
-.br
173
-Nils Ohlmeier
174
-.br
175
-Ramona-Elena Modroiu
176
-.br
177
-Raphael Coeffic
178
-.br
179
-Ricardo Baratto
180
-.br
181
-Stelios Sidiroglou-Douskos
157
+
158
+see 
159
+.B /usr/share/doc/ser/AUTHORS
182 160
 
183 161
 .SH SEE ALSO
184 162
 .BR ser.cfg(5)
... ...
@@ -29,31 +29,9 @@ This manual page is incomplete. For further information please read the
29 29
 .br
30 30
 
31 31
 .SH AUTHORS
32
-Andrei Pelinescu - Onciul, <pelinescu-onciul@fokus.gmd.de>
33
-.br
34
-Bogdan Andrei Iancu
35
-.br
36
-Daniel-Constantin Mierla
37
-.br 
38
-Jan Janak
39
-.br
40
-Jiri Kuthan
41
-.br
42
-Juha Heinanen
43
-.br
44
-Maxim Sobolev
45
-.br
46
-Miklos Tirpak
47
-.br
48
-Nils Ohlmeier
49
-.br
50
-Ramona-Elena Modroiu
51
-.br
52
-Raphael Coeffic
53
-.br
54
-Ricardo Baratto
55
-.br
56
-Stelios Sidiroglou-Douskos
32
+
33
+see 
34
+.B /usr/share/doc/ser/AUTHORS
57 35
 
58 36
 .SH SEE ALSO
59 37
 .BR ser(8)