Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SR-9874] System library modules cannot be imported in SwiftPM REPL #4730

Open
sharplet opened this issue Feb 6, 2019 · 0 comments
Open
Labels

Comments

@sharplet
Copy link

sharplet commented Feb 6, 2019

Previous ID SR-9874
Radar None
Original Reporter @sharplet
Type Bug
Environment
% swift --version
Apple Swift version 5.0 (swiftlang-1001.0.60.3 clang-1001.0.37.8)
Target: x86_64-apple-darwin18.2.0
ABI version: 0.7
% xcodebuild -version
Xcode 10.2
Build version 10P91b
Additional Detail from JIRA
Votes 0
Component/s Package Manager
Labels Bug
Assignee None
Priority Medium

md5: 3eee2e6974c079bd026576279dc7935c

Issue Description:

It currently doesn't appear possible to import system library modules via swift run --repl:

% git clone https://github.com/sharplet/greetings-sqlite.git
% cd greetings-sqlite
% swift run --repl
Launching Swift REPL with arguments: -I/Users/asharp/src/sharplet/greetings-sqlite/.build/x86_64-apple-macosx/debug -L/Users/asharp/src/sharplet/greetings-sqlite/.build/x86_64-apple-macosx/debug -lgreetings__REPL -I/usr/local/Cellar/sqlite/3.26.0_1/include
Welcome to Apple Swift version 5.0 (swiftlang-1001.0.60.3 clang-1001.0.37.8).
Type :help for assistance.
  1> import CSQlite
error: repl.swift:1:8: error: no such module 'CSQlite'
import CSQlite
       ^

I can work around the issue by taking the REPL arguments and adding -ISources/CSQLite, then launching swift manually with the modified arguments.

@swift-ci swift-ci transferred this issue from apple/swift-issues Apr 25, 2022
@shahmishal shahmishal transferred this issue from apple/swift May 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants