source: gs2-extensions/gnome-lib/branches/macos-dev/src/packages/CASCADE-MAKE/GLIB.sh@ 34550

Last change on this file since 34550 was 34550, checked in by ak19, 3 years ago

Can't assume PCRE is already installed on the system, and it needs to be compile before GLIB. Also found PCRE has to be configured with unicode support on. Some additional tweaking CFLAG/LDFLAG and associated environment variables needed to GLIB could see the cascade-make compiles libffi and libpcre

  • Property svn:executable set to *
File size: 2.8 KB
Line 
1#!/bin/bash
2
3# glib2.28.1 was modified for Greenstone to allow compilation to succed on a Mac, so it has acquired a 'gs-' prefix
4# More recently compiling on Macrocarpa (MacOS) newer compilation errors were encountered,
5# prompting a signficant bump up in version number
6
7#package=gs-glib
8package=glib
9#version=-2.24.2
10#version=-2.28.1
11##version=-2.34.3
12version=-2.54.3
13
14progname=$0
15
16source ../cascade-make/lib/cascade-lib.bash GEXTGNOME ../.. $*
17
18prefix=$GEXTGNOME_INSTALLED
19
20export CFLAGS="$CFLAGS -I$GEXTGNOME_INSTALLED/include"
21export CPPFLAGS="$CPPFLAGS -I$GEXTGNOME_INSTALLED/include"
22export CXXFLAGS="$CXXFLAGS -I$GEXTGNOME_INSTALLED/include"
23export LDFLAGS="$LDFLAGS -L$GEXTGNOME_INSTALLED/lib"
24
25export LIBFFI_CFLAGS="-I$GEXTGNOME_INSTALLED/lib/libffi-3.0.11/include"
26export LIBFFI_LIBS="-L$GEXTGNOME_INSTALLED/lib -lffi"
27
28export PCRE_CFLAGS="-I$GEXTGNOME_INSTALLED/include"
29export PCRE_LIBS="-L$GEXTGNOME_INSTALLED/lib -lpcre"
30
31if [ "x$crossOS" = "xandroid" ] ; then
32 # Based on details found at:
33 # http://axcoto.com/blog/article/836
34 extra_config_args="glib_cv_stack_grows=${glib_cv_stack_grows=no} glib_cv_uscore=${glib_cv_uscore=no} ac_cv_func_posix_getpwuid_r=${ac_cv_func_posix_getpwuid_r=no} ac_cv_func_posix_getgrgid_r=${ac_cv_func_posix_getgrgid_r=no}"
35
36 # Not clear how many of the following are needed.
37 # List came from:
38 # https://mail.gnome.org/archives/gtk-devel-list/2011-March/msg00096.html
39 #
40 # Could be that some of these are helpful in general (i.e. move out to
41 # main section of this script) in making a more minimal glib
42
43 extra_config_args="--without-included-regex --disable-java --disable-openmp --without-libiconv-prefix --without-libintl-prefix --without-libglib-2.0-prefix --without-libcroco-0.6-prefix --with-included-libxml --without-libncurses-prefix --without-libtermcap-prefix --without-libcurses-prefix --without-libexpat-prefix --without-emacs $extra_config_args"
44
45
46else
47 extra_config_args=
48fi
49
50opt_run_untar $force_untar $auto_untar $package $version
51opt_run_configure $force_config $auto_config $package $version $prefix \
52 --disable-shared --enable-static --disable-dtrace --disable-systemtap $extra_config_args
53
54# In the above ...
55# Linking error can occur when compiling due to mix of wanting static libraries built
56# and 'dtrace' and 'systemtap' being present on the underlying linux system
57# Details relating to the linking error disucssed at:
58# https://gitlab.gnome.org/GNOME/glib/issues/653
59# Since we don't want to move to a newer version of the the gslib library (at this stage)
60# the workaround is to add in:
61# --disable-dtrace and --disable-systemtap in
62
63opt_run_make $compile $package $version
64opt_run_make $install $package $version "install"
65opt_run_make $clean $package $version "clean"
66opt_run_make $distclean $package $version "distclean"
67
68opt_run_tarclean $tarclean $package $version
Note: See TracBrowser for help on using the repository browser.