ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
This is the output of Kdevelop 3.4.0 when I try to "run automake and friends"
I dont understand the line shown in bold below...
And, I do have both necessary autoconf and automake installed.
cd '/home/nikolay/internship/GPS/GPSSystem' && WANT_AUTOCONF_2_5="1" WANT_AUTOMAKE_1_6="1" make -f Makefile.cvs
This Makefile is only for the CVS repository
This will be deleted before making the distribution
./admin/cvs.sh: 632: ./admin/detect-autoconf.pl: Permission denied
./admin/cvs.sh: 651: --version: not found
*** AUTOCONF NOT FOUND!.
*** KDE requires autoconf 2.53 or newer
make: *** [cvs] Error 1
make: *** [all] Error 2
*** Exited with status: 2 ***
ok, i checked online for the "owner of the file on linux", and found the results about the file owner and etc...
So, made the folder of the whole project to be both read and write, and also an executable...
but still as i run automake and friends, i keep getting the same error...
This happened after I reinstalled my ubuntu. I just had this project backed up in my mailbox, and it worked perfectly fine before...
In the previous message I say that I have modified the rights, but actually I was modifying the rights by clicking on the main project folder, and saying something like: "apply permission to enclosed files", but then, when I looked at the detect-autoconf.pl I saw that the feature of "allow executing file as program" was not ticked... So I ticked it, and I could run automake and friends
But, now, I dunno what to do with the "there is no active target".
I can build and install the whole thing, but cannot execute. And, I did set in Automake Manager the option of set as Active target...
Oh, shit! hehe.
As i looked at the error message that was given when trying to execute...It told me smthing like:
src/gpssystem: permission denied
so, I had to modify the access right, namely the "allow executing file as program"... IT WORKS NOW!!
Thanks for listening to me hehe
Last edited by brownflamigo1; 07-25-2007 at 06:04 AM.
ok, I have more problems now though...
it is qwt that gives me problems.
After I installed it, and added a thermo widget to my project and tried to build, it told me that the header <qwt_thermo.h> did not exist, so I tried replacing the path of the header with the following one: #include </home/nikolay/qwt-5.0.2/src/qwt_thermo.h>, directly to the folder of the just newly installed qwt. So, it did not give me an error of nonexistance of the header, but instead it gives me now this problem, that I dont really understand..
cd '/home/nikolay/internship/GPS/GPSSystem' && WANT_AUTOCONF_2_5="1" WANT_AUTOMAKE_1_6="1" make -k
Making all in doc
Making all in .
make: Nothing to be done for `all-am'.
Making all in en
make: Nothing to be done for `all'.
Making all in po
make: Nothing to be done for `all'.
Making all in src
compiling gpssystemdialog.cpp (g++)
mv -f .deps/gpssystemdialog.Tpo .deps/gpssystemdialog.Po
linking gpssystem (g++)
gpssystemdialog.o: In function `GpsSystem::GpsSystem(QWidget*, char const*, unsigned int)':
gpssystemdialog.cpp:(.text+0x25e0): undefined reference to `QwtThermo::QwtThermo(QWidget*, char const*)'
gpssystemdialog.cpp:(.text+0x268d): undefined reference to `QwtThermo::QwtThermo(QWidget*, char const*)'
gpssystemdialog.cpp:(.text+0x273a): undefined reference to `QwtThermo::QwtThermo(QWidget*, char const*)'
gpssystemdialog.cpp:(.text+0x27e7): undefined reference to `QwtThermo::QwtThermo(QWidget*, char const*)'
gpssystemdialog.cpp:(.text+0x2894): undefined reference to `QwtThermo::QwtThermo(QWidget*, char const*)'
gpssystemdialog.o:gpssystemdialog.cpp:(.text+0x2941): more undefined references to `QwtThermo::QwtThermo(QWidget*, char const*)' follow
collect2: ld returned 1 exit status
make: *** [gpssystem] Error 1
make: Target `all' not remade because of errors.
make: *** [all-recursive] Error 1
make: *** [all] Error 2
*** Exited with status: 2 ***
This is, like the constructor is not defined... for all of the 16 thermos that I added.... very weird. And I was getting the same problem, like a week or two weeks ago when I was trying this out, but then I had to switch to do a different task.
Please clarify whats going on No google results for
undefined reference to `QwtThermo::QwtThermo(QWidget*, char const*)'
I have tried which seems to me EVERYTHING in the past couple of hours, but I could not still resolve the above problem....
I am really getting frustrated about this issue....
I tried doing something like including paths for the headers, and etc... I dont really remember everything now, but i namely tried to do: Project Options->Configure Options->Linker Flags:-L/usr/include/qwt
and i cannot locate qwt_thermo.cpp or any other qwt_*'s
It seems as if they are missing at all.
I tried reinstalling qwt, but still.
Help out please
Last edited by brownflamigo1; 07-25-2007 at 10:13 AM.
First compile qwt. I assume it's already done. You'll need to link to it.
Now, linking flags. You have done: Project Options->Configure Options->Linker Flags:-L/usr/include/qwt
It'd be OK for include flags (-I). -L specifies the directory where library's binary is. You should have libqwt.a somewhere in the qwt directory. -L will be something like -Lqwt/lib or, if qwt is installed, something like -L/usr/local/lib/. But the directory will be not enough. You need to tell the compiler to link your program with the library. -l option is used for this. In your case -lqwt (it means you want to link with libqwt.a).
So, finally, your linker flags should be something like
QwtThermo::QwtThermo(QWidget * parent = NULL) [explicit]
QwtThermo::QwtThermo(QWidget*, char const*)
I have not looked into the library, but it's standard for the Qt-based libraries to have both versions. If the char const * parameter is not given, the default should be used. So, the way you use the constructor should not cause problems.
So, I dont see how making it link against -lqwt is equivalent as to linking against the libqwt.a? Is it something "like predefined" or what? i mean, that I did not have to specify the pass all the way up to the libqwt.a? And, actually I tried specifying the pass like: -l/usr/lib/libqwt.a and it gave me some WARNING about "newline something something...". weird...
I tried searching for linking in Kdevelop, but didnt really get any explanatory result, something like a step by step walkthrough. Do you have any link by any chance where I can read more about linking in Kdevelop, so that I dont bother anyone again if this sort of problem occurs
thanks again, I really appreciate you helping.
It's not a KDevelop-specific issue. -l is a gcc (compiler) option. The library name form is customary and have a long tradition. You may consider it predefined. You do not need to specify the whole path in -l, but it should be known to the linker. If it's not in th edefaults, you still need to use -L option to specify the path (as I did in the example three posts above).
The manual says:
Use the library named library when linking.
The linker searches a standard list of directories for the library, which is actually a file named `lib library .a'. The linker then uses this file as if it had been specified precisely by name.
The directories searched include several standard system directories plus any that you specify with `-L '.
Normally the files found this way are library files archive files whose members are object files. The linker handles an archive file by scanning through it for members which define symbols that have so far been referenced but not defined. However, if the linker finds an ordinary object file rather than a library, the object file is linked in the usual fashion. The only difference between using an `-l ' option and specifying a file name is that `-l ' surrounds library with `lib ' and `.a ' and searches several directories.