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

Add python-fontmake #3128

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

taotieren
Copy link
Contributor

No description provided.

Copy link
Member

@Y7n05h Y7n05h left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

下面这些依赖不在官方源或 archlinuxcn 源里。缺失相关依赖,因此无法完成打包。

error: target not found: python-fontmath
error: target not found: python-glyphslib
error: target not found: python-ttfautohint-py
error: target not found: python-ufo2ft
error: target not found: python-compreffor
error: target not found: python-defcon
error: target not found: python-mutatormath
error: target not found: python-skia-pathops

@taotieren
Copy link
Contributor Author

下面这些依赖不在官方源或 archlinuxcn 源里。缺失相关依赖,因此无法完成打包。

error: target not found: python-fontmath
error: target not found: python-glyphslib
error: target not found: python-ttfautohint-py
error: target not found: python-ufo2ft
error: target not found: python-compreffor
error: target not found: python-defcon
error: target not found: python-mutatormath
error: target not found: python-skia-pathops

好的,晚点抽空补齐这些包。

@taotieren taotieren force-pushed the python-fontmake-git branch 3 times, most recently from be42d62 to 543e4c6 Compare January 29, 2023 15:58
@taotieren
Copy link
Contributor Author

taotieren commented Jan 30, 2023

待续。后满还有一些包需要补齐。。。。。。

@Y7n05h 需要的依赖包补齐了,可以帮忙检查下吗?没问题的话帮忙合并下,谢谢

@taotieren taotieren requested a review from Y7n05h January 30, 2023 14:00
@taotieren taotieren force-pushed the python-fontmake-git branch 2 times, most recently from 8d2da8d to d1fb112 Compare January 31, 2023 11:33
Copy link
Member

@Y7n05h Y7n05h left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

我目前只 review 了一部分。看起来有一些包,没法完成打包流程。这可能与你没有使用 devtools 来验证你的 PKGBUILD 有关。

请确保每一个 PKGBUILD 能通过 devtools 打包(需要安装 devtools-cn-git)。
在含有 PKGBUILD 的目录中执行 extra-x86_64-buildarchlinuxcn-x86_64-build 就好。如果需要使用一个源里面没有的包可以通过参数 -I PATH 把本地包传进去。

更新:
突然发现我把 -I 的用法没说清楚,可能产生了歧义。举例说明一下:

extra-x86_64-build -- -I ../libglibutil/libglibutil-1.0.67-1-x86_64.pkg.tar.zst -I ../libgbinder/libgbinder-1.1.31-1-x86_64.pkg.tar.zst

archlinuxcn/python-ufonormalizer-git/PKGBUILD Outdated Show resolved Hide resolved
archlinuxcn/python-ufonormalizer-git/PKGBUILD Outdated Show resolved Hide resolved
archlinuxcn/python-ttfautohint-py-git/PKGBUILD Outdated Show resolved Hide resolved
archlinuxcn/python-skia-pathops-git/PKGBUILD Outdated Show resolved Hide resolved
@taotieren
Copy link
Contributor Author

我目前只 review 了一部分。看起来有一些包,没法完成打包流程。这可能与你没有使用 devtools 来验证你的 PKGBUILD 有关。

请确保每一个 PKGBUILD 能通过 devtools 打包(需要安装 devtools-cn-git)。 在含有 PKGBUILD 的目录中执行 extra-x86_64-buildarchlinuxcn-x86_64-build 就好。如果需要使用一个源里面没有的包可以通过参数 -I PATH 把本地包传进去。

好的,我按这个方式重新测试下。

@taotieren taotieren force-pushed the python-fontmake-git branch 17 times, most recently from 4839d6d to 320ac63 Compare February 3, 2023 13:46
@Y7n05h
Copy link
Member

Y7n05h commented Feb 6, 2023

ci 没过我猜是因为 repo_depends 里面只能用 pkgname ,而不支持 provide 这种机制。

@hubutui
Copy link
Contributor

hubutui commented Feb 6, 2023

其实我前面就有说了,一般来说没有特殊需要的话,不用打 -git 包.即使打 -git 包,也不代表这个包依赖的那些包都要打 -git 包.

PS:真的佩服这毅力,这么多依赖包,是我的话干脆就不打了.

建议安装好 namcap,使用 devtools 打包最后会自动进行包的检查,注意查看这些提示,根据提示修改好再提交吧.不然这个 review 到啥时候啊.这里指出的问题基本上是每个包都要检查的,返工一次也很耗费精力的.

@Y7n05h
Copy link
Member

Y7n05h commented Feb 6, 2023

一般来说没有特殊需要的话,不用打 -git 包.即使打 -git 包,也不代表这个包依赖的那些包都要打 -git 包.

他可能误会了什么。#3141 (comment)
我猜他可能觉得非 -git 是被保留给官方仓库的。

PS:真的佩服这毅力,这么多依赖包,是我的话干脆就不打了.

同感。我当初也提及过替代方案。#3031 (comment)

@taotieren
Copy link
Contributor Author

taotieren commented Feb 6, 2023

其实我前面就有说了,一般来说没有特殊需要的话,不用打 -git 包.即使打 -git 包,也不代表这个包依赖的那些包都要打 -git 包.

PS:真的佩服这毅力,这么多依赖包,是我的话干脆就不打了.

建议安装好 namcap,使用 devtools 打包最后会自动进行包的检查,注意查看这些提示,根据提示修改好再提交吧.不然这个 review 到啥时候啊.这里指出的问题基本上是每个包都要检查的,返工一次也很耗费精力的.

现在疑惑的是用不用 -git 包呢?还是其他方式呢?但是用 -I *-git* 这种方式来编译是可以通过的。

@Y7n05h
Copy link
Member

Y7n05h commented Feb 6, 2023

现在疑惑的是用不用 -git 包呢?还是其他方式呢?

没看懂这句话在表达什么。
我们所说的不打 -git 包是指使用 git 仓库中的最新提交来打包。而是使用上游发布的版本来打包(包含 github release,git tag,pypi 等多种渠道)。

用 -I *-git* 这种方式来编译是可以通过的。

我们不是在表达你打的包无法完成构建。我们是在表达,在非 -git 包能满足需求的情况下,打包 -git 的包不是个好选择。

关于 -git 包的问题,你可以参考下仓库里的 yay-git 和 yay 的 PKGBUILD 的区别。

@hubutui
Copy link
Contributor

hubutui commented Feb 6, 2023

一般来说没有特殊需要的话,不用打 -git 包.即使打 -git 包,也不代表这个包依赖的那些包都要打 -git 包.

他可能误会了什么。#3141 (comment) 我猜他可能觉得非 -git 是被保留给官方仓库的。

没有这回事吧。官方是否收录某个包主要取决于有没有 TU 去添加这个包。

PS:真的佩服这毅力,这么多依赖包,是我的话干脆就不打了.

同感。我当初也提及过替代方案。#3031 (comment)

打这么多报就只是为了成功打那个字体包?字体包没有必要从源码编译吧,直接用二进制包就好了。参考一下官方仓库里的字体包如何打包的。

@taotieren taotieren force-pushed the python-fontmake-git branch 3 times, most recently from 454c176 to 56598e4 Compare February 7, 2023 13:58
@hubutui
Copy link
Contributor

hubutui commented Feb 7, 2023

具体文件 review 提到的问题都不是个例,请检查所有的文件看看是否有问题。

@taotieren
Copy link
Contributor Author

taotieren commented Feb 8, 2023

具体文件 review 提到的问题都不是个例,请检查所有的文件看看是否有问题。

现在改成 py 包了,获取最新 py 包部分帮忙看看,有没有问题,本地测试是通过的,

@hubutui
Copy link
Contributor

hubutui commented Feb 8, 2023

我前面具体写的修改意见,你是一个都没有改也没有解释啊。
本地测试我不知道你怎么测试的,请参考打包指南在一个干净的 chroot 环境打包测试。

@taotieren
Copy link
Contributor Author

我前面具体写的修改意见,你是一个都没有改也没有解释啊。 本地测试我不知道你怎么测试的,请参考打包指南在一个干净的 chroot 环境打包测试。

使用的是 extra-x86_64-build -- -I 的方式测试

@hubutui
Copy link
Contributor

hubutui commented Feb 9, 2023

你这一次性添加的包太多了.麻烦给个正确的打包顺序,我们才好检查测试.

@Y7n05h
Copy link
Member

Y7n05h commented Feb 9, 2023

建议把全部依赖已存在于源里的包全都拆到另一个 pr 里面去。

@hubutui
Copy link
Contributor

hubutui commented Feb 9, 2023

或者简单的一个 pr 添加一个包就好了嘛,按顺序来,加好一个再下一个.

@hubutui
Copy link
Contributor

hubutui commented Feb 9, 2023

至少有以下几项通用的需要修改的地方:

  1. 优先使用 PEP 517 的方式打包,参考文档,然后才是 legacy setuptools.
  2. 请保持代码的缩进对齐,统一好使用空格缩进.
  3. 确认局部变量 python_version 是已经定义的,参考文档
  4. 确认许可证的名字,以及这个许可证是否包含在 licenses 中,未包含的需要将其打包.
  5. 源码不是 git repo 的不需要执行 git submodule 命令啊.

@yan12125
Copy link
Member

yan12125 commented Feb 9, 2023

這些包有 circular dependency, lilac 沒辦法處理: python-booleanoperations -> python-fontpens -> python-fontparts -> python-booleanoperations. See: https://aur.archlinux.org/cgit/aur.git/tree/PKGBUILD?h=python-booleanoperations#n37

@hubutui
Copy link
Contributor

hubutui commented Feb 9, 2023

@yan12125 你是怎么看出来的啊。我看包太多了都不方便看了。

@yan12125
Copy link
Member

yan12125 commented Feb 9, 2023 via email

@Zenvie
Copy link
Contributor

Zenvie commented Sep 18, 2023

I have added the python-fontmake package to the repository, pull request can be closed. Check out #3467.

@Zenvie Zenvie closed this Sep 18, 2023
@Zenvie
Copy link
Contributor

Zenvie commented Oct 12, 2023

I don’t want to maintain this package anymore, because it has too many dependencies. If you want to continue maintaining it, I will reopen this pull request.

@Zenvie Zenvie reopened this Oct 12, 2023
Copy link
Contributor

@Zenvie Zenvie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The following Python packages, python-booleanoperations, python-defcon, python-fontmath, python-fontparts, python-fontpens, python-mutatormath and python-pyclipper, are available in the official repositories.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants