Makefile: windows - compile separate object files
This commit is contained in:
parent
991a21af4e
commit
013d98e941
67
Makefile
67
Makefile
@ -106,25 +106,68 @@ progresswindow.o: gtk/progresswindow.cpp
|
||||
.PHONY: windows
|
||||
windows: tv_rename.exe
|
||||
|
||||
tv_rename.exe: tv_rename.cpp functions.cpp windows/filesystem.cpp\
|
||||
windows/network.cpp progress.cpp sqlite3.c main.cpp tv_rename_stringtable.res
|
||||
$(CXX) -MD -EHsc -Fe"tv_rename" tv_rename.cpp windows/filesystem.cpp\
|
||||
functions.cpp windows/network.cpp progress.cpp sqlite3.c main.cpp\
|
||||
WINDOWS_CLI_OBJECTS = tv_rename_cli.obj functions_cli.obj filesystem_cli.obj\
|
||||
network_cli.obj progress_cli.obj sqlite3.obj main.obj
|
||||
|
||||
sqlite3.obj: sqlite3.c
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -D_WIN32 -DUNICODE -c
|
||||
tv_rename_cli.obj: tv_rename.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -D_WIN32 -DUNICODE -c
|
||||
functions_cli.obj: functions.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -D_WIN32 -DUNICODE -c
|
||||
filesystem_cli.obj: windows/filesystem.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -D_WIN32 -DUNICODE -c
|
||||
network_cli.obj: windows/network.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -D_WIN32 -DUNICODE -c
|
||||
progress_cli.obj: progress.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -D_WIN32 -DUNICODE -c
|
||||
main.obj: main.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -D_WIN32 -DUNICODE -c
|
||||
|
||||
tv_rename.exe: $(WINDOWS_CLI_OBJECTS) tv_rename_stringtable.res
|
||||
$(CXX) -MD -EHsc -Fe"tv_rename" $(WINDOWS_CLI_OBJECTS)\
|
||||
-D_WIN32 -DUNICODE -link wininet.lib shlwapi.lib ole32.lib\
|
||||
shell32.lib user32.lib tv_rename_stringtable.res
|
||||
|
||||
.PHONY: windows_gui
|
||||
windows_gui: tv_rename_gui.exe
|
||||
|
||||
WINDOWS_GUI_CPP = windows/gui.cpp windows/mainwindow.cpp\
|
||||
windows/gui_functions.cpp tv_rename.cpp\
|
||||
windows/filesystem.cpp functions.cpp windows/network.cpp\
|
||||
progress.cpp sqlite3.c windows/patternwindow.cpp\
|
||||
windows/progresswindow.cpp windows/seasonwindow.cpp\
|
||||
windows/databasewindow.cpp windows/searchwindow.cpp
|
||||
WINDOWS_GUI_OBJECTS = gui.obj mainwindow.obj\
|
||||
gui_functions.obj tv_rename.obj\
|
||||
filesystem.obj functions.obj network.obj\
|
||||
progress.obj sqlite3.obj patternwindow.obj\
|
||||
progresswindow.obj seasonwindow.obj\
|
||||
databasewindow.obj searchwindow.obj
|
||||
|
||||
tv_rename_gui.exe: $(WINDOWS_GUI_CPP) tv_rename.res tv_rename_stringtable.res
|
||||
$(CXX) -MD -EHsc -Fe"tv_rename_gui" $(WINDOWS_GUI_CPP) -DGUI -D_WIN32 -DUNICODE\
|
||||
gui.obj: windows/gui.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -DGUI -D_WIN32 -DUNICODE -c
|
||||
mainwindow.obj: windows/mainwindow.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -DGUI -D_WIN32 -DUNICODE -c
|
||||
gui_functions.obj: windows/gui_functions.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -DGUI -D_WIN32 -DUNICODE -c
|
||||
filesystem.obj: windows/filesystem.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -DGUI -D_WIN32 -DUNICODE -c
|
||||
network.obj: windows/network.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -DGUI -D_WIN32 -DUNICODE -c
|
||||
patternwindow.obj: windows/patternwindow.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -DGUI -D_WIN32 -DUNICODE -c
|
||||
progresswindow.obj: windows/progresswindow.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -DGUI -D_WIN32 -DUNICODE -c
|
||||
seasonwindow.obj: windows/seasonwindow.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -DGUI -D_WIN32 -DUNICODE -c
|
||||
databasewindow.obj: windows/databasewindow.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -DGUI -D_WIN32 -DUNICODE -c
|
||||
searchwindow.obj: windows/searchwindow.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -DGUI -D_WIN32 -DUNICODE -c
|
||||
tv_rename.obj: tv_rename.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -DGUI -D_WIN32 -DUNICODE -c
|
||||
functions.obj: functions.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -DGUI -D_WIN32 -DUNICODE -c
|
||||
progress.obj: progress.cpp
|
||||
$(CXX) -MD -EHsc -Fo"$@" $^ -DGUI -D_WIN32 -DUNICODE -c
|
||||
|
||||
tv_rename_gui.exe: $(WINDOWS_GUI_OBJECTS) tv_rename.res tv_rename_stringtable.res
|
||||
$(CXX) -MD -EHsc -Fe"tv_rename_gui" $(WINDOWS_GUI_OBJECTS) -DGUI -D_WIN32 -DUNICODE\
|
||||
-link wininet.lib shlwapi.lib ole32.lib\
|
||||
shell32.lib user32.lib gdi32.lib comctl32.lib tv_rename.res tv_rename_stringtable.res
|
||||
mt -manifest tv_rename_gui.exe.manifest -outputresource:tv_rename_gui.exe
|
||||
|
2
main.cpp
2
main.cpp
@ -4,10 +4,10 @@
|
||||
|
||||
#ifdef _WIN32
|
||||
|
||||
#include <windows.h>
|
||||
#include "resources_windows.h"
|
||||
#include <fcntl.h>
|
||||
#include <io.h>
|
||||
#include <windows.h>
|
||||
|
||||
using char_t = wchar_t;
|
||||
using string = std::wstring;
|
||||
|
@ -1,3 +1,4 @@
|
||||
#include <windows.h>
|
||||
#include "gui_functions.hpp"
|
||||
#include "mainwindow.hpp"
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
#include "gui_functions.hpp"
|
||||
#include "../functions.hpp"
|
||||
#include "../resources_windows.h"
|
||||
#include "gui_functions.hpp"
|
||||
#include "databasewindow.hpp"
|
||||
#include "mainwindow.hpp"
|
||||
#include "patternwindow.hpp"
|
||||
|
Loading…
Reference in New Issue
Block a user