source: libcaca/trunk/build-win32 @ 892

Last change on this file since 892 was 867, checked in by Sam Hocevar, 15 years ago
  • Removed my previously introduced --enable-pangoft2 and replaced it with a nicer cross compilation check.
  • Property svn:executable set to *
  • Property svn:keywords set to Id
File size: 1.2 KB
Line 
1#! /bin/sh
2
3##  Win32 cross-compilation for libcaca -- Sam Hocevar <sam@zoy.org>
4##  $Id: build-win32 867 2006-04-24 22:10:38Z sam $
5
6set -x
7set -e
8
9# Clean up our working directory
10DIRNAME="libcaca-win32-`sed -ne '/^VERSION/s/[^0-9]*//p' Makefile`"
11DESTDIR="`pwd`/${DIRNAME}"
12rm -Rf "${DIRNAME}"
13rm -f "${DIRNAME}.zip"
14mkdir "${DIRNAME}"
15
16# Build for win32
17./configure --host=i586-mingw32msvc --prefix=/ --bindir=/bin --libdir=/lib --disable-imlib2 --disable-doc
18make pkglibdir=/lib pkgdatadir=/data bindir=/bin
19
20# Install into our private directory
21make install DESTDIR="${DESTDIR}" pkglibdir=/lib/ pkgdatadir=/ bindir=/bin/
22
23mv "${DESTDIR}/bin/"* "${DESTDIR}/"
24mv "${DESTDIR}/lib/"* "${DESTDIR}/"
25i586-mingw32msvc-strip "${DESTDIR}/"*.exe
26i586-mingw32msvc-strip "${DESTDIR}/"*.dll
27rmdir "${DESTDIR}/bin"
28rmdir "${DESTDIR}/lib"
29
30mkdir "${DESTDIR}/doc"
31for f in COPYING COPYING.LGPL COPYING.GPL README AUTHORS NEWS NOTES THANKS TODO; do
32   sed -e 's/$/ /' < "${f}" > "${DESTDIR}/doc/${f}.txt"
33done
34rm -Rf "${DESTDIR}/share"
35rm -Rf "${DESTDIR}/man"
36rm -Rf "${DESTDIR}/include"
37rm -f "${DESTDIR}/caca-config"
38rm -f "${DESTDIR}/"*.a
39rm -f "${DESTDIR}/"*.la
40
41# Pack the directory
42zip "${DIRNAME}.zip" `find "${DIRNAME}"`
43rm -Rf "${DIRNAME}"
44
Note: See TracBrowser for help on using the repository browser.