verifysig.parts 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. ############################################################################
  2. # Copyright 2016 Intel Corporation
  3. #
  4. # Licensed under the Apache License, Version 2.0 (the "License");
  5. # you may not use this file except in compliance with the License.
  6. # You may obtain a copy of the License at
  7. #
  8. # http://www.apache.org/licenses/LICENSE-2.0
  9. #
  10. # Unless required by applicable law or agreed to in writing, software
  11. # distributed under the License is distributed on an "AS IS" BASIS,
  12. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. # See the License for the specific language governing permissions and
  14. # limitations under the License.
  15. ############################################################################
  16. Import('*')
  17. env.PartName("verifysig")
  18. src_files = Pattern(src_dir='src/',
  19. includes=['*.c'],
  20. recursive=True).files()
  21. inc_files = Pattern(src_dir='src/',
  22. includes=['*.h'],
  23. recursive=True).files()
  24. parts_file = ['verifysig.parts']
  25. if 'install_package' in env['MODE']:
  26. env.InstallTopLevel(src_files + inc_files, sub_dir='example/${PART_SHORT_NAME}/src')
  27. env.InstallTopLevel(parts_file, sub_dir='example/${PART_SHORT_NAME}')
  28. else:
  29. env.DependsOn([
  30. Component('verifier'),
  31. Component('util')
  32. ])
  33. env.Append(CPPPATH='#/example/verifysig')
  34. if env['TARGET_PLATFORM']['OS'] == 'win32':
  35. if env.isConfigBasedOn('debug'):
  36. env['PDB'] = '${PART_NAME}.pdb'
  37. outputs = env.Program('${PART_NAME}', src_files,
  38. no_import_lib=True)
  39. env.InstallBin(outputs,
  40. no_pkg=False,
  41. INSTALL_BIN='${INSTALL_SAMPLE_BIN}')