[XviD-devel] [RFC] Build process change for unix envs

Edouard Gomez ed.gomez at free.fr
Wed Sep 24 02:45:04 CEST 2003


Hello,

I would like to change the unix  build process a bit so it would compile
outside source tree in a well separated build directory.

This change has 2 good consequences and 1 bad.
 + this is clearer solution, sources are never mixed with object files
 + this allow easy per target building w/o file overwriting. This could
   save CPU time (cheap nowadays) and better cross comiling.
 - The Makefile would require support for some "make" features:
      * generic rules
      * VPATH
      * variables $< $^ $(<D) $(<F) $@ $(@F) $(@D)

Generic rules are rules that look like:
%.o : %.c
    $(CC) $(CFLAGS) -o $@ $<

The  VPATH  variable  makes  "make"  look  for  prerequisites  into  the
directories  specified into  it.  VPATH=  $(SRC_DIR):$(BUILD_DIR) allows
make looking  for all prerequisites  in the source dir  (when compiling)
and in the build dir (when linking)

Would my  change annoy some people  relying on current  build process or
can i go on and merge this change ?

PS: of course GNU make does work fine, but i suspect old solaris make to
break... the price for a better system.

-- 
Edouard Gomez


More information about the XviD-devel mailing list