zlib and make issues [message #66452] |
Wed, 09 April 2003 11:10  |
Eclipse User |
|
|
|
Originally posted by: bart.torbert.ihsenergy.com
I have just been thrown into the LINUX world and told to get some of my
C++ code running under LINUX. My company is moving rapidly to JAVA using
eclipse. So I figure if I can plug my legacy C++ code in to the CDT, I am
in sync with the development environment the rest of the company is going
to.
Now here are my problems----
WE use the zlib compression package. I have loaded the source code etc.
onto my LINUX box (running SUSE 8.1). I can build zlib by just running
the make command on the command line. But I can not ge CDT to deal with
it.
On the online FAQ the instruction is given to not use the default CDT but
to use the custom command "make -f makefile". Why won't the default
command work? What is the default command doing?
Even when I point the custom build command to point to the zlib makefile,
I get errors. What am I missing here.
In the CDT interface you can bring up "Make Targets" window. Can anyone
explain how this is supposed to work. You can add targets, but you can
not edit them or tie them to the makefile. How does this interact with
the build command?
Also a side issue--- Does anybody know how to get eclipse to run from a
LINUX desktop shortcut? The only way I can get it to run at the moment
is to bring up a terminal window, cd to the eclipse directory and run it
from the commmand prompt. Why don't shortcuts work?
Bart Torbert
bart.torbert@ihsenergy.com
|
|
|
|
|
Re: zlib and make issues [message #66558 is a reply to message #66452] |
Wed, 09 April 2003 15:50  |
Eclipse User |
|
|
|
Bart Torbert schrieb:
> I have just been thrown into the LINUX world and told to get some of my
> C++ code running under LINUX. My company is moving rapidly to JAVA using
> eclipse. So I figure if I can plug my legacy C++ code in to the CDT, I am
> in sync with the development environment the rest of the company is going
> to.
>
> Now here are my problems----
> WE use the zlib compression package. I have loaded the source code etc.
> onto my LINUX box (running SUSE 8.1). I can build zlib by just running
> the make command on the command line. But I can not ge CDT to deal with
> it.
>
> On the online FAQ the instruction is given to not use the default CDT but
> to use the custom command "make -f makefile". Why won't the default
> command work? What is the default command doing?
>
In the FAQ is stated, that it's for Windows.
Also, make will look by default for 'Makefile' instead of 'makefile'.
The option '-f makefile' will make look for a lowercase make-file.
Also if you happen to have subprojects, you can tell make where to start
by the '-C <path>' option.
> Even when I point the custom build command to point to the zlib makefile,
> I get errors. What am I missing here.
>
> In the CDT interface you can bring up "Make Targets" window. Can anyone
> explain how this is supposed to work. You can add targets, but you can
> not edit them or tie them to the makefile. How does this interact with
> the build command?
Let's say you have three different targets defined in you makefile:
all:
debug:
install:
The standard Eclipse behaviour on Build and Rebuild is to call:
make clean
make
The second make call depends on what the first target rule is in your
makefile or if you have set .DEFAULT in your makefile, what is set there.
You can add more targets within Eclipse and use them, so they have to
correspond to your makefile targets. E.g. you could add targets for
building zlib or an Application like:
zlib:
$(MAKE) -C zlibdir all
zlibd:
$(MAKE) -C zlibdir debug
Application: $(APP_OBJECTS)
$(LD) -o $@ $^ $(LDFLAGS)
> Also a side issue--- Does anybody know how to get eclipse to run from a
> LINUX desktop shortcut? The only way I can get it to run at the moment
> is to bring up a terminal window, cd to the eclipse directory and run it
> from the commmand prompt. Why don't shortcuts work?
It depends on your Desktop. You should consult the KDE or Gnome or
whatever desktop Manual, how to create an Desktop Shortcut.
The execute statement should be something like:
$ECLIPSE_PATH/eclipse -data $HOME/workspace
Here you have to set $ECLIPSE_PATH if eclipse is not in your standard
binary-searchpath PATH. The -data option points Eclipse to a workspace.
> Bart Torbert
> bart.torbert@ihsenergy.com
>
H.Riedel
|
|
|
Powered by
FUDForum. Page generated in 0.03648 seconds