diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..1353e07 --- /dev/null +++ b/.gitignore @@ -0,0 +1,55 @@ +# C++ objects and libs +*.slo +*.lo +*.o +*.a +*.la +*.lai +*.so +*.so.* +*.dll +*.dylib + +# Qt-es +object_script.*.Release +object_script.*.Debug +*_plugin_import.cpp +/.qmake.cache +/.qmake.stash +*.pro.user +*.pro.user.* +*.qbs.user +*.qbs.user.* +*.moc +moc_*.cpp +moc_*.h +qrc_*.cpp +ui_*.h +*.qmlc +*.jsc +Makefile* +*build-* +*.qm +*.prl + +# Qt unit tests +target_wrapper.* + +# QtCreator +*.autosave + +# QtCreator Qml +*.qmlproject.user +*.qmlproject.user.* + +# QtCreator CMake +CMakeLists.txt.user* + +# QtCreator 4.8< compilation database +compile_commands.json + +# QtCreator local machine specific files for imported projects +*creator.user* + +*_qmlcache.qrc +© 2020 GitHub, Inc. diff --git a/HomeForm.ui.qml b/HomeForm.ui.qml index a63aeb6..247c17b 100644 --- a/HomeForm.ui.qml +++ b/HomeForm.ui.qml @@ -4,8 +4,8 @@ import QtGraphicalEffects 1.0 Page { id: page - width: 1920 - height: 1080 + width: window.width + height: window.height contentWidth: 4 title: qsTr("Classmoor") background: Rectangle { @@ -21,16 +21,6 @@ Page { color: "#1f777c" radius: 6 border.width: 0 - - DropShadow { - anchors.fill: rectangle1 - horizontalOffset: 0 - verticalOffset: 8 - radius: 12.0 - samples: 25 - color: "#80000000" - source: rectangle1 - } } Rectangle { diff --git a/classmoor.pro b/classmoor.pro index 0cc47fe..40f6773 100644 --- a/classmoor.pro +++ b/classmoor.pro @@ -7,14 +7,14 @@ CONFIG += c++11 # depend on your compiler). Refer to the documentation for the # deprecated API to know how to port your code away from it. DEFINES += QT_DEPRECATED_WARNINGS -QML_IMPORT_PATH += /opt/Qt5.8.0/5.8/gcc_64/qml/QtGraphicalEffects +#QML_IMPORT_PATH += /opt/Qt5.8.0/5.8/gcc_64/qml/QtGraphicalEffects # You can also make your code fail to compile if it uses deprecated APIs. # In order to do so, uncomment the following line. # You can also select to disable deprecated APIs only up to a certain version of Qt. #DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0x060000 # disables all the APIs deprecated before Qt 6.0.0 INCLUDEPATH += /usr/local/include -LIBS += -L/usr/local/lib64 -laws-cpp-sdk-core -laws-cpp-sdk-s3 +LIBS += -L/usr/local/lib -laws-cpp-sdk-core -laws-cpp-sdk-s3 SOURCES += \ main.cpp @@ -37,3 +37,7 @@ else: unix:!android: target.path = /opt/$${TARGET}/bin #INCLUDEPATH += $$PWD/../../../usr/local/include/aws #DEPENDPATH += $$PWD/../../../usr/local/include/aws + +DISTFILES += \ + .gitignore \ + readme.md diff --git a/classmoor.pro.user b/classmoor.pro.user index e0339ce..00f8773 100644 --- a/classmoor.pro.user +++ b/classmoor.pro.user @@ -1,10 +1,10 @@ - + EnvironmentId - {b3545020-debd-4c69-8e71-390edbc7f8f2} + {026e9c65-3292-4356-a33b-9413d660f401} ProjectExplorer.Project.ActiveTarget @@ -72,17 +72,17 @@ ProjectExplorer.Project.Target.0 - Desktop Qt 5.14.2 GCC 64bit - Desktop Qt 5.14.2 GCC 64bit - qt.qt5.5142.gcc_64_kit + Desktop Qt 5.13.0 clang 64bit + Desktop Qt 5.13.0 clang 64bit + qt.qt5.5130.clang_64_kit 0 0 0 true 0 - /home/andrewpaulino/build-classmoor-Desktop_Qt_5_14_2_GCC_64bit-Debug - /home/andrewpaulino/build-classmoor-Desktop_Qt_5_14_2_GCC_64bit-Debug + /Users/andrewpaulino/Desktop/classmoor/build-classmoor-Desktop_Qt_5_13_0_clang_64bit-Debug + /Users/andrewpaulino/Desktop/classmoor/build-classmoor-Desktop_Qt_5_13_0_clang_64bit-Debug true @@ -132,8 +132,8 @@ true 2 - /home/andrewpaulino/build-classmoor-Desktop_Qt_5_14_2_GCC_64bit-Release - /home/andrewpaulino/build-classmoor-Desktop_Qt_5_14_2_GCC_64bit-Release + /Users/andrewpaulino/Desktop/classmoor/build-classmoor-Desktop_Qt_5_13_0_clang_64bit-Release + /Users/andrewpaulino/Desktop/classmoor/build-classmoor-Desktop_Qt_5_13_0_clang_64bit-Release true @@ -183,8 +183,8 @@ true 0 - /home/andrewpaulino/build-classmoor-Desktop_Qt_5_14_2_GCC_64bit-Profile - /home/andrewpaulino/build-classmoor-Desktop_Qt_5_14_2_GCC_64bit-Profile + /Users/andrewpaulino/Desktop/classmoor/build-classmoor-Desktop_Qt_5_13_0_clang_64bit-Profile + /Users/andrewpaulino/Desktop/classmoor/build-classmoor-Desktop_Qt_5_13_0_clang_64bit-Profile true @@ -306,19 +306,20 @@ 2 - Qt4ProjectManager.Qt4RunConfiguration:/home/andrewpaulino/classmoor/classmoor.pro - /home/andrewpaulino/classmoor/classmoor.pro + Qt4ProjectManager.Qt4RunConfiguration:/Users/andrewpaulino/Desktop/classmoor/Classmoor/classmoor.pro + /Users/andrewpaulino/Desktop/classmoor/Classmoor/classmoor.pro false false true - true + false + false false false true - /home/andrewpaulino/build-classmoor-Desktop_Qt_5_14_2_GCC_64bit-Debug + /Users/andrewpaulino/Desktop/classmoor/build-classmoor-Desktop_Qt_5_13_0_clang_64bit-Debug/classmoor.app/Contents/MacOS 1 diff --git a/main.cpp b/main.cpp index e2cc28b..948aa4d 100644 --- a/main.cpp +++ b/main.cpp @@ -1,8 +1,22 @@ +#include #include #include -#include +//#include + int main(int argc, char *argv[]) { + + + //AWS SDK test +// Aws::SDKOptions options; +// Aws::InitAPI(options); +// Aws::String test; + +// test = "AWS SDK Connected"; + +// std::cout << test << std::endl; + //END TEST + QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling); QGuiApplication app(argc, argv); @@ -17,4 +31,5 @@ int main(int argc, char *argv[]) engine.load(url); return app.exec(); +// Aws::ShutdownAPI(options); } diff --git a/main.qml b/main.qml index 8876f08..a004bd5 100644 --- a/main.qml +++ b/main.qml @@ -4,9 +4,9 @@ import QtQuick.Controls 2.5 ApplicationWindow { id: window visible: true - width: 1920 + width: 1000 color: "#F5F5F5" - height: 1080 + height: 920 title: qsTr("Stack") header: ToolBar { diff --git a/readme.md b/readme.md new file mode 100644 index 0000000..dfa1f9e --- /dev/null +++ b/readme.md @@ -0,0 +1,31 @@ +# Classmoor Build Directions + +## Mac OS/Linux +### Requirements: +* QT 4.12^ +* C++ Compiler (QMake) +* [AWS-cpp-sdk]([https://github.com/aws/aws-sdk-cpp](https://github.com/aws/aws-sdk-cpp)) +### Prerequisites +In the .pro there is a line +`QML_IMPORT_PATH =/opt/Qt5.14.2/gcc_64/qml/QtGraphicalEffects/` +Please use the correct file path or just comment it out. +### Steps To build +1. Clone the AWS SDK repo and follow the directions to build. + +2. I recommend you put all classmoor dependencies in one root folder and add the sdk there in two folders; the source folders and the built CMake files. + +3. Create a folder called `aws-build` and run this command `cmake -DBUILD_ONLY="s3;dynamodb;sns" ../aws-sdk-cpp/` If following the way we built our file system it should start running the cmake process. +4. After, we will install the dependencies to our local user include file. by running this + 1. `make` + 2. `sudo make install` +***This will take a while too, we are basically compiling all the sdk's we need*** +5. If linked successfully, you can now run the program in QT, by opening the pro file with QT. You should see `AWS SDK connected` in your console as that means it is working. Each .pro file will be different since the OS will have varying different installation paths. +#### Issues +* I noticed when running Qt you might get this error [here](https://stackoverflow.com/questions/35509731/dyld-symbol-not-found-cg-jpeg-resync-to-restart) + +#### Run Without AWS +Comment out Line 16 and 17 in the .pro file +``` +INCLUDEPATH += /usr/local/include +LIBS += -L/usr/local/lib -laws-cpp-sdk-core -laws-cpp-sdk-s3 +```