Commit Graph

120 Commits

Author SHA1 Message Date
Edwin Groothuis
b5f58d7778 - Add support for chrooted installs.
- Add examples to the man-page.

MFC after:	1 week
2009-10-21 20:55:04 +00:00
Edwin Groothuis
ada5f18a1b Instead of having to know which timezone was picked last time, you
now can run "tzsetup -r" which will reinstall the last choice. This
data is recorded in /var/db/zoneinfo.

MFC after:	 1 week
2009-10-20 06:54:31 +00:00
Edwin Groothuis
b89269048d Make the usage of the default zoneinfo file to install clearer.
MFC after:	 1 week
2009-10-19 21:37:31 +00:00
Edwin Groothuis
08c7e8c879 When tzsetup is run as non-root and the "CMOS clock question on
UTC" is answered as No, it would abort without properly ending the
dialog session.

MFC after:	 1 week
2009-10-19 21:24:19 +00:00
Attilio Rao
5d279e6530 Add a new options (-s) that, when specified, skips the question about
adjusting the clock to UTC.
That avoids to write on /etc/wall_cmos_clock which is useful in some
cases (example: host user in a jail).

Sponsored by:	Sandvine Incorporated
Initially submitted by:	Matt Koivisto <mkoivisto at sandvine dot com>
Approved by:	re (kib)
2009-07-04 11:11:21 +00:00
Jung-uk Kim
659a596a2c - Replace rcsid with __FBSDID.
- Remove paths.h and embed it in the source.
- Remove stale alpha support.
- Clean up compiler warnings and fix style(9) bugs.
2008-06-03 22:34:52 +00:00
Jung-uk Kim
62467b2549 Fix a crash when Arctic Ocean is selected.
MFC after:	1 week
2008-06-02 23:37:33 +00:00
Ruslan Ermilov
59a3c79da6 Sort sections. 2005-01-18 20:02:45 +00:00
Murray Stokely
84b7e70dfc Update wording regarding geography to match the man page and web site.
Specifically, change the second level menu title from 'Country' to
'Country or Region', since e.g. Hong Kong is not a country.

Submitted by:	Xin LI <delphij@frontfree.net>
2004-08-10 05:34:23 +00:00
Ruslan Ermilov
07bfccd71e Mechanically kill hard sentence breaks. 2004-07-02 23:13:00 +00:00
Jimmy Olgeni
50c956f08d Cosmetic fix: a message was mixed with a dialog box border line.
Approved by:	re (rwatson)
2003-11-28 20:44:25 +00:00
David E. O'Brien
052238b16c style.Makefile(5) 2003-04-04 17:49:21 +00:00
Philippe Charnier
490d5836b5 The .Nm utility 2002-07-14 14:47:15 +00:00
Dag-Erling Smørgrav
cb20e5a97a Explicitly cast NCONTINENTS to int to silence an overflow warning. 2002-05-15 09:39:31 +00:00
David E. O'Brien
a956ec3bed Default to UTC on sparc64 also. 2002-03-06 06:18:21 +00:00
Ruslan Ermilov
c4d9468ea0 mdoc(7) police:
Avoid using parenthesis enclosure macros (.Pq and .Po/.Pc) with plain text.
Not only this slows down the mdoc(7) processing significantly, but it also
has an undesired (in this case) effect of disabling hyphenation within the
entire enclosed block.
2001-08-07 15:48:51 +00:00
David E. O'Brien
90e655ea4e Perform a major cleanup of the usr.sbin Makefiles.
These are not perfectly in agreement with each other style-wise, but they
are orders of orders of magnitude more consistent style-wise than before.
2001-07-20 06:20:32 +00:00
Dima Dorfman
f247324df7 Remove whitespace at EOL. 2001-07-15 08:06:20 +00:00
Ruslan Ermilov
a4c37c816b mdoc(7) police: removed HISTORY info from the .Os call. 2001-07-10 15:12:08 +00:00
David E. O'Brien
546f81a8d1 Remove -Wall. It breaks compiling with non-gcc compilers. 2001-04-05 20:52:33 +00:00
David E. O'Brien
2881e5831b Default the UTC question to "yes" on the Alpha. 2001-04-05 02:46:40 +00:00
David E. O'Brien
232470f6f6 This builds fine with -Wall. 2001-04-05 02:46:21 +00:00
Ruslan Ermilov
345e52e742 - Backout botched attempt to introduce MANSECT feature.
- MAN[1-9] -> MAN.
2001-03-26 14:42:20 +00:00
Ruslan Ermilov
c73e22c3d4 Set the default manual section for usr.sbin/ to 8. 2001-03-20 18:17:26 +00:00
Ben Smithurst
d0d78e1303 Convert to use the <sys/queue.h> macros rather than fiddling with the queue
structure internals.

Reviewed by:	markm
2000-12-29 18:04:54 +00:00
Jordan K. Hubbard
0e3099f516 Use dialog_noyes() for UTC selection; uses No as default answer now. 2000-12-16 05:29:38 +00:00
Ruslan Ermilov
e97407b4f2 mdoc(7) police: use the new features of the Nm macro. 2000-11-20 20:10:44 +00:00
Ruslan Ermilov
b5c508fba3 Use Fx macro wherever possible. 2000-11-14 11:20:58 +00:00
Garrett Wollman
eb2fc78027 Don't depend on <sys/stat.h> bogusly including <sys/time.h> (and thereby
<time.h>).
2000-10-10 01:50:26 +00:00
Andrey A. Chernov
f4723e5279 Remove unneded -lmytinfo 2000-09-16 03:33:00 +00:00
Jake Burkholder
e39756439c Back out the previous change to the queue(3) interface.
It was not discussed and should probably not happen.

Requested by:		msmith and others
2000-05-26 02:09:24 +00:00
Jake Burkholder
740a1973a6 Change the way that the queue(3) structures are declared; don't assume that
the type argument to *_HEAD and *_ENTRY is a struct.

Suggested by:	phk
Reviewed by:	phk
Approved by:	mdodd
2000-05-23 20:41:01 +00:00
Philippe Charnier
bb897a8710 Convert err() to errx(), reason is already provided. Complete the
abort on allocation failure instead of deferencing NULL later.
2000-01-23 20:25:01 +00:00
Chris Costello
bca1bc6498 Re-add the libmytinfo/libncurses stuff - removing it breaks static
linkage.

Pointed out by:		bde
1999-09-01 23:36:21 +00:00
Chris Costello
5d3e37130b The libraries libmytinfo' and libncurses' are not required by this
program.
1999-09-01 20:37:44 +00:00
Peter Wemm
97d92980a9 $Id$ -> $FreeBSD$ 1999-08-28 01:35:59 +00:00
Ruslan Ermilov
c43651a60d - ignore the user-supplied umask, set it to 0022 by default
- install /etc/wall_cmos_clock with 0444 mode rather than 0666
- -Wall inspection

PR:		12967
1999-08-05 11:48:47 +00:00
Michael Haro
3256d507ff Make UTC or local time message a little more clear. 1999-06-23 03:31:36 +00:00
Garrett Wollman
239e57d031 Add a `default' feature to tzsetup for use in script-driven installation
(if someone writes the other half).  Also rewrite the man page in a more
appropriate (formal) style.
1999-02-02 20:26:31 +00:00
Peter Wemm
8b315e85c7 Old stuff lying around a source tree:
Create/remove /etc/wall_cmos_clock without using system() and magic paths.
1998-12-16 05:34:49 +00:00
Steve Price
f8ddb109a4 Minor brace gymnastics so that /etc/wall_cmos_clock is really
created.

PR:		5473
Submitted by:	MIHIRA Yoshiro <sanpei@yy.cs.keio.ac.jp>
1998-01-10 15:55:11 +00:00
Joerg Wunsch
8f8262da39 Teach tzsetup to understand blank lines in the iso3166 file.
Found by:  evanc@synapse.net (Evan Champion)
1997-11-07 00:07:27 +00:00
Philippe Charnier
342afc34d7 Add usage(). Document -n flag. Do not touch/remove /etc/wall_cmos_clock
when -n (do nothing) is used.
1997-10-27 07:49:47 +00:00
Steve Price
d0dff61cfb Fix a minor nit in the .Dd macro invocation so that
the revision date is displayed correctly.
1997-06-23 04:52:13 +00:00
Peter Wemm
476602a9d0 Revert $FreeBSD$ to $Id$ 1997-02-22 16:15:28 +00:00
Jordan K. Hubbard
b94679130c Ask about local or UTC here, like we used to. 1997-02-16 23:51:03 +00:00
John Hay
3e70cf1f94 At the end it was much simpler than I thought. 26 * 26 = 676 and not 576.
South Africa and a few other countries exists again. This fix pr 2595.
This should go into 2.2.
1997-02-01 17:03:10 +00:00
Jordan K. Hubbard
c9af0102c6 Make some of the less necessary user feedback #ifdef VERBOSE.
We could also make this stuff only come out when getpid() != 1
and thus avoid the install case (where it really is just too verbose,
and people have complained), but this seems less messy and no one
complained when tzsetup didn't print the final "things went fine!"
messages (which sort of contravene the UNIX spirit of only yelling
when you need to anyway).
1997-01-21 10:53:38 +00:00
Wolfram Schneider
bfd34a4a60 Sort cross references. 1997-01-20 00:03:00 +00:00
Jordan K. Hubbard
1130b656e5 Make the long-awaited change from $Id$ to $FreeBSD$
This will make a number of things easier in the future, as well as (finally!)
avoiding the Id-smashing problem which has plagued developers for so long.

Boy, I'm glad we're not using sup anymore.  This update would have been
insane otherwise.
1997-01-14 07:20:47 +00:00
Joerg Wunsch
b0fa330d5f Remove two uninitialized and unused variables that used to cause a
segfault before.
1996-11-19 23:21:52 +00:00
Garrett Wollman
037def9693 Completely re-vamped `tzsetup':
- It no longer attempts to fiddle wall-vs-UTC-in-RTC.  The results
  were just confusing most of the time.

- The program no longer contains a pre-compiled list of timezones
  (compiled by groveling through the tzdata source files for comments
  starting with `ZONE-DESCR').  Now it uses the new `zone.tab' file
  supplied with current versions of the timezone data files, to determine
  the list at run time.  (It also requires the ISO 3166 table  I
  committed some months ago.)

AS A RESULT, this program will NOT work until the new timezone data files
are committed (should happen sometime soon).
1996-11-19 18:09:41 +00:00
Bruce Evans
680b396b51 Removed unused `-I.'s from CFLAGS.
"." means the object directory, so it is just confusing to use it
when nothing is included from the object directory unless the object
directory is also the source directory.  It is confusing for "."
not to mean the source directory anyway, so used `-I.'s should be
replaced by `-I${.OBJDIR}'.
1996-09-04 22:25:35 +00:00
Wolfram Schneider
5a80fb277e sync copyright with /usr/share/examples/etc/bsd-style-copyright 1996-08-27 20:04:45 +00:00
Wolfram Schneider
7e0b7d4a87 add pathnames.h, -Wall cleanup 1996-08-20 23:51:20 +00:00
Jordan K. Hubbard
d009678316 Only print the selected timezone in verification rather than the bogus time. 1996-07-03 01:17:34 +00:00
Joerg Wunsch
c78cc02b89 Copy /etc/localtime, unless it's already a symlink. 1996-04-01 08:17:49 +00:00
Joerg Wunsch
2d71a1f121 Another round of fixes:
. Replace my NIH-suffering code to detect the number of lines on
  the terminal by the curses variable LINES.

. Fix the selection code for countries with more than one screenful
  of locations.  The very few people living in America/US/Pacific
  now won't be charged for Indiana any longer... :)

. Removed the gross code that copied over the timezone file to
  /etc/localtime, and create a symlink now instead.
1996-03-31 09:55:02 +00:00
Joerg Wunsch
53d5c416fe All this was horribly broken. The menues were overflowing, the `diff'
calculation wrong, bogus `reboot now!' hints given, and the displayed
month off by one.

Fix all of this.

Requested by:	jkh
1996-03-22 22:22:40 +00:00
Wolfram Schneider
8349ecbf7a Convert "time zone" to "timezone" in NAME section
Submitted by:	obrien@cs.ucdavis.edu (David E. O'Brien)
1996-02-27 00:27:21 +00:00
Wolfram Schneider
8eeb71d709 add a manpage 1996-01-24 00:11:58 +00:00
Peter Wemm
a5b996a7ec recording cvs-1.6 file death 1995-12-30 19:02:48 +00:00
Jordan K. Hubbard
a936507ae9 Don't put up bogus confirmation dialog. 1995-10-06 02:46:23 +00:00
Rodney W. Grimes
d3628763db Merge RELENG_2_0_5 into HEAD 1995-06-11 19:33:05 +00:00
Rodney W. Grimes
709e8f9ae1 Remove trailing whitespace. 1995-05-30 03:57:47 +00:00
Garrett Wollman
d259f40530 Grand new all-singing, dialog-wielding tzsetup(8). Still needs a man page. 1995-04-24 21:04:35 +00:00
Andrey A. Chernov
a3d3b73b53 Restore back -i for adjkerntz 1994-11-02 09:43:38 +00:00
Andrey A. Chernov
07e01ef0c9 Remove -i option from adjkerntz 1994-11-02 00:00:17 +00:00
Andrey A. Chernov
65c3bb832a Add 'rm -f /etc/localtime' before cp to /etc/localtime,
I have a link here and got strange results without 'rm'
1994-09-18 18:27:30 +00:00
Garrett Wollman
e7d3fe3100 A little script to help users in setting up their timezone. (Try it!) 1994-09-13 23:01:59 +00:00