Index: Portfile
===================================================================
--- Portfile	(revision 99128)
+++ Portfile	(working copy)
@@ -105,15 +105,15 @@
     if {![info exists startupitem.install]} {
         set startupitem.install yes
     }
-    if { ${startupitem.install} != "no" } {
+    if { ${startupitem.install} != "no" && ${startupitem_type} != "none" } {
         xinstall -d -m 755 ${destroot}${startup_root}/Library/LaunchAgents
         ln -s ${prefix}/Library/LaunchAgents/org.macports.kdecache.plist ${destroot}${startup_root}/Library/LaunchAgents
     }
 }
 
 post-activate {
-    if { ![variant_isset no_root] } {
-        file attributes ${prefix}/Library/LaunchAgents/org.macports.kdecache.plist -owner root -group wheel 
+    if { ![variant_isset no_root] && ${startupitem_type} != "none" && ${startupitem.install} != "no" } {
+        file attributes ${prefix}/Library/LaunchAgents/org.macports.kdecache.plist -owner root -group wheel
     }
 }
 
