ktigcc.pro 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176
  1. TEMPLATE = app
  2. LANGUAGE = C++
  3. CONFIG += qt warn_on debug
  4. LIBS += -lktexteditor -lqassistantclient -lkutils
  5. HEADERS += tpr.h \
  6. ktigcc.h \
  7. preferences.h \
  8. srcfile.h \
  9. tiemu.h \
  10. tiemu_stub.h \
  11. callbacks.h \
  12. parsing.h
  13. SOURCES += ktigcc.cpp \
  14. preferences.cpp \
  15. tpr.cpp \
  16. tiemu_stub.cpp \
  17. callbacks.cpp \
  18. parsing.cpp
  19. FORMS = srcfilewin.ui \
  20. projectoptions.ui \
  21. programoptions.ui \
  22. preferencesdlg.ui \
  23. mainform.ui \
  24. errorlist.ui \
  25. programoutput.ui \
  26. functions.ui \
  27. newsdlg.ui
  28. IMAGES = images/00 \
  29. images/01 \
  30. images/02 \
  31. images/03 \
  32. images/04 \
  33. images/05 \
  34. images/06 \
  35. images/07 \
  36. images/08 \
  37. images/09 \
  38. images/10 \
  39. images/11 \
  40. images/12 \
  41. images/13 \
  42. images/14 \
  43. images/15 \
  44. images/16 \
  45. images/17 \
  46. images/18 \
  47. images/19 \
  48. images/20 \
  49. images/21 \
  50. images/22 \
  51. images/23 \
  52. images/24 \
  53. images/25 \
  54. images/26 \
  55. images/27 \
  56. images/tpr.png \
  57. images/folder1.png \
  58. images/folder2.png \
  59. images/filec.png \
  60. images/fileh.png \
  61. images/fileo.png \
  62. images/files.png \
  63. images/filet.png \
  64. images/filex.png \
  65. images/icon.png \
  66. images/filereplace.png \
  67. images/error.png \
  68. images/warning.png \
  69. images/info.png \
  70. images/ktigcc.png
  71. # If this is not used, a build from /usr/.... will generate
  72. # Makefiles with relative paths for install. This totally
  73. # fucks up using INSTALL_ROOT for a staged install.
  74. # See http://bugs.debian.org/180240
  75. # (Thanks to Debian for the fix for this qmake stupidity.)
  76. QMAKE_PROJECT_DEPTH=1
  77. unix {
  78. UI_DIR = .ui
  79. MOC_DIR = .moc
  80. OBJECTS_DIR = .obj
  81. }
  82. !exists($$QMAKE_INCDIR_QT/qassistantclient.h) {
  83. error("Qt Assistant 3 headers required, try installing qt3-apps-dev.")
  84. }
  85. KDEPREFIX = $$system(kde-config --prefix)
  86. isEmpty(KDEPREFIX):error(KDE 3 kdelibs required.)
  87. exists($$KDEPREFIX/include/kde3) {
  88. INCLUDEPATH += $$KDEPREFIX/include/kde3
  89. } else:exists($$KDEPREFIX/include/kde) {
  90. INCLUDEPATH += $$KDEPREFIX/include/kde
  91. } else {
  92. INCLUDEPATH += $$KDEPREFIX/include
  93. }
  94. KDELIBDIR = $$KDEPREFIX/lib$$system(kde-config --libsuffix)
  95. !equals(KDELIBDIR,/usr/lib):!equals(KDELIBDIR,/usr/lib64) {
  96. LIBS += -L"$$KDELIBDIR" -Wl,--rpath,"$$KDELIBDIR"
  97. }
  98. GLIB2_MINVERSION = 2.0.0
  99. HAVE_GLIB2 = $$system(pkg-config --atleast-version=$$GLIB2_MINVERSION glib-2.0 && echo yes || echo no)
  100. !equals(HAVE_GLIB2,yes):error(glib2 $$GLIB2_MINVERSION or higher required.)
  101. PKGCONFIG_CFLAGS += $$system(pkg-config --cflags glib-2.0)
  102. LIBS += $$system(pkg-config --libs glib-2.0)
  103. TICONV_MINVERSION = 0.0.1
  104. HAVE_TICONV = $$system(pkg-config --atleast-version=$$TICONV_MINVERSION ticonv && echo yes || echo no)
  105. !equals(HAVE_TICONV,yes):error(libticonv $$TICONV_MINVERSION or higher required.)
  106. PKGCONFIG_CFLAGS += $$system(pkg-config --cflags ticonv)
  107. LIBS += $$system(pkg-config --libs ticonv)
  108. TICABLES_MINVERSION = 0.1.3
  109. HAVE_TICABLES = $$system(pkg-config --atleast-version=$$TICABLES_MINVERSION ticables2 && echo yes || echo no)
  110. !equals(HAVE_TICABLES,yes):error(libticables2 $$TICABLES_MINVERSION or higher required.)
  111. PKGCONFIG_CFLAGS += $$system(pkg-config --cflags ticables2)
  112. LIBS += $$system(pkg-config --libs ticables2)
  113. TIFILES_MINVERSION = 0.0.9
  114. HAVE_TIFILES = $$system(pkg-config --atleast-version=$$TIFILES_MINVERSION tifiles2 && echo yes || echo no)
  115. !equals(HAVE_TIFILES,yes):error(libtifiles2 $$TIFILES_MINVERSION or higher required.)
  116. PKGCONFIG_CFLAGS += $$system(pkg-config --cflags tifiles2)
  117. LIBS += $$system(pkg-config --libs tifiles2)
  118. TICALCS_MINVERSION = 0.2.4
  119. HAVE_TICALCS = $$system(pkg-config --atleast-version=$$TICALCS_MINVERSION ticalcs2 && echo yes || echo no)
  120. !equals(HAVE_TICALCS,yes):error(libticalcs2 $$TICALCS_MINVERSION or higher required.)
  121. PKGCONFIG_CFLAGS += $$system(pkg-config --cflags ticalcs2)
  122. LIBS += $$system(pkg-config --libs ticalcs2)
  123. syntaxfiles.path = /usr/share/apps/katepart/syntax/
  124. syntaxfiles.files = gnuasm68k.xml masm68k.xml
  125. INSTALLS += syntaxfiles
  126. TIGCC = $$(TIGCC)
  127. isEmpty(TIGCC) {
  128. TIGCC = /usr/local/tigcc
  129. }
  130. target.path = $$TIGCC/bin
  131. documentation.path = $$TIGCC/doc/ktigcc
  132. documentation.files = COPYING
  133. INSTALLS += target documentation
  134. CXXFLAGS = $$(CXXFLAGS)
  135. isEmpty(CXXFLAGS) {
  136. debug {
  137. CXXFLAGS = -Os -g
  138. } else {
  139. CXXFLAGS = -Os -s -fomit-frame-pointer
  140. }
  141. }
  142. QMAKE_CXXFLAGS_DEBUG = $$CXXFLAGS -Wno-non-virtual-dtor $$PKGCONFIG_CFLAGS
  143. QMAKE_CXXFLAGS_RELEASE = $$CXXFLAGS -Wno-non-virtual-dtor $$PKGCONFIG_CFLAGS
  144. QMAKE_LFLAGS_RELEASE = -s
  145. DISTFILES += $${syntaxfiles.files} $${documentation.files} INSTALL configure KTIGCC.prj fedora/ktigcc.spec images/copyright.txt
  146. distbz2.target = dist-bzip2
  147. distbz2.commands = zcat ktigcc.tar.gz | bzip2 --best -c > ktigcc.tar.bz2
  148. distbz2.depends = dist
  149. rpm.target = rpm
  150. rpm.commands = rpmbuild -ta ktigcc.tar.bz2
  151. rpm.depends = distbz2
  152. QMAKE_EXTRA_UNIX_TARGETS += distbz2 rpm