Re: Read Signal from ADC on Raspberry Pi with FLTK
Albrecht Schlosser
Oct 21, 2020
On 10/21/20 4:48 PM LosCelos wrote:
mistake from my side:
i dont need the makefile. I can compile the shown adc program in
terminal with: gcc testADC.c -o testADC -lwiringPi
i compile the fltk App with: fltk-config --compile app.cxx
the problem is that i cant put the needed -lwiringPi in the compile
line from the fltk
The "easiest" way to do this is to use `fltk-config --compile app.cxx`,
copy the command line you see and run the entire command on a new
command (copy and paste). Then "go back" one line in your shell
(typically by using the uparrow key) and edit the command line, i.e. put
'-lwiringPi' before or after '-lfltk' or at another appropriate place.
OTOH, I'd likely save the command file in a shell script and edit this
script for my build so I can easily repeat it. If you like you can also
use a combination of a simple Makefile that uses `fltk-config
--cxxflags' and `fltk-config --ld[static]flags' to get the proper FLTK
flags.
Given your command above, you could probably build your app using:
Comments are owned by the poster. All other content is copyright 1998-2025 by Bill Spitzak and others. This project is hosted by The FLTK Team. Please report site problems to 'erco@seriss.com'.