Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] downloads: removing git repos and offline builds
@ 2024-11-19 16:12 Grant Edwards
  0 siblings, 0 replies; 3+ messages in thread
From: Grant Edwards @ 2024-11-19 16:12 UTC (permalink / raw)
  To: buildroot

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

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

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?

--
Grant

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Buildroot] downloads: removing git repos and offline builds
       [not found] <mailman.17954.1732090118.1448558.buildroot@buildroot.org>
@ 2024-11-20  9:27 ` Andreas Ziegler
       [not found] ` <eb63a9dac0a90b6aa67315f285039615__24185.6297756144$1732095375$gmane$org@umbiko.net>
  1 sibling, 0 replies; 3+ messages in thread
From: Andreas Ziegler @ 2024-11-20  9:27 UTC (permalink / raw)
  To: Grant Edwards; +Cc: buildroot

Hi Grant,

On 2024-11-19 16:12, Grant Edwards wrote:
> 
> 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
> 
> 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.

> 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

> --
> Grant
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Buildroot] downloads: removing git repos and offline builds
       [not found] ` <eb63a9dac0a90b6aa67315f285039615__24185.6297756144$1732095375$gmane$org@umbiko.net>
@ 2024-11-20 13:25   ` Grant Edwards
  0 siblings, 0 replies; 3+ messages in thread
From: Grant Edwards @ 2024-11-20 13:25 UTC (permalink / raw)
  To: buildroot

On 2024-11-20, Andreas Ziegler <br015@umbiko.net> wrote:
> On 2024-11-19 16:12, Grant Edwards wrote:
>
>> [...] 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.
>
> 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.

>> [....] 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
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2024-11-20 13:25 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-11-19 16:12 [Buildroot] downloads: removing git repos and offline builds Grant Edwards
     [not found] <mailman.17954.1732090118.1448558.buildroot@buildroot.org>
2024-11-20  9:27 ` Andreas Ziegler
     [not found] ` <eb63a9dac0a90b6aa67315f285039615__24185.6297756144$1732095375$gmane$org@umbiko.net>
2024-11-20 13:25   ` Grant Edwards

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox