arguments to xlC (shared libraries)

arguments to xlC (shared libraries)

Post by William F. Dowlin » Tue, 13 Jun 2000 04:00:00



I am moving from g++ to xlC for generating code for some shared libs.

xlC -g -c Example.cpp -o bin.aix4/Example.o
xlC -G -bnoentry -bernotok -bE:Example_wrap.exp -brtl \
     -lperl -L/usr/local/perl/lib/5.00503/aix/CORE -lbsd \
     -obin.aix4/Example.so bin.aix4/Example.o bin.aix4/Example_wrap.o
xlC: 1501-252 The option -G is not supported. Use makeC++SharedLib to
build shared objects

This tells me -G is no good; I take the advice and try
-makeC++SharedLib.

xlC -g -c Example.cpp -o bin.aix4/Example.o
xlC -makeC++SharedLib -bnoentry -bernotok -bE:Example_wrap.exp -brtl \
     -lperl -L/usr/local/perl/lib/5.00503/aix/CORE -lbsd \
     -obin.aix4/Example.so bin.aix4/Example.o bin.aix4/Example_wrap.o
munch: 1547-002 Cannot open input file -obin.aix4/Example.so

The success of the 1st command tells me xlC can write into the bin.aix4
directory; the failure of the 2nd is peculiar: I wouldn't have thought
-obin.aix4/Example.so would be taken for input.

My online docs (bless the sysadmins' pointy little heads) indicate -G is
fine for ld, and say nothing about -makeC++SharedLib.  Am I dealing with
a compiler/linker version mismatch? A compiler/OS  version mismatch?
(AIX 4.2).  

Any help (including especially pointers to up-to-date docs that can clue
me in about -makeC++SharedLib) gratefully appreciated.  Thanks,

Will

--
William F. Dowling
Institute for Scientific Information
215-386-0100 x-1156

 
 
 

arguments to xlC (shared libraries)

Post by William F. Dowlin » Tue, 13 Jun 2000 04:00:00


I am moving from g++ to xlC for generating code for some shared libs.

xlC -g -c Example.cpp -o bin.aix4/Example.o
xlC -G -bnoentry -bernotok -bE:Example_wrap.exp -brtl \
     -lperl -L/usr/local/perl/lib/5.00503/aix/CORE -lbsd \
     -obin.aix4/Example.so bin.aix4/Example.o bin.aix4/Example_wrap.o
xlC: 1501-252 The option -G is not supported. Use makeC++SharedLib to
build shared objects

This tells me -G is no good; I take the advice and try
-makeC++SharedLib.

xlC -g -c Example.cpp -o bin.aix4/Example.o
xlC -makeC++SharedLib -bnoentry -bernotok -bE:Example_wrap.exp -brtl \
     -lperl -L/usr/local/perl/lib/5.00503/aix/CORE -lbsd \
     -obin.aix4/Example.so bin.aix4/Example.o bin.aix4/Example_wrap.o
munch: 1547-002 Cannot open input file -obin.aix4/Example.so

The success of the 1st command tells me xlC can write into the bin.aix4
directory; the failure of the 2nd is peculiar: I wouldn't have thought
-obin.aix4/Example.so would be taken for input.

My online docs (bless the sysadmins' pointy little heads) indicate -G is
fine for ld, and say nothing about -makeC++SharedLib.  Am I dealing with
a compiler/linker version mismatch? A compiler/OS  version mismatch?
(AIX 4.2).  

Any help (including especially pointers to up-to-date docs that can clue
me in about -makeC++SharedLib) gratefully appreciated.  Thanks,

Will

--
William F. Dowling
Institute for Scientific Information
215-386-0100 x-1156

 
 
 

arguments to xlC (shared libraries)

Post by Gary R. Hoo » Wed, 14 Jun 2000 04:00:00



> I am moving from g++ to xlC for generating code for some shared libs.

> xlC -g -c Example.cpp -o bin.aix4/Example.o
> xlC -G -bnoentry -bernotok -bE:Example_wrap.exp -brtl \
>      -lperl -L/usr/local/perl/lib/5.00503/aix/CORE -lbsd \
>      -obin.aix4/Example.so bin.aix4/Example.o bin.aix4/Example_wrap.o
> xlC: 1501-252 The option -G is not supported. Use makeC++SharedLib to
> build shared objects

> This tells me -G is no good; I take the advice and try
> -makeC++SharedLib.

> xlC -g -c Example.cpp -o bin.aix4/Example.o
> xlC -makeC++SharedLib -bnoentry -bernotok -bE:Example_wrap.exp -brtl \
>      -lperl -L/usr/local/perl/lib/5.00503/aix/CORE -lbsd \
>      -obin.aix4/Example.so bin.aix4/Example.o bin.aix4/Example_wrap.o
> munch: 1547-002 Cannot open input file -obin.aix4/Example.so

Um, /usr/ibmcxx/bin/makeC++SharedLib (or whatever product directory
it resides within).  It's a shell script, not a compiler option.

Quote:> My online docs (bless the sysadmins' pointy little heads) indicate -G is
> fine for ld, and say nothing about -makeC++SharedLib.  Am I dealing with
> a compiler/linker version mismatch? A compiler/OS  version mismatch?
> (AIX 4.2).

> Any help (including especially pointers to up-to-date docs that can clue
> me in about -makeC++SharedLib) gratefully appreciated.  Thanks,

Try searching in the docs for "makeC++SharedLib".

--
Gary R. Hook / AIX Kernel Development, IBM / These opinions are _MINE_
________________________________________________________________________
A piece of canvas is only the beginning
It takes on character with every loving stroke
This thing of beauty is the passion of an artist's heart
By God's design, we are a skin kaleidoscope    "Colored people", dc Talk

 
 
 

arguments to xlC (shared libraries)

Post by Sean Perr » Fri, 23 Jun 2000 04:00:00


If you upgrade to the v5 compiler your original command would work.


> I am moving from g++ to xlC for generating code for some shared libs.

> xlC -g -c Example.cpp -o bin.aix4/Example.o
> xlC -G -bnoentry -bernotok -bE:Example_wrap.exp -brtl \
>      -lperl -L/usr/local/perl/lib/5.00503/aix/CORE -lbsd \
>      -obin.aix4/Example.so bin.aix4/Example.o bin.aix4/Example_wrap.o
> xlC: 1501-252 The option -G is not supported. Use makeC++SharedLib to
> build shared objects

> This tells me -G is no good; I take the advice and try
> -makeC++SharedLib.

> xlC -g -c Example.cpp -o bin.aix4/Example.o
> xlC -makeC++SharedLib -bnoentry -bernotok -bE:Example_wrap.exp -brtl \
>      -lperl -L/usr/local/perl/lib/5.00503/aix/CORE -lbsd \
>      -obin.aix4/Example.so bin.aix4/Example.o bin.aix4/Example_wrap.o
> munch: 1547-002 Cannot open input file -obin.aix4/Example.so

> The success of the 1st command tells me xlC can write into the bin.aix4
> directory; the failure of the 2nd is peculiar: I wouldn't have thought
> -obin.aix4/Example.so would be taken for input.

> My online docs (bless the sysadmins' pointy little heads) indicate -G is
> fine for ld, and say nothing about -makeC++SharedLib.  Am I dealing with
> a compiler/linker version mismatch? A compiler/OS  version mismatch?
> (AIX 4.2).

> Any help (including especially pointers to up-to-date docs that can clue
> me in about -makeC++SharedLib) gratefully appreciated.  Thanks,

> Will

> --
> William F. Dowling
> Institute for Scientific Information
> 215-386-0100 x-1156

--
Sean Perry

 
 
 

1. create a shared library on AIX4.3 with xlC Compiler

Hallo AIX friends,
I want to compile on a AIX4.3 with xlC compiler and build a shared
library.
Compiling was ok. But when I start the makeC++SharedLib_r the following
error message comes:

 ...
test.o -lm -lpthreads_compat -lpthreads -L/usr/lpp/xlC/lib -lbsd
<libpath /usr/lpp/xlC/lib:/usr/ibmcxx/lib:/usr/lib:/lib

What the matter??

Do you need more information?
Thank you for your tips.
Greetings from Berlin
Thomas

Hallo AIX friends,
I want to compile on a AIX4.3 with xlC compiler and build a shared
library.
Compiling was ok. But when I start the makeC++SharedLib_r the following
error message comes:

 ...
test.o -lm -lpthreads_compat -lpthreads -L/usr/lpp/xlC/lib -lbsd

- Show quoted text -

<libpath /usr/lpp/xlC/lib:/usr/ibmcxx/lib:/usr/lib:/lib

What the matter??

Do you need more information?
Thank you for your tips.
Greetings from Berlin
Thomas

_____________________________________________________________________
ProSTEP GIDA GmbH       Phone:  +49-30-6392 6041
Thomas Rademacher           Fax:    +49-30-6392 6050
IGZ                                     e-mail:

Rudower Chaussee 29
D-12489 Berlin
______________________________________________________________________

2. Swap file on an msdos or nfs file system.

3. linking with a shared library using xlC on Aix 5.1

4. pppd problems on RH4.2

5. create a shared library on AIX 4.3 with xlC

6. command line mixer?

7. Will strip(debug shared library) == nodebug shared library ?

8. KOffice & MS Office 97 files

9. Help with building shared libraries with dependencies on other shared libraries

10. Question: Inclusion of shared libraries during linking of shared libraries

11. Shared library loading shared library.

12. Need a Shared Library Guru: beyond simple shared library question

13. When is a shared library not a shared library?