Skip to content

Commit

Permalink
Use explicit module map
Browse files Browse the repository at this point in the history
  • Loading branch information
kishikawakatsumi committed Feb 10, 2018
1 parent 3e410b7 commit d65d7e6
Show file tree
Hide file tree
Showing 9 changed files with 21 additions and 10 deletions.
2 changes: 2 additions & 0 deletions BitcoinKit.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ Pod::Spec.new do |spec|
spec.requires_arc = true
spec.source = { git: 'https://github.com/kishikawakatsumi/BitcoinKit.git', tag: "v#{spec.version}" }
spec.source_files = 'BitcoinKit/**/*.{h,m,swift}'
spec.private_header_files = 'BitcoinKit/**/BitcoinKitInternal.h'
spec.module_map = 'BitcoinKit/BitcoinKit.modulemap'
spec.ios.deployment_target = '8.0'
spec.swift_version = '4.0'

Expand Down
4 changes: 3 additions & 1 deletion BitcoinKit.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
objects = {

/* Begin PBXBuildFile section */
1419E83A202CDBE500FCB0BE /* BitcoinKitInternal.h in Headers */ = {isa = PBXBuildFile; fileRef = 1419E838202CDBE500FCB0BE /* BitcoinKitInternal.h */; };
1419E83A202CDBE500FCB0BE /* BitcoinKitInternal.h in Headers */ = {isa = PBXBuildFile; fileRef = 1419E838202CDBE500FCB0BE /* BitcoinKitInternal.h */; settings = {ATTRIBUTES = (Private, ); }; };
1419E83B202CDBE500FCB0BE /* BitcoinKitInternal.m in Sources */ = {isa = PBXBuildFile; fileRef = 1419E839202CDBE500FCB0BE /* BitcoinKitInternal.m */; };
141FE2E22022588C00A08B04 /* PublicKey.swift in Sources */ = {isa = PBXBuildFile; fileRef = 141FE2E12022588C00A08B04 /* PublicKey.swift */; };
141FE2E42022589E00A08B04 /* PrivateKey.swift in Sources */ = {isa = PBXBuildFile; fileRef = 141FE2E32022589E00A08B04 /* PrivateKey.swift */; };
Expand Down Expand Up @@ -479,6 +479,7 @@
"$(SRCROOT)/Libraries/openssl/lib",
"$(SRCROOT)/Libraries/secp256k1/lib",
);
MODULEMAP_FILE = "$(SRCROOT)/BitcoinKit/BitcoinKit.modulemap";
PRODUCT_BUNDLE_IDENTIFIER = com.kishikawakatsumi.BitcoinKit;
PRODUCT_NAME = "$(TARGET_NAME:c99extidentifier)";
SKIP_INSTALL = YES;
Expand Down Expand Up @@ -512,6 +513,7 @@
"$(SRCROOT)/Libraries/openssl/lib",
"$(SRCROOT)/Libraries/secp256k1/lib",
);
MODULEMAP_FILE = "$(SRCROOT)/BitcoinKit/BitcoinKit.modulemap";
PRODUCT_BUNDLE_IDENTIFIER = com.kishikawakatsumi.BitcoinKit;
PRODUCT_NAME = "$(TARGET_NAME:c99extidentifier)";
SKIP_INSTALL = YES;
Expand Down
11 changes: 11 additions & 0 deletions BitcoinKit/BitcoinKit.modulemap
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
framework module BitcoinKit {
umbrella header "BitcoinKit.h"

export *
module * { export * }

explicit module Private {
header "BitcoinKitInternal.h"
link "crypto"
}
}
2 changes: 1 addition & 1 deletion BitcoinKit/Crypto.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
//

import Foundation
import BitcoinKitInternal
import BitcoinKit.Private
import secp256k1

public struct Crypto {
Expand Down
2 changes: 1 addition & 1 deletion BitcoinKit/HDPrivateKey.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
//

import Foundation
import BitcoinKitInternal
import BitcoinKit.Private

public class HDPrivateKey {
public let network: Network
Expand Down
2 changes: 1 addition & 1 deletion BitcoinKit/HDPublicKey.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
//

import Foundation
import BitcoinKitInternal
import BitcoinKit.Private

public class HDPublicKey {
public let network: Network
Expand Down
2 changes: 1 addition & 1 deletion BitcoinKit/Mnemonic.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
//

import Foundation
import BitcoinKitInternal
import BitcoinKit.Private

public struct Mnemonic {
public enum Strength : Int {
Expand Down
2 changes: 1 addition & 1 deletion BitcoinKit/PublicKey.swift
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
//

import Foundation
import BitcoinKitInternal
import BitcoinKit.Private

public struct PublicKey {
let raw: Data
Expand Down
4 changes: 0 additions & 4 deletions Libraries/BitcoinKitInternal/module.modulemap

This file was deleted.

0 comments on commit d65d7e6

Please sign in to comment.