Build FREELDR.SYS and SETUPLDR.SYS in a single make run.

Fixed build process for SETUPLDR.SYS.

svn path=/trunk/; revision=3445
This commit is contained in:
Eric Kohl 2002-08-31 18:09:31 +00:00
parent bd3e14d1f7
commit fd7d5a399f
8 changed files with 56 additions and 45 deletions

View file

@ -1,3 +1,13 @@
Changes in v1.7.6 (8/31/2002) (ekohl)
- bootsect/isoboot.asm: Reduced read transfer size to ensure that
the read buffer for an int13/ah=42h (exended read) does not
cross a segment boundary.
- freeldr.c, bootmgr.c, setupldr.c, makefile: Renamed
LoadBootManager() and ReactOSRunSetupLoader() to RunLoader().
Either bootmgr.o or setupldr.o is used to build freeldr.sys or
setupldr.sys
Changes in v1.7.5 (8/21/2002) (brianp)
- biosvid.S (BiosVideoDisableBlinkBit): Added code to

View file

@ -124,13 +124,7 @@ else
COMPILER_DEBUG_DEFINES =
endif
ifeq ($(MAKECMDGOALS),setupldr)
COMPILER_SETUPLDR_DEFINES = -D__SETUPLDR__
else
COMPILER_SETUPLDR_DEFINES =
endif
COMPILER_DEFINES = -D__$(TARGET)__ $(COMPILER_DEBUG_DEFINES) $(COMPILER_SETUPLDR_DEFINES)
COMPILER_DEFINES = -D__$(TARGET)__ $(COMPILER_DEBUG_DEFINES)
#############################################
# INCLUDE DIRECTORY OPTIONS
@ -206,8 +200,7 @@ REACTOS_OBJS= reactos.o \
arcname.o \
hwdetect.o \
reghive.o \
registry.o \
setupldr.o
registry.o
COMM_OBJS = rs232.o \
portio.o
@ -234,21 +227,21 @@ VIDEO_OBJS = video.o \
# This code was taken from the GCC v3.1 source
MATH_OBJS = libgcc2.o
FREELDR_OBJS= freeldr.o \
miscboot.o \
options.o \
linuxboot.o \
BASE_OBJS = freeldr.o \
debug.o \
drivemap.o \
multiboot.o \
debug.o \
oslist.o \
bootmgr.o \
drivemap.o \
version.o
#############################################
# ALL THE OBJECTS
#
OBJS = $(ARCH_OBJS) \
FREELDR_OBJS= bootmgr.o \
miscboot.o \
options.o \
linuxboot.o \
oslist.o
SETUPLDR_OBJS= setupldr.o
COMMON_OBJS = $(ARCH_OBJS) \
$(RTL_OBJS) \
$(FS_OBJS) \
$(UI_OBJS) \
@ -260,8 +253,22 @@ OBJS = $(ARCH_OBJS) \
$(INIFILE_OBJS) \
$(VIDEO_OBJS) \
$(MATH_OBJS) \
$(BASE_OBJS)
F_OBJS = $(COMMON_OBJS) \
$(FREELDR_OBJS)
S_OBJS = $(COMMON_OBJS) \
$(SETUPLDR_OBJS)
#############################################
# ALL THE OBJECTS
#
ALL_OBJS = $(COMMON_OBJS) \
$(FREELDR_OBJS) \
$(SETUPLDR_OBJS)
#############################################
# SET THE VPATH SO MAKE CAN FIND THE SOURCE FILES
#
@ -282,30 +289,25 @@ VPATH = $(SRCDIR)/ \
#############################################
all : freeldr.sys
all : freeldr.sys setupldr.sys
@echo Make ALL done.
#############################################
freeldr.sys : $(OBJS)
freeldr.sys : $(ALL_OBJS)
@echo ===================================================== LINKING $@
# @$(LD) -N -Ttext=0x8000 --oformat=binary -s -o freeldr.sys $(OBJS)
@$(LD) $(LFLAGS) -Map freeldr.map -o freeldr.exe $(OBJS)
# @$(CC) -Wl,-Ttext=0x8000,-N,-Map,freeldr.map -o freeldr.exe $(OBJS)
# @$(LD) -N -Ttext=0x8000 --oformat=binary -s -o freeldr.sys $(F_OBJS)
@$(LD) $(LFLAGS) -Map freeldr.map -o freeldr.exe $(F_OBJS)
# @$(CC) -Wl,-Ttext=0x8000,-N,-Map,freeldr.map -o freeldr.exe $(F_OBJS)
@$(NM) --numeric-sort freeldr.exe > freeldr.sym
@$(OBJCOPY) -O binary freeldr.exe freeldr.sys
#############################################
setupldr : setupldr.sys
@echo Make SETUPLDR done.
#############################################
setupldr.sys : $(OBJS)
setupldr.sys : $(ALL_OBJS)
@echo ===================================================== LINKING $@
# @$(LD) -N -Ttext=0x8000 --oformat=binary -s -o setupldr.sys $(OBJS)
@$(LD) $(LFLAGS) -Map setupldr.map -o setupldr.exe $(OBJS)
# @$(LD) -N -Ttext=0x8000 --oformat=binary -s -o setupldr.sys $(S_OBJS)
@$(LD) $(LFLAGS) -Map setupldr.map -o setupldr.exe $(S_OBJS)
@$(NM) --numeric-sort setupldr.exe > setupldr.sym
@$(OBJCOPY) -O binary setupldr.exe setupldr.sys
@ -328,7 +330,7 @@ setupldr.sys : $(OBJS)
#############################################
# Include the automagically generated dependencies
-include $(OBJS:%.o=%.d)
-include $(ALL_OBJS:%.o=%.d)
#############################################

View file

@ -33,7 +33,7 @@
#include <bootmgr.h>
#include <drivemap.h>
VOID RunBootManager(VOID)
VOID RunLoader(VOID)
{
UCHAR SettingName[80];
UCHAR SettingValue[80];

View file

@ -47,9 +47,5 @@ VOID BootMain(VOID)
return;
}
#ifdef __SETUPLDR__
ReactOSRunSetupLoader();
#else
RunBootManager();
#endif // defined __SETUPLDR__
RunLoader();
}

View file

@ -21,7 +21,6 @@
#define __BOOTMGR_H
VOID RunBootManager(VOID);
U32 GetDefaultOperatingSystem(PUCHAR OperatingSystemList[], U32 OperatingSystemCount);
S32 GetTimeOut(VOID);

View file

@ -70,5 +70,6 @@ extern U32 BootPartition; // Boot Partition, 1-4
extern BOOL UserInterfaceUp; // Tells us if the user interface is displayed
void BootMain(void);
VOID RunLoader(VOID);
#endif // defined __FREELDR_H

View file

@ -22,7 +22,7 @@
/* just some stuff */
#define VERSION "FreeLoader v1.7.5"
#define VERSION "FreeLoader v1.7.6"
#define COPYRIGHT "Copyright (C) 1998-2002 Brian Palmer <brianp@sginet.com>"
#define AUTHOR_EMAIL "<brianp@sginet.com>"
#define BY_AUTHOR "by Brian Palmer"
@ -36,7 +36,7 @@
//
#define FREELOADER_MAJOR_VERSION 1
#define FREELOADER_MINOR_VERSION 7
#define FREELOADER_PATCH_VERSION 5
#define FREELOADER_PATCH_VERSION 6
PUCHAR GetFreeLoaderVersionString(VOID);

View file

@ -32,6 +32,9 @@
#include "registry.h"
#include "hwdetect.h"
VOID ReactOSRunSetupLoader(VOID)
VOID RunLoader(VOID)
{
printf("RunLoader() called!\n");
printf("*** System stopped ***\n");
for(;;);
}