From: Jesus Calvino-F. <Je...@ec...> - 2002-08-11 20:42:30
|
Hi all, Also the location of the include and lib directories should be consistent across all versions and maybe platforms. For example the VC version uses \sdcc\include and \sdcc\lib. An older cygwin version (2.3.1) uses \sdcc\share\sdcc\include, and the newest cygwin snapshot (2.3.2) uses \sdcc\sdcc\include. Another thing. It doesn't seen necessary to install cygwin in order to compile with VC. Just flex, bison, and gawk will do. I got bison and flex for Visual Studio from http://borg.rave.org/cgi-bin/borgcvs/history/tools/ http://borg.rave.org/cgi-bin/borgcvs/history/tools/bfwizard-1.6.zip I don't remember where I got gawk from, but it is in this directory of my hard drive: Directory of C:\Program Files\Microsoft Visual Studio\VC98\Bin GAWK EXE 153,600 11-11-99 12:00a gawk.exe Regards, At 08:05 PM 8/11/02 +0200, Borut Razem wrote: >Hello SDCC developers, > >if you look to the file sdcc_vc.h, you will see that it is out-of-date >(and also out of sync ;-). >The version info looks like: > >#define SDCC_VERSION_HI 2 >#define SDCC_VERSION_LO 2 >#define SDCC_VERSION_P 1 >#define SDCC_VERSION_STR "2.2.2" > >The problem is, that the version number is stored in file .version. The >configure script, which creates sdccconf.h file, generates version #define >lines from file .version. This doesn't work for sdcc_vc.h, so it should be >updated manually. Obviously this was not done for some time, and it also >wasn't done correctly: SDCC_VERSION_P should be set to 2. > >To avoid such mistakes and to change the version number only in one location >(.version), I suggest that sdcc_vc.h includes sdccconf.h, and undefines >and/or >redefines all macros which differ. All untouched macro definitions >(including >SDCC_VERSION_XXX :-) will be inherited from sdccconf.h. > >The problem with this approach could be, that sdccconf.h should be generated >with configure. I don't see this as an big obstacle, because Visual Studio >build >already uses gawk, bison and flex tools, which are part of cygwin. Probably >all developers, which compile SDCC on Visual Studio, have cygwin already >installed >on their machines (or I'm mistaken?). > >sdcc_vc.h would look like this: > >/* > * This file contains diffs to sdccconf.h > */ > >#ifndef SDCC_VC_HEADER >#define SDCC_VC_HEADER > >#include "sdccconf.h" > >/* MSVC 6 does not have __FUNCTION__ preprocessor macro defined */ > >#if defined(_MSC_VER) && (_MSC_VER < 1300) >#define __FUNCTION__ __FILE__ >#endif > >#undef PREFIX >#undef DATADIR >#undef SRCDIR > >#undef STANDARD_INCLUDE_DIR >#undef SDCC_INCLUDE_DIR >#undef SDCC_LIB_DIR > >#define PREFIX "\\sdcc" > >#define SDCC_INCLUDE_DIR "\\sdcc\\include" >#define SDCC_LIB_DIR "\\sdcc\\lib" > >#undef HAVE_STRERROR > >#undef OPT_DISABLE_MCS51 >#undef OPT_DISABLE_GBZ80 >#undef OPT_DISABLE_Z80 >#undef OPT_DISABLE_AVR >#undef OPT_DISABLE_TININative >#undef OPT_DISABLE_PIC >#undef OPT_DISABLE_XA51 > >#endif > >/* End of sdcc_vc.h */ > > >Please comment this proposal. >If have any suggestion or objection, please let me know. > >Best Regards, >Borut > >-- >Borut Razem > > > >------------------------------------------------------- >This sf.net email is sponsored by:ThinkGeek >Welcome to geek heaven. >http://thinkgeek.com/sf >_______________________________________________ >sdcc-devel mailing list >sdc...@li... >https://lists.sourceforge.net/lists/listinfo/sdcc-devel |