Opened 12 years ago

Last modified 11 years ago

#1204 new Defect

Make of 7.0.28 fails with ar unable to find "libboinc_la-app_ipc.o"

Reported by: Bluefin Tuna Owned by: Eric Korpela
Priority: Undetermined Milestone: Undetermined
Component: Client - Build Version: 7.0.28
Keywords: Cc:

Description

Compile from source using


./configure CXXFLAGS="-Wall -W -Wshadow -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -fno-common " --prefix=/home/boinc/boinc_7.0.28

Calling "make" eventually results in an error:


make  all-recursive
make[1]: Entering directory `/home/boinc/BUILD/boinc_core_release_7_0_28'
Making all in m4
make[2]: Entering directory `/home/boinc/BUILD/boinc_core_release_7_0_28/m4'
make[2]: Nothing to be done for `all'.
make[2]: Leaving directory `/home/boinc/BUILD/boinc_core_release_7_0_28/m4'
Making all in api
make[2]: Entering directory `/home/boinc/BUILD/boinc_core_release_7_0_28/api'
rm -f libboinc_api.a
/bin/ln .libs/libboinc_api.a .
rm -f libboinc_opencl.a
/bin/ln .libs/libboinc_opencl.a .
make[2]: Leaving directory `/home/boinc/BUILD/boinc_core_release_7_0_28/api'
Making all in lib
make[2]: Entering directory `/home/boinc/BUILD/boinc_core_release_7_0_28/lib'
/bin/sh ../libtool --tag=CXX   --mode=link g++ -Wall -Wextra -Wshadow -Wredundant-decls -Wdisabled-optimization -Wpointer-arith -Wstrict-aliasing -fPIC -DPIC -pthread -Wall -W -Wshadow -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -fno-common  -L/home/boinc/boinc_7.0.28/lib -rpath /home/boinc/boinc_7.0.28/lib -static -version-number 7:0:28  -o libboinc.la -rpath /home/boinc/boinc_7.0.28/lib libboinc_la-app_ipc.lo libboinc_la-base64.lo libboinc_la-cc_config.lo libboinc_la-cert_sig.lo libboinc_la-coproc.lo libboinc_la-diagnostics.lo libboinc_la-filesys.lo libboinc_la-gui_rpc_client.lo libboinc_la-gui_rpc_client_ops.lo libboinc_la-gui_rpc_client_print.lo libboinc_la-hostinfo.lo libboinc_la-md5.lo libboinc_la-md5_file.lo libboinc_la-mem_usage.lo libboinc_la-mfile.lo libboinc_la-miofile.lo libboinc_la-msg_log.lo libboinc_la-network.lo libboinc_la-notice.lo libboinc_la-parse.lo libboinc_la-prefs.lo libboinc_la-procinfo.lo libboinc_la-proc_control.lo libboinc_la-proxy_info.lo libboinc_la-shmem.lo libboinc_la-str_util.lo libboinc_la-synch.lo libboinc_la-unix_util.lo libboinc_la-url.lo libboinc_la-util.lo libboinc_la-procinfo_unix.lo   
libtool: link: ar cru .libs/libboinc.a  libboinc_la-app_ipc.o libboinc_la-base64.o libboinc_la-cc_config.o libboinc_la-cert_sig.o libboinc_la-coproc.o libboinc_la-diagnostics.o libboinc_la-filesys.o libboinc_la-gui_rpc_client.o libboinc_la-gui_rpc_client_ops.o libboinc_la-gui_rpc_client_print.o libboinc_la-hostinfo.o libboinc_la-md5.o libboinc_la-md5_file.o libboinc_la-mem_usage.o libboinc_la-mfile.o libboinc_la-miofile.o libboinc_la-msg_log.o libboinc_la-network.o libboinc_la-notice.o libboinc_la-parse.o libboinc_la-prefs.o libboinc_la-procinfo.o libboinc_la-proc_control.o libboinc_la-proxy_info.o libboinc_la-shmem.o libboinc_la-str_util.o libboinc_la-synch.o libboinc_la-unix_util.o libboinc_la-url.o libboinc_la-util.o libboinc_la-procinfo_unix.o
ar: libboinc_la-app_ipc.o: No such file or directory
make[2]: *** [libboinc.la] Error 1
make[2]: Leaving directory `/home/boinc/BUILD/boinc_core_release_7_0_28/lib'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/boinc/BUILD/boinc_core_release_7_0_28'
make: *** [all] Error 2

libboinc_la-app_ipc.o actually exists, in this case:

/home/boinc/BUILD/boinc_core_release_7_0_28/lib/.libs/libboinc_la-app_ipc.o

However, this is not a place where "ar" can find it.

Apparently it should be in

/home/boinc/boinc_7.0.28/lib

which is the target directory, or possibly in

/home/boinc/BUILD/boinc_core_release_7_0_28/lib

where it is not. It is in

/home/boinc/BUILD/boinc_core_release_7_0_28/lib/.libs

Other libraries in .libs:

libboinc_la-app_ipc.o
libboinc_la-base64.o
libboinc_la-cc_config.o
libboinc_la-cert_sig.o
libboinc_la-coproc.o
libboinc_la-diagnostics.o
libboinc_la-filesys.o
libboinc_la-gui_rpc_client.o
libboinc_la-gui_rpc_client_ops.o
libboinc_la-gui_rpc_client_print.o
libboinc_la-hostinfo.o
libboinc_la-md5_file.o
libboinc_la-md5.o
libboinc_la-mem_usage.o
libboinc_la-mfile.o
libboinc_la-miofile.o
libboinc_la-msg_log.o
libboinc_la-network.o
libboinc_la-notice.o
libboinc_la-parse.o
libboinc_la-prefs.o
libboinc_la-proc_control.o
libboinc_la-procinfo.o
libboinc_la-procinfo_unix.o
libboinc_la-proxy_info.o
libboinc_la-shmem.o
libboinc_la-str_util.o
libboinc_la-synch.o
libboinc_la-unix_util.o
libboinc_la-url.o
libboinc_la-util.o

Change History (8)

comment:1 Changed 12 years ago by Nicolas

Owner: changed from romw to Eric Korpela

comment:2 Changed 12 years ago by Eric Korpela

Was this a clean compile? When it builds the libraries ar is operating in the .lib directory. I suppose it could be a bug introduced in libtool or autoconf/automake.

I'm doing a clean rebuild now to see if I can recreate the problem.

To see if it recurs do the following in the boinc root directory

mv config.status config.status.bak make distclean ./_autosetup ./config.status.bak --recheck make all

If it recurs, let me know what verion of automake, autoconf,and libtool you have installed.

comment:3 Changed 12 years ago by Eric Korpela

Everything built just fine...

comment:4 Changed 12 years ago by Nicolas

FWIW, I get similar “file not found” errors if I try to compile in parallel (eg. make -j4). I haven’t checked if it’s the same file or file extension as in this bug report, though.

comment:5 Changed 12 years ago by Bluefin Tuna

Hi,

Yes this is a clean build. On Fedora 17.

I just tried again from 0:

mkdir mybuild
cd mybuild
svn co http://boinc.berkeley.edu/svn/tags/boinc_core_release_7_0_28/
cd boinc_core_release_7_0_28
./_autosetup 
./configure CXXFLAGS="-Wall -W -Wshadow -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -fno-common " --prefix=/home/boinc/boinc_7.0.28 
make

Now it works. The "libboinc_la-app_ipc.o" object is in "lib", so the previously failing instruction succeeds.

So, let's continue...

  • Compilation breaks because of missing "mysql.h". Added, package mysql-devel then "make" again.
  • Compilation breaks because
../tools/process_input_template.cpp: In function 'bool got_md5_info(const char*, char*, double*)':
../tools/process_input_template.cpp:86:23: error: 'unlink' was not declared in this scope
../tools/process_input_template.cpp: In function 'void write_md5_info(const char*, const char*, double)':
../tools/process_input_template.cpp:129:23: error: 'unlink' was not declared in this scope

Ok, here we have "gcc version 4.7.0". According to http://gcc.gnu.org/gcc-4.7/porting_to.html , one has to edit tools/process_input_template.cpp and include <unistd.h> explicitely.

No sooner said than done, then "make" again.

  • Compilation breaks because
plan_class_spec.cpp: In member function ‘bool PLAN_CLASS_SPEC::check(SCHEDULER_REQUEST&, HOST_USAGE&)’:
plan_class_spec.cpp:212:63: error: ‘struct CUDA_DEVICE_PROP’ has no member named ‘dtotalGlobalMem’

...and I'm stumped :-(

But let's first solve the "make" problem.

Trying again.

make clean; make

Works again!

I still have to old Makefile in "lib" of the failing installation. Comparison may be enlightening.

diff --side-by-side ~/goodbuild/boinc_core_release_7_0_28/lib/Makefile  ~/badbuild/boinc_core_release_7_0_28/lib/Makefile  | less

Some declarations have changed for unclear reason (working Makefile on the left). I remember that I had to add the gcc package. Maybe configure didn't pick it up on the first time?

CXXCPP = g++ -E                                               | CXXCPP = 
CXXDEPMODE = depmode=gcc3                                     | CXXDEPMODE = depmode=none
CXXFLAGS = -Wall -W -Wshadow -Wpointer-arith -Wcast-qual -Wca | CXXFLAGS = -Wall -W -Wshadow -Wpointer-arith -Wcast-qual -Wca

Revision code has changed., I suppose the SVN repository was updated

REV = 26058                                                   | REV = 26044

Additional changes

XCB_CFLAGS =                                                  | XCB_CFLAGS = 
XCB_LIBS = -lxcb                                              | XCB_LIBS = 
ac_ct_CXX = g++                                               | ac_ct_CXX = 

Most interesting, the library build instructions have complementary commenting:

libboinc_la-app_ipc.lo: app_ipc.cpp                             libboinc_la-app_ipc.lo: app_ipc.cpp
        $(LIBTOOL)  --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLA | #       $(LIBTOOL)  --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLA
        $(am__mv) $(DEPDIR)/libboinc_la-app_ipc.Tpo $(DEPDIR) | #       $(am__mv) $(DEPDIR)/libboinc_la-app_ipc.Tpo $(DEPDIR)
#       source='app_ipc.cpp' object='libboinc_la-app_ipc.lo'  |         source='app_ipc.cpp' object='libboinc_la-app_ipc.lo' 
#       DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) \           |         DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) \
#       $(LIBTOOL)  --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLA |         $(LIBTOOL)  --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLA

The commented-out 'ammv' (alias for a 'mv -f') looks relevant to this problem though it moves files with "Plo" ending:

$(am__mv) $(DEPDIR)/libboinc_la-app_ipc.Tpo $(DEPDIR)/libboinc_la-app_ipc.Plo

Not sure what happens here or why the commenting is complementary at all. But as said, it could be due to a mangled configuration file due to package gcc-c++ initially missing (but package gcc being present) at ./configure time.

Best regards,

-- David

comment:6 Changed 12 years ago by Christian Beer

If you just want to build the client and manager you should add --disable-server to your configure parameters. This should eliminate the need for mysql-devel and some other serverrelated stuff.

comment:7 in reply to:  6 Changed 11 years ago by Bluefin Tuna

Hit the exact same problem again with release 7.0.65.

  1. Download source
  2. Configure (with --disable-server)
  3. Make
  4. Make breaks off because no g++:

CXX boinc_api.lo

../libtool: line 1159: g++: command not found

  1. yum install gcc-c++
  2. Make

ar: libboinc_la-app_ipc.o: No such file or directory

  1. Arrr!
  2. Find this bug report back
  3. make; make clean
  4. ar: libboinc_la-app_ipc.o: No such file or directory
  5. ARrrrrrr!
  6. Clean up everything, download source again using git etc .. up until "make"
  7. Works.

comment:8 Changed 11 years ago by Nicolas

Re-downloading from git is never needed. If you want to delete absolutely every generated file, use git clean -dfx.

Note: See TracTickets for help on using tickets.