mirror of
https://github.com/ldc-developers/ldc.git
synced 2025-05-08 03:46:02 +03:00
issue #1161: return status if lib invocation
This commit is contained in:
parent
f7cfa4fb95
commit
8b5cee7a7c
3 changed files with 7 additions and 5 deletions
|
@ -431,7 +431,7 @@ int linkObjToBinary(bool sharedLib)
|
|||
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
void createStaticLibrary()
|
||||
int createStaticLibrary()
|
||||
{
|
||||
Logger::println("*** Creating static library ***");
|
||||
|
||||
|
@ -501,7 +501,8 @@ void createStaticLibrary()
|
|||
CreateDirectoryOnDisk(libName);
|
||||
|
||||
// try to call archiver
|
||||
executeToolAndWait(tool, args, global.params.verbose);
|
||||
int rc = executeToolAndWait(tool, args, global.params.verbose);
|
||||
return rc;
|
||||
}
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////
|
||||
|
|
|
@ -23,8 +23,9 @@ int linkObjToBinary(bool sharedLib);
|
|||
|
||||
/**
|
||||
* Create a static library from object files.
|
||||
* @return 0 on success.
|
||||
*/
|
||||
void createStaticLibrary();
|
||||
int createStaticLibrary();
|
||||
|
||||
/**
|
||||
* Delete the executable that was previously linked with linkObjToBinary.
|
||||
|
|
|
@ -1347,7 +1347,7 @@ int main(int argc, char **argv)
|
|||
if (global.params.link)
|
||||
status = linkObjToBinary(createSharedLib);
|
||||
else if (createStaticLib)
|
||||
createStaticLibrary();
|
||||
status = createStaticLibrary();
|
||||
|
||||
if (global.params.run && status == EXIT_SUCCESS)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue