mk-include.sh 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. #!/bin/bash
  2. # /****************************************************************************
  3. # **
  4. # ** Created using Monkey Studio IDE v1.8.4.0 (1.8.4.0)
  5. # ** Authors : Filipe AZEVEDO aka Nox P@sNox <pasnox@gmail.com>
  6. # ** Project : Fresh Library
  7. # ** FileName : mk-include.sh
  8. # ** Date : 2011-02-20T00:44:25
  9. # ** License : LGPL v3
  10. # ** Home Page : https://github.com/pasnox/fresh
  11. # ** Comment : Fresh Library is a Qt 4 extension library providing set of new core & gui classes.
  12. # **
  13. # ** This program is free software: you can redistribute it and/or modify
  14. # ** it under the terms of the GNU Leser General Public License as published by
  15. # ** the Free Software Foundation, either version 3 of the License, or
  16. # ** (at your option) any later version.
  17. # **
  18. # ** This package is distributed in the hope that it will be useful,
  19. # ** but WITHOUT ANY WARRANTY; without even the implied warranty of
  20. # ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  21. # ** GNU Lesser General Public License for more details.
  22. # **
  23. # ** You should have received a copy of the GNU Lesser General Public License
  24. # ** along with this program. If not, see <http://www.gnu.org/licenses/>.
  25. # **
  26. # ****************************************************************************/
  27. CORE_HEADERS=`find src/core -type f -name '*.h'`
  28. GUI_HEADERS=`find src/gui -type f -name '*.h'`
  29. rm -fr include
  30. mkdir -p include/FreshCore
  31. mkdir -p include/FreshGui
  32. for header in ${CORE_HEADERS};
  33. do
  34. headerFileName=`basename "${header}"`
  35. if [ "${headerFileName}" == "Core.h" ]; then
  36. continue;
  37. fi
  38. headerBaseName=`basename "${header}" .h`
  39. echo "#include \"${headerFileName}\"" >> "include/FreshCore/${headerBaseName}"
  40. done
  41. for header in ${GUI_HEADERS};
  42. do
  43. headerFileName=`basename "${header}"`
  44. if [ "${headerFileName}" == "Gui.h" ]; then
  45. continue;
  46. fi
  47. headerBaseName=`basename "${header}" .h`
  48. echo "#include \"${headerFileName}\"" >> "include/FreshGui/${headerBaseName}"
  49. done