mirror of
https://git.freebsd.org/ports.git
synced 2025-06-08 06:10:30 -04:00
Release notes at <https://github.com/igraph/python-igraph/releases/tag/0.8.3> - Update WWW: URL - Set LIB_DEPENDS for math/igraph - Depends on py-cairocffi - Let it find an image viewer for FreeBSD Without that, you cannot run code like: >>> import igraph as ig >>> g = ig.Graph.Famous("petersen") >>> ig.plot(g) - Add a plist PR: 252381 Submitted by: /me Approved by: lwhsu@ (maintainer)
21 lines
944 B
Python
21 lines
944 B
Python
--- src/igraph/configuration.py.orig 2020-10-08 10:13:28 UTC
|
|
+++ src/igraph/configuration.py
|
|
@@ -56,6 +56,18 @@ def get_platform_image_viewer():
|
|
if os.path.isfile(full_path):
|
|
return full_path
|
|
return ""
|
|
+ elif plat == "FreeBSD":
|
|
+ # FreeBSD also has a whole lot of choices, try to find one
|
|
+ choices = ["eog", "gthumb", "geeqie", "display",
|
|
+ "gpicview", "gwenview", "qiv", "gimv", "ristretto",
|
|
+ "geeqie", "eom"]
|
|
+ paths = ["%%LOCALBASE%%/bin"]
|
|
+ for path in paths:
|
|
+ for choice in choices:
|
|
+ full_path = os.path.join(path, choice)
|
|
+ if os.path.isfile(full_path):
|
|
+ return full_path
|
|
+ return ""
|
|
elif plat == "Windows" or plat == "Microsoft": # Thanks to Dale Hunscher
|
|
# Use the built-in Windows image viewer, if available
|
|
return "start"
|