linuxserver / docker-baseimage-guacgui

GNU General Public License v3.0
99 stars 52 forks source link

Error "Illegal option" during build #27

Closed tradmangh closed 2 years ago

tradmangh commented 4 years ago

linuxserver.io

docker build stops with error "/bin/sh: 0: Illegal option -" at Line 42 of the Dockerfile /bin/list-dependencies.sh "${BUILD_DIR}src/guacd/.libs/guacd" $(find ${BUILD_DIR} | grep "so$") > ${BUILD_DIR}/doc-pak/DEPENDENCIES caused by a grep "segmentation fault"


Expected Behavior

Docker build should create a docker container based on the docker file provided at linuxserver/docker-base-image-guacgui

Current Behavior

Error during build: /bin/sh: 0: Illegal option - The command '/bin/sh -c echo "**** install build deps ****" && apt-get update && apt-get install -qy --no-install-recommends checkinstall curl $BUILD_DEPENDENCIES && echo "**** prep build ****" && mkdir ${BUILD_DIR} && ln -sf /usr/bin/gcc-6 /usr/bin/gcc && curl -o /tmp/guacd.tar.gz -s -L "https://sourceforge.net/projects/guacamole/files/current/source/guacamole-server-${GUAC_VER}.tar.gz" && tar -xf /tmp/guacd.tar.gz --strip=1 -C ${BUILD_DIR} && echo "**** build guacd ****" && cd ${BUILD_DIR} && ./configure --with-init-dir=/etc/init.d --prefix=/usr && make -j 2 CC=gcc-6 && mkdir ${BUILD_DIR}/doc-pak && /bin/list-dependencies.sh "${BUILD_DIR}src/guacd/.libs/guacd" $(find ${BUILD_DIR} | grep "so$") > ${BUILD_DIR}/doc-pak/DEPENDENCIES && PREFIX=/usr checkinstall -y -D --nodoc--pkgname ${PKG_NAME} --pkgversion ${GUAC_VER} --pakdir /tmp --exclude "/usr/share/man","/usr/include","/etc" && mv /tmp/${PKG_NAME}_${GUAC_VER}-*.deb /tmp/${PKG_NAME}_${GUAC_VER}.deb' returned a non-zero code: 2

Steps to Reproduce

  1. Install Docker Desktop for Windows
  2. docker build https://github.com/linuxserver/docker-baseimage-guacgui.git

Environment

OS: Windows 10 CPU architecture: x86_64 How docker service was installed: Docker Desktop

Command used to create docker container (run/create/compose/screenshot)

docker build https://github.com/linuxserver/docker-baseimage-guacgui.git

Docker logs

github-actions[bot] commented 4 years ago

Thanks for opening your first issue here! Be sure to follow the issue template!

aptalca commented 4 years ago

Here's our ci build from yesterday: https://ci.linuxserver.io/blue/organizations/jenkins/Docker-BaseImages%2Fdocker-baseimage-guacgui/detail/master/180/pipeline/122

github-actions[bot] commented 4 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

iwm911 commented 3 years ago

Hi,

i actually encountered the same issue when trying to build the container.

apparently the /bin/list-dependencies.sh shebang contains a -e switch which cause the error above.

removing the -e switch solved the issue for me and i was able to build the image.

github-actions[bot] commented 3 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.