summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnu Mittal <anu22mittal@gmail.com>2015-02-07 12:40:15 (GMT)
committerAnu Mittal <anu22mittal@gmail.com>2015-02-09 14:20:42 (GMT)
commitc3b298e1a51f1a9dac668248166ef59bbd1d8d33 (patch)
tree28056f382fc8e76bfd8fac05c157a754f281d551
parentce9292edb8ab9cbaddfe3f47ab783165fb4cfdeb (diff)
Porting :KalziumConfigureChecks.cmake and plasmoid/applet
-rw-r--r--KalziumConfigureChecks.cmake39
-rw-r--r--plasmoid/applet/psePlasmoid/CMakeLists.txt30
2 files changed, 44 insertions, 25 deletions
diff --git a/KalziumConfigureChecks.cmake b/KalziumConfigureChecks.cmake
index e3197ac..65ba760 100644
--- a/KalziumConfigureChecks.cmake
+++ b/KalziumConfigureChecks.cmake
@@ -1,21 +1,24 @@
include(CheckIncludeFiles)
include(CheckFunctionExists)
-macro_optional_find_package(OCaml)
-macro_optional_find_package(Libfacile)
-macro_optional_find_package(OpenBabel2)
-macro_optional_find_package(Eigen3)
-macro_optional_find_package(Avogadro 1.0.0 NO_MODULE)
+find_package(OCaml)
+find_package(Libfacile)
+find_package(OpenBabel2)
+find_package(Eigen3)
+find_package(Avogadro 1.0.0 NO_MODULE)
find_package(PkgConfig)
pkg_check_modules(CHEMICAL_MIME_DATA chemical-mime-data)
-
+include(CheckIncludeFiles)
check_include_files(ieeefp.h HAVE_IEEEFP_H)
-
-macro_bool_to_01(LIBFACILE_FOUND HAVE_FACILE)
-macro_bool_to_01(OPENBABEL2_FOUND HAVE_OPENBABEL2)
-macro_bool_to_01(EIGEN3_FOUND HAVE_EIGEN)
-macro_bool_to_01(Avogadro_FOUND HAVE_AVOGADRO)
+set(HAVE_FACILE ${LIBFACILE_FOUND})
+set(HAVE_OPENBABEL2 ${OPENBABEL2_FOUND})
+set(HAVE_EIGEN ${EIGEN3_FOUND})
+set(HAVE_AVOGADRO ${Avogadro_FOUND})
+#macro_bool_to_01(LIBFACILE_FOUND HAVE_FACILE)
+#macro_bool_to_01(OPENBABEL2_FOUND HAVE_OPENBABEL2)
+#macro_bool_to_01(EIGEN3_FOUND HAVE_EIGEN)
+#macro_bool_to_01(Avogadro_FOUND HAVE_AVOGADRO)
# at the end, output the configuration
configure_file(
@@ -23,10 +26,10 @@ configure_file(
${CMAKE_CURRENT_BINARY_DIR}/config-kalzium.h
)
-macro_log_feature(OCAML_FOUND "OCaml" "OCaml is needed by Kalzium for the Equation Solver" "http://caml.inria.fr/" FALSE "" "")
-macro_log_feature(LIBFACILE_FOUND "LibFacile" "libfacile is needed by Kalzium for the Equation Solver." "http://www.recherche.enac.fr/log/facile/" FALSE "" "")
-macro_log_feature(OPENBABEL2_FOUND "OpenBabel2" "OpenBabel is needed by Kalzium for the 3D-molecule viewer" "http://openbabel.sourceforge.net/" FALSE "2.2" "")
-macro_log_feature(EIGEN3_FOUND "Eigen3" "A generic C++ template library for dense and sparse matrices" "http://eigen.tuxfamily.org" FALSE "3.0.0" "")
-macro_log_feature(Avogadro_FOUND "Avogadro" "Advanced molecular editor" "http://avogadro.openmolecules.net" FALSE "1.0" "")
-macro_log_feature(CHEMICAL_MIME_DATA_FOUND "Chemical mime data" "Needed to open CML molecules from the file manager" "http://chemical-mime.sourceforge.net/" FALSE "" "")
-
+#set_package_properties(OCAML_FOUND "OCaml" "http://caml.inria.fr/" FALSE "OCaml is needed by Kalzium for the Equation Solver")
+#(OCAML_FOUND "OCaml" "OCaml is needed by Kalzium for the Equation Solver" "http://caml.inria.fr/" FALSE "" "")
+#set_package_properties(LIBFACILE_FOUND "LibFacile" "libfacile is needed by Kalzium for the Equation Solver." "http://www.recherche.enac.fr/log/facile/" FALSE "" "")
+#set_package_properties(OPENBABEL2_FOUND "OpenBabel2" "OpenBabel is needed by Kalzium for the 3D-molecule viewer" "http://openbabel.sourceforge.net/" FALSE "2.2" "")
+#set_package_properties(EIGEN3_FOUND "Eigen3" "A generic C++ template library for dense and sparse matrices" "http://eigen.tuxfamily.org" FALSE "3.0.0" "")
+#set_package_properties(Avogadro_FOUND "Avogadro" "Advanced molecular editor" "http://avogadro.openmolecules.net" FALSE "1.0" "")
+#set_package_properties(CHEMICAL_MIME_DATA_FOUND "Chemical mime data" "Needed to open CML molecules from the file manager" "http://chemical-mime.sourceforge.net/" FALSE "" "") \ No newline at end of file
diff --git a/plasmoid/applet/psePlasmoid/CMakeLists.txt b/plasmoid/applet/psePlasmoid/CMakeLists.txt
index 7f2d736..c837bfd 100644
--- a/plasmoid/applet/psePlasmoid/CMakeLists.txt
+++ b/plasmoid/applet/psePlasmoid/CMakeLists.txt
@@ -1,7 +1,23 @@
-MESSAGE(STATUS "Kalzium Plasma widget 'bodr' disabled, needs porting")
-#add_subdirectory(bodr)
-add_subdirectory(didyouknow)
-add_subdirectory(nuclearPlasmoid)
-add_subdirectory(concentrationPlasmoid)
-add_subdirectory(gasPlasmoid)
-add_subdirectory(psePlasmoid)
+include_directories(
+ ${CMAKE_SOURCE_DIR}
+ ${CMAKE_BINARY_DIR}
+ ${KDE4_INCLUDES}
+ ${CMAKE_SOURCE_DIR}/libkdeedu/libscience
+ )
+
+# We add our source code here
+set(periodic_SRCS Molmasscalculator.cpp Periodictable.cpp)
+
+qt5_wrap_ui(periodic_SRCS Molmassconfig.ui)
+
+# Now make sure all files get to the right place
+add_library(plasma_applet_molmassCalculator ${periodic_SRCS})
+
+target_link_libraries(plasma_applet_molmassCalculator
+ KF5::Plasma KF5::WidgetAddons science)
+
+install(TARGETS plasma_applet_molmassCalculator
+ DESTINATION ${PLUGIN_INSTALL_DIR})
+
+install(FILES plasma-applet-Molmasscalculator.desktop
+ DESTINATION ${SERVICES_INSTALL_DIR})