Show
Ignore:
Timestamp:
01.08.2017 22:18:10 (2 years ago)
Author:
ak19
Message:

Documented the changes required to compile wget-1.19-gs. But it fails compilation on darwin.

Location:
main/trunk/greenstone2/build-src/packages
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone2/build-src/packages/configure

    r31836 r31840  
    284284#wget_pkgname=wget-1.15-gs 
    285285wget_pkgname=wget-1.17.1-gs 
     286#wget_pkgname=wget-1.19-gs 
    286287echo "" 
    287288echo "Configuring wget" 
     
    315316##CPPFLAGS="-I$PACKAGES/openssl/include $CPPFLAGS" LDFLAGS="-L$PACKAGES/openssl/lib $LDFLAGS" ./configure $CACHE_FILE --prefix=$PACKAGES/wget --with-ssl=openssl --bindir="$bindir" -disable-nls $HOSTTARGETFLAGS $wget_extraargs 
    316317 
    317 # for wget-1.17.1-gs. (can also try adding --localstatedir="$bindir/wget" --enable-iri) 
     318# for wget-1.17.1-gs and wget-1.19-gs (can also try adding --localstatedir="$bindir/wget" --enable-iri) 
    318319echo OPENSSL_CFLAGS="-I$PACKAGES/openssl/include" OPENSSL_LIBS="-L$PACKAGES/openssl/lib -lssl -lcrypto" ./configure $CACHE_FILE --prefix=$PACKAGES/wget --with-ssl=openssl --with-openssl=auto --with-libssl-prefix="$PACKAGES/openssl" --bindir="$bindir" -disable-nls $HOSTTARGETFLAGS $wget_extraargs 
    319320cd "$PACKAGES/wget/$wget_pkgname" && \ 
  • main/trunk/greenstone2/build-src/packages/wget/README

    r31837 r31840  
    79798) 2017/07/27 - ak19 (anupama.krishnan@waikato.ac.nz) - still using wget version 1.15, but now compiling wget up with OpenSSL support. Wget needs SSL support in order for it to access pages over HTTPS. In future, the web will be using https. 
    8080 
    81 We're now compiling up OpenSSL during the configuration phase since wget needs it to exist during its configure phase. We're building OpenSSL statically, by setting the no-shared flag. The built OpenSSL gets put into gs2build/linux|darwin/openssl, containing lib, include and bin subfolders. When configuring wget, we build wget against our OpenSSl, and make and make install proceed as normal. Refer to gs2build/build-src/packages configure. 
    82  
     81Downloaded OpenSSL version 1.0.2l downloaded from https://www.openssl.org/source/ 
     82We're now compiling up OpenSSL during the configuration phase since wget needs it to exist during its configure phase. We're building OpenSSL statically, by setting the no-shared flag. Since OpenSSL is being statically built, we don't need to ship its lib, bin and include folders with GS, since wget will be compiled and linked against our static openSSL, producing a wget binary independent of OpenSSL. The built OpenSSL now just gets put into gs2build/build-src/packages/openssl too, along with other openSSL subfolders generated when compiling openSSL. 
     83 
     84When configuring wget, we build wget against our OpenSSl, and make and make install proceed as normal. Refer to gs2build/build-src/packages configure. 
    8385We weren't compiling up wget statically before either, so we're still not doing so. But if that will be necessary in future, see the section on COMPILING WGET UP STATICALLY further below. 
    8486 
     
    99101 
    100102The wget 1.11.4 we have, compiled without SSL does not work on https pages. 
    101 Neither does the wget from http://nebm.ist.utl.pt/~glopes/wget/, even after including the --no-check-certificate flag in the wget command. So we'll need to upgrade the wget binary on Windows to a later version too. 
     103Neither does the wget from http://nebm.ist.utl.pt/~glopes/wget/, even after including the --no-check-certificate flag in the wget command. So we'll need to upgrade the wget binary on Windows to a later version too. See the section WINDOWS WGET BINARIES WITH OPENSSL SUPPORT 
    102104 
    103105 
     
    108110LINUX CHANGES: 
    109111- Grabbed wget-1.17.1.tar.gz from https://ftp.gnu.org/gnu/wget/ 
    110 - Made the modifications in steps 5 and 6 above and re-tarred as wget-1.17.1-gs.tar.gz, with corresponding changes in build-src/packages' configure, Makefile.in and Makefile 
     112- Made the modifications in steps 5 and 6 above 
     113- To be compatible with the version of pod2man doc generation tool installed on LSB release-kit machines, can't pass the new --utf8 flag to it. Changed doc/Makefile.in and doc/Makefile.am from: 
     114  $(POD2MAN) --center="GNU Wget" --release="GNU Wget @VERSION@" --utf8 $? > $@ 
     115changed to 
     116  $(POD2MAN) --center="GNU Wget" --release="GNU Wget @VERSION@" $? > $@ 
     117- Then re-tarred as wget-1.17.1-gs.tar.gz, with corresponding changes in build-src/packages' configure, Makefile.in and Makefile 
    111118- The configure step has now changed for wget v 1.17.1. Refer to build-src/packages/configure 
    112119 
     
    114121* --with-libssl-prefix to $bindir/openssl, so the wget build process can find openssl's include and lib folders. (Whereas the --with-ssl indicates what type of ssl we're using, which is openssl in our case.) 
    115122* configuring had initially failed, reporting that OPENSSL_CFLAGS and OPENSSL_LIBS need to be set if not wanting to use whatever pkg-config may find. To set LIBS variables, use one of these forms: LIBS="-L/path/to/lib" or LIBS="/path/to/lib/lib.a" or LIBS="-lssl". To combine all three, separate with spaces. See http://trac.greenstone.org/changeset/30948 and https://github.com/tatsuhiro-t/spdylay/issues/43 
     123 
     124 
     125________________________________ 
     126    FURTHER INFO 
     127________________________________ 
     128 
     129SHIFTING TO WGET 1.19 
     130Wget 1.19 doesn't yet compile on Mac, but it works on Linux. 
     131Shifting to wget-1.19 requires only steps 5 and 6 to be applied to get wget-1.19-gs. This new version of wget takes care of the pod2man issue on our LSB release-kit environment without requiring the additional edits seen in (9) above. 
    116132 
    117133PROBLEM AND SOLUTION WITH WGETRC 
     
    175191 
    176192 
    177  
    178  
    179193TO DO: 
    180194+ If I delete the gs2build/bin/linux/openssl folder, the built wget still works fine without it. Dr Bainbridge confirmed that this is because, wget is built against OpenSSL's static libraries and therefore no longer needs the OpenSSL stuff we build and have been putting into gs2build/bin/linux/openssl. So we no longer need to put the built OpenSSL there.