I was trying to compile a project that compiled cleanly last time I tried (with SDCC 3.2.0), meanwhile I've upgraded to 3.4.0:
~/sdcc-3.4.0/bin/sdcc -v SDCC : mcs51/z80/z180/r2k/r3ka/gbz80/tlcs90/ds390/pic16/pic14/TININative/ds400/hc0 8/s08/stm8 3.4.0 #8981 (Apr 5 2014) (Mac OS X i386) published under GNU General Public License (GPL) my code contains: __code char __at 0x300000 CONFIG1L = 0x20; // USBDIV=1, CPUDIV=00, PLLDIV = 000 __code char __at 0x300001 CONFIG1H = 0x0E; // IESO=0, FCMEN=0, FOSC = 1110 __code char __at 0x300002 CONFIG2L = 0x20; // Brown out off, PWRT On __code char __at 0x300003 CONFIG2H = 0x00; // WDT off __code char __at 0x300004 CONFIG3L = 0xff; // Unused configuration bits __code char __at 0x300005 CONFIG3H = 0x80; // MCLR enabled , PORTB digital, CCP2 - RB2 __code char __at 0x300006 CONFIG4L = 0x80; // ICD off, ext off, LVP off, stk ovr off __code char __at 0x300007 CONFIG4H = 0xff; // Unused configuration bits and the linking fails with: "(0x300000) is absolute but occurs in more than one file" now, if comment out all but one of these the compile succeeds, so my conclusion is that I don't have these defined in multiple files or above file included multiple times. A single: __code char __at 0x300000 CONFIG1L = 0x20; // USBDIV=1, CPUDIV=00, PLLDIV = 000 in any file in the project seems to be fine but two lines: __code char __at 0x300000 CONFIG1L = 0x20; // USBDIV=1, CPUDIV=00, PLLDIV = 000 __code char __at 0x300001 CONFIG1H = 0x0E; // IESO=0, FCMEN=0, FOSC = 1110 anywhere will fail. I know, I should upgrade myc code to use the CONFIG as I get the warning: "Warning[212] __CONFIG has been deprecated for PIC18 devices. Use directive CONFIG." but right now I would not like to go through the datasheet and figure out names for all those bits, especially as not all of them are what I consider logical, that is error prone, time consuming and tedious. So is there any way I can use what I have without Doing The Right Thing(tm) ?? Also, isn't the warning and apparent backwards compatibility a bit futile if it does not work, eh? cheers Kusti This e-mail may contain confidential or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and destroy this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden. We will not be liable for direct, indirect, special or consequential damages arising from alteration of the contents of this message by a third party or as a result of any virus being passed on or as of transmission of this e-mail in general. ------------------------------------------------------------------------------ Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/ _______________________________________________ Sdcc-user mailing list Sdcc-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sdcc-user