pkgsrc-Users archive

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

Re: changing the default ghostscript type



Hello Greg,

Greg Troxel writes:
> [...]
> 2) Currently, ghostscript has a fixed dependency on the chosen type; the
> code is basically:
>
>   PKG_OPTIONS_VAR=		PKG_OPTIONS.gs_type
>   PKG_OPTIONS_OPTIONAL_GROUPS=	ghostscript
>   PKG_OPTIONS_GROUP.ghostscript+=	ghostscript-agpl ghostscript-gpl
>   PKG_SUGGESTED_OPTIONS+=		ghostscript-gpl
>
>   .if !empty(PKG_OPTIONS:Mghostscript-agpl)
>   DEPENDS+=	ghostscript-agpl-[0-9]*:../../print/ghostscript-agpl
>   .elif !empty(PKG_OPTIONS:Mghostscript-gpl)
>   DEPENDS+=	ghostscript-gpl-[0-9]*:../../print/ghostscript-gpl
>   .endif
>
> I am contemplating changing the code so that in the absence of an
> installed ghostscript package, the package will depend on the chosen
> version, but that if either version is installed, the installed version
> will be used.  With this setup, I believe that if someone installs
> ghostcript-gpl (overding the vulnerable check), then ghostscript, even
> with the new default option, will happiliy depend on it, that that
> person can easily have what they want, even with binary packages.
> [...]

I think that's probably okay for packages that needs ghostscript
via DEPENDS (e.g. if they just need `gs') but I am not sure if it
can be problematic for packages that includes
print/ghostscript/buildlink3.mk.

Apart that the PKG_OPTIONS.gs_type will then not reflect the actual
reality and leads to possible surprises (okay, `pkg_info
ghostscript-{a,}gpl' will then reveal the truth :)).

For these reasons I think it would be better to avoid `step 2'.


Thank you!


PS: In my limited experience switching back and forth from
ghostscript-{a,}gpl by adjusting PKG_OPTIONS.gs_type and
`pkg_delete -f ghostscript-{a,}gpl' worked.  But I consider this switch
back and forth without possible revbump and rebuild of all dependent
ghostscript packages something worth the `-f' flag as `OK, there
can be some problems in doing that!'. :)


Home | Main Index | Thread Index | Old Index