The Mozilla
Organization
Our Mission
Who We Are
Getting Involved
Community
Editorials
What's New
Newsbot
Development
Roadmap
Module Owners
Blue Sky
Projects
Status
Tools
Products
Source Code
Binaries
Documentation
License Terms
Bug Reports
Quality
Search
Feedback


Configurator FAQ

Stephen Lamm, slamm@netscape.com
Last modified: Wed Mar 31 09:02:59 PST 1999
Q. What are the Unix Build Configurator and client.mk?
Q. How does it work?
Q. Can I still do all the build steps by hand?
Q. Can I reload and existing '.mozconfig'?
Q. How do I force client.mk to run autoconf?
Q. How do I use .mozconfig with more than one tree?
Q. What is the best way to build with dependencies? Should I use 'make depend'?
Q. I changed a Makefile.in file. How to do I update the Makefile?
Q. What are the Unix Build Configurator and client.mk?
A. The Unix Build Configurator is a CGI form for picking and saving build options.
client.mk has been around for a while, but I never used it because there was no easy way to pass options into it. It used a set of environment variable to control parameters. However, these variables had no direct correlation to the options that configure used.

The .mozconfig script describes build options in a way that both client.mk and configure understand. It saves you the trouble of typing the options on the command-line all the time. Of course, you are still welcome to type options on the command-line if you want. Any options you give configure on the command-line will be listed after the .mozconfig options. In this way, you can override individual .mozconfig options.

 
Q. How does it work?
A. The Build Configurator produces a script, .mozconfig, that you save in your home directory. When client.mk runs, it reads in the options that apply to it (e.g. object dirctory). When configure runs, it also reads in the options that it understands.

If you are interested in more of the details, you can start by looking at the README file. Or, send me an email.

 
Q. Can I still do all the build steps by hand?
A. Absolutely. Fill free to mix and match build steps.
 
Q. Can I reload and existing '.mozconfig'?
A. Yes.
    cd mozilla
    gmake -f client.mk webconfig
It uses netscape -remote, so make sure you have netscape running. I also plan to add a "Load .mozconfig" button to the form.
 
Q. How do I force client.mk to run autoconf?
A. Set the environment variable RUN_AUTOCONF_LOCALLY. You should not need to do this unless you are making changes to configure.in. The configure script gets updated automatically anytime someone makes a change to configure.in.
 
Q. How do I use .mozconfig with more than one tree?
A. If you want to use different options with different trees, you can save a ".mozconfig" as mozilla/.mozconfig in the root of the tree. That file will be read instead of the .mozconfig in your home directory. If you only want to override an option or two, you could save a mozilla/.mozconfig like the following,
    # mozilla/.mozconfig
    . $HOME/.mozconfig
    ac_add_options --disable-debug
 
Q. What is the best way to build with dependencies? Should I use 'make depend'?
A. If you are building with gcc or egcs, you should build with --enable-md. This causes the compiler to generate the dependencies when the objects are build. With this option, there is no need to run 'make depend'. There are some issues with --enable-md and building with 'make -j8'. slamm plans to have a fix for this real soon.
 
Q. I changed a Makefile.in file. How to do I update the Makefile?
A. make will update the Makefile for you. It has a dependency rule to update the Makefile,
    $(OBJDIR)/Makefile: Makefile.in
      @echo Updating $@
      $(topsrcdir)/build/autoconf/update-makefile.sh


Send questions or comments to <slamm@netcape.com>.



Copyright © 1998 The Mozilla Organization.