This is the mail archive of the cygwin@sourceware.cygnus.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

difference between linux and cygwin32 makefile?


I try to built the same program under cygwin32 and linux RatHat

The makefile has multiple machine specifications e.g DEC, HP, convex,
and SGI.

Questions?>
Generally, how should I choose the settings in the makefile? Which
machine's settings should I choose? Since I am new to unix, please
advice how to learn to set these settings for either linux or cygwin32
when the makefile is not universal unix friendly.

By arbitrarity keeping to the DEC settings, the program can be built in
linux ( though it causes segmentation core dump when run). For cygwin32,
the build process terminated with the following errors

XXX.o<.text+0X3b>: XXX.c: undefiend reference to 'drand48'
XXX.o<.text+0X71>: XXX.c: undefiend reference to 'srand48'
XXX.o<.text+0Xe4>: XXX.c: undefiend reference to 'lockf'

The following is extracted from the makefile
***************************************************************
LIB= -lm
#LIB= -lm #       DEC-Alpha,HP,SGI
#LIB= -lm -lc #       Convex

PROF=
#PROF= #       no profiling
#PROF= -p #       profiling

DBUG=
#DBUG= #       no debugging
#DBUG= -g3 #       dbx, DEC-Alpha, SGI
#DBUG= -DDEBUG #      DEBUG code
#DBUG= -g -DDEBUG #      dbx+DEBUG code

CSTD= -std -edit2 -verbose $(PROF) $(DBUG) #  DEC-Alpha
#CSTD= -std $(PROF) $(DBUG) #    SGI
#CSTD= -DHPPA -D_HPUX_SOURCE -Aa $(PROF) $(DBUG) # HP
#CSTD= -std $(PROF) $(DBUG) #    Convex

CFLAGS= $(CSTD) -O2 #     SGI,DEC-Alpha,HP,Convex

CCOPT= -O2 $(CSTD) #     DEC-Alpha,Convex
#CCOPT= -O2 -mips2 $(CSTD) #    SGI
#CCOPT= -O +O3 +Obb1000 $(CSTD) #   HP
#CCOPT= $(CSTD) #      dbx debugging

CCOPT3= -O3 $(CSTD) #     DEC-Alpha,Convex
#CCOPT3= $(CCOPT) #     SGI, HP
#CCOPT3= #       dbx debugging

#OPTLIM= $(CCOPT) -Olimit 2500 #    SGI,DEC-Alpha
OPTLIM= $(CCOPT) #     HP, Convex
#OPTLIM= #       dbx debugging

LINT = lint #      code checking

LINTFLAGS= $(LIB) -MA -c #    DEC-Alpha
#LINTFLAGS= -DHPPA -D_HPUX_SOURCE -Aa $(LIB) -c # HP
#LINTFLAGS= -u -n -lm #     Sun Sparc

******************************************************************

I appreciate any suggestion. Thank you

Seow

-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]