General :: Using Makefile - 'Multiple Definition' Compile Errors

Mar 1, 2011

As part of an assignment, our class was given a small set of c++ classes which are compiled using a makefile. As part of the assignment, I have created a namespace and saved in it a .cpp file. The functions, constants and typedefs from the namespace are now used in one of the original files, and so I added an <#include MyFile.cpp> to the file I modified, in addition to a using MyNamespace;

When I try to use the original makefile, the compiler gives a lot of errors about multiple definitions of every function in the namespace. What do I need to do to resolve this? Do I need to change the makefile or one of the files themselves? I am new to Linux programming and makesfiles.

View 2 Replies


General :: Compile Multiple File Using Makefile ?

Jun 1, 2011

How to compile single file in Linux environment using gcc. Now i dont know how to use make file to compile multiple file.

View 5 Replies View Related

General :: Compile Multiple Source Using Single Makefile In ECos?

Jun 3, 2010

I'm calling a function defined in "uart.c" from "main.c"

But on "make" using cygwin bash, it's giving an error:"Unreferenced function"...
Pls help me to overcome this problem.

If i'm putting the definition of that function in "main.c" itself, its working.

So pls tell me how to write the make file for it?

View 4 Replies View Related

Programming :: 'makefile' \ Errors Are Mainly Due To Multiple Declarations Of The Functions?

Nov 24, 2010

This is the makefile....

animesh:main.o input.o bsort.o output.o
gcc -o animesh main.o input.o bsort.o output.o


View 7 Replies View Related

General :: Use Make And Makefile To Compile And Link Some .cpp/.h

Sep 20, 2009

I've been trying to figure out how to use make and makefile to compile and link some .cpp/.h. All i seem to find on google says to read the README for the software. But this is my own created c++ project. Im just looking for a simple makefile for my own .cpp/.h files( about 20 total).

I have tried using 2 different makefile "examples" as a template, but neither worked. I am getting error saying "file1.cpp: no newline character at end of file". or something to that degree.

View 5 Replies View Related

General :: Errors - After Editing Makefile In Line 880

Apr 6, 2010

I want to install pgplot on ubuntu 9.10 but I have some errors after editing makefile in line 880

replaced "pndriv.o : ./png.h ./pngconf.h ./zlib.h ./zconf.h" by
"pndriv.o : /usr/local/include/png.h /usr/local/include/pngconf.h /usr/local/include/zlib.h /usr/local/include/zconf.h"
and running code "make" I get this error :
No rule to make target `/usr/local/include/png.h', needed by `pndriv.o'. Stop.
also I tried to uncomment this line got another error :
make: *** [pndriv.o] Error 1
and also replace "pndriv.o : ./png.h ./pngconf.h ./zlib.h ./zconf.h" by "pndrive.o : "
what should I do ?

View 14 Replies View Related

Software :: Errors With New OO Fork - Warning: Underquoted Definition Of AM_PATH_NSPR

May 4, 2010

if this is log spam or significant stuff, and what I should do about it? I grabbed the latest build of [URL] the new fork of OO (git download) and ran ./

bash-3.1$ ./
/usr/share/aclocal/nspr.m4:8: warning: underquoted definition of AM_PATH_NSPR
/usr/share/aclocal/nspr.m4:8: run info '(automake)Extending aclocal'
/usr/share/aclocal/nspr.m4:8: or see installing `./install-sh' installing `./missing'

I then get a string of poor guesses, of which I enclose a few

bin/piece/ wildcard inst-*: non-POSIX variable name
bin/piece/ (probably a GNU make extension)
bin/piece/ wildcard post-inst-*: non-POSIX variable name
bin/piece/ (probably a GNU make extension)
desktop/16x16/ wildcard ooo-*.png: non-POSIX variable name
desktop/16x16/ (probably a GNU make extension)

It leaves little confidence that I am getting a good setup. My distro is slamd64-12.2 (An excellent first attempt) I did check the redhat page, but it may have as well been in Fortran or Perl.

View 2 Replies View Related

Programming :: Multiple Definition Of 'variable_name'

Nov 3, 2010

I have the following header file in /usr/include/test.h:

#ifndef TEST_H
#define TEST_H
const int test_version = 1;


View 3 Replies View Related

Programming :: Tell Makefile Not To Compile Debug Code?

Mar 4, 2010

I've been trying to work out a way to stop chunks of code being compiled using a variable in my makefile but can't work it out. What I mean is for example in my code I might have.

/****output comms portdata********/
debug comms port %d",ReadPort("ttys1);

I only wish this code to be compiled when I'm debugging. What I've tried is using #ifdef with

debug comms port %d",ReadPort("ttys1);

Then in my make file I set COMM_PORT_DEBUG to 1 so


I then thought I could put it into my in my link line


but this gives a

gcc: COMM_PORT_DEBUG=1: No such file or directory

is there a way to do this sort of thing? Or am I barking up the wrong tree?

View 1 Replies View Related

Programming :: Compile And Build Program Using A Makefile Template?

Jul 8, 2011

I am new to the whole concept of makefiles, and I'm trying to compile and build my program using a makefile template I have found. My project consists of three directories: "source", where my .cpp files are (source1.cpp, source2.cpp, source3.cpp), "include", where my .h files are (header1.h, header2.h, header3.h), and "obj", where the object files are to be stored (obj1.o, obj2.o, obj3.o). In the project root directory is my makefile, which is as follows:

EXEC = myexe
CC = g++
IDIR = include
SDIR = source
ODIR = obj


View 4 Replies View Related

Ubuntu :: Gopenvpn Compile Error - Cannot Find Input File: `po/'

Mar 6, 2010

Ubuntu 9.10 64-bit
Lenovo T400

I'm trying to install gopenvpn from source. [URL] I'm pretty sure I have all the necessary libraries installed.

./configure ends with:
configure: creating ./config.status
config.status: creating Makefile
config.status: creating pixmaps/Makefile
config.status: creating src/Makefile
config.status: error: cannot find input file: `po/'

View 4 Replies View Related

General :: Libtool Has Syntax Errors When Running After GLib-2 Cross Compile For PPC Using LTIB?

Jun 10, 2010

First, I'm trying to cross compile mono 2.6.4 so that it will run on Freescale Embedded Linux for a PowerPC CPU. My host machine is running Fedora 13 on an x86. Freescale provides a copy of the Linux Target Image Builder (LTIB) that has been pre-configured for the particular board I'm using, and LTIB seems to be able to help with the cross compilation of other stuff--you can add in your own packages to be built and included in your newly-built Linux image.

Mono depends on pkg-config and glib-2, so I have selected them in the LTIB package selection config. I've also added a new package for mono that builds mono-2.6.4 from the source tar (after the other deps have also been built).

I'm having a problem getting the glib-2.24.0 package libraries created. Basically they appear to build and link ok, but then libtool runs and errors out claiming it has a syntax error! (numerous wths followed...)

Here is LTIB's temporary build script for only the glib2 package:


Here is the output when building the glib2 package (configure + make):


Build path taken because: directory build, build key set, no prebuilt rpm,

View 7 Replies View Related

Slackware :: Makefile:535: /usr/src/linux- No Such File Or Directory

May 31, 2010

I just downloaded slackware 13.1(x86) and i'm trying to compile ndiswrapper-1.56 using the slackbuild from and i'm getting this error:


Makefile:535: /usr/src/linux- No such file or directory
make[2]: *** No rule to make target `/usr/src/linux-'. Stop.
make[1]: *** [modules] Error 2
make: *** [all] Error 2

looks like the folder i486 doesn't exist

View 2 Replies View Related

Ubuntu :: Old Kernel Compile Errors Resurface

Mar 2, 2010

I un-installed all packages that I downloaded and removed all references to the attempted kernel and I thought it was over. Today I tried to install xubuntu-desktop and the install exits with a dpkg errros that refers to that old custom kernel attempt. I run dpkg as instructed (see below):


I cannot run apt-get until I try to figure out where this error is.

View 1 Replies View Related

Hardware :: X-Fi Titanium RedHat 4 Getting Errors When Trying To Compile

Nov 1, 2010

I have a machine with X-Fi Titanium sound card. Im getting the following errors when trying to compile the driver.


View 3 Replies View Related

Slackware :: Compile Errors With Various X11-relying Programs?

Jan 31, 2010

I've been trying to compile and install different terminal emulators:Eterm, aterm, and libAfterImage for urxvt.

I've been getting all these errors, and it seems odd to me. I did some fiddling awhile back enabling KMS with my radeon, install custom packages for xf86-ati, mesa, and libdrm. Could that or some other fiddling have broken these dependencies?

Here is an excerpt, with the full error log attached and here:url

In file included from libungif/../xwrap.h:5,
from libungif/../asim_afterbase.h:23,
from libungif/../afterbase.h:36,
from libungif/gif_hash.h:24,
from libungif/gif_lib_private.h:5,

View 1 Replies View Related

Software :: Compile Ardour 2.8.7 From Source - Stopped With Errors

May 15, 2010

I'm trying to compile ardour 2.8.7 from source and the compile got past the dependencies and everything else fine but it stopped at one point with these errors


I have no experience compiling python. I would not like to install from a package as the one with ubuntu is wrongly compiled and so are many others which are hosted I have heard the only way to make the problems with packaged versions stop is by compiling ardour yourself so I would still like to go ahead with it.

View 6 Replies View Related

CentOS 5 :: Unable To GCC Compile Any Stuff - Random Errors

Jan 24, 2009

I am new to CENTOS (5.2) and more importantly new to linux. Any time I try to gcc compile something, it always throws random errors. I yum installed development-tools which is what I have seen other threads suggest but that did not solve the issue. I still get the same errors. I cannot find a common error among the many things I have attempted to compile.

Here is my most recent file for an example made when trying to compile up-imapproxy :
gcc -g -O2 -I. -I./include -c -o src/icc.o src/icc.c
gcc -g -O2 -I. -I./include -c -o src/main.o src/main.c
src/main.c: In function "int main(int, char**)":
src/main.c:618: error: invalid conversion from *void* to *void* (*)(void*)
src/main.c:618: error: initializing argument 3 of int pthread_create(pthread_t*, const pthread_attr_t*, void* (*)(void*), void*)
src/main.c:646: error: invalid conversion from int* to socklen_t*
src/main.c:646: error: initializing argument 3 of int accept(int, sockaddr*,socklen_t*)
src/main.c:675: error: invalid conversion from void* to void* (*)(void*)
src/main.c:675: error: initializing argument 3 of int pthread_create(pthread_t*, const pthread_attr_t*, void* (*)(void*), void*)
make: *** [src/main.o] Error 1

View 3 Replies View Related

Ubuntu Multimedia :: Compile Errors From OpenCV With Ffmpeg + X264

May 29, 2011

I am trying to compile OpenCV 2.0 with ffmpeg (with x264) support on my Ubuntu 11.04 64-bit machine. (Since I want to use the binaries provided by other developers, I have to use opencv 2.0 version)

I followed the guide from: [URL] to compile x264 and ffmpeg manually, and succeeded.

Then I followed the guide in the INSTALL file provided by the OpenCV 2.0 package. I use CMake to configure and generate them, and use "make" command to try compiling. However, I got the following error report, which haunted me for almost half a week.

Linking CXX static library ../../lib/libhighgui_pch_dephelp.a
[ 71%] Built target highgui_pch_dephelp
Scanning dependencies of target pch_Generate_highgui
[ 71%] Generating _highgui.h
[ 71%] [COLOR="rgb(65, 105, 225)"]Generating


View 7 Replies View Related

Ubuntu Installation :: Compile Errors Installing VMWare Workstation 7.1.0

Aug 19, 2011

I have played around with Fedora for a few years and recently switched to Ubuntu. I am installing VMWare Workstation version 7.1.0 from a retail packaged CD. When I attempt to install VMWare Workstation and VMWare Player I get the following error:

Aug 15 16:24:54.826: app-3078788800| Your GCC version: 4.5
Aug 15 16:24:54.837: app-3078788800| Your GCC version: 4.5
Aug 15 16:24:54.889: app-3078788800| Trying to find a suitable PBM set for kernel 2.6.38-10-generic.
Aug 15 16:24:54.895: app-3078788800| Trying to find a suitable PBM set for kernel 2.6.38-10-generic.....
Aug 15 16:24:56.163: app-3078788800| Failed to compile module vmmon!

I tried installing the patch for kernal 2.6.38-8 found here - [URL] - but it did not resolve the issue. Is there a patch for kernal 2.6.38-10?

I also found this posting for the same problem: [URL]. I followed the following instructions as advised in the post . . .
sudo apt-get update
sudo apt-get install make
sudo apt-get install gcc

Then enter:
uname -r

My kernel was: 2.6.38-10-generic
sudo apt-get install build-essential linux-headers-2.6.38-10-generic
Now run the script.

Everything ran without error. However, I continue to get the same error. Another post suggested uninstalliung and reinstalling the software, but this had no affect either. Another post suggested that after running the above update to them run the /usr/bin/ script. However I do not seem to have the in my /usr/bin directory. I checked the various VMWARE directories in /etc and the /tmp/vmware-root directories but no

View 2 Replies View Related

Software :: Php Compile Errors - Found Not - Flex , Bison , Re2c?

Jun 8, 2010

configure: warning: bison versions supported for regeneration of the Zend/PHP parsers: 1.28 1.35 1.75 1.875 2.0 2.1 2.2 2.3 2.4 2.4.1 (found: none).
configure: warning: flex versions supported for regeneration of the Zend/PHP parsers:


View 4 Replies View Related

General :: Automate A Definition Process?

May 24, 2011

I would like to automate a definition process. I have 11,581 to define. :|

I would like to read each word, copy the definition(s) and append it next or below the word or save definitions to file.

The word list has one word per line.

Python script?

Its an interesting project but I cant seem to figure it out. Lack of programming skills.

View 2 Replies View Related

Programming :: Multiple Files To Compile By G++?

Jan 12, 2011

how i could compile for example: a tutorial file of cantera open source files. when i do :g++ example.cpp -o examplei get huge errors such as the header files are not here,...please tell me how i could compile it. ofcourse i have configured the full opensources and i see in /usr/local/cantera/binthat the files are there but i still can not compile and execute any cpp file.

View 2 Replies View Related

Software :: Get Rid Of Multiple Bad Image Errors?

Oct 22, 2010

Whenever I open up any program or just start my computer, multiple bad image errors pop up and I am forced to close all of them by pushing "ok." Everything is fully functional that I know of, but I would like to fix them. I have tried checking the system but it doesn't work. I have AVG Antivirus and Registry Defense installed. It has supposedly fixed things but the error messages still pop up.Would a malware remover work?
If so what would be a good one?

View 1 Replies View Related

General :: Symantec AntiVirus Update Will Not Download Virus Definition Files?

Jan 27, 2010

can't seem to get my Linux AntiVirus Live update to download virus defs from my Windows Symantec Update Server?Windows workstations can update and download without a problem?When I run LiveUpdate from the side it errors out with "an error has occurred (code=-2,001)" Also, I'm not sure where the Linux defs are to be placed on my windows side for download from my linux workstations? I've found a couple good articles but everything I've tried hasn't fixed my problem? If I download the virus defs locally to each linux box I can update the virus defs without a problem, not a good option when I have several Linux boxes.

View 1 Replies View Related

Fedora Installation :: FC10 Multiple Errors Right After Install

Jan 30, 2009

I have just loaded the FC9 onto a HP/Compaq D510 2.8Ghz/Intel graphic card. Everything when as expected during the install but on login I get the following set of errors. The follow Panels encounters a problem.


View 3 Replies View Related

Debian Installation :: Multiple SystemD Errors After Upgrade From Wheezy

Mar 3, 2016

Recently I upgraded my machine from wheezy to jessie.

Everything went smooth until the point that I restarted the node.

During startup I'm getting the following message which is flooding the screen:

Code: Select allsystemd-journald[296]: Failed to forward syslog message: Connection refused

After waiting a long time (the message above still continues to flood the screen), I'm being prompted with the following:

Code: Select allGive root password for maintenance (or type Control-D to continue):

If I press Ctrl+D the boot process continues and finally boots normally.

What I can do to avoid pressing Ctrl+D during the boot process?

I'm assuming that it must be a startup service which is failing but I'm unable to trace which exactly is that.

I'm attaching the full log [URL] ....

View 8 Replies View Related

OpenSUSE Hardware :: Multiple Errors When Trying To Start Ntfs Config

May 27, 2011

First of all, ntfs-config does not appear in the menu in openSUSE 11.4 Gnome 2.32. When I try to start it using the run command(Alt + F2) it gives the following error in a small window: Insufficient Rights. You need administrative rights to start this application. I then try to run it as root (su -l or su) and it gives the following error:


All these packages and others are already installed in my computer.

View 9 Replies View Related

Ubuntu :: Xsession-errors: Multiple Calls To Startxfce4 And Xfce4-panel?

Jun 8, 2010

I get the following messages while starting up. This also delays my desktop initialisation.

/etc/gdm/Xsession: Beginning session setup...
Setting IM through im-switch for locale=en_GB.
Start IM through /etc/X11/xinit/xinput.d/all_ALL linked to /etc/X11/xinit/xinput.d/default.
/usr/bin/startxfce4: X server already running on display :0
xrdb: "Xft.hinting" on line 9 overrides entry on line 6


If I run in terminal tail -f .xsession-errors while my system initialises, I see these messages appearing every 5 sec.

View 2 Replies View Related

Ubuntu Networking :: How I Fixed Asus USB-N13 Compile Errors In Ubuntu 10.10

Oct 21, 2010

It seems with the newer linux headers, two functions changed their names slightly and caused a crash when attempting to build the Asus-provided USB-N13 drivers.

I'm still in the middle of getting the device to work, but actually compiling the driver was a major problem for me and others I've seen that complained of the breakage in 10.10.

Here's the fix:
Within the include/os/rt_linux.h and os/linux/rt_usb_util.c files, the usb_buffer_alloc and usb_buffer_free functions are part of an internal macro. These functions do not exist anymore and are replaced by the usb_alloc_coherent and usb_free_coherent respectively. Input parameters did not change, just the names.

The macro is defined in rt_linux.h and the functions are used in a symbol export within rt_usb_util.c. Simply renaming the functions should allow it to build.

As I said, I'm still in the process of getting the wireless to work, just wanted to let everyone know of the quick fix.

This issue will probably be addressed with a macro fix somewhere eventually.

#define usb_alloc_coherent(a, b, c, d) usb_buffer_alloc(a, b, c, d)
#define usb_free_coherent(a, b, c, d) usb_buffer_free(a, b, c, d)

View 3 Replies View Related

Copyrights 2005-15, All rights reserved