Skip to content

Commit

Permalink
Add install commands, glm check
Browse files Browse the repository at this point in the history
  • Loading branch information
hannesha committed Apr 3, 2017
1 parent 909c85e commit 4c721e9
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
build/*
mbuild/*
.*
!.gitignore
!.travis.yml
2 changes: 2 additions & 0 deletions meson.build
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
project('GLMViz', 'cpp')

subdir('src')

install_data(sources: 'config', install_dir: '/etc/GLMViz')
13 changes: 12 additions & 1 deletion src/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,17 @@ dep_fftw = dependency('fftw3f')
dep_glfw = dependency('glfw3')
dep_cfgpp = dependency('libconfig++')
dep_basedir = dependency('libxdg-basedir')
dep_glm = dependency('glm', required: false)

if not dep_glm.found()
message('Can\'t find glm pkg-config file, checking glm headers.')
glm_header = meson.get_compiler('cpp').has_header('glm/glm.hpp')
if glm_header
message('glm found, consider updating your glm library.')
else
error('glm not found!')
endif
endif

opt_pulse = dependency('libpulse', required: false)
opt_pulse_simple = dependency('libpulse-simple', required: false)
Expand All @@ -18,4 +29,4 @@ endif

src = ['GLMViz.cpp', 'Program.cpp', 'FFT.cpp', 'Spectrum.cpp', 'Oscilloscope.cpp', 'Fifo.cpp', 'Buffer.cpp', 'Config.cpp']

exe = executable('glmviz', [src, src_pulse], dependencies: [dep_gl, dep_threads, dep_fftw, dep_glfw, dep_cfgpp, dep_basedir, dep_pulse])
exe = executable('glmviz', [src, src_pulse], dependencies: [dep_gl, dep_threads, dep_fftw, dep_glfw, dep_cfgpp, dep_basedir, dep_pulse], install: true)

0 comments on commit 4c721e9

Please sign in to comment.