Date: Thu, 20 Sep 2018 19:35:39 +1000 From: Kubilay Kocak <koobs@FreeBSD.org> To: Axel Rau <Axel.Rau@Chaos1.DE> Cc: python@FreeBSD.org, =?UTF-8?Q?Michael_Str=c3=b6der?= <michael@stroeder.com>, Palle Girgensohn <girgen@FreeBSD.org> Subject: Re: Why are devel/py-setuptools missing -I${LOCALBASE}/include ? Message-ID: <3f44c803-df9c-5683-3aa5-7bec1ba721a1@FreeBSD.org> In-Reply-To: <9D14E231-BFD7-4442-9418-3878E70A9C71@Chaos1.DE> References: <9D14E231-BFD7-4442-9418-3878E70A9C71@Chaos1.DE>
next in thread | previous in thread | raw e-mail | index | archive | help
On 20/09/2018 6:55 pm, Axel Rau wrote: > Hi all, Hi Axel, > while doing a > pip install ldap0 > I get Standard warning first up: use of pip install as root (without --user) to install third party packages directly into the system site-packages environment is completely unsupported, and *will* break the python environment if mixing with ports/packages. The pkg-message for devel/py-pip contains this warning too. > - - - > In file included from _libldap0/LDAPObject.c:8: > _libldap0/errors.h:7:10: fatal error: 'lber.h' file not found > #include "lber.h" > ^~~~~~~~ > 1 error generated. > error: command ‚clang' failed with exit status 1 > - - - > > Shouldn’t setuptools take care of this? No. `pythonX.Y-config` on the other hand (provided by each lang/python?? port) can provide the *FLAGS that the python environment was built in/for, *if* a consumer chooses to use it. However, this is most often used only by non-Python-library softwares that want to depend on the python shared library. The options from here, depending on the specific package are: - Try CFLAGS/LDFLAGS to pass the -I/-L paths. - Try using the --include-dirs, --libraries and --library-dirs (-L) arguments to the setuptools build_ext command (see pythonX.Y setup.py build_ext --help for more) Or, just use the net/py-ldap0 port [1], which already does the right thing (it appears the ldap0 package uses a non-standard INCLUDE variable to pass things into it) Hope that helps. If you have questions and need any more help, we're always available on #freebsd-python on freenode IRC if you need us. [1] https://www.freshports.org/net/py-ldap0/ > Thanks, Axel > --- > PGP-Key:29E99DD6 ☀ computing @ chaos claudius >
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3f44c803-df9c-5683-3aa5-7bec1ba721a1>