Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do i ignore/unmark certain ports?

Tags:

macports

I would like to know how to either ignore upgrading certain ports or unmark them as "outdated".

This is motivated by certain ports failing to upgrade, while I wish to upgrade all the rest. I know about sudo port install -n, which allows one to install a port without upgrading port dependencies, as in the case of mongodb requiring an older (not the current) version of theboost libraries, but this is not applicable here.

For example:

$ sudo port list outdated
gdb                            @7.5            devel/gdb
py27-scikits-image             @0.7.1          python/py-scikits-image

As [email protected] fails to update, I would just like to upgrade the others, ie. py27-scikits-image, without going thru the whole sudo port list outdated | awk '{print $1}' | grep -v gdb | xargs sudo port upgrade pipeline.

Much appreciated.

like image 959
evandrix Avatar asked Nov 16 '25 11:11

evandrix


1 Answers

I would advise to create a local portfile for gdb with a lower version number.

  1. Create a local portfile repository: howto
  2. Copy the gdb portfile directory (a directory called "gdb" containing the file "Portfile" and directory "files") into your local portfile repository
  3. Change the version number in the portfile to e.g. 0.0
  4. Run portindex in your local portfile repository

The local portfile overrides the one downloaded from the default port repository. The low version number makes macports think your version of gdb is up to date.

I hope this can help.

BTW: you can do sudo port upgrade outdated and not gdb

like image 84
Vortexfive Avatar answered Nov 18 '25 20:11

Vortexfive



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!