Hi Pritpal,

Today I have turned to hbmk2 seriously for my
large projects and I am looking for some possible ways
to build every library/exe from one place.

Here is my development environment tree:

c:\dev_projects  contains folders per project
c:\dev_sources contains source|include|resource folders per project or
otherwise
c:\dev_libs         contains libs generated by lib projects
c:\dev_exes       contains all exe's generated by executable projects

c:\dev_projects\vouch\vouch.hbp contains these entries:

-hblib
-olib/${hb_arch}/${hb_comp}/vouch
-inc
-q0 -w1 -es2 -m -n -a

-Ic:/dev_sources/vouch/include

You can use here: -Iinclude

...

-D__WVT__
...

c:/dev_sources/vouch/source/A_ARRAY.PRG
c:/dev_sources/vouch/source/B_53.PRG

Here it's enough to use: source/A_ARRAY.PRG, etc...
(no need to list the absolute path, only the one
relative to holder .hbp file)

It runs fine and generates this folder structure:

c:\dev_projects\vouch\lib
                              \lib\win
                              \lib\win\mingw
\lib\win\mingw\.hbmk ( and subfolders holding
.o, .c files )
                              \lib\win\mingw\libvouch.a

Question is : how can I separate the output paths of object files and final
binaries.
For example, in above case, I would like to place libvouch.a (only) to a
different folder
c:\dev_libs. And on the same analogy any .exe to folder c:\dev_exes.

You can override both dirs. libvouch.a will be placed according
to your '-o' parameter. By default the intermediate files (.hbmk dir)
will be placed under the dir specced in -o option. If that's not
good for some reason, you can use -workdir=<dir> option to override
the default here.

F.e. I use this:
-workdir=lib/${hb_arch}/${hb_comp}/${hb_work}/vf

This will put intermediate files to lib/win/mingw/.hbmk/vf

You can of course set it to any dirs you want. Just keep
in mind that if you use multiple target compilers (or platforms)
for your project, to use different dirs for each. This is
the reason I use the above macros in the example.

I hope that helps.

Brgds,
Viktor

_______________________________________________
Harbour mailing list
[email protected]
http://lists.harbour-project.org/mailman/listinfo/harbour

Reply via email to