porting: Linux to Freebsd

Matthias Andree matthias.andree at gmx.de
Mon Jun 22 22:36:04 UTC 2009


Am 08.06.2009, 21:15 Uhr, schrieb Peter Jeremy  
<peterjeremy at optushome.com.au>:

> On 2009-Jun-08 11:33:27 -0400, Robert Huff <roberthuff at rcn.com> wrote:
>> Alexander Leidinger writes:
>>>  > 	Right: I re-ran under bash, and got the same problems.
>>>  > 	Looking at configure.ac, I see:
>>>  >
>>>  > AC_PATH_PROG(YACC,byacc,no)
>>>  > if test "x$YACC" == "xno"
>>>
>>>  This should be a "=", not a "==".
>>
>> 	Same result.
>>
>>>  > 	Relevant bit is:
>>>  >
>>>  > for ac_remove_CFLAG in "-O1" "-O2" "-O3" ; do
>>>  > 	CFLAGS=${CFLAGS//${ac_remove_CFLAG}/}
>>>  > 	CPPFLAGS=${CPPFLAGS//${ac_remove_CFLAG}/}
>>>  > 	CXXFLAGS=${CXXFLAGS//${ac_remove_CFLAG}/}
>>>  > done
>>>
>>>  Quick try:
>>>  CFLAGS=`echo $CFLAGS | sed -e 's:-O[123]::g'`
>>
>> 	No change here either.
>
> Obvious question but if you edited configure.ac, you did remember to
> rerun autoconf afterwards didn't you?  Can you post the configure
> script?
>
> Note that your problems with configure do not surprise me.  Despite
> claims otherwise, it appears to have been designed (using the word
> very loosely) as a tool to impede application portability.

I beg to differ on "impede". It's a tool, as you're writing, and as such,  
it can only be as powerful as its operator. Programmers using non-portable  
shell code are subverting the tool, not using it.

Operating systems also have their share there. For instance, all too many  
FreeBSD system header files are _not_ standalone, but have undocumented  
dependencies on other headers, even if that runs counter to IEEE Std.  
1003.1 (aka Single Unix Specification or POSIX). While such bugs are  
easily fixed, it's often hard for the learning porter to do...

So rather than spraying non-helpful comments over the thread (if you have  
issues with autoconf, file bug reports or contribute to make autoconf - or  
another tool you deem more suitable - better).

-- 
Matthias Andree


More information about the freebsd-ports mailing list