The R Project SVN R

Rev

Rev 37099 | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 37099 Rev 37364
1
include ../MkRules
1
include ../MkRules
2
 
2
 
3
JPEGDIR=jpeg-6b
3
JPEGDIR=jpeg-6b
4
PNGDIR=libpng
4
PNGDIR=libpng
5
 
5
 
6
all:
6
all:
7
	@$(MAKE) --no-print-directory buildzlib buildpng buildjpeg rbitmap.o 
7
	@$(MAKE) --no-print-directory buildzlib buildpng buildjpeg rbitmap.o 
8
	@$(MAKE) --no-print-directory installdll
8
	@$(MAKE) --no-print-directory ../../../modules/Rbitmap.dll
9
 
9
 
10
buildzlib:
10
buildzlib:
11
	@$(MAKE) -C ../../extra/zlib -f Makefile.win
11
	@$(MAKE) -C ../../extra/zlib -f Makefile.win
12
 
12
 
13
buildpng:
13
buildpng:
14
	@$(MAKE) CC='$(CC)' CFLAGS="-O3 -I../../../extra/zlib" \
14
	@$(MAKE) CC='$(CC)' CFLAGS="-O3 -I../../../extra/zlib" \
15
	  RANLIB=$(RANLIB) ZLIBLIB=../../../extra/zlib -C $(PNGDIR) \
15
	  RANLIB=$(RANLIB) ZLIBLIB=../../../extra/zlib -C $(PNGDIR) \
16
	  -f scripts/makefile.std libpng.a
16
	  -f scripts/makefile.std libpng.a
17
 
17
 
18
# jconfig.h and Makefile obtained running 'CC="gcc -mno-cygwin" ./configure'
18
# jconfig.h and Makefile obtained running 'CC="gcc -mno-cygwin" ./configure'
19
# under CYGWIN. They are here since the configure script doesn't run 
19
# under CYGWIN. They are here since the configure script doesn't run 
20
# (I suspect) using the reduced set of tools we distribute.
20
# (I suspect) using the reduced set of tools we distribute.
21
## 2006-01-15 checked under current tools
21
## 2006-01-15 checked under current tools
22
buildjpeg: $(JPEGDIR)/jconfig.h Makefile.jpeg
22
buildjpeg: $(JPEGDIR)/jconfig.h Makefile.jpeg
23
	$(MAKE) CC='$(CC)' AR='$(AR) rc' RANLIB=$(RANLIB) -C $(JPEGDIR) \
23
	$(MAKE) CC='$(CC)' AR='$(AR) rc' RANLIB=$(RANLIB) -C $(JPEGDIR) \
24
	  -f ../Makefile.jpeg libjpeg.a
24
	  -f ../Makefile.jpeg libjpeg.a
25
 
25
 
26
$(JPEGDIR)/jconfig.h: jconfig.h 
26
$(JPEGDIR)/jconfig.h: jconfig.h 
27
	$(CP) jconfig.h $(JPEGDIR)/jconfig.h
27
	$(CP) jconfig.h $(JPEGDIR)/jconfig.h
28
 
28
 
29
rbitmap-CFLAGS=-O3 -Wall -pedantic -DHAVE_PNG -DHAVE_JPEG -I../../extra/zlib -I./libpng -I$(JPEGDIR) -I../../include
29
rbitmap-CFLAGS=-O3 -Wall -pedantic -DHAVE_PNG -DHAVE_JPEG -I../../extra/zlib -I./libpng -I$(JPEGDIR) -I../../include
30
Rbitmap-DLLLIBS=-L../../../bin -lR
30
# Rbitmap-DLLLIBS=-L../../../bin -lR
31
Rbitmap-DLLFLAGS=-s
31
# Rbitmap-DLLFLAGS=-s
32
 
32
 
33
Rbitmap.dll: rbitmap.o $(PNGDIR)/libpng.a $(JPEGDIR)/libjpeg.a
33
../../../modules/Rbitmap.dll: rbitmap.o $(PNGDIR)/libpng.a $(JPEGDIR)/libjpeg.a
34
 
-
 
35
installdll: Rbitmap.dll
-
 
36
	$(CP) Rbitmap.dll ../../../bin
34
	$(DLL) -shared -s -o $@ $^ -L../../../bin -lR
37
 
35
 
38
clean:
36
clean:
39
	$(RM) *.o *.a *.dll *.def *~ \#*\#
37
	$(RM) *.o *.a *.dll *.def *~ \#*\#
40
	-$(MAKE) CC='$(CC)' -C $(PNGDIR) -f scripts/makefile.std clean
38
	-$(MAKE) CC='$(CC)' -C $(PNGDIR) -f scripts/makefile.std clean
41
	-$(MAKE) CC='$(CC)' -C $(JPEGDIR) -f ../Makefile.jpeg clean
39
	-$(MAKE) CC='$(CC)' -C $(JPEGDIR) -f ../Makefile.jpeg clean
42
 
40
 
43
 
41
 
44
 
42
 
45
 
43