MacPort selfupdate using SVN

Jackson Isaac jacksonisaac2008 at gmail.com
Wed Mar 11 03:19:36 PDT 2015


On Wed, Mar 11, 2015 at 2:31 AM, Rainer Müller <raimue at macports.org> wrote:
> On 2015-03-10 15:48, Jackson Isaac wrote:
>> On Mon, Mar 9, 2015 at 5:03 PM, Ryan Schmidt <ryandesign at macports.org> wrote:
>>> On Mar 9, 2015, at 06:02, Jackson Isaac wrote:
>>>>
>>>> But when I try 'port -d sync', it says I need to run 'port
>>>> selfupdate'. My University network blocks rsync.
>>>
>>> selfupdate always uses rsync; it cannot be configured to use another method. If your network blocks rsync, then you cannot use the selfupdate command. Instead, use sync to sync your portfile definitions, and on the rare occasions when MacPorts base itself is updated, install it another way, for example by downloading the installer from our website.
>>
>> Here: http://trac.macports.org/wiki/howto/SyncingWithSVN
>> it says that when I run 'port -d sync' it will run 'svn update'
>
> That is correct.
>
>> But when I do 'port -d sync' it doesn't update the ports and asks me
>> to run 'port selfupdate' which uses rsync, which I do not want to as
>> the network blocks it.
>
> Hm, "doesn't update" is highly unspecific. How did you determine that it
> did not update? What was the output on terminal?

I meant that it doesn't run 'svn update' when I do sync. It just tries to
"Synchronizing local ports tree from
file:///opt/local/var/macports/sources/svn.macports.org/trunk/dports/"

The output of running sync with svn was the following:

"""
DEBUG: Copying /Users/JacksonIsaac/Library/Preferences/com.apple.dt.Xcode.plist
to /opt/local/var/macports/home/Library/Preferences
--->  Updating the ports tree
Synchronizing local ports tree from
file:///opt/local/var/macports/sources/svn.macports.org/trunk/dports/
Warning: port definitions are more than two weeks old, consider
updating them by running 'port selfupdate'.
Creating port index in
/opt/local/var/macports/sources/svn.macports.org/trunk/dports

Total number of ports parsed:    0
Ports successfully parsed:    0
Ports failed:            0
Up-to-date ports skipped:    0
"""

>
> I can only guess this was either about a missing port index or that your
> port definitions are more than two weeks old. In both cases it is
> hardcoded to say 'port selfupdate', since this is what users are
> supposed to use. In special cases such as yours when rsync is not
> available, you can use 'port sync' instead, after which these messages
> should not appear anymore.
>
> However, as Ryan said, when you use 'port sync', remember to update
> MacPorts itself manually from the disk image or by compiling from source.
>
> As a side note from a developer's point of view, we should get rid of
> rsync for selfupdate and fetch signed source tarballs over HTTP. Or
> probably even use the binary .pkg installers instead.
>

I tried using the http://trac.macports.org/wiki/howto/PortTreeTarball
method. For this it shows the following output:

"""
DEBUG: Copying /Users/JacksonIsaac/Library/Preferences/com.apple.dt.Xcode.plist
to /opt/local/var/macports/home/Library/Preferences
--->  Updating the ports tree
Synchronizing local ports tree from https://distfiles.macports.org/ports.tar.gz
Warning: Cannot check if https://distfiles.macports.org/ports.tar.gz
was updated, (Peer certificate cannot be authenticated with given CA
certificates)
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:--  0:00:01
--:--:--     0Error: Fetching
https://distfiles.macports.org/ports.tar.gz failed (SSL certificate
problem: Invalid certificate chain)
DEBUG: Synchronization of 1 source(s) failed
    while executing
"mportsync [array get global_options]"
port sync failed: Synchronization of 1 source(s) failed
"""

As a workaround I used http:// instead of https. So it would be better
if this is also mentioned in the wiki/PortTreeTarball. Can I update
the wiki for this?

> Rainer



-- 
Jackson Isaac
S6 B.Tech CSE
Amrita Vishwa Vidyapeetham
jacksonisaac.wordpress.com
Github/JacksonIsaac


More information about the macports-dev mailing list