Commit Graph

142 Commits

Author SHA1 Message Date
truckman
1cbdd13fe9 Use strlcpy() instead of strncpy() when copying the encoding value
to ensure that the destination is NUL terminated.  Length truncation
of one more character should not be an issue since encoding values
that long are not supported by libc.  The destination string is
treated as a NUL terminated string, but it is only passed to strcmp()
for comparison to a set of shorter, fixed length strings, so this
is not a serious problem.

Reported by:	Coverity
CID:		974769
MFC after:	1 week
2016-05-12 08:41:22 +00:00
bapt
2f359d8f3e Note that mklocale(1) and colldef(1) are no longer used
mklocale and colldef has been replaced by localedef, but they have to be kept
until 10.2 is EOL for mklocale (it has been added to 10.3 as a bootstrap tools)
and until 10.3 is EOL for colldef (it has never been added to bootstrap tools)
2016-04-17 23:02:49 +00:00
bdrewery
2a891f1feb DIRDEPS_BUILD: Regenerate without local dependencies.
These are no longer needed after the recent 'beforebuild: depend' changes
and hooking DIRDEPS_BUILD into a subset of FAST_DEPEND which supports
skipping 'make depend'.

Sponsored by:	EMC / Isilon Storage Division
2016-02-24 17:20:11 +00:00
bapt
3a63b2a80a Reintegrate colldef(1) and mklocale(1)
While those tools are not needed anymore they are necessary to build FreeBSD 9
and 10. it does not hurt to keep those tools around until both 9 and 10 branch
become EOLed.

Modify colldef(1) to build after the change in the collation header, and ensure
it does produce the same collation definition it used to generate for 9 and 10

Reported by:	Oliver Pinter
2015-11-20 23:15:05 +00:00
bapt
2e7b1bea59 Remove mklocale which is not needed anymore 2015-08-08 20:07:32 +00:00
sjg
852129abd1 new depends 2015-06-16 23:37:19 +00:00
sjg
008d7c831f Add META_MODE support.
Off by default, build behaves normally.
WITH_META_MODE we get auto objdir creation, the ability to
start build from anywhere in the tree.

Still need to add real targets under targets/ to build packages.

Differential Revision:       D2796
Reviewed by: brooks imp
2015-06-13 19:20:56 +00:00
sjg
75a137820d dirdeps.mk now sets DEP_RELDIR 2015-06-08 23:35:17 +00:00
sjg
5860f0d106 Updated dependencies 2014-05-16 14:09:51 +00:00
sjg
1a7e48acf1 Updated dependencies 2014-05-10 05:16:28 +00:00
sjg
62bb106222 Merge from head 2013-09-05 20:18:59 +00:00
jkim
b6198521c8 Work around build breakages with GCC 4.2.
Reported by:	tinderbox
2013-05-23 05:42:35 +00:00
ed
120125784a Add the Clang specific -Wmissing-variable-declarations to WARNS=6.
This compiler flag enforces that that people either mark variables
static or use an external declarations for the variable, similar to how
-Wmissing-prototypes works for functions.

Due to the fact that Yacc/Lex generate code that cannot trivially be
changed to not warn because of this (lots of yy* variables), add a
NO_WMISSING_VARIABLE_DECLARATIONS that can be used to turn off this
specific compiler warning.

Announced on:	toolchain@
2013-04-19 19:45:00 +00:00
sjg
6d37b86f2b Updated dependencies 2013-03-11 17:21:52 +00:00
sjg
0ee5295509 Updated dependencies 2013-02-16 01:23:54 +00:00
marcel
9dd41e3647 Sync FreeBSD's bmake branch with Juniper's internal bmake branch.
Requested by: Simon Gerraty <sjg@juniper.net>
2012-08-22 19:25:57 +00:00
bapt
310ab6d7ff Fix world after byacc import:
- old yacc(1) use to magicially append stdlib.h, while new one don't
- new yacc(1) do declare yyparse by itself, fix redundant declaration of
  'yyparse'

Approved by:	des (mentor)
2012-05-22 16:33:10 +00:00
joel
82a81c78d9 Minor mdoc nits. 2012-05-13 14:16:04 +00:00
joel
29af67e52c Remove the advertising clause from UCB copyrighted files in usr.bin. This
is in accordance with the information provided at
ftp://ftp.cs.berkeley.edu/pub/4bsd/README.Impt.License.Change

Also add $FreeBSD$ to a few files to keep svn happy.

Discussed with:	imp, rwatson
2010-12-11 08:32:16 +00:00
ed
9b380e30d4 Build usr.bin/ with WARNS=6 by default.
Also add some missing $FreeBSD$ to keep svn happy.
2010-01-02 10:27:05 +00:00
ed
b9ca89bfc4 ANSIfy almost all applications that use WARNS=6.
I was considering committing all these patches one by one, but as
discussed with brooks@, there is no need to do this. If we ever
need/want to merge these changes back, it is still possible to do this
per application.
2009-12-29 22:53:27 +00:00
delphij
0842b7d53f Revert most part of 200420 as requested, as more review and polish is
needed.
2009-12-13 03:14:06 +00:00
delphij
b963db4652 Remove unneeded header includes from usr.bin/ except contributed code.
Tested with:	make universe
2009-12-11 23:35:38 +00:00
ed
5337594c18 Make mklocale work again, now that fwrite()'s return codes are different.
Submitted by:	Navdeep Parhar <nparhar gmail com>
Approved by:	re (kib)
2009-07-14 09:19:33 +00:00
ache
0f0fc0acb4 Understand newly introduced "ASCII" encoding 2008-01-22 00:04:50 +00:00
rafan
0e5790193d - Include runefile.h for _CACHED_RUNES 2007-11-07 14:46:22 +00:00
kevlo
ee96f0aa6f Use NULL instead of 0 for the return value of fopen().
Approved by: re (kensmith)
2007-09-21 01:55:11 +00:00
kevlo
5a57d3e796 getopt(3) returns -1, not EOF. 2007-02-06 08:48:28 +00:00
ru
86758e8895 Make <runefile.h> internal to libc.
Suggested by:	phantom
2005-05-16 09:32:41 +00:00
ru
dff27cebe2 Make the format of LC_CTYPE files architecture independent by
introducing the disk formats for _RuneLocale and friends.

The disk formats do not have (useless) pointers and have 32-bit
quantities instead of rune_t and long.  (htonl(3) only works
with 32-bit quantities, so there's no loss).

Bootstrap mklocale(1) when necessary.  (Bootstrapping from 4.x
would be trivial (verified), but we no longer provide pre-5.3
source upgrades and this is the first commit to actually break
it.)
2005-02-26 21:47:54 +00:00
ru
3666aefb6a Fixed xref. 2005-01-21 10:48:35 +00:00
ru
7f3c7f0d46 Sort sections. 2005-01-18 13:43:56 +00:00
tjr
3d89cd8c71 Remove the obsolete <rune.h> interface. 2004-10-17 06:51:50 +00:00
tjr
8a463b57c4 Use <runetype.h> instead of <rune.h> since the latter is going away. 2004-10-17 03:02:50 +00:00
tjr
b956669fcf Remove explicit support for generating LC_CTYPE data files that specify
the obsolete "UTF2" encoding.
2004-10-17 01:08:11 +00:00
tjr
6ad9afc94f The UTF2 encoding and the INVALID keyword are now obsolete. 2004-08-21 08:16:36 +00:00
ru
ee5b7e52fa Deal with double whitespace. 2004-07-03 00:24:45 +00:00
ru
fb1d8b3724 Mechanically kill hard sentence breaks. 2004-07-02 22:22:35 +00:00
tjr
d04fd4700f Prefix the names of members of _RuneLocale and its sub-structures
with ``__'' to avoid polluting the namespace. This doesn't change the
documented rune interface at all, but breaks applications that accessed
_RuneLocale directly.
2004-06-23 07:01:44 +00:00
tjr
126f909d87 Fix section number in cross reference. 2004-01-23 20:29:03 +00:00
tjr
39b36ed8f7 Update cross references after utf2/euc move. 2003-11-15 02:49:53 +00:00
tjr
41b66e50b6 Add GB2312 to the list of supported encodings. Cross-reference gb2312(5). 2003-11-08 03:19:26 +00:00
davidxu
a6e1effefa Add gb2312 encoding. 2003-11-05 22:52:51 +00:00
tjr
3bdf2e08b5 #include <runetype.h> directly for the definition of _CACHED_RUNES, needed
by ldef.h, rather than relying on GCC-specific pollution from <ctype.h>.

Noticed by:	Stefan Farfeleder
2003-09-05 16:05:21 +00:00
tjr
e57dce4ab7 Add GB18030 and GBK to the list of encodings. Cross-reference the
new manual pages for the Big5, GB18030, GBK, and MSKanji encodings.
2003-08-10 11:51:14 +00:00
ache
31c272ad24 Allow GB18030 locale 2003-07-29 07:56:05 +00:00
charnier
501fae1f3a Bump WARNS to 6. Add usage(). Use provided xmalloc() instead of malloc().
Use err().
2003-06-17 19:58:33 +00:00
ache
5b07ec4fbc Change fatal to warnx() for unknown encoding 2003-06-03 16:58:31 +00:00
ache
7b3c2b7e5f Hardcore supported encodings list 2003-06-02 19:54:29 +00:00
schweikh
fec6546e12 english(4) police. 2002-12-27 12:15:40 +00:00