|
|
> Here's a thing, can you try this, and post the results, please? This is from my everyday machine, which has FLTK 1.4 build in home path, but it's not installed. Thanks!
[ken01@Manjaro home]$ which fltk-config /usr/local/bin/fltk-config
[ken01@Manjaro home]$ fltk-config --version 1.4.0
[ken01@Manjaro home]$ fltk-config --cxxflags -I/usr/local/include -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_THREAD_SAFE -D_REENTRANT
[ken01@Manjaro home]$ fltk-config --ldflags -L/usr/local/lib -lfltk -lm -lX11 -lXext -lpthread -lXinerama -lXfixes -lXcursor -lXft -lXrender -lm -lfontconfig -ldl
[ken01@Manjaro home]$ fltk-config --includedir /usr/local/include
On Monday, April 26, 2021 at 6:58:01 PM UTC+2 Ian MacArthur wrote:
On Monday, 26 April 2021 at 11:31:31 UTC+1 ken wrote:
> So, when you say you installed 1.3.5, and then installed 1.4; did you un-install 1.3.5 before you installed 1.4?
yes, I uninstalled 1.3.5 before installing 1.4 - and 1.4 did not worked then I uninstalled 1.4 and re-install 1.3.5 and 1.3.5 didn't work this time so the only time it worked was at the first install (of 1.3.5)
That is curious, and somewhat unsettling...
Here's a thing, can you try this, and post the results, please?
In a shell, enter which fltk-config
What result do you get? If it says something like "which: fltk-config: unknown command" then the fltk-config script is not accessible in your path, and as a result the Makefile that uses it will then fail.
If it says something like... "/usr/bin/fltk-config" or similar, that's possibly OK, and can you then try the following commands and post the results:
fltk-config --version
fltk-config --cxxflags
fltk-config --ldflags
fltk-config --includedir
(Note: there are *two* "-" in each of those parameters!)
> I don't know Manjaro, or how it sets things up, but when I see a path like "/run/media" I assume it is a path to a removable medium it's a path to a NTFS partition on the same disk with my / and /home partitions for Linux. I was a Windows user until recently so the biggest partition is NTFS. I wanted to have FLTK there so I could use it from Windows too (and build in a different subfolder). If it's something wrong with that, I could increase the size /home to have a path like you said
If you are more familiar with Windows, you might get better results in a Windows environment anyway? Fltk doesn't care and ISTR that Dr.S.'s book was originally written for a Windows setup? Or, if you want a "posix-like" experience in Windows, just install Mingw with Msys, and use that (I usually do!)
################ template makefile ############## # We don't know what compiler to use to build fltk on this machine - but fltk-config does... CXX = $(shell fltk-config --cxx)
# Set the flags for compiler: fltk-config knows the basic settings, then we can add our own... CXXFLAGS = $(shell fltk-config --cxxflags) -w -Wall -std=c++14 -O3 -I/other/include/paths... -I/run/media/repos/fltk-1.4.x/ -I/run/media/repos/fltk-1.4.x/build/ -I/run/media/repos/fltk-1.4.x/build/lib/
This looks *very* suspicious. The fltk-config command should be returning pretty much *all* of this, so you should never have to add the explicit references to the fltk repo. (fltk-config should generate them for you) So I think that command should only look like:
CXXFLAGS = $(shell fltk-config --cxxflags) -Wall -std=c++14 -O3 -i /include/path/for/PPP/headers
I would suggest.
# We don't know what libraries to link with: fltk-config does... LINKFLTK = $(shell fltk-config --ldstaticflags) LINKFLTK_GL = $(shell fltk-config --use-gl --ldstaticflags) LINKFLTK_IMG = $(shell fltk-config --use-images --ldstaticflags)
# Define what your target application is called all: 13.12_circle.bin
# Define how to build the various object files...
Graph.o: Graph.cpp Graph.H $(CXX) -c $< $(CXXFLAGS)
Window.o: Window.cpp Window.H $(CXX) -c $< $(CXXFLAGS)
GUI.o: GUI.cpp GUI.H $(CXX) -c $< $(CXXFLAGS)
Simple_window.o: Simple_window.cpp Simple_window.H $(CXX) -c $< $(CXXFLAGS)
13.12_circle.o: 13.12_circle.cpp $(CXX) -c $< $(CXXFLAGS)
# Now define how to link the final app - let's assume it needs image and OpenGL support 13.12_circle.bin: Graph.o Window.o GUI.o Simple_window.o 13.12_circle.o $(CXX) -o $@ Graph.o Window.o GUI.o Simple_window.o 13.12_circle.o $(LINKFLTK) $(LINKFLTK_GL) $(LINKFLTK_IMG)
clean: rm -rf *.o
############### end #################
--
You received this message because you are subscribed to the Google Groups "fltk.general" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fltkgeneral+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/fltkgeneral/687e3f46-7596-43e0-b3ac-37f2a5b1089dn%40googlegroups.com.
[ Direct Link to Message ] | |
|
| |