Makefile compatible with OS X

The Makefile now detects whether OS X (Darwin) is being used, and changes the
extension suffix accordingly from .so to .dylib. On current Apple hardware,
i386 architecture is no longer applicable, so it is removed from the build.

Note: two tests fail on OS X: testSave and testResize. Output:

```
.E...............[pcl::PLYReader] /var/folders/bm/j5txvfpx3qj4x7k5dc6hz9_r0000gn/T/tmpkzT9mLpcl-test/foo.ply:2: parse error
[pcl::PLYReader::read] problem parsing header!
[pcl::PLYReader::read] problem parsing header!
E...........
======================================================================
ERROR: testResize (test.TestExceptions)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Users/joris/Developer/project-patty/python-pcl/tests/test.py", line 230, in testResize
    self.assertRaises(MemoryError, self.p.resize, -1)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/unittest/case.py", line 475, in assertRaises
    callableObj(*args, **kwargs)
  File "pcl/_pcl.pyx", line 231, in pcl._pcl.PointCloud.resize (pcl/_pcl.cpp:4936)
    self.thisptr().resize(x)
RuntimeError: vector

======================================================================
ERROR: testSave (test.TestSave)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Users/joris/Developer/project-patty/python-pcl/tests/test.py", line 183, in testSave
    p = pcl.load(d)
  File "/Users/joris/Developer/project-patty/python-pcl/pcl/__init__.py", line 22, in load
    % (path, format))
IOError: error while loading pointcloud from '/var/folders/bm/j5txvfpx3qj4x7k5dc6hz9_r0000gn/T/tmpkzT9mLpcl-test/foo.ply' (format='ply')
```
You’re very right to be skeptical by the way… It seems that setup.py generates .so files regardless of the OS. I’ll fix it now.

Op 16 okt. 2014, om 13:36 heeft Lars Buitinck <notifications@github.com> het volgende geschreven:

> In Makefile:
> 
> >  
> > -pcl/_pcl.so: pcl/_pcl.pxd pcl/_pcl.pyx setup.py pcl/pcl_defs.pxd \
> > +ifeq "$(OS)" ""
> > +	OS = $(shell uname -s)
> > +endif
> > +
> > +ifeq "$(OS)" "Darwin"
> > +	PLUGIN_EXT = .dylib
> > +	export ARCHFLAGS= -arch x86_64
> 
> What does this do?
> 
> —
> Reply to this email directly or view it on GitHub.
>