Skip to content

Commit

Permalink
final demo
Browse files Browse the repository at this point in the history
  • Loading branch information
omarzl committed Oct 16, 2021
1 parent 8244b7a commit 3dda60b
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 13 deletions.
7 changes: 4 additions & 3 deletions BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,11 @@ swift_library(
name = "MyLib",
srcs = glob(["Sources/*.swift"]),
copts = [
"-Xcc",
"-fmodule-map-file=Sources/Dummy.modulemap",
"-import-underlying-module",
"-Xcc",
"-fmodule-map-file=Sources/MyLib.modulemap",
],
data = ['Sources/Dummy.modulemap', 'Sources/Dummy-umbrella.h'],
data = ['Sources/MyLib.modulemap', 'Sources/MyLib-umbrella.h'],
module_name = "MyLib",
visibility = ["//visibility:public"],
)
6 changes: 0 additions & 6 deletions Sources/Dummy.modulemap

This file was deleted.

4 changes: 2 additions & 2 deletions Sources/Dummy-umbrella.h → Sources/MyLib-umbrella.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,5 @@
#endif


FOUNDATION_EXPORT double DummyVersionNumber;
FOUNDATION_EXPORT const unsigned char DummyVersionString[];
FOUNDATION_EXPORT double MyLibVersionNumber;
FOUNDATION_EXPORT const unsigned char MyLibVersionString[];
6 changes: 6 additions & 0 deletions Sources/MyLib.modulemap
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
module MyLib {
umbrella header "MyLib-umbrella.h"

export *
module * { export * }
}
1 change: 0 additions & 1 deletion Sources/OtherClass.swift
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import UIKit

class OtherClass {

Expand Down
1 change: 0 additions & 1 deletion Sources/SomeClass.swift
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import UIKit

class SomeClass {

Expand Down

0 comments on commit 3dda60b

Please sign in to comment.