Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Fix multiarch support on Debian/Ubuntu #4

Merged
merged 1 commit into from over 1 year ago

2 participants

Axel Haustant Mathieu Le Marec - Pasquet
Axel Haustant

Allow installation from pip/easy_install on multiarch enabled distrib.

See https://wiki.ubuntu.com/MultiarchSpec

I think there some fix to apply to mapnik-utils too.

Backporting to 2.0.x to have it in pypi would be very nice!

Mathieu Le Marec - Pasquet kiorky merged commit b5d1a5b into from August 04, 2012
Mathieu Le Marec - Pasquet kiorky closed this August 04, 2012
Mathieu Le Marec - Pasquet
Collaborator

Thx !

Mathieu Le Marec - Pasquet
Collaborator

I can also make you co maintainer of pypi, just give me your id.
Just use zest.releaser's fullrelease (see buildout) to make a proper release.

Axel Haustant

Glad to help!!
Here's my pypi ID: noirbizarre (same as github)

I don't much about zest-releaser but it seems interesting.
I going learn about it right now!

Thanks!

Mathieu Le Marec - Pasquet
Collaborator

added to pypi as maintainer

basically:

  • have the buildout running
  • easy_install -U setuptools_git (you need it both in your buildout scripts & in your python because zest.releaser calls directly python under the hood)
  • then when you release, commits what it needs to, but dont increment any version stuff nor update the date in CHANGES because it is handled by zest.releaser
  • finally use the magical bin/fullrelease, answer the questions are you are done.
    • tag creation, version increment, date update, pypi & github checkins will be handled for you
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Showing 1 unique commit by 1 author.

Aug 03, 2012
Axel Haustant Fix multiarch support for sigc++config.h 517a50b
This page is out of date. Refresh to see the latest.

Showing 1 changed file with 19 additions and 2 deletions. Show diff stats Hide diff stats

  1. 21  src/mapnik/utils.py
21  src/mapnik/utils.py
@@ -2,7 +2,7 @@
2 2
 
3 3
 import re
4 4
 import os
5  
-from subprocess import Popen, PIPE
  5
+from subprocess import Popen, PIPE, check_output
6 6
 from ctypes import CDLL
7 7
 
8 8
 def read(rnames):
@@ -37,7 +37,7 @@ def get_config_output(exe, args):
37 37
     if ret.wait() != 0:
38 38
         raise Exception(
39 39
             '%s error: %s\n%s' % (
40  
-                cmd, 
  40
+                cmd,
41 41
                 ret.stdout.read(),
42 42
                 ret.stderr.read(),
43 43
             )
@@ -91,6 +91,21 @@ def get_boost_flags():
91 91
                   raise Exception('Cant find boost_python lib!')
92 92
     return {'includes': includes, 'libraries': libraries}
93 93
 
  94
+
  95
+def add_multiarch_paths(flags):
  96
+    '''
  97
+    Find multiarchs specifics paths for Debian/Ubuntu.
  98
+    See https://wiki.ubuntu.com/MultiarchSpec
  99
+    Could be fixed in Scons and/or mapnik-utils
  100
+    '''
  101
+    try:
  102
+        arch = check_output(['dpkg-architecture', '-qDEB_HOST_MULTIARCH'])
  103
+        arch = arch[:-1] if arch.endswith('\n') else arch
  104
+        flags['includes'].append('-I/usr/lib/%s/sigc++-2.0/include' % arch)
  105
+    except:
  106
+        pass
  107
+
  108
+
94 109
 def get_compilation_flags():
95 110
     compilation_flags = {
96 111
         'includes': [],
@@ -104,6 +119,8 @@ def get_compilation_flags():
104 119
     compilation_flags['libraries'].extend(bf['libraries'])
105 120
     compilation_flags['includes'].extend(mapnik_config(["--cflags"]).split())
106 121
     compilation_flags['extra_link_args'].extend(mapnik_config(["--libs"]).split())
  122
+    if sys.platform.startswith("linux"):
  123
+        add_multiarch_paths(compilation_flags)
107 124
     return compilation_flags
108 125
 
109 126
 
Commit_comment_tip

Tip: You can add notes to lines in a file. Hover to the left of a line to make a note

Something went wrong with that request. Please try again.