Bug 455383

Summary: Build fails on macOS
Product: [Frameworks and Libraries] libkgapi Reporter: Max Leiter <maxwell.leiter>
Component: GeneralAssignee: Daniel Vrátil <dvratil>
Status: RESOLVED FIXED    
Severity: normal    
Priority: NOR    
Version: GIT   
Target Milestone: ---   
Platform: Homebrew (macOS)   
OS: macOS   
Latest Commit: Version Fixed In:
Attachments: Patch of changes to src/saslplugin/plugin_common.{c,h}

Description Max Leiter 2022-06-16 07:41:36 UTC
Created attachment 149774 [details]
Patch of changes to src/saslplugin/plugin_common.{c,h}

SUMMARY

I'm trying to compile libkgapi for macOS (as it's a downstream dependency of kmailtransport) and have encountered an issue. Some of the imports in `saslplugin/plugin_common.c` and the header are wrapped in a `#ifndef macintosh`. The following are needed for utsname/sockaddr/etc and allow the package to compile. 

```
#include <sys/socket.h>
#include <netdb.h>
#include <sys/utsname.h>
```

I've attempted to provide a patch and can confirm it compiles on macOS but not other operating systems.

I'm MaxLeiter in #kde and #kde-mac if anyone wants to reach out that way. 

STEPS TO REPRODUCE
1. 
2. 
3. 

OBSERVED RESULT


EXPECTED RESULT


SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 
KDE Frameworks Version: 
Qt Version: 

ADDITIONAL INFORMATION
Comment 1 Max Leiter 2022-06-16 07:44:57 UTC
I've opened a merge request at https://invent.kde.org/pim/libkgapi/-/merge_requests/28
Comment 2 Max Leiter 2022-06-21 17:26:14 UTC
Fixed in https://invent.kde.org/pim/libkgapi/-/merge_requests/28