From 4dd560c5f06ddbc90bc2592bdc22520a0744891e Mon Sep 17 00:00:00 2001
From: patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>
Date: Wed, 6 Feb 2008 15:44:29 +0000
Subject: [PATCH] Pascal P-Code binaries are now big-endian

git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@639 42af7a65-404d-4744-a932-0658087f49c3
---
 ChangeLog                   |   1 +
 Documentation/NuttX.html    |   1 +
 TODO                        |   9 +--------
 examples/pashello/hello.h   |  22 +++++++++++-----------
 examples/pashello/hello.pex | Bin 232 -> 232 bytes
 5 files changed, 14 insertions(+), 19 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index b502b1e262..834812fe01 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -326,6 +326,7 @@
 	 (4) fseek() flushes read/write data when before moving the file pointer
 	 (5) When read data is flushed, reposition the file pointer to account for
 	     buffered, but unreand data
+	* Pascal P-Code files are now standardized to big-endian for portability
 
 
 
diff --git a/Documentation/NuttX.html b/Documentation/NuttX.html
index 998f55ad4f..a7e6caae9e 100644
--- a/Documentation/NuttX.html
+++ b/Documentation/NuttX.html
@@ -984,6 +984,7 @@ nuttx-0.3.8 2008-xx-xx Gregory Nutt &lt;spudmonkey@racsa.co.cr&gt;
 	 (4) fseek() flushes read/write data when before moving the file pointer
 	 (5) When read data is flushed, reposition the file pointer to account for
 	     buffered, but unreand data
+	* Pascal P-Code files are now standardized to big-endian for portability
 
 pascal-0.1.2 2008-xx-xx Gregory Nutt &lt;spudmonkey@racsa.co.cr&gt;
 
diff --git a/TODO b/TODO
index 36ec798081..5b79a57734 100644
--- a/TODO
+++ b/TODO
@@ -11,7 +11,7 @@ NuttX TODO List (Last updated January 6, 2008)
   (2)  USB (drivers/usbdev)
   (3)  Libraries (lib/)
   (2)  File system (fs/, drivers/)
-  (2)  Pascal add-on (pcode/)
+  (1)  Pascal add-on (pcode/)
   (2)  Documentation (Documentation/)
   (3)  Build system
   (0)  Applications & Tests (examples/)
@@ -236,13 +236,6 @@ o Pascal Add-On (pcode/)
   Status:      Open
   Priority:    Medium
 
-  Description: POFF file is generated in the native endian-ness of the
-               host machine (little-endian for x86 hosts).  They will
-               not run at present on big-endian targets.  Solution: the
-               POFF files must be independent of endian-ness.
-  Status:      Open
-  Priority:    Medium
-
 o Documentation (Documentation/)
   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 
diff --git a/examples/pashello/hello.h b/examples/pashello/hello.h
index 82f1f749c4..818e5e4a54 100644
--- a/examples/pashello/hello.h
+++ b/examples/pashello/hello.h
@@ -1,15 +1,15 @@
 unsigned char hello_pex[] = {
-  0x50, 0x4f, 0x46, 0x46, 0x01, 0x01, 0x00, 0x00, 0x14, 0x00, 0x05, 0x00,
-  0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00,
-  0x01, 0x06, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-  0x7c, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, 0x01, 0x03, 0x00, 0x00,
-  0x17, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x8d, 0x00, 0x00, 0x00,
-  0x0f, 0x00, 0x00, 0x00, 0x05, 0x00, 0x04, 0x00, 0x1f, 0x00, 0x00, 0x00,
-  0x00, 0x00, 0x00, 0x00, 0x9c, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00,
-  0x06, 0x00, 0x08, 0x00, 0x28, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-  0xa0, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00,
-  0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb0, 0x00, 0x00, 0x00,
-  0x38, 0x00, 0x00, 0x00, 0xb1, 0x00, 0x00, 0x74, 0x0e, 0xf9, 0x00, 0x00,
+  0x50, 0x4f, 0x46, 0x46, 0x01, 0x01, 0x00, 0x00, 0x00, 0x14, 0x00, 0x05,
+  0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18,
+  0x01, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x11, 0x01, 0x03, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x17, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x8d,
+  0x00, 0x00, 0x00, 0x0f, 0x05, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x1f,
+  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x9c, 0x00, 0x00, 0x00, 0x04,
+  0x06, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x28, 0x00, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0xa0, 0x00, 0x00, 0x00, 0x10, 0x03, 0x00, 0x00, 0x00,
+  0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xb0,
+  0x00, 0x00, 0x00, 0x38, 0xb1, 0x00, 0x00, 0x74, 0x0e, 0xf9, 0x00, 0x00,
   0x25, 0xb5, 0xff, 0xfc, 0xf9, 0x00, 0x00, 0x20, 0x3f, 0x48, 0x65, 0x6c,
   0x6c, 0x6f, 0x20, 0x77, 0x6f, 0x72, 0x6c, 0x64, 0x21, 0x21, 0x21, 0x00,
   0x07, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
diff --git a/examples/pashello/hello.pex b/examples/pashello/hello.pex
index 0f14eb1013fab6f98ae464899b547e79e06948d5..c2361059840240b8f6b25a71c4988fee16b58021 100644
GIT binary patch
delta 135
zcmaFC_=2%Mz~9Y{k&%IcL4<)7NP<`(Ai>B6rUk(y149jv7Gz`w^TeTIy+E2DsEGwg
m%R|NH0BIJWRt_Mo0To*Sqy->a84RFe8-TRMMh1q7^_c*yy9xjR

delta 135
zcmaFC_=2%Mz~9Y{k&%Hxgn^X-NP&R_kYr?IU=W1zYk)L}&B)BaAPyDl1=9RL%*w#R
rAP*Ir1Eg7in2mvhK?5qb07we}F;FXm0T6@01|YTo;*AUp6YDbpxho0)

-- 
GitLab