Commit Graph

13 Commits (1944d8c53d613b5185b5fe6734007f41324e4421)

Author SHA1 Message Date
Andreas Dilger 3a941bef3b build: use long long for __u64 by default
Don't print a verbose configure error in parse-types.h if
<asm/types.h> missing and __[SU]*_TYPEDEF is unset.  This is
always the case for non-Linux builds.

The printf formatting strings all use "%llu" for printing 64-bit
values and this it produces a large number of warnings if __u64
is defined as "unsigned long".  If __U64_TYPEDEF isn't set use
"unsigned long long" for __u64 in ext2-types.h and blkid-types.h
by default instead of using "unsigned long".

Fix a few places where "%d" or "%u" or "%Lu" were used to print a
64-bit value, by converting them to use "%lld" or "%llu" instead.

Fix a few places where "%lu" was used to print .tv_usec, by casting
the variable to "(long)" since .tv_usec is "int" on some systems.

Signed-off-by: Andreas Dilger <adilger@dilger.ca>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2013-12-15 22:10:09 -05:00
Theodore Ts'o d1154eb460 Shorten compile commands run by the build system
The DEFS line in MCONFIG had gotten so long that it exceeded 4k, and
this was starting to cause some tools heartburn.  It also made "make
V=1" almost useless, since trying to following the individual commands
run by make was lost in the noise of all of the defines.

So fix this by putting the configure-generated defines in lib/config.h
and the directory pathnames to lib/dirpaths.h.

In addition, clean up some vestigal defines in configure.in and in the
Makefiles to further shorten the cc command lines.

Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2011-09-18 17:34:37 -04:00
Theodore Ts'o efc6f628e1 Remove trailing whitespace for the entire source tree
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2008-08-27 23:07:54 -04:00
Theodore Ts'o 6ec9ef1881 libuuid: Windows portability fixes
Make the uuid library (more) portable for Windows.

Addresses-Sourceforge-Feature-Request: #1937287

Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
2008-08-22 12:15:56 -04:00
Theodore Ts'o 2625803ecf Use C99 stdint.h types instead of custom types in the uuid library. 2004-04-03 10:20:26 -05:00
Theodore Ts'o 1bbfec624c Change the license on the UUID library to be 3-clause BSD-style 2004-03-20 14:02:24 -05:00
Theodore Ts'o ce2722f86d compare.c (uuid_compare), copy.c (uuid_copy),
isnull.c (uuid_is_null), pack.c (uuid_pack), 
	parse.c (uuid_parse), unpack.c (uuid_unpack),
	unparse.c (uuid_unparse), uuid.h, uuidP.h, 
	uuid_time.c (uuid_time, uuid_type, uuid_variant):
	Use const for pointer variables that we don't modify.  Add
	the appropriate ifdef's in uuid.h to make it be C++ friendly.
2001-09-10 20:30:09 -04:00
Theodore Ts'o 0923fc6d35 ChangeLog, unpack.c, unparse.c, uuid_time.c:
unpack.c, unparse.c, uuid_time.c: Update files to be under the LGPL
  	(that somehow were missed when libuuid was converted to use the LGPL).
  	Whoops.
2001-06-01 15:03:25 +00:00
Theodore Ts'o 54c637d4d2 Many files:
badblocks.c, chattr.c, dumpe2fs.c, e2image.c, findsuper.c, lsattr.c,
  	mke2fs.c, mklost+found.c, tune2fs.c, util.c: Change location of
  	ext2_fs.h to be ext2fs/ext2_fs.h
ChangeLog, Makefile.in, resize2fs.h:
  resize2fs.h: Change location of ext2_fs.h to be ext2fs/ext2_fs.h
ChangeLog, Makefile.in, debugfs.h:
  debugfs.h: Change location of ext2_fs.h to be ext2fs/ext2_fs.h
ChangeLog, Makefile.in, e2fsck.h, scantest.c:
  e2fsck.h, scantest.c: Change location of ext2_fs.h to be
  	ext2fs/ext2_fs.h
ChangeLog, Makefile.in, tst_uuid.c, uuid_time.c:
  tst_uuid.c, uuid_time.c: Remove unneeded #include of ext2_fs.h
ChangeLog, Makefile.in, e2p.h:
  e2p.h: Change location of ext2_fs.h to be ext2fs/ext2_fs.h
ChangeLog, Makefile.in, test_icount.c, test_rel.c:
  test_icount.c, test_rel.c: Change location of ext2_fs.h to be
  	ext2fs/ext2_fs.h
2001-05-14 11:45:38 +00:00
Theodore Ts'o 96394d11b0 ChangeLog, copy.c, gen_uuid.c, tst_uuid.c, uuid_time.c:
uuid_time.c (main), tst_uuid.c (main): Fix gcc -Wall complaints.
  copy.c (uuid_copy): Change arguments to make it clear which argument
  	is the source and which is the destination.
  gen_uuid.c (get_random_fd): Use gettimeofday to seed the PRNG, so we
  	can take advantage of tv_usec to do (slightly) better at seeding it.
2001-01-12 18:30:54 +00:00
Theodore Ts'o 36caf25f8d ChangeLog, e2p.h, feature.c:
feature.c: Fix GCC warnings; add const to the char * types in the
  	function prototypes for e2p_feature2string and e2p_edit_feature.
ChangeLog, uuid.h, uuid_time.c:
  uuid_time.c (variant_string): Declare to be static to avoid gcc warnings.
  uuid.h: Add function prototypes for uuid_generate_random() and
  	uuid_generate_time().
ChangeLog, chattr.c:
  chattr.c: Add hack to compile in a definition for S_ISLNK so we can
  	successfully compile even with warnings turned on.
1999-10-26 14:29:22 +00:00
Theodore Ts'o b19d1a959e Many files:
* gen_uuid.c (get_random_bytes): Use a while loop when reading from
  	/dev/urandom so that if we get interrupted while reading the right
  	thing happens.
  	(uuid_generate_random): Add new function which uses the new UUID
  	format which uses 122 random bits to form the 128-bit UUID.
  	(uuid_generate): Rename the old uuid_generate to be
  	uuid_generate_time, and create a new uuid_generate function which
  	calls either uuid_generate_random or uuid_genereate_time depending on
  	whether /dev/urandom is present.
  uuid_generate.3.in: Update to reflect changesin uuid_generate and its
  	two new variants.
  tst_uuid.c: Updated to test new uuid_generate functions, and to
  	reflect new semantics of uuid_compare.  Added tests to make sure the
  	UUID type and variant created by UUID generate is correct.
  uuid_time.c (uuid_variant, uuid_type): Added new functions to return
  	the UUID variant and type information.  The debugging program now
  	prints the UUID variant and type, and warns if the unparsed time
  	information is likely to be incorrect.
  uuid_parse.3.in, libuuid.3.in: Miscellaneous text cleanups.
uuidgen.1.in:
  Miscellaneous text cleanups.
1999-06-18 00:32:03 +00:00
Theodore Ts'o 1e0a221b5d ChangeLog, Makefile.in, tst_uuid.c, uuid.h, uuid_time.c:
Makefile.in: Update version numbers of the UUID shared library, since
  	we've added a new function (uuid_time()).
  uuid_time.c: New file which returns the time field of a UUID.  (Good
  	for debugging purposes)
libext2fs.texinfo:
  Update version number for 1.13 release.
1998-12-04 08:13:52 +00:00