Comments (5)
请通过 Go Modules 进行构建。
from pipe.
Hi @88250
环境:Windows 10版本,golang v1.14支持go mod;
问题:设置CGO_ENABLED=0出现错误:
go run main.go
opens database failed: Binary was compiled with 'CGO_ENABLED=0', go-sqlite3 requires cgo to work. This is a stub
后来改成CGO_ENABLED=1,出现错误:
go run main.go
github.com/mattn/go-sqlite3
exec: "gcc": executable file not found in %PATH%
我已经在windows10上安装SQLite,仍旧有问题。还是pipe不支持windows下编译运行?谢谢。
from pipe.
- 我这里没有单独安装 SQLite
- 支持 Windows 编译运行
from pipe.
谢谢,那这个错误该如何解决啊? 本机没有安装MYSQL,打算使用SQLite3.
go run master.go 或者./pipe.exe
D 2020/04/14 23:43:02 confs.go:183: configurations [&model.Configuration{Server:"http://localhost:5897", StaticServer:"http://localhost:5897", StaticResourceVersion:"1586060811337", LogLevel:"debug", ShowSQL:false, SessionSecret:"1TabWo9Y8jAhMVwqOPkVzMvFD9u1ISWn", SessionMaxAge:86400, RuntimeMode:"dev", SQLite:"C:\Users\Gordon/pipe.db", MySQL:"user:password@(localhost:3306)/pipe?charset=utf8mb4&parseTime=True&loc=Local&timeout=1s&readTimeout=16s&writeTimeout=16s", Port:"5897", AxiosBaseURL:"/api", MockServer:"http://localhost:8888"}]
D 2020/04/14 23:43:02 themes.go:43: loaded [7] themes
F 2020/04/14 23:43:02 db.go:44: opens database failed: Binary was compiled with 'CGO_ENABLED=0', go-sqlite3 requires cgo to work. This is a stub
exit status 1
from pipe.
Binary was compiled with 'CGO_ENABLED=0', go-sqlite3 requires cgo to work. This is a stub
看样子是编译的时候需要打开 CGO_ENABLED=1
。
from pipe.
Related Issues (20)
- Add README in English
- 支持 PostgreSQL 数据库 HOT 18
- Upgrade vuefity to latest version 2.2.27 HOT 4
- 后台设置提交优化
- 修复登录验证安全漏洞
- 为 Littlewin 添加目录
- 希望能添加类似清风明月的功能 HOT 1
- Pipe启动后报错:Scan error on column index 1, name "created_at" HOT 4
- pipe不支持https:This request has been blocked; the content must be served over HTTPS. HOT 2
- 编辑文章报错
- 社区端域名变更
- 或许可以期待一个docker一键最小脚本?caddy+sqlite那种?
- 数据库连接池泄露 HOT 1
- 编译pipe的Docker镜像是报错,盼复 HOT 1
- 升级编辑器
- 黑名单刷新问题
- errors from cd console npm install HOT 1
- errors from postgresql HOT 1
- 编辑器 CDN 从 `cdn.jsdelivr.net` 切换到 `unpkg.com`
- 自转跳转到localhost
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pipe.