tech-pkg archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: KDE Frameworks 5 build problem



On Sun, 31 Jan 2016 08:18:56 Roland Illig wrote:
> > /src/work/pkgsrc/wip/kcoreaddons/work.x86_64/kcoreaddons-5.18.0/src/lib/ca
> > ching/kshareddatacache_p.h: In function 'SharedLockId
> > findBestSharedLock()':
> > /src/work/pkgsrc/wip/kcoreaddons/work.x86_64/kcoreaddons-5.18.0/src/lib/ca
> > ching/kshareddatacache_p.h:399:48: error: expected primary-expression
> > before '(' token
> > 
> >              tempLock = QSharedPointer<KSDCLock>(new
> > 
> > semaphoreTimedLock(tempSemaphore));
> 
> Did you have a look at what the preprocessor makes out of this? I agree
> that this sounds weird, as all the identifiers don't look like
> candidates for macros, but who knows?

On second look its easier than I thought - was concentrating on the wrong bit.

The class semaphoreTimedLock is never defined on NetBSD because its wrapped in 
a

#if ... && defined(KSDC_TIMEOUTS_SUPPORTED)

and that in turn is defined 

#if defined(_POSIX_TIMEOUTS) && ((_POSIX_TIMEOUTS == 0) || (_POSIX_TIMEOUTS >= 
200112L))
#define KSDC_TIMEOUTS_SUPPORTED 1
#endif


and _POSIX_TIMEOUTS is undef on NetBSD.

Looks like the use it trips over should also be wrapped by 
KSDC_TIMEOUTS_SUPPORTED.


While looking at this I see some other functionality not being enabled because 
of _POSIX options:

#if defined(_POSIX_MAPPED_FILES) && ((_POSIX_MAPPED_FILES == 0) || 
(_POSIX_MAPPED_FILES >= 200112L))
#define KSDC_MAPPED_FILES_SUPPORTED 1
#endif

   _POSIX_MAPPED_FILES  is set to 1 on NetBSD



#if defined(_POSIX_SYNCHRONIZED_IO) && ((_POSIX_SYNCHRONIZED_IO == 0) || 
(_POSIX_SYNCHRONIZED_IO >= 200112L))
#define KSDC_SYNCHRONIZED_IO_SUPPORTED 1
#endif


   _POSIX_SYNCHRONIZED_IO  is set to 1 on NetBSD


// posix_fallocate is used to ensure that the file used for the cache is
// actually fully committed to disk before attempting to use the file.
#if defined(_POSIX_ADVISORY_INFO) && ((_POSIX_ADVISORY_INFO == 0) || 
(_POSIX_ADVISORY_INFO >= 200112L))
#define KSDC_POSIX_FALLOCATE_SUPPORTED 1
#endif


   _POSIX_ADVISORY_INFO undefined but posix_fallocate() exists.


cheers
mark





Home | Main Index | Thread Index | Old Index