Programming :: Way To Add Some Sort Of I-/usr/include Commands
Feb 27, 2011
I'm learning GTK , and would like to use Codeblocks, and/or KDEvelop, and compile my c files using that, but always get an error about gtk/gtk.h not found, but can't figure out how to add the commands... I normally type gcc -o Program1 main.c `pkg-config --libs --cflags gtk+-2.0` That's a lot to type every time to compile.. Isn't there an easier way, in KDevelop, Monodevelop, and/or Codeblocks to make this step quicker, by adding some sort of I-/usr/include commands, or something?? thanks in advance, =). I looked online for some results, but didn't come across anything handy..
What options should I use when I'm using the sort command to sort the top 5 CPU processes (ps -eo user,pid,ppid,%cpu,%mem,fname | sort ??? | head -5) showing max to min usage?
We switched from unix to linux and we have an old report that extracted data from a database, output to an ascii file and then sorted the results in the file based on different arguments. The report now blows up when it runs,and I can only guess it is because the options for sort on linux differ slightly from unix.For example, here is one of the commands issued from within the report app that ran on the old unix box:
I will eventually rewrite the report to store the data in a local table, but I can simply adjust the options to suit the requirments of linux. Basically, I need to know if this can be a quick fix for the short term.
I am working on a Linux embedded C++ project. When I do an install, all of the header files are copied into the target at /usr/include/.My question is, why would the target ever need the C++ header files? It seems to me all the target needs is the executables and the library *.so files.I want to remove the installation of header files into the target but I'm afraid I'm missing something.
Basically I have a dir that contains my makefile and another directory inside this called source this holds main source files. External to these I have a couple of dirs common and drives.
In my make file I use
To include the protoypes from the headers in the folders common and drivers used by source, this works fine. However in common and drivers I use a few variables that are set in the source dir. I set these with externs inside the common and driver files. However I'm sure I should be able to set the directory path for source inside my makefile. So say I have inside source hardware.h with prototypes, I set DINCDIR = -I/Source -I../Drivers -I../CommonFiles
Then from a c file inside my common folder I say #include "hardware.h" the file should be able to see hardware.h and it's protoypes. However I get:
Is there some way I can get the extern dirs to see the source dir?
What's the best way to include variables in a string using C,i.e if i want to do the following query in C, how would i do that.How do i build the string variable up in C?
I am trying to re-write my local web pages in HTML5. My original pages used an include file so that I had a consistent set of links on the top of each page. I used - require("link_list.php");
But this does not seem to be possible in HTML5. I am guessing that there is a way to do this, searching the web suggests object or embed, but these create a new page within my original page, which is not what I want.
For gcc, it seems that there are multiple include paths like /usr/include and /usr/src/linux/include. How do I check the current include path for gcc via command line? How do I edit it?
I am trying to learn how to include common elements on every page. At first I made the mistake of calling it ssi but I do not think that is correct in php5. I downloaded phpb3 to look at and they are not doing it that way. they do it like this. Code...
Problem is I can not find any articles that explain it. I even looked at the php manual and did not find it. Could someone explain this or point me in the right direction.
I have installed QT on Slackware 13.37 x64 and when I create gui project it works ok, but I need OpenGL.When I add #include <QGLWidget>I get error No such file or directory there is my env
What is the difference between /usr/local/include and /usr/include? When I compile my program, is both /usr/local/include and /usr/include avaliable? Can I copy a file from /usr/local/include to /usr/include?
I just downloaded the SDL source code. i did compile and make of this code.then i did make install. but i didnt see the files of SDL.h and lib.SDL.*** in /usr/include/ but later i found out that these files are placed in /usr/local/include and /usr/local/lib. how can i specifically install libraries on /usr/include and /usr/lib
I use OpenSuse 11.3, Eclipse Elios for C++. What do I have to do for using boost? I put #include <boost/regex.hpp>, but it can't find the file. What variable do I have to use?
The above command does exactly what I want: limit the search of files in $SEARCHDIR to those specified by --include.
I use double quotes rather than single quotes because of the shell variables. I would have thought this would cause the shell to expand the "*" but this doesn't seem to be the case.
Right now we send notification emails using a velocity template (apache and java), the thing is that the notification engine call the Email.vm file to add all the information and variables. This process only attach the information (text) on the .vm file.
We need to send that email on html. The thing is that if we write the html code on the file, when the .vm file is called that email includes the code not the result of the html.
We have tried adding the headers and everything.
The question is:
Is there some way that we can pre-process the html code and include to that email the result?
Or can we tell the .vm file that it should be handle as html? (like php for example <?php ?>, the <html> and </html> tags doesn't work.
I am writing a script that is used to submit a package to testflight from my build system. In order to make the presentation as clear as possible I would like to include some basic HTML in the note section, however, using a < or > causes an error in curl. I have tried different variations of quoting and escaping but have not yet been able to find the solution.
I am trying to modify the source code of a C application (quagga) in order to insert data into a mysql table. I have added 2 new source files to the source (neto_mysql, neto_trend) which in turn use mysql.h. I have also modified the Makefile.am file to include the /usr/include/mysql directory.
When trying to compile, i get the following error. What am I missing? I have minimal experience with formal C applications like this. I feel like I may also have to include the mysql.h file in the libbgp? I dont understand why it cant find the mysql functions...
I have C++ source code(*.cpp) files that expects it's header files in System's include folder which is/usr/include.The cpp files has include lines like this:
I have made two source files named as sum.c and average.cI have included sum.c in average.c both files in Documents directory.when i compile average.ot followingerror"average.c:4:22: fatal error: sum.c: No such file or directorycompilation terminated.How to solve this issue?I have tried to copy sum.c to usrinclude folder but unable to copy
I am creating a document using Latex and I am using the existing article class "documentclass[twocolumn]{article}" The paper needs to have a two column format, but I have figures that I would like to include in a landscape orientation, possibly on a new page, (they appear too small even if I have them span either 1 or both columns).
I'm using gmake (v3.81) to build some c executables. As the first step in the process I run the files through a preprocessor (for embedded SQL). The preprocessor completes successfully, but the gmake reports an error and discontinues buiding the remaining dependencies...
make *** [myfile.c] Error 4
which (according to /usr/include/asm-generic/errno-base.h) means "interrupted System Call". My preprocessor doesn't raise any signals, so I'm not sure what's causing this error.
what is the best way (i.e standard way that is supported on all browsers and probably as well followed by web crawlers).... to include an html file either locally or externally in another ? Of course , i've done the research and i also know that there are server side includes (php , asp ...you name it) at the moment , i'm using this:
Quote:
<script type="text/javascript" src="path to file/include-file.js"> </script>
however, i've been warned that this method may not show up in some browsers as some tend to ignore this tag and that crawlers like your favorite search engine wouldn't bother reading this. so , what is the best and safest way to do the job? and btw , the reason why i've ousted SSI's from the start is because of among other things:
1) the fact that the included file is static html and because the text is included pretty much everywhere
2) hoping to reduce load time as the code (if successfully recognized) would hopefully be treated like any other embedded external file (e.x like an image) , therefore it would be cached without the need to downloaded it over and over again for each new page on the site.