Re: [cmake-developers] Compiling CMake 3.6.1 fails on Raspbian Jessie

2016-09-07 Thread Cristian Adam
On Tue, Sep 6, 2016 at 9:13 PM, Brad King  wrote:

> On 09/06/2016 02:39 PM, Cristian Adam wrote:
> > Who should have noticed that the two object files were empty and try a
> > new compilation? CMake or make?
>
> Nothing.  This is not a failure case that we expect to be handled.
> The .o files exist with a timestamp newer than their dependencies,
> so the build system thinks they are up to date.  The fact that the
> wrong content was written to them due to a system failure is not
> something we can know or tolerate.
>
> -Brad
>
>
I see. Due to object headers one should not be able to produce an
empty object file with a compiler.

Brad, thank you for the help. Now I know how to analyze archive files \m/

Cheers,
Cristian.
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake-developers

Re: [cmake-developers] Compiling CMake 3.6.1 fails on Raspbian Jessie

2016-09-06 Thread Brad King
On 09/06/2016 02:39 PM, Cristian Adam wrote:
> Who should have noticed that the two object files were empty and try a 
> new compilation? CMake or make?

Nothing.  This is not a failure case that we expect to be handled.
The .o files exist with a timestamp newer than their dependencies,
so the build system thinks they are up to date.  The fact that the
wrong content was written to them due to a system failure is not
something we can know or tolerate.

-Brad

-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake-developers


Re: [cmake-developers] Compiling CMake 3.6.1 fails on Raspbian Jessie

2016-09-06 Thread Cristian Adam

On 06-Sep-16 14:26, Brad King wrote:

On 09/05/2016 04:39 PM, Cristian Adam wrote:

On Mon, Sep 5, 2016 at 10:33 PM, Brad King wrote:

Something goes wrong with finding some of the symbols in it,
such as some from `json_value.cpp`.

$ ar t Utilities/cmjsoncpp/libcmjsoncpp.a
json_reader.cpp.o
json_value.cpp.o
json_writer.cpp.o

 From the binary you sent me:

```
$ file Utilities/cmjsoncpp/CMakeFiles/cmjsoncpp.dir/src/lib_json/*.o
Utilities/cmjsoncpp/CMakeFiles/cmjsoncpp.dir/src/lib_json/json_reader.cpp.o: 
empty
Utilities/cmjsoncpp/CMakeFiles/cmjsoncpp.dir/src/lib_json/json_value.cpp.o:  
empty
Utilities/cmjsoncpp/CMakeFiles/cmjsoncpp.dir/src/lib_json/json_writer.cpp.o: 
ELF 32-bit LSB relocatable, ARM, EABI5 version 1 (SYSV), not stripped
```

Somehow two of the .o files ended up empty.  The Makefile content
looks fine and the command line to compile is the same for all
three sources.  Is this reproducible?  If you remove the two empty
files and build again do they still end up empty?

-Brad


Removal of the empty object files lead to a successful compilation.

In retrospect I should have cleaned my build directory after my 
Raspberry PI froze when compiling with MAKEFLAGS=-j4.
Bootstrap compiled fine with -j4, but make managed to crash the system 
with -j4 and -j3.


Who should have noticed that the two object files were empty and try a 
new compilation? CMake or make?


Cheers,
Cristian.



--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake-developers


Re: [cmake-developers] Compiling CMake 3.6.1 fails on Raspbian Jessie

2016-09-06 Thread Brad King
On 09/05/2016 04:39 PM, Cristian Adam wrote:
> On Mon, Sep 5, 2016 at 10:33 PM, Brad King wrote:
>> Something goes wrong with finding some of the symbols in it,
>> such as some from `json_value.cpp`.
> 
> $ ar t Utilities/cmjsoncpp/libcmjsoncpp.a
> json_reader.cpp.o
> json_value.cpp.o
> json_writer.cpp.o

>From the binary you sent me:

```
$ file Utilities/cmjsoncpp/CMakeFiles/cmjsoncpp.dir/src/lib_json/*.o
Utilities/cmjsoncpp/CMakeFiles/cmjsoncpp.dir/src/lib_json/json_reader.cpp.o: 
empty
Utilities/cmjsoncpp/CMakeFiles/cmjsoncpp.dir/src/lib_json/json_value.cpp.o:  
empty
Utilities/cmjsoncpp/CMakeFiles/cmjsoncpp.dir/src/lib_json/json_writer.cpp.o: 
ELF 32-bit LSB relocatable, ARM, EABI5 version 1 (SYSV), not stripped
```

Somehow two of the .o files ended up empty.  The Makefile content
looks fine and the command line to compile is the same for all
three sources.  Is this reproducible?  If you remove the two empty
files and build again do they still end up empty?

-Brad
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake-developers


Re: [cmake-developers] Compiling CMake 3.6.1 fails on Raspbian Jessie

2016-09-05 Thread Cristian Adam
On Mon, Sep 5, 2016 at 10:33 PM, Brad King  wrote:

> On 09/05/2016 04:01 PM, Cristian Adam wrote:
> > [ 62%] Built target cmjsoncpp
> [snip]
> > [ 93%] Linking CXX executable ../bin/cmake
> > libCMakeLib.a(cmGlobalGenerator.cxx.o): In function `cmGlobalGenerator::
> WriteSummary(cmGeneratorTarget*)':
> > cmGlobalGenerator.cxx:(.text+0x117a8): undefined reference to
> `Json::Value::Value(Json::ValueType)'
> [snip]
> > ../Utilities/cmjsoncpp/libcmjsoncpp.a(json_writer.cpp.o): In function
> `Json::FastWriter::writeValue(Json::Value const&)':
> [snip]
> > No idea why it can't find its own cmjsoncpp library
>
> Actually it is finding the library because some of the error messages
> reference objects in it.  Something goes wrong with finding some of
> the symbols in it, such as some from `json_value.cpp`.
> What is the output of?
>
> $ ar t Utilities/cmjsoncpp/libcmjsoncpp.a
>
>
$ ar t Utilities/cmjsoncpp/libcmjsoncpp.a
json_reader.cpp.o
json_value.cpp.o
json_writer.cpp.o

Cheers,
Cristian.
-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake-developers

Re: [cmake-developers] Compiling CMake 3.6.1 fails on Raspbian Jessie

2016-09-05 Thread Brad King
On 09/05/2016 04:01 PM, Cristian Adam wrote:
> [ 62%] Built target cmjsoncpp
[snip]
> [ 93%] Linking CXX executable ../bin/cmake
> libCMakeLib.a(cmGlobalGenerator.cxx.o): In function 
> `cmGlobalGenerator::WriteSummary(cmGeneratorTarget*)':
> cmGlobalGenerator.cxx:(.text+0x117a8): undefined reference to 
> `Json::Value::Value(Json::ValueType)'
[snip]
> ../Utilities/cmjsoncpp/libcmjsoncpp.a(json_writer.cpp.o): In function 
> `Json::FastWriter::writeValue(Json::Value const&)':
[snip]
> No idea why it can't find its own cmjsoncpp library

Actually it is finding the library because some of the error messages
reference objects in it.  Something goes wrong with finding some of
the symbols in it, such as some from `json_value.cpp`.
What is the output of?

$ ar t Utilities/cmjsoncpp/libcmjsoncpp.a

I don't have access to this platform so hopefully someone else can dig
into it further.  Perhaps some preprocessing differences cause symbol
mangling to be different across sources.

-Brad

-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake-developers


[cmake-developers] Compiling CMake 3.6.1 fails on Raspbian Jessie

2016-09-05 Thread Cristian Adam
Hi,

Compiling CMake for Raspberri Pi (Raspbian Jessie) used to work

simply as:

./bootstrap
make
sudo make install

with CMake 3.6.1, build fails with:

make
[  3%] Built target cmsys
[  3%] Built target cmsysTestDynload
[  4%] Built target cmsys_c
[  4%] Built target cmsysTestProcess
[  5%] Built target cmsysTestSharedForward
[  5%] Built target cmsysTestsC
[  7%] Built target cmsysTestsCxx
[  9%] Built target kwiml_test
[ 11%] Built target cmzlib
[ 30%] Built target cmcurl
[ 30%] Built target LIBCURL
[ 30%] Built target cmcompress
[ 31%] Built target cmbzip2
[ 42%] Built target cmliblzma
[ 60%] Built target cmlibarchive
[ 61%] Built target cmexpat
*[ 62%] Built target cmjsoncpp*
[ 82%] Built target CMakeLib
[ 85%] Built target CPackLib
[ 93%] Built target CTestLib
[ 93%] Linking CXX executable ../bin/cmake
libCMakeLib.a(cmGlobalGenerator.cxx.o): In function
`cmGlobalGenerator::WriteSummary(cmGeneratorTarget*)':
cmGlobalGenerator.cxx:(.text+0x117a8): undefined reference to
`Json::Value::Value(Json::ValueType)'
cmGlobalGenerator.cxx:(.text+0x117b8): undefined reference to
`Json::Value::operator[](char const*)'
cmGlobalGenerator.cxx:(.text+0x117cc): undefined reference to
`Json::Value::Value(Json::ValueType)'
cmGlobalGenerator.cxx:(.text+0x117dc): undefined reference to
`Json::Value::operator=(Json::Value)'
cmGlobalGenerator.cxx:(.text+0x117f0): undefined reference to
`Json::Value::~Value()'
cmGlobalGenerator.cxx:(.text+0x117fc): undefined reference to
`Json::Value::operator[](char const*)'
cmGlobalGenerator.cxx:(.text+0x1181c): undefined reference to
`Json::Value::Value(std::string const&)'
cmGlobalGenerator.cxx:(.text+0x1182c): undefined reference to
`Json::Value::operator=(Json::Value)'
cmGlobalGenerator.cxx:(.text+0x11838): undefined reference to
`Json::Value::~Value()'
cmGlobalGenerator.cxx:(.text+0x11844): undefined reference to
`Json::Value::operator[](char const*)'
cmGlobalGenerator.cxx:(.text+0x11858): undefined reference to
`Json::Value::Value(Json::ValueType)'
cmGlobalGenerator.cxx:(.text+0x11868): undefined reference to
`Json::Value::operator=(Json::Value)'
cmGlobalGenerator.cxx:(.text+0x1187c): undefined reference to
`Json::Value::~Value()'
cmGlobalGenerator.cxx:(.text+0x1188c): undefined reference to
`Json::Value::operator[](char const*)'
cmGlobalGenerator.cxx:(.text+0x118a0): undefined reference to
`Json::Value::Value(Json::ValueType)'
cmGlobalGenerator.cxx:(.text+0x118b0): undefined reference to
`Json::Value::operator=(Json::Value)'
cmGlobalGenerator.cxx:(.text+0x118c4): undefined reference to
`Json::Value::~Value()'
cmGlobalGenerator.cxx:(.text+0x11a1c): undefined reference to
`Json::Value::Value(std::string const&)'
cmGlobalGenerator.cxx:(.text+0x11a2c): undefined reference to
`Json::Value::append(Json::Value const&)'
cmGlobalGenerator.cxx:(.text+0x11a38): undefined reference to
`Json::Value::~Value()'
cmGlobalGenerator.cxx:(.text+0x11c1c): undefined reference to
`Json::Value::Value(Json::ValueType)'
cmGlobalGenerator.cxx:(.text+0x11c2c): undefined reference to
`Json::Value::append(Json::Value const&)'
cmGlobalGenerator.cxx:(.text+0x11c40): undefined reference to
`Json::Value::~Value()'
cmGlobalGenerator.cxx:(.text+0x11c98): undefined reference to
`Json::Value::operator[](char const*)'
cmGlobalGenerator.cxx:(.text+0x11cac): undefined reference to
`Json::Value::Value(std::string const&)'
cmGlobalGenerator.cxx:(.text+0x11cbc): undefined reference to
`Json::Value::operator=(Json::Value)'
cmGlobalGenerator.cxx:(.text+0x11cc8): undefined reference to
`Json::Value::~Value()'
cmGlobalGenerator.cxx:(.text+0x11d40): undefined reference to
`Json::Value::operator[](char const*)'
cmGlobalGenerator.cxx:(.text+0x11d54): undefined reference to
`Json::Value::Value(Json::ValueType)'
cmGlobalGenerator.cxx:(.text+0x11d64): undefined reference to
`Json::Value::operator=(Json::Value)'
cmGlobalGenerator.cxx:(.text+0x11d78): undefined reference to
`Json::Value::~Value()'
cmGlobalGenerator.cxx:(.text+0x11e58): undefined reference to
`Json::Value::Value(std::string const&)'
cmGlobalGenerator.cxx:(.text+0x11e68): undefined reference to
`Json::Value::append(Json::Value const&)'
cmGlobalGenerator.cxx:(.text+0x11e74): undefined reference to
`Json::Value::~Value()'
cmGlobalGenerator.cxx:(.text+0x11f60): undefined reference to
`Json::Value::~Value()'
cmGlobalGenerator.cxx:(.text+0x11fd0): undefined reference to
`Json::Value::~Value()'
cmGlobalGenerator.cxx:(.text+0x11fe0): undefined reference to
`Json::Value::~Value()'
cmGlobalGenerator.cxx:(.text+0x11ff0): undefined reference to
`Json::Value::~Value()'
libCMakeLib.a(cmGlobalGenerator.cxx.o):cmGlobalGenerator.cxx:(.text+0x12000):
more undefined references to `Json::Value::~Value()' follow
../Utilities/cmjsoncpp/libcmjsoncpp.a(json_writer.cpp.o): In function
`Json::FastWriter::writeValue(Json::Value const&)':
json_writer.cpp:(.text+0xc4c): undefined reference to `Json::Value::type()
const'