diff -Nuar wxHexEditor.old//makefile wxHexEditor/makefile --- wxHexEditor.old//makefile 2012-03-07 00:24:51.136162595 +0600 +++ wxHexEditor/makefile 2012-03-07 00:46:58.705208433 +0600 @@ -1,8 +1,8 @@ WXCONFIG = wx-config CC = `$(WXCONFIG) --cc` CPP = `$(WXCONFIG) --cxx` -CXXFLAGS= `$(WXCONFIG) --cxxflags` -Iudis86 -Imhash/include -MMD -O2 -c ${OPTFLAGS} -LDFLAGS = `$(WXCONFIG) --libs` +WXCXXFLAGS= `$(WXCONFIG) --cxxflags` -MMD -c ${OPTFLAGS} +WXLDFLAGS = `$(WXCONFIG) --libs` ${LDFLAGS} RC = `$(WXCONFIG) --rescomp` #RC = x86_64-w64-mingw32-windres --define WX_CPU_AMD64 RCFLAGS = `$(WXCONFIG) --cxxflags | sed s/' '-m.*//g;` @@ -19,7 +19,7 @@ src/HexEditorCtrl/wxHexCtrl/Tag.cpp\ src/HexEditorCtrl/HexEditorCtrlGui.cpp\ src/HexEditorFrame.cpp -LIBS = udis86/libudis86/.libs/libudis86.a mhash/lib/.libs/libmhash.a +LIBS = -ludis86 -lmhash OBJECTS=$(SOURCES:.cpp=.o) DEPENDS=$(OBJECTS:.o=.d) RESOURCES= resources/resource.rc @@ -28,7 +28,8 @@ EXECUTABLE_WIN=$(EXECUTABLE).exe EXECUTABLE_DIR_MAC=$(EXECUTABLE).app -PREFIX = /usr/local +DESTDIR = +PREFIX = $(DESTDIR)/usr BINDIR = $(PREFIX)/bin DATADIR = $(PREFIX)/share LOCALEDIR = $(DATADIR)/locale @@ -37,34 +38,25 @@ all: $(EXECUTABLE) -$(OBJECTS): $(LIBS) $(SOURCES) +$(OBJECTS): $(SOURCES) $(EXECUTABLE): $(OBJECTS) - $(CPP) $(OBJECTS) $(LIBS) $(LDFLAGS) -lgomp -o $@ + $(CPP) $(OBJECTS) $(LIBS) $(WXLDFLAGS) $(LDFLAGS) -lgomp -o $@ -.cpp.o: $(LIBS) - $(CPP) $(CXXFLAGS) $< -o $@ +.cpp.o: + $(CPP) $(WXCXXFLAGS) $(CXXFLAGS) $< -o $@ %.o : %.rc $(RC) $(RCFLAGS) $< -o $@ -udis86/libudis86/.libs/libudis86.a: - cd udis86;./autogen.sh - cd udis86;./configure --host=$(HOST) - cd udis86/libudis86; $(MAKE) $(MFLAGS) - -mhash/lib/.libs/libmhash.a: - cd mhash; ./configure --host=$(HOST) - cd mhash; $(MAKE) $(MFLAGS) - win: $(RESOURCES) $(EXECUTABLE_WIN) #Stack override required for file comparison function... $(EXECUTABLE_WIN): $(OBJECTS) $(RESOURCE_OBJ) - $(CPP) $(OBJECTS) $(RESOURCE_OBJ) $(LIBS) $(LDFLAGS) -static-libgcc -static-libstdc++ -Wl,--stack,32000000 -o $@ + $(CPP) $(OBJECTS) $(RESOURCE_OBJ) $(LIBS) $(WXLDFLAGS) -static-libgcc -static-libstdc++ -Wl,--stack,32000000 $(LDFLAGS) -o $@ maclink: $(OBJECTS) - $(CPP) $(OBJECTS) $(LIBS) $(LDFLAGS) -lexpat -Wl,-stack_size,0x2000000 -o $(EXECUTABLE) + $(CPP) $(OBJECTS) $(LIBS) $(WXLDFLAGS) -lexpat -Wl,-stack_size,0x2000000 $(LDFLAGS) -o $(EXECUTABLE) mac: maclink mkdir -p $(EXECUTABLE_DIR_MAC)/Contents diff -Nuar wxHexEditor.old//src/HexDialogs.cpp wxHexEditor/src/HexDialogs.cpp --- wxHexEditor.old//src/HexDialogs.cpp 2012-03-07 00:24:51.073162593 +0600 +++ wxHexEditor/src/HexDialogs.cpp 2012-03-07 00:42:12.354198548 +0600 @@ -24,7 +24,7 @@ #define NANINT 0xFFFFFFFFFFFFFFFFLL #include "HexDialogs.h" #include -#include "../mhash/include/mhash.h" +#include #ifdef _OPENMP #include diff -Nuar wxHexEditor.old//src/HexEditor.h wxHexEditor/src/HexEditor.h --- wxHexEditor.old//src/HexEditor.h 2012-03-07 00:24:51.074162593 +0600 +++ wxHexEditor/src/HexEditor.h 2012-03-07 00:42:34.105199299 +0600 @@ -25,7 +25,7 @@ #ifndef _wxHexEditor_h_ #define _wxHexEditor_h_ -#include "../mhash/include/mhash.h" +#include #include #include diff -Nuar wxHexEditor.old//src/HexPanels.h wxHexEditor/src/HexPanels.h --- wxHexEditor.old//src/HexPanels.h 2012-03-07 00:24:51.073162593 +0600 +++ wxHexEditor/src/HexPanels.h 2012-03-07 00:41:24.105196881 +0600 @@ -27,7 +27,7 @@ #include "HexEditorFrame.h" #include "HexEditorCtrl/HexEditorCtrl.h" #include "HexEditorCtrl/wxHexCtrl/wxHexCtrl.h" -#include "../udis86/udis86.h" +#include #ifdef WX_GCH #include