Skip to content

Commit

Permalink
Several fixes for Windows
Browse files Browse the repository at this point in the history
- Windows Qt needs OpenSSL linked in
- MSVC has bugs that are triggered by QStringLiteral
  • Loading branch information
thirtythreeforty committed Jan 3, 2015
1 parent 4f342ac commit 530f4a2
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
8 changes: 4 additions & 4 deletions GitHubUpdateChecker.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,9 @@ void GitHubUpdateChecker::onRequestFinished(QNetworkReply* reply)
// and that has a valid semantic version string in the name.
for(const auto& val: array) {
QJsonObject topRelease = val.toObject();
QJsonValue name = topRelease[QStringLiteral("name")];
QJsonValue html_url = topRelease[QStringLiteral("html_url")];
QJsonValue prerelease = topRelease[QStringLiteral("prerelease")];
QJsonValue name = topRelease["name"];
QJsonValue html_url = topRelease["html_url"];
QJsonValue prerelease = topRelease["prerelease"];

if(name.type() != QJsonValue::String ||
html_url.type() != QJsonValue::String ||
Expand Down Expand Up @@ -105,7 +105,7 @@ void GitHubUpdateChecker::onRequestFinished(QNetworkReply* reply)

bool GitHubUpdateChecker::parseSemanticVersionString(const QString &str, unsigned int &major, unsigned int &minor, unsigned int &patch) const
{
QRegularExpression re(QStringLiteral(R"(v?(\d+)\.(\d+)(?:\.(\d+))?)"));
QRegularExpression re(R"(v?(\d+)\.(\d+)(?:\.(\d+))?)");
QRegularExpressionMatch match = re.match(str);
if(match.hasMatch()) {
major = match.captured(1).toUInt();
Expand Down
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ BullyCPP depends on Qt 5.2 or later. Qt is cross-platform, so BullyCPP should w

If you have Qt Creator installed, you can simply import the project and click Build.
This is the recommended way to build on Windows.
(Note that you will have to compile and use a static version of Qt if you wish to redistribute the executable to Windows users who do not have Qt installed.)
(Note that you will have to compile and use a static version of Qt if you wish to redistribute the executable to users who do not have Qt installed.)

On Linux and Mac OS X, you can build with Qt Creator as described above, or you can build manually.
Begin by cloning the repository:
Expand All @@ -37,6 +37,11 @@ Now build (you can pass `-j` if you have a multicore processor):

The executable `bullycpp` will be generated.

Note: If you want to redistribute the resulting application, you will need to use a statically linked Qt, which you must compile yourself.
The configure line used to build the provided Windows precompiled versions is

configure -opensource -confirm-license -static -release -openssl-linked -skip qtwebkit -platform win32-msvc2013 -nomake examples -nomake tests -no-style-fusion -mp -I C:\openssl\include -L C:\openssl\out32 -L "C:\Program Files (x86)\Microsoft SDKs\Windows\v7.1A\Lib"

Usage
-----
BullyCPP has both a command-line and a GUI mode.
Expand Down

0 comments on commit 530f4a2

Please sign in to comment.