mirror of
https://github.com/reactos/reactos.git
synced 2025-08-05 01:15:43 +00:00
Add ROS_ARCH environment variable
Set -r option of rbuild as mandatory svn path=/trunk/; revision=28124
This commit is contained in:
parent
e94c193f12
commit
1a47ede2ff
6 changed files with 36 additions and 10 deletions
|
@ -49,6 +49,10 @@
|
||||||
#
|
#
|
||||||
# Accepted environment variables:
|
# Accepted environment variables:
|
||||||
#
|
#
|
||||||
|
# ROS_ARCH
|
||||||
|
# This variable specifies the name of the architecture to build ReactOS for.
|
||||||
|
# The variable defaults to i386.
|
||||||
|
#
|
||||||
# ROS_PREFIX
|
# ROS_PREFIX
|
||||||
# This variable specifies the prefix of the MinGW installation. On Windows
|
# This variable specifies the prefix of the MinGW installation. On Windows
|
||||||
# a prefix is usually not needed, but on linux it is usually "mingw32". If
|
# a prefix is usually not needed, but on linux it is usually "mingw32". If
|
||||||
|
@ -323,13 +327,19 @@ else # mingw32-windows
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
ifneq ($(ROS_ARCH),)
|
||||||
|
ARCH := $(ROS_ARCH)
|
||||||
|
else
|
||||||
|
ARCH := i386
|
||||||
|
endif
|
||||||
|
|
||||||
ifneq ($(ROS_INTERMEDIATE),)
|
ifneq ($(ROS_INTERMEDIATE),)
|
||||||
INTERMEDIATE := $(ROS_INTERMEDIATE)
|
INTERMEDIATE := $(ROS_INTERMEDIATE)
|
||||||
else
|
else
|
||||||
ifneq ($(ROS_CDOUTPUT),)
|
ifneq ($(ROS_CDOUTPUT),)
|
||||||
INTERMEDIATE := obj-$(ROS_CDOUTPUT)
|
INTERMEDIATE := obj-$(ROS_CDOUTPUT)
|
||||||
else
|
else
|
||||||
INTERMEDIATE := obj-i386
|
INTERMEDIATE := obj-$(ARCH)
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
INTERMEDIATE_ := $(INTERMEDIATE)$(SEP)
|
INTERMEDIATE_ := $(INTERMEDIATE)$(SEP)
|
||||||
|
@ -340,7 +350,7 @@ else
|
||||||
ifneq ($(ROS_CDOUTPUT),)
|
ifneq ($(ROS_CDOUTPUT),)
|
||||||
OUTPUT := output-$(ROS_CDOUTPUT)
|
OUTPUT := output-$(ROS_CDOUTPUT)
|
||||||
else
|
else
|
||||||
OUTPUT := output-i386
|
OUTPUT := output-$(ARCH)
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
OUTPUT_ := $(OUTPUT)$(SEP)
|
OUTPUT_ := $(OUTPUT)$(SEP)
|
||||||
|
@ -392,7 +402,6 @@ include lib/lib.mak
|
||||||
include tools/tools.mak
|
include tools/tools.mak
|
||||||
include boot/freeldr/bootsect/bootsect.mak
|
include boot/freeldr/bootsect/bootsect.mak
|
||||||
-include $(ROS_AUTOMAKE)
|
-include $(ROS_AUTOMAKE)
|
||||||
include tools/nci/nci.mak
|
|
||||||
|
|
||||||
PREAUTO := \
|
PREAUTO := \
|
||||||
$(BIN2C_TARGET) \
|
$(BIN2C_TARGET) \
|
||||||
|
@ -402,17 +411,17 @@ PREAUTO := \
|
||||||
$(BUGCODES_RC) \
|
$(BUGCODES_RC) \
|
||||||
$(ERRCODES_H) \
|
$(ERRCODES_H) \
|
||||||
$(ERRCODES_RC) \
|
$(ERRCODES_RC) \
|
||||||
$(GENDIB_DIB_FILES)
|
$(GENDIB_DIB_FILES) \
|
||||||
|
$(NCI_SERVICE_FILES)
|
||||||
|
|
||||||
POSTAUTO : \
|
POSTAUTO : \
|
||||||
psdk \
|
psdk \
|
||||||
$(IDL_FILES) \
|
$(IDL_FILES)
|
||||||
$(NCI_SERVICE_FILES)
|
|
||||||
|
|
||||||
$(ROS_AUTOMAKE): $(RBUILD_TARGET) $(PREAUTO) $(XMLBUILDFILES)
|
$(ROS_AUTOMAKE): $(RBUILD_TARGET) $(PREAUTO) $(XMLBUILDFILES)
|
||||||
${mkdir} $(INTERMEDIATE_)media$(SEP)inf 2>$(NUL)
|
${mkdir} $(INTERMEDIATE_)media$(SEP)inf 2>$(NUL)
|
||||||
$(ECHO_RBUILD)
|
$(ECHO_RBUILD)
|
||||||
$(Q)$(RBUILD_TARGET) $(ROS_RBUILDFLAGS) mingw
|
$(Q)$(RBUILD_TARGET) $(ROS_RBUILDFLAGS) -rReactOS-$(ARCH).rbuild mingw
|
||||||
@$(MAKE) POSTAUTO
|
@$(MAKE) POSTAUTO
|
||||||
|
|
||||||
world: all bootcd livecd
|
world: all bootcd livecd
|
||||||
|
|
|
@ -51,6 +51,13 @@ void Exception::SetMessageV ( const char* message, va_list args )
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
MissingArgumentException::MissingArgumentException ( const string& argument )
|
||||||
|
: Exception ( "Argument '%s' is missing",
|
||||||
|
argument.c_str () )
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
OutOfMemoryException::OutOfMemoryException ()
|
OutOfMemoryException::OutOfMemoryException ()
|
||||||
: Exception ( "Out of memory" )
|
: Exception ( "Out of memory" )
|
||||||
{
|
{
|
||||||
|
|
|
@ -39,6 +39,13 @@ private:
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
class MissingArgumentException : public Exception
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
MissingArgumentException ( const std::string& argument );
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
class InvalidOperationException : public Exception
|
class InvalidOperationException : public Exception
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
|
|
@ -33,7 +33,7 @@ using std::string;
|
||||||
using std::vector;
|
using std::vector;
|
||||||
|
|
||||||
static string BuildSystem;
|
static string BuildSystem;
|
||||||
static string RootXmlFile = "ReactOS.rbuild";
|
static string RootXmlFile;
|
||||||
static Configuration configuration;
|
static Configuration configuration;
|
||||||
|
|
||||||
bool
|
bool
|
||||||
|
@ -239,12 +239,11 @@ main ( int argc, char** argv )
|
||||||
if ( !ParseArguments ( argc, argv ) )
|
if ( !ParseArguments ( argc, argv ) )
|
||||||
{
|
{
|
||||||
printf ( "Generates project files for buildsystems\n\n" );
|
printf ( "Generates project files for buildsystems\n\n" );
|
||||||
printf ( " rbuild [switches] buildsystem\n\n" );
|
printf ( " rbuild [switches] -r{rootfile.rbuild} buildsystem\n\n" );
|
||||||
printf ( "Switches:\n" );
|
printf ( "Switches:\n" );
|
||||||
printf ( " -v Be verbose.\n" );
|
printf ( " -v Be verbose.\n" );
|
||||||
printf ( " -c Clean as you go. Delete generated files as soon as they are not\n" );
|
printf ( " -c Clean as you go. Delete generated files as soon as they are not\n" );
|
||||||
printf ( " needed anymore.\n" );
|
printf ( " needed anymore.\n" );
|
||||||
printf ( " -r{file.rbuild} Name of the root rbuild file. Default is ReactOS.rbuild.\n" );
|
|
||||||
printf ( " -dd Disable automatic dependencies.\n" );
|
printf ( " -dd Disable automatic dependencies.\n" );
|
||||||
printf ( " -dm{module} Check only automatic dependencies for this module.\n" );
|
printf ( " -dm{module} Check only automatic dependencies for this module.\n" );
|
||||||
printf ( " -ud Disable multiple source files per compilation unit.\n" );
|
printf ( " -ud Disable multiple source files per compilation unit.\n" );
|
||||||
|
@ -267,6 +266,9 @@ main ( int argc, char** argv )
|
||||||
}
|
}
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
if ( RootXmlFile.length () == 0 )
|
||||||
|
throw MissingArgumentException ( "-r" );
|
||||||
|
|
||||||
string projectFilename ( RootXmlFile );
|
string projectFilename ( RootXmlFile );
|
||||||
|
|
||||||
printf ( "Reading build files..." );
|
printf ( "Reading build files..." );
|
||||||
|
|
|
@ -48,6 +48,7 @@ include tools/cdmake/cdmake.mak
|
||||||
include tools/dbgprint/dbgprint.mak
|
include tools/dbgprint/dbgprint.mak
|
||||||
include tools/gendib/gendib.mak
|
include tools/gendib/gendib.mak
|
||||||
include tools/mkhive/mkhive.mak
|
include tools/mkhive/mkhive.mak
|
||||||
|
include tools/nci/nci.mak
|
||||||
include tools/pefixup.mak
|
include tools/pefixup.mak
|
||||||
include tools/raddr2line.mak
|
include tools/raddr2line.mak
|
||||||
include tools/rbuild/rbuild.mak
|
include tools/rbuild/rbuild.mak
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue