diff --git a/meson.build b/meson.build new file mode 100644 --- /dev/null +++ b/meson.build @@ -0,0 +1,10 @@ +project('SocExplorer','c','cpp') + +qt5_mod = import('qt5') +qt5widgets = dependency('qt5', modules: ['Gui']) +qt5printsupport = dependency('qt5', modules: ['PrintSupport']) +qt5network = dependency('qt5', modules: ['Network']) +qt5svg = dependency('qt5', modules: ['Svg']) +pkg = import('pkgconfig') + +subdir('src') diff --git a/src/common/meson.build b/src/common/meson.build new file mode 100644 --- /dev/null +++ b/src/common/meson.build @@ -0,0 +1,90 @@ +moc_headers=[ + 'QCustomPlot/qcustomplot.h', + 'SocExplorerPlot.h', + 'tcp_terminal_client.h', + 'genericBinaryFiles/elf/elfinfowdgt.h', + 'genericBinaryFiles/elf/elffile.h', + 'genericBinaryFiles/elf/elffilewidget.h', + 'qipdialogbox.h', + 'genericBinaryFiles/srec/srecfile.h', + 'genericBinaryFiles/srec/srecfilewidget.h', + 'genericBinaryFiles/BinFile/binaryfile.h', + 'genericBinaryFiles/BinFile/binaryfilewidget.h', + 'genericBinaryFiles/genericbinaryfilewidget.h', + 'genericBinaryFiles/abstractbinfile.h', + 'genericBinaryFiles/qvpushbutton.h', + 'genericBinaryFiles/filelist.h', + 'qhexedit/qhexedit.h', + 'qhexedit/qhexedit_p.h', + 'memsizewdgt.h', + 'qhexspinbox.h', + ] + +moc_sources=[] + +ui_files = [ + 'genericBinaryFiles/elf/elffilewidget.ui', + 'genericBinaryFiles/srec/srecfilewidget.ui', + 'genericBinaryFiles/BinFile/binaryfilewidget.ui', + 'genericBinaryFiles/genericbinaryfilewidget.ui'] + +processed = qt5_mod.preprocess( + moc_headers : moc_headers, # Only headers that need moc should be put here + moc_sources : moc_sources, # must have #include"moc_helperFile.cpp" + ui_files : ui_files, + qresources : ['genericBinaryFiles/ressources/genericBinaryFiles.qrc'] +) + +if target_machine.system() == 'windows' + lppserial_sources = 'lppserial/src/RS232_win.c' +else + lppserial_sources = 'lppserial/src/RS232_unix.c' +endif + +sources = [ + lppserial_sources, + 'qsvgicon.cpp', + 'genericBinaryFiles/elf/elfparser.cpp', + 'genericBinaryFiles/qtablewidgetintitem.cpp', + 'genericBinaryFiles/genericbinaryfilewidget.cpp', + 'qhexedit/xbytearray.cpp', + 'qhexedit/commands.cpp', + 'memsizewdgt.cpp', + 'qhexspinbox.cpp', + 'qhexedit/qhexedit_p.cpp', + 'qhexedit/qhexedit.cpp', + 'QCustomPlot/qcustomplot.cpp', + 'tcp_terminal_client.cpp', + 'genericBinaryFiles/elf/elfinfowdgt.cpp', + 'genericBinaryFiles/elf/elffile.cpp', + 'qipdialogbox.cpp', + 'SocExplorerPlot.cpp', + 'genericBinaryFiles/elf/elffilewidget.cpp', + 'genericBinaryFiles/srec/srecfile.cpp', + 'genericBinaryFiles/srec/srecfilewidget.cpp', + 'genericBinaryFiles/abstractbinfile.cpp', + 'genericBinaryFiles/BinFile/binaryfile.cpp', + 'genericBinaryFiles/BinFile/binaryfilewidget.cpp', + 'genericBinaryFiles/qvpushbutton.cpp', + 'genericBinaryFiles/filelist.cpp', + processed +] + +inc = ['QCustomPlot','genericBinaryFiles','genericBinaryFiles/srec','genericBinaryFiles/BinFile','qhexedit'] + +libelf = dependency('libelf', fallback:['libelf','libelf_dep']) + +socexplorercommon = shared_library('socexplorercommon', + sources, + include_directories: include_directories(inc), + dependencies: [qt5widgets, qt5printsupport, qt5network, qt5svg,libelf], + install: true + ) + + +pkg.generate(libraries : socexplorercommon, + subdirs : inc, + version : '1.0', + name : 'libsocexplorercommon', + filebase : 'socexplorercommon', + description : 'SocExplorer common.') diff --git a/src/meson.build b/src/meson.build new file mode 100644 --- /dev/null +++ b/src/meson.build @@ -0,0 +1,1 @@ +subdir('common') diff --git a/subprojects/libelf.wrap b/subprojects/libelf.wrap new file mode 100644 --- /dev/null +++ b/subprojects/libelf.wrap @@ -0,0 +1,11 @@ +[wrap-file] +directory = libelf-0.8.13 + +source_url = http://www.mr511.de/software/libelf-0.8.13.tar.gz +source_filename = libelf-0.8.13.tar.gz +source_hash = 591a9b4ec81c1f2042a97aa60564e0cb79d041c52faa7416acb38bc95bd2c76d + +patch_url = file:///home/jeandet/Téléchargements/test/libelf-wrap-0.8.13.zip +patch_filename = libelf-wrap-0.8.13.zip +patch_hash = 37c3a3a47240e4fb06400263b8e2183333f5f9ef405dfcc28074da269e191f73 +