diff options
author | Jan Holesovsky <kendy@suse.cz> | 2011-03-23 16:59:59 +0100 |
---|---|---|
committer | Jan Holesovsky <kendy@suse.cz> | 2011-03-23 16:59:59 +0100 |
commit | 4be7cca60bc7cc0a066b7384d56624266dc0dfcf (patch) | |
tree | 990b1fda00fca6f26ff74fd29552687b4e3c37ed /codemaker | |
parent | 79a6c0f8a28b43c36c3b02dc5e116f2d17e92ef0 (diff) | |
parent | a24842b43a687808376f69d4bdbb45fcddde73c4 (diff) |
Merge commit 'ooo/DEV300_m103'
Conflicts:
codemaker/source/bonobowrappermaker/corbaoptions.cxx
codemaker/source/cppumaker/cppuoptions.cxx
codemaker/source/cunomaker/cunooptions.cxx
codemaker/source/idlmaker/idloptions.cxx
codemaker/source/javamaker/javaoptions.cxx
cppu/source/typelib/typelib.cxx
idlc/source/options.cxx
offapi/com/sun/star/util/PathSubstitution.idl
offapi/drafts/com/sun/star/form/ListEntryEvent.idl
offapi/drafts/com/sun/star/form/XBindableValue.idl
offapi/drafts/com/sun/star/form/XListEntryListener.idl
offapi/drafts/com/sun/star/form/XListEntrySink.idl
offapi/drafts/com/sun/star/form/XListEntrySource.idl
offapi/drafts/com/sun/star/form/XValueBinding.idl
registry/tools/checksingleton.cxx
registry/tools/options.hxx
registry/tools/regcompare.cxx
registry/tools/regmerge.cxx
sal/cppunittester/cppunittester.cxx
sal/osl/unx/socket.c
sal/osl/w32/diagnose.c
sal/prj/d.lst
sal/rtl/source/alloc_fini.cxx
sal/rtl/source/alloc_global.c
sal/rtl/source/makefile.mk
Diffstat (limited to 'codemaker')
-rw-r--r-- | codemaker/source/cppumaker/cppuoptions.cxx | 18 | ||||
-rw-r--r-- | codemaker/source/javamaker/javaoptions.cxx | 18 |
2 files changed, 26 insertions, 10 deletions
diff --git a/codemaker/source/cppumaker/cppuoptions.cxx b/codemaker/source/cppumaker/cppuoptions.cxx index c77a15904442..37b843b6544c 100644 --- a/codemaker/source/cppumaker/cppuoptions.cxx +++ b/codemaker/source/cppumaker/cppuoptions.cxx @@ -38,6 +38,13 @@ using ::rtl::OUString; using ::rtl::OUStringToOString; using ::rtl::OString; + +#ifdef SAL_UNX +#define SEPARATOR '/' +#else +#define SEPARATOR '\\' +#endif + sal_Bool CppuOptions::initOptions(int ac, char* av[], sal_Bool bCmdFile) throw( IllegalArgument ) { @@ -48,7 +55,9 @@ sal_Bool CppuOptions::initOptions(int ac, char* av[], sal_Bool bCmdFile) { bCmdFile = sal_True; - m_program = av[0]; + OString name(av[0]); + sal_Int32 index = name.lastIndexOf(SEPARATOR); + m_program = name.copy((index > 0 ? index+1 : 0)); if (ac < 2) { @@ -340,7 +349,7 @@ OString CppuOptions::prepareHelp() help += " necessary information is available for bridging the type in UNO.\n"; help += " -G = generate only target files which does not exists.\n"; help += " -Gc = generate only target files which content will be changed.\n"; - help += " -X<file> = extra types which will not be taken into account for generation.\n"; + help += " -X<file> = extra types which will not be taken into account for generation.\n\n"; help += prepareVersion(); return help; @@ -348,9 +357,8 @@ OString CppuOptions::prepareHelp() OString CppuOptions::prepareVersion() { - OString version("\nSun Microsystems (R) "); - version += m_program + " Version 2.0\n\n"; - + OString version(m_program); + version += " Version 2.0\n\n"; return version; } diff --git a/codemaker/source/javamaker/javaoptions.cxx b/codemaker/source/javamaker/javaoptions.cxx index 82fa4d55ad87..e29280b211d2 100644 --- a/codemaker/source/javamaker/javaoptions.cxx +++ b/codemaker/source/javamaker/javaoptions.cxx @@ -37,6 +37,13 @@ using ::rtl::OUString; using ::rtl::OString; using ::rtl::OUStringToOString; + +#ifdef SAL_UNX +#define SEPARATOR '/' +#else +#define SEPARATOR '\\' +#endif + sal_Bool JavaOptions::initOptions(int ac, char* av[], sal_Bool bCmdFile) throw( IllegalArgument ) { @@ -47,7 +54,9 @@ sal_Bool JavaOptions::initOptions(int ac, char* av[], sal_Bool bCmdFile) { bCmdFile = sal_True; - m_program = av[0]; + OString name(av[0]); + sal_Int32 index = name.lastIndexOf(SEPARATOR); + m_program = name.copy((index > 0 ? index+1 : 0)); if (ac < 2) { @@ -284,7 +293,7 @@ OString JavaOptions::prepareHelp() help += " -nD = no dependent types are generated.\n"; help += " -G = generate only target files which does not exists.\n"; help += " -Gc = generate only target files which content will be changed.\n"; - help += " -X<file> = extra types which will not be taken into account for generation.\n"; + help += " -X<file> = extra types which will not be taken into account for generation.\n\n"; help += prepareVersion(); return help; @@ -292,9 +301,8 @@ OString JavaOptions::prepareHelp() OString JavaOptions::prepareVersion() { - OString version("\nSun Microsystems (R) "); - version += m_program + " Version 2.0\n\n"; - + OString version(m_program); + version += " Version 2.0\n\n"; return version; } |