Index: /trunk/platform/s5is/sub/101a/boot.c
===================================================================
--- /trunk/platform/s5is/sub/101a/boot.c	(revision 954)
+++ /trunk/platform/s5is/sub/101a/boot.c	(revision 955)
@@ -2,4 +2,5 @@
 #include "platform.h"
 #include "core.h"
+#include "stdlib.h"
 
 const char * const new_sa = &_end;
Index: /trunk/platform/s5is/sub/101b/boot.c
===================================================================
--- /trunk/platform/s5is/sub/101b/boot.c	(revision 954)
+++ /trunk/platform/s5is/sub/101b/boot.c	(revision 955)
@@ -2,4 +2,5 @@
 #include "platform.h"
 #include "core.h"
+#include "stdlib.h"
 
 const char * const new_sa = &_end;
Index: /trunk/platform/ixus40_sd300/kbd.c
===================================================================
--- /trunk/platform/ixus40_sd300/kbd.c	(revision 954)
+++ /trunk/platform/ixus40_sd300/kbd.c	(revision 955)
@@ -43,5 +43,5 @@
 } SEM_B_STATE;
 
-typedef void *SEM_ID; 
+typedef int SEM_ID; 
 extern SEM_ID _semBCreate(int options, SEM_B_STATE initialState);
 extern STATUS _TakeSemaphore(SEM_ID, int);
Index: /trunk/platform/ixus60_sd600/kbd.c
===================================================================
--- /trunk/platform/ixus60_sd600/kbd.c	(revision 954)
+++ /trunk/platform/ixus60_sd600/kbd.c	(revision 955)
@@ -3,4 +3,5 @@
 #include "core.h"
 #include "keyboard.h"
+#include "stdlib.h"
 
 #define KEY_MASK 0x17FF
Index: /trunk/platform/g11/sub/100f/boot.c
===================================================================
--- /trunk/platform/g11/sub/100f/boot.c	(revision 954)
+++ /trunk/platform/g11/sub/100f/boot.c	(revision 955)
@@ -773,5 +773,5 @@
                "BL      sub_FF8398B4\n"
              //"ADR     R2, sub_FF860490\n"
-               "ADR     R2, sub_FF860490_my\n" //+
+               "ADRL     R2, sub_FF860490_my\n" //+
                "MOV     R1, R2\n"
                "ORR     R3, R4, #0x200\n"
@@ -892,5 +892,5 @@
                "BEQ     loc_FF860810\n"
             // "ADR     R2, sub_FF860490\n"
-               "ADR     R2, sub_FF860490_my\n" //+
+               "ADRL     R2, sub_FF860490_my\n" //+
                "MOV     R1, R2\n"
                "ORR     R3, R4, #0x400\n"
Index: /trunk/platform/g11/sub/100j/boot.c
===================================================================
--- /trunk/platform/g11/sub/100j/boot.c	(revision 954)
+++ /trunk/platform/g11/sub/100j/boot.c	(revision 955)
@@ -491,5 +491,5 @@
                "LDMEQFD SP!, {R4-R8,LR}\n"
                "LDREQ   R0, =0xFF86F9A8\n"
-			   "BEQ     0xFF81175C\n" //qPrintf
+			   "BEQ     =0xFF81175C\n" //qPrintf
                "LDMFD   SP!, {R4-R8,PC}\n"
  );
@@ -682,5 +682,5 @@
                  "LDR     R0, =0xFF86F378\n"
                  
-				 "BL   0xFF81E88C\n"
+				 "BL   	  =0xFF81E88C\n"
 
 "loc_FF86F340:\n"
@@ -779,5 +779,5 @@
                "LDR     R0, [R5,R4,LSL#2]\n"
                "BL      sub_FF8398E4\n"
-               "ADR     R2, sub_FF8604E0_my\n"
+               "ADRL     R2, sub_FF8604E0_my\n"
 //               "LDR     R2, sub_FF8604E0\n"
                "ADD     R1, R2, #0\n"
@@ -900,5 +900,5 @@
                "BEQ     loc_FF860860\n"
 //               "ADR     R2, loc_FF8604E0\n"
-               "ADR     R2,sub_FF8604E0_my\n"
+               "ADRL     R2,sub_FF8604E0_my\n"
                "ADD     R1, R2, #0\n"
                "ORR     R3, R4, #0x400\n"
Index: /trunk/platform/ixus65_sd630/kbd.c
===================================================================
--- /trunk/platform/ixus65_sd630/kbd.c	(revision 954)
+++ /trunk/platform/ixus65_sd630/kbd.c	(revision 955)
@@ -3,4 +3,5 @@
 #include "core.h"
 #include "keyboard.h"
+#include "stdlib.h"
 
 #define KEY_MASK 0x17FF
Index: /trunk/platform/ixus65_sd630/sub/100a/lib.c
===================================================================
--- /trunk/platform/ixus65_sd630/sub/100a/lib.c	(revision 954)
+++ /trunk/platform/ixus65_sd630/sub/100a/lib.c	(revision 955)
@@ -40,5 +40,5 @@
 void *vid_get_viewport_fb_d()
 {
-    return 0x104AFCA0;
+    return (void*)0x104AFCA0;
     //return (void*)(*(int*));
 }
Index: /trunk/platform/a2000/sub/100c/capt_seq.c
===================================================================
--- /trunk/platform/a2000/sub/100c/capt_seq.c	(revision 954)
+++ /trunk/platform/a2000/sub/100c/capt_seq.c	(revision 955)
@@ -22,6 +22,6 @@
 "                LDR     R1, =0x539\n"
 "                LDR     R0, =0xFFC4AA98\n"			// "SsShootTask.c"
-"                BL      0xFFC0BD98\n"				// DebugAssert
-"                BL      0xFFC0BB50\n"				// eventproc_export_ExitTask ; LOCATION: KerTask.c:0
+"                BL      =0xFFC0BD98\n"				// DebugAssert
+"                BL      =0xFFC0BB50\n"				// eventproc_export_ExitTask ; LOCATION: KerTask.c:0
 "                LDMFD   SP!, {R3-R7,PC}\n"
 "loc_FFC4AEB8:\n"
Index: /trunk/platform/ixus100_sd780/kbd.c
===================================================================
--- /trunk/platform/ixus100_sd780/kbd.c	(revision 954)
+++ /trunk/platform/ixus100_sd780/kbd.c	(revision 955)
@@ -4,5 +4,7 @@
 #include "keyboard.h"
 #include "conf.h"
-//#include "stdlib.h"
+#include "stdlib.h"
+#include "gui.h"
+#include "../../core/gui_draw.h"
 
 typedef struct {
@@ -203,5 +205,5 @@
 		"stmdb sp!, {r0, r1, lr}\n"
 		"mov r0, sp\n"
-		"BL 0xFF922E14\n"  //GetLogToFile
+		"BL =0xFF922E14\n"  //GetLogToFile
 		"ldmia sp!, {r0, r1, lr}\n"
 	);
@@ -212,7 +214,7 @@
 	int i;
 	char aStr[50];
-	void* l;
-
-	l=(void*)Fopen_Fut("A/PropDmp.txt","a");
+	long l;
+
+	l=Fopen_Fut("A/PropDmp.txt","a");
 	for (i=0;i<300;i++){
 		_GetPropertyCase(i, &avv, sizeof(avv));	// 23 for DiGiC III
@@ -229,5 +231,5 @@
 	#define FWSIZE            0x30
 
-	void* l;
+	long l;
 	int j,k;
 	int* myPtr, myPtr2;
@@ -245,5 +247,5 @@
 	j=0;
 
-	l=(void*)Fopen_Fut("A/aHookList.txt","ab");
+	l=Fopen_Fut("A/aHookList.txt","ab");
 
 	while (j<aHookNum)
Index: /trunk/platform/ixus100_sd780/wrappers.c
===================================================================
--- /trunk/platform/ixus100_sd780/wrappers.c	(revision 954)
+++ /trunk/platform/ixus100_sd780/wrappers.c	(revision 955)
@@ -18,7 +18,9 @@
 }
 
-//VERIFY_SD780 Only one arg?
-long OpLog_Get(long i)
-{
-	return _OpLog_Get(i);
-}
+// VERIFY_SD780 Only one arg? - unknown
+// I dared to comment it out, because it produced
+// a warning, but is not called anywhere - ultimA
+//long OpLog_Get(long i)
+//{
+//	return _OpLog_Get(i);
+//}
Index: /trunk/platform/ixus100_sd780/sub/100c/capt_seq.c
===================================================================
--- /trunk/platform/ixus100_sd780/sub/100c/capt_seq.c	(revision 954)
+++ /trunk/platform/ixus100_sd780/sub/100c/capt_seq.c	(revision 955)
@@ -685,5 +685,5 @@
 			"                MOV     R1, #1\n"
 			"                BL      sub_FF866178\n"
-			"                BL      0xFF81B23C\n"		//ExitTask
+			"                BL      =0xFF81B23C\n"		//ExitTask
 			"                ADD     SP, SP, #0x20\n"
 			"                LDMFD   SP!, {R4-R8,PC}\n"
@@ -738,5 +738,5 @@
 			"loc_FF899E10:\n"
 			"                LDR     R0, =0xFF896C24\n"  //aExpdrv_c
-			"                BL      0xFF81B284\n" 		//DebugAssert
+			"                BL      =0xFF81B284\n" 		//DebugAssert
 			"                B       loc_FF899DB8\n"
 			"loc_FF899E1C:\n"
@@ -1186,5 +1186,5 @@
 			"                LDRNE   R1, =0x583\n"
 			"                LDRNE   R0, =0xFF896C24\n" //aExpdrv_c
-			"                BLNE    0xFF81B284\n"  //DebugAssert
+			"                BLNE    =0xFF81B284\n"  //DebugAssert
 			"loc_FF897740:\n"
 			"                CMP     R5, #1\n"
@@ -1198,5 +1198,5 @@
 			"                LDRNE   R0, =0xFF896C24\n" //aExpdrv_c
 			"                LDMNEFD SP!, {R4-R8,LR}\n"
-			"                BNE     0xFF81B284\n"  //DebugAssert
+			"                BNE     =0xFF81B284\n"  //DebugAssert
 			"                LDMFD   SP!, {R4-R8,PC}\n"
 );
@@ -1216,5 +1216,5 @@
 			"                MOVNE   R1, #0x140\n"
 			"                LDRNE   R0, =0xFF888D10\n"  //aShutter_c
-			"                BLNE    0xFF81B284\n"  //DebugAssert
+			"                BLNE    =0xFF81B284\n"  //DebugAssert
 			"                CMN     R4, #0xC00\n"
 			"                LDREQSH R4, [R5,#2]\n"
@@ -1223,5 +1223,5 @@
 			"                LDREQ   R0, =0xFF888D10\n"  //aShutter_c
 			"                STRH    R4, [R5,#2]\n"
-			"                BLEQ    0xFF81B284\n"  //DebugAssert
+			"                BLEQ    =0xFF81B284\n"  //DebugAssert
 			"                MOV     R0, R4\n"
 //			"                BL      sub_FF9A010C\n" //--
@@ -1236,5 +1236,5 @@
 			"                LDMNEFD SP!, {R4-R6,LR}\n"
 			"                LDRNE   R0, =0xFF888D10\n"  //aShutter_c
-			"                BNE     0xFF81B284\n"  //DebugAssert
+			"                BNE     =0xFF81B284\n"  //DebugAssert
 			"                LDMFD   SP!, {R4-R6,PC}\n"
 );
Index: /trunk/platform/ixus100_sd780/sub/100c/boot.c
===================================================================
--- /trunk/platform/ixus100_sd780/sub/100c/boot.c	(revision 954)
+++ /trunk/platform/ixus100_sd780/sub/100c/boot.c	(revision 955)
@@ -2,4 +2,7 @@
 #include "platform.h"
 #include "core.h"
+#include "stdlib.h"
+#include "gui.h"
+#include "../../../../core/gui_draw.h"
 
 const char * const new_sa = &_end;
@@ -8,5 +11,5 @@
 extern long wrs_kernel_bss_start;
 extern long wrs_kernel_bss_end;
-long aHookList[128];
+int* aHookList[128];
 long aHookNum=0;
 
@@ -139,13 +142,13 @@
 int jF;
 
-	void* l;
+	long l;
 	char filen[32];
 
-	l=(void*)Fopen_Fut("A/0xCF90a.bin","ab");
-	Fwrite_Fut(START_ADDRESS,1,FWSIZE,l);
+	l = Fopen_Fut("A/0xCF90a.bin","ab");
+	Fwrite_Fut((void*)(START_ADDRESS),1,FWSIZE,l);
 	Fflush_Fut(l);
 	Fclose_Fut(l);
-	l=(void*)Fopen_Fut("A/0xCF90b.bin","ab");
-	Fwrite_Fut(START_ADDRESS2,1,FWSIZE,l);
+	l = Fopen_Fut("A/0xCF90b.bin","ab");
+	Fwrite_Fut((void*)(START_ADDRESS2),1,FWSIZE,l);
 	Fflush_Fut(l);
 	Fclose_Fut(l);
Index: /trunk/core/edgeoverlay.c
===================================================================
--- /trunk/core/edgeoverlay.c	(revision 954)
+++ /trunk/core/edgeoverlay.c	(revision 955)
@@ -1,4 +1,6 @@
+#include "platform.h"
+
+#ifdef OPT_EDGEOVERLAY
 #include "edgeoverlay.h"
-#include "platform.h"
 #include "conf.h"
 #include "keyboard.h"
@@ -765,2 +767,5 @@
 
 }   // function
+
+#endif
+
Index: /trunk/core/gui.c
===================================================================
--- /trunk/core/gui.c	(revision 954)
+++ /trunk/core/gui.c	(revision 955)
@@ -43,5 +43,7 @@
 	#include "curves.h"
 #endif
-#include "edgeoverlay.h"
+#ifdef OPT_EDGEOVERLAY
+	#include "edgeoverlay.h"
+#endif
 //-------------------------------------------------------------------
 
@@ -159,6 +161,4 @@
 static void gui_draw_load_lang(int arg);
 static void gui_menuproc_mkbootdisk(int arg);
-static void gui_menuproc_edge_save(int arg);
-static void gui_menuproc_edge_load(int arg);
 #ifdef OPT_DEBUGGING
 void gui_compare_props(int arg);
@@ -256,5 +256,9 @@
 #endif
 
+#ifdef OPT_EDGEOVERLAY
+static void gui_menuproc_edge_save(int arg);
+static void gui_menuproc_edge_load(int arg);
 static const char* gui_edge_pano_enum(int change, int arg);
+#endif
 
 void rinit();
@@ -2046,9 +2050,4 @@
 //		if (conf.zoom_override) shooting_set_zoom(conf.zoom_override_value);
 #endif
-}
-
-static void gui_load_edge_selected( const char* fn ) {
-    if( fn )
-	load_edge_overlay(fn);
 }
 
@@ -3205,4 +3204,10 @@
 }
 
+#ifdef OPT_EDGEOVERLAY
+static void gui_load_edge_selected( const char* fn ) {
+    if( fn )
+	load_edge_overlay(fn);
+}
+
 void gui_menuproc_edge_save(int arg) {
     save_edge_overlay();
@@ -3224,4 +3229,5 @@
     gui_fselect_init(LANG_MENU_EDGE_LOAD, path, gui_load_edge_selected);
 }
+#endif
 
 //-------------------------------------------------------------------
@@ -3364,4 +3370,18 @@
  	}
 }
+
+#ifdef OPT_EDGEOVERLAY
+static const char* gui_edge_pano_enum(int change, int arg)
+{
+    static const char* modes[]={ "Off", "Right", "Down", "Left", "Up", "Free"};
+
+    conf.edge_overlay_pano+=change;
+    if (conf.edge_overlay_pano<0) 
+        conf.edge_overlay_pano=(sizeof(modes)/sizeof(modes[0]))-1; 
+    else if (conf.edge_overlay_pano>=(sizeof(modes)/sizeof(modes[0]))) 
+        conf.edge_overlay_pano=0; 
+    return modes[conf.edge_overlay_pano]; 
+}
+#endif
 
 #ifdef OPT_DEBUGGING
@@ -3415,15 +3435,3 @@
 }
 
-static const char* gui_edge_pano_enum(int change, int arg)
-{
-    static const char* modes[]={ "Off", "Right", "Down", "Left", "Up", "Free"};
-
-    conf.edge_overlay_pano+=change;
-    if (conf.edge_overlay_pano<0) 
-        conf.edge_overlay_pano=(sizeof(modes)/sizeof(modes[0]))-1; 
-    else if (conf.edge_overlay_pano>=(sizeof(modes)/sizeof(modes[0]))) 
-        conf.edge_overlay_pano=0; 
-    return modes[conf.edge_overlay_pano]; 
-}
-
-#endif
+#endif
