mirror of
https://github.com/phire/kvmbox.git
synced 2024-05-12 18:25:12 -04:00
Replaced plain old make with qmake. (Note: qmake has no idea how to build the loader, but that doesn't really need to be changed)
Started a gui in Qt.
This commit is contained in:
parent
7afe0e9822
commit
871f2d3142
16
Makefile
16
Makefile
|
@ -1,16 +0,0 @@
|
|||
CFLAGS = -g -O2 -Wall
|
||||
LIBS = -lpthread
|
||||
|
||||
all: kvmbox loader
|
||||
|
||||
kvmbox: main.c kvmbox.o smbus.o pci.o
|
||||
gcc $(CFLAGS) $(LIBS) main.c kvmbox.o smbus.o pci.o -o kvmbox
|
||||
|
||||
loader: loader.asm
|
||||
nasm loader.asm
|
||||
|
||||
clean:
|
||||
rm *.o kvmbox
|
||||
|
||||
run: kvmbox
|
||||
./kvmbox BIOSs/mine/2bl.img BIOSs/mine/bios.bin
|
21
gui.cpp
Normal file
21
gui.cpp
Normal file
|
@ -0,0 +1,21 @@
|
|||
#include <QtGui>
|
||||
|
||||
int main(int argv, char **args) {
|
||||
QApplication app(argv, args);
|
||||
|
||||
QTextEdit *textEdit = new QTextEdit;
|
||||
QPushButton *quitButton = new QPushButton("Quit");
|
||||
|
||||
QObject::connect(quitButton, SIGNAL(clicked()), qApp, SLOT(quit()));
|
||||
|
||||
QVBoxLayout *layout = new QVBoxLayout();
|
||||
layout->addWidget(textEdit);
|
||||
layout->addWidget(quitButton);
|
||||
|
||||
QWidget window;
|
||||
window.setLayout(layout);
|
||||
|
||||
window.show();
|
||||
|
||||
return app.exec();
|
||||
}
|
17
xbox.pro
Normal file
17
xbox.pro
Normal file
|
@ -0,0 +1,17 @@
|
|||
######################################################################
|
||||
# Automatically generated by qmake (2.01a) Mon Oct 17 18:26:57 2011
|
||||
######################################################################
|
||||
|
||||
TEMPLATE = app
|
||||
TARGET = kvmbox
|
||||
DEPENDPATH += .
|
||||
INCLUDEPATH += .
|
||||
|
||||
# Input
|
||||
|
||||
HEADERS += kvmbox.h
|
||||
SOURCES += gui.cpp kvmbox.c pci.c smbus.c
|
||||
|
||||
nogui {
|
||||
SOURCES = main.c kvmbox.c pci.c smbus.c
|
||||
}
|
Loading…
Reference in a new issue