Changeset 6810bbb


Ignore:
Timestamp:
07/05/13 13:34:23 (13 months ago)
Author:
Kris Moore <kris@…>
Branches:
master, 9.2-release, releng/10.0, releng/10.0.1, releng/10.0.2
Children:
a32c256
Parents:
8534088 (diff), cc7dbf3 (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:
3 edited

Legend:

Unmodified
Added
Removed
  • src-qt4/EasyPBI/mainGUI.cpp

    r9bdcc26 rcc7dbf3  
    163163} 
    164164 
    165 bool MainGUI::isValidPort(QString pPath){ 
     165bool MainGUI::isValidPort(QString pPath, bool allowOverride){ 
    166166  bool ok = FALSE; 
    167167  if( QFile::exists(pPath) && QFile::exists(pPath+"/Makefile") && QFile::exists(pPath+"/distinfo") ){ 
    168168    ok = TRUE; 
     169  } 
     170  //Display a warning message 
     171  if(allowOverride){ 
     172    ok = (QMessageBox::Apply == QMessageBox::warning(this,tr("EasyPBI: Invalid Port"), tr("The directory selected does not appear to be a valid FreeBSD port. \n\n Do you wish to continue using it anyway?"), QMessageBox::Apply | QMessageBox::Cancel, QMessageBox::Cancel) );  
     173  }else{ 
     174    QMessageBox::warning(this,tr("EasyPBI: Invalid Port"), tr("The directory selected is not a valid FreeBSD port. Please select a port directory which contains the appropriate Makefile and distinfo.")); 
    169175  } 
    170176  return ok; 
     
    545551  //Check if the port is valid 
    546552  if( !isValidPort(portSel) ){ 
    547     QMessageBox::warning(this,tr("EasyPBI: Invalid Port"), tr("The directory selected is not a valid FreeBSD port. Please select a port directory which contains the appropriate Makefile and distinfo.")); 
    548553    return; 
    549554  } 
     
    622627  if(portSel.isEmpty()){return;} //action cancelled or closed    
    623628  //Check if the port is valid 
    624   if( !isValidPort(portSel) ){ 
    625     QMessageBox::warning(this,tr("EasyPBI: Invalid Port"), tr("The directory selected is not a valid FreeBSD port. Please select a port directory which contains the appropriate Makefile and distinfo files.")); 
     629  if( !isValidPort(portSel,TRUE) ){ 
    626630    return; 
    627631  } 
     
    649653  if(portSel.isEmpty()){return;} //action cancelled or closed    
    650654  //Check if the port is valid 
    651   if( !isValidPort(portSel) ){ 
    652     QMessageBox::warning(this,tr("EasyPBI: Invalid Port"), tr("The directory selected is not a valid FreeBSD port. Please select a port directory which contains the appropriate Makefile and distinfo files.")); 
     655  if( !isValidPort(portSel,TRUE) ){ 
    653656    return; 
    654657  } 
     
    12341237  QStringList contents = ui->text_scripts_edit->toPlainText().split("\n"); 
    12351238  //get the current file 
    1236   QString filename = currentModule->path() + "/scripts/"+ui->list_scripts_file->currentText(); 
     1239  QString dir = currentModule->path() + "/scripts/"; 
     1240  bool ok = ModBuild::createDir(dir); //make sure the scripts directory exists 
     1241  QString filename = ui->list_scripts_file->currentText(); 
    12371242  //Save the file 
    1238   bool ok = ModBuild::createFile(filename,contents); 
     1243  ok = ModBuild::createFile(dir+filename,contents); 
    12391244  //display a warning if error 
    12401245  if(!ok){ 
  • src-qt4/EasyPBI/mainGUI.h

    re177abf rcc7dbf3  
    111111 
    112112    void SetupDefaults(); 
    113     bool isValidPort(QString); 
     113    bool isValidPort(QString, bool allowOverride = FALSE); 
    114114    void checkMime(); 
    115115 
  • src-sh/pbi-manager/pbi-manager

    r9788f38 r8534088  
    53495349        if [ -n "$PBI_ADD_ALTVER" ] ; then _rVer=$PBI_ADD_ALTVER ; fi 
    53505350 
    5351  
    53525351        check_pbi_update "$_rtar" "nodisplay" \ 
    53535352         "$_rtar" "$_rVer" \ 
    53545353         "$FBSDMAJOR" "$_rArch" "${PBI_ADDREPO_ID}" 
    53555354        if [ "$?" != "0" ] ; then  
    5356                 exit_err "Could not find \"$_rtar\" in any indexes"  
     5355                # If we are on amd64, do a fallback check to i386 for this PBI 
     5356                # This catches apps like wine / skype and others 
     5357                if [ "$_rArch" = "amd64" ] ; then 
     5358                        _rArch="i386" 
     5359                        check_pbi_update "$_rtar" "nodisplay" \ 
     5360                        "$_rtar" "$_rVer" \ 
     5361                        "$FBSDMAJOR" "$_rArch" "${PBI_ADDREPO_ID}" 
     5362                        if [ "$?" != "0" ] ; then  
     5363                                exit_err "Could not find \"$_rtar\" in any indexes"  
     5364                        fi 
     5365                else 
     5366                        exit_err "Could not find \"$_rtar\" in any indexes"  
     5367                fi 
    53575368        fi 
    53585369 
Note: See TracChangeset for help on using the changeset viewer.