summaryrefslogtreecommitdiffstats
path: root/Source/cmNinjaNormalTargetGenerator.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmNinjaNormalTargetGenerator.cxx')
-rw-r--r--Source/cmNinjaNormalTargetGenerator.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/Source/cmNinjaNormalTargetGenerator.cxx b/Source/cmNinjaNormalTargetGenerator.cxx
index be7739e..5c9bf78 100644
--- a/Source/cmNinjaNormalTargetGenerator.cxx
+++ b/Source/cmNinjaNormalTargetGenerator.cxx
@@ -495,7 +495,8 @@ void cmNinjaNormalTargetGenerator::WriteLinkStatement()
int commandLineLengthLimit = 8000 - linkRuleLength;
#elif defined(__linux) || defined(__APPLE__)
// for instance ARG_MAX is 2096152 on Ubuntu or 262144 on Mac
- int commandLineLengthLimit = sysconf(_SC_ARG_MAX) - linkRuleLength - 1000;
+ int commandLineLengthLimit = ((int)sysconf(_SC_ARG_MAX))
+ - linkRuleLength - 1000;
#else
int commandLineLengthLimit = -1;
#endif