-
Notifications
You must be signed in to change notification settings - Fork 222
Open
Labels
Continuous IntegrationEnhancement RequestTriageIssue needs to be assessed and labeled, further information on reported might be neededIssue needs to be assessed and labeled, further information on reported might be needed
Description
General Summary
Address the issue that occurs now and needs manual correction to remove a hidden copy of the files by doing something similar to the following plan. The following plan is windows specific but an example to follow.
Detailed Description
The tar balls are currently including a hidden copy of all the files with an '.' prepended to the file name.
Possible Implementation
Exact Code Changes Required to Fix Windows Tarball Issue (Revised)
Change 1: Modify CMakeLists.txt to Switch Windows Generator
File: CMakeLists.txt
Location: Before line 1485 (before include(CPack))
# Platform-specific CPack generators
if(WIN32)
# Windows: Generate IFW (installer) and ZIP (portable)
# Note: TGZ disabled in CPack to avoid including hidden build artifacts/ADS.
# We will generate a clean TGZ from the ZIP in the CI workflow.
set(CPACK_GENERATOR "IFW;ZIP" CACHE STRING "CPack generators")
elseif(APPLE)
set(CPACK_GENERATOR "IFW;TGZ" CACHE STRING "CPack generators")
else()
set(CPACK_GENERATOR "IFW;TGZ;DEB;RPM" CACHE STRING "CPack generators")
endif()
if (NOT DELAY_INCLUDE_CPACK)
include(CPack)
endif()Change 2: Modify Workflow to Convert ZIP to Clean TGZ
File: .github/workflows/full-build.yml
Location: After "Create packages" step (around line 1611)
- name: Create packages
if: ${{ success() && !cancelled() }}
working-directory: ${{ env.OPENSTUDIO_BUILD }}
run: |
& $env:ComSpec /c "call conanbuild.bat && cpack -C ${{ env.BUILD_TYPE }}"
- name: Create clean tar.gz from zip
if: ${{ success() && !cancelled() }}
working-directory: ${{ env.OPENSTUDIO_BUILD }}
run: |
# Convert clean ZIP to TAR.GZ to avoid Windows ADS/hidden file issues
$zipDir = "${{ env.OPENSTUDIO_BUILD }}/_CPack_Packages/win64/ZIP"
$tgzDir = "${{ env.OPENSTUDIO_BUILD }}/_CPack_Packages/win64/TGZ"
if (Test-Path $zipDir) {
New-Item -ItemType Directory -Force -Path $tgzDir | Out-Null
$zips = Get-ChildItem -Path $zipDir -Filter "*.zip"
foreach ($zip in $zips) {
Write-Host "Converting $($zip.Name) to tar.gz..."
$extractPath = Join-Path $zipDir ("extract_" + $zip.BaseName)
Expand-Archive -Path $zip.FullName -DestinationPath $extractPath
$tarName = $zip.Name.Replace(".zip", ".tar.gz")
$tarPath = Join-Path $tgzDir $tarName
# Create tar.gz using system tar (bsdtar)
# -C changes to extract dir, so we archive the contents (which includes top-level folder)
tar -czf $tarPath -C $extractPath .
if ($LASTEXITCODE -ne 0) {
Write-Error "Failed to create tar.gz for $($zip.Name)"
exit 1
}
# Cleanup
Remove-Item -Recurse -Force $extractPath
}
}What Stays the Same
- The "Upload Signed TGZ installer" step (lines 1706-1711) remains unchanged. It will pick up the new file because we put it in the
TGZfolder. - The
windows-publishjob remains unchanged. It will continue to find and upload thetar.gz.
Result
- CPack creates a clean
.zip(no ADS/hidden metadata). - We script the conversion of
.zip->.tar.gz. - The resulting
.tar.gzis clean because the source.zipwas clean. - CI pipeline continues to work exactly as before, satisfying all requirements.
Metadata
Metadata
Assignees
Labels
Continuous IntegrationEnhancement RequestTriageIssue needs to be assessed and labeled, further information on reported might be neededIssue needs to be assessed and labeled, further information on reported might be needed