[opensuse-packaging] filtering requires and provides
Hi, I want to provide my own script for finding provides and requirements. The issue I have with RPM's automatic stuff is that a certain package provides libraries which are not really accessible from other applications (or shouldn't be accessed) since they are not for system-wide usage but only for that single application. So what I found as kind of documentation about it is the following: Source91: filter-requires.sh %define _use_internal_dependency_generator 0 %define __find_requires %{SOURCE91} where filter-requires.sh basically would create the list for RPM. That seems not to work (at least with openSUSE 10.3 within the buildservice). So what I wonder is: - does SUSE's rpm know about _use_internal_dependency_generator at all? - can I instead just use "AutoReqProv: no" and keep the rest of the above example? Thanks, Wolfgang --------------------------------------------------------------------- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-packaging+help@opensuse.org
Wolfgang Rosenauer wrote:
Source91: filter-requires.sh %define _use_internal_dependency_generator 0 %define __find_requires %{SOURCE91}
where filter-requires.sh basically would create the list for RPM.
That seems not to work (at least with openSUSE 10.3 within the buildservice).
Well, it should work :). What does your filter-requires.sh script look like? It should expect a list of filenames on stdin and output a list of dependencies on stdout.
So what I wonder is: - does SUSE's rpm know about _use_internal_dependency_generator at all?
SUSE's rpm has _use_internal_dependency_generator already set to 0, so this part is OK.
- can I instead just use "AutoReqProv: no" and keep the rest of the above example?
I'm not sure, but I think that with this line rpm won't generate _any_ automatic dependencies for the package. Michal --------------------------------------------------------------------- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-packaging+help@opensuse.org
Michal Marek wrote:
Wolfgang Rosenauer wrote:
Source91: filter-requires.sh %define _use_internal_dependency_generator 0 %define __find_requires %{SOURCE91}
where filter-requires.sh basically would create the list for RPM.
That seems not to work (at least with openSUSE 10.3 within the buildservice).
Well, it should work :). What does your filter-requires.sh script look like? It should expect a list of filenames on stdin and output a list of dependencies on stdout.
Probably there was another issue in the spec. Trying again now with that fixed and see if it works now: #!/bin/sh # Finds requirements provided outside of the current file set filelist=`sed "s/[]['\"*?{}]/\\\\\&/g"` provides=`echo $filelist | /usr/lib/rpm/find-provides` { for f in $filelist ; do echo $f | /usr/lib/rpm/find-requires | while read req ; do found=0 for p in $provides ; do if [ "$req" = "$p" ]; then found=1 fi done if [ "$found" = "0" ]; then echo $req fi done done } | sort -u Wolfgang --------------------------------------------------------------------- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-packaging+help@opensuse.org
participants (2)
-
Michal Marek
-
Wolfgang Rosenauer