Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 29 additions & 13 deletions conda/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,40 @@

# Inspired from https://github.com/conda-forge/pyqt-feedstock/tree/main/recipe

if [ "$(uname)" == "Linux" ];
then
USED_BUILD_PREFIX=${BUILD_PREFIX:-${PREFIX}}
if [ "$(uname)" == "Linux" ]; then
# USED_BUILD_PREFIX=${BUILD_PREFIX:-${PREFIX}}

ln -s ${GXX} g++ || true
ln -s ${GCC} gcc || true
ln -s ${USED_BUILD_PREFIX}/bin/${HOST}-gcc-ar gcc-ar || true
# ln -s ${GXX} g++ || true
# ln -s ${GCC} gcc || true
# ln -s ${USED_BUILD_PREFIX}/bin/${HOST}-gcc-ar gcc-ar || true

export LD=${GXX}
export CC=${GCC}
export CXX=${GXX}
export QMAKE_CXX="${CXX}"
export QMAKE_CC="${CC}"
export PKG_CONFIG_EXECUTABLE=$(basename $(which pkg-config))

export PATH=${PWD}:${PATH}
# export PATH=${PWD}:${PATH}
fi

echo "CC=${CC}"
echo "CXX=${CXX}"
echo "GCC=${GCC}"
echo "GXX=${GXX}"

which gcc
which g++

readlink -f "$(which gcc)" || true
readlink -f "$(which g++)" || true
readlink -f "$GCC" || true
readlink -f "$GXX" || true

"${CC}" --version
"${CXX}" --version

"$GXX" -v -E -x c++ /dev/null

echo "**** BUILD"
sip-install --verbose
Expand All @@ -27,14 +45,12 @@ echo "****** CHECK PYTHON LIB"

# To check if Python lib is not in the dependencies with conda-forge distribution.
# See https://github.com/conda-forge/boost-feedstock/issues/81
if [ `uname` = "Darwin" ]; then
otool -L `${PYTHON} -c "import PyQGLViewer as pyqgl ; print(pyqgl.__file__)"`
if [ $(uname) = "Darwin" ]; then
otool -L $(${PYTHON} -c "import PyQGLViewer as pyqgl ; print(pyqgl.__file__)")
fi


if [ "$(uname)" == "Linux" ];
then
ldd `${PYTHON} -c "import PyQGLViewer as pyqgl ; print(pyqgl.__file__)"`
if [ "$(uname)" == "Linux" ]; then
ldd $(${PYTHON} -c "import PyQGLViewer as pyqgl ; print(pyqgl.__file__)")

fi
echo "****** END OF BUILD PROCESS"
7 changes: 4 additions & 3 deletions conda/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,11 @@ build:

requirements:
build:
- {{ compiler('cxx')}}
- {{ compiler('cxx') }}
- {{ stdlib('c') }}
- make # [unix]
- pkg-config # [linux]
- {{ cdt('mesa-libgl-devel') }} # [linux] # match libqglviewer CDT GL strategy
- libgl-devel # [linux] # match libqglviewer CDT GL strategy
# from https://conda-forge.org/docs/maintainer/knowledge_base.html#libgl
- python # [build_platform != target_platform]
- sip # [build_platform != target_platform]
Expand All @@ -39,7 +40,7 @@ requirements:
- sip
- pyqt5-sip
- pyqt-builder
- {{ cdt('mesa-libgl-devel') }} # [linux]
- libgl-devel # [linux]
- libxcb # [linux]
- pthread-stubs # [linux]
- xorg-libxfixes # [linux]
Expand Down
Loading