compiler-errors

Compiling with mpicc (MPICH2) and pthread_barrier (-lpthread)

I have a functioning implementation of a MPI routine, which works fine. In the process of making this a hybrid between MPI and shared memory, I am using pthreads. This in turn proofed the need of pthread_barriers. But when I try to compile my code with the mpicc compiler, it complains over pthread_barrier_t and other barrier commands. ...

Does C++ enforce return statements?

Okay, little oddity I discovered with my C++ compiler. I had a not-overly complex bit of code to refactor, and I accidentally managed to leave in a path that didn't have a return statement. My bad. On the other hand, this compiled, and segfaulted when I ran it and that path was hit, obviously. Here's my question: Is this a compiler bug...

Build Errors When Migrating to VS 2010 and .NET4.0 from VS 2008 and .NET3.5

Hi, I have a VS 2008 project. This project's target framework 3.5. Everything is Ok in this situation. I migrated this project to VS 2010 and I also changed target framework to .Net 4.0. Then I tried to build the project. But I got an error which says me to about to use "NetFx40_LegacySecurityPolicy" switch. So I used that switch and e...

android build source errors

i have ubuntu installed on the lenovo s10e netbook. i am not sure if this is related to the issue. i am new to source builds so i would appreciate some direction. i followed instructions on cyanogen's wiki (http://wiki.cyanogenmod.com/index.php/Building_from_source) i am stuck on the last step of 'Building CyanogenMod' after starting th...

Float to String Arduino Compile Error

I'm using this library to convert a float to a string: http://www.arduino.cc/playground/Main/FloatToString?action=sourceblock&ref=1 . This is the snippet of code, where printing out flt looks like "29.37": float flt = tempSensor.getTemperature(); char buffer[25]; char str[20]; Serial.print(floatToString(str, flt, ...

Link error in DevC++ not in codepad.org

Hello- I am learning C++ and need some help with compile error messages. I have some code... http://codepad.org/ncGTYWew. When I compile in DevC++, I get this output: 22 C:\Dev-Cpp\Program Files\linkedListType.h template-id operator<< <>' forstd::basic_ostream >& operator<<(std::basic_ostream >&, const linkedListType&)' does not match...

Should get 20 errors... but get 0... when compiling without declaring an instance variable.

In my iPhone apps I regularly do this in xCode v3.2.3: Declare a BOOL variable in the *.h file Use @property in the same *.h file. Use @sythesize in the matching *.m file. I accidentally forgot to do #1... but it still complied fine. 0 warnings. 0 errors. 0 analyzer errors. How can that be? Shouldn't my code to loaded with compil...

Visual Studio compiles but the exe isn't there

Source code that compiles fine on other peoples environments won't correctly work in my environment. When I do a rebuild the compile occurs but when visual studio goes to move the exe from /obj/debug/{solution} to /debug/{solution} it cannot find the exe in the /obj/debug/{solution}. To make this even more crazy even after I reinstall ...

package org.hibernate.cfg does not exist import org.hibernate.cfg.Configuration;

I'm using hibernate & I got this error during compilation,so plz help me package org.hibernate.cfg does not exist import org.hibernate.cfg.Configuration; ...

Maven Multi Module Project breaking compile-time class resolution

Hi, I've been previously managing a 3-module project as 3 seperate maven projects. As this project has been moving forward, I decided I ought to take advantage of the dependency management of maven2 to streamline integration between these 3 evolving modules. I defined a super-project that deploys as POM. Some shared dependencies are de...

Compiling openssl with ruby on windows

Hello, i am trying to compile openssl with my ruby config on a windows computer with MingW. I am running ruby 1.9.2rc2 with these commands: $ ruby extconf.rb --with-openssl-dir=/c/openssl ... ... ... === Checking done. === creating extconf.h creating Makefile Done. Okay, so that works without any errors. Let's try to make: $ make gcc...

CS0120: An object reference is required.......

Getting this error when I submit my form to savetext.aspx action file: Compiler Error Message: CS0120: An object reference is required for the nonstatic field, method, or property 'System.Web.UI.Page.Request.get' On this line: string path = "/txtfiles/" + Request.Form["file_name"]; Whole code: <%@ Page Language="C#" %> <%@ Import ...

C#: WCF: Interface inheritance and casting question

I am writing the client side for a WCF service that supports both synchronous and asynchronous calls without having to implement 5-6 different methods in channel for each method in the contract. I have a base interface (IServiceClient) and a generic class based on this interface type (ServiceClient) as follows: public interface IServic...

Abstract class' constructor asks for a return type

I don't understand what's happening here, I've copied this code from another project (which compiled without problems), but as soon as I got it into my own, I got a compiler error on the constructor definition saying the method needs a return type. public abstract class BaseSqlRepository<T, InterfaceT, PrimaryKeyT> where T : cla...

Compilation fails if delegate definitions is put in another project?

UPDATE: I've filed this as an issue on Microsoft Connect if you can reproduce this and/or would love to see this fixed please help vote up the issue over there. I've been trying to solve this problem for hours now. Would really appreciate whatever idea/advice you can think of. First of all, I have 3 files Class.cs Definitions.cs and ...

Win Service project won't Build after switching to Any CPU config.

I'm trying to find a fix for my problem. After changing my .net 4.0 C# Win Service project to Any CPU/Release build configuration, I am getting this compile time error: Cannot specify /main if building a module or library It identifies the offending file as "CSC" and the project generating it is my Service project (not my accompanying ...

Compiler errors while building a project which uses Eigen, the C++ template library for linear algebra...

Hi Guys, in my project I'm making use of Eigen C++ library for linear algebra and ONLY when I turn on the vectorization flags (mfpu=neon -mfloat-abi=softfp) for ARM NEON, I get compiler errors. I'm not able to understand whats going wrong. Do I need to enable any preprocessor directives for ARM NEON in the Eigen Library? main.c #inc...

CodeSourcery giving compilation error: missing bits/c++config.h

Hi Guys, in my project I'm making use of Eigen C++ library for linear algebra. ONLY when I turn on the vectorization flags (-mfpu=neon -mfloat-abi=softfp) for ARM NEON, I get a compiler error - c++config.h no such file or directory. I'm not able to understand whats going wrong, what is this bits/c++config.h? What should I do to fix thi...

Why does C# throw casting errors when attempting math operations on integer types other than int?

Consider this static test class: public static class Test { public static ushort sum(ushort value1, ushort value2) { return value1 + value2 } } This causes the following compile error, with value1 + value2 underlined in red: Cannot implicitly convert type 'int' to 'ushort'. An explicit conversion exists (ar...

Android ant compile fails: java.lang.NoClassDefFoundError: com.android.jarutils.SignedJarBuilder

So I created my build.xml from scratch using the android utility: $ /opt/android-sdk-linux_86/tools/android create project --target android-6 --name Dash --path . --activity Main --package com.gtosoft.dash Then I try to kick off a compile, but it fails! $ ant release Buildfile: build.xml [setup] Android SDK Tools Revision 6 ...