initial commit

IOS-2882
Andreas Buff 2021-07-15 16:13:07 +02:00
commit 2b1d68e9f8
37 changed files with 2889 additions and 0 deletions

78
.gitignore vendored Normal file
View File

@ -0,0 +1,78 @@
generated*
tmp
*build/*
### Objective-C ###
# Xcode
## Build generated
build/
DerivedData/
## Various settings
*.pbxuser
!default.pbxuser
*.mode1v3
!default.mode1v3
*.mode2v3
!default.mode2v3
*.perspectivev3
!default.perspectivev3
*xcuserdata/
## Other
*.moved-aside
*.xccheckout
*.xcscmblueprint
## Obj-C/Swift specific
*.hmap
*.ipa
*.dSYM.zip
*.dSYM
### Objective-C Patch ###
### OSX ###
# General
.DS_Store
.AppleDouble
.LSOverride
# Icon must end with two \r
Icon
# Thumbnails
._*
# Files that might appear in the root of a volume
.DocumentRevisions-V100
.fseventsd
.Spotlight-V100
.TemporaryItems
.Trashes
.VolumeIcon.icns
.com.apple.timemachine.donotpresent
# Directories potentially created on remote AFP share
.AppleDB
.AppleDesktop
Network Trash Folder
Temporary Items
.apdisk
## Playgrounds
timeline.xctimeline
playground.xcworkspace
# Swift Package Manager
# Add this line if you want to avoid checking in source code from Swift Package Manager dependencies.
# Packages/
# Package.pins
# Package.resolved
.build/
### Xcode Patch ###
**/xcshareddata/WorkspaceSettings.xcsettings

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<Workspace
version = "1.0">
<FileRef
location = "self:">
</FileRef>
</Workspace>

View File

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IDEDidComputeMac32BitWarning</key>
<true/>
</dict>
</plist>

View File

@ -0,0 +1,67 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1250"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EEFC26A0432A00B822E1"
BuildableName = "CLEAN_ALL"
BlueprintName = "CLEAN_ALL"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EEFC26A0432A00B822E1"
BuildableName = "CLEAN_ALL"
BlueprintName = "CLEAN_ALL"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,67 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1250"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EEA5269EDA1E00B822E1"
BuildableName = "build_asn1cexecutable"
BlueprintName = "build_asn1cexecutable"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EEA5269EDA1E00B822E1"
BuildableName = "build_asn1cexecutable"
BlueprintName = "build_asn1cexecutable"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,67 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1250"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EE39269EC90100B822E1"
BuildableName = "build_boost_macOS"
BlueprintName = "build_boost_macOS"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EE39269EC90100B822E1"
BuildableName = "build_boost_macOS"
BlueprintName = "build_boost_macOS"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,67 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1250"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EE48269ECB8700B822E1"
BuildableName = "build_cryptopp_macOS"
BlueprintName = "build_cryptopp_macOS"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EE48269ECB8700B822E1"
BuildableName = "build_cryptopp_macOS"
BlueprintName = "build_cryptopp_macOS"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,67 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1250"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EE27269DD87700B822E1"
BuildableName = "build_libiconv_macOS"
BlueprintName = "build_libiconv_macOS"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EE27269DD87700B822E1"
BuildableName = "build_libiconv_macOS"
BlueprintName = "build_libiconv_macOS"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,67 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1250"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EE3E269EC9BB00B822E1"
BuildableName = "build_openssl_macOS"
BlueprintName = "build_openssl_macOS"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EE3E269EC9BB00B822E1"
BuildableName = "build_openssl_macOS"
BlueprintName = "build_openssl_macOS"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,67 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1250"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EE4D269ECFA900B822E1"
BuildableName = "build_pEpAdapter_macOS"
BlueprintName = "build_pEpAdapter_macOS"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EE4D269ECFA900B822E1"
BuildableName = "build_pEpAdapter_macOS"
BlueprintName = "build_pEpAdapter_macOS"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,67 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1250"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EEAA269EDAE200B822E1"
BuildableName = "build_pEpengine_macOS"
BlueprintName = "build_pEpengine_macOS"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EEAA269EDAE200B822E1"
BuildableName = "build_pEpengine_macOS"
BlueprintName = "build_pEpengine_macOS"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,67 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1250"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EE43269ECB2500B822E1"
BuildableName = "build_pEpwebserver_macOS"
BlueprintName = "build_pEpwebserver_macOS"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EE43269ECB2500B822E1"
BuildableName = "build_pEpwebserver_macOS"
BlueprintName = "build_pEpwebserver_macOS"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,67 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1250"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EF0526A0479800B822E1"
BuildableName = "build_sequoia_iOS"
BlueprintName = "build_sequoia_iOS"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EF0526A0479800B822E1"
BuildableName = "build_sequoia_iOS"
BlueprintName = "build_sequoia_iOS"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,67 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1250"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EECA269EF0F100B822E1"
BuildableName = "build_sequoia_macOS"
BlueprintName = "build_sequoia_macOS"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "1585EECA269EF0F100B822E1"
BuildableName = "build_sequoia_macOS"
BlueprintName = "build_sequoia_macOS"
ReferencedContainer = "container:CommonPEPDependencies.xcodeproj">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>MACOSX_DEPLOYMENT_x86_64</key>
<string>10.10</string>
<key>MACOSX_DEPLOYMENT_M1</key>
<string>11.0</string>
<key>CommonPEPDependencies_PREFIX</key>
<string>build</string>
</dict>
</plist>

100
README.md Normal file
View File

@ -0,0 +1,100 @@
Contains one macOS build script for each dependency and an Xcode project with convenience build aggragates (using the build scripts).
## Prerequisites
### Package managers
MacPorts for installing dependencies:
Install [MacPorts](https://www.macports.org/) for your
[version of OS X/macOS](https://www.macports.org/install.php).
### Dependencies of prerequisites
You need a working python3 environment and all dependencies:
```
sudo port install git
sudo port install asn1c
sudo port install python38
sudo port install py38-lxml
sudo port select --set python3 python38
sudo port install gmake
sudo port install autoconf
sudo port install libtool
sudo port install automake
sudo port install wget
sudo port install gsed
sudo port install capnproto
xcode-select --install
```
#### Install Rust
```
curl https://sh.rustup.rs -sSf | sh
```
add this to ~/.profile (create if it doesn't exist):
```
source $HOME/.cargo/env
export PATH="$HOME/.cargo/bin:$PATH"
```
Restart your Console!
```
sudo port install pkgconfig
rustup toolchain install nightly
rustup target add x86_64-apple-darwin
rustup target add aarch64-apple-darwin
rustup target add aarch64-apple-darwin --toolchain nightly
rustup update
```
## Dependencies
```
git clone https://gitea.pep.foundation/buff/mac-os-build-scripts-common-dependencies.git
```
## Build
We recomend to not use the shell scripts directly but to use Xcode (because its a working, tested onliner and using the scripts directly is undocumented and untested).
### Using Xcode UI
`open CommonPEPDependencies/CommonPEPDependencies.xcodeproj`.
Build the scheme fitting your needs (e.g. "build-pEpMIME-dependencies_macOS" if you need the dependencies for building pEpMIME).
### Using terminal
`xcodebuild -project "CommonPEPDependencies/CommonPEPDependencies.xcodeproj" -scheme "$NAME_OF_SCHEME_FITING_YOUR_NEEDS" -configuration [RELEASE|DEBUG]`
## Output Dir
You can configure the PREFIX to save build arttefacts and headers in CommonPEPDependencies/config.plist, setting the value for key "CommonPEPDependencies_PREFIX". It is relative to `CommonPEPDependencies/CommonPEPDependencies.xcodeproj`.
The default output dir is `CommonPEPDependencies/build`.
See: #Configs section for details re configuring it
## Configs
### config.plist
There is a `CommonPEPDependencies/config.plist` config file which you can configure the following in:
#### CommonPEPDependencies_PREFIX
Defines the PREFIX directory to save build arttefacts and headers in. It is relative to `CommonPEPDependencies/CommonPEPDependencies.xcodeproj`.
### pEp_versions.plist
There is a `/_config/pEp_versions.plist` where you can configure the version used for pEp dependencies.
For 3rd party dependencies, the version used is hardcoded in the corresponding .code file (e.g. `buildcode/iconv.code`) as it is assumed to use the same 3rd party lib version for all pEp projects (if that assumtion is wrong, please do not chagne the `.code`file but ping the maintainer to the version to `/_config/pEp_versions.plist` ).

View File

@ -0,0 +1,28 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>SEQUOIA_4_iOS_VERSION</key>
<string>v2.1.6</string>
<key>SEQUOIA_4_MAC_OS_VERSION</key>
<string>v2.1.6</string>
<key>PEP4THUNDERBIRD_VERSION</key>
<string>1.1.111-build2</string>
<key>IMPORT_FROM_ENIGMAIL_VERSION</key>
<string>Release_2.1.18</string>
<key>PEP_ENGINE_VERSION</key>
<string>Release_2.1.45</string>
<key>LIB_PEP_ADAPTER_VERSION</key>
<string>Release_2.1.21</string>
<key>WEBSERVER_VERSION</key>
<string>Release_2.1.0-RC7</string>
<key>JSON_SERVER_ADAPTER_VERSION</key>
<string>Release_2.1.5</string>
<key>DOWNLOADCLIENT_VERSION</key>
<string>Release_2.1.2-RC2</string>
<key>MAC_OS_ADAPTER_VERSION</key>
<string>Release_2.1.6-RC2</string>
<key>PEP4THUNDERBIRD_PKG_MAKER_VERSION</key>
<string>Release_2.1.4-RC2</string>
</dict>
</plist>

46
build-asn1executable.sh Normal file
View File

@ -0,0 +1,46 @@
#!/bin/bash
# Pass PREFIX as argument. If not passed, "local/" is used as deafult.
# Exit on errors
set -e
SCRIPT_DIR=$(dirname "$0")
PREFIX=$1
# Get Absolute Paths & Setup
SCRIPT_DIR=$(dirname "$0")
pushd "${SCRIPT_DIR}"
SCRIPT_DIR=$(pwd)
popd
if [ "${PREFIX}" = "" ]; then
PREFIX="${SCRIPT_DIR}/local"
fi
mkdir -p "${PREFIX}"
pushd "${PREFIX}"
PREFIX=$(pwd)
popd
TMP_DIR="${SCRIPT_DIR}/tmp"
mkdir -p "${TMP_DIR}"
if [ -f "${PREFIX}/bin/asn1c" ]; then
echo "lib exists already in ${LIB_DIR}. If you want to rebuild it, delete the existing one."
exit 0
fi
# ASN1c executable
ASN1_DIR="${TMP_DIR}/asn1c"
if [ ! -d "${ASN1_DIR}" ]; then
pushd "${TMP_DIR}"
git clone -b "v0.9.28" git://github.com/vlm/asn1c.git
popd
fi
pushd ${ASN1_DIR}
autoreconf -iv
./configure --prefix=${PREFIX}
make -j4 install
popd

54
build-fat-libs.sh Normal file
View File

@ -0,0 +1,54 @@
#!/bin/bash
# Creates fat libs of all .a files in `ARCH1_DIR` (1st param), combining .a with same name in `ARCH2_DIR` (2nd param), saving fat lib in `OUTPUT_DIR` (3rd param).
# Exit on errors
set -e
SCRIPT_DIR=$(dirname "$0")
ARCH1_DIR=$1
ARCH2_DIR=$2
OUTPUT_DIR=$3
# Get absolute paths
pushd "${SCRIPT_DIR}"
SCRIPT_DIR=$(pwd)
popd
pushd "${ARCH1_DIR}"
ARCH1_DIR=$(pwd)
popd
pushd "${ARCH2_DIR}"
ARCH2_DIR=$(pwd)
popd
pushd "${OUTPUT_DIR}"
OUTPUT_DIR=$(pwd)
popd
echo "BUFF: ARCH1_DIR: ${ARCH1_DIR}"
echo "BUFF: ARCH1_DIR: ${ARCH2_DIR}"
exitAndPrintHelp()
{
echo "Must be called with ARCH1_DIR ARCH2_DIR OUTPUT_DIR, all absolute paths."
exit 1
}
if [ "${ARCH1_DIR}" = "" ]; then
exitAndPrintHelp
elif [ "${ARCH2_DIR}" = "" ]; then
exitAndPrintHelp
elif [ "${OUTPUT_DIR}" = "" ]; then
exitAndPrintHelp
fi
pushd "${ARCH1_DIR}"
OBJECT_FILE_NAMES=$(ls *.a)
popd
for OBJECT_FILE_NAME in ${OBJECT_FILE_NAMES}; do
IN1="${ARCH1_DIR}/${OBJECT_FILE_NAME}"
IN2="${ARCH2_DIR}/${OBJECT_FILE_NAME}"
OUT="${OUTPUT_DIR}/${OBJECT_FILE_NAME}"
mkdir -p "${OUTPUT_DIR}"
lipo -create -output "${OUT}" "${IN1}" "${IN2}"
done

61
build-macOSAdapter.sh Normal file
View File

@ -0,0 +1,61 @@
#!/bin/bash
# Builds fat lib for macOS (ARM64 & x86_64).
# Pass PREFIX as argument. If not passed, "local/" is used as deafult. Config can also be passed.
# Sample:
# `sh build-pEpEngine-macOS.sh $MyPREFIX [RELEASE|DEBUG]
# Exit on errors
set -e
SCRIPT_DIR=$(dirname "$0")
PREFIX=$1
CONFIG=$2
if [ "${CONFIG}" = "" ]; then
CONFIG="RELEASE"
fi
MACOSADAPTER_VERSION=$(sh get-pEp-version.sh "MAC_OS_ADAPTER_VERSION")
DOWNLOADCLIENT_VERSION=$(sh get-pEp-version.sh "DOWNLOADCLIENT_VERSION")
# Get Absolute Paths & Setup
SCRIPT_DIR=$(sh "${SCRIPT_DIR}/helper/absolutepath.sh ${SCRIPT_DIR}"
if [ "${PREFIX}" = "" ]; then
PREFIX="${SCRIPT_DIR}/local"
fi
mkdir -p "${PREFIX}"
PREFIX=$(sh "${SCRIPT_DIR}/helper/absolutepath.sh ${PREFIX}"
TMP_DIR="${SCRIPT_DIR}/tmp"
mkdir -p "${TMP_DIR}"
if [ -f "${PREFIX}/bin/foundation.pEp.adapter.macOS" ]; then
echo "lib exists already in ${LIB_DIR}. If you want to rebuild it, delete the existing one."
exit 0
fi
# libpEpEngine
pushd "${TMP_DIR}"
MAC_OS_ADAPTER_DIR="${TMP_DIR}/pEpMacOSAdapter"
if [ ! -d "${MAC_OS_ADAPTER_DIR}" ]; then
git clone -b "${MACOSADAPTER_VERSION}" https://gitea.pep.foundation/pEp.foundation/pEpMacOSAdapter/
fi
DOWNLOADCLIENT_DIR="${TMP_DIR}/downloadclient"
if [ ! -d "${DOWNLOADCLIENT_DIR}" ]; then
git clone -b "${DOWNLOADCLIENT_VERSION}" https://gitea.pep.foundation/pEp.foundation/downloadclient
# Is build with macOSAdapter Xcode project
fi
pushd ${MAC_OS_ADAPTER_DIR}
xcodebuild -workspace "pEpMacOSAdapter.xcworkspace" -scheme "All" -configuration ${CONFIG}
cp -r "build/foundation.pEp.adapter.macOS.xpc/Contents/MacOS/foundation.pEp.adapter.macOS" "${PREFIX}/bin/foundation.pEp.adapter.macOS"
mkdir -p "${PREFIX}/apps"
cp -r "Submodules/pEpNotifications/build/p≡p updates.app" "${PREFIX}/apps/p≡p updates.app"
popd
popd
# Cleanup
rm -rf "${TMP_DIR}/x86_64"
rm -rf "${TMP_DIR}/arm64"
export MACOSX_DEPLOYMENT_TARGET=10.10

View File

@ -0,0 +1,92 @@
#!/bin/bash
# Builds fat lib for macOS (ARM64 & x86_64).
# Pass PREFIX as argument. If not passed, "local/" is used as deafult.
# Exit on errors
set -e
SCRIPT_DIR=$(dirname "$0")
PREFIX=$1
# Get Absolute Paths & Setup
SCRIPT_DIR=$(dirname "$0")
pushd "${SCRIPT_DIR}"
SCRIPT_DIR=$(pwd)
popd
if [ "${PREFIX}" = "" ]; then
PREFIX="${SCRIPT_DIR}/local"
fi
mkdir -p "${PREFIX}"
pushd "${PREFIX}"
PREFIX=$(pwd)
popd
TMP_DIR="${SCRIPT_DIR}/tmp"
INCLUDE_DIR="${PREFIX}/include"
LIB_DIR="${PREFIX}/lib"
mkdir -p "${INCLUDE_DIR}"
mkdir -p "${LIB_DIR}"
mkdir -p "${TMP_DIR}"
MACOSX_DEPLOYMENT_TARGET_INTEL=$("${SCRIPT_DIR}"/get-config-macos-deployment-target-x86_64.sh)
MACOSX_DEPLOYMENT_TARGET_ARM=$("${SCRIPT_DIR}"/get-config-macos-deployment-target-M1.sh)
# Funcs
buildLib()
{
ARCH=$1
TARGET=$2
HOST=$3
SDK=$4
SDK_PATH=`xcrun -sdk ${SDK} --show-sdk-path`
if [ "${ARCH}" == "x86_64" ]; then
export MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET_INTEL}
elif [ "${ARCH}" == "arm64" ]; then
export MACOSX_DEPLOYMENT_TARGET=${MACOSX_DEPLOYMENT_TARGET_ARM}
else
echo "Error: Unhandled arch!"
exit 1
fi
CURRENT_LIB_DIR="${TMP_DIR}/${ARCH}"
mkdir -p "${CURRENT_LIB_DIR}/lib"
mkdir -p "${CURRENT_LIB_DIR}/include"
# START: Lib Specific Code
BUILD_CODE
# END: Lib Specific Code
}
# Cleanup
cleanup()
{
rm -rf "${TMP_DIR}/x86_64"
rm -rf "${TMP_DIR}/arm64"
export MACOSX_DEPLOYMENT_TARGET=10.10
}
cleanup
# Setup
mkdir -p "${TMP_DIR}"
mkdir -p "${PREFIX}"
# Build
pushd "${TMP_DIR}"
buildLib "x86_64" "x86_64-apple-macos10.10" "x86_64-apple-darwin" "macosx"
buildLib "arm64" "arm64-apple-macos11.1" "aarch64-apple-darwin" "macosx"
popd
# Make Fat Lib
sh "${SCRIPT_DIR}/build-fat-libs.sh" "${TMP_DIR}/arm64/lib" "${TMP_DIR}/x86_64/lib" "${LIB_DIR}"
# Copy Headers
ARM64_INCLUDE_DIR="${TMP_DIR}/arm64/include"
cp -r "${ARM64_INCLUDE_DIR}"/* "${INCLUDE_DIR}"
# Cleanup
cleanup

78
build-pEpEngine-macOS.sh Normal file
View File

@ -0,0 +1,78 @@
#!/bin/bash
# Builds fat lib for macOS (ARM64 & x86_64).
# Pass PREFIX as argument. If not passed, "local/" is used as deafult. Config can also be passed.
# Sample:
# `sh build-pEpEngine-macOS.sh $MyPREFIX [RELEASE|DEBUG]
# Exit on errors
set -e
SCRIPT_DIR=$(dirname "$0")
PREFIX=$1
CONFIG=$2
if [ "${CONFIG}" = "" ]; then
CONFIG="RELEASE"
fi
VERSION=$(sh "${SCRIPT_DIR}/get-pEp-version.sh" "PEP_ENGINE_VERSION")
# Get Absolute Paths & Setup
pushd "${SCRIPT_DIR}"
SCRIPT_DIR=$(pwd)
popd
if [ "${PREFIX}" = "" ]; then
PREFIX="${SCRIPT_DIR}/local"
fi
mkdir -p "${PREFIX}"
pushd "${PREFIX}"
PREFIX=$(pwd)
popd
TMP_DIR="${SCRIPT_DIR}/tmp"
mkdir -p "${TMP_DIR}"
if [ -f "${PREFIX}/lib/libpEpEngine.a" ]; then
echo "lib exists already in ${LIB_DIR}. If you want to rebuild it, delete the existing one."
exit 0
fi
# libpEpEngine
pushd "${TMP_DIR}"
PEP_ENGINE_DIR="${TMP_DIR}/pEpEngine"
if [ ! -d "${PEP_ENGINE_DIR}" ]; then
git clone -b "${VERSION}" https://gitea.pep.foundation/buff/pEpEngine
fi
SQLITE3_DIR="${TMP_DIR}/sqlite"
if [ ! -d "${SQLITE3_DIR}" ]; then
git clone -b "master" https://pep-security.lu/gitlab/misc/sqlite.git
# build with Engine Xcode project
fi
LIBETPAN_DIR="${TMP_DIR}/libetpan"
if [ ! -d "${LIBETPAN_DIR}" ]; then
git clone -b "master" https://gitea.pep.foundation/buff/libetpan.git
# build with Engine Xcode project
fi
XCODE_PROJECT_DIR="${PEP_ENGINE_DIR}/build-mac"
pushd ${XCODE_PROJECT_DIR}
xcodebuild -project "pEpEngine.xcodeproj" -scheme "pEpEngine_macOS" -configuration ${CONFIG}
popd
# Copy Artefacts
cp "${XCODE_PROJECT_DIR}/build/libpEpEngine.a" "${PREFIX}/lib/libpEpEngine.a"
cp "${XCODE_PROJECT_DIR}/Subprojects/pEpASN1/build/libpEpASN1_macOS.a" "${LIB_DIR}/lib/libasn1.a"
cp "${XCODE_PROJECT_DIR}/Subprojects/PEPSQLITE3/build/libPEPSQLITE3_macOS.a" "${PREFIX}/lib/libsqlite3.a"
cp "${SCRIPT_DIR}/libetpan/build-mac/build/libetpan.a" "${PREFIX}/lib"
# Copy Headers
cp -r "${XCODE_PROJECT_DIR}/build/include"/* "${PREFIX}/include"
cp -r "${XCODE_PROJECT_DIR}/Subprojects/pEpASN1/build/include"/* "${PREFIX}/include"
cp -r ${XCODE_PROJECT_DIR}/Subprojects/PEPSQLITE3/build/include/* "${PREFIX}/include"
popd
# Cleanup
rm -rf "${TMP_DIR}/x86_64"
rm -rf "${TMP_DIR}/arm64"
export MACOSX_DEPLOYMENT_TARGET=10.10

59
build-sequoia-iOS.sh Normal file
View File

@ -0,0 +1,59 @@
#!/bin/bash
# Builds fat lib for macOS (ARM64 & x86_64).
# Pass PREFIX as argument. If not passed, "local/" is used as deafult.
set -e
SCRIPT_DIR=$(dirname "$0")
PREFIX=$1
VERSION=$(sh "${SCRIPT_DIR}/get-pEp-version.sh" "SEQUOIA_4_iOS_VERSION")
# Get Absolute Paths & Setup
# Get Absolute Paths & Setup
SCRIPT_DIR=$(dirname "$0")
pushd "${SCRIPT_DIR}"
SCRIPT_DIR=$(pwd)
popd
if [ "${PREFIX}" = "" ]; then
PREFIX="${SCRIPT_DIR}/local"
fi
mkdir -p "${PREFIX}"
pushd "${PREFIX}"
PREFIX=$(pwd)
popd
# Go, Build
if [ -f "${PREFIX}/lib/libsequoia_openpgp_ffi.a" ]; then
echo "lib exists already in ${LIB_DIR}. If you want to rebuild it, delete the existing one."
exit 0
fi
TMP_DIR="${SCRIPT_DIR}/tmp"
mkdir -p "${TMP_DIR}"
pushd "${TMP_DIR}"
SEQUOIA_4_IOS_DIR="${TMP_DIR}/sequoia4macos"
if [ ! -d "${SEQUOIA_4_IOS_DIR}" ]; then
git clone -b "${VERSION}" http://pep-security.lu/gitlab/iOS/sequoia4ios.git
fi
pushd ${SEQUOIA_4_IOS_DIR}
sh build.sh
popd
# Copy artefacts ...
cp "${SEQUOIA_4_IOS_DIR}/build/lib/libgmp.a" "${PREFIX}/lib/"
cp "${SEQUOIA_4_IOS_DIR}/build/lib/libhogweed.a" "${PREFIX}/lib/"
cp "${SEQUOIA_4_IOS_DIR}/build/lib/libnettle.a" "${PREFIX}/lib/"
cp "${SEQUOIA_4_IOS_DIR}/build/lib/libsequoia_openpgp_ffi.a" "${PREFIX}/lib/"
# ... and headers
cp -R "${SEQUOIA_4_IOS_DIR}/build/include/nettle" "${PREFIX}/include/"
cp -R "${SEQUOIA_4_IOS_DIR}/build/include/sequoia" "${PREFIX}/include/"
cp "${SEQUOIA_4_IOS_DIR}/build/include/gmp.h" "${PREFIX}/include/"
popd
# Cleanup
rm -rf "${TMP_DIR}/x86_64"
rm -rf "${TMP_DIR}/arm64"

61
build-sequoia-macOS.sh Normal file
View File

@ -0,0 +1,61 @@
#!/bin/bash
# Builds fat lib for macOS (ARM64 & x86_64).
# Pass PREFIX as argument. If not passed, "local/" is used as deafult.
set -e
SCRIPT_DIR=$(dirname "$0")
PREFIX=$1
VERSION=$(sh "${SCRIPT_DIR}/get-pEp-version.sh" "SEQUOIA_4_MAC_OS_VERSION")
# Get Absolute Paths & Setup
# Get Absolute Paths & Setup
SCRIPT_DIR=$(dirname "$0")
pushd "${SCRIPT_DIR}"
SCRIPT_DIR=$(pwd)
popd
if [ "${PREFIX}" = "" ]; then
PREFIX="${SCRIPT_DIR}/local"
fi
mkdir -p "${PREFIX}"
pushd "${PREFIX}"
PREFIX=$(pwd)
popd
# Go, Build
if [ -f "${PREFIX}/lib/libsequoia_openpgp_ffi.a" ]; then
echo "lib exists already in ${LIB_DIR}. If you want to rebuild it, delete the existing one."
exit 0
fi
TMP_DIR="${SCRIPT_DIR}/tmp"
mkdir -p "${TMP_DIR}"
pushd "${TMP_DIR}"
SEQUOIA_4_MACOS_DIR="${TMP_DIR}/sequoia4macos"
if [ ! -d "${SEQUOIA_4_MACOS_DIR}" ]; then
git clone -b "${VERSION}" http://pep-security.lu/gitlab/macos/sequoia4macos.git
fi
pushd ${SEQUOIA_4_MACOS_DIR}
sh build.sh
popd
# Copy artefacts ...
cp "${SEQUOIA_4_MACOS_DIR}/build/lib/libgmp.a" "${PREFIX}/lib/"
cp "${SEQUOIA_4_MACOS_DIR}/build/lib/libhogweed.a" "${PREFIX}/lib/"
cp "${SEQUOIA_4_MACOS_DIR}/build/lib/libnettle.a" "${PREFIX}/lib/"
cp "${SEQUOIA_4_MACOS_DIR}/build/lib/libsequoia_ffi.a" "${PREFIX}/lib/"
cp "${SEQUOIA_4_MACOS_DIR}/build/lib/libsequoia_openpgp_ffi.a" "${PREFIX}/lib/"
# ... and headers
cp -R "${SEQUOIA_4_MACOS_DIR}/build/include/nettle" "${PREFIX}/include/"
cp -R "${SEQUOIA_4_MACOS_DIR}/build/include/sequoia" "${PREFIX}/include/"
cp "${SEQUOIA_4_MACOS_DIR}/build/include/gmp.h" "${PREFIX}/include/"
popd
# Cleanup
rm -rf "${TMP_DIR}/x86_64"
rm -rf "${TMP_DIR}/arm64"
export MACOSX_DEPLOYMENT_TARGET=10.10

38
buildcode/boost.code Normal file
View File

@ -0,0 +1,38 @@
if [ -f "${LIB_DIR}/libboost_regex.a" ]; then
echo "lib exists already in ${LIB_DIR}. If you want to rebuild it, delete the existing one."
exit 0
fi
BOOST_DIR="${TMP_DIR}/boost"
if [ ! -d "${BOOST_DIR}" ]; then
git clone -b boost-1.73.0 --recursive https://github.com/boostorg/boost.git
fi
pushd "${BOOST_DIR}"
rm -rf "stage"
./bootstrap.sh --with-toolset=clang-darwin macosx-version-min=${MACOSX_DEPLOYMENT_TARGET} cxxflags="-arch ${ARCH} -mmacosx-version-min=${MACOSX_DEPLOYMENT_TARGET}" cflags="-arch ${ARCH} -isysroot ${SDK_PATH}" linkflags="-arch ${ARCH}"
BOOST_TOOLSET="toolset=clang-darwin"
BOOST_TARGET="target-os=darwin"
USED_BOOST_LIBS_ARGS="--with-regex --with-filesystem --with-program_options --with-thread --with-system"
if [ ${ARCH} = "x86_64" ]; then
./b2 clean
./b2 ${BOOST_TOOLSET} ${BOOST_TARGET} architecture=x86 -std=c++11 cxxflags="-arch ${ARCH} -mmacosx-version-min=${MACOSX_DEPLOYMENT_TARGET}" cflags="-arch ${ARCH}" linkflags="-arch ${ARCH} " ${USED_BOOST_LIBS_ARGS} stage
./b2 install
elif [ ${ARCH} = "arm64" ]; then
./b2 clean
./b2 ${BOOST_TOOLSET} ${BOOST_TARGET} architecture=arm -std=c++11 abi=aapcs cxxflags="-arch ${ARCH} -mmacosx-version-min=${MACOSX_DEPLOYMENT_TARGET}" cflags="-arch ${ARCH}" linkflags="-arch ${ARCH}" ${USED_BOOST_LIBS_ARGS} stage
./b2 install
else
echo "unhandled ARCH"
exit 1
fi
# Copy *.a files
TARGET_DIR="${CURRENT_LIB_DIR}/lib"
mkdir -p "${TARGET_DIR}"
cp stage/lib/*.a "${TARGET_DIR}"
# Copy Headers
TARGET_DIR="${CURRENT_LIB_DIR}/include/"
#cp -r boost "${TARGET_DIR}"
rsync -rL boost "${TARGET_DIR}"
popd

36
buildcode/cryptopp.code Normal file
View File

@ -0,0 +1,36 @@
if [ -f "${LIB_DIR}/libcryptopp.a" ]; then
echo "lib exists already in ${LIB_DIR}. If you want to rebuild it, delete the existing one."
exit 0
fi
CRYPTOPP_DIR="${TMP_DIR}/cryptopp"
if [ ! -d "${CRYPTOPP_DIR}" ]; then
git clone -b CRYPTOPP_8_2_0 https://github.com/weidai11/cryptopp
fi
pushd ${CRYPTOPP_DIR}
export CXX="$(xcrun --sdk ${SDK} -f clang++) -arch ${ARCH} -isysroot ${SDK_PATH} -stdlib=libc++"
export CFLAGS="-arch ${ARCH} -isysroot ${SDK_PATH} -std=c14"
export LDFLAGS="-arch ${ARCH}"
export CC="$(xcrun --sdk ${SDK} -f clang) -arch ${ARCH} -isysroot ${SDK_PATH}-target ${TARGET}"
export PREFIX=${CURRENT_LIB_DIR}
if [ "${ARCH}" == "x86_64" ]; then
export CXXFLAGS="-arch ${ARCH} -isysroot ${SDK_PATH} -mmacosx-version-min=10.10"
make clean
make -j4
make install
elif [ "${ARCH}" == "arm64" ]; then
export CXXFLAGS="-arch ${ARCH} -isysroot ${SDK_PATH} -mmacosx-version-min=11.0 -DDISABLE_NATIVE_ARCH=1 -DCRYPTOPP_ARM_CRC32_AVAILABLE=0"
make clean
make -j4
make install
else
echo "Error: Unhandled arch!"
exit 1
fi
popd
unset PREFIX
unset CXXFLAGS
unset CXX
unset CFLAGS
unset LDFLAGS
unset CC

23
buildcode/iconv.code Normal file
View File

@ -0,0 +1,23 @@
if [ -f "${LIB_DIR}/libiconv.a" ]; then
echo "lib exists already in ${LIB_DIR}. If you want to rebuild it, delete the existing one."
exit 0
fi
ICONV_DIR="${TMP_DIR}/libiconv"
if [ ! -d "${ICONV_DIR}" ]; then
git clone -b "v1.16_without_lib_prefix_defines" https://gitea.pep.foundation/buff/libiconv.git
fi
pushd "${ICONV_DIR}"
export CFLAGS="-arch ${ARCH} -isysroot ${SDK_PATH} -std=c99"
export LDFLAGS="-arch ${ARCH}"
export CC="$(xcrun --sdk ${SDK} -f clang) -arch ${ARCH} -isysroot ${SDK_PATH}"
PKG_CONFIG_ALLOW_CROSS=1 PKG_CONFIG_PATH="${CURRENT_LIB_DIR}/lib/pkgconfig" ./configure --host=${HOST} --prefix=${CURRENT_LIB_DIR} --enable-static=yes --enable-shared=no
make clean
make -j4
make install
unset CFLAGS
unset LDFLAGS
unset CC
popd

24
buildcode/openssl.code Normal file
View File

@ -0,0 +1,24 @@
if [ -f "${LIB_DIR}/libcrypto.a" ]; then
echo "lib exists already in ${LIB_DIR}. If you want to rebuild it, delete the existing one."
exit 0
fi
OpenSSL_DIR="${TMP_DIR}/openssl"
if [ ! -d "${OpenSSL_DIR}" ]; then
git clone -b OpenSSL_1_1_1i https://github.com/openssl/openssl.git
fi
pushd "${OpenSSL_DIR}"
OPEN_SSL_TARGET="Not set"
if [ ${ARCH} == "arm64" ]; then
OPEN_SSL_TARGET=darwin64-arm64-cc
elif [ ${ARCH} = "x86_64" ]; then
OPEN_SSL_TARGET=darwin64-x86_64-cc
else
echo "unhandled ARCH"
exit 1
fi
./Configure --prefix=${CURRENT_LIB_DIR} --openssldir=${CURRENT_LIB_DIR}/ssl ${OPEN_SSL_TARGET}
make clean
make
make install
popd

31
buildcode/pEpAdapter.code Normal file
View File

@ -0,0 +1,31 @@
if [ -f "${LIB_DIR}/libpEpAdapter.a" ]; then
echo "lib exists already in ${LIB_DIR}. If you want to rebuild it, delete the existing one."
exit 0
fi
LIB_PEP_ADAPTER_DIR="${TMP_DIR}/libpEpAdapter"
if [ ! -d "${LIB_PEP_ADAPTER_DIR}" ]; then
git clone -b "${LIB_PEP_ADAPTER_VERSION}" https://gitea.pep.foundation/pEp.foundation/libpEpAdapter
fi
export CXXFLAGS="-arch ${ARCH} -isysroot ${SDK_PATH} -std=c++14 -fPIC"
export LDFLAGS="-arch ${ARCH}"
export CXX="$(xcrun --sdk ${SDK} -f clang++) -arch ${ARCH} -isysroot ${SDK_PATH}"
pushd ${LIB_PEP_ADAPTER_DIR}
LOCAL_CONF="\n
\n
DEBUG=0\n
\n
PREFIX=${CURRENT_LIB_DIR}\n
\n
ENGINE_LIB_PATH="${PREFIX}/lib"\n
\n
ENGINE_INC_PATH="${PREFIX}/include"\n
"
make clean
echo ${LOCAL_CONF} > local.conf
make all -j 4
make install
popd
unset CXXFLAGS
unset LDFLAGS
unset CXX

View File

@ -0,0 +1,42 @@
if [ -f "${PREFIX}/bin/pEp-mini-json-adapter" ]; then
echo "lib exists already in ${LIB_DIR}. If you want to rebuild it, delete the existing one."
exit 0
fi
PEP_JSON_ADAPTER_DIR="${TMP_DIR}/pEpJSONServerAdapter"
if [ ! -d "${PEP_JSON_ADAPTER_DIR}" ]; then
git clone -b ${JSON_SERVER_ADAPTER_VERSION} https://gitea.pep.foundation/pEp.foundation/pEpJSONServerAdapter.git
fi
export CXXFLAGS="-arch ${ARCH} -isysroot ${SDK_PATH}"
export CXX="$(xcrun --sdk ${SDK} -f clang++) -arch ${ARCH} -isysroot ${SDK_PATH} -stdlib=libc++"
export LDFLAGS="-arch ${ARCH}"
export CFLAGS="-arch ${ARCH} -isysroot ${SDK_PATH} -std=c14"
export CC="$(xcrun --sdk ${SDK} -f clang) -arch ${ARCH} -isysroot ${SDK_PATH}"
pushd "${PEP_JSON_ADAPTER_DIR}/server"
LOCAL_CONF="\n
\n
NDEBUG=yes\n
\n
PREFIX=${CURRENT_LIB_DIR}\n
\n
PEP_INCLUDE=${PREFIX}/include\n
\n
PEP_LIB_PATH=${PREFIX}/lib\n
\n
LIBRARY_PATH=${PREFIX}/lib\n
\n
BOOST_MT=\n
"
echo ${LOCAL_CONF} > local.conf
make clean
make
popd
unset CXXFLAGS
unset CXX
unset LDFLAGS