qhyccd-lzr / QHYCCD_Linux_New

This repository contains a new (2017+) QHYCCD's Ubuntu Linux 64 and ARM V8 (Raspberry PI3, Odroid XU4) deliveries.
8 stars 3 forks source link

Problems with gcc 4.9 on ubuntu 14.04 #1

Open mikee512 opened 7 years ago

mikee512 commented 7 years ago

The samples will not compile due to _cxx11 library references. I can't use the library in projects that reference it. Any ideas what I can do to fix this or do I need a library from you compiled with 4.9 ?

qhyccd-lzr commented 7 years ago

Hi, are you talking about using that stuff on RPI 3? Could you be more specific, please ? Jan ---------- Původní e-mail ---------- Od: mikee512 notifications@github.com Komu: qhyccd-lzr/QHYCCD_Linux_New QHYCCD_Linux_New@noreply.github.com Datum: 4. 9. 2017 10:20:22 Předmět: [qhyccd-lzr/QHYCCD_Linux_New] Problems with gcc 4.9 on ubuntu 14.04 (#1) " The samples will not compile due to _cxx11 library references. I can't use the library in projects that reference it. Any ideas what I can do to fix this or do I need a library from you compiled with 4.9 ?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub (https://github.com/qhyccd-lzr/QHYCCD_Linux_New/issues/1), or mute the thread (https://github.com/notifications/unsubscribe-auth/AE-NVPJFtQqaHMNwGmQ20dc_cNJJUu7Pks5se7K_gaJpZM4PLmL3) .

"

mikee512 commented 7 years ago

Thanks Jan, Sorry about the confusion.

No, this is no RPI. I am trying to get PHD2 to run under linux on a chromebook using a QHY5L-II-M. I am running Ubuntu 14.04 in a chroot on chromeos/linux kernel 3.18.0. I originally tried the QHYCCD_Linux repo but it appears it was built for 32 bit and quite old. I then saw your new repo and installed the linux libraries. They appear to be compiled with gcc 5 (GLIBCXX 3.4.21). This caused problems for me since I am on gcc 4.8 (GLIBC 3.4.18).

I installed gcc-5 as an alternative. Once I got the library to compile with gcc-5 I went back to the QHYCCD_Linux code to see if I could get the examples to compile and run against it. I could not use the cmake build but was able to manually compile and link (I am using cmake 3.4.1 upgraded since PHD2 needs at least this version). The examples do not find any cameras. I suspect this may be due to the way chromeos splits udev between the chroot and host. I think I may need to run fxload manually to get the firmware in the camera to be recognized buy the library. I am looking at that today.

I am a bit concerned about loading firmware in the camera since it is brand new but from what it appears the firmware is not retained after power loss since it is loaded on every USB detection in 85-qhyccd.rules. Is this correct ?

Once I get this done I still need to integrate the support into PHD2 which I suspect it going to have its own problems with gcc-5.

Thanks for the follow up,

mikee512 commented 7 years ago

Success! If I run fxload manually I can connect the camera in phd2. Just need to get all the components aligned for building.

mikee512 commented 7 years ago

I can link if I use the shared library but I can't link with the object library.

If I try to use the .a file I get the following error:

/usr/bin/ld: /home/mike/ssd/git/phd2/cameras/qhyccdlibs/linux/x86_64/libqhy.a(qhyccd.cpp.o): unrecognized relocation (0x2a) in section `.text' /usr/bin/ld: final link failed: Bad value collect2: error: ld returned 1 exit status

This file is a link to the QHYCCD_Linux_New libraries.