HalfHour / libnxt

Automatically exported from code.google.com/p/libnxt
GNU General Public License v2.0
0 stars 0 forks source link

Code will not compile (Ubuntu 10.10) #4

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. svn checkout http://libnxt.googlecode.com/svn/trunk/ libnxt-read-only
2. cd libnxt-read-only
3. scons

What is the expected output? What do you see instead?

jadler@server:~/dl/lego/libnxt/libnxt-read-only$ scons
scons: Reading SConscript files ...

scons: warning: The Options class is deprecated; use the Variables class 
instead.
File "/home/jadler/dl/lego/libnxt/libnxt-read-only/SConstruct", line 8, in 
<module>

scons: warning: The BoolOption() function is deprecated; use the BoolVariable() 
function instead.
File "/home/jadler/dl/lego/libnxt/libnxt-read-only/SConstruct", line 14, in 
<module>
Checking for C library usb... yes
scons: done reading SConscript files.
scons: Building targets ...
gcc -o samba.o -c -Wall -Werror -std=gnu99 -D_NXT_LITTLE_ENDIAN -O3 samba.c
cc1: warnings being treated as errors
samba.c: In function 'nxt_read_common':
samba.c:107: error: dereferencing type-punned pointer will break 
strict-aliasing rules
scons: *** [samba.o] Error 1
scons: building terminated because of errors.
jadler@server:~/dl/lego/libnxt/libnxt-read-only$

What version of the product are you using? On what operating system?

This attempt used version 'trunk', latest from 4 years ago.

Ubuntu 10.10 amd64

Please provide any additional information below.

jadler@server:~/dl/lego/libnxt/libnxt-read-only$ apt-cache policy libusb-dev
libusb-dev:
  Installed: 2:0.1.12-15ubuntu2
  Candidate: 2:0.1.12-15ubuntu2
  Version table:
 *** 2:0.1.12-15ubuntu2 0
        500 http://se.archive.ubuntu.com/ubuntu/ maverick/main amd64 Packages
        100 /var/lib/dpkg/status
jadler@server:~/dl/lego/libnxt/libnxt-read-only$ apt-cache policy libusb-0.1-4
libusb-0.1-4:
  Installed: 2:0.1.12-15ubuntu2
  Candidate: 2:0.1.12-15ubuntu2
  Version table:
 *** 2:0.1.12-15ubuntu2 0
        500 http://se.archive.ubuntu.com/ubuntu/ maverick/main amd64 Packages
        100 /var/lib/dpkg/status
jadler@server:~/dl/lego/libnxt/libnxt-read-only$ apt-cache policy libusb-1.0-0
libusb-1.0-0:
  Installed: 2:1.0.8-2
  Candidate: 2:1.0.8-2
  Version table:
 *** 2:1.0.8-2 0
        500 http://se.archive.ubuntu.com/ubuntu/ maverick/main amd64 Packages
        100 /var/lib/dpkg/status
jadler@server:~/dl/lego/libnxt/libnxt-read-only$ apt-cache policy 
libusb-1.0-0-dev
libusb-1.0-0-dev:
  Installed: 2:1.0.8-2
  Candidate: 2:1.0.8-2
  Version table:
 *** 2:1.0.8-2 0
        500 http://se.archive.ubuntu.com/ubuntu/ maverick/main amd64 Packages
        100 /var/lib/dpkg/status
jadler@server:~/dl/lego/libnxt/libnxt-read-only$ apt-cache policy scons
scons:
  Installed: 2.0.0-1
  Candidate: 2.0.0-1
  Version table:
 *** 2.0.0-1 0
        500 http://se.archive.ubuntu.com/ubuntu/ maverick/main amd64 Packages
        100 /var/lib/dpkg/status
jadler@server:~/dl/lego/libnxt/libnxt-read-only$ 

Original issue reported on code.google.com by johan.ad...@gmail.com on 14 Mar 2011 at 10:04

GoogleCodeExporter commented 8 years ago
OK, the non-trunk version, 0.3, actually compiled with just a warning:

jadler@server:~/dl/lego/libnxt/libnxt-0.3$ scons
scons: Reading SConscript files ...
scons: done reading SConscript files.
scons: Building targets ...
gcc -o samba.o -c -Wall -std=gnu99 -g -ggdb -D_NXT_LITTLE_ENDIAN samba.c
gcc -o error.o -c -Wall -std=gnu99 -g -ggdb -D_NXT_LITTLE_ENDIAN error.c
./make_flash_header.py
./make_flash_header.py:15: DeprecationWarning: the sha module is deprecated; 
use the hashlib module instead
  import sha
gcc -o firmware.o -c -Wall -std=gnu99 -g -ggdb -D_NXT_LITTLE_ENDIAN firmware.c
gcc -o flash.o -c -Wall -std=gnu99 -g -ggdb -D_NXT_LITTLE_ENDIAN flash.c
gcc -o lowlevel.o -c -Wall -std=gnu99 -g -ggdb -D_NXT_LITTLE_ENDIAN lowlevel.c
ar rc libnxt.a samba.o error.o firmware.o flash.o lowlevel.o
ranlib libnxt.a
gcc -o main_fwflash.o -c -Wall -std=gnu99 -g -ggdb -D_NXT_LITTLE_ENDIAN 
main_fwflash.c
gcc -o fwflash main_fwflash.o -L. -lusb -lnxt
gcc -o main_fwexec.o -c -Wall -std=gnu99 -g -ggdb -D_NXT_LITTLE_ENDIAN 
main_fwexec.c
gcc -o fwexec main_fwexec.o -L. -lusb -lnxt
scons: done building targets.
jadler@server:~/dl/lego/libnxt/libnxt-0.3$ 

I guess problems are to be expected with old and unmaintained code.

Original comment by johan.ad...@gmail.com on 14 Mar 2011 at 10:08