- wxMessageBox(_T("Done !"),_T("creaNewProject"),
- wxOK | wxICON_INFORMATION);
+ wxMessageBox(_T("New Project created !"),_T("creaNewProject"),
+ wxOK | wxICON_INFORMATION);
+
+ // Create a Package at the same time. JPR
+
+ //execGUICreateNewPackage += "/../../../share/bbtk/bbs/toolsbbtk/appli/GUICreatePackage.bbs";
+ //system(execGUICreateNewPackage.c_str());
+
+ // or, better, new trick :
+ // bbCreatePackage nomDirectory nomPackage author Description
+
+//EED char *author = getenv("USER");
+ char *author = (char*) (authorWX.mb_str()) ;
+ std::string nomDirectory = crea::wx2std(dir) + "/" + crea::wx2std(name);
+ std::string nomPackageDirectory = nomDirectory + "/" + "bbtk_" + crea::wx2std(name) + "_PKG";
+
+ std::string bbCreatePackage("bbCreatePackage ");
+ bbCreatePackage += nomDirectory + " " + crea::wx2std(name) + " " + author + " " + crea::wx2std(description);
+ system (bbCreatePackage.c_str());
+
+ std::string add;
+ add = "echo 'ADD_SUBDIRECTORY(bbtk_" + crea::wx2std(name) + "_PKG)' >> " + nomDirectory + "/CMakeLists.txt";
+ //std::cout << add << std::endl;
+ system(add.c_str());
+