pkgsrc-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: What happened to make show-depends-options ?



from Roland Illig:

> Ah, now we're getting closer. 

> The show-depends-options target is defined in mk/misc/show.mk and runs
> the following commands:
        
    ${_DEPENDS_WALK_CMD} ${PKGPATH}
>     ${RECURSIVE_MAKE} ${MAKEFLAGS} show-options
        
> The _DEPENDS_WALK_CMD command runs depends-depth-first.awk to process
> all dependencies. And in there we find:
        
>     cmd = "if " TEST " -d " dir "; then cd " dir " && "
>           MAKE " show-depends-pkgpaths DEPENDS_TYPE=\""
>           depends_type "\"; fi"

> The two error messages "cd: bad substitution" and "test: stopped" look
> closely related to that command. Probably the list of directories is
> somewhat broken.

> To see why, you should edit the depends-depth-first.awk program to show
> the actual command that it runs and what these commands output. To do
> this, add 2 lines around the "while (cmd |" line, so that the code looks
> like this:

>     cmd = "if " TEST " -d " dir "; then ...
>     print("running command: " cmd) > "/dev/stderr"
>     while (cmd | getline depends_pkgpath) {
>         print("found dependency: " depends_pkgpath) > "/dev/stderr"

> Now when you now "make show-depends-options" again, the error messages
> will still appear. But around them, you will see the actual command that
> is causing it. Some of these commands will have special characters (like
> parentheses, ampersands, asterisks) in them, and these special
> characters produce the error messages.

> The next step will then be to look where these special characters come
> from. To analyze this further, I first need to see what these special
> characters are. So please run:

>     make show-depends-options

> and post the output of that command again. This will provide further clues.

I finally found depends-depth-first.awk, you should have told me where it was to save me from looking for the needle in the haystack.



Result of "make show-depends-options" in /BETA1/pkgsrc/print/hplip was

running command: if test -d /BETA1/pkgsrc//usr/packages/All; then cd /BETA1/pkgsrc//usr/packages/All && /usr/bin/make show-depends-pkgpaths DEPENDS_TYPE="all"; fi
make[1]: don't know how to make show-depends-pkgpaths. Stop
found dependency: 
found dependency: make[1]: stopped in /BETA1/pkgsrc/usr/packages/All
running command: if test -d /BETA1/pkgsrc/; then cd /BETA1/pkgsrc/ && /usr/bin/make show-depends-pkgpaths DEPENDS_TYPE="all"; fi
make[1]: don't know how to make show-depends-pkgpaths. Stop
found dependency: 
found dependency: make[1]: stopped in /BETA1/pkgsrc
running command: if test -d /BETA1/pkgsrc/make[1]: stopped in /BETA1/pkgsrc; then cd /BETA1/pkgsrc/make[1]: stopped in /BETA1/pkgsrc && /usr/bin/make show-depends-pkgpaths DEPENDS_TYPE="all"; fi
test: stopped: unexpected operator
running command: if test -d /BETA1/pkgsrc/make[1]: stopped in /BETA1/pkgsrc/usr/packages/All; then cd /BETA1/pkgsrc/make[1]: stopped in /BETA1/pkgsrc/usr/packages/All && /usr/bin/make show-depends-pkgpaths DEPENDS_TYPE="all"; fi
===> Options for make[1]: stopped in /BETA1/pkgsrc
cd: bad substitution
===> Options for 
test: stopped: unexpected operator
make[1]: don't know how to make show-options. Stop

make[1]: stopped in /BETA1/pkgsrc
*** Error code 2

Stop.
make: stopped in /BETA1/pkgsrc/print/hplip


Tom



Home | Main Index | Thread Index | Old Index