Age | Commit message (Collapse) | Author |
|
This adds SPDX license headers to all source files in pseudo so license
identification models current best practise.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
|
|
Original commit message:
The idea came up here:
https://bugzilla.yoctoproject.org/show_bug.cgi?id=11309
and here:
http://lists.openembedded.org/pipermail/openembedded-core/2017-August/141491.html
Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
I've adapted this to make epoll a configure-time option; you must
use --enable-epoll to get the new behavior. I've also confirmed that
it builds both ways and appears to run, and restored the SIGUSR2
functionality (except for the state check) for the epoll case.
Signed-off-by: Seebs <seebs@seebs.net>
|
|
The output from configure with no --prefix is not as explicit as
it should perhaps be about why it's failing and printing a usage
message.
Signed-off-by: Seebs <seebs@seebs.net>
|
|
The sed command for arch_cflags wouldn't work if arch_cflags contained
commas. Changing punctuation just moves the problem elsewhere. Instead,
use backslashes to escape them.
Signed-off-by: Seebs <seebs@seebs.net>
|
|
This is a moderately experimental feature which stores values in an
extended attribute called 'user.pseudo_data' instead of in the database.
Still missing: Database<->filesystem synchronization for this.
For at least some workloads, this can dramatically improve performance.
Signed-off-by: Peter Seebach <peter.seebach@windriver.com>
|
|
A partially-implemented profiler for client time, which basically just
inserts (optional) gettimeofday calls in various places and stashes data
in a flat file containing one data block per pid.
Signed-off-by: Peter Seebach <peter.seebach@windriver.com>
|
|
The (cd $prefix; pwd) only works when the prefix already exists.
Check for prefix existing before doing that.
|
|
This is derived in significant part from contributions to oe-core
by Peter A. Bigot. I reworked the path routine a bit to use an
already duplicated string instead of allocating copies of parts of
it.
The first issue was just that there was a missing antimagic() around
some of the path operations. The second is that we wanted to have
a way to provide a fallback password file which isn't the host's,
but which can be used in the case where the target filesystem hasn't
got a password yet, for bootstrapping purposes. (So there's a minimal
password file that just has root, basically.)
Also, I noticed a design flaw, which is that if you ended up
calling pseudo_pwd_lck_open() twice in a row, the second time
through, pseudo would first check whether it had a path name
for the file (it does), and thus not allocate one, then call
the close routine (which frees it and nulls the pointer), then
open a new one... and not have a file name, so the next attempt
to close it wouldn't unlink the file. This shouldn't ever
come up in real code, but it was bugging me.
Signed-off-by: Peter Seebach <peter.seebach@windriver.com>
|
|
The sqlite flags don't need to be present if they don't have
meaningful values. I think.
|
|
Clean-up: Allow specification of environment hints for subports
scripts, such as whether xattr support is available. Also make
configure guess at a bit width if none is specified.
Signed-off-by: Peter Seebach <peter.seebach@windriver.com>
|
|
Ports can provide pseudo_wrappers.c or portdefs.h, and individual
functions have implementations. These dependencies aren't known until
post-configure. Make the Makefile include two sub-Makefiles which can
be updated by makewrappers.
Signed-off-by: Peter Seebach <peter.seebach@windriver.com>
|
|
In some cases, we'd rather pseudo fail than fall back to using
/etc/passwd or /etc/group. Make the determination of what to fall
back to when neither PSEUDO_PASSWD nor a chroot directory contains
passwd/group files controllable by a configure-time flag, controlled
by --with-passwd-fallback= or --without-passwd-fallback.
|
|
The openembedded build, at least with RPM or SMART, is heavily affected
by the cost of calling fsync or fdatasync on package databases all the
time. Gosh, wouldn't it be nice if we could suppress that without making
dozens of highly intrusive and risky changes into RPM, various database
packages, and so on?
Yes, yes it would. If only there were a program which could intercept
system calls and change their behavior!
Enter --enable-force-async. There are now wrappers for fsync, fdatasync,
and a few related functions. If --enable-force-async is set, these wrappers
instantly return 0, even if PSEUDO_DISABLED is set. And with any luck,
bitbake will now perform a bit better.
Credit for this insight goes to Richard Purdie. I've reimplemented
this to add the configure option, and make the fsync suppression work
even when PSEUDO_DISABLED is set.
|
|
It turns out that file databases don't get very large, and that
sqlite3 can be quite fast with an in-memory database. It also turns
out that dumping the database to disk on exit (or during idle times)
is pretty cheap compared to constant updates.
So: We add "--enable-memory-db", which defaults to on if you have
sqlite 3.7 or later, and off for 3.6 (because 3.6 has horrible
performance with in-memory db on some hosts we tried).
|
|
There's a few circumstances where sqlite's libdir isn't the same as
the directory name we want to use for libpseudo.so, so make it a
separate setting. This may obviate the need for --with-static-sqlite.
Signed-off-by: seebs <peter.seebach@windriver.com>
|
|
It turns out that the -L usage mostly doesn't matter (usually something
else has requested the right directory, or it's the default), but the
explicit path to libsqlite3.a hardcoded "lib", and on some systems
it should be something else, such as "lib64". Solution: Use $(LIB) for
that directory.
Note that this may not resolve things if, say, you're doing MIPS n32 on a
target where that lives in /usr/lib32, but I think in that case you'd
be specifying $libdir, so it should still work out.
Also added --with-static-sqlite=/path as an option in case people need
to further outsmart this.
Signed-off-by: Peter Seebach <peter.seebach@windriver.com>
|
|
Clean up a couple of (harmless, but unsightly) bits of cruft
left from a failed attempt at implementing the ARCH_FLAGS support.
|
|
Pseudo should never have been the one picking -m32/-m64. That should be
coming from the build system in some way. Deprecate --arch, add --cflags.
|
|
Long story short: ARM doesn't use -m32 and -m64, so make those
a little more dependent. We'll probably rework this completely "soon"
as we mess with more targets and x32 becomes an issue.
|
|
The existing behavior was to set rpath to whatever was specified
explicitly with --with-rpath, or to set a default if the opt_rpath
variable was unset and we reached a --with-sqlite.
This turns out to be incorrect in the case where a static sqlite is
being used. You can force the issue with --without-rpath, but it's
probably better to make the inference smarter. This also allows the
slight cleanup of setting opt_rpath to '' to begin with, because we're
no longer depending on the distinction between empty and unset.
|
|
Some systems prefer to avoid messing with LD_LIBRARY_PATH as much,
and instead link sqlite statically.
|
|
In OE-Core we need to be able to configure for both 32-bit and 64-bit
libpseudo libraries. In order to avoid some complex manipulations,
we adjust the configure and Makefile to facilitate this.
Upstream-Status: Submitted
Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
|
|
This is what GNU configure does, for valid reasons. My build wrapper
unconditionally passes --enable-maintainer-mode.
|
|
The way multilib works on at least Fedora is that --libdir=$prefix/lib64
is passed to configure. The source build system should not attempt to
guess at architecture or take other configure flags (like --bits); instead
it should default to whatever the given $(CC) does.
This patch preserves the ability to specify --bits however.
|
|
in one place, but then often reuse them in other project directories.
As a result, the --with-sqlite path is no longer the right path to
use for RPATH later in the program's life. In the past, we were
using chrpath to change the path to something more suitable, but this
doesn't work if the new path is longer.
Instead, allow an explicit --with-rpath setting which our build
system can use. The logic is:
* If you don't specify --with-sqlite or --with-rpath, you get
no -Wl,-R
* If you specify an empty path in --with-rpath, or --without-rpath,
you get no -Wl,-R
* If you specify --with-rpath with a non-empty path, you get
-Wl,-R<path>
* If you specify --with-sqlite, but not --with-rpath, you get
-Wl,-R$(SQLITE)/lib
|
|
CQ: WIND000225366
Pseudo requires functionality in sqlite3 only available in version
3.6.x. The configure script now checks if sqlite headers are installed
and checks that the version is at least 3.6.x.
|
|
|