source: gs2-extensions/rsync/trunk/src/setup.bash@ 23874

Last change on this file since 23874 was 23874, checked in by davidb, 13 years ago

Mods to set CFLAGS necessary for MinGW/Mini-Unix

File size: 1.2 KB
RevLine 
[23871]1
2extdesc="the Rsync Extension"
3
4full_setup=`pwd`/${BASH_SOURCE}
5fulldir=${full_setup%/*}
6fulldir=${fulldir%/.}
7
8if [ "x$GSDLHOME" = "x" ] ; then
9 if [ -e ../../setup.bash ] ; then
10 export gsopt_noexts=1 && pushd ../.. && source setup.bash && popd
11 export gsopt_noexts=
12 fi
13fi
14
15if [ "x$GEXTRSYNC" = "x" ] ; then
[23874]16
17 export RSYNCOS=`uname -s | tr '[A-Z]' '[a-z]' | sed 's/\([0-9]\+\)\?_.*$//'`
18
19 if [ $RSYNCOS = "mingw" ] ; then
20 MINGW_CFLAGS="-Duint16_t=u_int16_t -Duint32_t=u_int32_t -Duint64_t=u_int64_t -Doff64_t=u_int64_t"
21
22 if [ "x$CFLAGS" = "x" ] ; then
23 export CFLAGS="$MINGW_CFLAGS"
24 else
25 export CFLAGS="$CFLAGS $MINGW_CFLAGS"
26 fi
27 fi
28
29
[23871]30 export GEXTRSYNC=$fulldir
31 export GEXTRSYNC_INSTALLED=$GEXTRSYNC/$GSDLOS
32
33 export PATH=$GEXTRSYNC_INSTALLED/bin:$PATH
34
35 if [ "x$LD_LIBRARY_PATH" = "x" ] ; then
36 export LD_LIBRARY_PATH=$GEXTRSYNC_INSTALLED/lib
37 else
38 export LD_LIBRARY_PATH=$GEXTRSYNC_INSTALLED/lib:$LD_LIBRARY_PATH
39 fi
40
41 extdir=${GEXTRSYNC##*/}
42
43 if [ "x$GSDLEXTS" = "x" ] ; then
44 export GSDLEXTS=$extdir
45 else
46 export GSDLEXTS=$GSDLEXTS:$extdir
47 fi
48
49 echo "+Your environment is now setup for $extdesc to Greenstone"
50else
51 echo "+Your environment is already setup for $extdesc to Greenstone"
52fi
53
54
Note: See TracBrowser for help on using the repository browser.