Hi Dennis
Try usiing the GCC tools on the Solaris Companion CD. It installs in
/opt/sfw/bin. Ensure the /opt/sfw/bin and /usr/ccs/bin is in your path and
this should work.
Phil
On Thursday 01 November 2001 04:24 pm, dennis wrote:> Hi
>
> I'm attempting to compile samba 222 on Solaris 2.8 using Sun Forte 6 C
> compiler but I'm getting error messages.
> I used the following sequence of commands:
>
> setenv CC cc
> ./configure --prefix=/usr/local/samba.22 --with-acl-support --with-pam
> --with-pam_smbpass --with-syslog
> make
>
> See messages below:
> ===============================================================>
..........
> ...................
> Compiling passdb/pass_check.c
> "passdb/pass_check.c", line 668: warning: statement not reached
> Compiling passdb/smbpassfile.c
> Compiling passdb/machine_sid.c
> Compiling passdb/pdb_smbpasswd.c
> Compiling passdb/pampass.c
> "passdb/pampass.c", line 422: warning: assignment type mismatch:
> pointer to function(int, pointer to pointer to struct
> pam_message {int msg_style, pointer to char msg}, pointer to pointer to
> struct pam_response {pointer to char resp, int resp_retcode}, pointer to
> void) returning int "=" pointer to function(int, pointer to
pointer to
> const struct pam_message {int msg_style, pointer to char msg}, pointer
> to pointer to struct pam_response {pointer to char resp, int
> resp_retcode}, pointer to void) returning int
> Compiling passdb/pdb_tdb.c
> Compiling passdb/pdb_ldap.c
> Compiling passdb/pdb_nisplus.c
> Compiling printing/pcap.c
> Compiling printing/print_svid.c
> ....................
> ...........
> ...........
> ...................
> Compiling utils/make_unicodemap.c
> Linking bin/make_unicodemap
> Compiling utils/smbcacls.c
> Linking bin/smbcacls
> Compiling pam_smbpass/pam_smb_auth.c with -KPIC
> "pam_smbpass/pam_smb_auth.c", line 85: warning: argument #2 is
> incompatible with prototype:
> prototype: pointer to pointer to char :
> "/usr/include/security/pam_appl.h", line 211
> argument : pointer to pointer to const char
> "pam_smbpass/pam_smb_auth.c", line 90: warning: end-of-loop code
not
> reached
> "pam_smbpass/pam_smb_auth.c", line 99: warning: end-of-loop code
not
> reached
> "pam_smbpass/pam_smb_auth.c", line 104: warning: argument #2 is
> incompatible with prototype:
> prototype: pointer to char : "include/proto.h", line 2130
> argument : pointer to const char
> "pam_smbpass/pam_smb_auth.c", line 109: warning: end-of-loop code
not
> reached
> "pam_smbpass/pam_smb_auth.c", line 117: warning: end-of-loop code
not
> reached
> "pam_smbpass/pam_smb_auth.c", line 125: warning: end-of-loop code
not
> reached
> "pam_smbpass/pam_smb_auth.c", line 135: warning: end-of-loop code
not
> reached
> "pam_smbpass/pam_smb_auth.c", line 143: warning: end-of-loop code
not
> reached
> "pam_smbpass/pam_smb_auth.c", line 182: warning: argument #3 is
> incompatible with prototype:
> prototype: pointer to pointer to void :
> "/usr/include/security/pam_appl.h", line 178
> argument : pointer to pointer to const void
> "pam_smbpass/pam_smb_auth.c", line 197: warning: argument #1 is
> incompatible with prototype:
> prototype: pointer to char : "include/proto.h", line 2059
> argument : pointer to const char
> "pam_smbpass/pam_smb_auth.c", line 217: warning: argument #1 is
> incompatible with prototype:
> prototype: pointer to char : "include/proto.h", line 2059
> argument : pointer to const char
> Compiling pam_smbpass/pam_smb_passwd.c with -KPIC
> "pam_smbpass/pam_smb_passwd.c", line 47: warning: argument #1 is
> incompatible with prototype:
> prototype: pointer to char : "include/proto.h", line 2059
> argument : pointer to const char
> "pam_smbpass/pam_smb_passwd.c", line 112: warning: argument #2 is
> incompatible with prototype:
> prototype: pointer to pointer to char :
> "/usr/include/security/pam_appl.h", line 211
> argument : pointer to pointer to const char
> "pam_smbpass/pam_smb_passwd.c", line 130: warning: argument #2 is
> incompatible with prototype:
> prototype: pointer to char : "include/proto.h", line 2130
> argument : pointer to const char
> "pam_smbpass/pam_smb_passwd.c", line 213: warning: argument #3 is
> incompatible with prototype:
> prototype: pointer to pointer to void :
> "/usr/include/security/pam_appl.h", line 178
> argument : pointer to pointer to const void
> Compiling pam_smbpass/pam_smb_acct.c with -KPIC
> "pam_smbpass/pam_smb_acct.c", line 63: warning: argument #2 is
> incompatible with prototype:
> prototype: pointer to pointer to char :
> "/usr/include/security/pam_appl.h", line 211
> argument : pointer to pointer to const char
> "pam_smbpass/pam_smb_acct.c", line 81: warning: argument #2 is
> incompatible with prototype:
> prototype: pointer to char : "include/proto.h", line 2130
> argument : pointer to const char
> Compiling pam_smbpass/support.c with -KPIC
> "pam_smbpass/support.c", line 87: warning: argument #3 is
incompatible
> with prototype:
> prototype: pointer to pointer to void :
> "/usr/include/security/pam_appl.h", line 178
> argument : pointer to pointer to const void
> "pam_smbpass/support.c", line 91: warning: argument #2 is
incompatible
> with prototype:
> prototype: pointer to pointer to struct pam_message {int
> msg_style, pointer to char msg} : "unknown", line 0
> argument : pointer to pointer to const struct pam_message {int
> msg_style, pointer to char msg}
> "pam_smbpass/support.c", line 113: warning: assignment type
mismatch:
> pointer to char "=" pointer to const char
> "pam_smbpass/support.c", line 164: warning: argument #1 is
incompatible
> with prototype:
> prototype: pointer to char : "include/proto.h", line 1988
> argument : pointer to const char
> "pam_smbpass/support.c", line 275: warning: argument #3 is
incompatible
> with prototype:
> prototype: pointer to pointer to void :
> "/usr/include/security/pam_appl.h", line 178
> argument : pointer to pointer to const void
> "pam_smbpass/support.c", line 332: warning: argument #3 is
incompatible
> with prototype:
> prototype: pointer to pointer to void :
> "/usr/include/security/pam_appl.h", line 178
> argument : pointer to pointer to const void
> "pam_smbpass/support.c", line 352: warning: argument #1 is
incompatible
> with prototype:
> prototype: pointer to char : "include/proto.h", line 2043
> argument : pointer to const char
> "pam_smbpass/support.c", line 352: warning: argument #2 is
incompatible
> with prototype:
> prototype: pointer to unsigned char : "include/proto.h",
line
> 2043
> argument : pointer to char
> "pam_smbpass/support.c", line 374: warning: argument #1 is
incompatible
> with prototype:
> prototype: pointer to char : "include/proto.h", line 1220
> argument : pointer to const char
> "pam_smbpass/support.c", line 388: warning: argument #3 is
incompatible
> with prototype:
> prototype: pointer to pointer to void :
> "/usr/include/security/pam_appl.h", line 178
> argument : pointer to pointer to const void
> "pam_smbpass/support.c", line 503: warning: argument #3 is
incompatible
> with prototype:
> prototype: pointer to pointer to void :
> "/usr/include/security/pam_appl.h", line 178
> argument : pointer to pointer to const void
> "pam_smbpass/support.c", line 597: warning: argument #3 is
incompatible
> with prototype:
> prototype: pointer to pointer to void :
> "/usr/include/security/pam_appl.h", line 178
> argument : pointer to pointer to const void
> Compiling lib/debug.c with -KPIC
> Compiling lib/util_sid.c with -KPIC
> Compiling lib/messages.c with -KPIC
> Compiling lib/util_str.c with -KPIC
> ....................
> ...........
> ...........
> ...................
> Compiling passdb/secrets.c with -KPIC
> Compiling passdb/pass_check.c with -KPIC
> "passdb/pass_check.c", line 668: warning: statement not reached
> Compiling passdb/smbpassfile.c with -KPIC
> Compiling passdb/machine_sid.c with -KPIC
> Compiling passdb/pdb_smbpasswd.c with -KPIC
> Compiling passdb/pampass.c with -KPIC
> "passdb/pampass.c", line 422: warning: assignment type mismatch:
> pointer to function(int, pointer to pointer to struct
> pam_message {int msg_style, pointer to char msg}, pointer to pointer to
> struct pam_response {pointer to char resp, int resp_retcode}, pointer to
> void) returning int "=" pointer to function(int, pointer to
pointer to
> const struct pam_message {int msg_style, pointer to char msg}, pointer
> to pointer to struct pam_response {pointer to char resp, int
> resp_retcode}, pointer to void) returning int
> Compiling passdb/pdb_tdb.c with -KPIC
> Compiling passdb/pdb_ldap.c with -KPIC
> Compiling passdb/pdb_nisplus.c with -KPIC
> Linking shared library bin/pam_smbpass.so
> ld -shared -symbolic -o bin/pam_smbpass.so pam_smbpass/pam_smb_auth.po
> pam_smbpass/pam_smb_passwd.po pam_smbpass/pam_smb_acct.po
> pam_smbpass/support.po lib/debug.po lib/util_sid.po lib/messages.po
> lib/util_str.po lib/wins_srv.po lib/substitute.po lib/select.po
> lib/util.po nsswitch/wb_client.po nsswitch/wb_common.po lib/system.po
> lib/charset.po lib/util_file.po lib/kanji.po lib/genrand.po
> lib/username.po lib/charcnv.po lib/time.po lib/md4.po
> lib/util_unistr.po lib/signal.po lib/talloc.po lib/ms_fnmatch.po
> lib/util_sock.po lib/smbrun.po lib/util_sec.po ubiqx/ubi_sLinkList.po
> libsmb/smbencrypt.po libsmb/smbdes.po param/loadparm.po param/params.po
> tdb/tdb.po tdb/spinlock.po tdb/tdbutil.po passdb/passdb.po
> passdb/secrets.po passdb/pass_check.po passdb/smbpassfile.po
> passdb/machine_sid.po passdb/pdb_smbpasswd.po passdb/pampass.po
> passdb/pdb_tdb.po passdb/pdb_ldap.po passdb/pdb_nisplus.po -lpam -lsec
> -lgen -lsocket -lnsl -ldl -lpam -lc
> ld: illegal option -- y
> ld: warning: option -o appears more than once, first setting taken
> usage: ld [-6:abc:d:e:f:h:il:mo:p:rstu:z:B:D:F:GI:L:M:N:P:Q:R:S:VY:?]
> file(s)
> [-64] enforce a 64-bit link-edit
> [-a] create an absolute file
> [-b] do not do special PIC relocations in a.out
> [-c file] record configuration `file'
> [-d y|n] operate in dynamic|static mode
> [-e sym] use `sym' as entry point address
> [-f name] specify library for which this file is an
> auxiliary
> filter
> [-h name] use `name' as internal shared object identifier
> [-i] ignore LD_LIBRARY_PATH setting
> [-l x] search for libx.so or libx.a
> [-m] print memory map
> [-o outfile] name the output file `outfile'
> [-p name] identify audit object to accompany this object
> [-r] create a relocatable object
> [-s] strip any symbol and debugging information
> [-t] do not warn of multiply-defined symbols that
> have
> different sizes or alignments
> [-u sym] create an undefined symbol `sym'
> [-z absexec] when building an executable absolute symbols
> referenced in dynamic objects are promoted to
> the executable.
> [-z now] mark object as requiring non-lazy binding
> [-z defs|nodefs]
> disallow|allow undefined symbols
> [-z endfiltee] marks a filtee such that it will terminate a
> filters
> search
> [-z groupperm|nogroupperm]
> enable|disable setting of GROUP permissions
> on dynamic dependencies
> [-z ignore|record]
> ignore|record unused dynamic dependencies
> [-z initfirst] mark object to indicate that its .init section
> should
> be executed before the .init section of any
> other
> objects
> [-z loadfltr] mark filter as requiring immediate loading of
> its
> filtees at runtime
> [-z interpose] dynamic object is to be an `interposer' on
> direct bindings
> [-z lazyload|nolazyload]
> enable|disable delayed loading of shared objects
> [-z muldefs] allow multiply-defined symbols
> [-z nodefaultlib]
> mark object to ignore any default library search
> path
> [-z nodelete] mark object as non-deletable
> [-z nodlopen] mark object as non-dlopen()'able
> [-z nodump] mark object as non-dldump()'able
> [-z nopartial] expand any partially initialized symbols
> [-z noversion] don't record any version sections
> [-z origin] mark object as requiring $ORIGIN processing
> [-z redlocsym] reduce local syms in .symtab to a minimum
> [-z text] disallow output relocations against text
> [-z textwarn] warn if there are relocations against text
> [-z textoff] allow output relocations against text
> [-z verbose] generate warnings for suspicious processings
> [-z weakextract]
> allow extraction of archive members to resolve
> weak
> references
> [-z allextract] extract all member files from archive files
> [-z defaultextract]
> extract member files from archive files
> which resolve undefined or tentative symbols
> [-z combreloc] combine multiple relocation sections
> [-B dynamic|static]
> search for shared libraries|archives
> [-B group] relocate object from within group
> [-B eliminate] eliminate unqualified global
> symbols from the symbol table
> [-B local] reduce unqualified global symbols to local
> [-B reduce] process symbol reductions
> [-B symbolic] bind external references to definitions when
> creating
> shared objects
> [-B direct] specify `direct' bindings for executable when
> run
> [-B translator] specify that this object is to act as a
> 'translator'
> for an application bound with -Bdirect
> [-D options] print diagnostic messages
> [-F name] specify library for which this file is a filter
> [-G] create a shared object
> [-I interp] use `interp' as path name of interpreter
> [-L path] search for libraries in directory `path'
> [-M mapfile] use processing directives contained in
`mapfile'
> [-N file] create a dynamic dependency on `file'
> [-P name] identify audit object for processing the
> dependencies
> of this object
> [-Q y|n] do|do not place version information in output
> file
> [-R path] specify a library search path to be used at run
> time
> [-S name] specify a link-edit support library
> [-V] print version information
> [-Y P,dirlist] use `dirlist' as a default path when searching
> for
> libraries
> *** Error code 1
> make: Fatal error: Command failed for target `bin/pam_smbpass.so'
>
> ===============================================================>
> I've also tried compiling using the gcc 2.95.3 compiler but I get the
> same errors.
> In either case, if I compile without pam it compiles cleanly.
>
> Can someone tell what I'm doing wrong?
>
> Dennis