[pacman-dev] makepkg creates bad .FILELIST
This patch[1] breaks the creation of .FILELIST, directories don't end with / so pacman treats them as files and does conflict checks and bails out because /usr (or any other dir) has already been installed by another package. Posted a patch[2] to my ready_to_pull branch. [1] http://projects.archlinux.org/git/?p=pacman.git;a=commit;h=430a19c604e474e90... [2] http://repo.or.cz/w/pacman.git?a=shortlog;h=ready_to_pull Andrew
2007/6/23, Andrew Fyfe <andrew@neptune-one.net>:
This patch[1] breaks the creation of .FILELIST, directories don't end with / so pacman treats them as files and does conflict checks and bails out because /usr (or any other dir) has already been installed by another package.
Posted a patch[2] to my ready_to_pull branch.
[1] http://projects.archlinux.org/git/?p=pacman.git;a=commit;h=430a19c604e474e90... [2] http://repo.or.cz/w/pacman.git?a=shortlog;h=ready_to_pull
Please remove from ready_to_pull branch and replace with: http://bugs.archlinux.org/task/7485#comment17443 -- Roman Kyrylych (Роман Кирилич)
Roman Kyrylych wrote:
2007/6/23, Andrew Fyfe <andrew@neptune-one.net>:
This patch[1] breaks the creation of .FILELIST, directories don't end with / so pacman treats them as files and does conflict checks and bails out because /usr (or any other dir) has already been installed by another package.
Posted a patch[2] to my ready_to_pull branch.
[1] http://projects.archlinux.org/git/?p=pacman.git;a=commit;h=430a19c604e474e90... [2] http://repo.or.cz/w/pacman.git?a=shortlog;h=ready_to_pull
Please remove from ready_to_pull branch and replace with: http://bugs.archlinux.org/task/7485#comment17443
Done :) Andrew
On 6/27/07, Andrew Fyfe <andrew@neptune-one.net> wrote:
Roman Kyrylych wrote:
2007/6/23, Andrew Fyfe <andrew@neptune-one.net>:
This patch[1] breaks the creation of .FILELIST, directories don't end with / so pacman treats them as files and does conflict checks and bails out because /usr (or any other dir) has already been installed by another package.
Posted a patch[2] to my ready_to_pull branch.
[1] http://projects.archlinux.org/git/?p=pacman.git;a=commit;h=430a19c604e474e90... [2] http://repo.or.cz/w/pacman.git?a=shortlog;h=ready_to_pull
Please remove from ready_to_pull branch and replace with: http://bugs.archlinux.org/task/7485#comment17443
Done :)
Andrew
Apparently my comment there was missed? I wasn't fixing the directory issue, I was fixing the prefix issue. We should stay with the old format and leave './' off of there. Your fix doesn't work for that, although I'm sure we can do something to fix it. We also don't want the current directory entry './'. -Dan
2007/6/27, Dan McGee <dpmcgee@gmail.com>:
On 6/27/07, Andrew Fyfe <andrew@neptune-one.net> wrote:
Roman Kyrylych wrote:
2007/6/23, Andrew Fyfe <andrew@neptune-one.net>:
This patch[1] breaks the creation of .FILELIST, directories don't end with / so pacman treats them as files and does conflict checks and bails out because /usr (or any other dir) has already been installed by another package.
Posted a patch[2] to my ready_to_pull branch.
[1] http://projects.archlinux.org/git/?p=pacman.git;a=commit;h=430a19c604e474e90... [2] http://repo.or.cz/w/pacman.git?a=shortlog;h=ready_to_pull
Please remove from ready_to_pull branch and replace with: http://bugs.archlinux.org/task/7485#comment17443
Done :)
Andrew
Apparently my comment there was missed?
I wasn't fixing the directory issue, I was fixing the prefix issue. We should stay with the old format and leave './' off of there. Your fix doesn't work for that, although I'm sure we can do something to fix it. We also don't want the current directory entry './'.
What is wrong here? [rk@server foobar]$ find * -exec ls -dp {} \; | sort test1/ test1/test01 test1/test02 test1/test03 test2/ test2/.test I think you've got my first comment notification by e-mail, which was worng (without *), then I quickly corrected it. BTW, Andrew, you've missed sort ;-) - find * 2>/dev/null | sort >.FILELIST + find * -exec ls -dp {} \; 2>/dev/null >.FILELIST should be + find * -exec ls -dp {} \; 2>/dev/null | sort >.FILELIST -- Roman Kyrylych (Роман Кирилич)
On 6/27/07, Roman Kyrylych <roman.kyrylych@gmail.com> wrote:
2007/6/27, Dan McGee <dpmcgee@gmail.com>:
On 6/27/07, Andrew Fyfe <andrew@neptune-one.net> wrote:
Roman Kyrylych wrote:
2007/6/23, Andrew Fyfe <andrew@neptune-one.net>:
This patch[1] breaks the creation of .FILELIST, directories don't end with / so pacman treats them as files and does conflict checks and bails out because /usr (or any other dir) has already been installed by another package.
Posted a patch[2] to my ready_to_pull branch.
[1] http://projects.archlinux.org/git/?p=pacman.git;a=commit;h=430a19c604e474e90... [2] http://repo.or.cz/w/pacman.git?a=shortlog;h=ready_to_pull
Please remove from ready_to_pull branch and replace with: http://bugs.archlinux.org/task/7485#comment17443
Done :)
Andrew
Apparently my comment there was missed?
I wasn't fixing the directory issue, I was fixing the prefix issue. We should stay with the old format and leave './' off of there. Your fix doesn't work for that, although I'm sure we can do something to fix it. We also don't want the current directory entry './'.
What is wrong here?
[rk@server foobar]$ find * -exec ls -dp {} \; | sort test1/ test1/test01 test1/test02 test1/test03 test2/ test2/.test
I think you've got my first comment notification by e-mail, which was worng (without *), then I quickly corrected it.
BTW, Andrew, you've missed sort ;-)
- find * 2>/dev/null | sort >.FILELIST + find * -exec ls -dp {} \; 2>/dev/null >.FILELIST
should be + find * -exec ls -dp {} \; 2>/dev/null | sort >.FILELIST
Did you see how slow this is, by the way? We have to fork an ls call for every single file in the tree. There has to be a better way. The only thing that ls call is doing is adding a trailing slash to directories. At this point, Andrew's solution is a whole lot faster, and it wasn't all that bad. -Dan
Dan McGee wrote:
On 6/27/07, Roman Kyrylych <roman.kyrylych@gmail.com> wrote:
2007/6/27, Dan McGee <dpmcgee@gmail.com>:
On 6/27/07, Andrew Fyfe <andrew@neptune-one.net> wrote:
Roman Kyrylych wrote:
2007/6/23, Andrew Fyfe <andrew@neptune-one.net>:
This patch[1] breaks the creation of .FILELIST, directories don't end with / so pacman treats them as files and does conflict checks and bails out because /usr (or any other dir) has already been installed by another package.
Posted a patch[2] to my ready_to_pull branch.
[1] http://projects.archlinux.org/git/?p=pacman.git;a=commit;h=430a19c604e474e90... [2] http://repo.or.cz/w/pacman.git?a=shortlog;h=ready_to_pull
Please remove from ready_to_pull branch and replace with: http://bugs.archlinux.org/task/7485#comment17443
Done :)
Andrew Apparently my comment there was missed?
I wasn't fixing the directory issue, I was fixing the prefix issue. We should stay with the old format and leave './' off of there. Your fix doesn't work for that, although I'm sure we can do something to fix it. We also don't want the current directory entry './'.
What is wrong here?
[rk@server foobar]$ find * -exec ls -dp {} \; | sort test1/ test1/test01 test1/test02 test1/test03 test2/ test2/.test
I think you've got my first comment notification by e-mail, which was worng (without *), then I quickly corrected it.
BTW, Andrew, you've missed sort ;-)
- find * 2>/dev/null | sort >.FILELIST + find * -exec ls -dp {} \; 2>/dev/null >.FILELIST
should be + find * -exec ls -dp {} \; 2>/dev/null | sort >.FILELIST
Did you see how slow this is, by the way? We have to fork an ls call for every single file in the tree. There has to be a better way. The only thing that ls call is doing is adding a trailing slash to directories. At this point, Andrew's solution is a whole lot faster, and it wasn't all that bad.
-Dan
_______________________________________________ pacman-dev mailing list pacman-dev@archlinux.org http://archlinux.org/mailman/listinfo/pacman-dev
tar -cvf /dev/null * real 0m0.043s user 0m0.012s sys 0m0.028s find * -exec ls -dp {} \; 2>/dev/null real 0m4.552s user 0m1.648s sys 0m2.872s find \( -type d -printf '%P/\n' \) , \( ! -type d -printf '%P\n' \) real 0m0.017s user 0m0.012s sys 0m0.004s The last one suggested here (http://bugs.archlinux.org/task/7485#comment17450) seems to be the best, I've updated the patch. Andrew
On 6/27/07, Andrew Fyfe <andrew@neptune-one.net> wrote:
tar -cvf /dev/null * real 0m0.043s user 0m0.012s sys 0m0.028s
find * -exec ls -dp {} \; 2>/dev/null real 0m4.552s user 0m1.648s sys 0m2.872s
find \( -type d -printf '%P/\n' \) , \( ! -type d -printf '%P\n' \) real 0m0.017s user 0m0.012s sys 0m0.004s
The last one suggested here (http://bugs.archlinux.org/task/7485#comment17450) seems to be the best, I've updated the patch.
Here we go- I like it. Looks a bit more elegant, at least. Can we get some people to test this before I pull it in for sure? It seems to work for me. Does anyone have objections to me pulling Andrew's bsdtar branch? http://repo.or.cz/w/pacman.git?a=shortlog;h=bsdtar I think reducing the number of programs we use will make makepkg a bit cleaner, and this does remove the unrecognized dependency on unzip that we have. bsdtar is pretty fast as well. -Dan
2007/6/27, Andrew Fyfe <andrew@neptune-one.net>:
find \( -type d -printf '%P/\n' \) , \( ! -type d -printf '%P\n' \) real 0m0.017s user 0m0.012s sys 0m0.004s
The last one suggested here (http://bugs.archlinux.org/task/7485#comment17450) seems to be the best, I've updated the patch.
Well, I noticed there was still at least one difference with this command : http://bugs.archlinux.org/task/7485#comment17451 Isn't it better with -mindepth 1 ? About the commit there : http://repo.or.cz/w/pacman.git?a=commitdiff;h=ba2107ccb7ead1da5c1de47a155ef4... any reason why the exit 1 was dropped ? About this one : http://repo.or.cz/w/pacman.git?a=commitdiff;h=86bcb91eddee03952f6455a1295c5d... I think it's interesting to know Aurelien wanted to take the opposite road. See item 5 there : http://www.archlinux.org/pipermail/pacman-dev/2006-March/005700.html I'm not criticizing anything myself though, I've personally no opinion on this, just found it funny ;) Also, that's just based on the description of the commit, I didn't really look at the changes. Maybe it's because of the added arch suffix that complicated things?
Xavier wrote:
2007/6/27, Andrew Fyfe <andrew@neptune-one.net>:
find \( -type d -printf '%P/\n' \) , \( ! -type d -printf '%P\n' \) real 0m0.017s user 0m0.012s sys 0m0.004s
The last one suggested here (http://bugs.archlinux.org/task/7485#comment17450) seems to be the best, I've updated the patch.
Well, I noticed there was still at least one difference with this command : http://bugs.archlinux.org/task/7485#comment17451
Isn't it better with -mindepth 1 ? Fixed :)
About the commit there : http://repo.or.cz/w/pacman.git?a=commitdiff;h=ba2107ccb7ead1da5c1de47a155ef4... any reason why the exit 1 was dropped ?
Fixed :)
About this one : http://repo.or.cz/w/pacman.git?a=commitdiff;h=86bcb91eddee03952f6455a1295c5d... I think it's interesting to know Aurelien wanted to take the opposite road. See item 5 there : http://www.archlinux.org/pipermail/pacman-dev/2006-March/005700.html I'm not criticizing anything myself though, I've personally no opinion on this, just found it funny ;) Also, that's just based on the description of the commit, I didn't really look at the changes. Maybe it's because of the added arch suffix that complicated things?
Parsing package file names are a pain in the ass. Because we've currently got to package file name formats it's difficult to parse the correct information from the name. So I changed it to read the info straight from the packages .PKGINFO file. bsdtar is fast enough as long as .PKGINFO appears near the start of the package file. Andrew
On 6/27/07, Xavier <shiningxc@gmail.com> wrote:
About this one : http://repo.or.cz/w/pacman.git?a=commitdiff;h=86bcb91eddee03952f6455a1295c5d... I think it's interesting to know Aurelien wanted to take the opposite road. See item 5 there : http://www.archlinux.org/pipermail/pacman-dev/2006-March/005700.html I'm not criticizing anything myself though, I've personally no opinion on this, just found it funny ;) Also, that's just based on the description of the commit, I didn't really look at the changes. Maybe it's because of the added arch suffix that complicated things?
That is a premature optimization. We already got rid of a lot of them because it just complicates things. There is no reason that the name and version should not be in the package. -Dan
2007/6/27, Dan McGee <dpmcgee@gmail.com>:
That is a premature optimization. We already got rid of a lot of them because it just complicates things. There is no reason that the name and version should not be in the package.
Ok fair enough. Anyway, I think the most interesting thing in this area is unifying .PKGINFO and depends/desc files, but there is already a thread about it :)
participants (4)
-
Andrew Fyfe
-
Dan McGee
-
Roman Kyrylych
-
Xavier