summaryrefslogtreecommitdiffstats
path: root/make
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>1998-04-27 18:42:04 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>1998-04-27 18:42:04 +0000
commit96d56b36902a1043c5834776411261c26872f4b8 (patch)
treeeda21ba0f0d9dc283c0d152b1eacc21150615d28 /make
parentAdded I386_HAS_BSWAP cpu model feature flag so swap u32 could take (diff)
downloadrtems-96d56b36902a1043c5834776411261c26872f4b8.tar.bz2
Update from Pedro Romano <pmcnr@camoes.rnl.ist.utl.pt>.
Diffstat (limited to 'make')
-rw-r--r--make/custom/pc386.cfg48
1 files changed, 31 insertions, 17 deletions
diff --git a/make/custom/pc386.cfg b/make/custom/pc386.cfg
index a9f139fa68..e642a8baf9 100644
--- a/make/custom/pc386.cfg
+++ b/make/custom/pc386.cfg
@@ -42,7 +42,7 @@ HAS_KA9Q=no
define make-target-options
@echo "/* #define NDEBUG 1 */ " >>$@
- @echo "#define RTEMS_TEST_NO_PAUSE 1" >>$@
+ @echo "/* #define RTEMS_TEST_NO_PAUSE 1 */" >>$@
@echo "/* #define RTEMS_DEBUG 1 */" >>$@
endef
@@ -51,13 +51,19 @@ endef
# Usage ref: src/tests/sptest/sp1/Makefile
#+--------------------------------------------------------------------------+
-#| Relocation address. Set this to the linear address where you want your code
-#| to start. It should abide to the following constraints:
-#| RELOCADDR >= 0x10200
-#| RELOCADDR + 'image file size' < 0xA0000
-#| RELOCADDR % 4 = 0 (i.e. aligned on a 4 byte boundary)
+#| Set the value of RELOCADDR to the address where you want your image to
+#| load. If you'll be using GRUB to load the images it will have to be >=
+#| 0x100000 (1024K). If you are using NetBoot to load the images it can be
+#| >= 0x10000 (64K) AND <= 0x97C00 (607K) OR >= 0x100000 (1024K). The memory
+#| top is of course another limit. Make sure there is enough space before the
+#| upper memory limits for the image and the memory allocated by it to fit.
+#| Make sure the value you choose is aligned to 4 bytes.
#+--------------------------------------------------------------------------+
-RELOCADDR=0x00020200
+ RELOCADDR=0x00100000
+
+START16FILE=$(PROJECT_RELEASE)/lib/start16.bin
+START16ADDR=0x00097C00
+ HEADERADDR=0x00097E00
# The following are definitions of make-exe which will work using ld as
# is currently required. It is expected that as of gcc 2.8, the end user
@@ -66,20 +72,28 @@ RELOCADDR=0x00020200
ifeq ($(RTEMS_USE_GCC272),yes)
define make-exe
$(LD) -N -T $(LINKCMDS) -Ttext $(RELOCADDR) -e start -nostdlib \
- -o $(basename $@).elf \
+ -o $(basename $@).obj \
$(START_FILE) $(LINK_OBJS) --start-group $(LINK_LIBS) --end-group
- $(OBJCOPY) -O binary --set-start $(RELOCADDR) $(basename $@).elf $@
- $(PROJECT_TOOLS)/bin2boot -v $@ $(basename $@).bin -s $(RELOCADDR)
- $(NM) -g -n $(basename $@).elf > $(basename $@).num
- $(SIZE) $(basename $@).elf
+ $(OBJCOPY) -O a.out-i386 --remove-section=.rodata --strip-unneeded \
+ $(basename $@).obj $@
+ $(OBJCOPY) -O binary $(basename $@).obj $(basename $@).bin
+ $(PROJECT_TOOLS)/bin2boot -v $(basename $@).bin $(HEADERADDR)\
+ $(START16FILE) $(START16ADDR) 0 $(basename $@).bin $(RELOCADDR) 0
+ $(NM) -g -n $(basename $@).obj > $(basename $@).num
+ $(SIZE) $(basename $@).obj
+ $(INSTALL_VARIANT) -m 555 $(basename $@).bt ${PROJECT_RELEASE}/BootImgs
endef
else
define make-exe
- $(CC) $(CFLAGS) $(CFLAGS_LD) -o $(basename $@).elf $(LINK_OBJS)
- $(OBJCOPY) -O binary --set-start $(RELOCADDR) $(basename $@).elf $@
- $(PROJECT_TOOLS)/bin2boot -v $@ $(basename $@).bin -s $(RELOCADDR)
- $(NM) -g -n $(basename $@).elf > $(basename $@).num
- $(SIZE) $(basename $@).elf
+ $(CC) $(CFLAGS) $(CFLAGS_LD) -Ttext $(RELOCADDR) -o $(basename $@).obj $(LINK_OBJS)
+ $(OBJCOPY) -O a.out-i386 --remove-section=.rodata --strip-unneeded \
+ $(basename $@).obj $@
+ $(OBJCOPY) -O binary $(basename $@).obj $(basename $@).bin
+ $(PROJECT_TOOLS)/bin2boot -v $(basename $@).bt $(HEADERADDR)\
+ $(START16FILE) $(START16ADDR) 0 $(basename $@).bin $(RELOCADDR) 0
+ $(NM) -g -n $(basename $@).obj > $(basename $@).num
+ $(SIZE) $(basename $@).obj
+ $(INSTALL_VARIANT) -m 555 $(basename $@).bt ${PROJECT_RELEASE}/BootImgs
endef
endif