Lazarus中文社区

 找回密码
 立即注册(注册审核可向QQ群索取)

QQ登录

只需一步,快速开始

Lazarus IDE and 组件 下载地址版权申明
查看: 4978|回复: 1

如何安装ZEOSlib

[复制链接]

该用户从未签到

发表于 2010-11-15 12:08:46 | 显示全部楼层 |阅读模式
安装ZEOSLib 6.6.6 到 Lazaurs 0.9.28, 总是提示:zcore.pas(10,5) Fatal: Can't find unit ZClasses used by zcore
! 是按官方说明的方法安装的:
Installation
------------

1.  Components / Open Package File (*.lpk)
2.  Open Components.Lpk
4.  Click Install
5.  Click Yes when asked if you want to rebuild Lazarus

That's it!

---------------------------------------------------------------------------------------------------------------------------------------------
unit zcore;

interface

uses
    ZClasses, ZCollections, ZCompatibility, ZExpression, ZExprParser,
  ZExprToken, ZFunctions, ZMatchPattern, ZMessages, ZSysUtils, ZTokenizer,
  ZVariables, ZVariant;

implementation

end.  

官方还这么说,请问要做何解?

If you receive the error "Cannot find unit ZClasses" or something similar, then you need to carefully check the case of the filenames in your Zeos source distribution.

Even if the cases match exactly, the autogenerated package source file can generate the wrong case name in the uses clause (Lazarus 0.9.18), i.e.:

{ This file was automatically created by Lazarus. Do not edit!
  This source is only used to compile and install the package.
}
unit Zcore;
interface
uses
  Zclasses, Zcollections, Zcompatibility, Zexprparser, Zexprtoken, Zexpression,
  Zfunctions, Zmatchpattern, Zmessages, Zsysutils, Ztokenizer, Zvariables,
  Zvariant;
implementation
end.

Notice that Lazarus has named the unit ZClasses Zclasses, resulting in a naming conflict. Presumably this is a bug in Lazarus, not the Zeos packages. One way around this is to rename all the zeos source files to lowercase. Trawl through each subdirectory under src/ and execute this command in a bash window:

rename -v 'y/A-Z/a-z/' *

Then, in Lazarus, reopen the package (.lpk) and fix the filename cases by clicking on "More..."/"Fix Files Case"
The package should compile now.
回复

使用道具 举报

该用户从未签到

发表于 2010-11-16 15:50:02 | 显示全部楼层
安装ZEOSLib 6.6.6 到 Lazaurs 0.9.28.3 或 0.9.29 是没有问题的
回复 支持 反对

使用道具 举报

*滑块验证:

本版积分规则

QQ|手机版|小黑屋|Lazarus中国|Lazarus中文社区 ( 鄂ICP备16006501号-1 )

GMT+8, 2025-5-2 22:14 , Processed in 0.029461 second(s), 11 queries , Redis On.

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表