Skip to content

tar failed when generate capi package #7254

Closed
@tensor-tang

Description

@tensor-tang

When I use paddle/scripts/docker/build.sh to generate c-api package, it crashed at tar.

+ cd /paddle/build/capi_output/usr/local
+ ls
+ egrep -v '^Found.*item$'
+ xargs tar /paddle/build/paddle.tgz
tar: invalid option -- '/'

This error is also encountered here.

The reason that #7237 passed the PR_CI is that WITH_C_API was disabled, so it did not actually run into function gen_capi_package.

As teamcity build log 9644 for #7237 shows:

+ gen_capi_package
[07:19:56]W: [Step 1/1] + [[ '' == \O\N ]]
[07:19:56]W: [Step 1/1] + [[ OFF == \O\N ]]
[07:19:56]W: [Step 1/1] + printf 'If you need to install PaddlePaddle in de
velop docker image,'
[07:19:56]W: [Step 1/1] + printf 'please make install or pip install build/python/dist/.whl.\n'
[07:19:56] : [Step 1/1] If you need to install PaddlePaddle in develop docker image,please make install or pip install build/python/dist/
.whl.
[07:19:56] : [Step 1/1]

how to reproduce this issue:

use below script:

#!/bin/bash
set -xe
export PADDLE_DEV_NAME="paddlepaddle/paddle:latest-dev"
docker run -i --rm -v $PWD:/paddle ${PADDLE_DEV_NAME} \
  rm -rf /paddle/build
docker run  -i --rm -v $PWD:/paddle \
  -e "WITH_PYTHON=OFF" \
  -e "WITH_SWIG_PY=OFF" \
  -e "WITH_PYTHON=OFF" \
  -e "WITH_C_API=ON" \
  -e "WITH_GPU=OFF" \
  -e "WITH_AVX=ON" \
  -e "WITH_MKL=ON" \
  -e "WITH_STYLE_CHECK=OFF" \
  ${PADDLE_DEV_NAME} \
  bash -x /paddle/paddle/scripts/docker/build.sh

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions