Skip to content

Commit

Permalink
Revert "sourcebuild: try to fix version..."
Browse files Browse the repository at this point in the history
This reverts commit 01c2355.

It doesn't fix the issue either...
  • Loading branch information
mara004 committed Nov 10, 2023
1 parent 01c2355 commit e10f667
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions setupsrc/pypdfium2_setup/build_pdfium.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,11 @@ def dl_pdfium(GClient, do_update, revision):

if is_sync:
# TODO consider passing -D ?
# FIXME Have to use --with-branch-heads, and unable to use --shallow --no-history because of versioning. This probably makes checkout *much* slower, but not sure how to properly get the version heads afterwards. If we just fetch a fixed number of commits, the versions do appear in git log but land in the remotes refspace, which confuses git describe.
run_cmd([GClient, "sync", "--revision", f"origin/{revision}", "--with_branch_heads"], cwd=SBDir)
run_cmd([GClient, "sync", "--revision", f"origin/{revision}", "--no-history", "--shallow"], cwd=SBDir)
# quick & dirty fix to make a version annotated commit available - pdfium gets versioned very frequently, so this should be more than enough
# TODO tighten to check out only up to the latest tag
# FIXME the repository is still left in a very confusing state - maybe we should just drop --no-history --shallow for simplicity?
run_cmd(["git", "fetch", "--depth=100"], cwd=PDFiumDir)

return is_sync

Expand Down

0 comments on commit e10f667

Please sign in to comment.