Date: Wed, 26 Apr 2017 11:01:37 -0600 From: Ian Lepore <ian@freebsd.org> To: Eric McCorkle <eric@metricspace.net>, "freebsd-hackers@freebsd.org" <freebsd-hackers@FreeBSD.org> Subject: Re: Generating sources during buildworld Message-ID: <1493226097.1195.1.camel@freebsd.org> In-Reply-To: <3f63e99c-9241-380d-2e3a-12ef6a5a2758@metricspace.net> References: <3f63e99c-9241-380d-2e3a-12ef6a5a2758@metricspace.net>
next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, 2017-04-26 at 11:40 -0400, Eric McCorkle wrote: > I'm looking for some help with the build system, specifically how to > generate sources for a library that will then be used to build the > library. > > Basically, I want to have a tool which collects public key > certificates, > then converts them into .c files which are used to build both loader > and > the kernel. > > Knowing how LLVM works, it seems that this is possible; however, I've > been unable to find documentation on how to write a makefile that > accomplishes this. Can someone point me to documentation or examples > on > how to do this? > > There's a program named bin2c in contrib/binutils, but nothing seems to use it. There is also firmware(9) and the code in sys/conf/kmod.mk to convert firmware blobs to loadable modules -- not exactly the problem you're solving, but maybe close enough to cobble some ideas from. Search for occurrances of FIRMWS in kmod.mk. -- Ian
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1493226097.1195.1.camel>