home *** CD-ROM | disk | FTP | other *** search
/ Hand Held Organizer Toolkit / walnutcreekcdrom-handheldorganizertoolkit-march1998.iso / PalmPilot / development / pfc.sit / Makefile next >
Makefile  |  1997-04-08  |  4KB  |  138 lines

  1. #######################################################
  2. #   Makefile for TestApp
  3. #   Target:     TestApp
  4. #
  5. #   This makefile compiles and links the TestApp sample
  6. #   application for testing custom fonts.
  7. #
  8. #   To run this make, use the MPW Directory Menu to set 
  9. #   the current directory to the MemoPad directory, go to
  10. #   the Build Menu, select "Build..." and enter "TestApp"
  11. #     into the dialog box.
  12. #   
  13. #######################################################
  14.  
  15.  
  16.  
  17. #######################################################
  18. # Set up paths
  19. ########################################################
  20. LIB_DIR = :::Libraries:PalmOS:
  21. INC_DIR = :::Incs:
  22. SRC_DIR = :Src:
  23. OBJ_DIR = :Obj:
  24.  
  25.  
  26. #######################################################
  27. # Set up Compiler
  28. ########################################################
  29. # Use Metrowerks'  compiler          
  30. CC = MWC68K 
  31. CPP = MWC68K 
  32. LINK = MWLink68K
  33.  
  34.  
  35. #######################################################
  36. # Compile Options
  37. #
  38. # The most likely options you might change are COUNTRY,
  39. #  LANGUAGE, and ERROR_CHECK_LEVEL.
  40. ########################################################
  41. C_OPTIONS = ╢
  42.                 -d COUNTRY=0    ╢
  43.                 -d LANGUAGE=0    ╢
  44.                   -d ERROR_CHECK_LEVEL=2 ╢
  45.                 -d CMD_LINE_BUILD ╢
  46.                   -d EMULATION_LEVEL=0 ╢
  47.                   -d ENVIRONMENT=0 ╢
  48.                   -d MEMORY_FORCE_LOCK=1 ╢
  49.                 -nosyspath ╢
  50.                 -i ":Src:" ╢
  51.                 -i "{INC_DIR}" ╢
  52.                 -i "{INC_DIR}System:" ╢
  53.                 -i "{INC_DIR}UI:" ╢
  54.                 -i "{INC_DIR}Hardware:" ╢
  55.                 -model near ╢
  56.                 -intsize 2 ╢
  57.                 -maxerrors 3 ╢
  58.                 -opt speed -opt global -opt peep ╢
  59.                   -mbg on ╢
  60.                 -b ╢
  61.                 -d PILOT_PRECOMPILED_HEADERS_OFF 
  62.                 
  63.  
  64. LINK_OPTIONS = -single -custom
  65.  
  66.  
  67. #######################################################
  68. # Object List
  69. #
  70. # Each of the source files must be listed here.
  71. ########################################################
  72. OBJECTS = ╢
  73.              "{LIB_DIR}StartupCode.c.o" ╢
  74.              "{OBJ_DIR}CustomFonts.c.o" ╢
  75.              "{OBJ_DIR}TestApp.c.o" 
  76. #             "{OBJ_DIR}Module2.c.o" ╢            Add other source files here
  77.              
  78.  
  79.  
  80. ########################################################################
  81. # Compiles
  82. #
  83. # There should be one compile statement per source file.  On the right side of
  84. # the first line is a list of files the target is dependent on.  Only if 
  85. # one of those files changes is the target regenerated.
  86. ########################################################################
  87. "{OBJ_DIR}TestApp.c.o" ─ MakeFile "{SRC_DIR}TestApp.c"
  88.      {CPP}  -o "{OBJ_DIR}TestApp.c.o" ╢
  89.              "{SRC_DIR}TestApp.c" ╢
  90.             {C_OPTIONS} 
  91.      
  92. "{OBJ_DIR}CustomFonts.c.o" ─ MakeFile "{SRC_DIR}CustomFonts.c"
  93.      {CPP}  -o "{OBJ_DIR}CustomFonts.c.o" ╢
  94.              "{SRC_DIR}CustomFonts.c" ╢
  95.             {C_OPTIONS} 
  96.      
  97.  
  98. ########################################################################
  99. # Final Link
  100. ########################################################################
  101. TestApp ── MakeFile  {OBJECTS} "{SRC_DIR}TestApp.r" 
  102. #
  103. #    Link all of the code together.
  104. #
  105.     {LINK} {LINK_OPTIONS} -t rsrc -c RSED ╢
  106.         {OBJECTS} ╢
  107.         -o TestApp.code
  108.     Delete -i  "TestApp"
  109. #
  110. #    Build a description of all the resources used by the application
  111. #
  112.     {CC} -d RESOURCE_COMPILER ╢
  113.             {C_OPTIONS} ╢
  114.             -e ╢
  115.             "{SRC_DIR}TestApp.r" > TestApp.i
  116. #
  117. #    Process the ui resources and combine them and the code into a single file
  118. #    for use on the Pilot.  Additionally, set other data about the Pilot file
  119. #    like it's type, creator, version number, name, etc.  Type PilotRez 
  120. #    in the MPW Worksheet to see a description of PilotRez's options.
  121. #
  122.     PilotRez -v 1 -t appl -c Test -it TestApp.i -ot "TestApp"
  123. #    
  124. #    Pilot Desktop prefers Pilot files to end with .prc
  125. #
  126.     Duplicate -y "TestApp" "TestApp.prc"
  127. #
  128. #    PilotDebugger is used by application developers to send the Pilot application
  129. #    to the Pilot.  Place a duplicate of the file in a place handy for the debugger.
  130. #
  131.     Duplicate -y "TestApp.prc"  "{PilotDir}"Debugger
  132.         
  133.         
  134.             
  135.  
  136.  
  137.