Cabal:Windows 8.1 中不存在
Cabal: Does not exists in Windows 8.1
今天我在笔记本电脑上安装了 windows 8.1 和 haskell。我正在尝试构建自己的 haskell 库,但是当我尝试使用 cabal sdist 时出现错误。这是错误:
D:\Development\School\AFP\Assignments\Practice\Exercise\Project>cabal sdist
Distribution quality errors:
'license: NONE' is not a recognised license. The known licenses are: GPL,
GPL-2, GPL-3, LGPL, LGPL-2.1, LGPL-3, AGPL, AGPL-3, BSD2, BSD3, MIT, ISC,
MPL-2.0, Apache, Apache-2.0, PublicDomain, AllRightsReserved, OtherLicense
Distribution quality warnings:
No 'category' field.
No 'maintainer' field.
No 'synopsis' field.
A 'license-file' is not specified.
When distributing packages it is encouraged to specify source control
information in the .cabal file using one or more 'source-repository' sections.
See the Cabal user guide for details.
Note: the public hackage server would reject this package.
Warning: Cannot run preprocessors. Run 'configure' command first.
Building source dist for Project-0.1.0.0...
cabal: does not exist
在使用 "cabal sdist" 之前,我使用了以下命令:
- cabal 初始化
- cabal 沙箱初始化
- cabal 安装-j
每个命令都成功,除了 cabal sdist。 cabal 安装仅给出以下警告:
D:\Development\School\AFP\Assignments\Practice\Exercise\Project>cabal install -j
Resolving dependencies...
In order, the following will be installed:
Project-0.1.0.0 (reinstall)
Warning: Note that reinstalls are always dangerous. Continuing anyway...
Notice: installing into a sandbox located at
D:\Development\School\AFP\Assignments\Practice\Exercise\Project\.cabal-sandbox
Configuring Project-0.1.0.0...
Building Project-0.1.0.0...
Installed Project-0.1.0.0
这是我的 Project.cabal 文件:
-- Initial Project.cabal generated by cabal init. For further
-- documentation, see http://haskell.org/cabal/users-guide/
-- Initial Project.cabal generated by cabal init. For further
-- documentation, see http://haskell.org/cabal/users-guide/
name: Project
version: 0.1.0.0
-- synopsis:
description: Education
license: NONE
-- license-file:
-- author:
-- maintainer:
-- copyright:
-- category:
build-type: Simple
extra-source-files: File6, File5, File4, File3, File2
cabal-version: >=1.10
library
exposed-modules: File1
-- other-modules:
-- other-extensions:
build-depends: base >=4.8 && <4.9, QuickCheck >=2.8 && <2.9
hs-source-dirs: src
default-language: Haskell2010
我试过google,但找不到好的解决方案。我使用以下版本:
Cabal 版本:1.22.4.0
Haskell版本:7.10.2
如果您需要更多信息,请询问。
我对 sdist
一无所知,但问题很明显:您已将 'NONE' 指定为您的 cabal 文件中的许可证,但 sdist
选项。 configure
、build
和 init
不关心特定的许可证,但 sdist
显然关心。
有关详细信息,我在 google 中搜索 "cabal sdist" 并找到了 this。
This [cabal sdist
] has the advantage that Cabal will do a bit more checking, and ensure that the tarball has the structure that HackageDB expects.
HackageDB 可能需要一个有效的许可证,因此 "NONE" 是不允许的。
问题是 cabal 无法在 extra-source-files 中找到文件。我以为我不必添加 haskell 文件的扩展名,但这是必需的。
我还有一个问题。 extra-source-files 没有使用 hs-source-dirs,所以我不得不在文件前面显式地写 "src/"。
今天我在笔记本电脑上安装了 windows 8.1 和 haskell。我正在尝试构建自己的 haskell 库,但是当我尝试使用 cabal sdist 时出现错误。这是错误:
D:\Development\School\AFP\Assignments\Practice\Exercise\Project>cabal sdist
Distribution quality errors:
'license: NONE' is not a recognised license. The known licenses are: GPL,
GPL-2, GPL-3, LGPL, LGPL-2.1, LGPL-3, AGPL, AGPL-3, BSD2, BSD3, MIT, ISC,
MPL-2.0, Apache, Apache-2.0, PublicDomain, AllRightsReserved, OtherLicense
Distribution quality warnings:
No 'category' field.
No 'maintainer' field.
No 'synopsis' field.
A 'license-file' is not specified.
When distributing packages it is encouraged to specify source control
information in the .cabal file using one or more 'source-repository' sections.
See the Cabal user guide for details.
Note: the public hackage server would reject this package.
Warning: Cannot run preprocessors. Run 'configure' command first.
Building source dist for Project-0.1.0.0...
cabal: does not exist
在使用 "cabal sdist" 之前,我使用了以下命令:
- cabal 初始化
- cabal 沙箱初始化
- cabal 安装-j
每个命令都成功,除了 cabal sdist。 cabal 安装仅给出以下警告:
D:\Development\School\AFP\Assignments\Practice\Exercise\Project>cabal install -j
Resolving dependencies...
In order, the following will be installed:
Project-0.1.0.0 (reinstall)
Warning: Note that reinstalls are always dangerous. Continuing anyway...
Notice: installing into a sandbox located at
D:\Development\School\AFP\Assignments\Practice\Exercise\Project\.cabal-sandbox
Configuring Project-0.1.0.0...
Building Project-0.1.0.0...
Installed Project-0.1.0.0
这是我的 Project.cabal 文件:
-- Initial Project.cabal generated by cabal init. For further
-- documentation, see http://haskell.org/cabal/users-guide/
-- Initial Project.cabal generated by cabal init. For further
-- documentation, see http://haskell.org/cabal/users-guide/
name: Project
version: 0.1.0.0
-- synopsis:
description: Education
license: NONE
-- license-file:
-- author:
-- maintainer:
-- copyright:
-- category:
build-type: Simple
extra-source-files: File6, File5, File4, File3, File2
cabal-version: >=1.10
library
exposed-modules: File1
-- other-modules:
-- other-extensions:
build-depends: base >=4.8 && <4.9, QuickCheck >=2.8 && <2.9
hs-source-dirs: src
default-language: Haskell2010
我试过google,但找不到好的解决方案。我使用以下版本:
Cabal 版本:1.22.4.0
Haskell版本:7.10.2
如果您需要更多信息,请询问。
我对 sdist
一无所知,但问题很明显:您已将 'NONE' 指定为您的 cabal 文件中的许可证,但 sdist
选项。 configure
、build
和 init
不关心特定的许可证,但 sdist
显然关心。
有关详细信息,我在 google 中搜索 "cabal sdist" 并找到了 this。
This [
cabal sdist
] has the advantage that Cabal will do a bit more checking, and ensure that the tarball has the structure that HackageDB expects.
HackageDB 可能需要一个有效的许可证,因此 "NONE" 是不允许的。
问题是 cabal 无法在 extra-source-files 中找到文件。我以为我不必添加 haskell 文件的扩展名,但这是必需的。
我还有一个问题。 extra-source-files 没有使用 hs-source-dirs,所以我不得不在文件前面显式地写 "src/"。