Warning, /education/kstars/kstars/CMakeLists.txt is written in an unsupported language. File is not indexed.

0001 if(NOT APPLE) #This is not needed on MacOS, since the data directory and icons are now installed to the app bundle first using the code at the bottom
0002     add_subdirectory( data )
0003     add_subdirectory( icons )
0004 endif(NOT APPLE)
0005 
0006 add_subdirectory( htmesh )
0007 
0008 if (ANDROID AND CMAKE_TOOLCHAIN_FILE)
0009     include(${CMAKE_TOOLCHAIN_FILE})
0010 endif ()
0011 
0012 if (NOT ANDROID)
0013     find_package(ZLIB REQUIRED)
0014     include_directories(${ZLIB_INCLUDE_DIR})
0015     find_package(Threads REQUIRED)
0016 endif ()
0017 
0018 if(MSVC)
0019     add_definitions(-D_USE_MATH_DEFINES=1)
0020     add_definitions(-DNOMINMAX)
0021 endif()
0022 
0023 include(CheckCXXSymbolExists)
0024 check_cxx_symbol_exists(sincos "math.h" HAVE_SINCOS)
0025 if(HAVE_SINCOS)
0026     add_definitions(-DHAVE_SINCOS)
0027 endif()
0028 
0029 include_directories(
0030     ${kstars_SOURCE_DIR}/kstars
0031     ${kstars_SOURCE_DIR}/kstars/skyobjects
0032     ${kstars_SOURCE_DIR}/kstars/skycomponents
0033     ${kstars_SOURCE_DIR}/kstars/auxiliary
0034     ${kstars_SOURCE_DIR}/kstars/time
0035     ${kstars_SOURCE_DIR}/kstars/tools
0036     ${kstars_SOURCE_DIR}/kstars/catalogsdb
0037     ${kstars_SOURCE_DIR}/kstars/polyfills
0038     )
0039 
0040 if (INDI_FOUND)
0041     if(BUILD_KSTARS_LITE)
0042             set (fits_klite_SRCS
0043                 fitsviewer/fitsdata.cpp
0044                 )
0045             set (fits2_klite_SRCS
0046                 fitsviewer/bayer.c
0047                 fitsviewer/fpack.c
0048                 fitsviewer/fpackutil.c
0049                 )
0050                 include_directories(${CFITSIO_INCLUDE_DIR})
0051                 include_directories(${NOVA_INCLUDE_DIR})
0052 
0053             set (indi_klite_SRCS
0054                 indi/clientmanagerlite.cpp
0055                 indi/inditelescopelite.cpp
0056                 kstarslite/skyitems/skynodes/crosshairnode.cpp
0057                 kstarslite/skyitems/telescopesymbolsitem.cpp
0058             )
0059     endif ()
0060 
0061     set(indiui_SRCS
0062         indi/streamform.ui
0063         indi/drivermanager.ui
0064         indi/opsindi.ui
0065         indi/indihostconf.ui
0066         indi/customdrivers.ui
0067         #indi/telescopewizard.ui
0068     )
0069 
0070     set(indi_SRCS
0071         indi/drivermanager.cpp
0072         indi/servermanager.cpp
0073         indi/clientmanager.cpp
0074         indi/blobmanager.cpp
0075         indi/guimanager.cpp
0076         indi/driverinfo.cpp
0077         indi/deviceinfo.cpp
0078         indi/indidevice.cpp
0079         indi/indigroup.cpp
0080         indi/wsmedia.cpp
0081         indi/indiproperty.cpp
0082         indi/indielement.cpp
0083         indi/indistd.cpp
0084         indi/indilistener.cpp
0085         indi/indiconcretedevice.cpp
0086         indi/indiguider.cpp
0087         indi/indimount.cpp
0088         indi/indicamera.cpp
0089         indi/indicamerachip.cpp
0090         indi/indifocuser.cpp
0091         indi/indifilterwheel.cpp
0092         indi/indidome.cpp
0093         indi/indigps.cpp
0094         indi/indiweather.cpp
0095         indi/indidustcap.cpp
0096         indi/indilightbox.cpp
0097         indi/indiauxiliary.cpp
0098         indi/indidetector.cpp
0099         indi/indirotator.cpp
0100         indi/indiadaptiveoptics.cpp
0101         indi/indicorrelator.cpp
0102         indi/indispectrograph.cpp
0103         indi/indidbus.cpp
0104         indi/opsindi.cpp
0105         indi/streamwg.cpp
0106         indi/videowg.cpp
0107         indi/indiwebmanager.cpp
0108         indi/customdrivers.cpp
0109     )
0110 
0111     if (CFITSIO_FOUND)
0112         set(ekosui_SRCS
0113             ekos/opsekos.ui
0114             ekos/manager.ui
0115             ekos/manager/focusmanager.ui
0116             ekos/manager/guidemanager.ui
0117             ekos/profileeditor.ui
0118             ekos/profilewizard.ui
0119             # Analyze
0120             ekos/analyze/analyze.ui
0121             ekos/analyze/yaxistool.ui
0122             # Scheduler
0123             ekos/scheduler/scheduler.ui
0124             ekos/scheduler/mosaic.ui
0125             ekos/scheduler/framingassistant.ui
0126             # Capture
0127             ekos/capture/capture.ui
0128             ekos/capture/calibrationoptions.ui
0129             ekos/capture/capturepreviewwidget.ui
0130             ekos/capture/capturecountswidget.ui
0131             ekos/capture/captureprocessoverlay.ui
0132             ekos/capture/dslrinfo.ui
0133             ekos/capture/rotatorsettings.ui
0134             ekos/capture/customproperties.ui
0135             ekos/capture/scriptsmanager.ui
0136             ekos/capture/limits.ui
0137             # Align
0138             ekos/align/align.ui
0139             ekos/align/opsastrometry.ui
0140             ekos/align/opsprograms.ui
0141             ekos/align/opsalign.ui
0142             #ekos/align/opsastrometrycfg.ui
0143             ekos/align/opsastrometryindexfiles.ui
0144             ekos/align/manualrotator.ui
0145             ekos/align/mountmodel.ui
0146             ekos/align/polaralignmentassistant.ui
0147             ekos/align/polaralignwidget.ui
0148             #ekos/align/opsastap.ui
0149             # Focus
0150             ekos/focus/focus.ui
0151             # Mount
0152             ekos/mount/mount.ui
0153             ekos/mount/meridianflipstatuswidget.ui
0154             # Guide
0155             ekos/guide/guide.ui
0156             ekos/guide/guidestatewidget.ui
0157             ekos/guide/opscalibration.ui
0158             ekos/guide/opsguide.ui
0159             ekos/guide/opsdither.ui
0160             ekos/guide/opsgpg.ui
0161             ekos/guide/manualdither.ui
0162             ekos/observatory/observatory.ui
0163             #TODO remove from GIT
0164             #ekos/guide/guider.ui
0165             #ekos/guide/rcalibration.ui
0166             # Auxiliary
0167             ekos/auxiliary/filtersettings.ui
0168             ekos/auxiliary/opslogs.ui
0169             ekos/auxiliary/serialportassistant.ui
0170             ekos/auxiliary/stellarsolverprofileeditor.ui
0171             ekos/auxiliary/darklibrary.ui
0172             ekos/auxiliary/opticaltrains.ui
0173             ekos/auxiliary/ledstatuswidget.ui
0174             # Ekos Live
0175             ekos/ekoslive/ekoslivedialog.ui
0176             # INDI Hub
0177             ekos/indihub.ui
0178         )
0179 
0180         set(ekos_SRCS
0181             ekos/ekos.cpp
0182             ekos/profileeditor.cpp
0183             ekos/profilewizard.cpp
0184             ekos/profilescript.cpp
0185             ekos/profilescriptdialog.cpp
0186             ekos/qMDNS.cpp
0187             ekos/opsekos.cpp
0188 
0189             # Manager
0190             ekos/manager.cpp
0191             ekos/manager/focusmanager.cpp
0192             ekos/manager/guidemanager.cpp
0193             ekos/manager/meridianflipstate.cpp
0194 
0195             # Auxiliary
0196             ekos/auxiliary/darklibrary.cpp
0197             ekos/auxiliary/darkprocessor.cpp
0198             ekos/auxiliary/darkview.cpp
0199             ekos/auxiliary/defectmap.cpp
0200             ekos/auxiliary/opticaltrainmanager.cpp
0201             ekos/auxiliary/profilesettings.cpp
0202             ekos/auxiliary/opticaltrainsettings.cpp
0203             ekos/auxiliary/filtermanager.cpp
0204             ekos/auxiliary/tabledelegate.cpp
0205             ekos/auxiliary/opslogs.cpp
0206             ekos/auxiliary/stellarsolverprofileeditor.cpp
0207             ekos/auxiliary/stellarsolverprofile.cpp
0208             ekos/auxiliary/solverutils.cpp
0209             ekos/auxiliary/serialportassistant.cpp
0210             ekos/auxiliary/portselector.cpp
0211             ekos/auxiliary/ledstatuswidget.cpp
0212 
0213             # Capture
0214             ekos/capture/capture.cpp
0215             ekos/capture/capturemodulestate.cpp
0216             ekos/capture/capturedeviceadaptor.cpp
0217             ekos/capture/capturepreviewwidget.cpp
0218             ekos/capture/capturecountswidget.cpp
0219             ekos/capture/captureprocessoverlay.cpp
0220             ekos/capture/refocusstate.cpp
0221             ekos/capture/sequencejob.cpp
0222             ekos/capture/sequencejobstate.cpp
0223             ekos/capture/dslrinfodialog.cpp
0224             ekos/capture/rotatorsettings.cpp
0225             ekos/capture/customproperties.cpp
0226             ekos/capture/scriptsmanager.cpp
0227             ekos/capture/placeholderpath.cpp
0228 
0229             # Analyze
0230             ekos/analyze/analyze.cpp
0231             ekos/analyze/yaxistool.cpp
0232 
0233             # Scheduler
0234             ekos/scheduler/schedulerjob.cpp
0235             ekos/scheduler/scheduler.cpp
0236             ekos/scheduler/mosaic.cpp
0237             ekos/scheduler/framingassistantui.cpp
0238             ekos/scheduler/mosaictilesmanager.cpp
0239             ekos/scheduler/mosaictilesmodel.cpp
0240             #ekos/scheduler/mosaicrenderer.cpp
0241             ekos/scheduler/greedyscheduler.cpp
0242 
0243             # Focus
0244             ekos/focus/focus.cpp
0245             ekos/focus/focushfrvplot.cpp
0246             ekos/focus/focusprofileplot.cpp
0247             ekos/focus/focusalgorithms.cpp
0248             ekos/focus/polynomialfit.cpp
0249             ekos/focus/focusstars.cpp
0250             ekos/focus/curvefit.cpp
0251 
0252             # Mount
0253             ekos/mount/mount.cpp
0254             ekos/mount/meridianflipstatuswidget.cpp
0255 
0256             # Align
0257             ekos/align/align.cpp
0258             ekos/align/alignview.cpp
0259             ekos/align/astrometryparser.cpp
0260             ekos/align/opsastrometry.cpp
0261             ekos/align/opsalign.cpp
0262             ekos/align/opsprograms.cpp
0263             ekos/align/opsastrometryindexfiles.cpp
0264             ekos/align/remoteastrometryparser.cpp
0265             ekos/align/poleaxis.cpp
0266             ekos/align/polaralign.cpp
0267             ekos/align/rotations.cpp
0268             ekos/align/mountmodel.cpp
0269             ekos/align/polaralignmentassistant.cpp
0270             ekos/align/manualrotator.cpp
0271             ekos/align/polaralignwidget.cpp
0272 
0273             # Guide
0274             ekos/guide/guide.cpp
0275             ekos/guide/guidestatewidget.cpp
0276             ekos/guide/guideinterface.cpp
0277             ekos/guide/opscalibration.cpp
0278             ekos/guide/opsguide.cpp
0279             ekos/guide/opsdither.cpp
0280             ekos/guide/opsgpg.cpp
0281             ekos/guide/guidedriftgraph.cpp
0282             ekos/guide/guidetargetplot.cpp
0283             # Internal Guide
0284             ekos/guide/internalguide/gmath.cpp
0285             ekos/guide/internalguide/guidealgorithms.cpp
0286             ekos/guide/internalguide/calibrationprocess.cpp
0287             ekos/guide/internalguide/internalguider.cpp
0288             #ekos/guide/internalguide/guider.cpp
0289             ekos/guide/internalguide/matr.cpp
0290             #ekos/guide/internalguide/rcalibration.cpp
0291             ekos/guide/internalguide/vect.cpp
0292             ekos/guide/internalguide/imageautoguiding.cpp
0293             ekos/guide/internalguide/guidelog.cpp
0294             ekos/guide/internalguide/starcorrespondence.cpp
0295             ekos/guide/internalguide/gpg.cpp
0296             ekos/guide/internalguide/calibration.cpp
0297             ekos/guide/internalguide/guidestars.cpp
0298             ekos/guide/guideview.cpp
0299             # External Guide
0300             ekos/guide/externalguide/phd2.cpp
0301             ekos/guide/externalguide/linguider.cpp
0302 
0303             #Observatory
0304             # Needs to migrate Observatory
0305             ekos/observatory/observatory.cpp
0306 #            ekos/observatory/observatorymodel.cpp
0307 #            ekos/observatory/observatorydomemodel.cpp
0308 #            ekos/observatory/observatoryweathermodel.cpp
0309 
0310             # Ekos Live
0311             ekos/ekoslive/ekosliveclient.cpp
0312             ekos/ekoslive/message.cpp
0313             ekos/ekoslive/media.cpp
0314             ekos/ekoslive/cloud.cpp
0315         )
0316 
0317     endif(CFITSIO_FOUND)
0318 
0319     include_directories(${INDI_INCLUDE_DIR})
0320 endif (INDI_FOUND)
0321 
0322 if (CFITSIO_FOUND)
0323   set (gpg_SRCS
0324         ekos/guide/internalguide/MPI_IS_gaussian_process/src/math_tools.cpp
0325         ekos/guide/internalguide/MPI_IS_gaussian_process/src/covariance_functions.cpp
0326         ekos/guide/internalguide/MPI_IS_gaussian_process/src/gaussian_process.cpp
0327         ekos/guide/internalguide/MPI_IS_gaussian_process/src/gaussian_process_guider.cpp
0328         )
0329     set (sep_SRCS
0330         fitsviewer/sep/analyse.c
0331         fitsviewer/sep/aperture.c
0332         fitsviewer/sep/background.c
0333         fitsviewer/sep/convolve.c
0334         fitsviewer/sep/deblend.c
0335         fitsviewer/sep/extract.c
0336         fitsviewer/sep/lutz.c
0337         fitsviewer/sep/util.c
0338         )
0339 
0340     set (hough_SRCS
0341         fitsviewer/hough/houghline.cpp
0342         )
0343 
0344     set (fits_SRCS
0345         fitsviewer/fitslabel.cpp
0346         fitsviewer/fitsviewer.cpp
0347         fitsviewer/stretch.cpp
0348         fitsviewer/fitstab.cpp
0349         fitsviewer/fitsdebayer.cpp
0350         fitsviewer/opsfits.cpp
0351         )
0352 
0353     if (Qt5DataVisualization_FOUND)
0354         set(fits_SRCS ${fits_SRCS} fitsviewer/starprofileviewer.cpp)
0355     endif()
0356 
0357     set (fits2_SRCS
0358         fitsviewer/bayer.c
0359         fitsviewer/fpack.c
0360         fitsviewer/fpackutil.c
0361         fitsviewer/fitshistogrameditor.cpp
0362         fitsviewer/fitshistogramview.cpp
0363         fitsviewer/fitshistogramcommand.cpp
0364         fitsviewer/fitsview.cpp
0365         fitsviewer/summaryfitsview.cpp
0366         fitsviewer/fitsdata.cpp
0367         fitsviewer/fitsstardetector.cpp
0368         fitsviewer/fitsthresholddetector.cpp
0369         fitsviewer/fitsgradientdetector.cpp
0370         fitsviewer/fitscentroiddetector.cpp
0371         fitsviewer/fitssepdetector.cpp
0372         fitsviewer/fitsbahtinovdetector.cpp
0373         fitsviewer/fitsskyobject.cpp
0374         )
0375     set (fitsui_SRCS
0376         fitsviewer/fitsheaderdialog.ui
0377         fitsviewer/statform.ui
0378         fitsviewer/fitsdebayer.ui
0379         indi/streamform.ui
0380         indi/recordingoptions.ui
0381         fitsviewer/fitshistogramui.ui
0382         fitsviewer/opsfits.ui
0383         )
0384     include_directories(${CFITSIO_INCLUDE_DIR})
0385 
0386 endif(CFITSIO_FOUND)
0387 
0388 IF (CFITSIO_FOUND)
0389     IF (("${CMAKE_CXX_COMPILER_ID}" STREQUAL "AppleClang" OR "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang"))
0390         IF (SANITIZERS)
0391             SET_SOURCE_FILES_PROPERTIES(fitsviewer/bayer.c PROPERTIES COMPILE_FLAGS "-Wno-cast-align -fno-sanitize=address,undefined -fomit-frame-pointer")
0392             SET_SOURCE_FILES_PROPERTIES(fitsviewer/fitsdata.cpp PROPERTIES COMPILE_FLAGS "-fno-sanitize=address,undefined -fomit-frame-pointer")
0393             SET_SOURCE_FILES_PROPERTIES(fitsviewer/fitshistogram.cpp PROPERTIES COMPILE_FLAGS "-fno-sanitize=address,undefined -fomit-frame-pointer")
0394             SET_SOURCE_FILES_PROPERTIES(fitsviewer/fitsview.cpp PROPERTIES COMPILE_FLAGS "-fno-sanitize=address,undefined -fomit-frame-pointer")
0395             SET_SOURCE_FILES_PROPERTIES(fitsviewer/hough/houghline.cpp PROPERTIES COMPILE_FLAGS "-fno-sanitize=address,undefined -fomit-frame-pointer")
0396         ELSE ()
0397             SET_SOURCE_FILES_PROPERTIES(fitsviewer/bayer.c PROPERTIES COMPILE_FLAGS "-Wno-cast-align")
0398         ENDIF ()
0399         SET_SOURCE_FILES_PROPERTIES(fitsviewer/sep/analyse.c PROPERTIES COMPILE_FLAGS "-Wno-cast-align")
0400         SET_SOURCE_FILES_PROPERTIES(fitsviewer/sep/aperture.c PROPERTIES COMPILE_FLAGS "-Wno-cast-align -Wno-pointer-arith")
0401         SET_SOURCE_FILES_PROPERTIES(fitsviewer/sep/background.c PROPERTIES COMPILE_FLAGS "-Wno-cast-align")
0402         SET_SOURCE_FILES_PROPERTIES(fitsviewer/sep/deblend.c PROPERTIES COMPILE_FLAGS "-Wno-cast-align -Wno-incompatible-pointer-types-discards-qualifiers")
0403         SET_SOURCE_FILES_PROPERTIES(fitsviewer/sep/extract.c PROPERTIES COMPILE_FLAGS "-Wno-cast-align")
0404         SET_SOURCE_FILES_PROPERTIES(fitsviewer/sep/lutz.c PROPERTIES COMPILE_FLAGS "-Wno-cast-align")
0405         SET_SOURCE_FILES_PROPERTIES(fitsviewer/sep/util.c PROPERTIES COMPILE_FLAGS "-Wno-incompatible-pointer-types-discards-qualifiers")
0406         SET_SOURCE_FILES_PROPERTIES(fitsviewer/fpack.c PROPERTIES COMPILE_FLAGS "-Wno-error")
0407         SET_SOURCE_FILES_PROPERTIES(fitsviewer/fpackutil.c PROPERTIES COMPILE_FLAGS "-Wno-error")
0408     ELSEIF (NOT WIN32)
0409         SET_SOURCE_FILES_PROPERTIES(fitsviewer/fpack.c PROPERTIES COMPILE_FLAGS "-Wno-error")
0410         SET_SOURCE_FILES_PROPERTIES(fitsviewer/fpackutil.c PROPERTIES COMPILE_FLAGS "-Wno-error")
0411         SET_SOURCE_FILES_PROPERTIES(fitsviewer/sep/aperture.c PROPERTIES COMPILE_FLAGS "-Wno-pointer-arith")
0412         SET_SOURCE_FILES_PROPERTIES(fitsviewer/sep/deblend.c PROPERTIES COMPILE_FLAGS "-Wno-discarded-qualifiers")
0413         SET_SOURCE_FILES_PROPERTIES(fitsviewer/sep/util.c PROPERTIES COMPILE_FLAGS "-Wno-discarded-qualifiers")
0414     ENDIF ()
0415 ENDIF ()
0416 
0417 if(WCSLIB_FOUND)
0418     include_directories( ${WCSLIB_INCLUDE_DIR} )
0419 endif(WCSLIB_FOUND)
0420 
0421 set(xplanet_SRCS
0422     xplanet/opsxplanet.cpp
0423 )
0424 
0425 set(xplanetui_SRCS
0426     xplanet/opsxplanet.ui
0427 )
0428 
0429 ########### next target ###############
0430 set(libkstarstools_SRCS
0431     tools/altvstime.cpp
0432     tools/avtplotwidget.cpp
0433     tools/calendarwidget.cpp
0434     tools/conjunctions.cpp
0435     tools/eclipsetool.cpp
0436     tools/eclipsehandler.cpp
0437 
0438     tools/eclipsetool/lunareclipsehandler.cpp
0439 
0440     tools/jmoontool.cpp
0441     tools/approachsolver.cpp
0442     tools/ksconjunct.cpp
0443     tools/eqplotwidget.cpp
0444     tools/astrocalc.cpp
0445     tools/modcalcangdist.cpp
0446     tools/modcalcapcoord.cpp
0447     tools/modcalcaltaz.cpp
0448     tools/modcalcsimple.cpp
0449     tools/modcalcdaylength.cpp
0450     tools/modcalceclipticcoords.cpp
0451     tools/modcalcvizequinox.cpp
0452     tools/modcalcgalcoord.cpp
0453     tools/modcalcgeodcoord.cpp
0454     tools/modcalcjd.cpp
0455     tools/modcalcplanets.cpp
0456     tools/modcalcsidtime.cpp
0457     tools/modcalcvlsr.cpp
0458     tools/observinglist.cpp
0459     tools/obslistpopupmenu.cpp
0460     tools/sessionsortfilterproxymodel.cpp
0461     tools/obslistwizard.cpp
0462     tools/planetviewer.cpp
0463     tools/pvplotwidget.cpp
0464     tools/scriptargwidgets.cpp
0465     tools/scriptbuilder.cpp
0466     tools/scriptfunction.cpp
0467     tools/skycalendar.cpp
0468     tools/wutdialog.cpp
0469     tools/flagmanager.cpp
0470     tools/horizonmanager.cpp
0471     tools/nameresolver.cpp
0472     tools/polarishourangle.cpp
0473     #FIXME Port to KF5
0474     #tools/moonphasetool.cpp
0475 
0476     tools/starhopper.cpp
0477     tools/eyepiecefield.cpp
0478     tools/exporteyepieceview.cpp
0479     tools/starhopperdialog.cpp
0480     tools/greatcircle.cpp
0481 
0482     tools/import_skycomp.cpp
0483 )
0484 
0485 if(${KF5_VERSION} VERSION_EQUAL 5.18.0 OR ${KF5_VERSION} VERSION_GREATER 5.18.0)
0486     set(libkstarstools_SRCS
0487         ${libkstarstools_SRCS}
0488         tools/whatsinteresting/skyobjlistmodel.cpp
0489         tools/whatsinteresting/wiview.cpp
0490         tools/whatsinteresting/modelmanager.cpp
0491         tools/whatsinteresting/skyobjitem.cpp
0492         tools/whatsinteresting/wilpsettings.cpp
0493         tools/whatsinteresting/wiequipsettings.cpp
0494         tools/whatsinteresting/obsconditions.cpp
0495         tools/whatsinteresting/skyobjdescription.cpp
0496     )
0497 endif()
0498 
0499 ki18n_wrap_ui(libkstarstools_ui_SRCS
0500     tools/altvstime.ui
0501     tools/argchangeviewoption.ui
0502     tools/argexportimage.ui
0503     tools/argloadcolorscheme.ui
0504     tools/arglooktoward.ui
0505     tools/argfindobject.ui
0506     tools/argprintimage.ui
0507     tools/argsetaltaz.ui
0508     tools/argsetcolor.ui
0509     tools/argsetgeolocation.ui
0510     tools/argsetlocaltime.ui
0511     tools/argsetradec.ui
0512     tools/argsettrack.ui
0513     tools/argtimescale.ui
0514     tools/argwaitfor.ui
0515     tools/argwaitforkey.ui
0516     tools/argzoom.ui
0517     tools/conjunctions.ui
0518     tools/eclipsetool.ui
0519     tools/modcalcangdist.ui
0520     tools/modcalcapcoord.ui
0521     tools/modcalcaltaz.ui
0522     tools/modcalcsimple.ui
0523     tools/modcalcdaylength.ui
0524     tools/modcalceclipticcoords.ui
0525     tools/modcalcvizequinox.ui
0526     tools/modcalcgalcoord.ui
0527     tools/modcalcgeod.ui
0528     tools/modcalcjd.ui
0529     tools/modcalcplanets.ui
0530     tools/modcalcsidtime.ui
0531     tools/modcalcvlsr.ui
0532     tools/observinglist.ui
0533     tools/obslistwizard.ui
0534     tools/optionstreeview.ui
0535     tools/planetviewer.ui
0536     tools/scriptbuilder.ui
0537     tools/scriptnamedialog.ui
0538     tools/skycalendar.ui
0539     tools/wutdialog.ui
0540     tools/flagmanager.ui
0541     tools/starhopperdialog.ui
0542     tools/horizonmanager.ui
0543     tools/polarishourangle.ui
0544 )
0545 
0546 if (${KF5_VERSION} VERSION_EQUAL 5.18.0 OR ${KF5_VERSION} VERSION_GREATER 5.18.0)
0547     ki18n_wrap_ui(libkstarstools_ui_SRCS
0548         tools/whatsinteresting/wilpsettings.ui
0549         tools/whatsinteresting/wiequipsettings.ui
0550     )
0551 endif()
0552 
0553 set(libkstarswidgets_SRCS
0554     widgets/clicklabel.cpp
0555     widgets/dmsbox.cpp
0556     widgets/draglistbox.cpp
0557     widgets/fovwidget.cpp
0558     widgets/logedit.cpp
0559     widgets/magnitudespinbox.cpp
0560     widgets/mapcanvas.cpp
0561     widgets/thumbimage.cpp
0562     widgets/timespinbox.cpp
0563     widgets/timestepbox.cpp
0564     widgets/timeunitbox.cpp
0565     widgets/infoboxwidget.cpp
0566 #    widgets/genericcalendarwidget.cpp
0567 #    widgets/moonphasecalendarwidget.cpp
0568     widgets/kshelplabel.cpp
0569     widgets/unitspinboxwidget.cpp
0570 )
0571 
0572 ki18n_wrap_ui(libkstarswidgets_ui_SRCS
0573 #    widgets/genericcalendarwidget.ui
0574     widgets/unitspinboxwidget.ui
0575 )
0576 
0577 set(kstars_options_SRCS
0578     options/opsadvanced.cpp
0579     options/opscatalog.cpp
0580     options/opscolors.cpp
0581     options/opsguides.cpp
0582     options/opssolarsystem.cpp
0583     options/opssatellites.cpp
0584     options/opssupernovae.cpp
0585     options/opsterrain.cpp
0586     options/opsdeveloper.cpp
0587 )
0588 
0589 set(kstars_optionsui_SRCS
0590     options/opsadvanced.ui
0591     options/opscatalog.ui
0592     options/opscolors.ui
0593     options/opsguides.ui
0594     options/opssolarsystem.ui
0595     options/opssatellites.ui
0596     options/opssupernovae.ui
0597     options/opsterrain.ui
0598     options/opsdeveloper.ui
0599 )
0600 
0601 set(kstars_dialogs_SRCS
0602     dialogs/addcatalogobject.cpp
0603     dialogs/catalogsdbui.cpp
0604     dialogs/catalogeditform.cpp
0605     dialogs/catalogcoloreditor.cpp
0606     dialogs/catalogdetails.cpp
0607     dialogs/catalogcsvimport.cpp
0608     dialogs/catalogobjectlistmodel.cpp
0609     dialogs/addlinkdialog.cpp
0610     dialogs/detaildialog.cpp
0611     dialogs/finddialog.cpp
0612     dialogs/focusdialog.cpp
0613     dialogs/fovdialog.cpp
0614     dialogs/locationdialog.cpp
0615     dialogs/timedialog.cpp
0616     dialogs/exportimagedialog.cpp
0617 )
0618 
0619 set(kstars_dialogsui_SRCS
0620     dialogs/addcatalogobject.ui
0621     dialogs/catalogsdbui.ui
0622     dialogs/catalogeditform.ui
0623     dialogs/catalogcoloreditor.ui
0624     dialogs/catalogdetails.ui
0625     dialogs/catalogcsvimport.ui
0626     dialogs/addlinkdialog.ui
0627     dialogs/details_database.ui
0628     dialogs/details_data.ui
0629     dialogs/details_data_comet.ui
0630     dialogs/details_links.ui
0631     dialogs/details_log.ui
0632     dialogs/details_position.ui
0633     dialogs/finddialog.ui
0634     dialogs/focusdialog.ui
0635     dialogs/fovdialog.ui
0636     dialogs/locationdialog.ui
0637     dialogs/wizwelcome.ui
0638     dialogs/wizlocation.ui
0639     dialogs/wizdownload.ui
0640     dialogs/wizdata.ui
0641     dialogs/newfov.ui
0642     dialogs/exportimagedialog.ui
0643 )
0644 
0645 set(hips_SRCS
0646     hips/healpix.cpp
0647     hips/hipsrenderer.cpp
0648     hips/hipsfinder.cpp
0649     hips/scanrender.cpp
0650     hips/pixcache.cpp
0651     hips/urlfiledownload.cpp
0652     hips/opships.cpp
0653 )
0654 
0655 set(terrain_SRCS
0656     terrain/terrainrenderer.cpp
0657 )
0658 
0659 set(hips_manager_SRCS
0660     hips/hipsmanager.cpp
0661 )
0662 
0663 set(oal_SRCS
0664     oal/log.cpp
0665     oal/observer.cpp
0666     oal/site.cpp
0667     oal/session.cpp
0668     oal/scope.cpp
0669     oal/dslrlens.cpp
0670     oal/eyepiece.cpp
0671     oal/filter.cpp
0672     oal/observation.cpp
0673     oal/lens.cpp
0674     oal/equipmentwriter.cpp
0675     oal/observeradd.cpp
0676     oal/execute.cpp
0677 )
0678 
0679 set(printing_SRCS
0680     printing/detailstable.cpp
0681     printing/finderchart.cpp
0682     printing/foveditordialog.cpp
0683     printing/fovsnapshot.cpp
0684     printing/kstarsdocument.cpp
0685     printing/legend.cpp
0686     printing/loggingform.cpp
0687     printing/printingwizard.cpp
0688     printing/pwizchartconfig.cpp
0689     printing/pwizchartcontents.cpp
0690     printing/pwizfovbrowse.cpp
0691     printing/pwizfovconfig.cpp
0692     printing/pwizfovmanual.cpp
0693     printing/pwizfovsh.cpp
0694     printing/pwizfovtypeselection.cpp
0695     printing/pwizobjectselection.cpp
0696     printing/pwizprint.cpp
0697     printing/shfovexporter.cpp
0698     printing/simplefovexporter.cpp
0699 )
0700 
0701 set(printingui_SRCS
0702     printing/foveditordialog.ui
0703     printing/pwizchartconfig.ui
0704     printing/pwizchartcontents.ui
0705     printing/pwizfovbrowse.ui
0706     printing/pwizfovconfig.ui
0707     printing/pwizfovmanual.ui
0708     printing/pwizfovsh.ui
0709     printing/pwizfovtypeselection.ui
0710     printing/pwizobjectselection.ui
0711     printing/pwizprint.ui
0712     printing/pwizwelcome.ui
0713 )
0714 
0715 set(libkstarscomponents_SRCS
0716     skycomponents/skylabeler.cpp
0717     skycomponents/highpmstarlist.cpp
0718     skycomponents/skymapcomposite.cpp
0719     skycomponents/skymesh.cpp
0720     skycomponents/linelistindex.cpp
0721     skycomponents/linelistlabel.cpp
0722     skycomponents/noprecessindex.cpp
0723     skycomponents/listcomponent.cpp
0724     skycomponents/pointlistcomponent.cpp
0725     skycomponents/solarsystemsinglecomponent.cpp
0726     skycomponents/solarsystemlistcomponent.cpp
0727     skycomponents/earthshadowcomponent.cpp
0728     skycomponents/asteroidscomponent.cpp
0729     skycomponents/cometscomponent.cpp
0730     skycomponents/planetmoonscomponent.cpp
0731     skycomponents/solarsystemcomposite.cpp
0732     skycomponents/satellitescomponent.cpp
0733     skycomponents/starcomponent.cpp
0734     skycomponents/deepstarcomponent.cpp
0735     skycomponents/catalogscomponent.cpp
0736     skycomponents/constellationartcomponent.cpp
0737     skycomponents/constellationboundarylines.cpp
0738     skycomponents/constellationlines.cpp
0739     skycomponents/constellationnamescomponent.cpp
0740     skycomponents/supernovaecomponent.cpp
0741     skycomponents/coordinategrid.cpp
0742     skycomponents/equatorialcoordinategrid.cpp
0743     skycomponents/horizontalcoordinategrid.cpp
0744     skycomponents/localmeridiancomponent.cpp
0745     skycomponents/ecliptic.cpp
0746     skycomponents/equator.cpp
0747     skycomponents/artificialhorizoncomponent.cpp
0748     skycomponents/hipscomponent.cpp
0749     skycomponents/terraincomponent.cpp
0750     skycomponents/horizoncomponent.cpp
0751     skycomponents/milkyway.cpp
0752     skycomponents/skycomponent.cpp
0753     skycomponents/skycomposite.cpp
0754     skycomponents/starblock.cpp
0755     skycomponents/starblocklist.cpp
0756     skycomponents/starblockfactory.cpp
0757     skycomponents/culturelist.cpp
0758     skycomponents/flagcomponent.cpp
0759     skycomponents/targetlistcomponent.cpp
0760     )
0761 
0762 IF (INDI_FOUND)
0763 LIST(APPEND libkstarscomponents_SRCS
0764     skycomponents/mosaiccomponent.cpp
0765     )
0766 ENDIF(INDI_FOUND)
0767 
0768 #LIST(APPEND libkstarscomponents_SRCS
0769 #    #skycomponents/notifyupdatesui.cpp
0770 #    )
0771 
0772 IF (BUILD_KSTARS_LITE)
0773     set(libkstarstools_ui_klite_SRCS
0774         tools/nameresolver.cpp
0775         )
0776 ENDIF ()
0777 
0778 set(kstars_skyobjects_SRCS
0779     skyobjects/constellationsart.cpp
0780     skyobjects/catalogobject.cpp
0781     skyobjects/jupitermoons.cpp
0782     skyobjects/planetmoons.cpp
0783     skyobjects/ksasteroid.cpp
0784     skyobjects/kscomet.cpp
0785     skyobjects/ksmoon.cpp
0786     skyobjects/ksearthshadow.cpp
0787     skyobjects/ksplanetbase.cpp
0788     skyobjects/ksplanet.cpp
0789     #skyobjects/kspluto.cpp
0790     skyobjects/kssun.cpp
0791     skyobjects/skyline.cpp
0792     skyobjects/skyobject.cpp
0793     skyobjects/skypoint.cpp
0794     skyobjects/starobject.cpp
0795     skyobjects/trailobject.cpp
0796     skyobjects/satellite.cpp
0797     skyobjects/satellitegroup.cpp
0798     skyobjects/supernova.cpp
0799     )
0800 
0801 IF (INDI_FOUND)
0802 LIST(APPEND kstars_skyobjects_SRCS
0803     skyobjects/mosaictiles.cpp
0804     )
0805 ENDIF(INDI_FOUND)
0806 
0807 set(kstars_projection_SRCS
0808     projections/projector.cpp
0809     projections/lambertprojector.cpp
0810     projections/gnomonicprojector.cpp
0811     projections/stereographicprojector.cpp
0812     projections/orthographicprojector.cpp
0813     projections/azimuthalequidistantprojector.cpp
0814     projections/equirectangularprojector.cpp
0815     )
0816 
0817 set(kstars_extra_SRCS
0818     auxiliary/colorscheme.cpp
0819     auxiliary/dms.cpp
0820     auxiliary/cachingdms.cpp
0821     auxiliary/geolocation.cpp
0822     auxiliary/ksfilereader.cpp
0823     auxiliary/ksuserdb.cpp
0824     auxiliary/binfilehelper.cpp
0825     auxiliary/ksutils.cpp
0826     auxiliary/ksdssimage.cpp
0827     auxiliary/ksdssdownloader.cpp
0828     auxiliary/nonlineardoublespinbox.cpp
0829     auxiliary/profileinfo.cpp
0830     auxiliary/filedownloader.cpp
0831     auxiliary/kspaths.cpp
0832     auxiliary/QRoundProgressBar.cpp
0833     auxiliary/skyobjectlistmodel.cpp
0834     auxiliary/ksnotification.cpp
0835     auxiliary/ksmessagebox.cpp
0836     auxiliary/QProgressIndicator.cpp
0837     auxiliary/ctkrangeslider.cpp
0838     time/simclock.cpp
0839     time/kstarsdatetime.cpp
0840     time/timezonerule.cpp
0841     ksnumbers.cpp
0842     kstarsdata.cpp
0843     texturemanager.cpp
0844     #to minimize number of indef KSTARS_LITE
0845     skypainter.cpp    
0846     )
0847 
0848 SET(kstars_extra_kstars_SRCS
0849     auxiliary/thememanager.cpp
0850     auxiliary/schememanager.cpp
0851     auxiliary/imageviewer.cpp
0852     auxiliary/xplanetimageviewer.cpp
0853     auxiliary/fov.cpp
0854     auxiliary/thumbnailpicker.cpp
0855     auxiliary/thumbnaileditor.cpp
0856     auxiliary/imageexporter.cpp
0857     auxiliary/kswizard.cpp
0858     auxiliary/qcustomplot.cpp
0859     kstarsdbus.cpp
0860     kspopupmenu.cpp
0861     ksalmanac.cpp
0862     kstarsactions.cpp
0863     kstarsinit.cpp
0864     kstars.cpp
0865     kstarssplash.cpp
0866     skymap.cpp
0867     skymapdrawabstract.cpp
0868     skymapqdraw.cpp
0869     skymapevents.cpp
0870     skyqpainter.cpp
0871     )
0872 
0873 SET(catalogsdb_SRCS
0874         catalogsdb/catalogsdb.cpp)
0875 
0876 if(NOT APPLE) #KStarsLite files including the QML files are not needed on MacOS right now
0877 # Temporary solution to allow use of qml files from source dir DELETE
0878 SET(KSTARSLITE_CPP_OPTIONS -DSOURCE_DIR=\"${kstars_SOURCE_DIR}\" -DQML_IMPORT="${CMAKE_CURRENT_SOURCE_DIR}")
0879 
0880 set(klite_SRCS
0881     kstarslite.cpp
0882     kstarsliteinit.cpp
0883     skymaplite.cpp
0884     skymapliteevents.cpp
0885     #Wrappers
0886     kstarslite/skypointlite.cpp
0887     kstarslite/skyobjectlite.cpp
0888     #ImageProvider
0889     kstarslite/imageprovider.cpp
0890     #Dialogs
0891     kstarslite/dialogs/detaildialoglite.cpp
0892     kstarslite/dialogs/finddialoglite.cpp
0893     kstarslite/dialogs/locationdialoglite.cpp
0894     #RootNode
0895     kstarslite/skyitems/rootnode.cpp
0896     kstarslite/skyitems/skyopacitynode.cpp
0897     kstarslite/skyitems/typedeflite.h
0898     #SkyItems
0899     kstarslite/skyitems/skyitem.cpp
0900     kstarslite/skyitems/planetsitem.cpp
0901     kstarslite/skyitems/asteroidsitem.cpp
0902     kstarslite/skyitems/cometsitem.cpp
0903     kstarslite/skyitems/horizonitem.cpp
0904     kstarslite/skyitems/labelsitem.cpp
0905     kstarslite/skyitems/constellationnamesitem.cpp
0906     kstarslite/skyitems/staritem.cpp
0907     kstarslite/skyitems/deepstaritem.cpp
0908     kstarslite/skyitems/deepskyitem.cpp
0909     kstarslite/skyitems/constellationartitem.cpp
0910     kstarslite/skyitems/satellitesitem.cpp
0911     kstarslite/skyitems/supernovaeitem.cpp
0912     kstarslite/skyitems/fovitem.cpp
0913     #Line
0914     kstarslite/skyitems/lines/linesitem.cpp
0915     kstarslite/skyitems/lines/equatoritem.cpp
0916     kstarslite/skyitems/lines/eclipticitem.cpp
0917     kstarslite/skyitems/lines/milkywayitem.cpp
0918     #SkyNodes
0919     kstarslite/skyitems/skynodes/planetnode.cpp
0920     kstarslite/skyitems/skynodes/skynode.cpp
0921     kstarslite/skyitems/skynodes/pointsourcenode.cpp
0922     kstarslite/skyitems/skynodes/planetmoonsnode.cpp
0923     kstarslite/skyitems/skynodes/horizonnode.cpp
0924     kstarslite/skyitems/skynodes/labelnode.cpp
0925     kstarslite/skyitems/skynodes/guidelabelnode.cpp
0926     kstarslite/skyitems/skynodes/deepskynode.cpp
0927     kstarslite/skyitems/skynodes/dsosymbolnode.cpp
0928     kstarslite/skyitems/skynodes/skypolygonnode.cpp
0929     kstarslite/skyitems/skynodes/constellationartnode.cpp
0930     kstarslite/skyitems/skynodes/satellitenode.cpp
0931     kstarslite/skyitems/skynodes/supernovanode.cpp
0932     kstarslite/skyitems/skynodes/trixelnode.cpp
0933     kstarslite/skyitems/skynodes/fovsymbolnode.cpp
0934     #Nodes
0935     kstarslite/skyitems/skynodes/nodes/pointnode.cpp
0936     kstarslite/skyitems/skynodes/nodes/polynode.cpp
0937     kstarslite/skyitems/skynodes/nodes/linenode.cpp
0938     kstarslite/skyitems/skynodes/nodes/ellipsenode.cpp
0939     kstarslite/skyitems/skynodes/nodes/rectnode.cpp
0940     #Other
0941     kstarslite/deviceorientation.cpp
0942     )
0943 
0944 set(kstarslite_libtess_SRC
0945     #libtess
0946     libtess/gluos.h
0947     libtess/priorityq-sort.h
0948     libtess/sweep.c
0949     libtess/tessmono.c
0950     libtess/dict-list.h
0951     libtess/glu.h
0952     libtess/tessellate.c
0953     libtess/dict.c
0954     libtess/geom.c
0955     libtess/memalloc.c
0956     libtess/mesh.c
0957     libtess/normal.c
0958     libtess/priorityq.c
0959     libtess/priorityq-heap.c
0960     libtess/render.c
0961     libtess/tess.c
0962     )
0963 
0964 IF (BUILD_KSTARS_LITE)
0965     ADD_CUSTOM_TARGET(convert_translations ${CMAKE_SOURCE_DIR}/tools/convert_translations.sh ${CMAKE_BINARY_DIR}
0966                       WORKING_DIRECTORY ${CMAKE_BINARY_DIR})
0967     ADD_DEPENDENCIES(convert_translations fetch-translations)
0968     IF (ANDROID)
0969         ADD_CUSTOM_TARGET(convert_translations_to_android ${CMAKE_SOURCE_DIR}/tools/convert_translations.sh ${CMAKE_BINARY_DIR}/packaging/android/export/share/kstars
0970                           WORKING_DIRECTORY ${CMAKE_BINARY_DIR})
0971         ADD_DEPENDENCIES(convert_translations_to_android fetch-translations)
0972     ENDIF ()
0973 ENDIF ()
0974 
0975 IF ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "AppleClang" OR "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
0976     SET_SOURCE_FILES_PROPERTIES(${kstarslite_libtess_SRC} PROPERTIES COMPILE_FLAGS "-Wno-error")
0977 ENDIF ()
0978 
0979 #Qml files will be probably moved to user's data dir, but for use
0980 #with QtCreator it is more convenient to have them here
0981 set(kstarsliteqml_SRCS
0982     kstarslite/qml/main.qml
0983     kstarslite/qml/constants/Constants.qml
0984     kstarslite/qml/modules/SkyMapLiteWrapper.qml
0985     kstarslite/qml/modules/BottomMenu.qml
0986     kstarslite/qml/modules/KSPage.qml
0987     kstarslite/qml/modules/KSListView.qml
0988     kstarslite/qml/modules/KSLabel.qml
0989     kstarslite/qml/modules/KSText.qml
0990     kstarslite/qml/modules/KSTabButton.qml
0991     kstarslite/qml/modules/KSTab.qml
0992     kstarslite/qml/modules/KSTabBarArrow.qml
0993     kstarslite/qml/modules/KSTextField.qml
0994     kstarslite/qml/modules/KSButton.qml
0995     kstarslite/qml/modules/TopMenu.qml
0996     kstarslite/qml/modules/helpers/TopMenuButton.qml
0997     kstarslite/qml/modules/helpers/BottomMenuButton.qml
0998     kstarslite/qml/modules/Splash.qml
0999     kstarslite/qml/modules/helpers/TimeSpinBox.qml
1000     kstarslite/qml/modules/TimePage.qml
1001     #Popups
1002     kstarslite/qml/modules/popups/ProjectionsPopup.qml
1003     kstarslite/qml/modules/popups/FOVPopup.qml
1004     kstarslite/qml/modules/popups/ColorSchemePopup.qml
1005     #Menus
1006     kstarslite/qml/modules/menus/ContextMenu.qml
1007     #Helpers
1008     kstarslite/qml/modules/helpers/PassiveNotification.qml
1009     kstarslite/qml/modules/helpers/KSMenuItem.qml
1010     kstarslite/qml/modules/helpers/TelescopeControl.qml
1011     #Dialogs
1012     kstarslite/qml/dialogs/FindDialog.qml
1013     kstarslite/qml/dialogs/LocationDialog.qml
1014     kstarslite/qml/dialogs/DetailsDialog.qml
1015     kstarslite/qml/dialogs/AboutDialog.qml
1016 
1017     kstarslite/qml/dialogs/helpers/DetailsItem.qml
1018     kstarslite/qml/dialogs/helpers/DetailsAddLink.qml
1019     kstarslite/qml/dialogs/helpers/LocationEdit.qml
1020     kstarslite/qml/dialogs/helpers/LocationLoading.qml
1021 
1022     kstarslite/qml/dialogs/menus/DetailsLinkMenu.qml
1023     kstarslite/qml/dialogs/menus/LocationsGeoMenu.qml
1024     #INDI
1025     kstarslite/qml/indi/INDIControlPanel.qml
1026     kstarslite/qml/indi/DevicePanel.qml
1027     kstarslite/qml/indi/ImagePreview.qml
1028     kstarslite/qml/indi/modules/MotionControl.qml
1029     kstarslite/qml/indi/modules/Led.qml
1030     kstarslite/qml/indi/modules/KSLed.qml
1031     kstarslite/qml/indi/modules/Property.qml
1032     kstarslite/qml/indi/modules/KSComboBox.qml
1033     kstarslite/qml/indi/modules/KSButtonSwitch.qml
1034     kstarslite/qml/indi/modules/KSCheckBox.qml
1035     kstarslite/qml/indi/modules/KSINDIText.qml
1036     kstarslite/qml/indi/modules/KSINDITextField.qml
1037     kstarslite/qml/indi/modules/KSButtonsSwitchRow.qml
1038     #Tutorial
1039     kstarslite/qml/modules/tutorial/TutorialPopup.qml
1040     kstarslite/qml/modules/tutorial/TutorialExitPopup.qml
1041     kstarslite/qml/modules/tutorial/TutorialStep1.qml
1042     kstarslite/qml/modules/tutorial/TutorialStep2.qml
1043     kstarslite/qml/modules/tutorial/TutorialStep3.qml
1044     kstarslite/qml/modules/tutorial/TutorialStep4.qml
1045     kstarslite/qml/modules/tutorial/TutorialStep5.qml
1046     kstarslite/qml/modules/tutorial/TutorialPane.qml
1047     )
1048 add_subdirectory(kstarslite/qml)
1049 ADD_CUSTOM_TARGET(kstarsliteqml SOURCES ${kstarsliteqml_SRCS})
1050 endif(NOT APPLE) #This is the end of the Mac KStars disabling of the KStarsLite Code
1051 
1052 if(ANDROID)
1053     add_subdirectory(kstarslite/res)
1054 endif(ANDROID)
1055 
1056 set(kstars_SRCS
1057     ${indi_SRCS}
1058     ${fits_SRCS}
1059     ${ekos_SRCS}
1060     ${libkstarswidgets_SRCS}
1061     ${libkstarscomponents_SRCS}
1062     ${libkstarstools_SRCS}
1063     ${kstars_extra_SRCS}
1064     ${kstars_extra_kstars_SRCS}
1065     ${kstars_projection_SRCS}
1066     ${xplanet_SRCS}
1067     ${kstars_options_SRCS}
1068     ${kstars_skyobjects_SRCS}
1069     ${kstars_dialogs_SRCS}
1070     ${hips_SRCS}
1071     ${terrain_SRCS}
1072     ${oal_SRCS}
1073     ${printing_SRCS}
1074     ${catalogsdb_SRCS}
1075     #KStars Lite
1076     ${kstarslite_SRCS}
1077     # Generated files
1078     ${libkstarstools_ui_SRCS}
1079     ${libkstarswidgets_ui_SRCS}
1080 )
1081 
1082 set(kstarslite_SRCS
1083     ${indi_klite_SRCS}
1084     ${libkstarscomponents_SRCS}
1085     ${kstars_extra_SRCS}
1086     ${kstars_projection_SRCS}
1087     ${kstars_skyobjects_SRCS}
1088 
1089     # KStars Lite sources
1090     ${klite_SRCS}
1091     # Generated files
1092     ${libkstarstools_ui_klite_SRCS}
1093 )
1094 
1095 # Generate all the necessary QLoggingCategory files
1096 ecm_qt_declare_logging_category(kstars_SRCS HEADER kstars_debug.h IDENTIFIER KSTARS CATEGORY_NAME org.kde.kstars)
1097 ecm_qt_declare_logging_category(kstars_SRCS HEADER indi_debug.h IDENTIFIER KSTARS_INDI CATEGORY_NAME org.kde.kstars.indi)
1098 ecm_qt_declare_logging_category(kstars_SRCS HEADER fits_debug.h IDENTIFIER KSTARS_FITS CATEGORY_NAME org.kde.kstars.fits)
1099 ecm_qt_declare_logging_category(kstars_SRCS HEADER ekos_debug.h IDENTIFIER KSTARS_EKOS CATEGORY_NAME org.kde.kstars.ekos)
1100 ecm_qt_declare_logging_category(kstars_SRCS HEADER ekos_capture_debug.h IDENTIFIER KSTARS_EKOS_CAPTURE CATEGORY_NAME org.kde.kstars.ekos.capture)
1101 ecm_qt_declare_logging_category(kstars_SRCS HEADER ekos_focus_debug.h IDENTIFIER KSTARS_EKOS_FOCUS CATEGORY_NAME org.kde.kstars.ekos.focus)
1102 ecm_qt_declare_logging_category(kstars_SRCS HEADER ekos_align_debug.h IDENTIFIER KSTARS_EKOS_ALIGN CATEGORY_NAME org.kde.kstars.ekos.align)
1103 ecm_qt_declare_logging_category(kstars_SRCS HEADER ekos_guide_debug.h IDENTIFIER KSTARS_EKOS_GUIDE CATEGORY_NAME org.kde.kstars.ekos.guide)
1104 ecm_qt_declare_logging_category(kstars_SRCS HEADER ekos_mount_debug.h IDENTIFIER KSTARS_EKOS_MOUNT CATEGORY_NAME org.kde.kstars.ekos.mount)
1105 ecm_qt_declare_logging_category(kstars_SRCS HEADER ekos_scheduler_debug.h IDENTIFIER KSTARS_EKOS_SCHEDULER CATEGORY_NAME org.kde.kstars.ekos.scheduler)
1106 ecm_qt_declare_logging_category(kstars_SRCS HEADER ekos_analyze_debug.h IDENTIFIER KSTARS_EKOS_ANALYZE CATEGORY_NAME org.kde.kstars.ekos.analyze)
1107 ecm_qt_declare_logging_category(kstars_SRCS HEADER ekos_observatory_debug.h IDENTIFIER KSTARS_EKOS_OBSERVATORY CATEGORY_NAME org.kde.kstars.ekos.observatory)
1108 
1109 ecm_qt_declare_logging_category(kstars_SRCS HEADER catalogsdb_debug.h IDENTIFIER KSTARS_CATALOGS CATEGORY_NAME org.kde.kstars.catalogdb)
1110 
1111 
1112 set( kstars_KCFG_SRCS Options.kcfgc )
1113 
1114 # We cannot generate property up until KF5 Config v5.78.0 or later
1115 if (${KF5_VERSION} VERSION_GREATER_EQUAL "5.78.0")
1116     set(KF5_CONFIG_OK true)
1117     configure_file(
1118         ${CMAKE_CURRENT_SOURCE_DIR}/Options.kcfgc.cmake
1119         ${CMAKE_CURRENT_SOURCE_DIR}/Options.kcfgc
1120     )
1121     kconfig_add_kcfg_files(kstars_SRCS ${kstars_KCFG_SRCS} GENERATE_MOC)
1122     kconfig_add_kcfg_files(kstarslite_SRCS ${kstars_KCFG_SRCS} GENERATE_MOC)
1123 else()
1124     set(KF5_CONFIG_OK false)
1125     configure_file(
1126         ${CMAKE_CURRENT_SOURCE_DIR}/Options.kcfgc.cmake
1127         ${CMAKE_CURRENT_SOURCE_DIR}/Options.kcfgc
1128     )
1129     kconfig_add_kcfg_files(kstars_SRCS ${kstars_KCFG_SRCS})
1130     kconfig_add_kcfg_files(kstarslite_SRCS ${kstars_KCFG_SRCS})
1131 endif()
1132 
1133 ecm_qt_declare_logging_category(kstarslite_SRCS HEADER kstars_debug.h IDENTIFIER KSTARS CATEGORY_NAME org.kde.kstars)
1134 ecm_qt_declare_logging_category(kstarslite_SRCS HEADER fits_debug.h IDENTIFIER KSTARS_FITS CATEGORY_NAME org.kde.kstars.fits)
1135 
1136 IF (UNITY_BUILD)
1137     ENABLE_UNITY_BUILD(kstars kstars_SRCS 10 cpp)
1138     ENABLE_UNITY_BUILD(kstarslite kstarslite_SRCS 10 cpp)
1139 ENDIF ()
1140 
1141 set(kstars_SRCS ${kstars_SRCS} ${fits2_SRCS} ${sep_SRCS} ${gpg_SRCS} ${hough_SRCS} ${hips_manager_SRCS})
1142 set(kstarslite_SRCS ${kstarslite_SRCS} ${fits_klite_SRCS} ${sep_SRCS} ${hough_SRCS} ${fits2_klite_SRCS} ${kstarslite_libtess_SRC})
1143 
1144 IF (NOT ANDROID)
1145     qt5_add_dbus_adaptor(kstars_SRCS org.kde.kstars.xml kstars.h KStars)
1146     qt5_add_dbus_adaptor(kstars_SRCS org.kde.kstars.SimClock.xml simclock.h SimClock)
1147     qt5_add_dbus_adaptor(kstars_SRCS org.kde.kstars.FOV.xml fov.h FOV)
1148 
1149     IF (INDI_FOUND)
1150         # INDI
1151         qt5_add_dbus_adaptor(kstars_SRCS org.kde.kstars.INDI.xml indi/indidbus.h INDIDBus)
1152         qt5_add_dbus_adaptor(kstars_SRCS org.kde.kstars.INDI.GenericDevice.xml indi/indistd.h ISD::GenericDevice)
1153         qt5_add_dbus_adaptor(kstars_SRCS org.kde.kstars.INDI.Dome.xml indi/indidome.h ISD::Dome)
1154         qt5_add_dbus_adaptor(kstars_SRCS org.kde.kstars.INDI.Weather.xml indi/indiweather.h ISD::Weather)
1155         qt5_add_dbus_adaptor(kstars_SRCS org.kde.kstars.INDI.DustCap.xml indi/indidustcap.h ISD::DustCap)
1156         # Ekos
1157         qt5_add_dbus_adaptor(kstars_SRCS org.kde.kstars.Ekos.xml ekos/manager.h Ekos::Manager)
1158         qt5_add_dbus_adaptor(kstars_SRCS org.kde.kstars.Ekos.Capture.xml ekos/capture/capture.h Ekos::Capture)
1159         qt5_add_dbus_adaptor(kstars_SRCS org.kde.kstars.Ekos.Focus.xml ekos/focus/focus.h Ekos::Focus)
1160         qt5_add_dbus_adaptor(kstars_SRCS org.kde.kstars.Ekos.Guide.xml ekos/guide/guide.h Ekos::Guide)
1161         qt5_add_dbus_adaptor(kstars_SRCS org.kde.kstars.Ekos.Align.xml ekos/align/align.h Ekos::Align)
1162         qt5_add_dbus_adaptor(kstars_SRCS org.kde.kstars.Ekos.Mount.xml ekos/mount/mount.h Ekos::Mount)
1163         qt5_add_dbus_adaptor(kstars_SRCS org.kde.kstars.Ekos.Scheduler.xml ekos/scheduler/scheduler.h Ekos::Scheduler)
1164         # TODO enable back observatory
1165         #qt5_add_dbus_adaptor(kstars_SRCS org.kde.kstars.Ekos.Observatory.xml ekos/observatory/observatory.h Ekos::Observatory)
1166     ENDIF ()
1167 
1168     ki18n_wrap_ui(kstars_SRCS
1169         ${indiui_SRCS}
1170         ${ui_SRCS}
1171         ${fitsui_SRCS}
1172         ${ekosui_SRCS}
1173         ${xplanetui_SRCS}
1174         ${kstars_optionsui_SRCS}
1175         ${kstars_dialogsui_SRCS}
1176         ${printingui_SRCS}
1177         auxiliary/thumbnailpicker.ui
1178         auxiliary/thumbnaileditor.ui
1179         oal/observeradd.ui
1180         oal/equipmentwriter.ui
1181         oal/execute.ui
1182         hips/opships.ui
1183         hips/opshipsdisplay.ui
1184         hips/opshipscache.ui
1185         #skycomponents/notifyupdatesui.ui
1186     )
1187 
1188     add_library(KStarsLib STATIC ${kstars_SRCS})
1189 
1190     if (BUILD_PYKSTARS)
1191       set_target_properties(KStarsLib PROPERTIES POSITION_INDEPENDENT_CODE ON)
1192     endif ()
1193 
1194     include(GenerateExportHeader)
1195     generate_export_header(KStarsLib)
1196 
1197     target_link_libraries(KStarsLib
1198         LibKSDataHandlers
1199         htmesh
1200         KF5::Crash
1201         KF5::I18n
1202         KF5::NewStuff
1203         KF5::KIOFileWidgets
1204         KF5::WidgetsAddons
1205         KF5::Plotting
1206         KF5::Notifications
1207         Qt5::Gui
1208         Qt5::PrintSupport
1209         Qt5::Sql
1210         Qt5::Svg
1211         Qt5::Qml
1212         Qt5::Quick
1213         Qt5::Network
1214         #Qt5::Positioning
1215         Qt5::Concurrent
1216         Qt5::WebSockets
1217         ${ZLIB_LIBRARIES}
1218         Eigen3::Eigen
1219         )
1220 
1221     if (Qt5Keychain_FOUND)
1222         target_include_directories(KStarsLib PUBLIC ${QTKEYCHAIN_INCLUDE_DIRS})
1223         target_link_libraries(KStarsLib ${QTKEYCHAIN_LIBRARIES})
1224     endif(Qt5Keychain_FOUND)
1225 
1226     if (Qt5DataVisualization_FOUND)
1227         target_link_libraries(KStarsLib Qt5::DataVisualization)
1228     endif(Qt5DataVisualization_FOUND)
1229 
1230     if (KF5NotifyConfig_FOUND)
1231         target_link_libraries(KStarsLib KF5::NotifyConfig)
1232     endif(KF5NotifyConfig_FOUND)
1233 
1234     if(NOT WIN32)
1235         target_link_libraries(KStarsLib m)
1236     endif(NOT WIN32)
1237 ENDIF ()
1238 
1239 if (BUILD_KSTARS_LITE)
1240     add_library(KStarsLiteLib STATIC ${kstarslite_SRCS})
1241     target_link_libraries(KStarsLiteLib
1242         LibKSDataHandlers
1243         htmesh
1244         KF5::I18n
1245         KF5::Plotting
1246         KF5::ConfigGui
1247         Qt5::Gui
1248         Qt5::Sql
1249         Qt5::Qml
1250         Qt5::Quick
1251         Qt5::QuickControls2
1252         Qt5::Positioning
1253         Qt5::PositioningQuick
1254         Qt5::Concurrent
1255         ${ZLIB_LIBRARIES}
1256         )
1257 
1258     if (ANDROID)
1259         target_link_libraries(KStarsLiteLib Qt5::AndroidExtras)
1260     endif ()
1261 
1262 endif ()
1263 
1264 
1265 if (CFITSIO_FOUND)
1266     if (NOT ANDROID)
1267         target_include_directories(KStarsLib PUBLIC ${CFITSIO_INCLUDE_DIR})
1268         target_link_libraries(KStarsLib ${CFITSIO_LIBRARIES})
1269     endif()
1270     if (BUILD_KSTARS_LITE)
1271         target_include_directories(KStarsLiteLib PUBLIC ${CFITSIO_INCLUDE_DIR})
1272         target_link_libraries(KStarsLiteLib ${CFITSIO_LIBRARIES})
1273     endif()
1274 endif(CFITSIO_FOUND)
1275 
1276 if(INDI_FOUND)
1277     if (NOT ANDROID)
1278         find_package(Nova REQUIRED)
1279         include_directories(${NOVA_INCLUDE_DIR})
1280     endif ()
1281 
1282     ## Support Multiple Platforms. All Require INDI
1283     ## WIN32 Desktop: Requires INDI Qt5 Client + GSL
1284     ## WIN32 Lite: Requires INDI Qt5 Client
1285     ## Linux + MacOS Desktop: Requires INDI Client + GSL
1286     ## Linux + MacOS Lite: Requires INDI Qt5 Client
1287     ## Android: Requires INDI Qt5 Client built for Android
1288     if (NOT ANDROID)
1289         # GSL
1290         find_package(GSL REQUIRED)
1291         include_directories(${GSL_INCLUDE_DIRS})
1292         target_link_libraries(KStarsLib ${GSL_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} KF5::Notifications)
1293         # StellarSolver
1294         target_link_libraries(KStarsLib StellarSolver::stellarsolver)
1295     endif ()
1296 
1297     if(WIN32 OR ANDROID)
1298         if(ANDROID)
1299             target_link_libraries(KStarsLiteLib ${INDI_CLIENT_ANDROID_LIBRARIES} ${CFITSIO_LIBRARIES} ${LIBRAW_LIBRARIES})
1300             target_compile_options(KStarsLiteLib PRIVATE ${KSTARSLITE_CPP_OPTIONS} -DUSE_QT5_INDI -DKSTARS_LITE)
1301         else(ANDROID)
1302             target_link_libraries(KStarsLib ${INDI_CLIENT_LIBRARIES} ${NOVA_LIBRARIES})
1303         endif(ANDROID)
1304     else(WIN32 OR ANDROID)
1305         if (BUILD_KSTARS_LITE)
1306             target_link_libraries(KStarsLiteLib ${INDI_CLIENT_QT_LIBRARIES} ${NOVA_LIBRARIES} z)
1307             target_compile_options(KStarsLiteLib PRIVATE ${KSTARSLITE_CPP_OPTIONS} -DUSE_QT5_INDI -DKSTARS_LITE)
1308         endif(BUILD_KSTARS_LITE)
1309         target_link_libraries(KStarsLib ${INDI_CLIENT_LIBRARIES} ${NOVA_LIBRARIES} z)
1310     endif(WIN32 OR ANDROID)
1311 
1312 endif(INDI_FOUND)
1313 
1314 if(WCSLIB_FOUND)
1315     target_link_libraries(KStarsLib ${WCSLIB_LIBRARIES})
1316     if (BUILD_KSTARS_LITE)
1317         target_link_libraries(KStarsLiteLib ${WCSLIB_LIBRARIES})
1318     endif()
1319 endif (WCSLIB_FOUND)
1320 
1321 if(LibRaw_FOUND)
1322     if (NOT ANDROID)
1323         target_link_libraries(KStarsLib ${LibRaw_LIBRARIES})
1324     endif()
1325     if (BUILD_KSTARS_LITE)
1326         target_link_libraries(KStarsLiteLib ${LibRaw_LIBRARIES})
1327     endif()
1328 endif (LibRaw_FOUND)
1329 
1330 # Link libnova if found
1331 if (NOVA_FOUND)
1332     target_link_libraries(KStarsLib ${NOVA_LIBRARIES})
1333 endif()
1334 
1335 #FIXME Enable OpenGL Later
1336 #if( OPENGL_FOUND )
1337 #    target_link_libraries(KStarsLib
1338 #    ${OPENGL_LIBRARIES}
1339 #    ${QT_QTOPENGL_LIBRARY}
1340 #    )
1341 #endif( OPENGL_FOUND )
1342 
1343 set (KSTARS_APP_SRCS
1344     main.cpp
1345 )
1346 
1347 # add icon to application sources
1348 ecm_add_app_icon(KSTARS_APP_SRCS ICONS
1349     ${CMAKE_CURRENT_SOURCE_DIR}/icons/16-apps-kstars.png
1350     ${CMAKE_CURRENT_SOURCE_DIR}/icons/32-apps-kstars.png
1351     ${CMAKE_CURRENT_SOURCE_DIR}/icons/48-apps-kstars.png
1352     ${CMAKE_CURRENT_SOURCE_DIR}/icons/64-apps-kstars.png
1353     ${CMAKE_CURRENT_SOURCE_DIR}/icons/128-apps-kstars.png
1354 )
1355 
1356 qt5_add_resources(KSTARS_APP_SRCS data/kstars.qrc)
1357 
1358 if (ANDROID)
1359     add_library(kstars SHARED ${KSTARS_APP_SRCS})
1360     target_compile_options(kstars PRIVATE ${KSTARSLITE_CPP_OPTIONS} -DUSE_QT5_INDI -DKSTARS_LITE)
1361     add_dependencies(KStarsLiteLib cfitsio indi raw)
1362     target_link_libraries(kstars KStarsLiteLib)
1363 else ()
1364     if (BUILD_KSTARS_LITE)
1365         add_executable(kstars_lite ${KSTARS_APP_SRCS})
1366         target_compile_options(kstars_lite PRIVATE ${KSTARSLITE_CPP_OPTIONS} -DUSE_QT5_INDI -DKSTARS_LITE)
1367         target_link_libraries(kstars_lite KStarsLiteLib)
1368     endif()
1369     add_executable(kstars ${KSTARS_APP_SRCS})
1370     target_link_libraries(kstars KStarsLib)
1371 endif ()
1372 
1373 if(APPLE)
1374     if(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/kstars-mac-files)
1375         message(STATUS "Updating KStars Mac Files")
1376         execute_process(COMMAND "git" "pull"
1377             WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/kstars-mac-files")
1378     else(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/kstars-mac-files)
1379         message(STATUS "Downloading KStars Mac Files")
1380         execute_process(COMMAND "git" "clone" "https://github.com/rlancaste/kstars-mac-files.git"
1381             WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}")
1382     endif(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/kstars-mac-files)
1383 
1384     set(KSTARS_APP "${CMAKE_BINARY_DIR}/bin/KStars.app")
1385     execute_process(COMMAND ${CMAKE_COMMAND}
1386                     -DBUNDLED_DATA_LOCATION=${CMAKE_BINARY_DIR}/bin/KStars.app/Contents/Resources
1387                     ${CMAKE_CURRENT_SOURCE_DIR}/data
1388                     WORKING_DIRECTORY "${CMAKE_BINARY_DIR}/kstars/data")
1389     execute_process(COMMAND ${CMAKE_COMMAND} --build . --target install
1390                     WORKING_DIRECTORY "${CMAKE_BINARY_DIR}/kstars/data")
1391     file(COPY
1392         "${CMAKE_CURRENT_SOURCE_DIR}/data/qml"
1393         DESTINATION "${KSTARS_APP}/Contents/Resources/kstars/")
1394     file(COPY
1395         "${CMAKE_CURRENT_SOURCE_DIR}/kstars-mac-files/icons"
1396         DESTINATION "${KSTARS_APP}/Contents/Resources/")
1397     file(COPY
1398         "${CMAKE_CURRENT_SOURCE_DIR}/kstars-mac-files/dbus"
1399         DESTINATION "${KSTARS_APP}/Contents/Plugins/")
1400     file(COPY
1401         "${CMAKE_CURRENT_SOURCE_DIR}/kstars-mac-files/gsc"
1402         DESTINATION "${KSTARS_APP}/Contents/MacOS/")
1403     file(COPY
1404         "${CMAKE_CURRENT_SOURCE_DIR}/kstars.notifyrc"
1405         DESTINATION "${KSTARS_APP}/Contents/Resources/knotifications5/")
1406     file(COPY
1407         "${CMAKE_CURRENT_SOURCE_DIR}/kstars.kcfg"
1408         DESTINATION "${KSTARS_APP}/Contents/Resources/")
1409 
1410     find_program(DBUS_SEND dbus-send PATHS ${PATHS})
1411     if(NOT DBUS_SEND)
1412         message(WARNING "DBUS Send program not found in Path, DBUS, KStars Scripting, and the Scheduler won't work without it.")
1413     else(NOT DBUS_SEND)
1414         file(COPY
1415             "${DBUS_SEND}"
1416             DESTINATION "${KSTARS_APP}/Contents/MacOS/")
1417     endif(NOT DBUS_SEND)
1418 
1419     find_program(DBUS_DAEMON dbus-daemon PATHS ${PATHS})
1420     if(NOT DBUS_DAEMON)
1421         message(WARNING "DBUS Daemon program not found in Path, DBUS, KStars Scripting, and the Scheduler won't work without it.")
1422     else(NOT DBUS_DAEMON)
1423         file(COPY
1424             "${DBUS_DAEMON}"
1425             DESTINATION "${KSTARS_APP}/Contents/MacOS/")    
1426     endif(NOT DBUS_DAEMON)
1427 
1428     find_program(XPLANET xplanet PATHS ${PATHS})
1429     if(NOT XPLANET)
1430         message(WARNING "X Planet program not found in Path, the XPlanet Solar System Simulator won't work without it.")
1431     else(NOT XPLANET)
1432         file(COPY
1433             "${XPLANET}"
1434             DESTINATION "${KSTARS_APP}/Contents/MacOS/")
1435     endif(NOT XPLANET)
1436 
1437     find_program(INDI_SERVER indiserver PATHS ${PATHS})
1438     if(NOT INDI_SERVER)
1439         message(WARNING "indiserver program and drivers not found, you can't run local indi drivers without it.")
1440     else(NOT INDI_SERVER)
1441         get_filename_component(INDI_DRIVERS_DIR "${INDI_SERVER}" DIRECTORY)
1442         # INDISERVER
1443         file(COPY
1444             "${INDI_SERVER}"
1445             DESTINATION "${KSTARS_APP}/Contents/MacOS/")
1446         # INDI Drivers
1447         file(GLOB INDI_DRIVERS
1448             "${INDI_DRIVERS_DIR}/indi*"
1449           )
1450         list(FILTER INDI_DRIVERS EXCLUDE REGEX "dSYM$")
1451         file(COPY ${INDI_DRIVERS} DESTINATION "${KSTARS_APP}/Contents/MacOS/")
1452         # Driver Support Files (Note: On some installations it is in the install prefix, in others in the /usr/local/lib directory)
1453         if(EXISTS "${CMAKE_INSTALL_PREFIX}/usr/local/lib/indi/DriverSupport")
1454             file(COPY "${CMAKE_INSTALL_PREFIX}/usr/local/lib/indi/DriverSupport" DESTINATION "${KSTARS_APP}/Contents/Resources/")
1455         elseif(EXISTS "/usr/local/lib/indi/DriverSupport")
1456             file(COPY "/usr/local/lib/indi/DriverSupport" DESTINATION "${KSTARS_APP}/Contents/Resources/")
1457         endif(EXISTS "${CMAKE_INSTALL_PREFIX}/usr/local/lib/indi/DriverSupport")
1458         file(GLOB XML_FILES
1459             "${CMAKE_INSTALL_PREFIX}/share/indi/*"
1460           )
1461         file(COPY ${XML_FILES} DESTINATION "${KSTARS_APP}/Contents/Resources/DriverSupport/")
1462         file(COPY "${CMAKE_INSTALL_PREFIX}/lib/indi/MathPlugins" DESTINATION "${KSTARS_APP}/Contents/Resources/")
1463         # GPHOTO Stuff
1464         #execute_process(COMMAND "pkg-config --modversion libgphoto2" OUTPUT_VARIABLE GPHOTO_VERSION)
1465         set(GPHOTO_VERSION "2.5.27")
1466         set(PORT_VERSION "0.12.0")
1467         file(GLOB IOLIBS
1468             "${CMAKE_INSTALL_PREFIX}/lib/libgphoto2_port/${PORT_VERSION}/*"
1469           )
1470         list(FILTER IOLIBS EXCLUDE REGEX "dSYM$")
1471         file(COPY ${IOLIBS} DESTINATION "${KSTARS_APP}/Contents/Resources/DriverSupport/gphoto/IOLIBS/")
1472         file(GLOB CAMLIBS
1473             "${CMAKE_INSTALL_PREFIX}/lib/libgphoto2/${GPHOTO_VERSION}/*"
1474           )
1475         list(FILTER CAMLIBS EXCLUDE REGEX "dSYM$")
1476         file(COPY ${CAMLIBS} DESTINATION "${KSTARS_APP}/Contents/Resources/DriverSupport/gphoto/CAMLIBS/")
1477     endif(NOT INDI_SERVER)
1478 
1479     execute_process(COMMAND "${CMAKE_COMMAND}" "-E" "tar" "xvz" "${CMAKE_CURRENT_SOURCE_DIR}/kstars-mac-files/phonon/FrameworksForVLC.zip"
1480         WORKING_DIRECTORY "${KSTARS_APP}/Contents/")
1481     execute_process(COMMAND "${CMAKE_COMMAND}" "-E" "tar" "xvz" "${CMAKE_CURRENT_SOURCE_DIR}/kstars-mac-files/phonon/backend.zip"
1482         WORKING_DIRECTORY "${KSTARS_APP}/Contents/Plugins/")
1483     execute_process(COMMAND "${CMAKE_COMMAND}" "-E" "tar" "xvz" "${CMAKE_CURRENT_SOURCE_DIR}/kstars-mac-files/phonon/vlc.zip"
1484         WORKING_DIRECTORY "${KSTARS_APP}/Contents/Plugins/")
1485     execute_process(COMMAND "${CMAKE_COMMAND}" "-E" "tar" "xvz" "${CMAKE_CURRENT_SOURCE_DIR}/kstars-mac-files/xplanet-data.zip"
1486         WORKING_DIRECTORY "${KSTARS_APP}/Contents/Resources/kstars/")
1487     execute_process(COMMAND "${CMAKE_COMMAND}" "-E" "tar" "xvz" "${CMAKE_CURRENT_SOURCE_DIR}/kstars-mac-files/sounds.zip"
1488         WORKING_DIRECTORY "${KSTARS_APP}/Contents/Resources/")
1489     execute_process(COMMAND "${CMAKE_COMMAND}" "-E" "tar" "xvz" "${CMAKE_CURRENT_SOURCE_DIR}/kstars-mac-files/locale.zip"
1490         WORKING_DIRECTORY "${KSTARS_APP}/Contents/Resources/")
1491     set(KSTARS_VERSION "${KStars_VERSION_MAJOR}.${KStars_VERSION_MINOR}.${KStars_VERSION_REVISION}")
1492     execute_process(COMMAND date "+%Y" OUTPUT_STRIP_TRAILING_WHITESPACE OUTPUT_VARIABLE THIS-YEAR)
1493     set_target_properties(kstars PROPERTIES
1494         MACOSX_BUNDLE TRUE
1495         MACOSX_BUNDLE_INFO_PLIST "${CMAKE_CURRENT_SOURCE_DIR}/kstars-mac-files/macosbundle.plist.in"
1496     )
1497 endif(APPLE)
1498 
1499 if (BUILD_PYKSTARS)
1500   add_subdirectory(python)
1501 endif()
1502 
1503 install(TARGETS kstars ${KDE_INSTALL_TARGETS_DEFAULT_ARGS})
1504 
1505 ########### install files ###############
1506 if(NOT APPLE) # The desktop file is not needed on MacOS and the other two are bundled above
1507 install(PROGRAMS org.kde.kstars.desktop DESTINATION ${KDE_INSTALL_APPDIR})
1508 install(FILES kstars.kcfg DESTINATION ${KDE_INSTALL_KCFGDIR})
1509 install(FILES kstars.notifyrc DESTINATION ${KNOTIFYRC_INSTALL_DIR})
1510 endif(NOT APPLE)
1511 
1512 if(INDI_FOUND)
1513 #install(FILES ekos/mount/mountbox.qml DESTINATION  ${KDE_INSTALL_DATADIR}/kstars/ekos/mount/qml)
1514 #install(DIRECTORY ekos/mount/ DESTINATION ${KDE_INSTALL_DATADIR}/kstars/ekos/mount/qml
1515 #        FILES_MATCHING PATTERN "*.png")
1516 endif()
1517 
1518 if (NOT ANDROID AND BUILD_KSTARS_LITE)
1519     install(TARGETS kstars_lite ${KDE_INSTALL_TARGETS_DEFAULT_ARGS})
1520 endif()