| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
| |
When updating packages on the target device we ideally want to match
user and group numbers from the existing file system. This patch encourages
opkg to lookup the uname/gname fields first and only use the hardcoded
numerical values if that fails.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
git-svn-id: http://opkg.googlecode.com/svn/trunk@637 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Patch from Mike Westerhof, with minor modifications to allow the use of both
GNU gunzip and busybox gunzip. His original patch header follows.
This patch allows a user to set an environment variable to cause opkg to
select either the built-in gunzip code or an external gunzip utility, in
order to dodge the OOM Killer.
The built-in code is, of course, is the most desirable way to use opkg,
since it is far more efficient. However, the built-in code can trigger
the OOM (out of memory) killer on small-memory machines, like the 32MB
NSLU2. This occurs because a standard fork will duplicate the entire
address space of the parent. Since opkg reads the entire feed database
into memory, this problem is compounded by large feeds.
This patch introduces a means for the user to cause opkg to use vfork()
instead -- vfork() does not behave in the same manner as fork(), and
does not trigger the OOM killer. However, the semantics of vfork() are
such that it cannot run the built-in gunzip code. Instead, it must
exec() an external utility to perform the gunzip operation. It seems
counter-intuitive, but the vfork()/exec() approach is the only good way
to avoid triggering the dreaded OOM killer.
In order to use this, the user must manually set the OPKG_USE_VFORK
environment variable to any value. For example:
$ OPKG_USE_VFORK=1 opkg install samba
The external utility used to do the gunzip operation is "busybox gunzip".
It would have been nice to be able to just invoke "gunzip", but the
full gunzip executable behaves slightly differently than does busybox,
generating annoying warning messages.
This is an update of the original patch by Mike Westerhof, Dec 2008.
Mike Westerhof, Feb 2011
git-svn-id: http://opkg.googlecode.com/svn/trunk@604 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Patch from Richard Purdie. Tracked as Issue #72. Original patch header follows.
If a tarball contains a long symlink (over 100 chars) in a longpath (over 100
chars) then the resulting link or path can be truncated to 100 chars.
This is due to a bug where if both 'L' and 'K' entries are found in the tarball,
only the first one takes affect due to get_header_tar recursively calling itself.
To fix this, process longname and linkname at the end of the function rather
than the start after any subcalls have taken place.
Richard Purdie
22/12/2010
git-svn-id: http://opkg.googlecode.com/svn/trunk@594 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
| |
Found with Clang.
git-svn-id: http://opkg.googlecode.com/svn/trunk@588 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@577 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@558 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@552 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
| |
From "paradox.kahn", see Issue #55.
git-svn-id: http://opkg.googlecode.com/svn/trunk@544 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
|
|
|
|
| |
Patch to remove "duplicate" bits of logs from opkg output, which
massively simplifies do_rootfs logs. The reason is we get unflushed
data passed to the children and duplicated.
RP - 26/1/10
git-svn-id: http://opkg.googlecode.com/svn/trunk@522 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@503 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@481 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@471 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
|
|
|
| |
As opkg has never failed from these errors in the past, many recipes in
OpenEmbedded have come to rely on this behaviour. So proceed regardless of
extraction errors for now, to give the OE folks a chance to fix broken
packages first.
git-svn-id: http://opkg.googlecode.com/svn/trunk@445 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
|
|
| |
Fix problem wich may lead to FALSE and TRUE being redefined.
Thanks to John L. for reporting this problem
git-svn-id: http://opkg.googlecode.com/svn/trunk@413 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
| |
child from being killed by SIGPIPE.
git-svn-id: http://opkg.googlecode.com/svn/trunk@392 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@390 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@388 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@385 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@384 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@347 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
<enrico.scholz@informatik.tu-chemnitz.de>, his analysis follows.
libbb/unarchive.c: prevent opkg hang when subprocess is stuck in a
write() call on a filled pipe and main process (which assumes that end
of data from pipe has been reached) waits for this died subprocess.
This patch swaps the original wait(pid) + close(pipe) sequencse so
that pipe is closed first.
The 'ar' code path has been fixed too by breaking the loop when
requested data have been found. Previously, the loop continued at
the (wrongly calculated) next position in the stream. The patch
moves the stream cleanup at a better place.
Variable declarations were moved to inner scopes too to ease detection
of broken deallocation.
NOTE: the
| f = fdopen(...);
| while (... /* do fread(f) */ ...) { /* ==1== */
| /* this is done in gz_open() */
| pid = fork();
| if (pid == 0) {
| fread(f); /* ==2== */
| _exit(0);
| }
| }
code looks problematic because '==2==' might update f's internal
buffer. As ==2== is done in an own process, these changes are not
seen by ==1==. It works only because gz_open() is called not more
than one time and the loops break (after the patch).
git-svn-id: http://opkg.googlecode.com/svn/trunk@340 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@332 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@326 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@325 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@314 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@310 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@308 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@307 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@306 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
|
|
| |
- Don't try to free() memory in a different process!
- Move the function to a more appropriate file.
- Fix error messages while here.
git-svn-id: http://opkg.googlecode.com/svn/trunk@305 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@304 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@303 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@280 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@233 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@228 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
|
|
| |
s/strndup/xstrndup/
Thanks to Graham Gower <graham.gower@gmail.com>
git-svn-id: http://opkg.googlecode.com/svn/trunk@224 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
|
|
|
|
| |
Modified seek_sub_file since the fgetc in the for loop
was very slow when installing huge packages.
A test on my machine showed a 4x gain when installing
a large package (23Mib)
git-svn-id: http://opkg.googlecode.com/svn/trunk@222 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
1. provide opkg with a tar file that has a link name that is 100
characters
or
2. provide opkg with a tar file that has a 'path_prefix' of 155
characters.
Thanks to pblack88@gmail.com
http://code.google.com/p/opkg/issues/detail?id=21
git-svn-id: http://opkg.googlecode.com/svn/trunk@217 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
|
|
|
| |
http://www.crisos.org/flyspray/index.php?do=details&task_id=10
Fix issue:
http://code.google.com/p/opkg/issues/detail?id=4#c5
git-svn-id: http://opkg.googlecode.com/svn/trunk@214 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
|
|
|
|
|
| |
Propagate gz_open() errors to caller function.
This is not enough, it is still needed to check deb_extract return value
everywhere in libopkg/pkg_extract.c
Signed-off-by: Antonio Ospite <ospite@studenti.unina.it>
git-svn-id: http://opkg.googlecode.com/svn/trunk@205 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Frans Meulenbroeks wrote:
> Anyway, appending the 0 byte is no good as tar_entry->name[100] is
> already out of bounds.
http://tiny.cc/964UD looks good enough. It's interesting that we have
to trace bugs already fixed upstream years ago.
http://lists.linuxtogo.org/pipermail/openembedded-devel/2009-March/008510.html
git-svn-id: http://opkg.googlecode.com/svn/trunk@203 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Frans Meulenbroeks
http://groups.google.com/group/opkg-devel/browse_thread/thread/23c3557277de0f2e
If a file name in a tar archive is exactly 100 bytes long the name
field is completely filled and there is no terminating null byte;
so extraction of the file will yield a name that is extended with the
mode (e.g. 000644).
The attached patch cures it although there might be better solutions.
The problem is also in busybox tar and reported there too.
Frans.
git-svn-id: http://opkg.googlecode.com/svn/trunk@201 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
|
| |
Waiting for the patch fixing bugs.
git-svn-id: http://opkg.googlecode.com/svn/trunk@192 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
----------
This patchset updates the libbb stuff to use a vfork() version of
gz_open, called gzvopen. This is done because a standard fork will
duplicate the entire address space. This will invoke the OOM
(out of memory) killer on small-memory machines, because most often
by the time we unzip any package, we've read the entire package
database into memory already. By using vfork() and immediatly
execing the external gunzip utility, we avoid the need to clone the
entire address space.
Yes, this is actually **LESS** efficient than the original way!
But there is no way to (currently) dodge the OOM killer on a
per-process basis, so the alternatives are to either change the
OOM killer behavior system-wide, or to use this workaround.
Mike Westerhof, Dec 2008
git-svn-id: http://opkg.googlecode.com/svn/trunk@190 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@157 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
| |
Scholz -- thanks!
git-svn-id: http://opkg.googlecode.com/svn/trunk@151 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@148 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
|
|
| |
running libopkg_test
git-svn-id: http://opkg.googlecode.com/svn/trunk@116 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
| |
git-svn-id: http://opkg.googlecode.com/svn/trunk@85 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|
|
|
|
|
|
|
|
| |
Fix the usage of dirname() in libbb/make_directory.c, as it is not correct according to the standard specification for dirname.
git-svn-id: http://opkg.googlecode.com/svn/trunk@48 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358
|