Date: Mon, 29 Feb 2016 22:25:29 -0500 From: Chris Inacio <nacho319@gmail.com> To: Chris H <bsd-lists@bsdforge.com> Cc: freebsd-ports@freebsd.org Subject: Re: library porting question - optional python bindings Message-ID: <CAG_PEez9i_s1aRfMTBqwOK2cPgGGABHxtgjAuaYDY6AR5WyzVg@mail.gmail.com> In-Reply-To: <7e308f12baf042f5972dfa7855774047@ultimatedns.net> References: <CAG_PEeyLw_VS=pL-3J6NZycx9-b_qo9GRaxoeV34i5gq_Cx=bg@mail.gmail.com> <82709c7e29849f965aef1319ce0a9093@ultimatedns.net> <7e308f12baf042f5972dfa7855774047@ultimatedns.net>
next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Feb 29, 2016 at 10:04 PM, Chris H <bsd-lists@bsdforge.com> wrote: > On Mon, 29 Feb 2016 18:53:37 -0800 "Chris H" <bsd-lists@bsdforge.com> > wrote > > > On Mon, 29 Feb 2016 21:38:40 -0500 Chris Inacio <nacho319@gmail.com> > wrote > > > > > All, > > > > > > I'm trying to build a port definition for a library/application that > can > > > optionally include Python bindings. The library/application generally > > > depends on other C libraries to exist (ZMQ v3, Protobufs-C) and if you > > > enable Python support, then you need a Python interpreter plus > > > Python-protobufs & python zmq. > > > > > > Putting an OPTION of Python in the port file is easy. Including the > > > optional Python dependencies (and presumably targets - but I'm not > that far > > > yet) seems to be a lot more complicated. I haven't found anything that > > > would tell me how I'm supposed to do that. I have found that I'm > supposed > > > to add pyXX prefixes to the python targets. > > > > > > Does anyone know of a similar application/library that I can go look > at? > > > Is there any documentation on how to solve this? > > Sure. You've read the Porters Handbook; > > https://www.freebsd.org/doc/en_US.ISO8859-1/books/porters-handbook/ > > Right? :) > I have read through the handbook - although probably not linearly. I have read the section on Python in ports. But the combination of what I'm trying to do - Python as an option - can do that, but also including extra python library dependencies as an option doesn't seem straight forward. > > Other than that, there's a myriad of ports in the ports tree. > > Almost all of which have (OPTIONAL) requirements. Your keyword > > here is; depends. :) > If I understand you correctly; maybe something like; > > if ${PORT_OPTIONS:MMYOPTION} > RUN_DEPENDS= ${LOCALBASE}/lib/somelib:${PORTSDIR}/lang/python... > endif > > Same is true for BUILD_DEPENDS > > I was hoping there was some newer / less documented <OPTION_NAME>_PYPACKAGE_DEPENDS variable that would save the day here. Or port that someone had worked on and effectively created some Makefile foo that does the equivalent of my made up variable/macro name. > > --Chris > > > > > > thanks, > > > Chris Inacio > > > > > > > _______________________________________________ > freebsd-ports@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-ports > To unsubscribe, send any mail to "freebsd-ports-unsubscribe@freebsd.org" >
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAG_PEez9i_s1aRfMTBqwOK2cPgGGABHxtgjAuaYDY6AR5WyzVg>