rc now also builds under R5 with TARGET_PLATFORM haiku.
Since we currently use the same build for the host and for the target, this is only a temporary fix - we should build it twice. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12783 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
8b47fd8708
commit
db4227c6ac
|
@ -9,5 +9,13 @@ StaticLibrary rdef :
|
||||||
|
|
||||||
BinCommand rc :
|
BinCommand rc :
|
||||||
rc.cpp
|
rc.cpp
|
||||||
|
|
||||||
|
# these two are needed for R5 only
|
||||||
|
strlcpy.c
|
||||||
|
strlcat.c
|
||||||
: librdef.a libstdc++.r4.so libbe.so
|
: librdef.a libstdc++.r4.so libbe.so
|
||||||
;
|
;
|
||||||
|
|
||||||
|
SEARCH on [ FGristFiles
|
||||||
|
strlcat.c strlcpy.c
|
||||||
|
] = [ FDirName $(OBOS_TOP) src system libroot posix string ] ;
|
||||||
|
|
|
@ -153,12 +153,7 @@ cut_extension(char *name, const char *ext)
|
||||||
static void
|
static void
|
||||||
add_extension(char *name, const char *ext)
|
add_extension(char *name, const char *ext)
|
||||||
{
|
{
|
||||||
#ifdef __HAIKU__
|
|
||||||
strlcat(name, ext, B_PATH_NAME_LENGTH);
|
strlcat(name, ext, B_PATH_NAME_LENGTH);
|
||||||
#else
|
|
||||||
strncat(name, ext, B_PATH_NAME_LENGTH);
|
|
||||||
name[B_PATH_NAME_LENGTH - 1] = '\0';
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -235,12 +230,7 @@ parse_options(int argc, char *argv[])
|
||||||
if (sOutputFile[0] == '\0') {
|
if (sOutputFile[0] == '\0') {
|
||||||
// no output file name was given, use the name of the
|
// no output file name was given, use the name of the
|
||||||
// first source file as base
|
// first source file as base
|
||||||
#ifdef __HAIKU__
|
|
||||||
strlcpy(sOutputFile, sFirstInputFile, sizeof(sOutputFile));
|
strlcpy(sOutputFile, sFirstInputFile, sizeof(sOutputFile));
|
||||||
#else
|
|
||||||
strncpy(sOutputFile, sFirstInputFile, sizeof(sOutputFile) - 1);
|
|
||||||
sOutputFile[sizeof(sOutputFile) - 1] = '\0';
|
|
||||||
#endif
|
|
||||||
|
|
||||||
cut_extension(sOutputFile, sDecompile ? ".rsrc" : ".rdef");
|
cut_extension(sOutputFile, sDecompile ? ".rsrc" : ".rdef");
|
||||||
add_extension(sOutputFile, sDecompile ? ".rdef" : ".rsrc");
|
add_extension(sOutputFile, sDecompile ? ".rdef" : ".rsrc");
|
||||||
|
|
Loading…
Reference in New Issue