LSTSRV-L Archives

LISTSERV Site Administrators' Forum

LSTSRV-L

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Topic: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Fri, 1 Dec 2006 14:39:50 -0600
text/plain (70 lines)
First, my thanks and apologies for the series of e-mails this morning  
to the list. I think I've gotten past whatever the issue was this  
morning and that success is only because of the kind and rapid  
responses from people here.

I am attempting to compile on Solaris 9 with unixODBC support using  
gcc. Here are the options in my Makefile:

CC=/usr/local/bin/gcc
CFLAGS=-O -L/opt/unixODBC/lib -L/opt/gnu/lib -R/opt/unixODBC/lib -R/ 
opt/gnu/lib
BINDIR=/opt/listserv/bin
LSVROOT=/opt/listserv
LSVSPOOL=/var/spool/listserv
LSVNAME=listserv
ALIASES=/etc/aliases
LSVAMIN_TYPE=paths
CGIDIR=/opt/listserv
WHOAMI=/usr/ucb/whoami
CFLAGS_Solaris=-lsocket -lnsl nooci.o -lodbc


As near as I can tell, the problems I am having are with links to  
libgcc_s.so and libodbc.so (in /opt/gnu/lib and /opt/unixODBC,  
respectively).

I have successfully compiled with LD_LIBRARY_PATH set to include the  
unixODBC and gnu libraries but when running lsv_amin (and I assume  
the other binaries) as the listserv user--who does not have that env  
variable set--I get a fatal error as the library cannot be located.  
ldd indicates as much when LD_LIB_PATH is unset:
	libodbc.so.1 =>         (file not found)
         libgcc_s.so.1 =>         (file not found)

When compiling with CFLAGS set as above, I am getting
> ld: fatal: library -lodbc: not found
> ld: fatal: File processing errors. No output written to lsv
> collect2: ld returned 1 exit status
> *** Error code 1
> make: Fatal error: Command failed for target `lsv_prog'
> Current working directory /home/src/oss/listserv/listserv15.0a
> *** Error code 1
> make: Fatal error: Command failed for target `lsv'
When attempting a `make listserv`.

And it looks as though make is not using CFLAGS:
> Makefile:
> 146:            $(CC) -o lsv lsv.o `echo "$(CFLAGS_$(UNAME))"`; \

Which includes CFLAGS_Solaris but not CFLAGS, correct?

Suggestions on how to do this correctly? I'm positive that there  
could be something patently stupid that I am doing but I honestly  
cannot recognize the problem--I will cop to being until as of late, a  
gcc/cc cripple by way of RPM.

Again, thanks for all of the help today, you've all proved  
terrifically helpful!

--
_______________________________________________
Mike Neuharth, BA, LPIC-1
Email/UNIX System Administrator
Internet Services, University of Minnesota
===============================================
"What is important, it seems to me, is not so much to defend a culture
whose existence has never kept a man from going hungry, as to extract,
from what is called culture, ideas whose compelling force is identical
with that of hunger."  -Antonin Artaud

ATOM RSS1 RSS2