Changed makefile of emulator to run on windows.
This commit is contained in:
5
emulator/.gitignore
vendored
5
emulator/.gitignore
vendored
@@ -5,8 +5,9 @@ qt/*.o
|
||||
qt/*.a
|
||||
qt/ui_*
|
||||
qt/moc_*
|
||||
qt/Makefile
|
||||
|
||||
qt/Makefile*
|
||||
qt/debug
|
||||
qt/release
|
||||
|
||||
libs/*/obj
|
||||
libs/*/*.a
|
||||
|
||||
@@ -10,7 +10,7 @@ QT_DIR=./qt
|
||||
COMMON_DIR=../common
|
||||
|
||||
#Tools
|
||||
CC=gcc -fdiagnostics-color=auto
|
||||
CC=gcc #-fdiagnostics=auto
|
||||
GDB=gdb
|
||||
|
||||
|
||||
@@ -28,13 +28,17 @@ CPPFLAGS= -march=x86-64 -mtune=generic -fPIC $(INCLUDES)
|
||||
CFLAGS= -O0 -g -std=c99
|
||||
|
||||
|
||||
LIBS= pixy usb-1.0 boost_system boost_timer boost_chrono
|
||||
LIBS+=Qt5Core Qt5Gui Qt5Widgets emulatorqt m stdc++
|
||||
LIBS= emulatorqt pixy usb-1.0
|
||||
LIBS+= boost_system-mgw49-mt-1_58 boost_timer-mgw49-mt-1_58 boost_chrono-mgw49-mt-1_58
|
||||
LIBS+= Qt5Core Qt5Gui Qt5Widgets m stdc++
|
||||
|
||||
|
||||
LDFLAGS= -L$(QT_DIR) $(addprefix -l,$(LIBS))
|
||||
LDFLAGS= -static-libgcc -static-libstdc++ #-Wl,-t -Wl,--Map=a.map
|
||||
LDFLAGS+= -L$(QT_DIR)
|
||||
LDFLAGS+= -L$(LIB_DIR)/Pixy
|
||||
|
||||
LDFLAGS+= -LC:/boost_1_58_0/buildsys/lib
|
||||
LDFLAGS+= -LC:/Qt/5.4/mingw491_32/lib
|
||||
LDFLAGS+= -L./libs/Pixy/windows
|
||||
LDFLAGS+= $(addprefix -l,$(LIBS))
|
||||
|
||||
#Finding Input files
|
||||
CFILES=$(shell find . -maxdepth 1 -name '*.c')
|
||||
@@ -58,7 +62,7 @@ debug: all
|
||||
$(GDB) ./build/emulator
|
||||
|
||||
$(QT_LIB):
|
||||
cd $(QT_DIR) && qmake &&make
|
||||
cd $(QT_DIR) && qmake && $(MAKE)
|
||||
|
||||
#objects to elf
|
||||
$(BUILD_DIR)/$(TARGET): $(OBJS) $(COMMON_OBJS) $(QT_LIB)
|
||||
@@ -83,7 +87,7 @@ $(OBJ_DIR)/%.o: $(COMMON_DIR)/%.c
|
||||
|
||||
#Clean Obj files and builded stuff
|
||||
clean:
|
||||
cd $(QT_DIR) && $(MAKE) clean && $(RM) Makefile && $(RM) *.a
|
||||
cd $(QT_DIR) && $(MAKE) clean && $(RM) Makefile* && $(RM) *.a && $(RMDIR) debug release
|
||||
$(RMDIR) $(BUILD_DIR) $(OBJ_DIR)
|
||||
|
||||
|
||||
|
||||
@@ -17,11 +17,13 @@ OBJ_DIR=./obj
|
||||
#Architecture flags
|
||||
|
||||
#Compiler, Linker Options
|
||||
CPPFLAGS=-I$(INC_DIR) -D__LINUX__=1 -DHOST=1 #-DDEBUG=1
|
||||
CPPFLAGS=-I$(INC_DIR) -DHOST=1 #-D__LINUX__=1 -DDEBUG=1
|
||||
CFLAGS=$(ARCH_FLAGS) -O0 -g #-ffunction-sections -fdata-sections -g
|
||||
#CFLAGS += -mlittle-endian -mthumb -mcpu=cortex-m4 -mthumb-interwork
|
||||
#CFLAGS += -mfloat-abi=hard -mfpu=fpv4-sp-d16
|
||||
CFLAGS+=-I/usr/include/libusb-1.0
|
||||
CFLAGS+=-I/usr/include/libusb-1.0
|
||||
CFLAGS+=-IC:/boost_1_58_0/buildsys/include/boost-1_58
|
||||
CFLAGS+=-I./windows/
|
||||
|
||||
#Finding Input files
|
||||
CFILES=$(shell find $(SRC_DIR) -name '*.cpp')
|
||||
|
||||
BIN
emulator/libs/Pixy/windows/libusb-1.0.dll
Normal file
BIN
emulator/libs/Pixy/windows/libusb-1.0.dll
Normal file
Binary file not shown.
BIN
emulator/libs/Pixy/windows/libusb-1.0.dll.a
Normal file
BIN
emulator/libs/Pixy/windows/libusb-1.0.dll.a
Normal file
Binary file not shown.
1970
emulator/libs/Pixy/windows/libusb.h
Normal file
1970
emulator/libs/Pixy/windows/libusb.h
Normal file
File diff suppressed because it is too large
Load Diff
@@ -8,7 +8,7 @@ QT += widgets gui
|
||||
|
||||
TARGET = emulatorqt
|
||||
TEMPLATE = lib
|
||||
CONFIG += staticlib
|
||||
CONFIG += staticlib debug
|
||||
|
||||
SOURCES += \
|
||||
mainwindow.cpp \
|
||||
@@ -30,3 +30,6 @@ INCLUDEPATH+= ../../common/lowlevel/ \
|
||||
FORMS += \
|
||||
mainwindow.ui
|
||||
|
||||
DESTDIR = $$_PRO_FILE_PWD_ #force windows to not create subfolders
|
||||
|
||||
#QMAKE_CXXFLAGS+= -v
|
||||
|
||||
BIN
emulator/windows_dlls.rar
Normal file
BIN
emulator/windows_dlls.rar
Normal file
Binary file not shown.
Reference in New Issue
Block a user