Please, who could tell me how to append the *dependencies* for the
project shown by the below Makefile ?

The source files are in the directories shown below. 
.hi, .o  files go to the directory  $(E)/

I tried   cd <directoryOf_Makefile>;  ghc -M;
                                      mkdependHS;
                                      make depend
and they always create the empty list.
Respond privately, please.
Thank you in advance.

------------------
Sergey Mechveliani
[EMAIL PROTECTED]




-- Makefile ------------------------------------ 

HC       = $(ghcRoot)/ghc
RANLIB   = ar -s
E        = export
RM       = rm -f
language = -fglasgow-exts  -optC-fallow-overlapping-instances \
                           -optC-fallow-undecidable-instances
HCFlags  = $(language)  -fvia-C  -O -O2-for-C                 \
           ...
a  =auxil/
d  =demotest/
f  =factor/
p  =parse/
r  =residue/
s  =source/
sy =symmfunc/

$(s)$(d)T__flags =  -Onot

# in this succession the compilation proceeds: ---------------------

dcFiles = $(a)Prelude_   $(p)Iparse_   $(p)OpTab_    \
          ...
dmFiles = $(d)T_permut   $(d)T_reseuc  $(d)T_primes  \
  ...
doconFiles = $(dcFiles:%= source/%)
demoFiles  = $(dmFiles:%= source/%)
doconSrcs  = $(doconFiles:%= %.hs)
doconObjs  = $(doconFiles:%= %.o)
demoSrcs   = $(demoFiles:%= %.hs)
demoObjs   = $(demoFiles:%= %.o)

.SUFFIXES : .hi .hs .o

.o.hi:
        @:

.hs.o: 
        $(HC) -c $< $(HCFlags) 

objs:   $(doconObjs) $(demoObjs)

docon:  $(doconObjs)
        $(RM)      $(E)/libDocon.a
        ar -q      $(E)/libDocon.a  `ls $(E)/*.o`
        $(RANLIB)  $(E)/libDocon.a 

depend: $(HC) -M $(doconSrcs)   ****** ???
----------------------------------------------------------------











Reply via email to