[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Compiling on OpenBSD
On 03/28/11 16:31, James Turner wrote:
> On Mon, Mar 28, 2011 at 04:27:16PM -0700, Colin Percival wrote:
>> On 03/28/11 16:16, James Turner wrote:
>>> Attached is a diff of the changes I needed to make in order to get
>>> kivaloo to compile on OpenBSD and install in my homedir. It would seem
>>> OpenBSD doesn't need -lrt.
>>
>> Does OpenBSD object to it, or is -lrt merely unnecessary? FreeBSD doesn't
>> need it either, but POSIX and Linux require it, and it should be harmless.
>
> Yes, it dies with:
>
> /usr/bin/ld: cannot find -lrt
> collect2: ld returned 1 exit status
> *** Error code 1
Hmm, that's a bug in OpenBSD then.
"The c99 utility shall recognize the following -l options for standard libraries:
...
-l rt This option shall make available... an implementation may search
this library in the absence of this option.
..."
OpenBSD is free to put the relevant functions into libc, but they should
either provide an empty librt or teach their compiler to ignore -l rt.
>>> Also I had to remove $$$$_ from the ends of the tmp filenames since on
>>> $$$$_ would be different for each step, meaning the binary saved had a
>>> different number at the end then what was then used to copy it over.
>>>
>>> Also, I switched the chmod and strip command around since I got permission
>>> denied errors when strip ran. The current order may be fine when ran as
>>> root but installing as a normal user in my homedir the binaries had to
>>> have write permission in order for me to strip them.
I just uploaded version 1.0.1 with these fixed.
--
Colin Percival
Security Officer, FreeBSD | freebsd.org | The power to serve
Founder / author, Tarsnap | tarsnap.com | Online backups for the truly paranoid