1 CC=/usr/bin/x86_64-w64-mingw32-gcc 2 CXX=/usr/bin/x86_64-w64-mingw32-g++ 3 STRIP=/usr/bin/x86_64-w64-mingw32-strip 4 CFLAGS=-O2 -Wall -static -static-libgcc -static-libstdc++ -D_FILE_OFFSET_BITS=64 -g 5 CXXFLAGS=-O2 -Wall -static -static-libgcc -static-libstdc++ -D_FILE_OFFSET_BITS=64 -g 6 #CXXFLAGS=-O2 -Wall -D_FILE_OFFSET_BITS=64 -I /usr/local/include -I/opt/local/include -g 7 LIB_NAMES=guid gptpart bsd parttypes attributes crc32 mbrpart basicmbr mbr gpt support diskio diskio-windows 8 MBR_LIBS=support diskio diskio-windows basicmbr mbrpart 9 LIB_SRCS=$(NAMES:=.cc) 10 LIB_OBJS=$(LIB_NAMES:=.o) 11 MBR_LIB_OBJS=$(MBR_LIBS:=.o) 12 LIB_HEADERS=$(LIB_NAMES:=.h) 13 DEPEND= makedepend $(CFLAGS) 14 15 all: gdisk fixparts 16 17 gdisk: $(LIB_OBJS) gdisk.o gpttext.o 18 $(CXX) $(CXXFLAGS) $(LIB_OBJS) gdisk.o gpttext.o -lrpcrt4 -static-libgcc -o gdisk64.exe 19 20 sgdisk: $(LIB_OBJS) sgdisk.o 21 $(CXX) $(CXXFLAGS) $(LIB_OBJS) sgdisk.o -lpopt -static-libgcc -o sgdisk64.exe 22 23 fixparts: $(MBR_LIB_OBJS) fixparts.o 24 $(CXX) $(CXXFLAGS) $(MBR_LIB_OBJS) fixparts.o $(LDFLAGS) -static-libgcc -o fixparts64.exe 25 26 lint: #no pre-reqs 27 lint $(SRCS) 28 29 clean: #no pre-reqs 30 rm -f core *.o *~ gdisk64.exe sgdisk64.exe 31 32 strip: #no pre-reqs 33 $(STRIP) gdisk64.exe fixparts64.exe 34 35 # what are the source dependencies 36 depend: $(SRCS) 37 $(DEPEND) $(SRCS) 38 39 $(OBJS): 40 41 # DO NOT DELETE 42