Commit a674a79f authored by Edlira Nano's avatar Edlira Nano
Browse files

debuged SCHEMA LOCATION when run from src/masschroq (without make install)

git-svn-id: https://subversion.renater.fr/masschroq/trunk@2255 e4b6dbb4-9209-464b-83f7-6257456c460c
parent 7961e187
......@@ -26,6 +26,7 @@ SET (MASSCHROQ_LIB_SOVERSION "1")
SET (MASSCHROQ_SCHEMA_VERSION "1.1")
SET (MASSCHROQ_SCHEMA_FILE "masschroq-${MASSCHROQ_SCHEMA_VERSION}.xsd")
SET (MASSCHROQ_XSD_LOCATION_DIR "${masschroq_SOURCE_DIR}/doc/schema")
SET (masschroq_BINARY_DIR "bin")
#SET (CMAKE_INSTALL_SO_NO_EXE "0")
......@@ -58,8 +59,8 @@ if (NOT CMAKE_INSTALL_PREFIX)
SET (CMAKE_INSTALL_PREFIX /usr/local)
endif (NOT CMAKE_INSTALL_PREFIX)
#SET(CMAKE_BUILD_TYPE "Release")
SET(CMAKE_BUILD_TYPE "RelWithDebInfo")
SET(CMAKE_BUILD_TYPE "Release")
#SET(CMAKE_BUILD_TYPE "RelWithDebInfo")
#SET( CMAKE_BUILD_TYPE "Debug")
IF(CMAKE_BUILD_TYPE MATCHES "Release")
......@@ -77,15 +78,15 @@ ENDIF( CMAKE_BUILD_TYPE MATCHES "RelWithDebInfo" )
IF (WIN32)
SET(MASSCHROQ_XSD_DIR "${CMAKE_INSTALL_PREFIX}")
SET(MASSCHROQ_XSD "${MASSCHROQ_XSD_DIR}/${MASSCHROQ_SCHEMA_FILE}")
SET(MASSCHROQ_XSD_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}")
SET(MASSCHROQ_XSD "${MASSCHROQ_XSD_INSTALL_DIR}/${MASSCHROQ_SCHEMA_FILE}")
#SET(CMAKE_CXX_FLAGS_RELEASE "-O2 -DNDEBUG")
ELSE (WIN32)
SET(CMAKE_CXX_FLAGS_DEBUG "-O3 -g -Wall")
SET(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O3 -g -Wall")
SET (CMAKE_CXX_FLAGS_RELEASE "-s ${CMAKE_CXX_FLAGS_RELEASE}")
SET(MASSCHROQ_XSD_DIR "${CMAKE_INSTALL_PREFIX}/share/xml/schema")
SET(MASSCHROQ_XSD "${MASSCHROQ_XSD_DIR}/${MASSCHROQ_SCHEMA_FILE}")
SET(MASSCHROQ_XSD_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/share/xml/schema")
SET(MASSCHROQ_XSD "${MASSCHROQ_XSD_INSTALL_DIR}/${MASSCHROQ_SCHEMA_FILE}")
ENDIF (WIN32)
......@@ -195,7 +196,7 @@ INCLUDE(CPack)
add_subdirectory (src)
#INSTALL library libmasschroq is in the src/CMakeLists file
INSTALL(PROGRAMS src/masschroq DESTINATION bin)
INSTALL(FILES doc/schema/${MASSCHROQ_SCHEMA_FILE} DESTINATION share/xml/schema)
INSTALL(FILES ${MASSCHROQ_XSD_LOCATION_DIR}/${MASSCHROQ_SCHEMA_FILE} DESTINATION share/xml/schema)
#INSTALL(FILES doc/man1/masschroq.1.gz DESTINATION share/man/man1)
#INSTALL(FILES doc/manual/masschroq_manual.pdf DESTINATION share/doc/masschroq)
#INSTALL(FILES doc/debian/changelog DESTINATION share/doc/masschroq)
......
......@@ -5,6 +5,7 @@
#cmakedefine MASSCHROQ_XSD "@MASSCHROQ_XSD@"
#cmakedefine MASSCHROQ_SCHEMA_VERSION "@MASSCHROQ_SCHEMA_VERSION@"
#cmakedefine MASSCHROQ_SCHEMA_FILE "@MASSCHROQ_SCHEMA_FILE@"
#cmakedefine MASSCHROQ_XSD_LOCATION_DIR "@MASSCHROQ_XSD_LOCATION_DIR@"
#define QT_V_4_5 0x040500
#define QT_V_4_6 0x040600
......
......@@ -42,11 +42,11 @@ FilterBackgroundWidget::create_parameters() {
QLabel * median_label = new QLabel("Median filtering half window");
QSpinBox * median_box = new QSpinBox;
connect(median_box, SIGNAL(valueChanged(int)),
this, SLOT(setMedianHalfWindow(int)));
median_box->setMaximum(20);
median_box->setWrapping(true);
median_box->setSingleStep(1);
connect(median_box, SIGNAL(valueChanged(int)),
this, SLOT(setMedianHalfWindow(int)));
median_box->setValue(5);
layout1->addWidget(median_label, 0, 0);
layout1->addWidget(median_box, 0, 1);
......@@ -57,11 +57,11 @@ FilterBackgroundWidget::create_parameters() {
QLabel * minmax_label = new QLabel("MinMax filtering half window");
QSpinBox * minmax_box = new QSpinBox;
connect(minmax_box, SIGNAL(valueChanged(int)),
this, SLOT(setMinMaxHalfWindow(int)));
minmax_box->setMaximum(20);
minmax_box->setWrapping(true);
minmax_box->setSingleStep(1);
connect(minmax_box, SIGNAL(valueChanged(int)),
this, SLOT(setMinMaxHalfWindow(int)));
median_box->setValue(5);
layout2->addWidget(minmax_label, 1, 0);
layout2->addWidget(minmax_box, 1, 1);
......
......@@ -26,15 +26,15 @@ XicSelectionWidget::XicSelectionWidget(QWidget * parent)
create_xic_range_group();
create_mz_group();
QPushButton * extractButton = new QPushButton(tr("&Extract"));
extractButton->setDefault(true);
_button_box = new QDialogButtonBox(Qt::Vertical);
_button_box->addButton(extractButton, QDialogButtonBox::AcceptRole);
_button_box->addButton(QDialogButtonBox::Cancel);
//QPushButton * extractButton = new QPushButton(tr("&Extract"));
//extractButton->setDefault(true);
//_button_box = new QDialogButtonBox(Qt::Vertical);
//_button_box->addButton(extractButton, QDialogButtonBox::AcceptRole);
//_button_box->addButton(QDialogButtonBox::Cancel);
connect(_button_box, SIGNAL(accepted()), this, SLOT(extractXic()));
connect(_button_box, SIGNAL(rejected()), this, SLOT(cancel()));
//connect(_button_box, SIGNAL(accepted()), this, SLOT(extractXic()));
// connect(_button_box, SIGNAL(rejected()), this, SLOT(cancel()));
QVBoxLayout * mainLayout = new QVBoxLayout;
mainLayout->addWidget(_mz_group);
......
......@@ -65,12 +65,6 @@ MassChroq::getBeginDateTime() {
return begin_date_time;
}
void
MassChroq::setMasschroqDir(const QString & masschroq_dir_path) {
_masschroq_dir_path = masschroq_dir_path;
}
MassChroq::MassChroq() {
qDebug() << "MassChroq::MassChroq begin";
_output_stream = new QTextStream(stdout, QIODevice::WriteOnly);
......@@ -153,8 +147,8 @@ MassChroq::validateXmlFile() {
QFile schema_file(MASSCHROQ_XSD);
if ( !QFile::exists(MASSCHROQ_XSD) ) {
QString schema_current = _masschroq_dir_path;
schema_current.append(MASSCHROQ_SCHEMA_FILE);
QString schema_current(MASSCHROQ_XSD_LOCATION_DIR);
schema_current.append("/").append(MASSCHROQ_SCHEMA_FILE);
if (QFile::exists(schema_current)) {
schema_file.setFileName(schema_current);
} else {
......
......@@ -153,8 +153,6 @@ public:
QuantificationMethod * findQuantificationMethod(const QString & method_id) const;
void debriefing();
void setMasschroqDir(const QString & masschroq_dir_path);
protected:
......@@ -181,8 +179,6 @@ public:
std::map<QString, const Protein *> _p_proteins;
QString _masschroq_dir_path;
};
#endif /* MASS_CHROQ_H_ */
......@@ -48,8 +48,6 @@ int main(int argc, char **argv) {
QCoreApplication app(argc, argv);
QLocale::setDefault(QLocale::system());
const QDateTime dt_begin = QDateTime::currentDateTime();
const QString masschroq_dir_path(QCoreApplication::applicationDirPath());
QStringList arguments = app.arguments();
QString fileName;
......@@ -131,8 +129,6 @@ int main(int argc, char **argv) {
MassChroq mass_chroq_engine;
try {
mass_chroq_engine.setMasschroqDir(masschroq_dir_path);
//mass_chroq_engine.setReporter(mass_chroq_logs);
mass_chroq_engine.setXmlFilename(fileName);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment