openSUSE / open-build-service

Build and distribute Linux packages from sources in an automatic, consistent and reproducible way #obs
https://openbuildservice.org
GNU General Public License v2.0
932 stars 438 forks source link

Sudo fails while building for ArchLinux #1329

Closed copyme closed 8 years ago

copyme commented 8 years ago

I cannot build packages on ArchExtra via OBS because of sudo problems:

[ 138s] sudo: no tty present and no askpass program specified [ 138s] ==> ERROR: 'pacman' failed to install missing dependencies.

My project: https://build.opensuse.org/package/show/home:copyme:DGtal/DGtal

adrianschroeter commented 8 years ago
  1. This is not an OBS code problem, but a config decision
  2. The default config of all distros in build.opensuse.org is not allowing to run sudo
adrianschroeter commented 8 years ago

also, you would not have network access at all inside of the build environent. It would be a security issue and contradicts the idea of having reproducable builds.

copyme commented 8 years ago

@adrianschroeter Wait, even sudo is prohibited (which seems fair), there must be a way to resolve dependencies. It works for openSUSE, Fedora, etc. All my deps are in Extra.

adrianschroeter commented 8 years ago

you need to write dependencies into your build description, the PKGBUILD file in the depends= or makedepends= line. OBS will parse that line and install the required packages to build env.

copyme commented 8 years ago

@adrianschroeter I have that. Nevertheless after sometime I've re-trigged rebuild and there was no problem any more. Thanks.