Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to achieve similar functionality in a server for community programming and I've drafted this to wrap up another take on oneide's functions: From a Perl CGI I build a script like this (not even pseudocode):

compiler_response = timeout (params) compiler (params)
result = timeout compiledprogram (params)
save result in database

I think timeout is the tool I need to restrain the program from executing or compiling more than X seconds, The problem I have is that I need to limit the compiled program from writing to anything other than STDOUT or reading from anything other than STDIN. Also I need to limit the size of the program to a certain limit, 128KB for example, and the ammount of RAM it can use, 64 MB for example.

What are the proper tools to do this from bash? Thanks in advance.

share|improve this question

LibreOffice and KDE use icecream & ccache for building faster their gigantic code source.

  • Ccache keeps many compiling information available for gcc/g++ for next one.
  • Icecream allows to compile remotely with a classical master/slave approach

They works really well, are easy to set up and are already integrated in many Linux distributions. On libreoffice, build time goes from 4 hours to 30 minutes.

If you do not plan to compile using gcc, maybe you can enhance one of those tools.

share|improve this answer

we use buildbot in our company.

share|improve this answer

I have not tried this before, but you could try using Koji of FedoraProject, this one builds RPM from the code tarballs.


It uses Mock


If your code is all about Java/.NET enterprise stuff, Hudson can be really cool http://wiki.hudson-ci.org/display/HUDSON/Home

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.