The R Project SVN R

Rev

Rev 37255 | Rev 38696 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | Download | RSS feed

#-*- Makefile -*-
include ../../gnuwin32/MkRules

MODULE=internet
all: makeMakedeps ../../../modules/internet.dll ../../../modules/internet2.dll

CSOURCES=internet.c nanoftp.c nanohttp.c sockconn.c Rsock.c sock.c

CFLAGS=$(OPTFLAGS) -I../../include -I../../gnuwin32 -DHAVE_CONFIG_H

../../../modules/internet.dll: internet.o nanoftp.o nanohttp.o sockconn.o Rsock.o sock.o dllversion.o

    $(MKDIR) -p ../../../modules
    @$(ECHO) "EXPORTS" >> internet.def
    @$(ECHO) " R_init_internet" >> internet.def
    $(DLL) -shared  -o $@ $^ internet.def -L../../../bin -lR -lwsock32
    @$(RM) internet.def

../../../modules/internet2.dll: internet2.o sockconn.o Rsock.o sock.o dllversion.o
    $(MKDIR) -p ../../../modules
    @$(ECHO) "EXPORTS" >> internet.def
    @$(ECHO) " R_init_internet2" >> internet.def
    $(DLL) -shared  -o $@ $^ internet.def -L../../../bin -lR -lwininet -lwsock32 
    @$(RM) internet.def

internet2.o: internet.c
    $(CC)  $(CFLAGS) -DUSE_WININET -c $< -o $@

clean:
    @$(RM) Makedeps *.d *.o *.def *.dll

# Dependencies
dllversion.o: ../../include/Rversion.h
DEPS=$(CSOURCES:.c=.d)

makeMakedeps: $(DEPS)
    @$(RM) Makedeps
    @cat $(DEPS) >> Makedeps

-include Makedeps