how to start with macports ?

Thomas De Contes d.l.tDeContes at free.fr
Tue Sep 18 19:29:28 PDT 2007


Le 16 sept. 07 à 19:09, Emmanuel Hainry a écrit :

> Citando Thomas De Contes :
>>
>> well, i try to make a script which can install or upgrade, without  
>> i have
>> to tell what to do
>>
>>
>> now i have :
>>
>> port install subversion
>> port install mpfr
>> port install gtk2
>> port -u upgrade outdated
>>
>> i though that in case of install, "port -u upgrade outdated" would do
>> nothing, and in case of upgrade, "port install ..." would do nothing,
>> but it's not like that
>>
>>
>> how can i make my script ?
>>
>> or is it possible to modify "port install ..." to make it either do
>> nothing, or upgrade properly ?
>>
>
> port consists in phases that are executed one after another. install
> needs configure, build, destroot to have been done. And those do not
> conflict with the fact a previous version of the port already exist.
> Which means that when you do port install foo, what is done is done
> (only the last (activate) phase was erroneous). deactivate and  
> activate
> are just some copying or moving of the built program.
>
>
> If you want to upgrade a port, you can first deactivate it then  
> install
> it. The thing upgrade does better is that it remembers the variants  
> you
> had selected. If doing a "port installed foo" before deciding if you
> need to upgrade or install foo is too much a burden, you can try
> something like:
>
> port deactivate foo ; port install foo
>
> which will issue an error if foo was not installed and will then  
> proceed
> to install it, and just install a new version if it is already  
> installed.

well, i try to understand all what you say,
but i need help from those who have experience, because i don't kow  
how to make tests, for this sort of thing



i tried :


port deactivate active || exit

port install subversion || exit
port install mpfr || exit
port install gtk2 || exit

port -u upgrade outdated || exit


+ port deactivate active
--->  Deactivating Xft2 2.1.12_0
--->  Deactivating apr 1.2.11_0
--->  Deactivating apr-util 1.2.10_0
--->  Deactivating atk 1.20.0_0
--->  Deactivating cairo 1.4.10_0
--->  Deactivating db44 4.4.20_1+darwin_8
--->  Deactivating expat 2.0.1_0
--->  Deactivating fontconfig 2.4.2_0+macosx
--->  Deactivating freetype 2.3.5_0
--->  Deactivating gettext 0.16.1_0
--->  Deactivating glib2 2.14.0_0
--->  Deactivating gmp 4.2.1_4+test
--->  Deactivating gtk2 2.12.0_0
--->  Deactivating jpeg 6b_2
--->  Deactivating libiconv 1.11_6+darwin_8
--->  Deactivating libpng 1.2.20_0+darwin_8
--->  Deactivating mpfr 2.3.0_2+darwin_8
--->  Deactivating ncurses 5.6_0+darwin_8
--->  Deactivating ncursesw 5.6_0+darwin_8
--->  Deactivating neon 0.26.4_0
--->  Deactivating openssl 0.9.8e_0+darwin_8
--->  Deactivating pango 1.18.1_0
--->  Deactivating pkgconfig 0.22_0
--->  Deactivating readline 5.2.007_0
--->  Deactivating render 0.9_1
--->  Deactivating sqlite3 3.4.2_0+darwin_8
--->  Deactivating subversion 1.4.5_0
--->  Deactivating tiff 3.8.2_0+darwin_8
--->  Deactivating xorg-util-macros 1.1.5_0
--->  Deactivating xorg-xproto 7.0.11_0
--->  Deactivating xrender 0.9.0_1+darwin_8
--->  Deactivating zlib 1.2.3_1
+ port install subversion
--->  Activating subversion 1.4.5_0
--->  Cleaning subversion
+ port install mpfr
--->  Activating mpfr 2.3.0_2+darwin_8
--->  Cleaning mpfr
+ port install gtk2
--->  Activating gtk2 2.12.0_0
Error: Target org.macports.activate returned: shell command "gdk- 
pixbuf-query-loaders /Users/thomas/Documents/prgm/bin/autoinstall/ 
macports/lib/gtk-2.0/2.10.0/loaders/*.so > /Users/thomas/Documents/ 
prgm/bin/autoinstall/macports/etc/gtk-2.0/gdk-pixbuf.loaders"  
returned error 133
Command output: dyld: Library not loaded: /Users/thomas/Documents/ 
prgm/bin/autoinstall/macports/lib/libpango-1.0.0.dylib
   Referenced from: /Users/thomas/Documents/prgm/bin/autoinstall/ 
macports/bin/gdk-pixbuf-query-loaders
   Reason: image not found

Error: Status 1 encountered during processing.
+ exit


well, it seems that "port install foo" installs and activates all  
dependancies of foo if there is nothing,
but activates only foo, without its dependancies, if all is already  
installed but not activated

so, what do you thing about


port deactivate outdated || exit

port install subversion || exit
port install mpfr || exit
port install gtk2 || exit

port -u upgrade outdated || exit


?

and about


port -u upgrade outdated || exit

port install subversion || exit
port install mpfr || exit
port install gtk2 || exit


?



sorry, all, i forget every time to do "reply all" instead of "reply"

-- 
j'agis contre l'assistanat, je travaille dans une SCOP !





More information about the macports-users mailing list