Closed N0ury closed 4 years ago
Are you sure that you used the correct fork of libnspire? It makes sense that you get errors with the original, as the cx2
in packet_recv_cx2
didn't exist when it was last updated.
Thanks @lights0123
I've just realized that I was using a shared directory between MacOS and Linux. In fact, at make time I was using the Mac configure result.
So under Linux, I have removed the directory and cloned again the project "libnspire" and "fuse-nspire" But with libnspire, make doesn't work. It says:
CDPATH="${ZSH_VERSION+.}:" && cd . && /bin/bash /home/c0238/Dropbox/divers/fouretout/libnspire/missing aclocal-1.13
/home/c0238/Dropbox/divers/fouretout/libnspire/missing: line 81: aclocal-1.13: command not found
WARNING: 'aclocal-1.13' is missing on your system.
You should only need it if you modified 'acinclude.m4' or
'configure.ac' or m4 files included by 'configure.ac'.
The 'aclocal' program is part of the GNU Automake package:
<http://www.gnu.org/software/automake>
It also requires GNU Autoconf, GNU m4 and Perl in order to run:
<http://www.gnu.org/software/autoconf>
<http://www.gnu.org/software/m4/>
<http://www.perl.org/>
make: *** [Makefile:355: aclocal.m4] Error 127
On my system, I have aclocal-1.16 and automake-1.16. I don't know how to change the project for using 1.16 versions. Do I have to open an issue on the right project (libnspire)
I'm using Debian sid.
I had the same issue. Running autoreconf -f -i
fixed it. I'm on Arch Linux, and libnspire seems to want to install itself in a nonstandard directory, so I had to run PKG_CONFIG_PATH=/usr/local/lib/pkgconfig make
and LD_LIBRARY_PATH=/usr/local/lib ./nspire
in this repo.
Oh thanks. libnspire compiles fine now
But with fuse-nspire I can't build nspire file. I see:
make
cc -c -DFUSE_USE_VERSION=26 -D_FILE_OFFSET_BITS=64 -I/usr/include/fuse -O3 -Wall -I/usr/local/include/libnspire -I/usr/include/libusb-1.0 -o nspire.o nspire.c
cc -c -DFUSE_USE_VERSION=26 -D_FILE_OFFSET_BITS=64 -I/usr/include/fuse -O3 -Wall -I/usr/local/include/libnspire -I/usr/include/libusb-1.0 -o dir.o dir.c
cc -c -DFUSE_USE_VERSION=26 -D_FILE_OFFSET_BITS=64 -I/usr/include/fuse -O3 -Wall -I/usr/local/include/libnspire -I/usr/include/libusb-1.0 -o file.o file.c
cc -c -DFUSE_USE_VERSION=26 -D_FILE_OFFSET_BITS=64 -I/usr/include/fuse -O3 -Wall -I/usr/local/include/libnspire -I/usr/include/libusb-1.0 -o stat.o stat.c
cc -o nspire -lfuse -pthread -L/usr/local/lib -lnspire -lusb-1.0 -O3 -Wall -I/usr/local/include/libnspire -I/usr/include/libusb-1.0 nspire.o dir.o file.o stat.o
/usr/bin/ld: nspire.o: in function `main':
nspire.c:(.text.startup+0x39): undefined reference to `nspire_init'
/usr/bin/ld: nspire.c:(.text.startup+0x6d): undefined reference to `fuse_opt_parse'
/usr/bin/ld: nspire.c:(.text.startup+0x90): undefined reference to `fuse_main_real'
/usr/bin/ld: nspire.c:(.text.startup+0x9c): undefined reference to `nspire_free'
/usr/bin/ld: nspire.c:(.text.startup+0xd9): undefined reference to `nspire_strerror'
/usr/bin/ld: dir.o: in function `nsp_readdir':
dir.c:(.text+0x16): undefined reference to `fuse_get_context'
/usr/bin/ld: dir.c:(.text+0x28): undefined reference to `fuse_get_context'
/usr/bin/ld: dir.c:(.text+0x3c): undefined reference to `nspire_dirlist'
/usr/bin/ld: dir.c:(.text+0xa4): undefined reference to `nspire_dirlist_free'
/usr/bin/ld: dir.c:(.text+0xa9): undefined reference to `fuse_get_context'
/usr/bin/ld: dir.o: in function `nsp_mkdir':
dir.c:(.text+0xe5): undefined reference to `fuse_get_context'
/usr/bin/ld: dir.c:(.text+0xf7): undefined reference to `fuse_get_context'
/usr/bin/ld: dir.c:(.text+0x106): undefined reference to `nspire_dir_create'
/usr/bin/ld: dir.c:(.text+0x10d): undefined reference to `fuse_get_context'
/usr/bin/ld: dir.o: in function `nsp_rmdir':
dir.c:(.text+0x135): undefined reference to `fuse_get_context'
/usr/bin/ld: dir.c:(.text+0x147): undefined reference to `fuse_get_context'
/usr/bin/ld: dir.c:(.text+0x156): undefined reference to `nspire_dir_delete'
/usr/bin/ld: dir.c:(.text+0x15d): undefined reference to `fuse_get_context'
/usr/bin/ld: dir.o: in function `nsp_rename':
dir.c:(.text+0x18e): undefined reference to `fuse_get_context'
/usr/bin/ld: dir.c:(.text+0x1a0): undefined reference to `fuse_get_context'
/usr/bin/ld: dir.c:(.text+0x1b2): undefined reference to `nspire_file_move'
/usr/bin/ld: dir.c:(.text+0x1b9): undefined reference to `fuse_get_context'
/usr/bin/ld: dir.o: in function `nsp_delete':
dir.c:(.text+0x1e5): undefined reference to `fuse_get_context'
/usr/bin/ld: dir.c:(.text+0x1f7): undefined reference to `fuse_get_context'
/usr/bin/ld: dir.c:(.text+0x206): undefined reference to `nspire_file_delete'
/usr/bin/ld: dir.c:(.text+0x20d): undefined reference to `fuse_get_context'
/usr/bin/ld: file.o: in function `nsp_truncate':
file.c:(.text+0x13): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x2e): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x40): undefined reference to `nspire_attr'
/usr/bin/ld: file.c:(.text+0x4d): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x65): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x94): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0xac): undefined reference to `nspire_file_read'
/usr/bin/ld: file.c:(.text+0xb9): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0xce): undefined reference to `nspire_file_write'
/usr/bin/ld: file.c:(.text+0xe6): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x121): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x137): undefined reference to `nspire_file_write'
/usr/bin/ld: file.o: in function `nsp_open':
file.c:(.text+0x1a8): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x1ba): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x1cc): undefined reference to `nspire_attr'
/usr/bin/ld: file.c:(.text+0x1dc): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x24c): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x281): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x2a5): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x2bd): undefined reference to `nspire_file_read'
/usr/bin/ld: file.o: in function `nsp_create':
file.c:(.text+0x321): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x333): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x345): undefined reference to `nspire_attr'
/usr/bin/ld: file.c:(.text+0x353): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x366): undefined reference to `nspire_file_write'
/usr/bin/ld: file.c:(.text+0x36f): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x3ab): undefined reference to `fuse_get_context'
/usr/bin/ld: file.o: in function `nsp_fsync':
file.c:(.text+0x528): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x549): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x55e): undefined reference to `nspire_file_write'
/usr/bin/ld: file.c:(.text+0x580): undefined reference to `fuse_get_context'
/usr/bin/ld: file.o: in function `nsp_release':
file.c:(.text+0x610): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x632): undefined reference to `fuse_get_context'
/usr/bin/ld: file.c:(.text+0x647): undefined reference to `nspire_file_write'
/usr/bin/ld: file.c:(.text+0x669): undefined reference to `fuse_get_context'
/usr/bin/ld: stat.o: in function `nsp_statfs':
stat.c:(.text+0xe): undefined reference to `fuse_get_context'
/usr/bin/ld: stat.c:(.text+0x20): undefined reference to `fuse_get_context'
/usr/bin/ld: stat.c:(.text+0x2f): undefined reference to `nspire_device_info'
/usr/bin/ld: stat.c:(.text+0x8b): undefined reference to `fuse_get_context'
/usr/bin/ld: stat.o: in function `nsp_getattr':
stat.c:(.text+0xd1): undefined reference to `fuse_get_context'
/usr/bin/ld: stat.c:(.text+0xe3): undefined reference to `fuse_get_context'
/usr/bin/ld: stat.c:(.text+0xf5): undefined reference to `nspire_attr'
/usr/bin/ld: stat.c:(.text+0x183): undefined reference to `fuse_get_context'
/usr/bin/ld: stat.o: in function `nsp_access':
stat.c:(.text+0x1ce): undefined reference to `fuse_get_context'
/usr/bin/ld: stat.c:(.text+0x1e0): undefined reference to `fuse_get_context'
/usr/bin/ld: stat.c:(.text+0x1f2): undefined reference to `nspire_attr'
/usr/bin/ld: stat.c:(.text+0x1fe): undefined reference to `fuse_get_context'
/usr/bin/ld: stat.c:(.text+0x20e): undefined reference to `fuse_get_context'
/usr/bin/ld: stat.c:(.text+0x239): undefined reference to `fuse_get_context'
collect2: error: ld returned 1 exit status
make: *** [Makefile:21: nspire] Error 1
An idea?
I did not get that error, and I have no clue why you did. It looks like it passed the correct linker args.
I have found. I need to replace: $(CC) -o $@ $(LIBS) $(CFLAGS) $^ with $(CC) -o $@ $^ $(LIBS) $(CFLAGS) .o files must be before libraries
It works fine now.
Thanks for all.
At make time, I have the following error:
Here are some more informations:
And finally, the strangest:
But libnspire compiles with no errors.
Am I doing something wrong?