Debian Codegraph @

debian/patches/cross.patch

raw
1 --- a/Makefile
2 +++ b/Makefile
3 @@ -1,3 +1,6 @@
4 +CC ?= gcc
5 +CXX ?= g++
6 +AR ?= ar
7 CPPFLAGS=-g -Wall -fPIC
8 CFLAGS=-g -Wall -fPIC
9
10 @@ -20,10 +23,10 @@
11 debug: clean all
12
13 libmmap_allocator.so: mmap_file_pool.o
14 - g++ -shared -o libmmap_allocator.so mmap_file_pool.o
15 + $(CXX) -shared -o libmmap_allocator.so mmap_file_pool.o
16
17 libmmap_allocator.a: mmap_file_pool.o
18 - ar r libmmap_allocator.a mmap_file_pool.o
19 + $(AR) r libmmap_allocator.a mmap_file_pool.o
20
21 install_sources: $(SOURCES)
22 cp $(SOURCES) $(SRC_INSTALL_TARGET_DIR)
23 @@ -41,10 +44,10 @@
24 bash -c 'export LD_LIBRARY_PATH=. ; ./test_allocator'
25
26 test_allocator: mmap_allocator.h mmap_file_pool.o test_allocator.o $(LIBRARIES)
27 - g++ test_allocator.o -L. -lmmap_allocator -o test_allocator
28 + $(CXX) test_allocator.o -L. -lmmap_allocator -o test_allocator
29
30 test_mmap_fixed: test_mmap_fixed.c
31 - gcc $(CFLAGS) test_mmap_fixed.c -o test_mmap_fixed
32 + $(CC) $(CFLAGS) test_mmap_fixed.c -o test_mmap_fixed
33
34 clean:
35 rm -f test_allocator test_mmap_fixed testfile testfile2 *.o $(LIBRARIES)