Hello trying to compile format.exe am getting error about duplicate symbols
please help
Compiling USERINT.C:
Compiling UFORMAT.C:
Compiling SAVEFS.C:
Warning SAVEFS.C 139: Code has no effect in function Save_File_System
Warning SAVEFS.C 675: Condition is always false in function
Restore_File_System
Compiling RECORDBC.C:
Compiling PRF.C:
Warning PRF.C 164: Conversion may lose significant digits in function
sprintf
Compiling MAIN.C:
Compiling INIT.C:
Compiling HDISK.C:
Warning HDISK.C 280: Conversion may lose significant digits in function
Set_Hard_Drive_Media_Parameters
Compiling GETOPT.C:
Compiling FLOPPY.C:
Warning FLOPPY.C 496: Condition is always true in function
Set_Floppy_Media_Type
Warning FLOPPY.C 538: Condition is always true in function
Set_Floppy_Media_Type
Compiling DRIVEIO.C:
Compiling CREATEFS.C:
Warning CREATEFS.C 669: Condition is always true in function
Write_FAT_Tables
Warning CREATEFS.C 693: Condition is always true in function
Write_FAT_Tables
Compiling BCREAD.C:
Warning BCREAD.C 99: Condition is always true in function BadClustPreserve32
Warning BCREAD.C 139: Condition is always true in function
BadClustPreserve32
Linking format.exe:
Linker Error: _ASCII_CD_Number defined in module USERINT.C is duplicated in
module USERINT.C
Linker Error: _Ask_User_To_Insert_Disk defined in module USERINT.C is
duplicated in module USERINT.C
Linker Error: _isLabelChar defined in module USERINT.C is duplicated in
module USERINT.C
Linker Error: _Ask_Label defined in module USERINT.C is duplicated in module
USERINT.C
Linker Error: _Confirm_Hard_Drive_Formatting defined in module USERINT.C is
duplicated in module USERINT.C
Linker Error: _Critical_Error_Handler defined in module USERINT.C is
duplicated in module USERINT.C
Linker Error: _Display_Drive_Statistics defined in module USERINT.C is
duplicated in module USERINT.C
Linker Error: _Display_Invalid_Combination defined in module USERINT.C is
duplicated in module USERINT.C
Linker Error: _Display_Help_Screen defined in module USERINT.C is duplicated
in module USERINT.C
Linker Error: _Display_Percentage_Formatted defined in module USERINT.C is
duplicated in module USERINT.C
Linker Error: _IllegalArg defined in module USERINT.C is duplicated in
module USERINT.C
Linker Error: _Key_For_Next_Page defined in module USERINT.C is duplicated
in module USERINT.C

-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of Eric Auer
Sent: 18 April 2007 14:00
To: [email protected]
Subject: Re: [Freedos-devel] format.exe


Hi, I looked into your problem description now...

The "condition is always true" cases are intentionally,
but maybe I should remove the "if (TRUE)" to make that
clear... Actually I had assumed that you only get a
warning when you have "if (some always true expression)"
and not when you use the "obviously true" case "TRUE".

Cases are: bcread.c 99/139: progress indicator display.
createfs.c 664/688: progress indicator display. Those
were "only in debug mode" in old versions of FORMAT.

Your floppy.c does not seem to be current FORMAT 0.91v,
as line numbers differ. You probably mean lines 502/544:
First is "always update params.cyl/sec/sides", not only
if the /f: option is used, and second is an "if (TRUE) {x}"
block which limits the variable scope of variables used in
x to the block x. Maybe you can recommend a better syntax?

The "significant digits lost" warning in prf.c 164 is
int = char* - char* - 1 which can indeed underflow the
returned "count of chars" when you print more than 32k
characters with a single printf... Safe in FORMAT imho.

The code at savefs.c 139 looks okay: I test whether the
number of reserved sectors is below 1 or above 64, why not?

At savefs.c 675, you actually found a buglet: The number of
FATs is unsigned byte, so "if <0 or >2" makes no sense, it
is never below 0. However, it is OR, so it is not always
false. Maybe your savefs.c is an old version?

There is no fdformat.c, probably you mean main.c... If you
get a warning "sysarg0 and syspath never used", then you
probably commented out the code which calls SYS ;-).

The errors about country, mycountry, co_thsep and co_desep
are because your C library implements DOS country support
different than the one used in FORMAT. However, the source
code of FORMAT contains at least 2 versions afair, just
uncomment the one which works for you :-).

Finally, you got some linker errors about duplicate symbols.
This is probably because of a bug in your Makefile ...?

By the way, why are you recompiling FORMAT? If you made
useful changes, I would like to add them to our normal
FORMAT as well. You could send the "diff -ur olddir/ newdir/"
output to describe the differences between your version and
the normal one, but please zip it and send it off-list.

Happy formatting ;-). Eric


-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Freedos-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/freedos-devel


------------------------------------------------------------------------------
Enter the BlackBerry Developer Challenge  
This is your chance to win up to $100,000 in prizes! For a limited time, 
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize  
details at: http://p.sf.net/sfu/Challenge
_______________________________________________
Freedos-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/freedos-devel

Reply via email to