mkver.py 304 B

12345678910111213
  1. from __future__ import print_function
  2. import sys
  3. if __name__ == '__main__':
  4. with open(sys.argv[1], 'r') as f:
  5. data = f.readline()
  6. beg = data.find('(') + 1
  7. end = data.find(')')
  8. version = data[beg:end]
  9. print('#pragma once')
  10. print('#define DEBIAN_VERSION "%s"' % version)