Skip to content

Commit

Permalink
Merge pull request #447 from bisdn/jogo_systemdunitdir
Browse files Browse the repository at this point in the history
meson.build: properly get systemd unit path
  • Loading branch information
rubensfig authored Aug 14, 2024
2 parents 17b0a2b + 7975af0 commit 157991a
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,12 @@ sources = files('''

# setup paths
prefixdir = get_option('prefix')
systemunitdir = '/usr/lib/systemd/system'
systemd = dependency('systemd', required: false)
if systemd.found()
systemunitdir = systemd.get_variable('systemdsystemunitdir')
else
systemunitdir = '/lib/systemd/system'
endif
if not prefixdir.startswith('/')
error('Prefix is not absolute: "@0@"'.format(prefixdir))
endif
Expand Down

0 comments on commit 157991a

Please sign in to comment.