diff --git a/BeefLibs/MiniZ/src/Zip.bf b/BeefLibs/MiniZ/src/Zip.bf index 49f35c91..c3c91929 100644 --- a/BeefLibs/MiniZ/src/Zip.bf +++ b/BeefLibs/MiniZ/src/Zip.bf @@ -1695,7 +1695,7 @@ namespace IDE.Util static void tdefl_start_dynamic_block(tdefl_compressor* d) { - uint32 num_lit_codes, num_dist_codes, num_bit_lengths; uint32 i, total_code_sizes_to_pack, num_packed_code_sizes, rle_z_count, rle_repeat_count, packed_code_sizes_index; + int32 num_lit_codes, num_dist_codes, num_bit_lengths; int32 i, total_code_sizes_to_pack, num_packed_code_sizes, rle_z_count, rle_repeat_count, packed_code_sizes_index; uint8[TDEFL_MAX_HUFF_SYMBOLS_0 + TDEFL_MAX_HUFF_SYMBOLS_1] code_sizes_to_pack = ?; uint8[TDEFL_MAX_HUFF_SYMBOLS_0 + TDEFL_MAX_HUFF_SYMBOLS_1] packed_code_sizes = ?; uint8 prev_code_size = 0xFF; @@ -3068,7 +3068,7 @@ namespace IDE.Util ZIP_ARRAY_ELEMENT!(&pZip.m_pState.m_sorted_central_dir_offsets, i) = (uint32)i; comp_size = (int32)ReadLE32!(p + ZIP_CDH_COMPRESSED_SIZE_OFS); decomp_size = (int32)ReadLE32!(p + ZIP_CDH_DECOMPRESSED_SIZE_OFS); - if (((ReadLE32!(p + ZIP_CDH_METHOD_OFS) == 0) && (decomp_size != comp_size)) || ((decomp_size != 0) && (comp_size == 0)) || (decomp_size == 0xFFFFFFFF) || (comp_size == 0xFFFFFFFF)) + if (((ReadLE32!(p + ZIP_CDH_METHOD_OFS) == 0) && (decomp_size != comp_size)) || ((decomp_size != 0) && (comp_size == 0)) || (decomp_size == -1) || (comp_size == -1)) return false; disk_index = ReadLE16!(p + ZIP_CDH_DISK_START_OFS); if ((disk_index != num_this_disk) && (disk_index != 1)) diff --git a/BeefLibs/corlib/src/Reflection/Convert.bf b/BeefLibs/corlib/src/Reflection/Convert.bf index b9a238c3..457f5626 100644 --- a/BeefLibs/corlib/src/Reflection/Convert.bf +++ b/BeefLibs/corlib/src/Reflection/Convert.bf @@ -39,14 +39,14 @@ namespace System.Reflection case .Int8: return (val >= -0x80) && (val <= 0x7F); case .Int16: return (val >= -0x8000) && (val <= 0x7FFF); case .Int32: return (val >= -0x80000000) && (val <= 0x7FFF'FFFF); - case .Int64: return (val >= -0x80000000'00000000) && (val <= 0x7FFFFFFF'FFFFFFFF); + case .Int64: return true; case .UInt8, .Char8: return (val >= 0) && (val <= 0xFF); case .UInt16, .Char16: return (val >= 0) && (val <= 0xFFFF); case .UInt32, .Char32: return (val >= 0) && (val <= 0xFFFFFFFF); - case .UInt64: return (val >= 0) && (val <= 0x7FFFFFFF'FFFFFFFF); + case .UInt64: return (val >= 0); #if BF_64_BIT - case .Int: return (val >= -0x80000000'00000000) && (val <= 0x7FFFFFFF'FFFFFFFF); - case .UInt: return (val >= 0) && (val <= 0x7FFFFFFF'FFFFFFFF); + case .Int: return true; + case .UInt: return (val >= 0); #else case .Int: return (val >= -0x80000000) && (val <= 0x7FFF'FFFF); case .UInt: return (val >= 0) && (val <= 0xFFFFFFFF); diff --git a/BeefTools/BeefMem/BeefMem.vcxproj b/BeefTools/BeefMem/BeefMem.vcxproj index f7df16ba..78f8c58d 100644 --- a/BeefTools/BeefMem/BeefMem.vcxproj +++ b/BeefTools/BeefMem/BeefMem.vcxproj @@ -1,4 +1,4 @@ - + @@ -231,32 +231,32 @@ $(ProjectName)64_d - $(SolutionDir)\dist\ + $(SolutionDir)\IDE\dist\ $(ProjectName)64_d - $(SolutionDir)\dist\ + $(SolutionDir)\IDE\dist\ $(ProjectName)64 - $(SolutionDir)\dist\ + $(SolutionDir)\IDE\dist\ false $(ProjectName)64 - $(SolutionDir)\dist\ + $(SolutionDir)\IDE\dist\ - $(SolutionDir)\dist\ + $(SolutionDir)\IDE\dist\ - $(SolutionDir)\dist\ + $(SolutionDir)\IDE\dist\ - $(SolutionDir)\dist\ + $(SolutionDir)\IDE\dist\ - $(SolutionDir)\dist\ + $(SolutionDir)\IDE\dist\ @@ -301,8 +301,8 @@ Windows DebugFull - $(SolutionDir)\dist\$(TargetName).dll - $(SolutionDir)\dist\$(TargetName).lib + $(SolutionDir)\IDE\dist\$(TargetName).dll + $(SolutionDir)\IDE\dist\$(TargetName).lib @@ -320,8 +320,8 @@ Windows DebugFull - $(SolutionDir)\dist\$(TargetName).dll - $(SolutionDir)\dist\$(TargetName).lib + $(SolutionDir)\IDE\dist\$(TargetName).dll + $(SolutionDir)\IDE\dist\$(TargetName).lib @@ -377,8 +377,8 @@ Debug true true - $(SolutionDir)\dist\$(TargetName).dll - $(SolutionDir)\dist\$(TargetName).lib + $(SolutionDir)\IDE\dist\$(TargetName).dll + $(SolutionDir)\IDE\dist\$(TargetName).lib @@ -397,8 +397,8 @@ DebugFull true true - $(SolutionDir)\dist\$(TargetName).dll - $(SolutionDir)\dist\$(TargetName).lib + $(SolutionDir)\IDE\dist\$(TargetName).dll + $(SolutionDir)\IDE\dist\$(TargetName).lib diff --git a/BeefTools/BeefMem/gperftools/vsprojects/libtcmalloc_minimal/libtcmalloc_minimal.vcxproj b/BeefTools/BeefMem/gperftools/vsprojects/libtcmalloc_minimal/libtcmalloc_minimal.vcxproj index 22522442..03e15615 100644 --- a/BeefTools/BeefMem/gperftools/vsprojects/libtcmalloc_minimal/libtcmalloc_minimal.vcxproj +++ b/BeefTools/BeefMem/gperftools/vsprojects/libtcmalloc_minimal/libtcmalloc_minimal.vcxproj @@ -1,4 +1,4 @@ - + @@ -39,7 +39,7 @@ <_ProjectFileVersion>12.0.21005.1 - $(SolutionDir)$(Configuration)\ + $(SolutionDir)\ide\dist\$(Platform)\$(Configuration)\ $(Configuration)\ true diff --git a/BeefySysLib/BeefySysLib_static.vcxproj b/BeefySysLib/BeefySysLib_static.vcxproj index 2dc9303e..139ba673 100644 --- a/BeefySysLib/BeefySysLib_static.vcxproj +++ b/BeefySysLib/BeefySysLib_static.vcxproj @@ -79,6 +79,7 @@ $(ProjectName)_d third_party\AK\lib\debug;C:\Program Files %28x86%29\Microsoft DirectX SDK %28June 2007%29\Lib\x86;$(LibraryPath);$(WindowsSDK_LibraryPath_x86) $(Platform)\$(Configuration)_static\ + $(SolutionDir)\ide\dist\$(Platform)\$(Configuration)\ false @@ -90,6 +91,7 @@ false $(Platform)\$(Configuration)_static\ + $(SolutionDir)\ide\dist\$(Platform)\$(Configuration)\ diff --git a/BeefySysLib/gfx/FTFont.cpp b/BeefySysLib/gfx/FTFont.cpp index 323ec407..49a4b55f 100644 --- a/BeefySysLib/gfx/FTFont.cpp +++ b/BeefySysLib/gfx/FTFont.cpp @@ -120,6 +120,7 @@ void FTFontManager::ClearCache() FTFontManager::Page::~Page() { + mTexture->Release(); //delete mTexture; } @@ -266,8 +267,7 @@ FTFontManager::Glyph* FTFont::AllocGlyph(int charCode, bool allowDefault) else img.mBits[i] = 0xFF0000FF; } - page->mTexture = gBFApp->mRenderDevice->LoadTexture(&img, TextureFlag_NoPremult); - page->mTexture->mRefCount = 0; + page->mTexture = gBFApp->mRenderDevice->LoadTexture(&img, TextureFlag_NoPremult); } if (bitmap.width > 0) diff --git a/BeefySysLib/util/BeefPerf.cpp b/BeefySysLib/util/BeefPerf.cpp index 98fb8444..98beab18 100644 --- a/BeefySysLib/util/BeefPerf.cpp +++ b/BeefySysLib/util/BeefPerf.cpp @@ -1781,4 +1781,4 @@ BP_EXPORT const char* BP_CALLTYPE BpDynStr(const char* str) return str; } -#endif \ No newline at end of file +#endif diff --git a/Debugger32/Debugger32.vcxproj b/Debugger32/Debugger32.vcxproj index 76d91e1e..0d25e75a 100644 --- a/Debugger32/Debugger32.vcxproj +++ b/Debugger32/Debugger32.vcxproj @@ -1,4 +1,4 @@ - + @@ -106,19 +106,21 @@ - $(SolutionDir)$(Platform)\$(Configuration)\ + $(SolutionDir)\ide\dist\$(Platform)\$(Configuration)\ $(Platform)\$(Configuration)\ $(VSInstallDir)\DIA SDK\include;C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Include;$(IncludePath) - $(SolutionDir)$(Platform)\$(Configuration)\ + $(SolutionDir)\ide\dist\$(Platform)\$(Configuration)\ $(Platform)\$(Configuration)\ $(VSInstallDir)\DIA SDK\include;C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Include;$(IncludePath) + $(SolutionDir)\ide\dist\$(Platform)\$(Configuration)\ $(VSInstallDir)\DIA SDK\include;C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Include;$(VC_IncludePath);$(WindowsSDK_IncludePath); + $(SolutionDir)\ide\dist\$(Platform)\$(Configuration)\ $(VSInstallDir)\DIA SDK\include;C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Include;$(VC_IncludePath);$(WindowsSDK_IncludePath); diff --git a/Debugger64/Debugger64.vcxproj b/Debugger64/Debugger64.vcxproj index 655c57bb..1a4c9f38 100644 --- a/Debugger64/Debugger64.vcxproj +++ b/Debugger64/Debugger64.vcxproj @@ -106,7 +106,7 @@ - $(SolutionDir)$(Platform)\$(Configuration)\ + $(SolutionDir)\ide\dist\$(Platform)\$(Configuration)\ $(Platform)\$(Configuration)\ $(VSInstallDir)\DIA SDK\include;C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Include;$(IncludePath) @@ -116,9 +116,11 @@ $(VSInstallDir)\DIA SDK\include;;C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Include;$(IncludePath) + $(SolutionDir)\ide\dist\$(Platform)\$(Configuration)\ $(VSInstallDir)\DIA SDK\include;C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Include;$(VC_IncludePath);$(WindowsSDK_IncludePath); + $(SolutionDir)\ide\dist\$(Platform)\$(Configuration)\ $(VSInstallDir)\DIA SDK\include;C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Include;$(VC_IncludePath);$(WindowsSDK_IncludePath); diff --git a/IDE/src/BuildContext.bf b/IDE/src/BuildContext.bf index b9bd2429..04227eef 100644 --- a/IDE/src/BuildContext.bf +++ b/IDE/src/BuildContext.bf @@ -831,19 +831,23 @@ namespace IDE return true; Workspace.Options workspaceOptions = gApp.GetCurWorkspaceOptions(); - BfCompiler bfCompiler = gApp.mBfBuildCompiler; + BfCompiler bfCompiler = gApp.mBfBuildCompiler; var bfProject = gApp.mBfBuildSystem.mProjectMap[project]; - bool bfHadOutputChanges; + bool bfHadOutputChanges = false; List bfFileNames = scope List(); - bfCompiler.GetOutputFileNames(bfProject, true, out bfHadOutputChanges, bfFileNames); - defer ClearAndDeleteItems(bfFileNames);//DeleteAndClearItems!(bfFileNames); + if (project.mCurBfOutputFileNames == null) + { + project.mCurBfOutputFileNames = new .(); + bfCompiler.GetOutputFileNames(bfProject, true, out bfHadOutputChanges, project.mCurBfOutputFileNames); + } + for (var fileName in project.mCurBfOutputFileNames) + bfFileNames.Add(fileName); if (bfHadOutputChanges) project.mNeedsTargetRebuild = true; List allFileNames = scope List(); List clangAllObjNames = scope List(); - //List clangObjNames = scope List(); - + gApp.GetClangFiles(project.mRootFolder, allFileNames); String workspaceBuildDir = scope String(); @@ -853,8 +857,6 @@ namespace IDE if (!projectBuildDir.IsEmpty) Directory.CreateDirectory(projectBuildDir).IgnoreError(); - //List buildFileNames = new List(); - String targetPath = scope String(); String outputDir = scope String(); diff --git a/IDE/src/Project.bf b/IDE/src/Project.bf index 47de9796..041cedad 100644 --- a/IDE/src/Project.bf +++ b/IDE/src/Project.bf @@ -1188,6 +1188,8 @@ namespace IDE public bool mFailed; public bool mNeedsCreate; + public List mCurBfOutputFileNames ~ DeleteContainerAndItems!(_); + public String ProjectFileName { get diff --git a/IDE/src/ui/WelcomePanel.bf b/IDE/src/ui/WelcomePanel.bf index 6b20349c..9665e5a2 100644 --- a/IDE/src/ui/WelcomePanel.bf +++ b/IDE/src/ui/WelcomePanel.bf @@ -111,7 +111,7 @@ namespace IDE.ui public override void Draw(Graphics g) { using (g.PushColor(0x40000000)) - g.FillRect(mWidth/2 - GS!(500), YOfs - GS!(24), GS!(500)*2, 570); + g.FillRect(mWidth/2 - GS!(500), YOfs - GS!(24), GS!(500)*2, GS!(570)); g.SetFont(mLargeFont); using (g.PushColor(0xFFE0E0FF)) diff --git a/IDEHelper/Compiler/BfExprEvaluator.cpp b/IDEHelper/Compiler/BfExprEvaluator.cpp index 810e9fa3..89e15aed 100644 --- a/IDEHelper/Compiler/BfExprEvaluator.cpp +++ b/IDEHelper/Compiler/BfExprEvaluator.cpp @@ -16230,11 +16230,158 @@ void BfExprEvaluator::PerformBinaryOperation(BfExpression* leftExpression, BfExp return PerformBinaryOperation(leftExpression, rightExpression, binaryOp, opToken, flags, leftValue); } +bool BfExprEvaluator::CheckConstCompare(BfBinaryOp binaryOp, BfAstNode* opToken, const BfTypedValue& leftValue, const BfTypedValue& rightValue) +{ + if ((binaryOp < BfBinaryOp_Equality) || (binaryOp > BfBinaryOp_LessThanOrEqual)) + return false; + + // LHS is expected to be a value and RHS is expected to be a const + if (!leftValue.mType->IsIntegral()) + return false; + + BF_ASSERT(rightValue.mValue.IsConst()); + auto rightConst = mModule->mBfIRBuilder->GetConstant(rightValue.mValue); + + BfType* checkType = leftValue.mType; + if (checkType->IsTypedPrimitive()) + checkType = checkType->GetUnderlyingType(); + if (!checkType->IsPrimitiveType()) + return false; + + BfTypeCode typeCode = ((BfPrimitiveType*)checkType)->mTypeDef->mTypeCode; + + int64 minValue = 0; + int64 maxValue = 0; + switch (typeCode) + { + case BfTypeCode_Int8: + minValue = -0x80; + maxValue = 0x7F; + break; + case BfTypeCode_Int16: + minValue = -0x8000; + maxValue = 0x7FFF; + break; + case BfTypeCode_Int32: + minValue = -0x80000000LL; + maxValue = 0x7FFFFFFF; + break; + case BfTypeCode_Int64: + minValue = -0x8000000000000000LL; + maxValue = 0x7FFFFFFFFFFFFFFFLL; + break; + case BfTypeCode_UInt8: + maxValue = 0xFF; + break; + case BfTypeCode_UInt16: + maxValue = 0xFFFF; + break; + case BfTypeCode_UInt32: + maxValue = 0xFFFFFFFF; + break; + default: + return false; + } + + int constResult = -1; + if (typeCode == BfTypeCode_UInt64) + { + switch (binaryOp) + { + case BfBinaryOp_Equality: + if (rightConst->mInt64 < minValue) + constResult = 0; + break; + case BfBinaryOp_InEquality: + if (rightConst->mInt64 < minValue) + constResult = 1; + break; + case BfBinaryOp_LessThan: + if (rightConst->mInt64 <= minValue) + constResult = 0; + break; + case BfBinaryOp_LessThanOrEqual: + if (rightConst->mInt64 < minValue) + constResult = 0; + break; + } + return false; + } + else + { + switch (binaryOp) + { + case BfBinaryOp_Equality: + if (rightConst->mInt64 < minValue) + constResult = 0; + else if (rightConst->mInt64 > maxValue) + constResult = 0; + break; + case BfBinaryOp_InEquality: + if (rightConst->mInt64 < minValue) + constResult = 1; + else if (rightConst->mInt64 > maxValue) + constResult = 1; + break; + case BfBinaryOp_LessThan: + if (rightConst->mInt64 <= minValue) + constResult = 0; + else if (rightConst->mInt64 > maxValue) + constResult = 1; + break; + case BfBinaryOp_LessThanOrEqual: + if (rightConst->mInt64 < minValue) + constResult = 0; + else if (rightConst->mInt64 >= maxValue) + constResult = 1; + break; + case BfBinaryOp_GreaterThan: + if (rightConst->mInt64 >= maxValue) + constResult = 0; + else if (rightConst->mInt64 < minValue) + constResult = 1; + break; + case BfBinaryOp_GreaterThanOrEqual: + if (rightConst->mInt64 > maxValue) + constResult = 0; + else if (rightConst->mInt64 <= minValue) + constResult = 1; + break; + } + } + + if (constResult == 0) + { + mModule->Warn(0, "The result of this operation is always 'false'", opToken); + mResult = BfTypedValue(mModule->mBfIRBuilder->CreateConst(BfTypeCode_Boolean, 1), mModule->GetPrimitiveType(BfTypeCode_Boolean)); + return true; + } + else if (constResult == 1) + { + mModule->Warn(0, "The result of this operation is always 'true'", opToken); + mResult = BfTypedValue(mModule->mBfIRBuilder->CreateConst(BfTypeCode_Boolean, 1), mModule->GetPrimitiveType(BfTypeCode_Boolean)); + return true; + } + + return false; +} + void BfExprEvaluator::PerformBinaryOperation(BfAstNode* leftExpression, BfAstNode* rightExpression, BfBinaryOp binaryOp, BfAstNode* opToken, BfBinOpFlags flags, BfTypedValue leftValue, BfTypedValue rightValue) { bool noClassify = (flags & BfBinOpFlag_NoClassify) != 0; bool forceLeftType = (flags & BfBinOpFlag_ForceLeftType) != 0; + if ((rightValue.mValue.IsConst()) && (!leftValue.mValue.IsConst())) + { + if (CheckConstCompare(binaryOp, opToken, leftValue, rightValue)) + return; + } + else if ((leftValue.mValue.IsConst()) && (!rightValue.mValue.IsConst())) + { + if (CheckConstCompare(GetOppositeBinaryOp(binaryOp), opToken, rightValue, leftValue)) + return; + } + if ((binaryOp == BfBinaryOp_NullCoalesce) && ((leftValue.mType->IsPointer()) || (leftValue.mType->IsObject()))) { auto prevBB = mModule->mBfIRBuilder->GetInsertBlock(); @@ -17261,7 +17408,7 @@ void BfExprEvaluator::PerformBinaryOperation(BfType* resultType, BfIRValue convL mResult = BfTypedValue(mModule->mBfIRBuilder->CreateCmpNE(convLeftValue, convRightValue), mModule->GetPrimitiveType(BfTypeCode_Boolean)); break; - case BfBinaryOp_LessThan: + case BfBinaryOp_LessThan: mResult = BfTypedValue(mModule->mBfIRBuilder->CreateCmpLT(convLeftValue, convRightValue, resultType->IsSignedInt()), mModule->GetPrimitiveType(BfTypeCode_Boolean)); break; diff --git a/IDEHelper/Compiler/BfExprEvaluator.h b/IDEHelper/Compiler/BfExprEvaluator.h index 90d4ff88..41a91e9c 100644 --- a/IDEHelper/Compiler/BfExprEvaluator.h +++ b/IDEHelper/Compiler/BfExprEvaluator.h @@ -336,6 +336,7 @@ public: void LookupQualifiedName(BfAstNode* nameNode, BfIdentifierNode* nameLeft, BfIdentifierNode* nameRight, bool ignoreInitialError, bool* hadError = NULL); void LookupQualifiedStaticField(BfQualifiedNameNode* nameNode, bool ignoreIdentifierNotFoundError); void LookupQualifiedStaticField(BfAstNode* nameNode, BfIdentifierNode* nameLeft, BfIdentifierNode* nameRight, bool ignoreIdentifierNotFoundError); + bool CheckConstCompare(BfBinaryOp binaryOp, BfAstNode* opToken, const BfTypedValue& leftValue, const BfTypedValue& rightValue); void PerformBinaryOperation(BfType* resultType, BfIRValue convLeftValue, BfIRValue convRightValue, BfBinaryOp binaryOp, BfAstNode* opToken); void PerformBinaryOperation(BfAstNode* leftExpression, BfAstNode* rightExpression, BfBinaryOp binaryOp, BfAstNode* opToken, BfBinOpFlags flags, BfTypedValue leftValue, BfTypedValue rightValue); void PerformBinaryOperation(BfExpression* leftNode, BfExpression* rightNode, BfBinaryOp binaryOp, BfTokenNode* opToken, BfBinOpFlags flags, BfTypedValue leftValue); diff --git a/IDEHelper/Compiler/BfStmtEvaluator.cpp b/IDEHelper/Compiler/BfStmtEvaluator.cpp index b9c4ec27..25e71ccb 100644 --- a/IDEHelper/Compiler/BfStmtEvaluator.cpp +++ b/IDEHelper/Compiler/BfStmtEvaluator.cpp @@ -1631,7 +1631,8 @@ BfLocalVariable* BfModule::HandleVariableDeclaration(BfVariableDeclaration* varD localDef->mValue = initValue.mValue; if ((localDef->mAddr) && (!localDef->mResolvedType->IsValuelessType())) { - wantsStore = true; + if (!initValue.mType->IsVar()) + wantsStore = true; } else { @@ -5448,7 +5449,7 @@ void BfModule::Visit(BfForEachStatement* forEachStmt) else if (isVarEnumerator) { // Generic method or mixin decl - BF_ASSERT(mBfIRBuilder->mIgnoreWrites); + BF_ASSERT(mBfIRBuilder->mIgnoreWrites || mHadVarUsage); } else if (!target.mType->IsTypeInstance()) { diff --git a/IDEHelper/WinDebugger.cpp b/IDEHelper/WinDebugger.cpp index df0b92e1..9a63a4d4 100644 --- a/IDEHelper/WinDebugger.cpp +++ b/IDEHelper/WinDebugger.cpp @@ -6543,7 +6543,7 @@ String WinDebugger::DbgTypedValueToString(const DbgTypedValue& origTypedValue, c break; case DbgType_UChar: if (language != DbgLanguage_Beef) - return IntTypeToString(typedValue.mUInt8, WrapWithModifiers("uint8_t", origValueType, language), displayInfo, formatInfo); + return IntTypeToString(typedValue.mUInt8, WrapWithModifiers("uint8_t", origValueType, language), displayInfo, formatInfo); case DbgType_SChar: { if (typedValue.mInt8 != 0) diff --git a/bin/build.bat b/bin/build.bat index d6e6be81..6584e6e4 100644 --- a/bin/build.bat +++ b/bin/build.bat @@ -10,6 +10,11 @@ PUSHD %~dp0..\ @ECHO Performing clean build :BUILD +@IF EXIST extern\llvm-project_8_0_1 GOTO LLVM_HAS +call extern\llvm_build.bat +@IF %ERRORLEVEL% NEQ 0 GOTO HADERROR +:LLVM_HAS + CALL bin/msbuild.bat BeefySysLib\BeefySysLib.vcxproj /p:Configuration=Debug /p:Platform=x64 /p:SolutionDir=%cd%\ /v:m %MSBUILD_FLAGS% @IF %ERRORLEVEL% NEQ 0 GOTO HADERROR diff --git a/extern/hunspell/src/win_api/libhunspell.vcxproj b/extern/hunspell/src/win_api/libhunspell.vcxproj index e7cef33e..feeec314 100644 --- a/extern/hunspell/src/win_api/libhunspell.vcxproj +++ b/extern/hunspell/src/win_api/libhunspell.vcxproj @@ -1,4 +1,4 @@ - + @@ -125,11 +125,11 @@ <_ProjectFileVersion>14.0.22823.1 - $(SolutionDir)$(Configuration)\$(ProjectName)\ + $(SolutionDir)\ide\dist\$(Platform)\$(Configuration)\ $(Configuration)\$(ProjectName)\ - $(SolutionDir)$(Configuration)\$(ProjectName)\ + $(SolutionDir)\ide\dist\$(Platform)\$(Configuration)\ $(Configuration)\$(ProjectName)\ @@ -148,6 +148,12 @@ true + + $(SolutionDir)\ide\dist\$(Platform)\$(Configuration)\ + + + $(SolutionDir)\ide\dist\$(Platform)\$(Configuration)\ + Disabled diff --git a/extern/llvm_build.bat b/extern/llvm_build.bat index 0db636ff..c6530ed1 100644 --- a/extern/llvm_build.bat +++ b/extern/llvm_build.bat @@ -1,4 +1,6 @@ -@IF EXIST llvm-project GOTO LLVM_HAS +PUSHD %~dp0..\ + +@IF EXIST llvm-project_8_0_1 GOTO LLVM_HAS git clone --config core.autocrlf=false https://github.com/llvm/llvm-project.git llvm-project_8_0_1 pushd llvm-project_8_0_1 GOTO :LLVM_SET @@ -24,3 +26,13 @@ cd llvm_win64_8_0_1 :DOBUILD cmake --build . --config Debug cmake --build . --config Release + +:SUCCESS +@ECHO SUCCESS! +@POPD +@EXIT /b 0 + +:HADERROR +@ECHO =================FAILED================= +@POPD +@EXIT /b %ERRORLEVEL% \ No newline at end of file