I have an Xilinx SDK workspace with:
- hardware specification (hw);
- board support package (bsp);
- C-language application.
In other words, it is no need to create an workspace like described here http://www.xilinx.com/support/documentation/sw_manuals/xilinx14_3/SDK_Doc/reference/sdk_u_commandline.htm.
Provided Xilinx SDK is an Eclipse-based IDE, how can I make Eclipse to run project clean and release|debug|all configurations build from command line/batch file?
This link really helps
http://www.xilinx.com/support/documentation/sw_manuals/xilinx14_1/SDK_Doc/reference/sdk_u_commandline.htm
about headlessbuild syntax:
https://www.cct.lsu.edu/~rguidry/eclipse-doc36/org/eclipse/cdt/managedbuilder/internal/core/HeadlessBuilder.html
script contents
set XILINX_EDK=c:\Xilinx\14.3\ISE_DS\EDK\
set XILINX=c:\Xilinx\14.3\ISE_DS\ISE\
set ECLIPSE=%XILINX_EDK%eclipse\nt\eclipse\eclipsec.exe
set WSPACE=%CD%
set VM=%XILINX%java6\nt\jre\bin\
set BSP=%CD%\TEST_bsp\
set BSPNAME=TEST_bsp
set APP=%CD%\TEST\
set APPNAME=TEST
%ECLIPSE% -vm %VM% -nosplash -application org.eclipse.cdt.managedbuilder.core.headlessbuild -cleanBuild all -data %WSPACE%
If you have the workspace already, can you not just run make clean; make in the project directory?
Related
I am trying to build my C++ eclipse project from command line.
Below is the command I have given ,
C:\Piranha_Development_Tools\Eclipse_Kepler_64bit\eclipsec.exe -nosplash -application org.eclipse.cdt.managedbuilder.core.headlessbuild -data
C:\Test_Trunk\TrunkTestWS - build k64f
Then I am getting below error,
Version: Kepler Release
Build id: 20130614-0229
Please let me know If I have to try something or if any link I can refer.
This is my first message on this forum… so hello at all..
I have to make c++ project with Eclipse IDE and using QT library… and I want to integrate QT library…
So I have downloaded Eclipse and QT version 5.1.0, included the library and all work…My problem born when I try to integrate qmake in eclipse for using moc compiler… I followed this procedure www.qtcentre.org/wiki/index.php?title=How_to_use_Eclipse_with_Qt4_in_10_steps.. but doesn't work…
Could someone help me?
Thanks
Sorry. I try to explain better the problem...
After installing eclipse with O.S. windows I have created a new project:
1) File->new->c++ Project (inserted the project name) and selected MinGW GCC as toolchains and debug and release as configurations
2)Project->Properties-> C/C++ Build->Settings->GCC C++ Compiler->Includes .. I included the path of may Qt library
3)Project->Properties-> C/C++ Build->Settings->MinGW C++ Linker-> LIbraries I included the link to the libraries.
4)I have created my file project called main.cpp and the header and cpp for my class (testclass1.h testclass1.cpp)
5) My class is a deriverd class of QObject and since I have to use signal and slot I need of Q_OBJECT macro.
6) Run->External ToolsConfigrations I created two new Programs.
.Name:Qmake
.Location .../bin/qmake
.Name:QtAssistant
.Location .../bin/assistant
7)Created a new target in my "Make target"
Target Name: qmake
Make Target: myQtProj.pro
Build Command: qmake
Target Name: all
Make Target: all
Build Command: default (make)
8) when I run qmake I have this error: undefined reference to `vtable for testclass1..I thinks that this depends on the macro Q_OBJECT.. I expect that running qmake the moc compiler is called so I should have in testclass1.cpp the macro Q_OBJECT "expanded"..
At the moment I solved the problem in this manner(from command line I called):
qmake -project (create myproject.pro)
qmake (create a makefile)
mingw32-make that create moc_testclass1.cpp...
So I copy the content of moc_testclass1.cpp in my testclass1... and I can build the project and all work. But this is not and automated way..
I hope to be more clear in my description.
Thanks for your help.
I am trying to create an eclipse project from a cmake project .
I used the following command
cmake -G "Eclipse CDT4 - Unix Makefiles" ./`
it gives the following error
CMake Error at CMakeLists.txt:119 (find_package):
By not providing "FindGlib.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "Glib", but
CMake did not find one.
Could not find a package configuration file provided by "Glib" (requested
version 2.28) with any of the following names:
GlibConfig.cmake
glib-config.cmake
Add the installation prefix of "Glib" to CMAKE_PREFIX_PATH or set
"Glib_DIR" to a directory containing one of the above files. If "Glib"
provides a separate development package or SDK, be sure it has been
installed.
-- Configuring incomplete, errors occurred!
I have glib installed . actually it couldn't resolve the path i guess. wherever find is there in cmake file , it is giving the smiler errors. please i suggest a way out, i badly need to load this project in cmake. Thanks.
Here is line 119 where error message is pointing
find_package(Glib 2.28 REQUIRED)
include_directories(${Glib_INCLUDE_DIRS})
list(APPEND LIBS ${Glib_LIBRARIES})
add_definitions(${Glib_DEFINITIONS})
When you call find_package(MyPackage) in a CMake file, it tries to find a FindMyPackage.cmake configuration in its system path (/usr/share/cmake-2.8/Modules on my Ubuntu box), or in the directory you did specify as CMAKE_MODULE_PATH).
The solution to your problem is to create a directory for modules in your source tree (e.g. CMakeModules), put in it a FindGlib.cmake file that you can find using Google, and add
set(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/CMakeModules)
in your CMakeLists.txt before the actual call to find_package.
(your problem is not related to the Eclipse generator, you could remove that from the title of the question).
When i try to run my code on Eclipse this error appears:
Usage: javaw [-options] class [args...]
(to execute a class)
or javaw [-options] -jar jarfile [args...]
(to execute a jar file)
where options include:
-d32 use a 32-bit data model if available
-d64 use a 64-bit data model if available
-server to select the "server" VM
-hotspot is a synonym for the "server" VM [deprecated]
The default VM is server.
-cp <class search path of directories and zip/jar files>
-classpath <class search path of directories and zip/jar files>
A ; separated list of directories, JAR archives,
and ZIP archives to search for class files.
-D<name>=<value>
set a system property
-verbose:[class|gc|jni]
enable verbose output
-version print product version and exit
-version:<value>
require the specified version to run
-showversion print product version and continue
-jre-restrict-search | -no-jre-restrict-search
include/exclude user private JREs in the version search
-? -help print this help message
-X print help on non-standard options
-ea[:<packagename>...|:<classname>]
-enableassertions[:<packagename>...|:<classname>]
enable assertions with specified granularity
-da[:<packagename>...|:<classname>]
-disableassertions[:<packagename>...|:<classname>]
disable assertions with specified granularity
-esa | -enablesystemassertions
enable system assertions
-dsa | -disablesystemassertions
disable system assertions
-agentlib:<libname>[=<options>]
load native agent library <libname>, e.g. -agentlib:hprof
see also, -agentlib:jdwp=help and -agentlib:hprof=help
-agentpath:<pathname>[=<options>]
load native agent library by full pathname
-javaagent:<jarpath>[=<options>]
load Java programming language agent, see java.lang.instrument
-splash:<imagepath>
show splash screen with specified image
See http://www.oracle.com/technetwork/java/javase/documentation/index.html for more details.
i try to coment my entired code and this error still appear.
It seems you haven't set your java path correctly.
Setting Up Eclipse with Java 1.6 on Windows
How To Install and Get Started with Java Programming
Run eclipse in clean mode
Edit the eclipse.ini file located in your Eclipse install directory and insert -clean as the first line.
If this is happening to a specific project only and other projects are running fine then your default run configuration might have changed. You may try the following
- Run -> Run As -> 1 Java Application.
I fixed this issue by deleting some of my old runtime configurations. Eclipse then started automatically generating them again.
This feels silly, but its been 2 days...somewhere after upgrading from Ubuntu 10.04 to 10.11 and from Eclipse Helios to Eclipse Indigo, I got stuck with the following problem:
Problem Description:
I'm trying to use a function in math.h called isinf(), but the problem also occurs with things like isnan(). The program compiles fine on the command line using make and fine in eclipse using build. But if I open the program file in eclipse it reports that it cannot reolve the isinf() function call. If I just insert the program contents into a new project and new source file, the error appears immediately. This problem did not occur under 11.04 with Eclipse Helios CDT
Questions:
Why are these errors only reported when the program file is opened and not on when the program is compiled; why are the errors not detected make is run from the command line? Is there a solution/workaround available?
Version Info
Linux Ubuntu 10.11 64-bit
Eclipse CDT Indigo, Service Release 1, Build id: 20110916-0149
(Also using Eclipse EE Indigo – if that makes a difference)
GNU Make 3.81
gcc 4.6.1-9Ubuntu3
To Duplicate:
Please find the two files you'll need to replicate below:
Step 0. Verify that everything is fine outside of Eclipse
Copy the attached source file and make file
create a directory e.g. Mkdir FunTest
Save the source file a 'Test.cpp' and the makefile as 'makefile'
Open a command prompt and navigate to the directory e.g. FunTest
Enter 'make'
Enter ./TestOut
Program responds “is not infinite”
Step 1. Create the project in Eclipse
Open Eclipse
Select File|New|MakeFile Project with Existing Code
Click Browse – navigate to the directory (FunTest) and click ok
Select 'Linux GCC' from the Toolchain selector
Click Finish
Step 2. Find the Error
Click Build All (Ctrl-B) – project builds without errors
Open the project in the project explorer to display the file in the directory
Double click on the file “Test.cpp”
Note the error icon next to line testing for infinity
Note the 2 error messages:
Semantic error: Function _isinff could not be resolved
Semantic error: Function _isinfl could not be resolved
Test.cpp:
include <math.h>
int main(int argc, char **argv)
{
int TestNum = 10;
if (isinf(TestNum) == 0)
printf("Not infinite\n");
return 0;
}
makefile:
# Specify the compiler
CC = g++
# Specify the compiler flags
CFLAGS += -c
# Specify the files making up the application
SOURCES = Test.cpp
OBJECTS = $(SOURCES:.cpp=.o)
EXECUTABLE = TestOut
all: $(EXECUTABLE)
$(EXECUTABLE): $(OBJECTS)
$(CC) $(LDFLAGS) $(OBJECTS) $(LDLIBS) -o $#
.cpp.o:
$(CC) $(CPPFLAGS) $(CFLAGS) $< -o $#
install:
#echo "Build complete!"
I have experienced similar problems of the CDT reporting errors even though the code compiled fine within Eclipse Indigo.
Project > Properties > Settings > Binary Parsers > "GNU Elf Parser"
helped in my case. I had the "Elf Parser" checked.
That looks like a problem that many others have had with eclipse CDT before. Sometimes shutting eclipse down and then starting it back up again is enough to help. If that isn't the case, take a look at what I have below:
Compilation ok, but eclipse content assist having problems
Check your includes: if you're using include<math.h> change it to include<cmath>. The same for stdio.h and stdlib.h, you should replace by cstdio and cstdlib. Another option may be change you project to a C project instead of a C++.
You are missing -lm option in your build preferences.
Project->Properties->Settings->Miscleanous->Other (linker) flags[]
For me, it was solved by adding a specific ‘Source Location’ folder, and removing the default. In Luna, it is under:
Project > Properties > C/C++ General > Paths and Symbols > Source
Location