Fixing some epocroot build issues. Added tefcons for hooking fshell into TestExecute.
Also removed a bunch of duplicate def files.
Fixed fshell.bat so that the emulator starts with platsec switched on.
--- a/build/common/bld.inf Fri Jun 25 13:06:42 2010 +0100
+++ b/build/common/bld.inf Sun Jul 04 15:58:56 2010 +0100
@@ -33,6 +33,7 @@
#include "..\..\plugins\consoles\rcons\group\bld.inf"
#include "..\..\plugins\consoles\vt100cons\group\bld.inf"
#include "..\..\plugins\consoles\win32cons\group\bld.inf"
+#include "..\..\plugins\consoles\tefcons\bld.inf"
#include "..\..\plugins\networking\nullnif\group\bld.inf"
#include "..\..\plugins\networking\tcpcsy\group\bld.inf"
#include "..\..\plugins\networking\winsockprt\group\bld.inf"
--- a/core/group/bld.inf Fri Jun 25 13:06:42 2010 +0100
+++ b/core/group/bld.inf Sun Jul 04 15:58:56 2010 +0100
@@ -98,7 +98,6 @@
.\autostart.script z:\system\console\scripts\autostart.script
.\comm.script z:\system\console\scripts\comm.script
-.\fshell.bat \epoc32\tools\fshell.bat
PRJ_MMPFILES
gnumakefile .\fshell_version.mk
--- a/core/group/fshell.bat Fri Jun 25 13:06:42 2010 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,13 +0,0 @@
-@REM fshell.bat
-@REM
-@REM Copyright (c) 2010 Accenture. All rights reserved.
-@REM This component and the accompanying materials are made available
-@REM under the terms of the "Eclipse Public License v1.0"
-@REM which accompanies this distribution, and is available
-@REM at the URL "http://www.eclipse.org/legal/epl-v10.html".
-@REM
-@REM Initial Contributors:
-@REM Accenture - Initial contribution
-@REM
-@%epocroot%epoc32\release\winscw\udeb\fshell.exe -mltkconsole -dnogui -- --console win32cons.dll %*
-@if %ERRORLEVEL% NEQ 0 echo fshell.exe exited with error %ERRORLEVEL%
\ No newline at end of file
--- a/documentation/fshell_builddocs.mk Fri Jun 25 13:06:42 2010 +0100
+++ b/documentation/fshell_builddocs.mk Sun Jul 04 15:58:56 2010 +0100
@@ -10,12 +10,12 @@
# Accenture - Initial contribution
#
MAKMAKE :
- ..\tools\fsh-builddocs -i ../../epoc32/include pod-list.txt
+ ..\tools\fsh-builddocs -i $(EPOCROOT)epoc32/include pod-list.txt
RELEASABLES :
- ..\tools\fsh-builddocs -i ../../epoc32/include pod-list.txt -w
+ ..\tools\fsh-builddocs -i $(EPOCROOT)epoc32/include pod-list.txt -w
CLEAN :
- ..\tools\fsh-builddocs -i ../../epoc32/include pod-list.txt -c
+ ..\tools\fsh-builddocs -i $(EPOCROOT)epoc32/include pod-list.txt -c
-MAKMAKE BLD FREEZE LIB CLEANLIB RESOURCE SAVESPACE FINAL :
+BLD FREEZE LIB CLEANLIB RESOURCE SAVESPACE FINAL :
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/plugins/consoles/common/BMARM/console.def Sun Jul 04 15:58:56 2010 +0100
@@ -0,0 +1,3 @@
+EXPORTS
+ NewConsole @ 1 NONAME R3UNUSED ; (null)
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/plugins/consoles/common/bwins/console.def Sun Jul 04 15:58:56 2010 +0100
@@ -0,0 +1,3 @@
+EXPORTS
+ NewConsole @ 1 NONAME
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/plugins/consoles/common/eabi/console.def Sun Jul 04 15:58:56 2010 +0100
@@ -0,0 +1,3 @@
+EXPORTS
+ NewConsole @ 1 NONAME
+
--- a/plugins/consoles/defcons/bmarm/defconsu.def Fri Jun 25 13:06:42 2010 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,3 +0,0 @@
-EXPORTS
- NewConsole @ 1 NONAME R3UNUSED ; (null)
-
--- a/plugins/consoles/defcons/bwins/defconsu.def Fri Jun 25 13:06:42 2010 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,3 +0,0 @@
-EXPORTS
- NewConsole @ 1 NONAME
-
--- a/plugins/consoles/defcons/eabi/defconsu.def Fri Jun 25 13:06:42 2010 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,3 +0,0 @@
-EXPORTS
- NewConsole @ 1 NONAME
-
--- a/plugins/consoles/defcons/src/defcons.mmp Fri Jun 25 13:06:42 2010 +0100
+++ b/plugins/consoles/defcons/src/defcons.mmp Sun Jul 04 15:58:56 2010 +0100
@@ -14,9 +14,11 @@
TARGET defcons.dll
TARGETTYPE dll
-UID 0x1000008d 0x100039e7
+UID 0x1000008d 0x100039e7
+CAPABILITY FSHELL_CAP_MMP_NORMAL
-CAPABILITY FSHELL_CAP_MMP_NORMAL
+DEFFILE ..\..\common\~\console.def
+NOSTRICTDEF
#include <fshell/fsh_system_include.mmh>
--- a/plugins/consoles/nullcons/BMARM/nullconsU.DEF Fri Jun 25 13:06:42 2010 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,3 +0,0 @@
-EXPORTS
- NewConsole @ 1 NONAME R3UNUSED ; (null)
-
--- a/plugins/consoles/nullcons/bwins/nullconsu.def Fri Jun 25 13:06:42 2010 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,3 +0,0 @@
-EXPORTS
- NewConsole @ 1 NONAME
-
--- a/plugins/consoles/nullcons/eabi/nullconsu.def Fri Jun 25 13:06:42 2010 +0100
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,3 +0,0 @@
-EXPORTS
- NewConsole @ 1 NONAME
-
--- a/plugins/consoles/nullcons/src/nullcons.mmp Fri Jun 25 13:06:42 2010 +0100
+++ b/plugins/consoles/nullcons/src/nullcons.mmp Sun Jul 04 15:58:56 2010 +0100
@@ -14,9 +14,11 @@
TARGET nullcons.dll
TARGETTYPE dll
-UID 0x1000008d 0x100039e7
+UID 0x1000008d 0x100039e7
+CAPABILITY FSHELL_CAP_MMP_NORMAL
-CAPABILITY FSHELL_CAP_MMP_NORMAL
+DEFFILE ..\..\common\~\console.def
+NOSTRICTDEF
#include <fshell/fsh_system_include.mmh>
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/plugins/consoles/tefcons/bld.inf Sun Jul 04 15:58:56 2010 +0100
@@ -0,0 +1,21 @@
+// bld.inf
+//
+// Copyright (c) 2010 Accenture. All rights reserved.
+// This component and the accompanying materials are made available
+// under the terms of the "Eclipse Public License v1.0"
+// which accompanies this distribution, and is available
+// at the URL "http://www.eclipse.org/legal/epl-v10.html".
+//
+// Initial Contributors:
+// Accenture - Initial contribution
+//
+#ifndef FSHELL_COMMON_MMH
+#include <fshell/common.mmh>
+#endif
+
+PRJ_EXPORTS
+//TODO sort this FSHELL_ROM_INCLUDE(tefcons.iby)
+
+PRJ_MMPFILES
+tefcons.mmp
+
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/plugins/consoles/tefcons/tefcons.cpp Sun Jul 04 15:58:56 2010 +0100
@@ -0,0 +1,164 @@
+// tefcons.cpp
+//
+// Copyright (c) 2010 Accenture. All rights reserved.
+// This component and the accompanying materials are made available
+// under the terms of the "Eclipse Public License v1.0"
+// which accompanies this distribution, and is available
+// at the URL "http://www.eclipse.org/legal/epl-v10.html".
+//
+// Initial Contributors:
+// Accenture - Initial contribution
+//
+
+#include <e32std.h>
+#include <e32cons.h>
+#include <e32keys.h>
+#include <test/testexecutelogger.h>
+#include <fshell/consoleextensions.h>
+
+NONSHARABLE_CLASS(CTefConsole) : public CConsoleBase
+ {
+public:
+ CTefConsole();
+ virtual ~CTefConsole();
+ virtual TInt Create(const TDesC &aTitle,TSize aSize);
+ virtual void Read(TRequestStatus &aStatus);
+ virtual void ReadCancel();
+ virtual void Write(const TDesC &aDes);
+ virtual TPoint CursorPos() const;
+ virtual void SetCursorPosAbs(const TPoint &aPoint);
+ virtual void SetCursorPosRel(const TPoint &aPoint);
+ virtual void SetCursorHeight(TInt aPercentage);
+ virtual void SetTitle(const TDesC &aTitle);
+ virtual void ClearScreen();
+ virtual void ClearToEndOfLine();
+ virtual TSize ScreenSize() const;
+ virtual TKeyCode KeyCode() const;
+ virtual TUint KeyModifiers() const;
+ virtual TInt Extension_(TUint aExtensionId, TAny*& a0, TAny* a1);
+
+ void WriteStdErr(const TDesC &aDes);
+
+private:
+ CTestExecuteLogger* iLogger;
+ };
+
+CTefConsole::CTefConsole()
+ {
+ }
+
+TInt CTefConsole::Create(const TDesC& aTitle, TSize /*aSize*/)
+ {
+ iLogger = new CTestExecuteLogger();
+ if (!iLogger) return KErrNoMemory;
+ TInt logMode = TLoggerOptions(ELogHTMLOnly);
+ TInt logLevel = RFileFlogger::TLogSeverity(ESevrAll);
+ iLogger->SetLoggerOptions(logMode);
+ TInt err = iLogger->Connect();
+ if (err) return err;
+ const TDesC& logFilePath(aTitle);
+ err = iLogger->HtmlLogger().CreateLog(logFilePath, RTestExecuteLogServ::ELogModeAppend);
+ if (err) return err;
+ iLogger->HtmlLogger().SetLogLevel(TLogSeverity(logLevel));
+
+ iLogger->HtmlLogger().Write(_L("<pre>\r\n")); // horrible horrible tef logging - the client is responsible for writing markup!
+ return KErrNone;
+ }
+
+
+CTefConsole::~CTefConsole()
+ {
+ if (iLogger)
+ {
+ iLogger->HtmlLogger().Write(_L("</pre>\r\n")); // horrible horrible tef logging - the client is responsible for writing markup!
+ iLogger->Close();
+ delete iLogger;
+ }
+ }
+
+void CTefConsole::Read(TRequestStatus &aStatus)
+ {
+ TRequestStatus *pS=(&aStatus);
+ User::RequestComplete(pS, KErrNotSupported);
+ }
+
+void CTefConsole::ReadCancel()
+ {
+ }
+
+void CTefConsole::Write(const TDesC& aDes)
+ {
+ //TODO sort out the file and line
+ //iLogger->LogExtra(((TText8*)__FILE__), __LINE__, ESevrInfo, aDes);
+ iLogger->HtmlLogger().Write(aDes);
+ }
+
+void CTefConsole::WriteStdErr(const TDesC &aDes)
+ {
+ //iLogger->LogExtra(((TText8*)__FILE__), __LINE__, ESevrErr, aDes);
+ iLogger->HtmlLogger().Write(aDes);
+ }
+
+TPoint CTefConsole::CursorPos() const
+ {
+ return TPoint(0,0);
+ }
+
+void CTefConsole::SetCursorPosAbs(const TPoint& /*aPoint*/)
+ {
+ }
+
+void CTefConsole::SetCursorPosRel(const TPoint& /*aPoint*/)
+ {
+ }
+
+void CTefConsole::SetCursorHeight(TInt /*aPercentage*/)
+ {
+ }
+
+void CTefConsole::SetTitle(const TDesC& /*aTitle*/)
+ {
+ }
+
+void CTefConsole::ClearScreen()
+ {
+ }
+
+void CTefConsole::ClearToEndOfLine()
+ {
+ }
+
+TSize CTefConsole::ScreenSize() const
+ {
+ return TSize(10,10);
+ }
+
+TKeyCode CTefConsole::KeyCode() const
+ {
+ return EKeyNull;
+ }
+
+TUint CTefConsole::KeyModifiers() const
+ {
+ return 0;
+ }
+
+extern "C" EXPORT_C TAny *NewConsole()
+ {
+ return(new CTefConsole);
+ }
+
+TInt CTefConsole::Extension_(TUint aExtensionId, TAny*& a0, TAny* a1)
+ {
+ if (aExtensionId == ConsoleStdErr::KWriteStdErrConsoleExtension)
+ {
+ TDesC* des = (TDesC*)a1;
+ WriteStdErr(*des);
+ return KErrNone;
+ }
+ else
+ {
+ return CConsoleBase::Extension_(aExtensionId, a0, a1);
+ }
+
+ }
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/plugins/consoles/tefcons/tefcons.mmp Sun Jul 04 15:58:56 2010 +0100
@@ -0,0 +1,29 @@
+// tefcons.mmp
+//
+// Copyright (c) 2010 Accenture. All rights reserved.
+// This component and the accompanying materials are made available
+// under the terms of the "Eclipse Public License v1.0"
+// which accompanies this distribution, and is available
+// at the URL "http://www.eclipse.org/legal/epl-v10.html".
+//
+// Initial Contributors:
+// Accenture - Initial contribution
+//
+
+#include <fshell/common.mmh>
+
+TARGET tefcons.dll
+TARGETTYPE dll
+UID 0x1000008d 0x100039e7
+CAPABILITY FSHELL_CAP_MMP_NORMAL
+
+DEFFILE ..\common\~\console.def
+NOSTRICTDEF
+
+#include <fshell/fsh_system_include.mmh>
+
+SOURCEPATH .
+SOURCE tefcons.cpp
+
+LIBRARY euser.lib
+LIBRARY testexecutelogclient.lib testexecuteutils.lib
--- a/plugins/consoles/win32cons/group/bld.inf Fri Jun 25 13:06:42 2010 +0100
+++ b/plugins/consoles/win32cons/group/bld.inf Sun Jul 04 15:58:56 2010 +0100
@@ -13,6 +13,11 @@
#include <fshell/common.mmh>
#endif
+PRJ_EXPORTS
+
+.\fshell.bat \epoc32\tools\fshell.bat
+.\fshellconsole.ini \epoc32\data\fshellconsole.ini
+
PRJ_MMPFILES
#if defined(WINS)
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/plugins/consoles/win32cons/group/fshell.bat Sun Jul 04 15:58:56 2010 +0100
@@ -0,0 +1,13 @@
+@REM fshell.bat
+@REM
+@REM Copyright (c) 2010 Accenture. All rights reserved.
+@REM This component and the accompanying materials are made available
+@REM under the terms of the "Eclipse Public License v1.0"
+@REM which accompanies this distribution, and is available
+@REM at the URL "http://www.eclipse.org/legal/epl-v10.html".
+@REM
+@REM Initial Contributors:
+@REM Accenture - Initial contribution
+@REM
+@%epocroot%epoc32\release\winscw\udeb\fshell.exe -mfshellconsole -dnogui -- --console win32cons.dll %*
+@if %ERRORLEVEL% NEQ 0 echo fshell.exe exited with error %ERRORLEVEL%
\ No newline at end of file
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/plugins/consoles/win32cons/group/fshellconsole.ini Sun Jul 04 15:58:56 2010 +0100
@@ -0,0 +1,16 @@
+# fshellconsole.ini
+#
+# Copyright (c) 2010 Accenture. All rights reserved.
+# This component and the accompanying materials are made available
+# under the terms of the "Eclipse Public License v1.0"
+# which accompanies this distribution, and is available
+# at the URL "http://www.eclipse.org/legal/epl-v10.html".
+#
+# Initial Contributors:
+# Accenture - Initial contribution
+#
+PlatSecEnforcement ON
+PlatSecDiagnostics ON
+PlatSecProcessIsolation ON
+PlatSecEnforceSysBin ON
+PlatSecDisabledCaps NONE
--- a/tools/fsh-buildsis Fri Jun 25 13:06:42 2010 +0100
+++ b/tools/fsh-buildsis Sun Jul 04 15:58:56 2010 +0100
@@ -77,7 +77,7 @@
#
# 1) Run the pre-processor over the supplied .iby file and capture the output
# to a temporary file.
- my $tempFileName = "$ENV{TEMP}\\ltkbs_temp.pkg";
+ my $tempFileName = "$ENV{TEMP}\\fsh-buildsis_temp.pkg";
if (-e $tempFileName) {
unlink $tempFileName;
}
--- a/tools/fshu.pm Fri Jun 25 13:06:42 2010 +0100
+++ b/tools/fshu.pm Sun Jul 04 15:58:56 2010 +0100
@@ -124,6 +124,10 @@
mkpath($dir) or die "Couldn't make path \"$dir\": $!\n";
}
}
+ if ($dir =~ /^\\epoc32/) {
+ # If it starts with \epoc32, chop the leading backslash and stick on $EPOCROOT
+ $dir =~ s/^\\/$ENV{EPOCROOT}/;
+ }
}
sub CopyFile {