Skip to contentSkip to conversation

downloads: removing git repos and offline builds

Buildroot Andreas Ziegler 2 participants 2 messages Nov 20, 2024 2 messages not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw

Hi Grant,

Quoted 15 lines · Grant Edwards

I've been using buildroot for many years and have always been able to archive (previously in SVN, now in Git/LFS) the contents of the downloads directory so that production firmware can be built offline using nothing but files checked out from SVN/Git. A question has come up with opkg-utils. It downloads a source tarball and clones a git repository:

    $ ls -l downloads/opkg-utils/
    total 48
    drwxr-xr-x 4 grante grante  4096 Nov 19 09:25 git
    -rw-r--r-- 1 grante grante   512 Nov 19 09:25 git.readme
    -rw-r--r-- 1 grante grante 36872 Nov 19 09:25 
opkg-utils-0.6.2-br1.tar.gz
Quoted 3 lines

Actually, I'm not entirely sure whether it downloaded that tarball or created it from the git repository -- I now suspect the latter.

The order is git repository -> tarball -> build directory. The git repository will be reused or recreated if either the package version changes or the tarball is removed. I use this behaviour occasionally to 'fake' package versions.

Quoted 11 lines

In either case, I can't archive a git repository.

It _appears_ that removing the git repo and leaving the tar.gz file is sufficient for doing a build, and if that tarball is present buildroot won't need to access the upstream git repository (thus allowing offline builds using the arhcived tarball).

Requiring offline builds for production firmware can't be that unusual.

Is just removing the git repo and archiving the tarball how people usually deal with this situation?

Any objections to just using a line in .gitignore?

downloads/*/git

Kind regards,
Andreas

Quoted 2 lines

--
Grant

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot

A message that is not in the archive (sent off-list or not yet received): eb63a9dac0a90b6aa67315f285039615__24185.6297756144$1732095375$gmane$org@umbiko.net

#3 lore raw
Quoted 8 lines · Andreas Ziegler
Quoted 5 lines · Grant Edwards

[...] A question has come up with opkg-utils. It downloads a source tarball and clones a git repository:
[...]
Actually, I'm not entirely sure whether it downloaded that tarball or created it from the git repository -- I now suspect the latter.

Quoted 4 lines

The order is git repository -> tarball -> build directory. The git repository will be reused or recreated if either the package version changes or the tarball is removed. I use this behaviour occasionally to 'fake' package versions.

Thanks for confirming that.

Quoted 9 lines
Quoted 5 lines

[....] Requiring offline builds for production firmware can't be that unusual.

Is just removing the git repo and archiving the tarball how people usually deal with this situation?

Any objections to just using a line in .gitignore?

downloads/*/git

Not really, that should work fine. I initially decided to remove it just to be sure whether or not it actually needed to be there to do a build.

--
Grant

_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot