summaryrefslogtreecommitdiffstats
path: root/package/pseudo
Commit message (Collapse)AuthorAgeFilesLines
* Globally replace $(HOST_DIR)/usr with $(HOST_DIR)Arnout Vandecappelle2017-07-051-1/+1
| | | | | | | | | | | Since things are no longer installed in $(HOST_DIR)/usr, the callers should also not refer to it. This is a mechanical change with git grep -l '\$(HOST_DIR)/usr' | xargs sed -i 's%\$(HOST_DIR)/usr%$(HOST_DIR)%g' Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* Globally replace $(HOST_DIR)/usr/lib with $(HOST_DIR)/libArnout Vandecappelle2017-07-051-2/+2
| | | | | | | | | | | Since things are no longer installed in $(HOST_DIR)/usr, the callers should also not refer to it. This is a mechanical change with git grep -l '$(HOST_DIR)/usr/lib' | xargs sed -i 's%$(HOST_DIR)/usr/lib%$(HOST_DIR)/lib%g' Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* boot, package: use SPDX short identifier for LGPLv2.1/LGPLv2.1+Rahul Bedarkar2017-04-011-1/+1
| | | | | | | | | | | We want to use SPDX identifier for license string as much as possible. SPDX short identifier for LGPLv2.1/LGPLv2.1+ is LGPL-2.1/LGPL-2.1+. This change is done using following command. find . -name "*.mk" | xargs sed -ri '/LICENSE( )?[\+:]?=/s/LGPLv2.1(\+)?/LGPL-2.1\1/g' Signed-off-by: Rahul Bedarkar <rahulbedarkar89@gmail.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* Revert "package/pseudo: add a legacy symlink to emulate fakeroot"Peter Korsgaard2016-11-271-5/+0
| | | | | | This reverts commit 7158403805f650e8e34de6c0ac0dcd9b565c679b. Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* Revert "package/pseudo: wrap the real pseudo with a wrapper"Peter Korsgaard2016-11-272-18/+0
| | | | | | This reverts commit a1d602a74d53f5610852c1763014632de145bf8b. Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* Revert "package/pseudo: provide better legacy handling for fakeroot"Peter Korsgaard2016-11-272-9/+2
| | | | | | This reverts commit 499f28fc7ce6184c8017ccd229ffc973a520adde. Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
* package/pseudo: provide better legacy handling for fakerootYann E. MORIN2016-11-092-2/+9
| | | | | | | | | | | | | | | | | | | | | We now have a wrapper that makes pseudo behaves like the fakeroot of the good ol' days. So the symlink will just magically keep old scripts working as they did before the switch to pseudo. However, using fakeroot is deprecated, and we want people to stop using it altogether and switch to pseudo. So, make the wrapper recognise how it's called, and if called as fakeroot, print a warning message. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Gaël PORTAY <gael.portay@savoirfairelinux.com> Cc: Patrick Keroulas <patrick.keroulas@savoirfairelinux.com> Cc: Erico Nunes <nunes.erico@gmail.com> Cc: Julien BOIBESSOT <julien.boibessot@free.fr> Cc: Arnout Vandecappelle <arnout@mind.be> Reviewed-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* package/pseudo: wrap the real pseudo with a wrapperYann E. MORIN2016-11-092-0/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Running pseudo is more involved than running fakeroot. In the transition from using fakeroot, we just did not account for the extra requirements. First, we explicitly tell pseudo where it is, otherwise it tries to guess. Its guess is correct, but it prints a warning, which is not nice. Second, we tell it where to find the passwd and group files in case it has to emulate access to them. We currently do not use that feature, but better safe than sorry. Third, pseudo spawns a background daemon, and talks to it (when fakeroot would emulate the state all in the current process' state, pseudo uses the daemon to coordinate the state across multiple processes). We are not much interested in the daemon lingering around, so we just tell it to terminate as soon as the last clients quits (this can take up to one second). Fourth and last, pseudo always stores its internal database when exiting, and reloads it when spawned. The database is by default stored in a sub-directory of the prefix it was installed in, but this is impractical for us. We want the database to be specific to the one config dir we are building, so we store the database in a (hidden) sub-dir of the build dir, thus ensuring it is never shared with another build. That directory is hidden (starts with a dot) because we consider that to be our internal state that we do not want to expose to the user. The wrapper has to be relocatable, so we avoid using hard-coded paths in there: we derive those paths fom the runtime path of pseudo. However, the build directory $(BUILD_DIR) is not available in the environment (we do not export it because it conflicts with some buildsystems). Instead, we use $(BASE_DIR) which is exported. Finally, when relocated, the wrapper would not be used in the Buildroot environment, so may not have access to TARGET_DIR or BASE_DIR, unless the user sets them. If he does not, we still want the wrapper to be working (to avoid the warning about the prefix, and to exit the daemon asap); thus we leave the passwd and localstatedir variable alone if we don't have what it needs to set them, rather than set them to incorrect values. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Gaël PORTAY <gael.portay@savoirfairelinux.com> Cc: Patrick Keroulas <patrick.keroulas@savoirfairelinux.com> Cc: Erico Nunes <nunes.erico@gmail.com> Cc: Julien BOIBESSOT <julien.boibessot@free.fr> Cc: Arnout Vandecappelle <arnout@mind.be> Reviewed-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* package/pseudo: force rpath and pass our host CFLAGSYann E. MORIN2016-11-091-0/+5
| | | | | | | | | | | | | | | | | | | pseudo whines when those are not set, and tries to find a suitable value; this is usually correct but risk an incorrect guess in corner cases. Rather than leaving those in guess-mode, just force them to values we know are correct. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Gaël PORTAY <gael.portay@savoirfairelinux.com> Cc: Patrick Keroulas <patrick.keroulas@savoirfairelinux.com> Cc: Erico Nunes <nunes.erico@gmail.com> Cc: Julien BOIBESSOT <julien.boibessot@free.fr> Cc: Arnout Vandecappelle <arnout@mind.be> Reviewed-by: Arnout Vandecappelle <arnout@mind.be> [Thomas: use double quotes instead of single quotes.] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* package/pseudo: enforce the host bitnessYann E. MORIN2016-11-091-0/+1
| | | | | | | | | | | | | | | | | | | | pseudo can detect the host bitness, but is not sure about it: it checks what type of file /bin/sh is, using file(1). However, in some conditions, /bin/sh can be of a different bitness than the rest of the system (weird, but not impossible), which causes build issues. Just enforce the bitness, so that pseudo needs not (wrongly) guess it. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Gaël PORTAY <gael.portay@savoirfairelinux.com> Cc: Patrick Keroulas <patrick.keroulas@savoirfairelinux.com> Cc: Erico Nunes <nunes.erico@gmail.com> Cc: Julien BOIBESSOT <julien.boibessot@free.fr> Cc: Arnout Vandecappelle <arnout@mind.be> Reviewed-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* package/pseudo: update versionYann E. MORIN2016-11-052-2/+2
| | | | | | | Brings in a fix about externded attributes (xattrs). Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* packages/pseudo: needs attrYann E. MORIN2016-11-051-1/+1
| | | | | | | | This fixes the build on machines that do not have attr development files installed. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* pseudo: fix build for python3 based distrosGaël PORTAY2016-11-053-0/+510
| | | | | | | | | | | | | | | | | | | | | | | | | Pseudo is not python3 friendly. It causes build failure on distros using python3 as default python interpretor. ./maketables enums/*.in File "./makewrappers", line 327 return """/* This function is not called if pseudo is configured --enable-force-async */ ^ TabError: inconsistent use of tabs and spaces in indentation File "./maketables", line 76 print "Flags: set for %s" % self.name ^ SyntaxError: Missing parentheses in call to 'print' make[2]: *** [Makefile:150: wrappers] Error 1 make[2]: *** Waiting for unfinished jobs.... make[2]: *** [Makefile:147: tables] Error 1 Those patches make pseudo works with python2 and python3. Signed-off-by: Gaël PORTAY <gael.portay@savoirfairelinux.com> Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Tested-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* package/pseudo: add a legacy symlink to emulate fakerootYann E. MORIN2016-11-031-0/+5
| | | | | | | | | In case some post-image script want to call fakeroot, add a symlink to use pseudo instead. Reported-by: Arnout Vandecappelle <arnout@mind.be> Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* package/pseudo: needs sqliteYann E. MORIN2016-11-031-0/+8
| | | | | | | | pseudo uses sqlite to store its state. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> [Thomas: add comment about --libdir.] Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
* package/pseudo: new packageYann E. MORIN2016-11-032-0/+17
Pseudo is a program that can either be used directly or as an LD_PRELOAD, which allows these operations to succeed as if the user did have system administrator privileges even though they are an ordinary user. Pseudo has a lot of similarities to fakeroot but is a new implementation that improves on the problems seen using fakeroot. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Cc: Andrey Yurovsky <yurovsky@gmail.com> Cc: Gustavo Zacarias <gustavo@zacarias.com.ar> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
OpenPOWER on IntegriCloud