diff --git a/.github/workflows/firmware_workflow.yml b/.github/workflows/firmware_workflow.yml new file mode 100644 index 0000000..3591c62 --- /dev/null +++ b/.github/workflows/firmware_workflow.yml @@ -0,0 +1,42 @@ +name: Build MMS + +on: + push: + branches: + - "main" + tags: + - "*" + pull_request: + +jobs: + make_gui: + runs-on: ubuntu-latest + name: GUI + + steps: + - uses: actions/checkout@v3 + - name: Install Deps + run: | + apt update + apt install qt5-qmake build-essential + - name: Make Bin + run: | + cd src + qmake mms.pro + make + + make_cli: + runs-on: ubuntu-latest + name: CLI + + steps: + - uses: actions/checkout@v2 + - name: Install Deps + run: | + apt update + apt install qt5-qmake build-essential + - name: Make Bin + run: | + cd src + qmake mms-cli.pro + make diff --git a/README.md b/README.md index 7356b1a..e604ea1 100644 --- a/README.md +++ b/README.md @@ -506,9 +506,12 @@ Clone, build, and run the project: # Clone the repo git clone git@github.com:mackorone/mms.git -# Build the simulator +# Build the simulator (gui) cd mms/src -qmake && make +qmake mms.pro && make + +# (Optional) Build the simulator (cli) +qmake mms-cli.pro && make # Run the simulator ../../bin/mms diff --git a/src/mms-cli.pro b/src/mms-cli.pro new file mode 100644 index 0000000..7634760 --- /dev/null +++ b/src/mms-cli.pro @@ -0,0 +1,23 @@ +QT += core +QT += gui +QT += opengl +QT += widgets +QT += xml + +TEMPLATE = app + +CONFIG += c++11 +CONFIG += debug +CONFIG += object_parallel_to_source +CONFIG += qt + +SOURCES += $$files(*.cpp, true) +SOURCES -= Window.cpp +HEADERS += $$files(*.h, true) +HEADERS -= Window.h +RESOURCES = resources.qrc + +DESTDIR = ../bin +MOC_DIR = ../build/moc +OBJECTS_DIR = ../build/obj +RCC_DIR = ../build/rcc diff --git a/src/mms.pro b/src/mms.pro index e6ef04a..f58f743 100644 --- a/src/mms.pro +++ b/src/mms.pro @@ -1,7 +1,6 @@ QT += core QT += gui QT += opengl -QT += openglwidgets QT += widgets QT += xml