2 # will build package, skipping %prep and %build stage
8 # do %install and rpm package, skips %clean
9 # SPECS$ ./repackage.sh kdelibs.spec
11 # after that is done you could try only package creation (as %clean was
12 # skipped), for adjusting %files lists:
13 # SPECS$ ./repackage.sh kdelibs.spec -bb
15 # See also: SPECS/compile.sh
18 # - make builder to understand -bi and use builder for short-circuit
23 # use gz payload as time is what we need here, not compress ratio
25 # we use %__ldconfig variable to test are we on rpm 4.4.9
26 # on 4.4.9 we should not redefine %clean to contain %clean, and redefine %__spec_clean_body instead
27 # on 4.4.2 we must redefine %clean to contain %clean
30 ${TARGET:+--target $TARGET} \
32 --define 'clean %%%{!?__ldconfig:clean}%{?__ldconfig:check} \
34 --define 'check %%check \
36 --define '_source_payload w9.gzdio' \
37 --define '_binary_payload w9.gzdio' \
38 --define '__spec_install_pre %___build_pre' \
39 --define '__spec_clean_body %{nil}' \
45 while [ $# -gt 0 ]; do
47 --target|--with|--without)
64 eval rpm-specdump $a || echo >&2 $?
67 tmp=$(specdump "$@" | awk '$2 == "_target_cpu" {print $3}')
72 # just create the rpm's if -bb is somewhere in the args
73 if [[ *$@* != *-bb* ]]; then