Commit Graph

403 Commits

Author SHA1 Message Date
ba0a57702c remove OUString wrap for string literals
For some functions and all kinds of Exceptions.

CannotConvertException
CloseVetoException
DisposedException
EmptyUndoStackException
ErrorCodeIOException
Exception
GridInvalidDataException
GridInvalidModelException
IOException
IllegalAccessException
IllegalArgumentException
IllegalTypeException
IndexOutOfBoundsException
NoMasterException
NoSuchElementException
NoSupportException
PropertyVetoException
RuntimeException
SAXException
ScannerException
StorageWrappedTargetException
UnsupportedFlavorException
VetoException
WrappedTargetException
ZipIOException
throwGenericSQLException
throwIllegallArgumentException

createInstance
createInstanceWithContext
forName
getByName
getPackageManager
getPropertyValue
getUnpackedValueOrDefault
getValueByName
hasPropertyByName
openKey
setName
setPropertyValue
supportsService

bash command:

for i in `cat list`; do git grep "$i\s*(\s*OUString(\s*\"" -- '*.[hc]xx'
	| cut -d ':' -f1 | sort -u
	| xargs sed -i
		-e "s/\(\<$i\s*(\)\s*OUString(\s*\(\"[^\")\\]*\"\)\s*)\s*/\1\2/g"
		-e "s/\($i.*\)\"+ /\1\" + /g";
done

Change-Id: Iaf8e641b0abf28c082906014f87a183517630535
Reviewed-on: https://gerrit.libreoffice.org/4624
Tested-by: LibreOffice gerrit bot <gerrit@libreoffice.org>
Reviewed-by: Thomas Arnhold <thomas@arnhold.org>
Tested-by: Thomas Arnhold <thomas@arnhold.org>
2013-06-29 21:52:54 +00:00
b6d97514cd reduce some spacing
Change-Id: I72d494b1c0ff5ed3c52ae6a078815f497e4dd647
2013-06-29 18:38:14 +02:00
7441d4bbdb PyUno fixed crash in function isInstanceOfStructOrException()
when we try to call PyUNO_callable object that doesn't have __class__ attribute

Change-Id: Ia05f70d70f248d50aa141b09625f7ec50189e1dd
Reviewed-on: https://gerrit.libreoffice.org/4309
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Tested-by: Michael Stahl <mstahl@redhat.com>
2013-06-16 15:29:04 +00:00
a2a3424953 Deprecated conversion from const wchar_t* to wchar_t*
Change-Id: I8c0a97372f0855543d6207adb0abaa4cc820aabd
2013-06-10 14:03:36 +02:00
7b91e84c72 Optional pyuno module should have its own services/pyuno.rdb
...this e.g. changes the error message when trying to register an extension that
contains an (actively registered) Python component but no pyuno is installed
from "Binary URP bridge disposed during call" to a less frightening "The service
com.sun.star.loader.Python cannot be instantiated."

Change-Id: I10f2b36b11395559ee95ce659878222b5ea99c11
2013-05-28 16:02:46 +02:00
8bf8a2f349 fdo#46808, Convert script::InvocationAdapterFactory to new style
Change-Id: I2fe24c863f4c43471f46032ed15fcd5b98863fc1
2013-05-14 13:39:29 +02:00
96fe61f40e pyuno: remove obsolete makefiles
These should have been removed in b6bcbb675afedba0c47654dd78dc446dac0630d1

Change-Id: Iec28da16542f16c459bf301649260d8b13c1c67d
2013-05-14 11:50:09 +02:00
717c9643bd More gb_PROGRAMDIRNAME clean up
Change-Id: I5af86e15bcb8958a680e7309f13d7a865f29d7a9
2013-05-10 14:06:47 +02:00
094978d48d No need for RTLD_NOW here
...it was like that "since the beginning," but for no apparent reason.

Change-Id: Ic293739b5cd5de0bfe9e2580a0755af64202e582
2013-05-08 20:16:44 +02:00
cf49e8b816 Library_puyuno_wrapper is not built on WNT anyway
Change-Id: Ia4e2f9d5f3475b0a7af8b6db80ba4b2cd5f6bfce
2013-05-08 20:16:44 +02:00
5589c72b88 Make sure again pyuno_wrapper does not link against libstdc++
...which got broken with gbuild'ification.

Change-Id: Ice2b3ffb81a646c9e542344ca348eb6a16eb4ce2
2013-05-08 18:37:05 +02:00
ed665f24ff copy pyuno files to instdir
Change-Id: I62fa315b942c5b2383ee83c644ecbcbca3d6c40f
2013-05-05 15:47:54 +02:00
72e5d0c8fb Move to MPLv2 license headers, with ESC decision and author's permission. 2013-04-30 13:34:06 +01:00
1cc9bbfd57 gbuild: drop empty use_packages calls
Change-Id: I8e9f70eb5d929c98b4379416c2259a74e31d587f
Reviewed-on: https://gerrit.libreoffice.org/3503
Reviewed-by: David Tardon <dtardon@redhat.com>
Tested-by: David Tardon <dtardon@redhat.com>
2013-04-24 05:18:15 +00:00
6c7659b584 move URE headers to include/
Change-Id: Ib48a12e902f2311c295b2007f08f44dee28f431d
Reviewed-on: https://gerrit.libreoffice.org/3499
Reviewed-by: David Tardon <dtardon@redhat.com>
Tested-by: David Tardon <dtardon@redhat.com>
2013-04-24 05:17:10 +00:00
b6bcbb675a replace python-core zip built in pyuno with direct use of Package
- python3: deliver files to INSTDIR, with same layout as instset
  and do not deliver .lib files
- pyuno: remove obsolete python.bin targets
- pyuno: remove usage of CustomTarget_zip for WNT and non-Mac UNX
  platforms (sadly it is apparently still needed for "system" python on
  MinGW)
- scp2: use the python3 filelist
  There is still a problem here because the installer does not currently
  allow to preserve the executable bit on files in a filelist
- RepositoryExternal: run python executable from INSTDIR
  and link against libraries in UnpackedTarball dir

Change-Id: I931ca0a8be6ff40051b1ca50da1f0770e6057832
Reviewed-on: https://gerrit.libreoffice.org/3525
Tested-by: LibreOffice gerrit bot <gerrit@libreoffice.org>
Reviewed-by: Michael Stahl <mstahl@redhat.com>
2013-04-22 11:33:25 +00:00
288c8b9d59 adapt path for test.dll for WNT
Change-Id: I4d7cb081805213f55ae69c4ade8638bbfc06f0c4
2013-04-21 15:00:51 +02:00
b865ff3d75 python3: put an RPATH into python binary ...
... and get rid of LD_LIBRARY_PATH hack in wrapper shell script.

Change-Id: I7d91c6086460504d656de7b018087264165f396b
2013-04-19 16:16:34 +02:00
1fb53a6375 pyuno_loader::CreateInstance: delete the initial PyThreadState
Don't see how it could be used again, it appears to be leaked
and causes the assertion in PyThreadState_Swap to fire.

Change-Id: Id6bbb4363928e4fdd8bda1905f6e1f9931dba74c
Reviewed-on: https://gerrit.libreoffice.org/3452
Reviewed-by: David Ostrovsky <David.Ostrovsky@gmx.de>
Tested-by: David Ostrovsky <David.Ostrovsky@gmx.de>
2013-04-18 16:27:16 +00:00
89035356bc pyuno_dlopenwrapper: give error message before abort() if dlopen() fails
Change-Id: Idf39b33efe4c7838f2669aec8773616416811d57
2013-04-12 09:47:18 +02:00
4eccc3798b warning C4101: 'e' : unreferenced local variable
Change-Id: I2828021d60d82e43358ba98a1a3b4967a6901cd6
2013-04-09 12:33:56 +02:00
542cf6d9ea unbreak windows tinderbox
Change-Id: Ic777267cb86acdb62b53a7b324e1423b7c6b67c5
2013-04-09 09:46:38 +02:00
ebeae438db move Python tests in-process
This is nice to make them more easily debuggable.
A series of crude hacks are employed to bootstrap enough services from
python so the current tests run.
This is only tested with system python3 on Fedora.

Change-Id: I5e06741e55ead7fddec41ff776ff8ca5d2399469
Reviewed-on: https://gerrit.libreoffice.org/3215
Reviewed-by: David Ostrovsky <David.Ostrovsky@gmx.de>
Tested-by: David Ostrovsky <David.Ostrovsky@gmx.de>
2013-04-09 05:52:49 +00:00
1946794ae0 mass removal of rtl:: prefixes for O(U)String*
Modules sal, salhelper, cppu, cppuhelper, codemaker (selectively) and odk
have kept them, in order not to break external API (the automatic using declaration
is LO-internal).

Change-Id: I588fc9e0c45b914f824f91c0376980621d730f09
2013-04-07 14:23:11 +02:00
8333cbf2a3 Remove RTL_CONSTASCII_(U)STRINGPARAM in pyuno
and use append() instead of appendAscii()

Change-Id: Iaf29a2f18eff39db5d1b5cc298cce23442ac51a9
2013-03-28 22:54:38 +01:00
39d45390f4 removal of RTL_CONSTASCII_USTRINGPARAM for quoted OUStrings declarations
s/(OUString\s+[a-zA-Z_][A-Za-z0-9_]*\s*)\(\s*RTL_CONSTASCII_USTRINGPARAM\s*\((\s*"[^")]*?"\s*)\)\s*\)/$1\($2\)/gms

Change-Id: Iad20f242c80c4bdc69df17e2d7a69d58ea53654b
Reviewed-on: https://gerrit.libreoffice.org/2835
Reviewed-by: Thomas Arnhold <thomas@arnhold.org>
Tested-by: Thomas Arnhold <thomas@arnhold.org>
2013-03-19 10:48:30 +00:00
8b27d78b4a automated removal of RTL_CONSTASCII_USTRINGPARAM for quoted OUStrings
Done with a perl regex:

s/OUString\s*\(\s*RTL_CONSTASCII_USTRINGPARAM\s*\((\s*"[^")]*?"\s*)\)\s*\)/OUString\($1\)/gms

Change-Id: Idf28320817cdcbea6d0f7ec06a9bf51bd2c3b3ec
Reviewed-on: https://gerrit.libreoffice.org/2832
Reviewed-by: Thomas Arnhold <thomas@arnhold.org>
Tested-by: Thomas Arnhold <thomas@arnhold.org>
2013-03-19 09:00:26 +00:00
a09124e6f5 avoid Wundef in cases where the usage seems otherwise ok
Change-Id: Iabccc31c59cec32235661f5225f45bb13f76a68f
2013-03-18 17:15:56 +01:00
79b0046ba0 remove legacy build.pl prj/build.lst files. 2013-03-14 17:05:51 +00:00
21e1e859a7 fdo#60724 change spelling error REMOVEABLE -> REMOVABLE
Only applies to PropertyAttribute::REMOVEABLE, and all instances in comments.
All other instances of the misspelling have remained the same.
Example: AF_REMOVEABLE

Change-Id: I391f4101bbc3e06689318235a37d616065bc1686
Signed-off-by: Stephan Bergmann <sbergman@redhat.com>
2013-03-06 10:39:30 +01:00
76fb62755b coverity#983056: Resource leak
Change-Id: Ic40776f3cec5139e7f7accb4985533e78bd7c158
2013-03-04 21:27:27 +01:00
b768611724 remove all d.lst
Change-Id: Icba4218c5f9fe89d183d25ea82a8eae52881f885
2013-02-28 18:40:06 +01:00
308cac3f23 sal: new ZipPackage_sal_odk_headers for public ODK headers
Change-Id: I76cb00121d7b4c21137be70ab7a5bd5389037302
2013-02-27 01:33:18 +01:00
ed26c01be1 quiet external module build log unless failure
ExternalProject usually involve a configure and a make
step that produce a bunch of output usually irrelevant
including a large number of warning and other mess.
now that everything is pretty much in tail_build
these output get interleaved with useful output from
the build of the product and actually drown them in a logorrhea
of messy noise.
This store the output of external modules in a log file
and only print them as a whole if the module failed do build.
on a non-verbose build.

Change-Id: I3abfcccd6d16821a9e061a71e031b427cc283647
Reviewed-on: https://gerrit.libreoffice.org/2304
Reviewed-by: Norbert Thiebaud <nthiebaud@gmail.com>
Tested-by: Norbert Thiebaud <nthiebaud@gmail.com>
2013-02-22 08:25:56 +00:00
f68cd77923 Fix type unkown -> unknown
Change-Id: I8d55d5ae5ae38ae2b252859b5400e36301f19ef0
2013-02-21 21:50:01 +01:00
77fd448d09 Removed several useless macros: UNISTRING, USTR, USTR_ASCII, ASCII_STR, ASCII_STRING, CONST_ASCII, ASCSTR, ASCII, DEFINE_CONST_UNICODE, DEFINE_CONST_OUSTRING
Change-Id: I96d690bf9f9b319e9eeafcf218ec5ce87f21215f
Reviewed-on: https://gerrit.libreoffice.org/1954
Reviewed-by: Tor Lillqvist <tml@iki.fi>
Tested-by: Tor Lillqvist <tml@iki.fi>
2013-02-14 13:20:14 +00:00
bd2c4e8dc4 Adapt PyUNO getConstantByName to previous TypeDescriptionMgr API CHANGE
Change-Id: I5a91c6c6dce103a8e4daa1572a638e1968a48fd8
2013-01-30 18:13:26 +01:00
5a61e28378 gbuild: fix silly "expandtabs" in makefile VIM modelines
Change-Id: I54d8923ad315e8041fd3904da3a29f1a7a8c8b16
2013-01-26 22:20:07 +01:00
a53586f4ef gbuild: do not copy boost headers around
- do not use gb_UnpackedTarball_copy_header_files for boost
- adapt the optimization in concat-deps.c for new path
- use boost_headers in all LinkTargets that require it
- add explicit include paths to mysqlc, mysqlcppconn, libvisio, liborcus

Change-Id: I0c43e73ed43cc9d2e6bce8faf55e992d655a0bb9
2013-01-26 22:20:06 +01:00
c2445b03f4 fdo#59728: Fix encoding of .py files as UTF-8 for Python 3
...where it could default to something like CP 1252 instead on Windows, while
keeping backwards compatibility for now with running under Python 2 (where
things apparently worked well with the original code).

Change-Id: I0ddd06771a36e1cd2cc2ce78abd8bd667db7778f
2013-01-23 17:58:25 +01:00
2e9ec0a8bc simplify processing of python.sh
Change-Id: I583407233fad1f7aaccc137642e5f134c3ba2874
2013-01-01 13:15:01 +01:00
085e0adf53 just pass the define through -D
I am constantly amazed at the creativity of the original makefile
writers. An extra header file, processed by sed, rather then adding one
item to CDEFS? Really?

Change-Id: I41ae8b10fc447ea5ab91e767c8afb87e39b9b5f5
2013-01-01 13:15:01 +01:00
d72a0b5c61 Check for __GNUC__ instead of GCC in sources
We still have checks for $(COM) being GCC or MSC in makefiles, of
course. But there is no reason to pass -D$(COM) to compilations.
Checking the built-in compiler-specific macros __GNUC__, _MSC_VER
(etc) is the right thing to do.

Change-Id: Ia961a29ba74e2c4977e5300a92318f38104c6592
2012-12-27 13:38:15 +02:00
c29098917a Get rid of (most uses of) GUI
GUI only takes values UNX or WNT, so it is fairly pointless. One can check
whether OS is WNT or not instead.

Change-Id: I78ae32c03536a496a563e5deeb0fca78aebf9c34
Reviewed-on: https://gerrit.libreoffice.org/1304
Reviewed-by: Peter Foley <pefoley2@verizon.net>
Tested-by: Peter Foley <pefoley2@verizon.net>
2012-12-25 17:53:25 +00:00
43df436f60 WaE: Fix needed with MSVS 2010, too
Change-Id: I1d1da64b14139c1d90ac07685f3fe88e99253815
2012-12-25 10:55:29 +02:00
781548472b VS2012 WaE: C4211: nonstandard extension used : redefined extern to static
Some screwup with hypot(). As a workaround, include <math.h> early.

Change-Id: Ic8c6abc45f8502097c6b6b619108d50ea3c22392
2012-12-21 18:39:28 +02:00
71f9633d67 some not important Python3.3 port (pythonloader DEBUG mode)
Change-Id: I9a6ee04524c0ecd10301c17d2ca6da156d1c2160
2012-12-19 11:16:14 +01:00
374c9af20d i118798 - Fix Pyuno dead-lock
Fixes fdo#57569, thanks to Miklós Prisznyák for the hint.

git-svn-id: https://svn-master.apache.org/repos/asf/incubator/ooo/trunk@1232123 13f79535-47bb-0310-9956-ffa450edef68
2012-12-11 19:40:50 +01:00
a0f86c9c1d Python/pep8: fix E711 (is or is not None instead of = or !=) in pyuno module
Change-Id: I8ee9abc9a31a6d7791a006ed589d83d5858de267
2012-12-09 23:16:08 +01:00
8f4ddb1910 pyuno: clean up that zipcore a little
That $(shell find...) is now entirely pointless with python3 in
tail_build; depend on package instead.

Change-Id: Iacc8a7d201f8ec2e41adf3e2351a755e955c0997
2012-12-02 21:52:23 +01:00