Re: [PATCH userspace 1/1] CircleCI: do not add Debian-specific parameter when invoking setup.py

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jun 29, 2022 at 3:37 AM Nicolas Iooss <nicolas.iooss@xxxxxxx> wrote:
>
> Runners on https://circleci.com/ use a custom version of Python without
> Debian-specific patches which added option --install-layout=deb. This
> leads to the following error:
>
>     error: option --install-layout not recognized
>
> Fix this by creating a new environment variable dedicated to detect
> CircleCI platform.
>
> Signed-off-by: Nicolas Iooss <nicolas.iooss@xxxxxxx>

Acked-by: James Carter <jwcart2@xxxxxxxxx>

> ---
> Hello,
> Even though the https://github.com/SELinuxProject/selinux is not using CircleCI,
> I have been using it for some years to generate a scan-build output which is
> directly hosted as build artifacts. This commit is about making the CircleCI
> work again.
>
> If you are interested about the results, the "pipeline" I am using is on
> https://app.circleci.com/pipelines/github/fishilico/selinux?filter=all
> and it generates scan-build reports such as
> https://output.circle-artifacts.com/output/job/20523141-5b39-4604-913b-78701e506f2b/artifacts/0/output-scan-build/2022-06-28-220742-7144-1/index.html
>
> Cheers,
> Nicolas
>
>  .circleci/config.yml   | 1 +
>  scripts/run-scan-build | 2 +-
>  2 files changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/.circleci/config.yml b/.circleci/config.yml
> index af20484b9ca5..a75d34c23959 100644
> --- a/.circleci/config.yml
> +++ b/.circleci/config.yml
> @@ -19,6 +19,7 @@ jobs:
>          name: Setup environment variables
>          command: |
>            echo 'export DESTDIR=$HOME/destdir' >> "$BASH_ENV"
> +          echo 'export IS_CIRCLE_CI=1' >> "$BASH_ENV"
>
>      # Download and install refpolicy headers for sepolgen tests
>      - run:
> diff --git a/scripts/run-scan-build b/scripts/run-scan-build
> index fad2a887bc5b..9c3bf0877332 100755
> --- a/scripts/run-scan-build
> +++ b/scripts/run-scan-build
> @@ -24,7 +24,7 @@ export PATH="$DESTDIR/usr/sbin:$DESTDIR/usr/bin:$DESTDIR/sbin:$DESTDIR/bin:$PATH
>  export PYTHONPATH="$DESTDIR$(${PYTHON:-python3} -c "from distutils.sysconfig import *;print(get_python_lib(prefix='/usr'))")"
>  export RUBYLIB="$DESTDIR/$(${RUBY:-ruby} -e 'puts RbConfig::CONFIG["vendorlibdir"]'):$DESTDIR/$(${RUBY:-ruby} -e 'puts RbConfig::CONFIG["vendorarchdir"]')"
>
> -if [ -f /etc/debian_version ]; then
> +if [ -f /etc/debian_version ] && [ -z "${IS_CIRCLE_CI:-}" ] ; then
>      export PYTHON_SETUP_ARGS='--install-layout=deb'
>  fi
>
> --
> 2.36.1
>



[Index of Archives]     [Selinux Refpolicy]     [Linux SGX]     [Fedora Users]     [Fedora Desktop]     [Yosemite Photos]     [Yosemite Camping]     [Yosemite Campsites]     [KDE Users]     [Gnome Users]

  Powered by Linux