Platform-independent MAKE

Platform-independent MAKE

Post by Ron Lancast » Sat, 25 Feb 1995 23:03:17

I am writing a make file that will be used in a variety of flavors
of Unix (including standard AIX, NCR, HP, SunOS, SunSolaris,
and VAX as well as gnu make) to build archive libraries.
The directory structure looks something like this:

Source files in:  /project/source
Archive libs in:  /project/libs

Because a variety of different compiling environments are used
on each system, the object files can be put one of four places,
depending on which option is passed to make.

Object files in:  /project/source/o1 or /project/source/o2 or
   /project/source/o3 or /project/source/o4

All the libraries (archives) are kept in the same directory and
have a digit 1-4 just before ".a" to identify which library it is.

I currently set VPATH to the object directory before calling make
and use the following rule, where all indicated macros are set
in a shell script before calling make:


The target is specified as follows:
/project/libs/lib$(LIBDIGIT) : f1.o f2.o f3.o f4.o

The above works fine on AIX and GNU and on the Sun systems.  However,
the NCR and the HP systems don't know about VPATH (which is how the
system knows where to look for the object files when building the archive).
I've tried putting full paths everywhere, but can't seem to get a combination
that works in all environments.

Has anyone else solved a problem like this one?  I need to maintain the same
code across multiple architectures (including non-Unix) and I'm hoping to
maintain only a single set of makefiles and shell scripts for Unix.


1. Best windows (platform-independent) Debugger?

What's currently the best debugger available. GNU?
I'm new to UNIX and looking for something which will run across
 several platforms - Ultrix, SUN, Apollo, etc - in a windows environment
 using C, FORTRAN, etc.
Price is a major consider - public domain is most attractive.
Thanks in advance,

                            |   ( )       ( )   |
| Name           : John B. Macallister                                        |
| Postal address : Nuclear Physics Laboratory, Keble Road, Oxford OX1 3RH, UK.|
| Telephone      : +44-865-273388 (direct) +44-865-273333 (tel receoption)    |
| Telex          : 83295 NUCLOX G                                             |
| Fax            : +44-865-273418                                             |

|                : UK.AC.OX.PH is DTE 000050250060 on the UK JANET network    |
|                : UK.AC.OX.PH is DTE 204334505211 on IXI                     |



3. make AT_SYSINFO platform-independent

4. /sbin/genksyms

5. Platform-independent shell scripts?

6. Linux/X MS bus mouse not found

7. ANNOUNCE: Spectrum Software Launches First Truly Integrated, Platform-Independent SCM System In Europe

8. Using disklabel

9. platform independent installation tools

10. No fast platform independent interfaces?

11. Are IEEE floats platform independent?

12. Platform independent JavaScript engine server application.

13. Platform independent IPsec