#!/bin/bash
#
# This script is used to cross-compile to a CGI-program "winhelpcgi.cgi"
# on a linux host targeting Sun Solaris
#
# (C) 2003 Herd Software Development http://www.herdsoft.com/
# This program is free software; you can redistribute it and/or    
# modify it under the terms of the GNU General Public License as   
# published by the Free Software Foundation; either version 2 of   
# the License.              
#                                                                  
# This program is distributed in the hope that it will be useful,  
# but WITHOUT ANY WARRANTY; without even the implied warranty of   
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the    
# GNU General Public License for more details.                     
#                                                                  
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software      
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.        
# 

# Set Variables defining what we want to do.
target=powerpc-linux
prefix=/opt/cross/$target

# Remove old "configure" temp files from other target platforms
rm -f config.cache config.log config.status libhlpaccess/libhlpaccess.a


export AR=$target-ar
export CC=$target-gcc
export LD=$target-ld
export RANLIB=$target-ranlib

./configure \
   --target=$target \
   --prefix=$prefix

make \
  AR=$AR \
  LDFLAGS=-s \
  clean all 

