Complete.Org: Mailing Lists: Archives: freeciv-dev: February 2003:
[Freeciv-Dev] (PR#2425) Civ Fehler unter Solaris
Home

[Freeciv-Dev] (PR#2425) Civ Fehler unter Solaris

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: rf13@xxxxxxxxxxxxxxxxx, Lew Palm <lpalm@xxxxxxxxxxxxxxxxxxxxxxxx>, lpalm@xxxxxxxxxxxxxxxxxxxxxxxx
Cc: freeciv-dev@xxxxxxxxxxx
Subject: [Freeciv-Dev] (PR#2425) Civ Fehler unter Solaris
From: "Reinier Post via RT" <rt@xxxxxxxxxxxxxx>
Date: Tue, 4 Feb 2003 08:42:30 -0800
Reply-to: rt.freeciv.org@xxxxxxxxxxxxxx

I assume that the problem has been solved somehow.  I'll set its status 
to "stalled".  The problem is noty Freeciv specific as far as I'm aware 
and I don't think anything in the Freeciv autoconf support will fix 
this.

If it was indeed a $LD_LIBRARY_PATH related problem perhaps the
following generic solution is helpful.

(Note that you have to do this on all software you compile (including
libraries used by other software) in order to get rid of the need to 
set $LD_LIBRARY_PATH at runtime.)

Before ./configure-ing your software set the $CC environment variable 
to "adding-R cc".  This is assuming the attached script is called 
adding-R and is in your path and that your regular compiler is called 
cc.  You can use gcc as well.)

The script is simply a wrapper that calls cc and adds -R arguments 
whenever a -L argument appears on the command line.




#!/usr/bin/env perl
#
# adding-R - script to fix linker commands on Solaris
#
# $Id: adding-R,v 1.1 2002/02/21 16:27:09 rp Exp $

# Usage: adding-R [whatever the original command line was]

# turn -L arg into -L arg -R arg
for (my $i = 0; $i < $#ARGV; ++$i)
{
  if ($ARGV[$i] eq '-L')
  {
    splice(@ARGV,$i+2,0,('-R',$ARGV[$i+1]));
    $i += 2;
  }
}
# turn -Larg into -Larg -Rarg
exec map { /^-L(.)/ ? ($_,"-R$1$'") : $_ } @ARGV;

[Prev in Thread] Current Thread [Next in Thread]
  • [Freeciv-Dev] (PR#2425) Civ Fehler unter Solaris, Reinier Post via RT <=