You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@harmony.apache.org by Salikh Zakirov <sa...@gmail.com> on 2007/08/16 13:00:04 UTC

Re: [drlvm][PATCH/RFC] GNU Make-based build system for DRLVM -- call for help

> Xiao-Feng Li wrote:
>> I highly support to have a Makefile based build system. Thanks for the
>> experiments! Only the nice "-j n" can make it a worth try.

Salikh Zakirov replied:
> Thanks, I will see if I can it make it "more cross-platform", and then
> file a JIRA with a patch.

So, I went ahead and cleaned makefile a little bit, squashing a couple of bugs
on the way, added Apache license boilerplates and uploaded the patch to
HARMONY-4640 '[drlvm][build] Makefiles for building native components of DRLVM'

The build works as a overlay on top of existing build system, as it currently uses
apr an other 3rd party libraries build by the ant build system. It deploys the
resulting binaries to the same deploy directories, in order to support quick
recompilation cycle if only native files were changed. This dramatically increases
effectiveness of development work if frequent recompilation are needed, especially
in the case of moved source files, which requires 'clean' step with the current
build system (~6-7 minutes on my machine), but makefiles allow for an incremental
recompilation (typicaly ~10-20 seconds).

I've tried makefiles only on Linux/x86, since that is what I have.

The functionality for the cross-platform configuration is designed in the makefiles,
however, the configuration itself is missing, and I need help from volunteers to bring
this build system to a fully configured state.

To make the experimentation and contribution to the build system development easier,
I've set up a git mirror of DRLVM repository on repo.or.cz. Use following commands to check out the copy

     $ git clone git://repo.or.cz/drlvm.git
     $ cd drlvm
     $ git checkout -b mob origin/mob

The branch 'master' is a pure mirror of SVN, and branch 'mob' contains the patch with the makefiles.
In order to facilitate easy integration of many patches, anonymous write access without password
is enabled with mob account [1]. The following command can be used to push patches to the repository

    $ git push ssh://mob@repo.or.cz/srv/git/drlvm.git mob

The only writable branch is 'mob'. Using this anonymously writable branch, anyone (including non-committers)
can contribute patches, and all modifications will be collected in one place without having to mail or
upload multitude of patches. It would be easier for me to review patches in this way as well.

So, if you are interested in having a more efficient and convenient build system for DRLVM, 
please help in porting it to more platforms.


--
[1] http://repo.or.cz/mob.html


Re: [drlvm][PATCH/RFC] GNU Make-based build system for DRLVM -- call for help

Posted by Salikh Zakirov <sa...@gmail.com>.
Salikh wrote:
>> To make the experimentation and contribution to the build system development easier,
>> I've set up a git mirror of DRLVM repository on repo.or.cz. Use following commands to check out the copy
>>
>>      $ git clone git://repo.or.cz/drlvm.git
>>      $ cd drlvm
>>      $ git checkout -b mob origin/mob

Egor Pasko replied:
> Salikh, GIT mirror of DRLVM is cool (!!!) (I would be glad to use it
> instead of using my own mirror as of today), but contribution back to
> GIT does not follow our process and each patch will have to be
> attached back to JIRA thus requiring duplicate of work, which is not
> very usable.

Okay, you've got the point here. 
Indeed, we need to enforce the same policy on the origin of patches
even the patches are collected in a different repository, so can
apply only the patches from JIRA. 

> I am thinking of a more convenient way to use GIT: run a JIRA crawler
> to collect all patches in JIRA (allowed to include in our sources) and
> apply them to the mirror (add a patch to the experimental branch
> automatically if the patch does not break a set of predefined
> tests). How is that?

A couple of thoughts:
- JIRA crawling automation (finding and downloading patches)
  may be useful to committers, even if they work with SVN only.
  
- Testing patches for experimental branch requires lots of CPU time,
  i.e. dedicated machine(s), and someone dedicated to keep the scripts
  running -- will we have volunteers for this?

Anyway, the idea sounds promising, I am looking forward to seeing
something concrete.

> And BIG THANKS for working on the build system. I am kinda deadly
> annoyed with current speed. With make we could cook parallel builds
> upto distcc.

"Patches welcome". Seriously, if you think it is useful, please go ahead
and use it. I am pretty sure you'll come up with further improvements soon,
and get it to closer to the state when it can be committed to SVN.

Re: [drlvm][PATCH/RFC] GNU Make-based build system for DRLVM -- call for help

Posted by Egor Pasko <eg...@gmail.com>.
On the 0x334 day of Apache Harmony Salikh Zakirov wrote:
> > Xiao-Feng Li wrote:
> >> I highly support to have a Makefile based build system. Thanks for the
> >> experiments! Only the nice "-j n" can make it a worth try.
> 
> Salikh Zakirov replied:
> > Thanks, I will see if I can it make it "more cross-platform", and then
> > file a JIRA with a patch.
> 
> So, I went ahead and cleaned makefile a little bit, squashing a couple of bugs
> on the way, added Apache license boilerplates and uploaded the patch to
> HARMONY-4640 '[drlvm][build] Makefiles for building native components of DRLVM'
> 
> The build works as a overlay on top of existing build system, as it currently uses
> apr an other 3rd party libraries build by the ant build system. It deploys the
> resulting binaries to the same deploy directories, in order to support quick
> recompilation cycle if only native files were changed. This dramatically increases
> effectiveness of development work if frequent recompilation are needed, especially
> in the case of moved source files, which requires 'clean' step with the current
> build system (~6-7 minutes on my machine), but makefiles allow for an incremental
> recompilation (typicaly ~10-20 seconds).
> 
> I've tried makefiles only on Linux/x86, since that is what I have.
> 
> The functionality for the cross-platform configuration is designed in the makefiles,
> however, the configuration itself is missing, and I need help from volunteers to bring
> this build system to a fully configured state.
> 
> To make the experimentation and contribution to the build system development easier,
> I've set up a git mirror of DRLVM repository on repo.or.cz. Use following commands to check out the copy
> 
>      $ git clone git://repo.or.cz/drlvm.git
>      $ cd drlvm
>      $ git checkout -b mob origin/mob
> 
> The branch 'master' is a pure mirror of SVN, and branch 'mob' contains the patch with the makefiles.
> In order to facilitate easy integration of many patches, anonymous write access without password
> is enabled with mob account [1]. The following command can be used to push patches to the repository
> 
>     $ git push ssh://mob@repo.or.cz/srv/git/drlvm.git mob
> 
> The only writable branch is 'mob'. Using this anonymously writable branch, anyone (including non-committers)
> can contribute patches, and all modifications will be collected in one place without having to mail or
> upload multitude of patches. It would be easier for me to review patches in this way as well.
> 
> So, if you are interested in having a more efficient and convenient build system for DRLVM, 
> please help in porting it to more platforms.

Salikh, GIT mirror of DRLVM is cool (!!!) (I would be glad to use it
instead of using my own mirror as of today), but contribution back to
GIT does not follow our process and each patch will have to be
attached back to JIRA thus requiring duplicate of work, which is not
very usable.

I am thinking of a more convenient way to use GIT: run a JIRA crawler
to collect all patches in JIRA (allowed to include in our sources) and
apply them to the mirror (add a patch to the experimental branch
automatically if the patch does not break a set of predefined
tests). How is that?

And BIG THANKS for working on the build system. I am kinda deadly
annoyed with current speed. With make we could cook parallel builds
upto distcc.

-- 
Egor Pasko


Re: [drlvm][PATCH/RFC] GNU Make-based build system for DRLVM -- call for help

Posted by Salikh Zakirov <sa...@gmail.com>.
Salikh Zakirov wrote:
> The functionality for the cross-platform configuration is designed in the makefiles,
> however, the configuration itself is missing, and I need help from volunteers to bring
> this build system to a fully configured state.

Sorry, I've forgot to give the instructions to get started with make system.
After you have obtained the patches work tree (or applied HARMONY-4640), do the following

  $ cd drlvm/build
  $ sh build.sh			# this will build extras and create deploy directory
  $ make

After this, the only command needed to recompile native bits of DRLVM is 'make'.

The build configuration is distributed as follows:

  build/Makefile contains the list of subcomponents (SUBDIRS)
  each subdire contains a subcomponent Makefile, currently
    vm/em/Makefile
    vm/vmi/Makefile
    vm/port/src/encoder/Makefile
    vm/port/Makefile
    vm/gc_cc/Makefile
    vm/tests/unit/ulist/Makefile
    vm/interpreter/Makefile
    vm/gc_gen/Makefile
    vm/thread/Makefile
    vm/vmcore/Makefile
    vm/jitrino/Makefile

  Each makefile contains a build configuration of a component, in a sequence of variable assignments of the form

    SOURCES := $(wildcard src/*.cpp)
    lnx_SOURCES := $(wildcard src/linux/*.cpp)

  The available configuration are described in detail in comments in build/makerules.inc, the list is
     NAME, TYPE, SOURCES, DEFINES, INCLUDES, SODEPENDS, LIBDEPENDS, LIBS, LIBDIRS, CFLAGS, CXXFLAGS, LDFLAGS

  The available prefixes are
    OSTAG = win | linux
    ARCHTAG = ia32 | em64t | ipf
    CFG = debug | release
  and some combinations thereof. Grep for '$($(' in makerules.inc for details.

What is ultimately needed is to put the configuration for platforms other than lnx/ia32 to the above Makefiles.