File: configure.ucrt

package info (click to toggle)
r-bioc-rhdf5lib 1.28.0%2Bdfsg-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 400 kB
  • sloc: sh: 79; ansic: 40; makefile: 7
file content (32 lines) | stat: -rwxr-xr-x 857 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#!/bin/sh

ARCH=`$R_HOME/bin/Rscript --no-echo -e 'cat(R.version$arch)'`

if [ X$ARCH == Xx86_64 ] ; then
  #untar the lib
  BASEPBNAME="hdf5"
  PBTGZNAME=hdf5_headers_1.10.7.tar.gz
  cd src
  if test -d ${BASEPBNAME}; then 
	echo 'found ' $BASEPBNAME ' header sources; using what is there.'
  else
	echo "untarring $PBTGZNAME ...";
	## we'll use Rscript to untar the file
	"${R_HOME}/bin${R_ARCH_BIN}/Rscript.exe" -e "untar('wininclude/$PBTGZNAME')"
  fi
else
  if which lld >/dev/null 2>/dev/null ; then
    ./configure LD=lld CPPFLAGS=-Wno-implicit-function-declaration $*
  else
    ./configure $*
  fi

  cp src/Makevars src/Makevars.ucrt
  if which lld >/dev/null ; then
    sed -i -e 's!LDFLAGS=!LD=lld \0!g' \
	   -e "s!CPPFLAGS='!CPPFLAGS='-Wno-implicit-function-declaration!g" \
	   -e 's!PKG_LIBS = .*!\0 -ldl!g' \
	   src/Makevars.ucrt
  fi
fi