antimony: update to 0.9.0c and fix build

Signed-off-by: Andreas Müller <schnitzeltony@googlemail.com>
This commit is contained in:
Andreas Müller
2016-03-07 00:21:13 +01:00
parent 3116822310
commit 47e36cac17
6 changed files with 191 additions and 52 deletions

View File

@@ -1,6 +1,6 @@
SUMMARY = "Antimony is a computer-aided design (CAD) tool from a parallel universe"
LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://README.md;beginline=23;endline=48;md5=42ef7697397331e7aa0d2251830f3df3"
LIC_FILES_CHKSUM = "file://README.md;beginline=23;endline=48;md5=9b0a0f10af772bdc7ab3e80c53fc287d"
inherit qmake5 python3native
@@ -11,11 +11,11 @@ SRC_URI = " \
file://0001-remove-paths-from-python3-config.patch \
file://0002-hardcode-boost_python3-library-detection-wont-t-work.patch \
file://0003-align-binary-installation-folders.patch \
file://0004-do-not-hard-link-to-python-version-we-don-t-have.patch \
file://0005-Change-isinf-to-std-isinf.patch \
"
SRC_URI[md5sum] = "22e632ffb9351ac9deb6db6be933c433"
SRC_URI[sha256sum] = "24d26c513e3d7abfe89a14cf8c2fc4dc0ff6e35581efdfa4721946deb353804c"
QMAKE_PROFILES = "${S}/qt/${BPN}.pro"
SRC_URI[md5sum] = "2df03f0a8b6d7db21c24dcf20142297e"
SRC_URI[sha256sum] = "78f22836ede812fa5bb283779ea6ada8568caf76fa4ab0473ee00d2d544b0aa4"
CXXFLAGS += "-I${STAGING_INCDIR}/${PYTHON_DIR}m"

View File

@@ -1,35 +1,23 @@
From b9bb2efb85657a74c075186764659a4252111de5 Mon Sep 17 00:00:00 2001
From a5cb20ec541a8e828859a25720f068bf32e6480d Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@googlemail.com>
Date: Tue, 21 Jul 2015 09:47:55 +0200
Subject: [PATCH] remove paths from python3-config
Date: Sat, 5 Mar 2016 22:20:41 +0100
Subject: [PATCH 1/3] remove paths from python3-config
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Upstream-Status: Inappropriate [configuration]
Signed-off-by: Andreas Müller <schnitzeltony@googlemail.com>
---
qt/fab.pri | 2 +-
qt/shared.pri | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
qt/python.pri | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/qt/fab.pri b/qt/fab.pri
index a54813b..b500536 100644
--- a/qt/fab.pri
+++ b/qt/fab.pri
@@ -54,7 +54,7 @@ DEFINES += '_STATIC_= '
linux {
QMAKE_CFLAGS += -std=gnu99
- QMAKE_CXXFLAGS += $$system(/usr/bin/python3-config --includes)
+ QMAKE_CXXFLAGS += $$system(python3-config --includes)
LIBS += -lpng
}
diff --git a/qt/shared.pri b/qt/shared.pri
index e7d0e3a..5ee0b5d 100644
--- a/qt/shared.pri
+++ b/qt/shared.pri
@@ -39,8 +39,8 @@ macx {
diff --git a/qt/python.pri b/qt/python.pri
index 2504c01..550383c 100644
--- a/qt/python.pri
+++ b/qt/python.pri
@@ -14,8 +14,8 @@ macx {
}
linux {
@@ -41,5 +29,5 @@ index e7d0e3a..5ee0b5d 100644
# Even though this is in QMAKE_LFLAGS, the linker is picky about
# library ordering (so it needs to be here too).
--
1.9.3
2.5.0

View File

@@ -1,21 +1,23 @@
From dc197a74f73664a08f9747f63df4bbd0dc466d2d Mon Sep 17 00:00:00 2001
From e3b4a08c4e8b4e59d8f2fb79df8fab7883ce9b35 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@googlemail.com>
Date: Wed, 22 Jul 2015 00:14:09 +0200
Subject: [PATCH] hardcode boost_python3 library - detection wont't work
Date: Sat, 5 Mar 2016 22:24:15 +0100
Subject: [PATCH 2/3] hardcode boost_python3 library - detection wont't work
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Upstream-Status: Inappropriate [configuration]
Signed-off-by: Andreas Müller <schnitzeltony@googlemail.com>
---
qt/shared.pri | 10 ++--------
qt/python.pri | 10 ++--------
1 file changed, 2 insertions(+), 8 deletions(-)
diff --git a/qt/shared.pri b/qt/shared.pri
index 5ee0b5d..b996eb2 100644
--- a/qt/shared.pri
+++ b/qt/shared.pri
@@ -63,14 +63,8 @@ linux {
diff --git a/qt/python.pri b/qt/python.pri
index 550383c..d51935a 100644
--- a/qt/python.pri
+++ b/qt/python.pri
@@ -38,14 +38,8 @@ linux {
error("Could not find ldconfig!")
}
@@ -33,5 +35,5 @@ index 5ee0b5d..b996eb2 100644
# If we couldn't find boost::python, exit with an error.
isEmpty(GOT_BOOST_PYTHON) {
--
1.9.3
2.5.0

View File

@@ -1,24 +1,26 @@
From 80a6a407f3e868be9203c98d38f5471141e2014c Mon Sep 17 00:00:00 2001
From 09db90cefb2d466e143ee655e3a10220d86fb88b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@googlemail.com>
Date: Wed, 22 Jul 2015 00:53:39 +0200
Subject: [PATCH] align binary installation folders
Date: Sat, 5 Mar 2016 22:28:58 +0100
Subject: [PATCH 3/3] align binary installation folders
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Upstream-Status: Inappropriate [configuration]
Signed-off-by: Andreas Müller <schnitzeltony@googlemail.com>
---
qt/antimony.pro | 6 +++---
app/app.pro | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/qt/antimony.pro b/qt/antimony.pro
index 9d586f4..9c423f8 100644
--- a/qt/antimony.pro
+++ b/qt/antimony.pro
@@ -125,11 +125,11 @@ macx {
}
diff --git a/app/app.pro b/app/app.pro
index 5559ab2..e425c55 100644
--- a/app/app.pro
+++ b/app/app.pro
@@ -39,11 +39,11 @@ linux {
# Rename file from "Antimony" to "antimony"
QMAKE_POST_LINK += $(MOVE) $$OUT_PWD/$${TARGET} $$OUT_PWD/$$lower($${TARGET})
linux {
- executable.path = /usr/local/bin
+ executable.path = /usr/bin
executable.files = antimony
@@ -31,5 +33,5 @@ index 9d586f4..9c423f8 100644
INSTALLS += executable nodes_folder fab_folder
}
--
1.9.3
2.5.0

View File

@@ -0,0 +1,33 @@
From f2e5c5cf4db97d328dc171d42360b8bb09125f4d Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@googlemail.com>
Date: Sun, 6 Mar 2016 22:40:18 +0100
Subject: [PATCH] do not hard link to python version we don't have
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Upstream-Status: Pending
Signed-off-by: Andreas Müller <schnitzeltony@googlemail.com>
---
qt/python.pri | 4 ----
1 file changed, 4 deletions(-)
diff --git a/qt/python.pri b/qt/python.pri
index d51935a..f28bb25 100644
--- a/qt/python.pri
+++ b/qt/python.pri
@@ -17,10 +17,6 @@ linux {
QMAKE_CXXFLAGS += $$system(python3-config --includes)
QMAKE_LFLAGS += $$system(python3-config --ldflags)
- # Even though this is in QMAKE_LFLAGS, the linker is picky about
- # library ordering (so it needs to be here too).
- LIBS += -lpython3.4m
-
# ldconfig is being used to find libboost_python, but it's in a different
# place in different distros (and is not in the default $PATH on Debian).
# First, check to see if it's on the default $PATH.
--
2.5.0

View File

@@ -0,0 +1,114 @@
From ec04dbca58d11f43304d32544d33b0276e3188c9 Mon Sep 17 00:00:00 2001
From: Stefano Probst <senden9@gmail.com>
Date: Thu, 3 Mar 2016 20:16:22 +0100
Subject: [PATCH] Change "isinf" to "std::isinf"
Upstream-Status: Submitted [1]
[1] https://github.com/mkeeter/antimony/pull/151
---
app/src/export/export_heightmap.cpp | 2 +-
app/src/graph/hooks/export.cpp | 10 +++++-----
app/src/render/render_task.cpp | 6 +++---
app/src/ui/dialogs/resolution_dialog.cpp | 2 +-
lib/fab/src/types/bounds.cpp | 8 ++++----
5 files changed, 14 insertions(+), 14 deletions(-)
diff --git a/app/src/export/export_heightmap.cpp b/app/src/export/export_heightmap.cpp
index f7e1c7c..13dca08 100644
--- a/app/src/export/export_heightmap.cpp
+++ b/app/src/export/export_heightmap.cpp
@@ -103,7 +103,7 @@ void ExportHeightmapTask::render()
.nk=1
};
- if (!isinf(bounds.zmin) && !isinf(bounds.zmax))
+ if (!std::isinf(bounds.zmin) && !std::isinf(bounds.zmax))
r.nk = uint32_t((bounds.zmax - bounds.zmin) * resolution);
build_arrays(
diff --git a/app/src/graph/hooks/export.cpp b/app/src/graph/hooks/export.cpp
index f09a3a5..3d4e76e 100644
--- a/app/src/graph/hooks/export.cpp
+++ b/app/src/graph/hooks/export.cpp
@@ -92,9 +92,9 @@ object ScriptExportHooks::stl(tuple args, dict kwargs)
bounds = get_bounds(kwargs);
// Sanity-check bounds
- if (isinf(bounds.xmin) || isinf(bounds.xmax) ||
- isinf(bounds.ymin) || isinf(bounds.ymax) ||
- isinf(bounds.zmin) || isinf(bounds.zmax))
+ if (std::isinf(bounds.xmin) || std::isinf(bounds.xmax) ||
+ std::isinf(bounds.ymin) || std::isinf(bounds.ymax) ||
+ std::isinf(bounds.zmin) || std::isinf(bounds.zmax))
{
throw AppHooks::Exception(
"Exporting mesh with invalid (infinite) bounds");
@@ -143,8 +143,8 @@ object ScriptExportHooks::heightmap(tuple args, dict kwargs)
bounds = get_bounds(kwargs);
// Sanity-check bounds
- if (isinf(bounds.xmin) || isinf(bounds.xmax) ||
- isinf(bounds.ymin) || isinf(bounds.ymax))
+ if (std::isinf(bounds.xmin) || std::isinf(bounds.xmax) ||
+ std::isinf(bounds.ymin) || std::isinf(bounds.ymax))
{
throw AppHooks::Exception(
"Exporting heightmap with invalid (infinite) bounds");
diff --git a/app/src/render/render_task.cpp b/app/src/render/render_task.cpp
index 299758d..d6f80a0 100644
--- a/app/src/render/render_task.cpp
+++ b/app/src/render/render_task.cpp
@@ -64,10 +64,10 @@ void RenderTask::render()
Q_ASSERT(get_shape.check());
Shape s = get_shape();
- if (!isinf(s.bounds.xmin) && !isinf(s.bounds.xmax) &&
- !isinf(s.bounds.xmin) && !isinf(s.bounds.xmax))
+ if (!std::isinf(s.bounds.xmin) && !std::isinf(s.bounds.xmax) &&
+ !std::isinf(s.bounds.xmin) && !std::isinf(s.bounds.xmax))
{
- if (isinf(s.bounds.zmin) || isinf(s.bounds.zmax))
+ if (std::isinf(s.bounds.zmin) || std::isinf(s.bounds.zmax))
render2d(s);
else
render3d(s);
diff --git a/app/src/ui/dialogs/resolution_dialog.cpp b/app/src/ui/dialogs/resolution_dialog.cpp
index 50e0970..9a91894 100644
--- a/app/src/ui/dialogs/resolution_dialog.cpp
+++ b/app/src/ui/dialogs/resolution_dialog.cpp
@@ -7,7 +7,7 @@
ResolutionDialog::ResolutionDialog(Bounds bounds, bool dimensions, bool has_units,
long max_voxels, QWidget* parent)
: QDialog(parent), bounds(bounds), ui(new Ui::ResolutionDialog),
- z_bounded(!isinf(bounds.zmax) && !isinf(bounds.zmin))
+ z_bounded(!std::isinf(bounds.zmax) && !std::isinf(bounds.zmin))
{
ui->setupUi(this);
diff --git a/lib/fab/src/types/bounds.cpp b/lib/fab/src/types/bounds.cpp
index e19541c..bf36443 100644
--- a/lib/fab/src/types/bounds.cpp
+++ b/lib/fab/src/types/bounds.cpp
@@ -81,13 +81,13 @@ Bounds Bounds::map(Transform t) const
bool Bounds::is_bounded_xy() const
{
- return !isinf(xmin) && !isinf(ymin) &&
- !isinf(xmax) && !isinf(ymax);
+ return !std::isinf(xmin) && !std::isinf(ymin) &&
+ !std::isinf(xmax) && !std::isinf(ymax);
}
bool Bounds::is_bounded_xyz() const
{
- return !isinf(xmin) && !isinf(ymin) && !isinf(zmin) &&
- !isinf(xmax) && !isinf(ymax) && !isinf(zmax);
+ return !std::isinf(xmin) && !std::isinf(ymin) && !std::isinf(zmin) &&
+ !std::isinf(xmax) && !std::isinf(ymax) && !std::isinf(zmax);
}
--
2.5.0