Bacula-users

Re: [Bacula-users] Cannot compile bacula 5.0.3 on Solaris 10.

2011-01-07 15:52:10
Subject: Re: [Bacula-users] Cannot compile bacula 5.0.3 on Solaris 10.
From: robert.denault AT videotron DOT ca
To: bacula-users AT lists.sourceforge DOT net
Date: Fri, 07 Jan 2011 15:48:41 -0500
Using the Sun (Oracle) Studio compiler solved the problem

Thanks
Robert Denault.
--- Begin Message ---
Subject: Cannot compile bacula 5.0.3 on Solaris 10.
From: robert.denault AT videotron DOT ca
To: bacula-users AT lists.sourceforge DOT net
Date: Wed, 05 Jan 2011 13:17:28 -0500
I am trying to compile the bacula service on Solaris 10 system.  I have followed the documentation but I get errors during the compilation.  All required package are installed:
SUNWbinutils binutils - GNU binutils
SUNWarc Lint Libraries (usr)
SUNWhea SunOS Header Files
SUNWgcc gcc - The GNU C compiler
SUNWgnutls GNU Transport Layer Security Library
SUNWgnutls-devel GNU Transport Layer Security Library - developer files
SUNWgmake gmake - GNU make
SUNWgccruntime GCC Runtime libraries
SUNWlibgcrypt Libgcrypt - Cryptographic Library
SUNWzlib The Zip compression library
SUNWzlibS Source for the Zip compression library
SUNWbinutilsS GNU binutils - GNU Binary file utilities (Source)
SUNWgmakeS GNU make - A utility used to build software (Source)
SUNWlibm Math & Microtasking Library Headers & Lint Files (Usr)


Parameters for configure:

LDFLAGS="-L/usr/sfw/lib -R/usr/sfw/lib"
CFLAGS="-g"
export PATH LDFLAGS CFLAGS
./configure \
  --prefix=/opt \
  --datarootdir=/usr/share \
  --mandir=/usr/share/man \
  --sbindir=/opt/bacula/sbin \
  --sysconfdir=/opt/bacula/etc \
  --oldincludedir=/usr/include \
  --includedir=/usr/local/include \
  --with-mysql \
  --enable-smartalloc \
  --disable-nls \
  --enable-conio \
  --with-pid-dir=/var/run \
  --with-subsys-dir=/var/bacula \
  --with-working-dir=/var/bacula \
  --with-job-email=mtl-coredev AT telus DOT com \
  --with-smtp-host=coredev-mail-relay.coredev.mtl.emergis.com

Contents of config.out:
Configuration on Wed Jan  5 11:08:03 EST 2011:

   Host:                    sparc-sun-solaris2.10 -- solaris 5.10
   Bacula version:          Bacula 5.0.3 (04 August 2010)
   Source code location:    .
   Install binaries:        /opt/bacula/sbin
   Install libraries:       /opt/lib
   Install config files:    /opt/bacula/etc
   Scripts directory:       /opt/bacula/etc
   Archive directory:       /tmp
   Working directory:       /var/bacula
   PID directory:           /var/run
   Subsys directory:        /var/bacula
   Man directory:           /usr/share/man
   Data directory:          /usr/share
   Plugin directory:        /opt/lib
   C Compiler:              gcc 3.4.6
   C++ Compiler:            /usr/local/bin/g++ 3.4.6
   Compiler flags:           -g -fno-strict-aliasing -fno-exceptions -fno-rtti
   Linker flags:             -L/usr/sfw/lib -R/usr/sfw/lib
   Libraries:               -lpthread -lresolv -lnsl -lsocket -lxnet  -lintl -lresolv -lrt
   Statically Linked Tools: no
   Statically Linked FD:    no
   Statically Linked SD:    no
   Statically Linked DIR:   no
   Statically Linked CONS:  no
   Database type:           MySQL
   Database port:           
   Database lib:           
   Database name:           bacula
   Database user:           bacula

   Job Output Email:        mtl-coredev AT telus DOT com
   Traceback Email:         root@localhost
   SMTP Host Address:       coredev-mail-relay.coredev.mtl.emergis.com

   Director Port:           9101
   File daemon Port:        9102
   Storage daemon Port:     9103

   Director User:          
   Director Group:         
   Storage Daemon User:    
   Storage DaemonGroup:    
   File Daemon User:       
   File Daemon Group:      

   SQL binaries Directory   /usr/local/mysql/bin

   Large file support:      yes
   Bacula conio support:    yes -lncurses
   readline support:        no
   TCP Wrappers support:    no
   TLS support:             no
   Encryption support:      no
   ZLIB support:            yes
   enable-smartalloc:       yes
   enable-lockmgr:          no
   bat support:             no
   enable-gnome:            no
   enable-bwx-console:      no
   enable-tray-monitor:     no
   client-only:             no
   build-dird:              yes
   build-stored:            yes
   Plugin support:          yes
   AFS support:             no
   ACL support:             yes
   XATTR support:           yes
   Python support:          no
   Batch insert enabled:    no

Result of the make command:
-bash-3.00$ /usr/ccs/bin/make
==>Entering directory /export/home/rdenault/downloads/bacula/bacula-5.0.3/src
==>Entering directory /export/home/rdenault/downloads/bacula/bacula-5.0.3/scripts
==>Entering directory /export/home/rdenault/downloads/bacula/bacula-5.0.3/src/lib
Compiling attr.c
In file included from /usr/include/sys/wait.h:24,
                 from /usr/include/stdlib.h:22,
                 from ../bacula.h:76,
                 from attr.c:36:
/usr/include/sys/siginfo.h:259: error: `ctid_t' does not name a type
/usr/include/sys/siginfo.h:260: error: `zoneid_t' does not name a type
/usr/include/sys/siginfo.h:390: error: `ctid_t' does not name a type
/usr/include/sys/siginfo.h:391: error: `zoneid_t' does not name a type
In file included from ../bacula.h:148,
                 from attr.c:36:
/usr/include/pthread.h:299: error: `pthread_spinlock_t' was not declared in this scope
/usr/include/pthread.h:299: error: expected primary-_expression_ before ',' token
/usr/include/pthread.h:299: error: expected primary-_expression_ before "int"
/usr/include/pthread.h:299: error: initializer _expression_ list treated as compound _expression_
/usr/include/pthread.h:300: error: `pthread_spinlock_t' was not declared in this scope
/usr/include/pthread.h:300: error: expected primary-_expression_ before ')' token
/usr/include/pthread.h:301: error: `pthread_spinlock_t' was not declared in this scope
/usr/include/pthread.h:301: error: expected primary-_expression_ before ')' token
/usr/include/pthread.h:302: error: `pthread_spinlock_t' was not declared in this scope
/usr/include/pthread.h:302: error: expected primary-_expression_ before ')' token
/usr/include/pthread.h:303: error: `pthread_spinlock_t' was not declared in this scope
/usr/include/pthread.h:303: error: expected primary-_expression_ before ')' token
/usr/include/pthread.h:304: error: `pthread_barrierattr_t' was not declared in this scope
/usr/include/pthread.h:304: error: expected primary-_expression_ before ')' token
/usr/include/pthread.h:305: error: `pthread_barrierattr_t' was not declared in this scope
/usr/include/pthread.h:305: error: expected primary-_expression_ before ')' token
/usr/include/pthread.h:306: error: `pthread_barrierattr_t' was not declared in this scope
/usr/include/pthread.h:306: error: expected primary-_expression_ before ',' token
/usr/include/pthread.h:306: error: expected primary-_expression_ before "int"
/usr/include/pthread.h:306: error: initializer _expression_ list treated as compound _expression_
/usr/include/pthread.h:308: error: expected `,' or `...' before '*' token
/usr/include/pthread.h:309: error: `pthread_barrier_t' was not declared in this scope
/usr/include/pthread.h:309: error: expected primary-_expression_ before ',' token
/usr/include/pthread.h:310: error: expected primary-_expression_ before "const"
/usr/include/pthread.h:310: error: expected primary-_expression_ before ')' token
/usr/include/pthread.h:310: error: initializer _expression_ list treated as compound _expression_
/usr/include/pthread.h:311: error: `pthread_barrier_t' was not declared in this scope
/usr/include/pthread.h:311: error: expected primary-_expression_ before ')' token
/usr/include/pthread.h:312: error: `pthread_barrier_t' was not declared in this scope
/usr/include/pthread.h:312: error: expected primary-_expression_ before ')' token
*** Error code 1
The following command caused the error:
/export/home/rdenault/downloads/bacula/bacula-5.0.3/libtool --silent --tag=CXX --mode=compile /usr/local/bin/g++   -c  -fno-strict-aliasing -fno-exceptions -fno-rtti  -I. -I..  -g -fno-strict-aliasing -fno-exceptions -fno-rtti attr.c
make: Fatal error: Command failed for target `attr.lo'
Current working directory /export/home/rdenault/downloads/bacula/bacula-5.0.3/src/lib


  ====== Error in /export/home/rdenault/downloads/bacula/bacula-5.0.3/src/lib ======


*** Error code 1
The following command caused the error:
for I in src scripts src/lib src/findlib src/filed   src/console src/plugins/fd src/cats src/dird src/stored src/tools manpages; \
  do (cd $I; echo "==>Entering directory `pwd`"; \
      /usr/ccs/bin/make DESTDIR= all || (echo ""; echo ""; echo "  ====== Error in `pwd` ======"; \
                    echo ""; echo ""; exit 1;)); \
done
make: Fatal error: Command failed for target `all'


Regards,
Robert Denault


--- End Message ---
------------------------------------------------------------------------------
Gaining the trust of online customers is vital for the success of any company
that requires sensitive data to be transmitted over the Web.   Learn how to 
best implement a security strategy that keeps consumers' information secure 
and instills the confidence they need to proceed with transactions.
http://p.sf.net/sfu/oracle-sfdevnl 
_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users
<Prev in Thread] Current Thread [Next in Thread>