Changeset e4f2841


Ignore:
Timestamp:
12/16/13 12:40:14 (9 months ago)
Author:
Ken Moore <ken@…>
Branches:
master, releng/10.0, releng/10.0.1, releng/10.0.2, releng/10.0.3
Children:
18af43e
Parents:
117b060 (diff), c8639a2 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge branch 'master' of github.com:pcbsd/pcbsd

Files:
1 deleted
6 edited

Legend:

Unmodified
Added
Removed
  • src-qt4/PCDM/rc.d/pcdm

    r1620346 rc8639a2  
    22 
    33# PROVIDE: pcdm 
    4 # REQUIRE: LOGIN cleanvar moused syscons 
     4# REQUIRE: LOGIN cleanvar moused syscons dbus 
    55# 
    66# Add the following to /etc/rc.conf to start PCDM at boot time: 
     
    2424pcdm_start() 
    2525{ 
     26  if ! checkyesno pcdm_enable ; then 
     27     return 0 
     28  fi 
     29  echo "Starting PCDM." 
     30 
    2631  ( 
    27     if ! checkyesno pcdm_enable ; then 
    28         return 0 
    29     fi 
    30     echo "Starting PCDM." 
     32    iter=0 
     33    while ! ps -axoargs | grep "^/usr/libexec/getty " | grep -qv grep >/dev/null 2>&1; do 
     34        if [ ${iter} -eq 60 ]; then 
     35            break 
     36        fi 
     37        sleep 1 
     38        iter=$(expr ${iter} + 1) 
     39    done 
     40    iter=0 
     41    while ! /usr/local/bin/lshal >/dev/null 2>&1 ; do 
     42        if [ ${iter} -eq 60 ]; then 
     43            break 
     44        fi 
     45        sleep 1 
     46        iter=$(expr ${iter} + 1) 
     47    done 
    3148 
    3249    #Start the PCDM login daemon 
  • src-qt4/pc-pkgmanager/mainWin.cpp

    r8c6e16d r9809371  
    357357  qDebug() << cmd + " " + flags.join(" "); 
    358358 
     359  system("rm /tmp/pkg-fifo 2>/dev/null"); 
     360 
    359361  // Create the EVENT_PIPE 
    360362  if ( wDir.isEmpty() ) 
    361     system("mkfifo /tmp/pkg-fifo"); 
     363    system("mkfifo /tmp/pkg-fifo ; sleep 1"); 
    362364  else 
    363     system("mkfifo " + wDir.toLatin1() + "/tmp/pkg-fifo"); 
     365    system("mkfifo " + wDir.toLatin1() + "/tmp/pkg-fifo ; sleep 1"); 
    364366 
    365367  // Open and connect the EVENT_PIPE 
    366368  eP = new QProcess(); 
    367   connect( eP, SIGNAL(readyReadStandardOutput()), this, SLOT(slotReadEventPipe()) ); 
    368   eP->start(QString("tail"), QStringList() << "-f" << wDir + "/tmp/pkg-fifo"); 
    369   qDebug() << "Starting EVENT_PIPE" << wDir + "/tmp/pkg-fifo"; 
    370    
     369  eP->setProcessChannelMode(QProcess::MergedChannels); 
     370  connect( eP, SIGNAL(readyRead()), this, SLOT(slotReadEventPipe()) ); 
     371  connect( eP, SIGNAL(finished(int, QProcess::ExitStatus)), this, SLOT(slotReadEventPipe()) ); 
     372  eP->start(QString("cat"), QStringList() << "-u" << wDir + "/tmp/pkg-fifo"); 
     373  qDebug() << "Starting EVENT_PIPE"; 
     374  eP->waitForStarted(); 
     375 
    371376  // Setup the first process 
    372377  uProc = new QProcess(); 
    373378  QProcessEnvironment env = QProcessEnvironment::systemEnvironment(); 
    374379  env.insert("PCFETCHGUI", "YES"); 
    375  
    376   // KPM 12-12-2013 
    377   // EVENT_PIPE causes segfaults in pkgng 1.2.3 :( 
    378   // Re-enable this when its fixed upstream 
    379   //env.insert("EVENT_PIPE", "/tmp/pkg-fifo"); 
    380  
     380  env.insert("EVENT_PIPE", "/tmp/pkg-fifo"); 
    381381  uProc->setProcessEnvironment(env); 
    382382  uProc->setProcessChannelMode(QProcess::MergedChannels); 
     
    950950  pCmds.clear(); 
    951951 
     952  // Adding packages 
    952953  if ( ! pkgAddList.isEmpty() ) { 
     954 
     955    // Look for conflicts first 
     956    if ( wDir.isEmpty() ) 
     957      pCmds << "pc-pkg" << "check-conflict" << pkgAddList.join(" "); 
     958    else 
     959      pCmds << "chroot" << wDir << "pc-pkg" << "check-conflict" << pkgAddList.join(" "); 
     960    pkgCmdList << pCmds; 
     961    pCmds.clear(); 
     962 
     963    // Now spin up the install process 
    953964    if ( wDir.isEmpty() ) 
    954965      pCmds << "pc-pkg" << "install" << "-y" << pkgAddList.join(" "); 
    955966    else 
    956967      pCmds << "chroot" << wDir << "pc-pkg" << "install" << "-y" << pkgAddList.join(" "); 
     968 
    957969    pkgCmdList << pCmds; 
    958970  } 
     
    15051517{ 
    15061518   QString line, tmp, file, dl, tot; 
     1519   bool ok, ok2; 
    15071520 
    15081521   while (eP->canReadLine()) { 
    15091522     line = eP->readLine().simplified(); 
    1510      qDebug() << line; 
     1523     //qDebug() << line; 
    15111524 
    15121525     // KPM!! 
     
    15391552          dl = line.section(":", 2, 2).section(",", 0, 0); 
    15401553          tot = line.section(":", 3, 3).section("}", 0, 0); 
     1554          dl = dl.simplified(); 
     1555          tot = tot.simplified(); 
     1556 
     1557          dl.toLongLong(&ok); 
     1558          tot.toLongLong(&ok2); 
     1559          if ( ok && ok2) { 
     1560            progressUpdate->setRange(0, tot.toLongLong(&ok) / 1024); 
     1561            progressUpdate->setValue(dl.toLongLong(&ok) / 1024 ); 
     1562          } 
    15411563 
    15421564          // Set the status update 
    1543           textStatus->setText(tr("Downloading") + " " + file + " (" + dl + "/" + tot + ")" ); 
     1565          textStatus->setText(tr("Downloading") + " " + file + " (" + dl + " / " + tot + ")" ); 
    15441566     } 
    15451567 
    15461568   } // End of while canReadLine() 
    1547 } 
     1569 
     1570} 
  • src-sh/pc-metapkgmanager/pc-metapkgmanager

    r8506de1f r9809371  
    8181        fi 
    8282 
     83        # Don't need this anymore 
     84        unset EVENT_PIPE 
     85 
    8386        # Time to run pkgng and let it install packages! 
    8487        pkg install -yUf "$pkgName" 
     
    279282} 
    280283 
     284do_pkg_conflicts() 
     285{ 
     286   fullopts="`echo $@ | sed 's|check-conflict||g'`" 
     287 
     288   echo "install -FUy $fullopts" > /tmp/err 
     289   # Lets check for any conflicts doing this install 
     290   check_pkg_conflicts "install -FUy $fullopts" 
     291   exit $? 
     292} 
     293 
    281294intercept_pkg_dl() 
    282295{ 
    283    local count=0; 
    284    fullopts="$@" 
    285    op="$1" 
    286     
    287    # Make sure we insert some flags we need 
    288    while [ $# -gt 0 ]; do 
    289      if [ $count -gt 0 ] ; then 
    290         # If we are already using -n, we can skip downloading anything 
    291         if [ "$1" = "-n" ] ; then 
    292            pkg $fullopts 
    293            exit $? 
    294         fi 
    295         flags="$flags $1" 
    296      else 
    297         flags="-U -n" 
    298      fi 
    299      count=`expr $count + 1` 
    300      shift 
    301    done 
    302  
    303    # Lets check for any conflicts doing this install 
    304    check_pkg_conflicts "${op} -FUy $flags" 
    305    if [ $? -ne 0 ] ; then 
    306         exit 1 
    307    fi 
    308  
    309296   # Time to run pkgng and let it do its thing 
    310    pkg $fullopts  
     297   pkg $@ 
    311298   result=$? 
    312299 
     
    347334{ 
    348335   case $1 in 
    349  install|upgrade) intercept_pkg_dl ${@} ;; 
     336         install) intercept_pkg_dl ${@} ;; 
     337  check-conflict) do_pkg_conflicts ${@} ;; 
    350338         getfile) get_file_dl ${@} ;; 
    351339               *) pkg ${@}  
  • src-qt4/EasyPBI-devel/ModuleUtils.cpp

    r85e9308 r117b060  
    203203  return MOD; 
    204204} 
     205 
     206QString ModuleUtils::generatePbiBuildCmd(QString confDir, QString outDir, QString sigFile){ 
     207  QString cmd = "pbi_makeport";  
     208  if(confDir.isEmpty()){ qDebug() << "Warning: a module must be supplied to build a PBII"; return ""; } 
     209  if(!confDir.isEmpty()){ cmd.append(" -c "+confDir); } 
     210  if(!outDir.isEmpty()){ cmd.append(" -o "+outDir); } 
     211  if(!sigFile.isEmpty()){ cmd.append(" --sign "+sigFile); } 
     212  cmd.append(" --pkgbuild"); 
     213  return cmd; 
     214} 
  • src-qt4/EasyPBI-devel/ModuleUtils.h

    r85e9308 r117b060  
    3030        static void compressModule(QString modulePath); 
    3131        static PBIModule newModule(QString moduleDir, QString port, QString iconFile); 
     32        static QString generatePbiBuildCmd(QString confDir, QString outDir, QString sigFile); 
    3233 
    3334}; 
  • src-qt4/EasyPBI-devel/mainGUI.cpp

    rcea69ea r117b060  
    12251225  QString outdir = settings->value("pbidir"); 
    12261226  if (outdir.isEmpty() ){gostatus=FALSE;} 
    1227   //QString sigfile = "";ui->linePBIDigSigFile->text(); //this one can be empty 
    12281227  QString modDir = MODULE.basepath(); 
    12291228  if(modDir.isEmpty()){gostatus=FALSE;} 
     
    12341233   
    12351234  //Generate the PBI build command 
    1236   QString cmd; 
    1237   // -- PBI from ports 
     1235  QString sigFile; 
     1236  if( settings->check("usesignature") && QFile::exists(settings->value("sigfile")) ){ sigFile = settings->value("sigfile"); } 
     1237  QString cmd = ModuleUtils::generatePbiBuildCmd(MODULE.basePath(), outdir, sigFile); 
     1238  /*// -- PBI from ports 
    12381239    //Check that the ports tree is available 
    12391240    if( !settings->check("isportsavailable") ){  
     
    12601261    } 
    12611262    if( settings->check("usesignature") && QFile::exists(settings->value("sigfile")) ){ cmd += " --sign " + settings->value("sigfile"); } 
    1262  
     1263  */ 
    12631264  //Display the command created in hte terminal 
    12641265  qDebug() << "Build PBI command created:"<<cmd; 
     
    12681269  QMessageBox verify(this); 
    12691270  verify.setText(tr("Are you sure you wish to start the PBI build?")); 
    1270   verify.setInformativeText(tr("This requires an active internet connection and administrator privileges. The time required to build a PBI varies depending upon system specifications and ports to be compiled.")); 
     1271  verify.setInformativeText(tr("This requires an active internet connection and administrator privileges.")); 
    12711272  verify.setStandardButtons(QMessageBox::Yes | QMessageBox::No); 
    12721273  verify.setDefaultButton(QMessageBox::Yes); 
Note: See TracChangeset for help on using the changeset viewer.