3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2026-05-16 07:05:35 +00:00

Fix netcoreapp2.0 references in FindDotnet.cmake, CMakeLists.txt, and mk_util.py

Agent-Logs-Url: https://github.com/Z3Prover/z3/sessions/2df6876c-cffb-44a2-8f4a-02e7e175886f

Co-authored-by: NikolajBjorner <3085284+NikolajBjorner@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot] 2026-05-14 07:26:56 +00:00 committed by GitHub
parent 20c057446c
commit a9ba041a2b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 7 additions and 7 deletions

View file

@ -262,8 +262,8 @@ FUNCTION(DOTNET_GET_DEPS _DN_PROJECT arguments)
ENDIF()
IF(_DN_NETCOREAPP)
SET(_DN_BUILD_OPTIONS -f netcoreapp2.0)
SET(_DN_PACK_OPTIONS /p:TargetFrameworks=netcoreapp2.0)
SET(_DN_BUILD_OPTIONS -f net8.0)
SET(_DN_PACK_OPTIONS /p:TargetFrameworks=net8.0)
ELSEIF(UNIX)
# Unix builds default to netstandard2.0
SET(_DN_BUILD_OPTIONS -f netstandard2.0)
@ -384,7 +384,7 @@ FUNCTION(RUN_DOTNET DOTNET_PROJECT)
COMMAND ${DOTNET_EXE} clean ${DOTNET_PROJPATH} ${DOTNET_BUILD_PROPERTIES}
COMMAND ${DOTNET_EXE} build --no-restore ${DOTNET_PROJPATH} -c ${DOTNET_CONFIG} ${DOTNET_BUILD_PROPERTIES} ${DOTNET_BUILD_OPTIONS}
# XXX tfm
COMMAND ${DOTNET_EXE} ${DOTNET_OUTPUT_PATH}/netcoreapp2.0/${DOTNET_PROJNAME}.dll ${DOTNET_ARGUMENTS}
COMMAND ${DOTNET_EXE} ${DOTNET_OUTPUT_PATH}/net8.0/${DOTNET_PROJNAME}.dll ${DOTNET_ARGUMENTS}
COMMAND ${CMAKE_COMMAND} -E touch ${CMAKE_CURRENT_BINARY_DIR}/${DOTNET_PROJNAME}.runtimestamp
WORKING_DIRECTORY ${DOTNET_OUTPUT_PATH})
ADD_CUSTOM_TARGET(
@ -399,7 +399,7 @@ FUNCTION(TEST_DOTNET DOTNET_PROJECT)
IF(WIN32)
SET(test_framework_args "")
ELSE()
SET(test_framework_args -f netcoreapp2.0)
SET(test_framework_args -f net8.0)
ENDIF()
ADD_TEST(NAME ${DOTNET_PROJNAME}

View file

@ -24,9 +24,9 @@ if(UNIX AND NOT APPLE)
add_custom_target(
z3_dotnet_test_manual_copy_assembly_hack ALL
COMMAND ${CMAKE_COMMAND} -E copy ${z3_dotnet_test_manual_copy_deps} ${PROJECT_BINARY_DIR}/dotnet/netcoreapp2.0/
COMMAND ${CMAKE_COMMAND} -E copy ${z3_dotnet_test_manual_copy_deps} ${PROJECT_BINARY_DIR}/dotnet/net8.0/
# hack the libz3 entry in deps so it's easy enough for dotnet to reach it...
COMMAND sed \"s/runtimes\\/.*libz3\\.so/libz3.so/\" -i ${PROJECT_BINARY_DIR}/dotnet/netcoreapp2.0/dotnet.deps.json
COMMAND sed \"s/runtimes\\/.*libz3\\.so/libz3.so/\" -i ${PROJECT_BINARY_DIR}/dotnet/net8.0/dotnet.deps.json
)
add_dependencies(z3_dotnet_test_manual_copy_assembly_hack BUILD_dotnet)

View file

@ -2314,7 +2314,7 @@ class DotNetExampleComponent(ExampleComponent):
dotnet_proj_str = r"""<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp2.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>
<PlatformTarget>%s</PlatformTarget>
</PropertyGroup>
<ItemGroup>