mirror of
https://salsa.debian.org/srivasta/make-dfsg.git
synced 2025-01-18 11:27:37 +00:00
[SV 49114] Remove support for the NO_FLOAT compile flag.
* makeint.h (max_load_average): Always a double. * main.c (max_load_average, default_load_average): Always doubles. (switches): -l option is a "floating" format. (decode_switches, define_makeflags): Support "floating" format. * remake.c (f_mtime): Show time skew as double. * rule.c (print_rule_data_base): Show percentages as double. * Makefile.ami, README.DOS.template, SMakefile.template: Remove references to NO_FLOAT. * SCOPTIONS, glob/SCOPTIONS: Remove NO_FLOAT settings.
This commit is contained in:
parent
e4a9c9b825
commit
72af7ce8af
10 changed files with 6 additions and 49 deletions
|
@ -32,7 +32,6 @@ LDFLAGS =
|
|||
|
||||
# Define these for your system as follows:
|
||||
# -DNO_ARCHIVES To disable 'ar' archive support.
|
||||
# -DNO_FLOAT To avoid using floating-point numbers.
|
||||
# -DENUM_BITFIELDS If the compiler isn't GCC but groks enum foo:2.
|
||||
# Some compilers apparently accept this
|
||||
# without complaint but produce losing code,
|
||||
|
|
|
@ -73,13 +73,7 @@ To build from sources:
|
|||
should be available from the usual DJGPP sites) and rerun
|
||||
configure.bat.
|
||||
|
||||
4. If you will need to run Make on machines without an FPU, you
|
||||
might consider building a version of Make which doesn't issue
|
||||
floating-point instructions (they don't help much on MSDOS
|
||||
anyway). To this end, edit the Makefile created by
|
||||
configure.bat and add -DNO_FLOAT to the value of CPPFLAGS.
|
||||
|
||||
5. Invoke Make.
|
||||
4. Invoke Make.
|
||||
|
||||
If you are building from outside of the source directory, you
|
||||
need to tell Make where the sources are, like this:
|
||||
|
@ -90,7 +84,7 @@ To build from sources:
|
|||
use a full, not relative, name of the source directory here, or
|
||||
else Make might fail.
|
||||
|
||||
6. After Make finishes, if you have a Unix-style shell installed,
|
||||
5. After Make finishes, if you have a Unix-style shell installed,
|
||||
you can use the 'install' target to install the package. You
|
||||
will also need GNU Fileutils and GNU Sed for this (they should
|
||||
be available from the DJGPP sites).
|
||||
|
@ -120,10 +114,10 @@ To build from sources:
|
|||
(If your Info directory is other than C:\DJGPP\INFO, change this
|
||||
command accordingly.)
|
||||
|
||||
7. The 'clean' targets also require Unix-style shell, and GNU Sed
|
||||
6. The 'clean' targets also require Unix-style shell, and GNU Sed
|
||||
and 'rm' programs (the latter from Fileutils).
|
||||
|
||||
8. To run the test suite, type "make check". This requires a Unix
|
||||
7. To run the test suite, type "make check". This requires a Unix
|
||||
shell (I used the DJGPP port of Bash 2.03), Perl, Sed, Fileutils
|
||||
and Sh-utils.
|
||||
|
||||
|
|
|
@ -6,7 +6,6 @@ OPTIMIZERALIAS
|
|||
DEFINE INCLUDEDIR="include:"
|
||||
DEFINE LIBDIR="lib:"
|
||||
DEFINE NO_ALLOCA
|
||||
DEFINE NO_FLOAT
|
||||
DEFINE NO_ARCHIVES
|
||||
IGNORE=161
|
||||
IGNORE=100
|
||||
|
|
|
@ -38,7 +38,6 @@ LDFLAGS =
|
|||
|
||||
# Define these for your system as follows:
|
||||
# -DNO_ARCHIVES To disable 'ar' archive support.
|
||||
# -DNO_FLOAT To avoid using floating-point numbers.
|
||||
# -DENUM_BITFIELDS If the compiler isn't GCC but groks enum foo:2.
|
||||
# Some compilers apparently accept this
|
||||
# without complaint but produce losing code,
|
||||
|
|
|
@ -6,7 +6,6 @@ OPTIMIZERALIAS
|
|||
DEFINE INCLUDEDIR="include:"
|
||||
DEFINE LIBDIR="lib:"
|
||||
DEFINE NO_ALLOCA
|
||||
DEFINE NO_FLOAT
|
||||
DEFINE NO_ARCHIVES
|
||||
IGNORE=161
|
||||
IGNORE=100
|
||||
|
|
1
hash.c
1
hash.c
|
@ -276,7 +276,6 @@ hash_rehash (struct hash_table *ht)
|
|||
void
|
||||
hash_print_stats (struct hash_table *ht, FILE *out_FILE)
|
||||
{
|
||||
/* GKM FIXME: honor NO_FLOAT */
|
||||
fprintf (out_FILE, _("Load=%lu/%lu=%.0f%%, "), ht->ht_fill, ht->ht_size,
|
||||
100.0 * (double) ht->ht_fill / (double) ht->ht_size);
|
||||
fprintf (out_FILE, _("Rehash=%u, "), ht->ht_rehashes);
|
||||
|
|
14
main.c
14
main.c
|
@ -277,13 +277,8 @@ char *sync_mutex = NULL;
|
|||
Negative values mean unlimited, while zero means limit to
|
||||
zero load (which could be useful to start infinite jobs remotely
|
||||
but one at a time locally). */
|
||||
#ifndef NO_FLOAT
|
||||
double max_load_average = -1.0;
|
||||
double default_load_average = -1.0;
|
||||
#else
|
||||
int max_load_average = -1;
|
||||
int default_load_average = -1;
|
||||
#endif
|
||||
|
||||
/* List of directories given with -C switches. */
|
||||
|
||||
|
@ -453,13 +448,8 @@ static const struct command_switch switches[] =
|
|||
"include-dir" },
|
||||
{ 'j', positive_int, &arg_job_slots, 1, 1, 0, &inf_jobs, &default_job_slots,
|
||||
"jobs" },
|
||||
#ifndef NO_FLOAT
|
||||
{ 'l', floating, &max_load_average, 1, 1, 0, &default_load_average,
|
||||
&default_load_average, "load-average" },
|
||||
#else
|
||||
{ 'l', positive_int, &max_load_average, 1, 1, 0, &default_load_average,
|
||||
&default_load_average, "load-average" },
|
||||
#endif
|
||||
{ 'o', filename, &old_files, 0, 0, 0, 0, 0, "old-file" },
|
||||
{ 'O', string, &output_sync_option, 1, 1, 0, "target", 0, "output-sync" },
|
||||
{ 'W', filename, &new_files, 0, 0, 0, 0, 0, "what-if" },
|
||||
|
@ -2942,7 +2932,6 @@ decode_switches (int argc, const char **argv, int env)
|
|||
= *(unsigned int *) cs->noarg_value;
|
||||
break;
|
||||
|
||||
#ifndef NO_FLOAT
|
||||
case floating:
|
||||
if (coptarg == 0 && optind < argc
|
||||
&& (ISDIGIT (argv[optind][0]) || argv[optind][0] == '.'))
|
||||
|
@ -2954,7 +2943,6 @@ decode_switches (int argc, const char **argv, int env)
|
|||
: *(double *) cs->noarg_value);
|
||||
|
||||
break;
|
||||
#endif
|
||||
}
|
||||
|
||||
/* We've found the switch. Stop looking. */
|
||||
|
@ -3156,7 +3144,6 @@ define_makeflags (int all, int makefile)
|
|||
}
|
||||
break;
|
||||
|
||||
#ifndef NO_FLOAT
|
||||
case floating:
|
||||
if (all)
|
||||
{
|
||||
|
@ -3176,7 +3163,6 @@ define_makeflags (int all, int makefile)
|
|||
}
|
||||
}
|
||||
break;
|
||||
#endif
|
||||
|
||||
case string:
|
||||
if (all)
|
||||
|
|
|
@ -662,11 +662,7 @@ extern int batch_mode_shell;
|
|||
extern char cmd_prefix;
|
||||
|
||||
extern unsigned int job_slots;
|
||||
#ifndef NO_FLOAT
|
||||
extern double max_load_average;
|
||||
#else
|
||||
extern int max_load_average;
|
||||
#endif
|
||||
|
||||
#ifdef WINDOWS32
|
||||
extern char *program;
|
||||
|
|
6
remake.c
6
remake.c
|
@ -1408,11 +1408,6 @@ f_mtime (struct file *file, int search)
|
|||
adjusted_now = now + (resolution - 1);
|
||||
if (adjusted_now < adjusted_mtime)
|
||||
{
|
||||
#ifdef NO_FLOAT
|
||||
OS (error, NILF,
|
||||
_("Warning: File '%s' has modification time in the future"),
|
||||
file->name);
|
||||
#else
|
||||
double from_now =
|
||||
(FILE_TIMESTAMP_S (mtime) - FILE_TIMESTAMP_S (now)
|
||||
+ ((FILE_TIMESTAMP_NS (mtime) - FILE_TIMESTAMP_NS (now))
|
||||
|
@ -1426,7 +1421,6 @@ f_mtime (struct file *file, int search)
|
|||
OSS (error, NILF,
|
||||
_("Warning: File '%s' has modification time %s s in the future"),
|
||||
file->name, from_now_string);
|
||||
#endif
|
||||
clock_skew_detected = 1;
|
||||
}
|
||||
}
|
||||
|
|
12
rule.c
12
rule.c
|
@ -511,16 +511,8 @@ print_rule_data_base (void)
|
|||
puts (_("\n# No implicit rules."));
|
||||
else
|
||||
{
|
||||
printf (_("\n# %u implicit rules, %u"), rules, terminal);
|
||||
#ifndef NO_FLOAT
|
||||
printf (" (%.1f%%)", (double) terminal / (double) rules * 100.0);
|
||||
#else
|
||||
{
|
||||
int f = (terminal * 1000 + 5) / rules;
|
||||
printf (" (%d.%d%%)", f/10, f%10);
|
||||
}
|
||||
#endif
|
||||
puts (_(" terminal."));
|
||||
printf (_("\n# %u implicit rules, %u (%.1f%%) terminal."),
|
||||
rules, terminal, (double) terminal / (double) rules * 100.0);
|
||||
}
|
||||
|
||||
if (num_pattern_rules != rules)
|
||||
|
|
Loading…
Reference in a new issue