mitchcurtis / slate

Pixel Art Editor
GNU General Public License v3.0
1.07k stars 103 forks source link

Add CMakeLists #117

Closed wow2006 closed 5 years ago

wow2006 commented 5 years ago

I just add CMakefile to lib,app. I am still having a problem with import ui. I just make this pull request so anyone with qml import part knowledge please help.

mitchcurtis commented 5 years ago

What's the error you're getting?

wow2006 commented 5 years ago

I did not include QML path to cmake

the error is:

QQmlApplicationEngine failed to load component
qrc:/qml/main.qml:30 "ui": no such directory
mitchcurtis commented 5 years ago

Just a guess, but if you're introducing a qml.qrc file for the CMake build, you should probably add all of the QML files:

https://github.com/mitchcurtis/slate/pull/117/files#diff-2caf519a0386c2f35d7cac9733d7a0ba

See https://github.com/mitchcurtis/slate/blob/master/app/qml/qml.qbs for the full list.

wow2006 commented 5 years ago

@mitchcurtis Thanks that help alot. Finally how to generate vcs-repo-state.h header I can not find rule to generate it? Chould you help me with it?

mitchcurtis commented 5 years ago

@mitchcurtis Thanks that help alot.

No worries!

Finally how to generate vcs-repo-state.h header I can not find rule to generate it? Chould you help me with it?

That's something that Qbs generates, so I see two options:

Which one would you prefer?

wow2006 commented 5 years ago

@mitchcurtis That works like a charm. I just generate the header using config.

mitchcurtis commented 5 years ago

Great! I will test these patches out soon. :)

mitchcurtis commented 5 years ago

The app builds and runs without problems, which is good!

A couple of issues though:

I'm happy to merge this as an "experimental" option for building Slate though.

Thanks for the contribution!