libcmis-0.5.2/0000775000175000017500000000000013411152402010134 500000000000000libcmis-0.5.2/COPYING.LGPL0000664000175000017500000006364213407173247011676 00000000000000 GNU LESSER GENERAL PUBLIC LICENSE Version 2.1, February 1999 Copyright (C) 1991, 1999 Free Software Foundation, Inc. 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. [This is the first released version of the Lesser GPL. It also counts as the successor of the GNU Library Public License, version 2, hence the version number 2.1.] Preamble The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public Licenses are intended to guarantee your freedom to share and change free software--to make sure the software is free for all its users. This license, the Lesser General Public License, applies to some specially designated software packages--typically libraries--of the Free Software Foundation and other authors who decide to use it. You can use it too, but we suggest you first think carefully about whether this license or the ordinary General Public License is the better strategy to use in any particular case, based on the explanations below. When we speak of free software, we are referring to freedom of use, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish); that you receive source code or can get it if you want it; that you can change the software and use pieces of it in new free programs; and that you are informed that you can do these things. To protect your rights, we need to make restrictions that forbid distributors to deny you these rights or to ask you to surrender these rights. These restrictions translate to certain responsibilities for you if you distribute copies of the library or if you modify it. For example, if you distribute copies of the library, whether gratis or for a fee, you must give the recipients all the rights that we gave you. You must make sure that they, too, receive or can get the source code. If you link other code with the library, you must provide complete object files to the recipients, so that they can relink them with the library after making changes to the library and recompiling it. And you must show them these terms so they know their rights. We protect your rights with a two-step method: (1) we copyright the library, and (2) we offer you this license, which gives you legal permission to copy, distribute and/or modify the library. To protect each distributor, we want to make it very clear that there is no warranty for the free library. Also, if the library is modified by someone else and passed on, the recipients should know that what they have is not the original version, so that the original author's reputation will not be affected by problems that might be introduced by others. Finally, software patents pose a constant threat to the existence of any free program. We wish to make sure that a company cannot effectively restrict the users of a free program by obtaining a restrictive license from a patent holder. Therefore, we insist that any patent license obtained for a version of the library must be consistent with the full freedom of use specified in this license. Most GNU software, including some libraries, is covered by the ordinary GNU General Public License. This license, the GNU Lesser General Public License, applies to certain designated libraries, and is quite different from the ordinary General Public License. We use this license for certain libraries in order to permit linking those libraries into non-free programs. When a program is linked with a library, whether statically or using a shared library, the combination of the two is legally speaking a combined work, a derivative of the original library. The ordinary General Public License therefore permits such linking only if the entire combination fits its criteria of freedom. The Lesser General Public License permits more lax criteria for linking other code with the library. We call this license the "Lesser" General Public License because it does Less to protect the user's freedom than the ordinary General Public License. It also provides other free software developers Less of an advantage over competing non-free programs. These disadvantages are the reason we use the ordinary General Public License for many libraries. However, the Lesser license provides advantages in certain special circumstances. For example, on rare occasions, there may be a special need to encourage the widest possible use of a certain library, so that it becomes a de-facto standard. To achieve this, non-free programs must be allowed to use the library. A more frequent case is that a free library does the same job as widely used non-free libraries. In this case, there is little to gain by limiting the free library to free software only, so we use the Lesser General Public License. In other cases, permission to use a particular library in non-free programs enables a greater number of people to use a large body of free software. For example, permission to use the GNU C Library in non-free programs enables many more people to use the whole GNU operating system, as well as its variant, the GNU/Linux operating system. Although the Lesser General Public License is Less protective of the users' freedom, it does ensure that the user of a program that is linked with the Library has the freedom and the wherewithal to run that program using a modified version of the Library. The precise terms and conditions for copying, distribution and modification follow. Pay close attention to the difference between a "work based on the library" and a "work that uses the library". The former contains code derived from the library, whereas the latter must be combined with the library in order to run. GNU LESSER GENERAL PUBLIC LICENSE TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 0. This License Agreement applies to any software library or other program which contains a notice placed by the copyright holder or other authorized party saying it may be distributed under the terms of this Lesser General Public License (also called "this License"). Each licensee is addressed as "you". A "library" means a collection of software functions and/or data prepared so as to be conveniently linked with application programs (which use some of those functions and data) to form executables. The "Library", below, refers to any such software library or work which has been distributed under these terms. A "work based on the Library" means either the Library or any derivative work under copyright law: that is to say, a work containing the Library or a portion of it, either verbatim or with modifications and/or translated straightforwardly into another language. (Hereinafter, translation is included without limitation in the term "modification".) "Source code" for a work means the preferred form of the work for making modifications to it. For a library, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the library. Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running a program using the Library is not restricted, and output from such a program is covered only if its contents constitute a work based on the Library (independent of the use of the Library in a tool for writing it). Whether that is true depends on what the Library does and what the program that uses the Library does. 1. You may copy and distribute verbatim copies of the Library's complete source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and distribute a copy of this License along with the Library. You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee. 2. You may modify your copy or copies of the Library or any portion of it, thus forming a work based on the Library, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions: a) The modified work must itself be a software library. b) You must cause the files modified to carry prominent notices stating that you changed the files and the date of any change. c) You must cause the whole of the work to be licensed at no charge to all third parties under the terms of this License. d) If a facility in the modified Library refers to a function or a table of data to be supplied by an application program that uses the facility, other than as an argument passed when the facility is invoked, then you must make a good faith effort to ensure that, in the event an application does not supply such function or table, the facility still operates, and performs whatever part of its purpose remains meaningful. (For example, a function in a library to compute square roots has a purpose that is entirely well-defined independent of the application. Therefore, Subsection 2d requires that any application-supplied function or table used by this function must be optional: if the application does not supply it, the square root function must still compute square roots.) These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Library, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Library, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it. Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Library. In addition, mere aggregation of another work not based on the Library with the Library (or with a work based on the Library) on a volume of a storage or distribution medium does not bring the other work under the scope of this License. 3. You may opt to apply the terms of the ordinary GNU General Public License instead of this License to a given copy of the Library. To do this, you must alter all the notices that refer to this License, so that they refer to the ordinary GNU General Public License, version 2, instead of to this License. (If a newer version than version 2 of the ordinary GNU General Public License has appeared, then you can specify that version instead if you wish.) Do not make any other change in these notices. Once this change is made in a given copy, it is irreversible for that copy, so the ordinary GNU General Public License applies to all subsequent copies and derivative works made from that copy. This option is useful when you wish to copy part of the code of the Library into a program that is not a library. 4. You may copy and distribute the Library (or a portion or derivative of it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange. If distribution of object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place satisfies the requirement to distribute the source code, even though third parties are not compelled to copy the source along with the object code. 5. A program that contains no derivative of any portion of the Library, but is designed to work with the Library by being compiled or linked with it, is called a "work that uses the Library". Such a work, in isolation, is not a derivative work of the Library, and therefore falls outside the scope of this License. However, linking a "work that uses the Library" with the Library creates an executable that is a derivative of the Library (because it contains portions of the Library), rather than a "work that uses the library". The executable is therefore covered by this License. Section 6 states terms for distribution of such executables. When a "work that uses the Library" uses material from a header file that is part of the Library, the object code for the work may be a derivative work of the Library even though the source code is not. Whether this is true is especially significant if the work can be linked without the Library, or if the work is itself a library. The threshold for this to be true is not precisely defined by law. If such an object file uses only numerical parameters, data structure layouts and accessors, and small macros and small inline functions (ten lines or less in length), then the use of the object file is unrestricted, regardless of whether it is legally a derivative work. (Executables containing this object code plus portions of the Library will still fall under Section 6.) Otherwise, if the work is a derivative of the Library, you may distribute the object code for the work under the terms of Section 6. Any executables containing that work also fall under Section 6, whether or not they are linked directly with the Library itself. 6. As an exception to the Sections above, you may also combine or link a "work that uses the Library" with the Library to produce a work containing portions of the Library, and distribute that work under terms of your choice, provided that the terms permit modification of the work for the customer's own use and reverse engineering for debugging such modifications. You must give prominent notice with each copy of the work that the Library is used in it and that the Library and its use are covered by this License. You must supply a copy of this License. If the work during execution displays copyright notices, you must include the copyright notice for the Library among them, as well as a reference directing the user to the copy of this License. Also, you must do one of these things: a) Accompany the work with the complete corresponding machine-readable source code for the Library including whatever changes were used in the work (which must be distributed under Sections 1 and 2 above); and, if the work is an executable linked with the Library, with the complete machine-readable "work that uses the Library", as object code and/or source code, so that the user can modify the Library and then relink to produce a modified executable containing the modified Library. (It is understood that the user who changes the contents of definitions files in the Library will not necessarily be able to recompile the application to use the modified definitions.) b) Use a suitable shared library mechanism for linking with the Library. A suitable mechanism is one that (1) uses at run time a copy of the library already present on the user's computer system, rather than copying library functions into the executable, and (2) will operate properly with a modified version of the library, if the user installs one, as long as the modified version is interface-compatible with the version that the work was made with. c) Accompany the work with a written offer, valid for at least three years, to give the same user the materials specified in Subsection 6a, above, for a charge no more than the cost of performing this distribution. d) If distribution of the work is made by offering access to copy from a designated place, offer equivalent access to copy the above specified materials from the same place. e) Verify that the user has already received a copy of these materials or that you have already sent this user a copy. For an executable, the required form of the "work that uses the Library" must include any data and utility programs needed for reproducing the executable from it. However, as a special exception, the materials to be distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable. It may happen that this requirement contradicts the license restrictions of other proprietary libraries that do not normally accompany the operating system. Such a contradiction means you cannot use both them and the Library together in an executable that you distribute. 7. You may place library facilities that are a work based on the Library side-by-side in a single library together with other library facilities not covered by this License, and distribute such a combined library, provided that the separate distribution of the work based on the Library and of the other library facilities is otherwise permitted, and provided that you do these two things: a) Accompany the combined library with a copy of the same work based on the Library, uncombined with any other library facilities. This must be distributed under the terms of the Sections above. b) Give prominent notice with the combined library of the fact that part of it is a work based on the Library, and explaining where to find the accompanying uncombined form of the same work. 8. You may not copy, modify, sublicense, link with, or distribute the Library except as expressly provided under this License. Any attempt otherwise to copy, modify, sublicense, link with, or distribute the Library is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance. 9. You are not required to accept this License, since you have not signed it. However, nothing else grants you permission to modify or distribute the Library or its derivative works. These actions are prohibited by law if you do not accept this License. Therefore, by modifying or distributing the Library (or any work based on the Library), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Library or works based on it. 10. Each time you redistribute the Library (or any work based on the Library), the recipient automatically receives a license from the original licensor to copy, distribute, link with or modify the Library subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein. You are not responsible for enforcing compliance by third parties with this License. 11. If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Library at all. For example, if a patent license would not permit royalty-free redistribution of the Library by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Library. If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply, and the section as a whole is intended to apply in other circumstances. It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice. This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License. 12. If the distribution and/or use of the Library is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Library under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded. In such case, this License incorporates the limitation as if written in the body of this License. 13. The Free Software Foundation may publish revised and/or new versions of the Lesser General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. Each version is given a distinguishing version number. If the Library specifies a version number of this License which applies to it and "any later version", you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Library does not specify a license version number, you may choose any version ever published by the Free Software Foundation. 14. If you wish to incorporate parts of the Library into other free programs whose distribution conditions are incompatible with these, write to the author to ask for permission. For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this. Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally. NO WARRANTY 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. END OF TERMS AND CONDITIONS How to Apply These Terms to Your New Libraries If you develop a new library, and you want it to be of the greatest possible use to the public, we recommend making it free software that everyone can redistribute and change. You can do so by permitting redistribution under these terms (or, alternatively, under the terms of the ordinary General Public License). To apply these terms, attach the following notices to the library. It is safest to attach them to the start of each source file to most effectively convey the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found. Copyright (C) This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Also add information on how to contact you by electronic and paper mail. You should also get your employer (if you work as a programmer) or your school, if any, to sign a "copyright disclaimer" for the library, if necessary. Here is a sample; alter the names: Yoyodyne, Inc., hereby disclaims all copyright interest in the library `Frob' (a library for tweaking knobs) written by James Random Hacker. , 1 April 1990 Ty Coon, President of Vice That's all there is to it! libcmis-0.5.2/compile0000755000175000017500000001632713407230142011444 00000000000000#! /bin/sh # Wrapper for compilers which do not understand '-c -o'. scriptversion=2018-03-07.03; # UTC # Copyright (C) 1999-2018 Free Software Foundation, Inc. # Written by Tom Tromey . # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # This file is maintained in Automake, please report # bugs to or send patches to # . nl=' ' # We need space, tab and new line, in precisely that order. Quoting is # there to prevent tools from complaining about whitespace usage. IFS=" "" $nl" file_conv= # func_file_conv build_file lazy # Convert a $build file to $host form and store it in $file # Currently only supports Windows hosts. If the determined conversion # type is listed in (the comma separated) LAZY, no conversion will # take place. func_file_conv () { file=$1 case $file in / | /[!/]*) # absolute file, and not a UNC file if test -z "$file_conv"; then # lazily determine how to convert abs files case `uname -s` in MINGW*) file_conv=mingw ;; CYGWIN*) file_conv=cygwin ;; *) file_conv=wine ;; esac fi case $file_conv/,$2, in *,$file_conv,*) ;; mingw/*) file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'` ;; cygwin/*) file=`cygpath -m "$file" || echo "$file"` ;; wine/*) file=`winepath -w "$file" || echo "$file"` ;; esac ;; esac } # func_cl_dashL linkdir # Make cl look for libraries in LINKDIR func_cl_dashL () { func_file_conv "$1" if test -z "$lib_path"; then lib_path=$file else lib_path="$lib_path;$file" fi linker_opts="$linker_opts -LIBPATH:$file" } # func_cl_dashl library # Do a library search-path lookup for cl func_cl_dashl () { lib=$1 found=no save_IFS=$IFS IFS=';' for dir in $lib_path $LIB do IFS=$save_IFS if $shared && test -f "$dir/$lib.dll.lib"; then found=yes lib=$dir/$lib.dll.lib break fi if test -f "$dir/$lib.lib"; then found=yes lib=$dir/$lib.lib break fi if test -f "$dir/lib$lib.a"; then found=yes lib=$dir/lib$lib.a break fi done IFS=$save_IFS if test "$found" != yes; then lib=$lib.lib fi } # func_cl_wrapper cl arg... # Adjust compile command to suit cl func_cl_wrapper () { # Assume a capable shell lib_path= shared=: linker_opts= for arg do if test -n "$eat"; then eat= else case $1 in -o) # configure might choose to run compile as 'compile cc -o foo foo.c'. eat=1 case $2 in *.o | *.[oO][bB][jJ]) func_file_conv "$2" set x "$@" -Fo"$file" shift ;; *) func_file_conv "$2" set x "$@" -Fe"$file" shift ;; esac ;; -I) eat=1 func_file_conv "$2" mingw set x "$@" -I"$file" shift ;; -I*) func_file_conv "${1#-I}" mingw set x "$@" -I"$file" shift ;; -l) eat=1 func_cl_dashl "$2" set x "$@" "$lib" shift ;; -l*) func_cl_dashl "${1#-l}" set x "$@" "$lib" shift ;; -L) eat=1 func_cl_dashL "$2" ;; -L*) func_cl_dashL "${1#-L}" ;; -static) shared=false ;; -Wl,*) arg=${1#-Wl,} save_ifs="$IFS"; IFS=',' for flag in $arg; do IFS="$save_ifs" linker_opts="$linker_opts $flag" done IFS="$save_ifs" ;; -Xlinker) eat=1 linker_opts="$linker_opts $2" ;; -*) set x "$@" "$1" shift ;; *.cc | *.CC | *.cxx | *.CXX | *.[cC]++) func_file_conv "$1" set x "$@" -Tp"$file" shift ;; *.c | *.cpp | *.CPP | *.lib | *.LIB | *.Lib | *.OBJ | *.obj | *.[oO]) func_file_conv "$1" mingw set x "$@" "$file" shift ;; *) set x "$@" "$1" shift ;; esac fi shift done if test -n "$linker_opts"; then linker_opts="-link$linker_opts" fi exec "$@" $linker_opts exit 1 } eat= case $1 in '') echo "$0: No command. Try '$0 --help' for more information." 1>&2 exit 1; ;; -h | --h*) cat <<\EOF Usage: compile [--help] [--version] PROGRAM [ARGS] Wrapper for compilers which do not understand '-c -o'. Remove '-o dest.o' from ARGS, run PROGRAM with the remaining arguments, and rename the output as expected. If you are trying to build a whole package this is not the right script to run: please start by reading the file 'INSTALL'. Report bugs to . EOF exit $? ;; -v | --v*) echo "compile $scriptversion" exit $? ;; cl | *[/\\]cl | cl.exe | *[/\\]cl.exe | \ icl | *[/\\]icl | icl.exe | *[/\\]icl.exe ) func_cl_wrapper "$@" # Doesn't return... ;; esac ofile= cfile= for arg do if test -n "$eat"; then eat= else case $1 in -o) # configure might choose to run compile as 'compile cc -o foo foo.c'. # So we strip '-o arg' only if arg is an object. eat=1 case $2 in *.o | *.obj) ofile=$2 ;; *) set x "$@" -o "$2" shift ;; esac ;; *.c) cfile=$1 set x "$@" "$1" shift ;; *) set x "$@" "$1" shift ;; esac fi shift done if test -z "$ofile" || test -z "$cfile"; then # If no '-o' option was seen then we might have been invoked from a # pattern rule where we don't need one. That is ok -- this is a # normal compilation that the losing compiler can handle. If no # '.c' file was seen then we are probably linking. That is also # ok. exec "$@" fi # Name of file we expect compiler to create. cofile=`echo "$cfile" | sed 's|^.*[\\/]||; s|^[a-zA-Z]:||; s/\.c$/.o/'` # Create the lock directory. # Note: use '[/\\:.-]' here to ensure that we don't use the same name # that we are using for the .o file. Also, base the name on the expected # object file name, since that is what matters with a parallel build. lockdir=`echo "$cofile" | sed -e 's|[/\\:.-]|_|g'`.d while true; do if mkdir "$lockdir" >/dev/null 2>&1; then break fi sleep 1 done # FIXME: race condition here if user kills between mkdir and trap. trap "rmdir '$lockdir'; exit 1" 1 2 15 # Run the compile. "$@" ret=$? if test -f "$cofile"; then test "$cofile" = "$ofile" || mv "$cofile" "$ofile" elif test -f "${cofile}bj"; then test "${cofile}bj" = "$ofile" || mv "${cofile}bj" "$ofile" fi rmdir "$lockdir" exit $ret # Local Variables: # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" # time-stamp-end: "; # UTC" # End: libcmis-0.5.2/ChangeLog0000664000175000017500000057050613411152402011643 00000000000000# Generated by Makefile. Do not edit. commit 5806decae091e0586b20ae04ca6e88930d91f952 Author: David Tardon Date: Thu Dec 27 14:07:55 2018 +0100 update NEWS commit 12258a1f54b42c12574239cc63258740a8066add Author: David Tardon Date: Thu Dec 27 09:41:14 2018 +0100 shorten the code a bit commit 625219f12ee76b556a74526e784f6ef12492030f Author: David Tardon Date: Thu Dec 27 08:59:47 2018 +0100 cid#328430 pass object by const ref commit 6a6106ddabb98574d63fa6fed558661732499a5a Author: David Tardon Date: Thu Dec 27 09:03:33 2018 +0100 make accessors const commit c5d97a2fbf097a3be61056d3a09f7cfc022a64a9 Author: David Tardon Date: Wed Dec 26 20:09:20 2018 +0100 fix condition commit 2cc9388b03a06fff83f4c391458b82597ecd7ae6 Author: David Tardon Date: Sun Dec 23 19:42:42 2018 +0100 oauth2-providers: drop intermediate var commit 1ea8fe42d96b776eb3b0c078c015836431088f1a Author: David Tardon Date: Sun Dec 23 19:36:02 2018 +0100 oauth2-providers: fix leak commit 18336092478a448042ecb081425ad18db372efec Author: David Tardon Date: Sun Dec 23 19:32:48 2018 +0100 http-session: use unique_ptr to manage memory commit c841e8141ae746a6664be10fbaf3e53157ed95ed Author: David Tardon Date: Sun Dec 23 19:29:04 2018 +0100 session-factory: match comment to reality commit 5fede0b4fe909672ce476e5457b94a29f2e28442 Author: David Tardon Date: Sun Dec 23 19:09:48 2018 +0100 mockup-config: fix another hidden leak in tests commit ea98c33fa4e5964504e6d5585a6aee9998031c07 Author: David Tardon Date: Sun Dec 23 19:02:10 2018 +0100 curl-mockup: fix long-standing leak in tests commit f7d71e6140c95d923b9bde26b0c231256bb32ebd Author: David Tardon Date: Sun Dec 23 15:56:08 2018 +0100 replace BOOST_FOREACH by foreach loop commit a46609ebd4187c52acf890457758e090e1397759 Author: David Tardon Date: Sun Dec 23 15:50:13 2018 +0100 replace boost::scoped_ptr by std::unique_ptr commit cd54cc49b50ac2a4d848679926c29737f8cd0e39 Author: David Tardon Date: Sun Dec 23 15:44:04 2018 +0100 reformat man page using more force commit 4d49839863ca2b6faf9f5c07947abdd3fb0e76dd Author: David Tardon Date: Sun Dec 23 14:32:13 2018 +0100 reformat man page commit 59a30cc98e4e82127e55abdf736cecf129754f7f Author: David Tardon Date: Sun Dec 23 14:17:26 2018 +0100 fill in package version in man page automatically commit acb8ceb889049e222c6b3dfb199359101e8dc1d4 Author: David Tardon Date: Sun Dec 23 14:08:36 2018 +0100 update man page revision date commit ddfff64c6e5ad90d99a1221afc8cd00474bc1fea Author: David Tardon Date: Sun Dec 23 13:59:45 2018 +0100 add bug reporting section to man page commit 822136a285be00d294fba67b2ff55c0039b38674 Author: David Tardon Date: Sun Dec 23 11:33:30 2018 +0100 nitpick commit 960bbe5b3b0859ed5a283ea993497f42e58b90ae Author: David Tardon Date: Sun Dec 23 11:29:17 2018 +0100 use of libcurl is impl. detail commit ff4279895fdd7f8c33e2ba060e2a321a86e2bb38 Author: David Tardon Date: Sun Dec 23 11:26:26 2018 +0100 fix copypasta commit 387b257fceb7c174062e41d5da5b53beeb1d0086 Author: David Tardon Date: Sun Dec 23 09:43:07 2018 +0100 move common test files to a helper library commit ad642fa5e3f1b654c09ecf1390847bfb7a5c86db Author: David Tardon Date: Sat Dec 22 19:28:19 2018 +0100 fix comment in C header commit 2f9ae51084aace4e83ab1b03ba23e7321b2dfb33 Author: David Tardon Date: Sat Dec 22 19:00:02 2018 +0100 be more consistent with naming conditionals commit 5a011586bfe341644627013c4ecfc0b3eb219e93 Author: David Tardon Date: Sat Dec 22 18:58:58 2018 +0100 use automake support for man pages commit 6d7254345deff48bdaf0a7332f44a3643217d7f6 Author: David Tardon Date: Sat Dec 22 18:43:33 2018 +0100 drop obsolete file from tarball commit e603c212e54ec512654531ecaea2c45e8e3ce214 Author: David Tardon Date: Sat Dec 22 18:42:40 2018 +0100 only ignore autogenerated files in m4 commit c75772cea1bc15218952f7e2ed284303b810e838 Author: David Tardon Date: Sat Dec 22 16:45:55 2018 +0100 only export public API symbols commit 048a618d39dd636e43d05093645b1dfe72eb7e15 Author: David Tardon Date: Sat Dec 22 15:25:41 2018 +0100 make the intent more clear commit 378f55bfa15f747744bee8e6e9a99ec62cfea4a9 Author: David Tardon Date: Sat Dec 22 15:19:21 2018 +0100 make the intent more clear commit 6e3d80dfc18d27b92c6a1d544ea4768edddcaf8a Author: David Tardon Date: Sat Dec 22 15:18:44 2018 +0100 apply the standard ordering of headers commit 2a2e2003e40c7dbc8f72ea3425a73981883b8bff Author: David Tardon Date: Sat Dec 22 15:16:05 2018 +0100 make the intent more clear ... and get rid of a few cppcheck issues at the same time, yay! commit 60227ebb290078c23db566f7073aa2a6aa44dac4 Author: David Tardon Date: Sat Dec 22 15:01:07 2018 +0100 do not reinvent the wheel commit d014770d87aff5a32f2ac6ee8ab0fd45addc2241 Author: David Tardon Date: Sat Dec 22 14:53:42 2018 +0100 use unique_ptr commit 90ec40f57fe441be9fdbf31b0a43029203e2e0c2 Author: David Tardon Date: Sat Dec 22 13:44:06 2018 +0100 simplify a bit commit 9528cf7f065756918a630bc68cc71e0802310360 Author: David Tardon Date: Sat Dec 22 11:31:13 2018 +0100 move cppcheck to a separate target commit cb8c4ccd7f3c999b28ed0947d7c687fbc592f705 Author: David Tardon Date: Sat Dec 22 10:30:47 2018 +0100 save some vertical space commit d67bb0408990c991d9c66ff46035a5a4e2367327 Author: David Tardon Date: Sat Dec 22 10:29:05 2018 +0100 fold checks for docbook2man variants into one commit eab4a91a4958af61a49bd6906755a3fd20ae60c7 Author: David Tardon Date: Sat Dec 22 10:24:15 2018 +0100 speed up cppcheck runs commit 069423c2a96ad9f8d1b9a74bc29979cccfe4c838 Author: David Tardon Date: Sat Dec 22 10:00:01 2018 +0100 allow to use cppcheck in out-of-tree build commit abca33c92696968fef25ae144a60bd54c9651160 Author: David Tardon Date: Sat Dec 22 09:38:27 2018 +0100 cppcheck: disable information messages commit db76d36a3e48a22247a6cffc7bd58248d7e342cf Author: David Tardon Date: Thu Dec 20 15:26:47 2018 +0100 ensure headers are self-containing commit e5209c1af8466836296b598978c5639303fecd0b Author: David Tardon Date: Thu Dec 20 14:07:15 2018 +0100 include API headers with full path commit 93bb274e604aed40703edd919bfe35d1fc6779f8 Author: David Tardon Date: Thu Dec 20 13:14:59 2018 +0100 include API headers with full path commit 5bb75200a5621c4c3971865dd07694861517602b Author: David Tardon Date: Thu Dec 20 13:18:06 2018 +0100 do not override compiler opt. flags commit aea7bc285f5b3bee1e4045d3136a5659d3820941 Author: David Tardon Date: Thu Dec 20 13:00:01 2018 +0100 generate versioned .pc files from configure commit 8bf9009b50b7044e9415ab22e82935563d9c1f1f Author: David Tardon Date: Thu Dec 20 12:57:36 2018 +0100 sort various file lists lexicographically commit c5cbc8450ed3071928510201e5220a86bf3f3630 Author: David Tardon Date: Thu Dec 20 12:53:42 2018 +0100 use tabs for indentation commit 775b544672c932ae5237e054f940dd15e50635d1 Author: David Tardon Date: Thu Dec 20 12:51:37 2018 +0100 move conditional up commit 57e1ebc6260f78d1b3135bc212b42704065d486c Author: David Tardon Date: Thu Dec 20 12:41:24 2018 +0100 move API headers into a separate dir commit 18f849afe72a6f5b5f1bde4bce945623eae9c5db Author: stbergmann Date: Fri Dec 21 13:24:17 2018 +0100 Properly encode OAuth2 credentials (#25) * Properly encode OAuth2 credentials Originally created as "Properly encode OAuth2 credentials". I was not sure which C++ version to target, so kept it pretty basic. commit eaee7f60ed7db9e155d8e0e3968a9b7a4b32395d Author: David Tardon Date: Wed Dec 19 14:30:31 2018 +0100 WaE (C++14): also define sized delete commit 51da3c3b26b24a60ba6e85b58da4aee0d2d0075f Merge: 732a676 4f52f83 Author: David Tardon Date: Sat Dec 1 11:47:18 2018 +0100 Merge pull request #21 from schnitzeltony/master Fix build with boost >= 1.68.0 commit 732a676958b8fabace231c068bc824e067730c29 Author: David Tardon Date: Sat Dec 1 11:32:55 2018 +0100 simplify this commit 463adde9e13350e9ec3f8ef24a93d0d2f8a9701e Author: David Tardon Date: Sat Dec 1 11:19:37 2018 +0100 nothing to see here, move along commit 1d924db953d2d3bd87f46b671969ce804d9a1eba Author: David Tardon Date: Sat Dec 1 11:11:00 2018 +0100 WaE: catch exception by ref commit 172e83762b2b4b300073212ffd841dc90680bb86 Merge: 738528d 4ddfdb3 Author: David Tardon Date: Sat Dec 1 11:24:14 2018 +0100 Merge pull request #16 from vmiklos/dynexcspec Remove dynamic exception specifications commit 4f52f83881cd824821160841d5c8bd8a0bd82729 Author: Andreas Müller Date: Fri Oct 26 22:57:36 2018 +0200 Fix build with boost >= 1.68.0 Addresses [1] https://github.com/tdf/libcmis/issues/19 Signed-off-by: Andreas Müller commit 4ddfdb3c87d6e0d5598f430a2bb6b001bf55c84d Author: Miklos Vajna Date: Tue Nov 28 09:16:44 2017 +0100 Remove dynamic exception specifications Replace deprecated dynamic exception specifications with the appropriate noexcept specification (introduced in C++11). Replace throw() with noexcept, and throw([,...]) with. commit 738528d790b2b1d52d9b72d673842969a852815d Author: David Tardon Date: Thu Jan 18 10:48:52 2018 +0100 return early if the time part is empty commit ff7ed27039693f91e8348495f3b909c23871123d Author: David Tardon Date: Thu Jan 18 10:42:04 2018 +0100 do not try to use [] on an empty string commit 310ff17804b5dd9ddc455592e116a75bb5c2e0e3 Merge: 86a50d6 449f926 Author: David Tardon Date: Mon Nov 27 17:32:21 2017 +0100 Merge pull request #15 from vmiklos/master Switch to C++11 commit 449f92685f1d9c81a4c7d697f99588e4317c6187 Author: Miklos Vajna Date: Mon Nov 27 08:38:46 2017 +0100 Switch to C++11 The immediate benefit would be that then dynamic exception specifications can be replaced by noexcept and noexcept(false), instead of removing them (to be able to build the code with -std=c++17). The m4 macros are used already in e.g. libepubgen, i.e. they are known to work on all platforms covered by LibreOffice Jenkins. Also, to please Travis: - fix prototype of the dummy operator new() to match what C++11 provides - fix -Werror,-Wvarargs errors - silence -Werror,-Wkeyword-macro errors commit 86a50d6bad2ba44a8107ddb379d2ec6b84537a48 Author: David Tardon Date: Tue May 16 11:58:12 2017 +0200 fix build error with gcc -std=c++98 atom-object.cxx: In member function ‘bool {anonymous}::MatchLink::operator()(AtomLink)’: atom-object.cxx:63:91: error: no matching function for call to ‘remove_if(std::__cxx11::basic_string::iterator, std::__cxx11::basic_string::iterator, )’ linkType.erase( remove_if( linkType.begin(), linkType.end(), std::isspace ), linkType.end() ); commit ca381ff4586c9fc1190d285137ba8f67b102d600 Author: David Tardon Date: Tue May 16 11:52:43 2017 +0200 do not reinvent the wheel commit 8b401fdea3f621101876f31f21aa98ffd60f5e91 Author: David Tardon Date: Tue May 16 10:02:19 2017 +0200 drop :: prefix commit e50aa2612799d308fb748cd01a2cc88c4f47330f Merge: 8cc9668 1effce6 Author: David Tardon Date: Thu Mar 30 13:44:26 2017 +0200 Merge pull request #14 from eszkadev/google-2fa-fix-2 Fix 2FA for Google Drive commit 1effce6d286ba3a9f467e15074b532d2ba4b7c98 Author: Szymon Kłos Date: Wed Mar 29 17:45:10 2017 +0200 Fix 2FA for Google Drive commit 8cc9668e21ef67ca26b9282fa117cd32fc5734c3 Author: David Tardon Date: Mon Feb 27 19:35:47 2017 +0100 IMHO 100 redirections is overkill commit c87fb4fa79071d249eb7f0c611f2d7176486d99a Author: David Tardon Date: Mon Feb 27 19:34:11 2017 +0100 limit the number of redirections for PUT too commit 3637a6bbf0a3daf8c11d4290ea47523e3ebeb496 Author: David Tardon Date: Mon Feb 27 19:33:45 2017 +0100 rhbz#1410197 limit the number of redirections commit 6d5d00b3e7ca36e53c9072f9af111f6739c3449a Author: Thorsten Behrens Date: Tue Dec 13 17:36:37 2016 +0100 -wError C4101: 'e' : unreferenced local variable commit 5bea25bfc77b3a0c9fea0289f5280740401324b1 Author: Thorsten Behrens Date: Sun Dec 11 03:23:11 2016 +0100 Catch empty / incomplete datetime strings early Otherwise code accesses past-the-end positions commit 119395c63f1d4a4a09d4e9333c4d69e2a28d87a3 Author: Thorsten Behrens Date: Sun Dec 11 03:21:28 2016 +0100 Test corner-cases for parseDateTime Build with CXXFLAGS=-D_GLIBCXX_DEBUG to make this fail commit 913408997351ff4099697ad3b731d2b0a56af558 Author: Thorsten Behrens Date: Sun Dec 11 02:44:51 2016 +0100 Update AUTHORS commit da8c3fdc281a0cb3753a6bb9eaa63ac6385e2963 Author: Mike Kaganski Date: Wed Aug 10 09:39:57 2016 +0200 tdf#101385: don't try to get SharePoint folder outside of allowed range commit 9ffb376c21f7f55fb9237d83f7ea322517f691e2 Author: David Tardon Date: Thu Jun 16 15:03:37 2016 +0200 update boost.m4 to fix version detection with gcc 6.1 commit d2054a12e3f52fff8e96341e8c48f0dcd75e2e2a Merge: 7c2eae3 9916eda Author: David Tardon Date: Fri Jun 3 07:36:02 2016 +0200 Merge pull request #9 from eszkadev/google-2fa-fix Google 2fa fix commit 9916eda65d22e2a65f3ad0d85376aa73420567dd Author: Szymon Kłos Date: Tue May 31 19:13:45 2016 +0200 macros with string literals and length commit fe77ebada2e6e11ce78a2a841630a94eeab53eef Author: Szymon Kłos Date: Tue May 31 09:56:14 2016 +0200 removed unnecessary conditions commit fc4c3a326f5dc98e62353572423a0da750975b57 Author: Szymon Kłos Date: Mon May 23 15:26:01 2016 +0200 google 2FA fix, new challenge page commit 22dce0a530b7f669d406c048e9d35b894a151c21 Author: Szymon Kłos Date: Mon May 23 15:18:39 2016 +0200 gdrive: test, new challenge page commit 7c2eae350f2bf8bfb4c42f53a4b4c06148e9b226 Author: David Tardon Date: Mon May 16 09:21:52 2016 +0200 and -> && commit bab8b288aa5a56ce0394ba305606d1cdf539a2ac Merge: d34c541 0b952f4 Author: David Tardon Date: Mon May 16 09:21:20 2016 +0200 Merge pull request #8 from eszkadev/google_2fa Google 2fa commit 0b952f449bd3cca422dfdfbfc8220f25b86f09c7 Author: Szymon Kłos Date: Sun May 15 13:40:20 2016 +0200 gdrive 2FA test commit 81ef503e10221e880c6783b9db588c8654827e7b Author: Szymon Kłos Date: Sun May 15 00:14:08 2016 +0200 google 2FA implementation commit d34c54133a9e7f88ee4498ef40c05792110843db Author: David Tardon Date: Tue May 10 14:41:55 2016 +0200 add gdrive fix to NEWS commit ed2d24efdcfe5ab683433ab0388832fec51e4023 Author: David Tardon Date: Tue May 10 14:36:04 2016 +0200 bump revision for the next release commit e582d018b6a80fc55e46263e9cf0036c59f26841 Author: David Tardon Date: Tue May 10 14:33:02 2016 +0200 produce xz-compressed tarballs commit ad89848c93d9357992f6d7d9a5b1e602f25e930c Author: Tomas Chvatal Date: Tue May 10 14:32:33 2016 +0200 libcmis is not a GNU-conformant project commit 4dbed0d44b7785ea1d738e4b278b39c8cf27b9f8 Merge: 4f9ba97 3ebc3d9 Author: David Tardon Date: Wed May 4 09:16:46 2016 +0200 Merge pull request #6 from beppec56/fix-gdrive-login Fix gdrive login commit 3ebc3d9fe6a9806de2bcdf79ac6398f0c14c3246 Author: Giuseppe Castagno Date: Tue May 3 15:41:52 2016 +0200 Fix test in test-onedrive commit 73662089059eb2e272a4c5eb245a497af044ccf6 Author: Giuseppe Castagno Date: Tue May 3 15:35:57 2016 +0200 Fix test in test-gdrive commit 04297298ad9659c949beb7ccd0f75cfd440a4fb8 Author: Giuseppe Castagno Date: Tue May 3 11:47:43 2016 +0200 Fix test in test-factory commit 0490c023cd14cbb3d1ba2bc1b648b216f848a648 Author: Giuseppe Castagno Date: Tue May 3 08:35:57 2016 +0200 Add new mokup login pages commit 32aecffb5517dfc3b3674a8f7db418456bd877ed Author: Giuseppe Castagno Date: Sat Apr 30 14:29:56 2016 +0200 Add new Google Drive OAuth 2.0 login procedure. The new Google login sequence uses two html pages: first page for user email the second page for password. The older sequence used only one page for both user email and user password. commit 4f9ba9754b91b68ab5be38b59ab1bd3c5b22e8a2 Author: David Tardon Date: Fri Mar 4 09:59:22 2016 +0100 prepare for a release commit ce8711795f5bb173e642386e8d03bbcd62550d08 Author: David Tardon Date: Wed Mar 2 17:51:19 2016 +0100 add compile to .gitignore commit 626ab4ee25f846b6559ae3c5591eb1414f2ee1d9 Author: David Tardon Date: Wed Mar 2 08:27:05 2016 +0100 fix mismatched free/delete[] commit 31d94900de5be5a31d35939c6b39f2b51e29f687 Author: David Tardon Date: Wed Mar 2 07:59:55 2016 +0100 ensure doc is not leaked commit c50fab73477536cb2f0853d7ff48742695f5915f Author: David Tardon Date: Wed Mar 2 07:52:10 2016 +0100 coverity: honor exception specs commit 5bb9255ee6b7033d9ea03702dfeda9c99bd79e0f Author: David Tardon Date: Wed Mar 2 07:48:09 2016 +0100 coverity: honor exception specs commit 2e4fd7e285a530a4fbe188db28b4d2f33b40aa21 Author: David Tardon Date: Wed Mar 2 07:39:34 2016 +0100 reset the "in OAuth2" flag on exception commit 9fb89379216159ee007edcf3a41deb4721fbfe15 Author: David Tardon Date: Wed Mar 2 07:35:05 2016 +0100 coverity: honor exception specs commit 27516e32955c7e0196df3c087174bae7156b4609 Author: David Tardon Date: Wed Mar 2 07:24:10 2016 +0100 coverity: honor exception specs commit e116720f71bfc94d963442218655ac727195fc1d Author: David Tardon Date: Wed Mar 2 07:23:27 2016 +0100 coverity: likely intent commit faee72686eba4c55ae40cc704083239013f4708f Author: David Tardon Date: Tue Mar 1 20:21:32 2016 +0100 coverity: avoid possible null ptr deref commit eca67a5e400b9c7d2267a6279b72fce2ece0c2ab Author: David Tardon Date: Tue Mar 1 20:20:00 2016 +0100 coverity: avoid possible null ptr deref This way dynamic_cast will throw an exception if the dynamic type does not match. commit fedfb6247925ad8b1206d96c2181f7e6aaffa45d Author: David Tardon Date: Tue Mar 1 14:49:18 2016 +0100 avoid memory leak commit d1541095b8c79adeac498641b0a39f9424782f16 Author: David Tardon Date: Tue Mar 1 14:17:07 2016 +0100 avoid memory leak commit ad16167fd4af205a62876cb9fc279e611ce5bccf Author: David Tardon Date: Tue Mar 1 14:15:38 2016 +0100 avoid memory leak commit 860c609580f8f3085ec5f6bec58eacb17660f5d1 Author: David Tardon Date: Tue Mar 1 12:31:51 2016 +0100 do not leak in case of exception commit ac4dbb38eeb1f7f4f2f6aa5593bb572368411b58 Author: David Tardon Date: Tue Mar 1 12:27:38 2016 +0100 ensure we can use the buffer as a C string commit df9b26d83eb3a5fe12d62f13114e019d8d6223f8 Author: David Tardon Date: Tue Mar 1 11:54:40 2016 +0100 avoid memory leak commit 95270e1522732a86166dbe331bc29f192b018a11 Author: David Tardon Date: Tue Mar 1 11:53:52 2016 +0100 avoid memory leak commit 15a4c68e52e8c17ad5f13c53245305ed8bfd519c Author: David Tardon Date: Tue Mar 1 11:51:31 2016 +0100 avoid memory leak commit 00b685b75e09347774e5e17da7076e36be39db64 Author: David Tardon Date: Tue Mar 1 11:50:08 2016 +0100 do not leak in case of exception commit d3a8264d053aaceb5a357bc0500bdb0a0f7066a8 Author: David Tardon Date: Tue Mar 1 11:48:15 2016 +0100 do not leak in case of exception commit c95ad2e3927bddf698b496504188a312fc9b0d47 Author: David Tardon Date: Tue Mar 1 11:44:08 2016 +0100 avoid memory leak commit ab520712efb46765714ba896ae3854d69c9bbdc2 Author: David Tardon Date: Tue Mar 1 11:43:49 2016 +0100 avoid memory leak commit 93cab114e9bb3ae79a8599991df4770fe7431989 Author: David Tardon Date: Tue Mar 1 11:41:51 2016 +0100 ensure we can use the buffer as a C string commit 48bee8309e72ccc5a72a3aad30799b56daeca8d7 Author: David Tardon Date: Tue Mar 1 11:35:01 2016 +0100 avoid memory leak commit 5ce62bed0459b77655cf89d1a51e9c28adf1971d Author: David Tardon Date: Tue Mar 1 11:34:02 2016 +0100 avoid memory leak commit 6e285d5fe13c47a2e19b65fa4e009d15d8c0230a Author: David Tardon Date: Tue Mar 1 11:28:28 2016 +0100 avoid memory leak commit 9442be314426028c61fc724675de0156ad5ed857 Author: David Tardon Date: Tue Mar 1 10:43:59 2016 +0100 avoid memory leak commit d83db6ad25f8bae35086ba77f5a3132b759fbc60 Author: David Tardon Date: Tue Mar 1 10:34:39 2016 +0100 avoid memory leak commit aab95fcffd67c013709fa75d7fa5347d8f4fb45b Author: David Tardon Date: Tue Mar 1 10:33:42 2016 +0100 avoid memory leak commit ee477289a38b2612842d31c715973d5cd07ea1a4 Author: David Tardon Date: Tue Mar 1 10:32:44 2016 +0100 avoid memory leaks commit 9dbe05577b737c061edfc545523b107c62080436 Author: David Tardon Date: Tue Mar 1 10:31:38 2016 +0100 avoid memory leaks commit 26f13e1cf86b984797a198830396170d65c01ba1 Author: David Tardon Date: Tue Mar 1 10:27:08 2016 +0100 avoid memory leak commit 41cd73c31be248186564455b12a16b40c9b04a18 Author: David Tardon Date: Tue Mar 1 10:19:50 2016 +0100 avoid memory leaks commit 4ce497fd9e58b04ac7b4f74f3a92979655e599bc Author: David Tardon Date: Tue Mar 1 10:06:48 2016 +0100 coverity: avoid possible memory leak commit 4ced72bff0bda9e7c0f9645cd9b8284f61eb8783 Author: David Tardon Date: Tue Mar 1 20:10:27 2016 +0100 likely intent commit 44327bc31d20982c86c40d1755f2a0839bc74d2c Author: David Tardon Date: Tue Mar 1 09:56:53 2016 +0100 avoid memory leak commit f484e87ab935c362f6a2a597d51f70f1f0ca5f1e Author: Jonathan Wakely Date: Wed Sep 2 16:35:45 2015 +0100 Remove invalid comments from test JSON file. commit a687896ddcc7819dd470ff7ddecc2231689345c1 Author: Jonathan Wakely Date: Tue Sep 1 13:00:18 2015 +0100 Avoid redundant upcast and dynamic_cast steps. commit 3c9d7b215904fd3120e5d2fa2f1e36a4aab19fc5 Author: Jonathan Wakely Date: Tue Sep 1 12:58:31 2015 +0100 In WSSession assignment release any existing resources. commit a9866eb68d2262f2d83a251786ea4db4c5710d28 Author: Jonathan Wakely Date: Mon Aug 31 15:15:45 2015 +0100 Use scoped_ptr to manage Sessions. commit cf637eefec87e2098abe9598968665054c633900 Author: Jonathan Wakely Date: Mon Aug 31 13:21:32 2015 +0100 Don't create exception on the heap before throwing. commit 41d66727ed987e8aaa87ea8cf7bcc095d903d007 Author: Thorsten Behrens Date: Mon Aug 17 00:14:20 2015 +0200 clang: -Werror,-Wunused-function commit 3d83f957fe829e535123c983c85d3b3d37f30404 Author: Thorsten Behrens Date: Sun Aug 16 23:00:07 2015 +0200 Add travis CI status to repo page commit 39e2147316ecdfefa311b1b0ae4f4fd02d85cef3 Author: Thorsten Behrens Date: Sun Aug 16 22:35:21 2015 +0200 Add .travis.yml for github-style CI commit 0a06805f6de5c4bfe881efc5f54231c146bc47ab Author: Cédric Bosdonnat Date: Thu Jul 16 16:23:51 2015 +0200 Fix AtomTest::createFolderBadTypeTest commit 0ad3ec084d918be503a8ce971af1b54887d7726f Author: Cédric Bosdonnat Date: Thu Jul 16 16:23:06 2015 +0200 Getting cppcheck-test to pass again commit b572b60a5fdc630f7f3b31dfd5dbdd1ed48659ca Author: Cédric Bosdonnat Date: Thu Jul 16 16:22:11 2015 +0200 Fix linking error when building with --with-boot commit 60506199cf4f6fc13133ac5bc74ecb81fd27db76 Author: Cédric Bosdonnat Date: Thu Jul 16 14:19:06 2015 +0200 README: added list of dependencies commit 3875cb5201d9af404df225d700da644304a1cb4e Author: Cédric Bosdonnat Date: Thu Jul 16 14:05:31 2015 +0200 README is a markdown file commit 1aac48fc57e880ceaad575c4a9ecb5576fa66060 Author: Cédric Bosdonnat Date: Thu Jul 16 13:58:08 2015 +0200 More useful README commit d87c52e1efc1f3e54e9ebf5994f10371350139eb Author: Vasily Melenchuk Date: Wed Jul 15 11:54:52 2015 +0200 do not require password to be not empty to use http authentication credentials commit 1100f4591dfae351199128fd90689ce07a9b6013 Author: Thorsten Behrens Date: Wed Jul 8 14:26:01 2015 +0200 tdf#90351: response does not always contain cmis:baseTypeId So if we know which object we just created, don't rely on the server response to tell us. commit 58130d0f774242da1177ae2f77a711e7aaa8ab7d Author: David Tardon Date: Thu Feb 26 14:48:27 2015 +0100 avoid use-after-delete commit 645df9a0885931001e0a7afaf56de39cd33f9119 Author: David Tardon Date: Thu Feb 12 15:13:28 2015 +0100 fix boost configuration with gcc 5 commit b5ac83cd9238cac07cd52a1c2e6eb33922772f56 Author: Cédric Bosdonnat Date: Thu Dec 11 15:12:05 2014 +0100 Fix sharepoint object copy test commit 97e970ba4903e0b31d16b03f2653cfa2c1825d56 Author: Cédric Bosdonnat Date: Wed Oct 1 23:15:35 2014 +0200 Added some more sharepoint simple tests commit 4037d0102fe9d874be4ca92827ef81ed60e9b5da Author: Cédric Bosdonnat Date: Wed Oct 1 22:23:45 2014 +0200 Added a copy constructor tests for WS services commit 2406efcec7f9ff3094d24cf149b9e70be210e5f4 Author: Cédric Bosdonnat Date: Wed Sep 24 22:36:05 2014 +0200 Improved WSObjectType tests Added test for refresh, getParentType, getBaseType and getChildren commit 612b398a04f0c99a949d898c3695012fb03b865f Author: Cédric Bosdonnat Date: Mon Sep 22 22:59:10 2014 +0200 Test coverage improvements for Rendition commit acd281d7d2885eb99a2e8876dca16eb9d4391b2d Author: Cédric Bosdonnat Date: Mon Sep 22 22:44:18 2014 +0200 Don't check coverage in Rendition::toString commit 61abc01bbca374fdf956d0c378ef6abcb16b45fe Author: Cédric Bosdonnat Date: Mon Sep 22 22:42:31 2014 +0200 Added SoapResponseFactory copy test commit 43fed0cba7974cc3cf280f553bbeb138c5a9d745 Author: Cédric Bosdonnat Date: Mon Sep 22 22:29:38 2014 +0200 test SOAP parseResponse XML version commit a8efe85ccfdd1be811df8536633008838f8b99cd Author: Cédric Bosdonnat Date: Mon Sep 22 22:22:14 2014 +0200 Added getRenditions test for WS binding commit 2cec221f8be4a8970e4619321a404d52818960c5 Author: Cédric Bosdonnat Date: Mon Sep 22 20:38:45 2014 +0200 Test coverage improvements for ObjectType commit 60e717e785ee0382565cfb1a4d42658a82e37075 Author: Cédric Bosdonnat Date: Fri Sep 19 09:33:51 2014 +0200 Added some copy constructors tests commit de006db972efcca57e1b1aa9adc10f6c9937f9b7 Author: Cédric Bosdonnat Date: Thu Sep 18 23:13:31 2014 +0200 Fixed GDriveSession::getObjectByPath and added unit tests for it commit 5ae325c0cc412c6a92aca26b2c358bcf7a346e5e Author: Cédric Bosdonnat Date: Thu Sep 11 22:47:56 2014 +0200 Test for GDriveSession::setRepository commit 0d7d4a143c5f984622f0223019e4b2132db19bde Author: Cédric Bosdonnat Date: Thu Sep 11 22:29:10 2014 +0200 Added test for GDrive property copy commit 965cbb604ea366ff6df3808a2aaaa68730c27964 Author: Cédric Bosdonnat Date: Thu Sep 11 22:12:00 2014 +0200 Reworked GDrive properties update test commit c6617ee827911a65a18147562929512673fe538f Author: Cédric Bosdonnat Date: Thu Sep 11 21:03:07 2014 +0200 libcmis: improved test coverage commit db2881921c62919f8fe1e225d7337fb7f9d74903 Author: Cédric Bosdonnat Date: Thu Sep 11 21:02:48 2014 +0200 cppcheck: fixed invalid use of possibly NULL pointer in tests mockup commit 9a6412665e6f1a180fdc2c5c4ab4bf44f9f1f32c Author: Mihai Varga Date: Tue Sep 16 16:08:09 2014 +0300 SharePoint - checkOut is canceled after checking out the document commit 5d83f017696e68b5e0fc5aad2095f46f678c955e Author: Mihai Varga Date: Tue Sep 16 15:50:34 2014 +0300 SharePoint - getParentTest inside getChildrenTest A document only gets its parentId set when the parent folder is listed and the ID is passed to the constructor, because SP doesn't provide a parentId property. So all the code from getChildrenTest was needed for the getParentTest and that would have been a lot of duplicated code commit 6bb8dc579d82de667149cd1ae4b3511452d7eea7 Author: David Tardon Date: Thu Sep 4 16:48:00 2014 +0200 coverity: return const string& Otherwise the use in the C wrapper functions is invalid, as the functions return char* from a string object that is destroyed in the function scope. commit 23110ee56717cde1901c66994a37a1951425349d Author: Cédric Bosdonnat Date: Tue Sep 2 16:30:46 2014 +0200 coverage: marked toString functions as untested commit 9c72613e39f92d4e6e86615af5dbfcae23df76b5 Author: Cédric Bosdonnat Date: Tue Sep 2 16:10:49 2014 +0200 Tested Document::getPaths() commit 3e8954b8c3f106a0c4d240358fb4437899345a46 Author: Cédric Bosdonnat Date: Tue Sep 2 15:33:38 2014 +0200 Clean more of the coverage results commit 4a8eff3cbc058b29edd126c53ff9cd3d907c7cf0 Author: Cédric Bosdonnat Date: Tue Sep 2 15:33:05 2014 +0200 Added unit tests for OneDrive ObjectType commit ad9e904be4671998a0b0f8c7b771af55bd31e922 Author: Cédric Bosdonnat Date: Tue Sep 2 11:35:52 2014 +0200 Fixed linking with --enable-coverage commit 6a9874bdfb69590d1af3fab9ffa638eb59e6c08c Author: Cédric Bosdonnat Date: Tue Sep 2 10:51:56 2014 +0200 Fixed problems reported by cppcheck commit 46f19b9084bdbae994f6cd5aaf2e61ccd069bd66 Author: Mihai Varga Date: Mon Aug 25 13:34:36 2014 +0300 Checkin test for the test script commit eff69a46bf061698d02c539d8c992299eff6e13e Author: Mihai Varga Date: Mon Aug 25 13:33:20 2014 +0300 Better arguments parsing for the test script commit 74c4ee580179efe55fcc0e12ee159169053ece83 Author: Mihai Varga Date: Mon Aug 25 13:30:22 2014 +0300 Folder and documents might have spaces in their names commit c2e0eb0409d8dc3b05901069d41825c6d3a3b730 Author: Mihai Varga Date: Thu Aug 14 18:40:10 2014 +0300 GDrive - an uploadType parameter was needed to upload file contents I think the api has changed since last year commit 5d13db64551320636cab1f85354a248f49175354 Author: Mihai Varga Date: Mon Aug 11 18:10:25 2014 +0300 cmis-test now supports bindings with oauth2 commit 7679b049f58ba3b4b4b3ebfe7a386113cd0920fe Author: Mihai Varga Date: Mon Aug 11 17:43:21 2014 +0300 removed empy line commit 08a0c1c81228339bf82f7b38a055fdd734295508 Author: Mihai Varga Date: Mon Aug 11 15:48:56 2014 +0300 AuthCode provided as parameter for the cmis-client Needed for times when automatical authentication fails, mainly in the OneDrive connection commit fce8d48f1fa3a14a512b422de9284a1fbb8d6737 Author: Mihai Varga Date: Wed Aug 6 17:19:04 2014 +0300 SharePoint - getAllVersions now adds the latest version too commit 1b2e60deb71dd4142047a6f316ee4f86dd061947 Author: Mihai Varga Date: Wed Aug 6 16:54:54 2014 +0300 Sharepoint - the file vers. createad date prop is needed as cmis:lastModDate commit 676f52b81f62c9337b7384bd919fc248d553233b Author: Mihai Varga Date: Wed Aug 6 15:03:05 2014 +0300 SharePoint - only documents are versionable commit d925768d6169c577a0909c2a45fa6645c435d36b Author: Mihai Varga Date: Wed Aug 6 15:01:49 2014 +0300 SharePoint parse added some more file version properties commit a82c448298d4f70386f66f76e325a6f4f47b7743 Author: Mihai Varga Date: Tue Aug 5 19:30:08 2014 +0300 SharePoint request body really needs to be empty commit cd96e42be79d6678f7f41922e35aad6cf0081c16 Author: Mihai Varga Date: Tue Aug 5 17:08:58 2014 +0300 SharePoint properties type is set commit 7f5e5bd486c4c94ab1d2b149ec3afec8aa51ff30 Author: Mihai Varga Date: Mon Aug 4 19:25:54 2014 +0300 SharePoint document isVersionSeriesCheckedOut property is set commit 7ea4fbad74f5dc1fc1c9513f80b49fdfd09de245 Author: Mihai Varga Date: Mon Aug 4 17:03:31 2014 +0300 SharePoint repository rootId the rootId needs to be http://host/_api/web/getFolderByServerRelativeUrl('/') so we need to know the baseUrl in the Repository's constructor commit 33a6a01e9148980e80f78319afcc2193a8cb824f Author: Mihai Varga Date: Mon Aug 4 16:15:44 2014 +0300 SharePoint getObjectByPath test commit de0858377d4c829fbf8e64171f7bd115ac1cc218 Author: Mihai Varga Date: Mon Aug 4 16:15:17 2014 +0300 SharePoint getObjectByPath method commit e7a7230ce2014dad324d43d7471b593c2963da20 Author: Mihai Varga Date: Fri Aug 1 12:26:07 2014 +0300 SharePoint getType method commit ed18770cb02f4a972045399968ca84dd4a1bebe3 Author: Mihai Varga Date: Wed Jul 30 12:27:04 2014 +0300 SharePoint object type - forgot to remove the description commit f05bcfaa0422580f7b0d8bceb4bdb1714e775c69 Author: Mihai Varga Date: Wed Jul 30 12:20:47 2014 +0300 SharePoint object type commit 0c67fed62395106861898949183388b6e8238511 Author: Mihai Varga Date: Wed Jul 30 12:08:19 2014 +0300 SharePoint updateProperties method commit 65ec0b2ab064bad34b1d32234be75ad56d81ad16 Author: Mihai Varga Date: Wed Jul 30 12:04:08 2014 +0300 SharePoint move test commit ed126e4b23db0c9e6021defd57cd9f8b08883140 Author: Mihai Varga Date: Wed Jul 30 12:02:59 2014 +0300 SharePoint move method commit f7376c8633b9ff2784a026eb8545e146c2d4be93 Author: Mihai Varga Date: Wed Jul 30 10:54:33 2014 +0300 SharePoint wrong file property name commit add54dce7a0111426e27be612e72e7cd551611b4 Author: Mihai Varga Date: Tue Jul 29 18:20:17 2014 +0300 SharePoint folder properties response commit a308ca96a5ae86e9b9628b6ee10164034377e614 Author: Mihai Varga Date: Tue Jul 29 18:19:10 2014 +0300 SharePoint createDocument test commit 1f98f12e3980fb141db6f38a9b512b8d48067003 Author: Mihai Varga Date: Tue Jul 29 18:18:35 2014 +0300 SharePoint createDocument method commit 655042a8c23738965ba649f7bf88060a2bc86566 Author: Mihai Varga Date: Tue Jul 29 15:49:10 2014 +0300 SharePoint createFolder test commit 9b44de224b51535a211a9d5e333f417dda3de187 Author: Mihai Varga Date: Tue Jul 29 15:48:33 2014 +0300 SharePoint createFolder method commit b85f804f16b30a44861ea88a42b8b9f32d88343f Author: Mihai Varga Date: Mon Jul 28 19:54:55 2014 +0300 SharePoint - updated the tests for the properties fetching commit a717f066749badacf34bdff9fdf4dac824cad2a7 Author: Mihai Varga Date: Mon Jul 28 19:53:30 2014 +0300 SharePoint creation/lastModification dates need to be fetched commit fa7b585eacda3d7afe4db1ddc9fda58cb30ee52e Author: Mihai Varga Date: Mon Jul 28 18:34:48 2014 +0300 SharePoint getChildren test commit a98f638e5f5ef8519d6dc519a5ea0db2330d4404 Author: Mihai Varga Date: Mon Jul 28 18:34:22 2014 +0300 SharePoint children JSON responses commit 7b9ce6fc6612925f81ca9ab6787a94f1bdafc6b0 Author: Mihai Varga Date: Mon Jul 28 18:33:40 2014 +0300 SharePoint getChildren method commit efca4ffb0264cf0b19339a319351a37c3864be6e Author: Mihai Varga Date: Mon Jul 28 18:30:52 2014 +0300 Extract data from JSON "d" object Basic GET requests get the data inside a "d" object, but child listing doesn't, so this unifies the representation commit 32d25750f825ab9100720837f595412ba64ec577 Author: Mihai Varga Date: Sat Jul 26 12:41:41 2014 +0300 SharePoint getFolder test commit 466f40c42dc7bf13d397717b6a6b274af972a5bd Author: Mihai Varga Date: Sat Jul 26 12:41:07 2014 +0300 SharePoint root folder JSON commit 1c3cb848efec64e091b72e3a54ce3d8af2263089 Author: Mihai Varga Date: Sat Jul 26 12:39:14 2014 +0300 SharePoint folder creation is now handled commit f0fda49cb346efb4ea98fe792ee998897bbd8fd2 Author: Mihai Varga Date: Sat Jul 26 12:38:43 2014 +0300 SharePoint folder class commit 4cb2143d202a53d05cb3725265762a70d12bbad5 Author: Mihai Varga Date: Sat Jul 26 12:38:08 2014 +0300 SharePoint - only add the parentId property if it is defined commit 1488d45013bb7c792f097e33e8c8f927ef2ab5b3 Author: Mihai Varga Date: Sat Jul 26 12:37:15 2014 +0300 SharePoint - new properties from the folder JSON response commit af37e8d4a00176bb0722876f8b839e5940f564c8 Author: Mihai Varga Date: Fri Jul 25 17:30:24 2014 +0300 SharePoint getAllVersions test commit d97b3c7ad92d67591bd1caf394b020219bddafe3 Author: Mihai Varga Date: Fri Jul 25 17:29:45 2014 +0300 SharePoint getAllVersions JSON responses commit e9f8ea6975255feecf47d42609ff59be8b3191c4 Author: Mihai Varga Date: Fri Jul 25 17:28:20 2014 +0300 SharePoint getAllVersions method commit cf3f5f6170bc2f4e4a79273741161670ba021f75 Author: Mihai Varga Date: Fri Jul 25 16:10:24 2014 +0300 SharePoint properties from file versions commit 36476de8fe0182068bb91f2e3f544903f86d41a2 Author: Mihai Varga Date: Fri Jul 25 13:05:52 2014 +0300 SharePoint checkIn test commit c58dcef747726bb5e6633cc6399e4766b246abf7 Author: Mihai Varga Date: Fri Jul 25 13:05:19 2014 +0300 SharePoint checkIn method commit 04c52170d33bdbaea52fd68eaf2daf096f8cf64a Author: Mihai Varga Date: Wed Jul 23 13:29:20 2014 +0300 OneDrive album objects can be treated as folders commit fdc967aa61dd2dfa410a022dcd7b44a494f7dd3d Author: Mihai Varga Date: Wed Jul 23 12:02:01 2014 +0300 OneDrive exported properties fix commit 52b7b792c7a2c3a524f73b64914e07124832e053 Author: Mihai Varga Date: Wed Jul 23 11:57:40 2014 +0300 OneDrive wrong property id commit f0a7a062a09a65b51744afa77c3d19a29a792300 Author: Mihai Varga Date: Tue Jul 22 20:37:40 2014 +0300 OneDrive document indentation fix commit 2effd724ee5631ea9165772e2a215b374c048547 Author: Mihai Varga Date: Tue Jul 22 20:26:16 2014 +0300 OneDrive - no more need for uploadStream commit 1b4de7655f115490deb94f5b908dcdaac3d0006e Author: Mihai Varga Date: Tue Jul 22 20:25:40 2014 +0300 OneDrive createDocument test updated commit a2145adc0d8f7b67b045734169236af8cb46a79f Author: Mihai Varga Date: Tue Jul 22 20:21:48 2014 +0300 OneDrive - upload the stream when creating a document, we spare 1 Put request this way commit c62278b027c23810d8ff28b629ea04b273256822 Author: Mihai Varga Date: Tue Jul 22 20:04:22 2014 +0300 OneDrive - createDocument - sometimes the fileName is not provided, so it must be extracted from the properties commit cdf377a84ea8042df8330b2a48455d2801865cbe Author: Mihai Varga Date: Tue Jul 22 19:04:04 2014 +0300 OneDrive - refresh parent folder after creating a new one commit 3eb07de88a306bfeedd015c7b3f6a0aff69e8e77 Author: Mihai Varga Date: Tue Jul 22 19:03:09 2014 +0300 OneDrive - export more properties commit d13fbfd0c5bce269ec76aaaeb97316c1106c1cca Author: Mihai Varga Date: Tue Jul 22 17:34:51 2014 +0300 SharePoint checkOut test commit fdbd30744bc380d98f4e22a257889cc9f7066e10 Author: Mihai Varga Date: Tue Jul 22 17:34:11 2014 +0300 SharePoint cancelCheckOut method commit cfc695475d4a407cfca6833a3151da3f92844d5b Author: Mihai Varga Date: Tue Jul 22 16:51:40 2014 +0300 SharePoint checkOut method commit b4b2229a9ea0de0215f42d218734ef65da44347b Author: Mihai Varga Date: Tue Jul 22 14:33:34 2014 +0300 SharePoint - indentation fix commit 2749018ee3fc9ddd8e4447fa56295ca3d619d71f Author: Mihai Varga Date: Mon Jul 21 19:04:34 2014 +0300 OneDrive - percent encode the fileName commit 03116f28b58f47c3d11b943b8b88f7f9ccc541d8 Author: Mihai Varga Date: Mon Jul 21 18:48:57 2014 +0300 Fixed the bad indentation commit 98bf7f1135daaf00673a84c3cec95bc75d248fe6 Author: Mihai Varga Date: Mon Jul 21 18:42:04 2014 +0300 OneDrive - updated tests for the new uploadStream url commit bcd422ffcb31086110e6d879124feb0a104e4153 Author: Mihai Varga Date: Mon Jul 21 18:41:23 2014 +0300 OneDrive uploadStream - updated the url commit 93c46bf8a62e538d982bde3dd5d6c7030c4010b2 Author: Mihai Varga Date: Mon Jul 21 15:34:44 2014 +0300 OneDrive object type commit 2be235f69d4cc8cd39656dd4c14b5e9dcefe13a9 Author: Mihai Varga Date: Fri Jul 18 15:15:44 2014 +0300 OneDrive, root folder is named SkyDrive commit 8f362d1f445b866fc40db61a4f7286988bab569b Author: Mihai Varga Date: Fri Jul 18 13:25:58 2014 +0300 OneDrive - getObjectByPath test commit 05f9d0dc9f53e471b4fda87c8f65aa7ff972dcc0 Author: Mihai Varga Date: Fri Jul 18 13:24:47 2014 +0300 OneDrive json responses for getObjectByPath test commit 9a8d7fb8282b6bce1a8afb2bb06fee76bb5e2700 Author: Mihai Varga Date: Fri Jul 18 13:22:05 2014 +0300 OneDrive - getObjectByPath method commit 94733e4e0705c71df7cba8802788c88dbc75a1dc Author: Cédric Bosdonnat Date: Thu Jul 17 13:41:59 2014 +0200 CURLAUTH_* are unsigned long commit f41529b6e04d84ed8ad7b69ee45b7a87fb8682bc Author: Cédric Bosdonnat Date: Thu Jul 17 13:33:40 2014 +0200 libcmis::escape and libcmis::unescape tests commit 36a9ce62eafaf6fc045b0e8900ca956f294a690a Author: Mihai Varga Date: Thu Jul 17 11:18:12 2014 +0300 Objects have a 'ServerRelativeUrl' property so there is no need for this method commit bda78e9c88c235352591acead95ef90eff4e1de2 Author: Mihai Varga Date: Wed Jul 16 18:50:44 2014 +0300 SharePoint setContentStream test commit 93e20752589b50bf45cb8365cc17207d7563d700 Author: Mihai Varga Date: Wed Jul 16 18:47:15 2014 +0300 SharePoint setContentStream method - and there is no need for the uploadStream method commit d734a9894837f1cdb98327c151754a82f57e31cc Author: Mihai Varga Date: Wed Jul 16 15:11:22 2014 +0300 SharePoint getContentStream test commit 5c9371125dba06958c64a71432c3c5a4a7fdf8eb Author: Mihai Varga Date: Wed Jul 16 15:01:49 2014 +0300 SharePoint getDocument test commit 9c79f7192cfaa9359a1cf85174531c7916dcf8c8 Author: Mihai Varga Date: Wed Jul 16 15:01:06 2014 +0300 SharePoint documents are handled commit c08c4aadac4b9f69ef33ab4485146895855ae29b Author: Mihai Varga Date: Wed Jul 16 14:59:52 2014 +0300 SharePoint document class commit 66276f48d6c58eb5e63ac642f37999eb2b041434 Author: Mihai Varga Date: Wed Jul 16 14:51:29 2014 +0300 Misspelled Time commit 863741c5fc96ee42892e134f21e1b3d4f5bb0521 Author: Mihai Varga Date: Wed Jul 16 12:20:25 2014 +0300 SharePoint allowable actions tests commit 0a89dc15b449a3093dfa9d19499345584888aed8 Author: Mihai Varga Date: Wed Jul 16 12:19:19 2014 +0300 SharePoint folder json response commit 9761fd79ca49d1c865f7fe61aab3bf41c745e9fd Author: Mihai Varga Date: Wed Jul 16 12:18:10 2014 +0300 SharePoint allowable actions commit abe777a2ef0097f9c7563f90b8deff6c799084c4 Author: Mihai Varga Date: Tue Jul 15 13:08:00 2014 +0300 SharePoint utils - getPath() method, it gets the server relative path to an object commit 5aad2736666be3b72d9a406806a6a3059c851a3c Author: Mihai Varga Date: Tue Jul 15 13:04:22 2014 +0300 ignoring sharepoint test exe commit f4a2031a9b2f023d4458fd789bf6a2445436b1f8 Author: Mihai Varga Date: Tue Jul 15 13:02:37 2014 +0300 SharePoint - removed unnecessary variable from tests commit 73d1350468702e70891dc2e378af5279e26663fb Author: Mihai Varga Date: Tue Jul 15 12:58:28 2014 +0300 SharePoint expired xdigetst code test commit fbb5f11a4e45b52a6959b1f250a454652cefaf05 Author: Mihai Varga Date: Tue Jul 15 12:57:38 2014 +0300 Refreshed xdigest code commit 0fc3e67c724585049749b4ede0183a9ebb80bb5a Author: Mihai Varga Date: Tue Jul 15 12:18:58 2014 +0300 SharePoint - updated the tests to handle the xdigest code acquiring request commit 19e4ecdfdd046f43ffff2a09f76d25613643bf22 Author: Mihai Varga Date: Tue Jul 15 12:17:25 2014 +0300 SharePoint xdigest code response commit 9dac35c2d8170be5e75278bf847ad956173c5614 Author: Mihai Varga Date: Tue Jul 15 12:14:09 2014 +0300 SharePoint method to get the xdigest code for the xrequestdigetst header and http(Post/Delete/Put) mehtods are overriden to handle the expired code commit bd66328ca15f7d73d643ce915a7cae282f26b53d Author: Mihai Varga Date: Mon Jul 14 16:12:19 2014 +0300 SharePoint delete test commit 26c986bd3ed3f712af054da02ee390c82bd70ab8 Author: Mihai Varga Date: Fri Jul 11 19:19:17 2014 +0300 m_curlHandle from parent class is now used commit 430f6d9ad02d1b959d34715793f4f5b5f3bf2be0 Author: Mihai Varga Date: Fri Jul 11 19:17:54 2014 +0300 Made httpRunRequest virtual so it can be overwritten and made m_curlHandle protected so it can be used by the overwriting method commit 3239e708ec3d2059682912038fd93bead6d4949a Author: Mihai Varga Date: Fri Jul 11 12:11:41 2014 +0300 Reuse a property variable instead of creating another one commit d5bc194fcc486276c0c7ba4f3161c6c5a1c135c4 Author: Mihai Varga Date: Fri Jul 11 12:03:49 2014 +0300 There is no parentId provided in the response (for files), so it must be set by the folder that lists its children commit b6986a896e84dd31e9d86455529c6587e7a86fc3 Author: Mihai Varga Date: Fri Jul 11 10:41:23 2014 +0300 The ID provided in responses is actualy the uri to the object, so the ID is no longer splitted by the binding url commit d7a37987dceecefe965a7a4f372bec98d093145a Author: Mihai Varga Date: Thu Jul 10 15:58:39 2014 +0300 SharePoint default authentication succeeding test commit e4befddd3689eecad05b99c6c07692aa478ba3c1 Author: Mihai Varga Date: Thu Jul 10 15:57:12 2014 +0300 SharePoint xml response to a request to the binding url commit 9463ffc8b23b05ff14dfce06930339e53611defa Author: Mihai Varga Date: Thu Jul 10 15:56:15 2014 +0300 SessionFactory - second SharePoint session catcher used when default auth succeeds commit adbea743c144c88ae975f629c2ffc6746cfb9084 Author: Mihai Varga Date: Thu Jul 10 15:15:24 2014 +0300 Exception was thrown in a wrong way commit b7968a2199f5c2f64cd4729c77dbdf631467f907 Author: Mihai Varga Date: Thu Jul 10 14:37:43 2014 +0300 SharePoint new constructor based that takes an HttpSession as a parameter commit 96dcb098c2d16d03af3951b3f445e61b26b10011 Author: Mihai Varga Date: Wed Jul 9 19:12:26 2014 +0300 SharePointSession - httpSession::httpRunRequest method overwritten commit fccee9cb8405d098cf2b6115f98ee30ec5596dd4 Author: Mihai Varga Date: Wed Jul 9 18:51:21 2014 +0300 Made HttpSession::httpRunRequest protected so it can be overwritten, as the SharePoint binding requires a header specifing that the response should be JSON, so a custom header had to be added to all requests commit 461e4ec692b1f3f92388e6246cae23f08db319bf Author: Mihai Varga Date: Wed Jul 9 18:48:17 2014 +0300 HttpSession - setAuthMethod instead of setNTLMAuth commit 62f6036d417638ecf4d9a6439f8d0963e27fa0a5 Author: Mihai Varga Date: Wed Jul 9 14:03:43 2014 +0300 SharePoint getObject & properties tests commit 3fa689fee422caf468a8b8a1b58505fd3ed64e0e Author: Mihai Varga Date: Wed Jul 9 14:02:36 2014 +0300 SharePoint getRepositories test commit 9c25abebe2302c7976ce209f0a9fc0b1fa7c8b7f Author: Mihai Varga Date: Wed Jul 9 14:01:22 2014 +0300 SharePoint mock json responses commit 1050b87cfa76687eba216b67a5ee1c2039fb3adb Author: Mihai Varga Date: Wed Jul 9 13:59:47 2014 +0300 SharePoint getObject handler commit 0dd24acf776170ec034eea9c52d57cabd51a2356 Author: Mihai Varga Date: Wed Jul 9 13:58:09 2014 +0300 SharePoint object class commit ee7fc9f36a4d064d7a573062f2b238b390c3621a Author: Mihai Varga Date: Wed Jul 9 13:55:38 2014 +0300 SharePoint property class commit 5b7894e08e4237a4fd4d8bdec750a70dcfa7d211 Author: Mihai Varga Date: Wed Jul 9 13:53:18 2014 +0300 SharePoint utils commit 306521080cf62d8a4d9f40ec3fffdf3b12961414 Author: Mihai Varga Date: Mon Jul 7 15:25:18 2014 +0300 SharePoint session creation test commit ecc84169d3ddeae9560eb3a2268e4511d393ebbc Author: Mihai Varga Date: Mon Jul 7 15:24:14 2014 +0300 SharePoint factory test JSON response commit fad92db6486d2ccc8868bb0a94dae637c9ed42fb Author: Mihai Varga Date: Mon Jul 7 15:18:36 2014 +0300 SharePoint session creation handler commit ed9880d712ad6dacc117b637c31244038190ebd2 Author: Mihai Varga Date: Mon Jul 7 15:16:46 2014 +0300 SharePoint session class commit 31777feb4580e21bfe0713375f222fcc3584dac9 Author: Mihai Varga Date: Mon Jul 7 15:13:59 2014 +0300 NTLM authentication for SharePoint commit 54b7278b109ad5731ce84390b20b3e0b29416fc2 Author: Mihai Varga Date: Mon Jul 7 15:10:19 2014 +0300 SharePoint dummy repository commit b05508b6e9d54cb0dfdb9a9a3f745a63aee6bea8 Author: Fridrich Štrba Date: Tue Jul 1 17:17:03 2014 +0200 Remove C++11 only std::to_string commit aade7c5c1cfdf3843d26bbd217e85ff0a8851d99 Author: Mihai Varga Date: Mon Jun 23 19:02:45 2014 +0300 Removed a useless http reqest for the OneDrive authentication commit 96a353c132c41b1ede4e6a233c3e7d7062025646 Author: Mihai Varga Date: Thu Jun 19 19:37:12 2014 +0300 Merged Cedric Bosdonnat's patch from LO, original message: Object creation mixed relationship properties with document properties Added a Unit test to show the problem. We surely don't want the relationship cmis:properties to be read as properties. This bug caused some problems with other operations like checkout. commit d334f9510e23ac50f8e599f40c16417624c61778 Author: Mihai Varga Date: Tue Jun 17 18:50:47 2014 +0300 OneDrive createDocument test commit 652817651902e13654ea5dd6d9fe6f234db76763 Author: Mihai Varga Date: Tue Jun 17 18:50:00 2014 +0300 OneDrive createDocument method commit c714511f7f64141885f48ffb64b9f1b38f16af51 Author: Cédric Bosdonnat Date: Tue Jun 17 14:45:39 2014 +0200 OneDrive: don't blindly create an object: use the helper function Blindly creating a OneDriveObject directly in updateProperties will lead to troubles when we'll need it to act as a Document (or Folder) depending on the kind of node we have. Using the getObjectFromJson helper, fixes the problem by creating the proper object. commit 1534f23357dba9f8f066ad29a6bbdd2fd5f31a15 Author: Cédric Bosdonnat Date: Tue Jun 17 14:30:40 2014 +0200 Log the missing data files for failing unit tests commit afba3c09424069bc4287e84e3564888cab1ec8f6 Author: Mihai Varga Date: Tue Jun 17 15:39:44 2014 +0300 OneDrive createDocument test - not working yet commit 3fe85822e5bb849e2513d08bae8054a44d266890 Author: Mihai Varga Date: Tue Jun 17 15:28:47 2014 +0300 Forgot to add this one commit eb1aa0dfe1134ee56f9b70b6bceb3b2f3ec31a67 Author: Mihai Varga Date: Mon Jun 16 18:05:07 2014 +0300 OneDrive setContentStreamTest commit ba25481e439bd7829e18b681827595d25efdf304 Author: Mihai Varga Date: Mon Jun 16 18:04:22 2014 +0300 OneDrive getContentStreamTest commit 3950a7c41c580f685b068b8bb6953be68bfe787a Author: Mihai Varga Date: Mon Jun 16 18:03:21 2014 +0300 OneDrive getDocumentParentTest commit 2476175d34f2ad6fe9cb2a88fe3d1ef8386409a9 Author: Mihai Varga Date: Mon Jun 16 18:00:40 2014 +0300 OneDrive getDocumentTet commit 33f09535473b3d4f15e37b8b0c4e5a67087aa8b5 Author: Mihai Varga Date: Mon Jun 16 17:56:48 2014 +0300 OneDrive document object can be created commit fcac389d85c781491a22f7f8fb352e7df5bc1365 Author: Mihai Varga Date: Mon Jun 16 17:54:46 2014 +0300 OneDrive Document class commit 3d161edd609168164c5c1c8af9c2fad635ac3c72 Author: Mihai Varga Date: Mon Jun 16 16:12:00 2014 +0300 No need for this commit 333224639dcc2ada4445b1d617bce65d61d56778 Author: Mihai Varga Date: Mon Jun 16 15:35:03 2014 +0300 OneDrive move test commit 25f59ae5e926fbc0cbd01e55773f38531e0146dc Author: Mihai Varga Date: Mon Jun 16 15:34:01 2014 +0300 OndDrive move method commit 31ce6084e055d6ad9777971ce774ef7d41193ea1 Author: Mihai Varga Date: Sat Jun 14 16:33:21 2014 +0300 OneDrive getObjectFromJson function commit 6ad98c0861f045be929f3aa4be0fa5fd730b2bf1 Author: Mihai Varga Date: Wed Jun 11 11:29:55 2014 +0300 OneDrive getFolder & getChildren tests commit b2f3866f59e942641590f90b7be0528dddbe6e20 Author: Mihai Varga Date: Wed Jun 11 11:23:41 2014 +0300 OneDrive session can return folder objects commit e1f59973a73589fc8fc36899405c9e01d111e135 Author: Mihai Varga Date: Wed Jun 11 11:18:37 2014 +0300 OneDrive folder class commit 6429151ef18bbdbcbdb4115affed1e4c33b5b63b Author: Mihai Varga Date: Tue Jun 10 22:33:46 2014 +0300 Updated the test files commit 8e22fcfb8694d8581575e839ad9fa941cc54dea9 Author: Mihai Varga Date: Tue Jun 10 22:21:48 2014 +0300 Removed folderPropTest, as the props will be tested in the getFolderTest() commit b5f8fef0146bb4ffa1658b9abf8f4af4477aaee6 Author: Mihai Varga Date: Thu Jun 5 14:58:23 2014 +0300 OneDrive - filename maped to both cmis:contentStreamFileName and cmis:name commit 4ff1a79fdb88f21990dda7dbc37851e195d80948 Author: Mihai Varga Date: Thu Jun 5 13:33:45 2014 +0300 OneDrive allowable actions test commit f9e62e2c00b88756c54544fef7e93d77880bc81e Author: Mihai Varga Date: Thu Jun 5 13:29:27 2014 +0300 OneDrive allowable actions commit 25806ca4f0c20dcd21256b25f6e6a260cf2eba8e Author: Mihai Varga Date: Tue Jun 3 11:55:05 2014 +0300 Ignore onedrive test exe commit ee562929324da1858041a99ac1e46d30bb948b24 Author: Mihai Varga Date: Tue Jun 3 11:47:44 2014 +0300 OneDrive updateProperties test commit a978c079c9bf99c4af11d034049c5a72365ff74d Author: Mihai Varga Date: Tue Jun 3 11:45:36 2014 +0300 OneDrive properties update method commit 42ed96535435cf0df6c305a13583024ad8168181 Author: Mihai Varga Date: Tue Jun 3 11:41:45 2014 +0300 cmis to OneDrive json converter commit 53fb01b89d6e1777d61584c8da5bd2788392af71 Author: Mihai Varga Date: Tue Jun 3 11:37:24 2014 +0300 OneDrive object delete test commit 08dad2c70f1f042bc8ae64a75471fe74394f397a Author: Mihai Varga Date: Sat May 31 20:32:41 2014 +0300 Onedrive object test commit 1c9293d391e7d0b3698531b140732e3f20fc95a1 Author: Mihai Varga Date: Sat May 31 20:13:06 2014 +0300 Onedrive file test with mock libcurl commit e209c5c9dab7f2f80bfa239aadae0c1d600c7ee2 Author: Mihai Varga Date: Sat May 31 20:11:14 2014 +0300 Onedrive object class commit 4b3f9d1174a5da9d9c487d5b6045d7126613b44c Author: Mihai Varga Date: Thu May 29 22:01:22 2014 +0300 Found updatable properties in another documentation commit d99167eb4cdbc41b909cb9e2d6581f741f353562 Author: Mihai Varga Date: Wed May 28 21:04:11 2014 +0300 Oops, used wrong coding style commit 4c7ab7f5b9de0cc7d9cc3d5b131f32ee572b321a Author: Mihai Varga Date: Wed May 28 20:59:22 2014 +0300 Listed folder properties test commit e409766d2bab21ca3b2a794549c1311017834f4f Author: Mihai Varga Date: Wed May 28 20:57:58 2014 +0300 One more update to mock responses commit d11970d410b195667a2c34dcdc745295f94b1e8e Author: Mihai Varga Date: Wed May 28 20:46:49 2014 +0300 Changed mock id commit d9a345c744fdb60fbda7547ea3f85248757bb0d4 Author: Mihai Varga Date: Wed May 28 20:16:37 2014 +0300 File property test commit 242d0a037513e73776555eb58ddeb72c582772b5 Author: Mihai Varga Date: Wed May 28 20:14:13 2014 +0300 Mock json responses for a file and a folder commit a092bc30e6d0e0e4fade2f1636f35f649aaaa64c Author: Mihai Varga Date: Wed May 28 20:12:23 2014 +0300 Makefile update for properties commit 356f98d8551a49075a7c2709a1dc5380d0fd8b7c Author: Mihai Varga Date: Tue May 27 11:46:31 2014 +0300 OneDrive object properties commit 06a33ee08db14917279cde0d7074d35ff9858f76 Author: Mihai Varga Date: Mon May 26 19:35:55 2014 +0300 One drive utils for properties parsing commit 040707d76319822736bbec529bf73901135038bb Author: Mihai Varga Date: Mon May 26 19:32:12 2014 +0300 Removed comment and unused if statement commit 48d04c7c0354523048266f3c6af41f3580ad1330 Author: Mihai Varga Date: Thu May 22 11:23:52 2014 +0300 getRepositories test commit 5091e718afcef35ef102361ed4be59a700335448 Author: Mihai Varga Date: Thu May 22 11:20:00 2014 +0300 Removed tests that don't pass commit 11187959e07bdb7b7b185d6494969187902f815a Author: Mihai Varga Date: Thu May 22 10:34:52 2014 +0300 One drive repository commit 02e8e50ed363beb3a50bbe81e645258ec4595f6c Author: Mihai Varga Date: Thu May 22 10:26:51 2014 +0300 License statement commit 8610ba385707be5130451ee14d8ef58c033dbc46 Author: Mihai Varga Date: Tue May 20 15:36:25 2014 +0300 Removed a misplaced whitespace commit 47daf99b21c10d0d00a1b00578ed1b4fdf500adf Author: Mihai Varga Date: Tue May 20 15:28:08 2014 +0300 ondrive tests are also run commit 6a343cf997c3a48c837bd6a5f43db431c46744f4 Author: Mihai Varga Date: Tue May 20 15:25:32 2014 +0300 test unit files for onedrive commit 27959d24b433703efb9455839bd9bd9812d883eb Author: Mihai Varga Date: Tue May 20 11:33:40 2014 +0300 unused varaible error commit eb946ee31bc0423f589a39e99cc0abbb0300de0b Author: Mihai Varga Date: Tue May 20 10:57:29 2014 +0300 removed trailing blank lines and unused code commit 9348429fcfb0564bb453e109cfa9a9827b239f54 Author: Mihai Varga Date: Mon May 19 13:21:34 2014 +0300 One drive session - basics commit b359c6e55dcf3e7eb2dec28a40af4157afb7d4bb Author: Cédric Bosdonnat Date: Tue Feb 11 12:43:48 2014 +0100 Fix OAuth2 refresh after refactoring commit e85f605e504f054c9a2539209aaba3f0476b0e4d Author: Cédric Bosdonnat Date: Thu Feb 6 10:41:17 2014 +0100 Fixed cppcheck complain about duplicate handle members (cherry picked from commit dbb5d41f7caabe361e721707e0d5661a7e650e60) commit a7227235d69e708e4e49f27da1b7bc03c7412ad7 Author: Adam Conrad Date: Thu Feb 6 09:13:32 2014 +0100 Fix int/bool confusion on big-endian architectures. (cherry picked from commit 433fad370ddd30c43df281b40ff468a842bc1c70) commit 40390e84aba1b0db2c4f653e3a42d6b246beb1c9 Author: Cédric Bosdonnat Date: Mon Nov 18 10:54:47 2013 +0100 Fixed OAuth2 authentication with the recent factory changes commit d5e5b11d31a1c65e63826e55f338b42a4590eb2c Author: Cédric Bosdonnat Date: Wed Nov 13 09:50:30 2013 +0100 Changed XPath expression to include all possible properties Alfresco supports aspects (CMIS 1.1 secondary types) for a long time and they provided them as extensions in their CMIS 1.0 implementation. Changing the XPath query to match all properties based on their propertyDefinitionId allows libcmis to provide those properties stored in the cmis:properties extension part. commit 1bcf74878f1f7c78f9050b51d10500a01bae1396 Author: Cédric Bosdonnat Date: Wed Nov 13 09:28:09 2013 +0100 libcmis-c: new [add|remove]SecondaryType methods commit fe232c1bb2b7d221fab05ce4524bd6c2c28d28d3 Author: Jesús Corrius Date: Wed Nov 6 22:55:27 2013 +0100 typo commit c907b9fb426e7a273bf8972bd11255eef0ebc1ab Author: Cédric Bosdonnat Date: Thu Nov 7 14:58:10 2013 +0100 PropertyType: Added update feature for temporary property types commit 13c47ac1095f4ef2711147b902eee4ee3d475cfe Author: Cédric Bosdonnat Date: Thu Nov 7 13:19:14 2013 +0100 Properties can now be created without a type description. Beware, the underlying type description that is created is now an incomplete one. This needs to be updated before use. The code to update it is not yet provided. commit f178f5dddf71c8bfc5193c23f0896c4eda388001 Author: Cédric Bosdonnat Date: Wed Oct 30 10:43:44 2013 +0000 Added addSecondaryType and removeSecondaryType on Object Only the unit test for addSecondaryType on WS binding is written by now... and failing. To get it working properly, Property needs to be decoupled from PropertyType and at least allow missing PropertyType at parsing time. commit bea5012912528a59193a1f9e9e8227fb932f09ff Author: Cédric Bosdonnat Date: Wed Oct 30 09:45:24 2013 +0000 udpateProperties won't send HTTP request for empty properties commit e8c713b42d0cd1500ae0ee1c22d50db0db296b12 Author: Cédric Bosdonnat Date: Wed Oct 30 08:22:31 2013 +0000 Added shortcut function to get CMIS 1.1 secondary type ids commit 86d19edb4ab491b5cbec6e73cd0d08ed01f50a63 Author: Cédric Bosdonnat Date: Tue Oct 29 20:14:34 2013 -0500 Added Session::getBaseTypes() commit 9d219571bb5d035aff2b5c50f4bd3b9d97a28026 Author: Cédric Bosdonnat Date: Tue Oct 29 17:27:51 2013 -0500 Updated NEWS file commit 3c3e30d338dc58ad76e85ec7c214f3f235d06740 Author: Cédric Bosdonnat Date: Tue Oct 29 17:23:32 2013 -0500 SessionFactory test that we have only one HTTP request on bindings Only implemented the test for CMIS Atom and WS bindings commit faea04f9ad55833513a6177bf80a88f6145bad87 Author: Cédric Bosdonnat Date: Tue Oct 29 17:11:37 2013 -0500 Added unit tests for SessionFactory commit 91f0a45ec6294bbec7a48d5310b6f92c514122f0 Author: Cédric Bosdonnat Date: Tue Oct 29 15:34:00 2013 -0500 Save a few HTTP requests during the session creation SessionFactory now runs the HTTP GET query on the binding URL itself and provides this response to the various bindings it tries in order to save a few HTTP requests. commit da9978451f194b9a694d10ef552089afba84129f Author: Cédric Bosdonnat Date: Tue Oct 29 13:03:09 2013 -0500 Extracted HTTP-related code from BaseSession This refactoring is mandatory to help reduce the number of HTTP requests sent in SessionFactory to decide which binding to use. commit c66051135892de8bec7a1d48e391d52582d2454d Author: Cédric Bosdonnat Date: Mon Oct 28 21:33:24 2013 -0600 No need to stick with serial tests anymore commit 8dc6dd5158bee388de3292e27058df702a5272e1 Author: Cédric Bosdonnat Date: Wed Oct 23 11:25:01 2013 -0600 Files move and test binaries as these turned useless commit 4aed0d13b92df10490c8ee92e719d6bdd06efe06 Author: Cédric Bosdonnat Date: Wed Oct 23 10:56:07 2013 -0600 Updated NEWS file commit 6fb8117f6002757d14ad5c26a536343c6ae75116 Author: Cédric Bosdonnat Date: Wed Oct 23 10:52:09 2013 -0600 Migrated the last WS unit test to mockup: removing the test server Unit tests now don't rely on chemistry inmemory server and are executing much faster and will be easier to maintain. commit 15e80e75ca519ad9bf11e7604d13824ff41d097b Author: Cédric Bosdonnat Date: Wed Oct 23 10:28:53 2013 -0600 Moved checkIn WS test to mockup commit b841ab7dc15662212410135902b4f009f6c13ec0 Author: Cédric Bosdonnat Date: Wed Oct 23 08:18:48 2013 -0600 Moved cancelCheckOut WS test to mockup commit 3d913fced0b04a229341ad67663cfc78d96b7bf3 Author: Cédric Bosdonnat Date: Mon Oct 21 08:28:03 2013 -0600 WSTest::checkOutTest migrated to mockup commit 8c101763a70dba707b888e8dce75bc276cdf80fd Author: Cédric Bosdonnat Date: Mon Oct 21 06:55:12 2013 -0600 WSTest::moveTest migrated to mockup commit 470af30e4a7d0db7a58b0f1b1672a5bfa05eb1a8 Author: Cédric Bosdonnat Date: Mon Oct 21 06:08:58 2013 -0600 Moved setContentStream WS test to mockup commit 04ed2cc1e2019be473e0ae677cb30db39e4472b3 Author: Cédric Bosdonnat Date: Mon Oct 21 06:08:32 2013 -0600 Tell YouCompleteMe to check with c++98 standard, not c++11 commit 87c1ce32552d770c82861295a26fc90bd273dc34 Author: Cédric Bosdonnat Date: Sun Oct 20 19:24:37 2013 -0700 YouCompleteMe config file to get completion and syntax checkin in vim commit 8847145a09ae6418302ba7e9bfc499c941576e12 Author: Cédric Bosdonnat Date: Sun Oct 20 19:23:32 2013 -0700 Moved getContentStream WS test to mockup commit 1066dc5dfc1ba2fb5253bd14bdc97ed7a8326bb0 Author: Cédric Bosdonnat Date: Sun Oct 20 17:17:50 2013 -0700 Moved delete object and tree WS tests to mockup commit 2b55060054df5fd8600e4aaf5414b969d6ff56d9 Author: Cédric Bosdonnat Date: Sun Oct 20 16:44:30 2013 -0700 Moved createDocument WS test to mockup commit 5839ebaab2defdb324783887a1fb5f321dd8d630 Author: Cédric Bosdonnat Date: Sun Oct 20 14:53:28 2013 -0700 Moved createFolderBadType WS test to mockup commit d9eec9d4960227aab97d8032fda681d42fad3d12 Author: Cédric Bosdonnat Date: Sun Oct 20 11:41:33 2013 -0700 Add lcov support To get it working: * ./autogen.sh --enable-coverage --disable-shared * make coverage * Open libcmis-lcov/index.html and check the results commit 427802aaeb03d2b0868efea3aaade475c22b94fd Author: Cédric Bosdonnat Date: Sun Oct 20 06:36:16 2013 -0700 Moved createFolder WS test to mockup commit 80cfa0f58113ac8fbba9438189e21c95c5a52501 Author: Cédric Bosdonnat Date: Sat Oct 19 08:17:47 2013 -0700 moved WS updateProperties test to mockup commit b066956c6e2675fc5eb759829b8025e64b227ff3 Author: Cédric Bosdonnat Date: Sat Oct 19 06:41:55 2013 -0700 Moved getByPathInvalid WS Test to mockup commit 88139b5f804538756728fb2d5625c6f3b9c36ae7 Author: Cédric Bosdonnat Date: Sat Oct 19 06:30:29 2013 -0700 Moved WS getByPathValidTest to mockup commit f1cd9cb8aa33de31ab63183ed5d9e1f3c76ad097 Author: Cédric Bosdonnat Date: Sat Oct 19 06:11:11 2013 -0700 Moved getChildren and getDocumentParents WS test to mockup This needed to improve the mockup to accept matching on a string contained inside the request body. This still may need to be improved later though. commit 0e37d25938b2b28a2423c62245bbaf1d5bcc81ef Author: Cédric Bosdonnat Date: Fri Oct 18 12:53:09 2013 -0700 Add getFolderTest to WS mockup commit 44e6d1db8a0d65ac453c00f50531ab0b167dd76b Author: Cédric Bosdonnat Date: Fri Oct 18 12:42:01 2013 -0700 Moved getDocument WS test to mockup commit 68fb20012f87419cd4c506c4332754be6706a853 Author: Cédric Bosdonnat Date: Fri Oct 18 12:31:58 2013 -0700 Moved getTypeChildren and getObject WS test to mockup commit 9338900272eeeff7773b505dbe700beaa91a00a2 Author: Cédric Bosdonnat Date: Fri Oct 18 08:51:31 2013 -0700 more getType*Test in test-ws-mockup commit bbb4e5ff3314b0062c0672f27421e6b1eff49f7a Author: Cédric Bosdonnat Date: Fri Oct 18 12:16:56 2013 +0100 Moved getTypeDefinitionTest to WS mockup test commit 2ea1b7e5faa0090065d0052e389ee4768a64b62b Author: Cédric Bosdonnat Date: Fri Oct 18 11:36:58 2013 +0200 Moved getRepositoryBad to test-ws-mockup.cxx commit 00a0e61d3741159ce9c1c179bbb668e57ff060be Author: Cédric Bosdonnat Date: Sat Oct 5 14:03:22 2013 +0200 WSTest mockup: test sent requests commit f051f5dd38609e1820fcd9a4f4bdebd14fa312a2 Author: Cédric Bosdonnat Date: Mon Sep 30 22:45:49 2013 +0200 WSTest mockup: added getRepositoryInfo test and fixed response setting commit 8f13dec86bf61ab4cef247e700992de9c01b9536 Author: Cédric Bosdonnat Date: Mon Sep 30 21:45:43 2013 +0200 WSTest mockup: actually test getRepositories without other requests commit c124cf16db68ae96da6509351eb4434723c69164 Author: Cédric Bosdonnat Date: Mon Sep 30 20:19:22 2013 +0200 WSTest: improve session creation to avoid any HTTP request commit 28c138c5d600f64e3b121ebabee35f180bc16e5e Author: Cao Cuong Ngo Date: Wed Sep 25 10:59:59 2013 +0200 Check is the path of the parent is empty In some ID-based protocol like Google Drive the return path may be empty, it causes crash if we don't check. commit c6b073ba08766fe7ba7d46a4c5cb002114cc1f07 Author: Cédric Bosdonnat Date: Mon Sep 23 22:56:48 2013 +0200 WSSession mockup unit test conversion. Started the conversion with a simple test case: getRepositoriesTest. commit c04b29ee80ac4886f1b87773eff32cc7fe7a000e Author: Cédric Bosdonnat Date: Mon Sep 23 22:54:01 2013 +0200 Allow related multiparts to contain unix line ends. This will allow to store multiparts responses for WSSession mockup testing in the git repository without trouble... and who knows, there may be a server out there not following the RFC. commit 26fb993f1f3e6b47fb75b6601d5110432c746924 Author: Cédric Bosdonnat Date: Wed Aug 7 16:11:34 2013 +0200 Bumped version number commit 3feda09e69d8a11af673308c33c6534c26ce550f Author: Cédric Bosdonnat Date: Wed Aug 7 16:09:05 2013 +0200 Don't install libcmis-mockup: it's only for testing (cherry picked from commit c09ab20c046049d5a8ae0c812c97e3d653ecd6ce) commit 8404d031bb238c12b9770e63618149b11296584e Author: Cao Cuong Ngo Date: Thu Aug 8 14:54:20 2013 +0200 Json util: check for empty string. libboost version in LO throw exception here. commit 7f0150914bacc0ff3e92c7bfa5a9b6918d1c3431 Author: Cédric Bosdonnat Date: Wed Aug 7 14:03:09 2013 +0200 makefile.mk no longer needed for LibreOffice builds (cherry picked from commit 66a387cc62f3ed6f328d37bf739120fd9bfd64e1) commit 409a319e0188de90c6d5fae6c3ce2fe328ebca91 Author: Cédric Bosdonnat Date: Tue Aug 6 19:03:48 2013 +0200 Fixed typo commit c7ff67a093519c16a177ff1d529794ae39e762c3 Author: Cédric Bosdonnat Date: Tue Aug 6 16:20:46 2013 +0200 Unit test for invalid SSL certificate handling commit 2691e6026dd9ba8c13fbed3df6805c34d764d7d9 Author: Cédric Bosdonnat Date: Tue Aug 6 15:42:07 2013 +0200 cmis-client: cache the SSL certificate validation answers commit 5bc05fe6a4124cc3459fb977850d0aca93ea253f Author: Cao Cuong Ngo Date: Tue Aug 6 17:00:32 2013 +0200 add gdrive-repository.cxx commit 2bc26640fe44940ec3eb760577c3866fc6d1ded8 Author: Cao Cuong Ngo Date: Tue Aug 6 13:59:21 2013 +0200 Add GDrive repository capabilities commit 193e53dff45016345b187c650ec77d9b4431c982 Author: Cédric Bosdonnat Date: Tue Aug 6 12:37:29 2013 +0200 Updated NEWS file commit d77e524aeafffbf03a31ed851795c1a620234733 Author: Cédric Bosdonnat Date: Tue Aug 6 12:32:36 2013 +0200 WSObject don't ask renditions to the server if it doesn't handle the feature commit 34e02faca4d38fd6d98ca88efa887c71d0d870b5 Author: Cédric Bosdonnat Date: Tue Aug 6 12:25:49 2013 +0200 Added libcmis-c part for the repository capabilities commit c3804f754abd8662f4840386b77904db83ee1af3 Author: Cédric Bosdonnat Date: Tue Aug 6 11:48:59 2013 +0200 Repository: provide access to capabilities Added cmis-client repo-infos command. commit e82faf704c6c8912db2bee62dcca552ad9dec359 Author: Cao Cuong Ngo Date: Tue Aug 6 11:03:50 2013 +0200 GDrive: make object type versionalle, creatable. commit 2b1b91a4a0d61305320fd1a09d10658a3900b794 Author: Cédric Bosdonnat Date: Mon Aug 5 18:08:34 2013 +0200 Added implementation for CMIS renditions in both Atom and WS bindings commit 557229b4c2ecde0656c3b06dbbba458ececd79ff Author: Cédric Bosdonnat Date: Mon Aug 5 10:46:51 2013 +0200 NEWS file: mention the unit test changes commit ee186f6e3ce0bf5c2defe0f8b022df287c125b13 Author: Cédric Bosdonnat Date: Mon Aug 5 10:44:46 2013 +0200 Updated NEWS file commit 5b91cf762047996e484bfecd05b1fe0805fac64c Author: Cédric Bosdonnat Date: Mon Aug 5 10:42:00 2013 +0200 Added Cuong to AUTHORS file commit 7747ef55f70965b2d509154491079b4ad3c04732 Author: Cédric Bosdonnat Date: Mon Aug 5 10:40:14 2013 +0200 libcmis-c: don't use internal type names in the API commit 0deb3957036fb91fe16b557bab94bd278735a556 Author: Cédric Bosdonnat Date: Fri Aug 2 16:31:35 2013 +0200 Added missing libcmis-c bits to cover new things from libcmis commit b494d2c5c9210d6c9407ffa5c4f0cf212c5ec9a0 Author: Cédric Bosdonnat Date: Thu Jul 25 14:10:44 2013 +0200 Give the complete certificate with PEM header/footer lines commit d9bdbb654d68f54ddcb2032997fffacc4a841ef6 Author: Cédric Bosdonnat Date: Thu Jul 25 13:52:01 2013 +0200 Added a static handler to have user validate SSL certificates. commit 6b73428786a9734b3313103500904aae8e3f2dfe Author: Cédric Bosdonnat Date: Thu Jul 25 11:44:39 2013 +0200 Remove the certificate's header/footer to only provide the Base64 part commit 9d1da17b6cce4074eb0e684281bfc52f422d8bc9 Author: Cédric Bosdonnat Date: Wed Jul 24 15:04:15 2013 +0200 Fixed cppunit errors in json-utils and gdrive some classes commit e253fbd7fdf3f540546be71246e5911902dcf790 Author: Cédric Bosdonnat Date: Wed Jul 24 13:49:48 2013 +0200 We need to show the whole chain of certificate for client to verify it commit 35e9ffd17479a1433a533b7ff6c4813e125467e3 Author: Cédric Bosdonnat Date: Thu Jul 11 17:05:41 2013 +0200 cmis-client: show the bad certificate if any commit 5589a8fdaca88aea441e90d43a5c10eaf77c311b Author: Cao Cuong Ngo Date: Fri Jul 19 23:00:11 2013 +0200 GDrive revisions: populate revision name, created date and created user commit 125bea9c59972a376bcaa0b8613fb0fd2bc316de Author: Cao Cuong Ngo Date: Thu Jul 18 19:49:18 2013 +0200 typo fix commit fdc99a0c1068b81c898f5e7c24dccf03c23ee6a5 Author: Cao Cuong Ngo Date: Thu Jul 18 19:46:50 2013 +0200 GDrive: revisions ID Revisions of GDrive has a different ID than the original file. Changed it to the original file to avoid confusion. commit b8075edcf1f4b75b9db41ee16cba986052598d55 Author: Cao Cuong Ngo Date: Thu Jul 18 14:14:42 2013 +0200 GDrive: set property MultiValued commit 257e53a291eb2a0e8d4a6231b45bc870ead4c9a9 Author: Cao Cuong Ngo Date: Thu Jul 18 10:29:47 2013 +0200 GDrive: better properties presentation commit 0be7eb2144c35dca2ea2ea7634f8cf7d1a85eef6 Author: Cao Cuong Ngo Date: Wed Jul 17 18:42:59 2013 +0200 GDrive set content stream Only upload filename when it's modified commit 3a5f9e5f39ab717cd6a3860271ff8aefc4c9cd39 Author: Cao Cuong Ngo Date: Wed Jul 17 09:23:04 2013 +0200 GDrive repository: a better name commit 574834017bc81c1553766b6bab1194ff658b6597 Author: Cao Cuong Ngo Date: Wed Jul 17 09:22:05 2013 +0200 GDrive: create repositories even if we are not authenticated commit 7a2e9221ad3074483c1b17adc6e27f092012f714 Author: Cao Cuong Ngo Date: Tue Jul 16 20:01:21 2013 +0200 GDrive: root folder name mapping commit 66064aff9205e7476f97ec52446aca3fdf374c51 Author: Cao Cuong Ngo Date: Tue Jul 16 14:41:39 2013 +0200 GDrive to CMIS property values mapping commit 59e05698ace71684a7adb4ed961538935bb0d766 Author: Cao Cuong Ngo Date: Tue Jul 16 14:29:43 2013 +0200 GDrive: root doesn't have a parent commit f2a770627ab76b955f95920a4be5f370b6bf1228 Author: Cao Cuong Ngo Date: Tue Jul 16 12:26:23 2013 +0200 JSON parser: switch to libboost commit afab987c67ec7393b7bcc0acb1543b8906601755 Author: Cédric Bosdonnat Date: Mon Jul 15 11:18:21 2013 +0200 Added noSslCheck parameter to createSession and cmis-client commit c9258990fadebf83e99e029a601a5a42b1c0d81c Author: Cao Cuong Ngo Date: Mon Jul 15 10:55:18 2013 +0200 GDrive get object by path Uses path as ID since Google Drive doesn't support get object by path. commit fc25cd22e77b6eb995104190219ef34a7f0740cb Author: Cédric Bosdonnat Date: Fri Jul 12 17:20:26 2013 +0200 Allow to disable SSL verification for a session commit 07b08ec5eabd16ab3015cae7ca722be4851585eb Author: Cao Cuong Ngo Date: Fri Jul 12 11:14:37 2013 +0200 configure: change docbook2x to docbook2x-man commit 5cbd3d65603a862fa9e4c8dde801afb2fb64bff5 Author: Cédric Bosdonnat Date: Fri Jul 12 10:53:39 2013 +0200 In some distros docbook-to-man only handles SGML, prefer docbook2x commit 693b05a9f4520c3f13378507afbc2ee62d259a52 Author: Cédric Bosdonnat Date: Thu Jul 11 16:38:35 2013 +0200 added libcmis-c/libcmis-c.h main header commit e0f3923d36a3b03729a707da803c6b2ee6b3c092 Author: Cédric Bosdonnat Date: Thu Jul 11 16:18:58 2013 +0200 Added a central header libcmis/libcmis.hxx commit b4b61112ac9a93e4712a282ca94a429db4a4d6c6 Author: Cédric Bosdonnat Date: Thu Jul 11 16:18:13 2013 +0200 Added missing libcmis-c.pc.in to extra dist commit 96b9e07cf527b3de521f0b7c3bdb0e88d451b476 Author: Cédric Bosdonnat Date: Thu Jul 11 16:17:00 2013 +0200 Removed json-utils.hxx from some public header commit 825b12d02c5e3116fb176026bc14a5548dbe5c68 Author: Cédric Bosdonnat Date: Thu Jul 11 16:16:02 2013 +0200 Fixed opencmis webapps tarball download URL (long tests) commit 2db9dbb36527cbdaeac0b8be313005c307ac442d Author: Cédric Bosdonnat Date: Wed Jul 10 17:58:37 2013 +0200 Bubble up the SSL certificate errors Get the failing SSL certificate and make it visible from the API. Note that this depends on libcurl to be built with openssl support. commit 57fcf5b076d2c5a4117191c3acbb1702e54db6ca Author: Cédric Bosdonnat Date: Wed Jul 10 11:09:23 2013 +0200 renamed test-mock-atom.cxx into test-atom.cxx commit 6c513ea816bfef6ccc807b2c24bf20dc0038d7af Author: Cédric Bosdonnat Date: Wed Jul 10 10:09:14 2013 +0200 automake now has parallel-tests as default, force serial-tests The long tests needing the run-test.sh can't be run with the test-driver in parallel: turning that feature back to serial to avoid problems. commit 270542cc7e2277f30b570043b1d7734b93d48f61 Author: Cédric Bosdonnat Date: Wed Jul 10 10:01:31 2013 +0200 Moved the last atom unit test to mockup tests commit 763308a8ac3ebdbaddea8548dd933c7bb7861574 Author: Cédric Bosdonnat Date: Thu Jun 13 14:58:10 2013 +0200 Moved AtomTest::getAllVersionTest to mockup tests commit fbb4d46c065a2018da970a35a1d04138e1663f90 Author: Cao Cuong Ngo Date: Tue Jun 18 12:12:03 2013 +0200 Gdrive property: keep the GDrive display name commit e6d340e70a50797326195219b155ebfe83fa543d Author: Cédric Bosdonnat Date: Thu Jun 13 11:46:18 2013 +0200 Make cmis-client remember the asked username/password commit 262f1372c2ff1cdaae69d11f51df5772b5782eb0 Author: Cédric Bosdonnat Date: Thu Jun 13 10:12:06 2013 +0200 Fixed related multipart import: there may be spaces in the content type commit 1436b7b824a185e6b768688a3395d0120af84a65 Author: Cédric Bosdonnat Date: Tue Jun 11 10:13:38 2013 +0200 some newer versions of cppcheck bring loads of false positives with unusedFunctions commit 90eef104c8b601dc57df51dedc1c30b3d31ca8e5 Author: Cédric Bosdonnat Date: Tue Jun 11 09:44:06 2013 +0200 Fixed cppcheck test missing sources in make distcheck commit 5e90af9c436db138b9ee33a4776a28f5d1c743e1 Author: Cédric Bosdonnat Date: Mon Jun 10 18:04:34 2013 +0200 Fixed some make distcheck problems commit 6dd7f758298643563bbc39e1dbeb7e226181e4f4 Author: Cédric Bosdonnat Date: Mon Jun 10 16:28:04 2013 +0200 some more cppcheck fixes commit b298e52bd3ab4cdc7c10f58f0c696df6759b4e00 Author: Cédric Bosdonnat Date: Mon Jun 10 16:27:46 2013 +0200 run cppcheck in make check if we have it around commit 6ae5279516c1342b444e92e06f4cc6ef962e15e4 Author: Cédric Bosdonnat Date: Mon Jun 10 14:54:27 2013 +0200 Fixed cppcheck-reported problems commit 96b3512c5276602427354e8e0e4c26ff018b74e2 Author: Cédric Bosdonnat Date: Mon Jun 10 14:14:15 2013 +0200 atom test: moved checkin to mockup tests commit 572aaf3fb98cec88f5a2622b3ed4250250365e0f Author: Cédric Bosdonnat Date: Wed Jun 5 11:45:31 2013 +0200 Added unit test for fdo#60954 property parsing case commit 4f532d4a2dd5e86e4a17e30ed703a67a4f149530 Author: Cao Cuong Ngo Date: Fri May 31 16:17:20 2013 +0200 GDrive: revisions should have the same parent ID with the original document commit c80e00195a5ad14ec45311cf1303518382a2176d Author: Cao Cuong Ngo Date: Fri May 31 16:00:06 2013 +0200 GDrive test: getAllVersions commit 1c8449c2693e69b4a7131331b5b1f484e65f5891 Author: Cao Cuong Ngo Date: Fri May 31 15:27:27 2013 +0200 Move some methods from GdriveUtils to OAuth2Providers commit c9a7b72944c1da7bb031aaa83e67c71aac8a0df7 Author: Cédric Bosdonnat Date: Thu May 30 14:28:09 2013 +0200 Renamed BaseSession::getBaseUrl() into getBindingUrl() commit 27f14a81c879e37eb87c9d97ef93e44bf4ef9c4a Author: Cédric Bosdonnat Date: Thu May 30 14:27:49 2013 +0200 Match Alfresco in the cloud OAuth2 parser based on the hostname only commit 5742fcab9f6d9b275d07b493fe1c32319798c778 Author: Cao Cuong Ngo Date: Thu May 30 13:55:20 2013 +0200 OAuth2 session refactoring commit a4235d5037a663020d7f18c8fa04c6f888d76c7e Author: Cédric Bosdonnat Date: Thu May 30 13:40:42 2013 +0200 AtomTest moved cancelCheckOutTest to mockup tests commit 26882d09e33d90c0198e727d2de688c22245118f Author: Cédric Bosdonnat Date: Thu May 30 13:40:17 2013 +0200 getAllowableActions() should catch CurlException commit e6b8f3688569d757c5d7dfc459556cc2d551daf0 Author: Cédric Bosdonnat Date: Thu May 30 10:48:24 2013 +0200 libcmis-c: readded oauth2-data removed code and fixed it commit b1cb78b419268877d61e6c39c2e5a255881f6cc5 Author: Cao Cuong Ngo Date: Wed May 29 15:31:45 2013 +0200 Rendition: some refactoring + C wrapper commit 4263ddd04b51a4010906ba857c7911418a717f97 Author: Cédric Bosdonnat Date: Tue May 28 17:04:52 2013 +0200 Added rendition.hxx to the public headers commit 65c580736ca8c13e311308eb99600c58d8b03be8 Author: Cao Cuong Ngo Date: Tue May 28 14:19:22 2013 +0200 OAuth2: drop authentication by refresh key. We always require username/password for each session creation. commit dbdaf2972f9c781fb6f89618261ca3a1e4e736a5 Author: Cao Cuong Ngo Date: Tue May 21 21:05:13 2013 +0200 return empty code to use fallback provider commit 52be61185d256ce97e48689bfd3371f7d039c36f Author: Cao Cuong Ngo Date: Tue May 21 20:26:22 2013 +0200 Oauth2Authenticate: return an empty auth code to fallback commit de8de722adc7963a1ceee83d2f0957049e4d9c49 Author: Cao Cuong Ngo Date: Tue May 21 19:45:26 2013 +0200 no need to create a temporary oauth2handler commit f919ca96408c4009c263e53d9d997533c0d05de0 Author: Cao Cuong Ngo Date: Tue May 21 19:05:39 2013 +0200 Alfresco public API OAuth2 parsing commit fa49b75ef7021282e58e0ae244a67822ccb620bb Author: Cao Cuong Ngo Date: Tue May 21 17:37:32 2013 +0200 OAuth2: if session creation fails with refresh token, continue with other methods commit e8e5d0e40a46bf37224299bfdd625254d24ac0ae Author: Cédric Bosdonnat Date: Tue May 21 16:31:48 2013 +0200 atom tests: moved checkOutTest to mockup commit f2be182947efbbefb92c161e3bac867b72f1829a Author: Cao Cuong Ngo Date: Tue May 21 15:29:58 2013 +0200 OAuth2AuthCodeProvider: return string instead of char* to free caller from deletion commit afc1523da778d9c18493a22b55560acca7c8f501 Author: Cédric Bosdonnat Date: Tue May 21 13:31:16 2013 +0200 Fixed test-jsonutils build: no need of the mockup libcurl commit 9baf1e12f46136171096c533bebba6f99d7c27ca Author: Cédric Bosdonnat Date: Tue May 21 10:29:40 2013 +0200 cmis-client: don't drop the temporary session, reuse it commit fc3a0aee07fbd362cd0a398dd6c1a844e5b5f475 Author: Cédric Bosdonnat Date: Thu May 16 13:58:48 2013 +0200 disable unit tests on windows as they don't build commit 13cb7a2a30fed32bfab344d43075f1af0ea00f54 Author: Cao Cuong Ngo Date: Tue May 21 11:34:54 2013 +0200 Object: add getThumbnailUrl( ) method which fetch the thumbnail link from renditions list. commit 97f44d66085e14fb85fbfb2cb3ad7e92cfc2db92 Author: Cao Cuong Ngo Date: Tue May 21 11:12:20 2013 +0200 OAuth2: allows client to fetch the refresh token from a session commit 3baa0c55ddc0f75f95cf8de2b415dcbc37ee7009 Author: Cao Cuong Ngo Date: Mon May 20 13:33:43 2013 +0200 GDrive: some clean up, move const strings to utility class commit 319441f3d94e33c8a96a4f1a9f2e2cb72853216a Author: Cao Cuong Ngo Date: Mon May 20 03:48:32 2013 +0200 OAuth2: access token expires in [expires_in] seconds, need to refresh it to get a new one commit 0945b5b98252d4d1be96ab31a75df21b532a678e Author: Cao Cuong Ngo Date: Mon May 20 00:48:02 2013 +0200 cmis-client: allows using of OAuth2 refresh token commit c68775892536f5f605f002c70a09007bab96431a Author: Cao Cuong Ngo Date: Sat May 18 11:28:22 2013 +0200 OAuth2: allow using of refresh token. OAuth2Data now allows client to use their refresh token to get access key directly without username/password commit 1d185b4424ffcc0bf1d29e64155b59fc0abf2044 Author: Cao Cuong Ngo Date: Fri May 17 22:03:51 2013 +0200 GDrive document: fetch thumbnail to renditions commit 9a177b9e12b2f638404f612c72caa3be2c7524d5 Author: Cao Cuong Ngo Date: Fri May 17 21:48:37 2013 +0200 GDrive move object: an object can have multi parents, The move function should replace only the source Id and keep the rest parents commit b88bd4663b6ed347ed4454d0bad4f9b65a8d7b21 Author: Cao Cuong Ngo Date: Fri May 17 21:10:14 2013 +0200 Move some methods to Gdrive utils commit ba6416ad7855d9742135a1b838cc5563eef90ff9 Author: Cao Cuong Ngo Date: Fri May 17 20:08:30 2013 +0200 GDrive: don't fetch trashed children commit 1f45f8760d774fe4128ee01134ff6f52ed0fbb58 Author: Cao Cuong Ngo Date: Fri May 17 19:26:42 2013 +0200 GDrive doesn't have a link to all children, we send a query to search for all files whose parentID is equal to the current folder to avoid using multiple queries. commit dd26e9f41fa5aa131a46b2fe196cdb2206486693 Author: Cao Cuong Ngo Date: Fri May 17 14:12:11 2013 +0200 Rendition: print to string commit 9956accb1564e5953164a7f15c805803c08a2b4b Author: Cao Cuong Ngo Date: Fri May 17 11:41:47 2013 +0200 cmis-client: add support for streamId commit ffbf74ba226a7e716d3689ca17a8556251527689 Author: Cao Cuong Ngo Date: Fri May 17 11:18:57 2013 +0200 GDrive document: use mimeType to check if it is a Google doc commit 07931cfb4b1ccc6f408ec1d9963dc5935079a05e Author: Cao Cuong Ngo Date: Fri May 17 09:56:32 2013 +0200 Add renditions support commit 69009b73c525553f947d147cecdf8d4b64cb47f2 Author: Cao Cuong Ngo Date: Thu May 16 22:54:56 2013 +0200 More Gdrive tests commit db48572f8eca70bb79f81f50aac2d07a2d1a3a90 Author: Cao Cuong Ngo Date: Thu May 16 22:19:12 2013 +0200 More Json tests commit 180ef55a1befd3a18a9f6b8a3b592a82520c4dac Author: Cao Cuong Ngo Date: Thu May 16 21:26:18 2013 +0200 Gdrive: CMIS name conversion of cmis:description commit 4f118e775ce31cbaaaa909ee2b91f9dbb7b2b5d9 Author: Cao Cuong Ngo Date: Thu May 16 19:46:36 2013 +0200 property: default constructor should not be public commit 4ca972d42472ecbf8e06e7302474d1735df5b381 Author: Cao Cuong Ngo Date: Thu May 16 19:21:55 2013 +0200 Gdrive: set object type updatable commit b841045e963257f8147110ff8022c741a71c201f Author: Cao Cuong Ngo Date: Thu May 16 17:19:54 2013 +0200 cmis:name and cmis:contentStreamFileName can be duplicated or not, better check before converting key. commit 29a18bfbf9501675b535287a7756742ecf6ac1ce Author: Cao Cuong Ngo Date: Thu May 16 15:29:02 2013 +0200 move compability functions to a separate file commit 13b127ab921444de24266707ff654dee7176c6ee Author: Cao Cuong Ngo Date: Thu May 16 11:17:23 2013 +0200 GDrive: Folder has one parent but Document can have multiples commit cc04585cb8347945a8d3b605025063f99ca0f5d6 Author: Cao Cuong Ngo Date: Wed May 15 21:42:25 2013 +0200 Google Drive doesn't support get object by path commit f9a4c6f5a0b51e0057546ab69224073f25a1e8cc Author: Cao Cuong Ngo Date: Wed May 15 21:33:34 2013 +0200 GDrive folder remove tree commit 925fadc037c31ef0ef77724e93f901e45b07713b Author: Cao Cuong Ngo Date: Wed May 15 20:34:52 2013 +0200 Missing move-object in client help commit 8db5ddee5684ccdd0867da89c3ceb137e7000ec1 Author: Cao Cuong Ngo Date: Wed May 15 16:00:43 2013 +0200 GDrive createDocument and CreateFolder commit c8e1e7553b26ca0f3982dd048ee13e8b0ac287bb Author: Cao Cuong Ngo Date: Wed May 15 15:14:49 2013 +0200 GDrive move object commit d8ba6350ebdd7ffcb95ee6cd3a0efcb9460ce94b Author: Cao Cuong Ngo Date: Wed May 15 14:00:08 2013 +0200 Gdrive Object: remove commit 28572214556509295b09e1da45feb4c3835f8d06 Author: Cao Cuong Ngo Date: Wed May 15 13:17:29 2013 +0200 Separate GDrive object type commit 721e18b7cab53c1de8f5e030ac6cb21531772185 Author: Cao Cuong Ngo Date: Wed May 15 12:57:14 2013 +0200 Handle json object when it's null commit 1e9eb3f3bb40b211cdb29e79cbaa51216c175fd3 Author: Cao Cuong Ngo Date: Wed May 15 11:12:13 2013 +0200 GDrive fixed: some folder doesn't have parent commit ff9738006b65b94cde7105f392e1b07db93912f4 Author: Cao Cuong Ngo Date: Wed May 15 01:38:46 2013 +0200 Fixed setContentStream fileName, Fixed updateProperties Url commit 43da75bf9d19321623501effa5a0634230797b7e Author: Cao Cuong Ngo Date: Wed May 15 00:42:34 2013 +0200 separate Gdrive repository commit d0cd11fafd9202afa3e03e5bf4c9217770ba17c0 Author: Cao Cuong Ngo Date: Wed May 15 00:20:58 2013 +0200 Gdrive: getUrl() and getUploadUrl() to avoid redundant codes commit bfc161949dabb998afa7d1ced4d594596ccec4fd Author: Cao Cuong Ngo Date: Tue May 14 23:08:29 2013 +0200 create Json object from properties commit caf61096d1b37f3a9df16ae6a63fe1a6150e2cfe Author: Cao Cuong Ngo Date: Tue May 14 20:57:57 2013 +0200 GDrive object refresh commit f200e755a5f4fc9ef217dbf688417638dee07e7b Author: Cao Cuong Ngo Date: Tue May 14 18:19:31 2013 +0200 Handle json type since libjson doesn't do it properly commit 733276acaf78f033ffbad05128b99fb1d9e5c503 Author: Cao Cuong Ngo Date: Tue May 14 17:26:29 2013 +0200 Avoid using namespace in .hxx commit 74939ae4539f11fc6ebfd6e5737c090eda99f627 Author: Cao Cuong Ngo Date: Tue May 14 11:16:12 2013 +0200 Some refactoring in Gdrive AllowableActions commit 659712b20452c26db67fc0178e571d4d42ee8b78 Author: Cao Cuong Ngo Date: Mon May 13 20:51:04 2013 +0200 GDrive CheckIn/CheckOut commit 2ddfe2d145aa4e4a1b19e8df6da520188118d40b Author: Cao Cuong Ngo Date: Mon May 13 20:02:00 2013 +0200 set GDrive allowable actions commit 38aa8e5c8fa005080b5a3329929a06b8c1893a7a Author: Cao Cuong Ngo Date: Mon May 13 18:25:20 2013 +0200 Extract the parentId from the parent list commit 06a6635992e56fc62d9a947c6f20241ecc913e73 Author: Cao Cuong Ngo Date: Mon May 13 16:29:14 2013 +0200 More GDrive tests commit 6d45fe16cb79c496a0ecacd4bef91a8e7cfc4706 Author: Fridrich Štrba Date: Mon May 13 11:51:45 2013 +0200 Check for Windows on configure time commit cc2aec888303eea547d0916ce7e025f20c1638d9 Author: Cédric Bosdonnat Date: Mon May 13 11:24:33 2013 +0200 Revert "Fix linking of libcurl-mockup (why to dupplicate internal curl functions???)" This reverts commit 533307c86c59c8353ea62279bcfd6c9b13a98f3b: this links the mockup tests with the real libcurl instead of its mockup even on linux... and breaks quite a lot of tests commit 4eb9e3ce42ed5c23fab48b27fab3195c6e42ea8f Author: Cao Cuong Ngo Date: Sun May 12 23:32:44 2013 +0200 GDrive test: more tests + refactoring commit 3b6b3a17282bbdc34509b0a91dafa8ddc9036b12 Author: Cao Cuong Ngo Date: Sat May 11 22:24:39 2013 +0200 Clean up GDrive test commit 533307c86c59c8353ea62279bcfd6c9b13a98f3b Author: Fridrich Štrba Date: Sat Apr 27 11:48:46 2013 +0200 Fix linking of libcurl-mockup (why to dupplicate internal curl functions???) commit ec0c35ef460c0e6d315cb3c03b5542125568464a Author: Fridrich Štrba Date: Sat Apr 27 10:53:39 2013 +0200 Fix linking on windows-mingw (cherry picked from commit 2682c3c0a03894a9e68bf9db9151cd03b1829581) commit e75bd2548101b8681edf13ea085d62634b7668cf Author: Cédric Bosdonnat Date: Mon Apr 22 15:45:26 2013 +0200 Init protocols should be done right after resetting curl handle commit 6401443248d7ce9fad1b42bad291418d59f4a623 Author: David Tardon Date: Mon Apr 8 20:18:19 2013 +0200 rhbz#918080 restrict the set of protocols for curl commit 8e66145d204f7d053549b7cc28aef6863cfd38c8 Author: David Tardon Date: Mon Apr 8 14:07:23 2013 +0200 rhbz#918079 always return 40 hexa digits commit 581a2ea1693b572d9f0a9f3cf356064c9920f71d Author: Cédric Bosdonnat Date: Fri Apr 12 11:05:25 2013 +0200 made libcmis_session_get... functions string parameters const commit f711bfaf9e6f8bcc7b2bc54f9ed558ccf419c2b2 Author: Cédric Bosdonnat Date: Fri Apr 12 11:04:34 2013 +0200 Fixed WSSession::setRepository() commit 3ebb532625ced11fa166cd6ac51505c539a8ee50 Author: Cédric Bosdonnat Date: Thu Apr 11 09:21:35 2013 +0200 added libcmis_session_setRepository() commit dabad5febb2f6673a31dc4f0511759e08a6cfd6c Author: Cédric Bosdonnat Date: Thu Apr 11 08:35:36 2013 +0200 Forgot unused parameter commit 862a85f487903feef0335dd7ec55ef9ffc73b8c0 Author: Cédric Bosdonnat Date: Thu Apr 11 08:31:24 2013 +0200 Added Session::setRepository to allow choosing a repo without recreating the session commit c461bde87188c88a59e775d9c62ceff7fbe47199 Author: Cédric Bosdonnat Date: Thu Apr 11 08:30:43 2013 +0200 Fixed GDriveTest::getObjectTest commit 30f82b2ad56add3dab6799a8be4a5df9701a4ff0 Author: Cédric Bosdonnat Date: Wed Apr 10 17:09:10 2013 +0200 libcmis_session_getRepository returns NULL if no repository is set commit 833a6d93bd05b83180a40a99800400e314eeb79b Author: Cédric Bosdonnat Date: Wed Apr 10 12:06:42 2013 +0200 libcmis-c tests adapted to error API changes commit 673619e4d8f46a61cd27431b586b27b9f93f8c62 Author: Cédric Bosdonnat Date: Tue Apr 9 16:53:32 2013 +0200 libcmis_createSession make sure we're not creating std::string from NULL commit 1785bd837ad159f18588f470508627f127d42237 Author: Cédric Bosdonnat Date: Mon Apr 8 11:25:55 2013 +0200 fixed libcmis-c.pc to point to versioned libcmis pc file commit 75801d0996e6b2b6bd4a1e3337f13a0b7149bf0d Author: Cédric Bosdonnat Date: Mon Apr 8 09:26:20 2013 +0200 libcmis-c: handle possible bad allocations commit bf8070dfed5532a96079e82c4083033365b0791b Author: Cao Cuong Ngo Date: Wed Mar 27 19:36:28 2013 +0100 GDrive folder implementation Conversion from properties to Json still need more work out. commit e0e0653944ab164918b1f0c9a9b29007174d66b1 Author: Cédric Bosdonnat Date: Fri Apr 5 15:23:55 2013 +0200 libcmis-c unit test: fixed valgrind errors commit 9c2269efd28d8520a281db1efaac383db07767d0 Author: Cédric Bosdonnat Date: Fri Apr 5 14:39:53 2013 +0200 Override delete operator to call free to avoid valgrind shout commit 23b7a1ee873997f08094df43ade445d6eb07c537 Author: Cédric Bosdonnat Date: Fri Apr 5 14:14:04 2013 +0200 rhbz#918044: bad_alloc handling in libcmis_document_getContentStream To test bad_alloc, the new operator is overridden in test-dummies.cxx and uses a global variable to throw bad_alloc at will. Just pay attention that the test objects may also call new: temporarily switch the flag off in those cases. commit c706615d560df583c48f526fb0ce280c05624cac Author: Cédric Bosdonnat Date: Fri Apr 5 10:27:53 2013 +0200 Reworked libcmis_getRepositories to fix several issues: * a potential memory leak (see rhbz#918044) * no size was returned: so method not usable * create and use libcmis_session_getRepositories to reflect the recent changes in libcmis * transformed the Session::getRepositories result from list to vector to ease mapping in C wrapper and for more consistance with other structures used in libcmis commit 0f7b1455a05136747740af8aa869af2b28593519 Author: Cao Cuong Ngo Date: Mon Mar 25 12:46:30 2013 +0100 Rename PropertyListPtr to PropertyPtrMap commit af54b07c1269f78de2389516e388d7c9ae05fb68 Author: Cao Cuong Ngo Date: Mon Mar 25 12:37:45 2013 +0100 We don't have to use base64 encode stream for Google Drive. commit 7a7d3f13751c7b0775edaeb510e5e8343d01e420 Author: Cédric Bosdonnat Date: Mon Mar 25 11:08:07 2013 +0100 Google Drive: document and folder types need to be mapped to CMIS types and are no arbitrary strings. Used cmis:document and cmis:folder for GDriveDocument and GDriveFolder commit f65c6d1d49cd522b453d8a44244bd57c9bb1f821 Author: Cao Cuong Ngo Date: Sun Mar 24 19:15:40 2013 +0100 GDriveObject::updateProperties commit ae5698ad293d8f04506d932bf6229cc1e0bf631f Author: Cao Cuong Ngo Date: Sun Mar 24 16:05:14 2013 +0100 typedef map< string, libcmis::PropertyPtr > PropertyListPtr which is frequently used and too long. commit 2bd907bc3c8bbc1bb4f32b6dd48980c71f3cf493 Author: Cao Cuong Ngo Date: Sun Mar 24 14:52:16 2013 +0100 Add catch exception for http requests commit c7399edab18997e455e665e5c3d9bebb616f3eaa Author: Cao Cuong Ngo Date: Sun Mar 24 13:47:29 2013 +0100 GDriveFolder::getChildren commit 9ab98a3430749edc8bb918e8c1a81fcd8c130057 Author: Cao Cuong Ngo Date: Sun Mar 24 01:04:39 2013 +0100 Dummy object-type commit 65220f1dd916dcf97ebe5db51630870614473382 Author: Cao Cuong Ngo Date: Sat Mar 23 00:47:54 2013 +0100 GDriveDocument::getParents commit 14f894615208dedd9639b1e12bd297349be1843f Author: Cao Cuong Ngo Date: Sat Mar 23 00:40:15 2013 +0100 GDriveDocumenet::getAllVersion commit d5803155ae8301b2a2328a02ee94a92dcd076a97 Author: Cao Cuong Ngo Date: Fri Mar 22 23:55:32 2013 +0100 remove commented code commit a2827304420a53281f1d0188810b7ab0657873f7 Author: Cao Cuong Ngo Date: Fri Mar 22 23:49:43 2013 +0100 GDriveDocument::setContentStream commit 0c5c977f782e3321c332ce6bae01297a6c6ef238 Author: Cao Cuong Ngo Date: Fri Mar 22 20:59:26 2013 +0100 GDriveDocument::getContentStream commit a9f74f1080c45a80423975a4f7f973c475a8d7a7 Author: Cao Cuong Ngo Date: Fri Mar 22 19:34:11 2013 +0100 GDriveSession: search for "kind" property first to determine if it's a file or not commit e3b18923c525ba23ee7649845a2f1f3ca9a7e0eb Author: Cao Cuong Ngo Date: Fri Mar 22 19:16:45 2013 +0100 gdrive folder skeleton commit 140a22660561fd283a72c56a23ccc71b57f49495 Author: Cao Cuong Ngo Date: Fri Mar 22 16:44:09 2013 +0100 getStringProperty( ) refactoring commit 93f1fec03ef7ccbc430bdcadfe2e36de0825a90f Author: Cao Cuong Ngo Date: Fri Mar 22 15:45:30 2013 +0100 GDrive Document skeleton, fix Document::getContentLength( ) bug commit 7b9cbc23fb056d42972e9bd4714fd2820e6753ad Author: Cao Cuong Ngo Date: Thu Mar 21 16:50:24 2013 +0100 Fix property names mapping commit 2cb1f18d4638b3c70cc2b8af533ba849a354a888 Author: Cao Cuong Ngo Date: Wed Mar 20 18:53:49 2013 +0100 Fix Json datetime type commit d2a5963961df49de4c5725682a8c8a3ca13fb7cb Author: Cao Cuong Ngo Date: Wed Mar 20 18:32:56 2013 +0100 Fix OAuth2 append header bug commit 78388176e832a6af1728e9428fad8df2d78d9a2c Author: Cao Cuong Ngo Date: Wed Mar 20 17:49:18 2013 +0100 Push dummy repository in Gdrive Session. Add default constructor in GdriveProperty. Simplify json test file. commit 1f3d81ca2e9fd303b50d5cad0ba825906e4cbddb Author: Cao Cuong Ngo Date: Wed Mar 20 14:40:05 2013 +0100 Move GDrive specified code to its classes from base classes. Some minor refactorings in test. commit 2b3da04277b69140f86642e7a3df47fdde628c2c Author: Cao Cuong Ngo Date: Wed Mar 20 10:00:35 2013 +0100 Typo fix commit cba5023e6f7a542797cab52692039b1f7234f9df Author: Cao Cuong Ngo Date: Wed Mar 20 09:50:41 2013 +0100 Using a DummyRepository class instead of a dummy constructor commit d901838bd98b9c64b4d0eaeb079e9f1ff61ae631 Author: Cao Cuong Ngo Date: Wed Mar 20 00:29:23 2013 +0100 Dummy repository commit 01dc2dd4d9983a53bfa9a0d9d9e1ee1f650ab631 Author: Cao Cuong Ngo Date: Tue Mar 19 21:09:45 2013 +0100 GDrive Object creation implementation + test commit b689104e6bea33cbf277089f359064fcad08f9d2 Author: Cédric Bosdonnat Date: Tue Mar 19 16:03:39 2013 +0100 GDriveSession: silence the HTML parsing and make it recovering errors commit dd5d309358a75fd1f2f50e12e623bbd4aba0b434 Author: Cédric Bosdonnat Date: Tue Mar 19 15:55:47 2013 +0100 GDrive, skeleton of GDriveObject to start to implement commit acd39fb53e8fb9d40dde9d2a4ec88ea6f777f49d Author: Cao Cuong Ngo Date: Sun Mar 17 23:43:44 2013 +0100 Pass oauth2 informations as arguments to Gdrive session instead of using predefined string. Use xmlTextReader instead of xml tree commit d26dbbf2b4c26594937c5920d43ade819a2d28da Author: Cao Cuong Ngo Date: Fri Mar 15 20:36:49 2013 +0100 Using libxml2 HTMP Parser instead of manual parsing commit 849bc7c282dda4a3262d0f7f8f256420f5ed01b3 Author: Cao Cuong Ngo Date: Thu Mar 14 20:44:42 2013 +0100 Move cookie handler to base-session, just activate the curl cookie engine is enough. commit 179a561e74d58070384d1f8e8544269d345167e4 Author: Cao Cuong Ngo Date: Thu Mar 14 19:14:12 2013 +0100 GDrive Session: - Parse all the input values of the response page to post instead of just necessary one. - Update mock test, check for post requests. Base Session: - Move follow location to httpRunRequest OAuth2 Hander: - Modify exception message commit 51547efd058e6db15aa4c57894aa214aa506f59b Author: Cédric Bosdonnat Date: Thu Mar 14 16:38:38 2013 +0100 Mockup test: moved the atom data files in their own folder commit 5529dc2f364c7ffe5c4ee5d5225ca3e0c4492a5d Author: Cédric Bosdonnat Date: Thu Mar 14 16:08:42 2013 +0100 Moved AtomTest::deleteTreeTest to mockup tests commit 473f90b8b9689bc1dc182014ffd57e17f1fde35e Merge: b17f620 8bd63be Author: Cao Cuong Ngo Date: Thu Mar 14 00:36:38 2013 +0100 Merge branch 'master' of ssh://git.code.sf.net/p/libcmis/code commit b17f6203f9219c60fa780c66dca59288b15e3284 Author: Cao Cuong Ngo Date: Thu Mar 14 00:34:46 2013 +0100 Gdrive oauth2 session mock test commit 8bd63be8bd6d43d0b287847bacd66ce0020b16cb Author: Cédric Bosdonnat Date: Wed Mar 13 11:32:48 2013 +0100 Made auth2Authenticate throw CurlException and catch it in order to help handling the problems when sending the HTTP requests: can be wrong client_id / secret_id, but also any network problem: we shouldn't obsfuscate the error message. commit 14099216e44894250ac5dadf7a0cb5f133bb16f2 Author: Cao Cuong Ngo Date: Wed Mar 13 00:25:40 2013 +0100 Handle exceptions of bad username/password, bad client ID and bad client secret commit e033e0ed7d07e36ec1fc51d12215ea83d114e06d Author: Cédric Bosdonnat Date: Tue Mar 12 11:55:46 2013 +0100 cmis-client now prompts for username/password if those are missing. The password is still shown on the console (hiding is varing with the platform/OS), but at least the password won't be in the shell history this way. commit 0a2e70014064ed507495a4148d8207a74385f35c Author: Cédric Bosdonnat Date: Tue Mar 12 11:34:06 2013 +0100 Added oauth2 options in cmis-client documentation commit 656b4292deb42c7038d766fa4a3ac3d58a7fd58f Author: Cédric Bosdonnat Date: Tue Mar 12 11:23:41 2013 +0100 BaseSession: make sure the credentials have been completed before using them commit 7f0f541cc8abbb9106a9b0a32c64538c0cd444e0 Author: Cédric Bosdonnat Date: Tue Mar 12 10:46:06 2013 +0100 Added GDriveSession creation in the factory. The binding URL to use to create the GDrive session is: https://www.googleapis.com/drive/v2 commit 24ed5ae02d0b261eb3a45e120c8872f6b501dcc9 Author: Cédric Bosdonnat Date: Tue Mar 12 10:45:31 2013 +0100 Cleaned up the code and comments in GDriveSession::oauth2authenticate commit 8138ef0d0c57f4c1e1d19141e8da73fac64fac37 Author: Cao Cuong Ngo Date: Tue Mar 12 10:29:16 2013 +0100 search for GALX cookie instead of the first cookie commit 3aa216342aed61ee7e62f6a6acbf0e0f319cd8ec Author: Cédric Bosdonnat Date: Tue Mar 12 09:50:18 2013 +0100 Removed the OAuth2Data authentication callback: was moved to BaseSession commit e1d03a8b5c4ac2dba8dcbc609246e73fedb185ec Author: Cédric Bosdonnat Date: Mon Mar 11 17:59:01 2013 +0100 Moved deleteDocumentTest to mockup commit 1c04ed10741e806fda4cebb09a77cb2feec1f3e8 Author: Cao Cuong Ngo Date: Tue Mar 12 09:19:03 2013 +0100 Fix the return authCode (should have used strcpy) commit 4946a8d03d4af3914565d99831d83bfffcb9711a Author: Cao Cuong Ngo Date: Tue Mar 12 00:02:33 2013 +0100 GDrive OAuth2 is now automatic. The HTML response pages are parsed from tags (Google can change the form some day). commit cd73c40023fa1e584f7ba905e990b5728600deb8 Merge: 7cc4b6f 4ee6044 Author: Cao Cuong Ngo Date: Mon Mar 11 18:21:00 2013 +0100 Merge branch 'master' of ssh://git.code.sf.net/p/libcmis/code commit 7cc4b6f5486a24a4a6e85efed259eb7d2d16cbc4 Author: Cao Cuong Ngo Date: Mon Mar 11 18:15:46 2013 +0100 OAuth2: went to the approve page, still have to parse the HTML to get the code commit 4ee6044fc806523c2a6d5f207011fb3257b1946a Author: nccuong Date: Mon Mar 11 18:15:46 2013 +0100 OAuth2: went to the approve page, still have to parse the HTML to get the code commit e4412ae688212bf1b6ab1b13afa4fe2e80d6ed49 Author: Cédric Bosdonnat Date: Fri Mar 8 15:15:41 2013 +0100 fixed build error: missing * commit 410db26bc197e74387141322526e4685f1026321 Author: Cédric Bosdonnat Date: Thu Mar 7 15:29:09 2013 +0100 Add OAuth2 HTTP header if OAuth2 authentication succeeded commit b9c2bc5b45fc4e14d5939b1e3012ba2139d26580 Author: Cédric Bosdonnat Date: Thu Mar 7 10:24:55 2013 +0100 BaseSession: add the headers only in httpRunRequest commit 60fcbac7d43f4c2c6d71e184a4abf02f469dfe4e Author: Cédric Bosdonnat Date: Thu Mar 7 09:23:53 2013 +0100 Removed debugging couts commit 07efd2231c1346b400a3c89d3226e92a210b5200 Author: Cédric Bosdonnat Date: Thu Mar 7 09:21:37 2013 +0100 Initialize OAuth2 after curl handle to avoid crashes commit 43b242651a65714a729a8615ad35dc59f16aa6c2 Author: Cédric Bosdonnat Date: Wed Mar 6 19:49:10 2013 +0100 Rename scopes to scope everywhere as OAuth doc mentions scope commit e44ab9c92ac23d61211645912d5c5b063f4013b3 Author: Cao Cuong NGO Date: Wed Mar 6 17:38:34 2013 +0100 Google Drive implementation start Started implementation of GDriveSession class and corresponding mockup unit tests. Added code to handle OAuth2 at the BaseSession level to benefit all bindings / protocols. This needed some small refactoring of the existing code. commit 75236d120d665198ce23eb7b06ab38c55467a5db Author: Bjoern Michaelsen Date: Fri Mar 1 01:49:37 2013 +0100 prevent warning prevents error: ignoring return value of 'size_t fread(void*, size_t, size_t, FILE*)', declared with attribute warn_unused_result [-Werror=unused-result] with strict CFLAGS (although this is a false positive anyway right now) commit 7cc784f74358dece8440db227e0d460ceafe53ac Author: Cédric Bosdonnat Date: Wed Feb 13 18:45:03 2013 +0100 AtomFolder::createDocument fix: use Location header if needed The specification says the created entry is returned as a URL in Location header. Thus the priority to get it is now: - try the response body - try Location header - try Content-Location header for Lotus Live commit 1b571d0ae214dbae0f8b19d7d46a37dd0bcec873 Author: Cédric Bosdonnat Date: Wed Feb 13 16:00:45 2013 +0100 Added ObjectType::getBaseTypeId() and getParentTypeId() for perf reasons commit c3ba5475fc46dba9fa412c75fe622cf4d724160a Author: Cédric Bosdonnat Date: Wed Feb 13 08:37:43 2013 +0100 AtomTest::createFolderBadType moved to mockup tests commit 61d74599e8db5a739c559abcd43e4ce387e44fe1 Author: Cédric Bosdonnat Date: Wed Feb 13 08:10:24 2013 +0100 AtomTest::createFolderTest moved to mockup tests commit 53f06102a1613dc4ccc660c278a778b581393a21 Author: Cédric Bosdonnat Date: Wed Feb 13 07:40:30 2013 +0100 Atom: fixed the error type for the 404 returns to be objectNotFound commit f86585cb41f79c9928adb480f06699cb23da6272 Author: Cédric Bosdonnat Date: Tue Feb 12 15:46:03 2013 +0100 Atom GetChildren allowableActions is not sent by Lotus Live In that condition, getChildren() should raise an exception only if canGetChildren is not allowed and defined. commit 3b17d146de8802feec25e7c6fd2080c097e8da46 Author: Cédric Bosdonnat Date: Tue Feb 12 15:20:15 2013 +0100 Atom: when we have no allowable actions, try to get them Some servers like Lotus Live aren't providing the allowable actions in the object entry in all cases. Then we need to fetch the allowable actions in the other way even though it adds one more http request. commit ecd344d1000c4a3467868e794f00a4c6780b0910 Author: Cédric Bosdonnat Date: Sun Feb 3 19:47:22 2013 +0100 Moved atom updatePropertiesTest to mockup commit f134d1be356d44f870cb23d8b36a71a398e20413 Author: Cédric Bosdonnat Date: Fri Feb 1 17:36:10 2013 +0100 Moved AtomTest::setContentStreamTest to mockup tests This required to add support for testing the PUT / POST requests in the CURL mockup. The general idea here is to get the request body that was sent and see if it matches the expectations. commit bc6f355317040368dcbac21571b5d472fb56670d Author: Cédric Bosdonnat Date: Fri Feb 1 11:18:01 2013 +0100 Moved AtomTest::getContentStreamTest to mockup tests commit 0790d8be5ea695e1d4bc168b176970f8fe0c7a2c Author: Cédric Bosdonnat Date: Thu Jan 31 10:27:14 2013 +0100 Moved getChildren and getParents atom tests to mockup tests commit 6e6a0f1b25baadc7c775370b7750989412062986 Author: Cédric Bosdonnat Date: Wed Jan 30 10:34:03 2013 +0100 Moved atom getAllowableActions test to mockups test commit 25491d48475cfb870e79e5cba5afd216c10e66c9 Author: Cédric Bosdonnat Date: Wed Jan 30 10:28:25 2013 +0100 Added allowable actions to Atom object responses commit 39b0ec2c8d42798c95f44287eaa07aab853ed2cb Author: Cédric Bosdonnat Date: Tue Jan 29 22:38:01 2013 +0100 Bumped version numbers for 0.4.0 commit 4dcc2f3a92326a2245c77e2f96c27048e5cfe970 Author: Cédric Bosdonnat Date: Mon Jan 28 17:28:27 2013 +0100 Moved Atom getByPath tests to mockup tests commit 0f551a749e5c5655428691189cae3d72b69c5250 Author: Cédric Bosdonnat Date: Mon Jan 28 17:07:38 2013 +0100 Moved Atom document and folder creation tests to mockup tests commit 1ba6d0da01db197f73570db1c6c3e917c5e32996 Author: Cédric Bosdonnat Date: Fri Jan 25 15:57:06 2013 +0100 Moved AtomTest::getUnexistantObjectTest to mockup test commit 70c5ffdc0b7c73b787fc9a40c1ac098390eb60d3 Author: Cédric Bosdonnat Date: Fri Jan 25 14:40:57 2013 +0100 Moved all Atom types tests to the mockup test commit 31cca296a3175a645832ea4329cd0ad7bfacd0f6 Author: Cédric Bosdonnat Date: Thu Jan 24 22:48:26 2013 +0100 Moved AtomTest::authCallback to the mockup test While moving the test method around, I discovered that the previous test wasn't correctly working as it should have failed earlier (when getting the services document). As InMemory required no authentication to get this document, it was working, but this isn't always the case. In order to fix this, the setAuthenticationProvider had to be moved to the session factory level and turned static. This way the same provider is used for all sessions and the auth Provider can be used within the constructr without adding one more parameter to it. commit ba8a6e400ae778cbfb68d2b5acf91b9033f010ba Author: Cédric Bosdonnat Date: Thu Jan 24 10:12:12 2013 +0100 Remember if we should output Expect: 100-Continue to save HTTP requests commit 473817890e25b3b57fd6d573e3122df0bde51306 Author: Cédric Bosdonnat Date: Wed Jan 23 13:37:33 2013 +0100 HTTP 1.0 proxies may reply with 417 error due to 100-Continue In such cases, disable that header and try again (only for POST and PUT methods) commit 4343a5383997795b133dc16eeb0f24f0d47af67a Author: Cédric Bosdonnat Date: Tue Jan 22 14:32:36 2013 +0100 Proxy support: keep API compatibility with older versions of libcmis The tests for the proxy feature required to move the cleanup of the curl handle at the beginning of the request creation (or we couldn't test anything). This commit also fixes the curl versions: the values need to be real hexadecimal. commit 94375caf5c6819aa0e28061765fc76ed435bcd60 Author: Cédric Bosdonnat Date: Thu Jan 17 15:52:46 2013 +0100 Added poxy settings to session to override the system config if needed commit d605a7238df9fdb43457314c06cc84726d8dcadd Author: David Tardon Date: Wed Dec 19 14:39:11 2012 +0100 allow setting of DOCBOOK2MAN on configure cmdline commit 70f38c73fe5c401d759124487190477aaafb47ef Author: David Tardon Date: Wed Dec 19 14:35:49 2012 +0100 rename DOCBOOK2X to DOCBOOK2MAN commit 7312c4479570de63e098177acf5f04b50c486a0d Author: David Tardon Date: Sat Dec 15 08:40:28 2012 +0100 make the man page valid docbook commit 836936b8a6e9cb64bffccd5101b9800a9883d1d8 Author: David Tardon Date: Sat Dec 15 08:36:48 2012 +0100 add public and system ID to doctype commit e8d97b0b2f085c07aeee37cd79f956c9d94f4a6a Author: Cédric Bosdonnat Date: Mon Dec 17 14:47:31 2012 +0100 added licence header in shell scripts commit 9a5861bb9c76a55abdcfc3139136c5aafcc8886c Author: Cédric Bosdonnat Date: Mon Dec 17 14:45:18 2012 +0100 added a sample populate.sh script to push a local tree to a CMIS server using cmis-client commit 451b239a49995f81d8526c68b080eb3f2c70b3b5 Author: Cédric Bosdonnat Date: Mon Dec 17 14:44:37 2012 +0100 fixed typo in cmis-test.sh commit e6e80350b8f31b749e328aabc2cd172e79c16d6c Author: David Tardon Date: Thu Dec 13 16:15:34 2012 +0100 coverity: cannot use content of temp. var. as return value commit fd9702d002988b797803ed489081bc7d192b67b1 Author: David Tardon Date: Thu Dec 13 15:46:38 2012 +0100 coverity: only libcmis::Exception is allowed here commit c6b4e5a52774ec90db8b0f43777d5f4e97ec5ea3 Author: David Tardon Date: Thu Dec 13 15:37:12 2012 +0100 coverity: only throw allowed exceptions commit 5b2f0d83f8aa68c6d197c0cb0cad9a06218f5d75 Author: David Tardon Date: Thu Dec 13 15:32:25 2012 +0100 make sure there is enough space for filled-in credentials commit 5d90791053460d9604d080262cc84136a352cc67 Author: David Tardon Date: Thu Dec 13 14:53:17 2012 +0100 coverity: actually _do_ the reading in a loop .-) The current code amounts to one-time read+write (in a block), followed by a potentially infinite loop with empty body. commit 4958952e4a018361194c54d635ffe5f595a0f5c7 Author: David Tardon Date: Thu Dec 13 14:31:06 2012 +0100 coverity: check dynamic_cast result for NULL commit 95b2038afbbf84d6d4dd566912722055207ecfe7 Author: David Tardon Date: Thu Dec 13 14:27:52 2012 +0100 coverity: check dynamic_cast result for NULL commit 30d6ff829b8ab171aa673c0e812b0d89ac9b73a3 Author: David Tardon Date: Thu Dec 13 14:09:45 2012 +0100 coverity: sizeof(ptr) returs size of the pointer commit 7e3a48fc047de9ddd3de4cf3fe1e368245b6b754 Author: Cédric Bosdonnat Date: Fri Nov 30 17:21:31 2012 +0100 cmis-test.sh: a tiny step further commit 2e76ab11c630f93596c745727eab07e3577c481e Author: Cédric Bosdonnat Date: Fri Nov 30 17:19:37 2012 +0100 Mockup: started moving the getType and getObjectType tests commit 802390b96f77c54e3ee25c9b6d6ad86dae8c555b Author: Cédric Bosdonnat Date: Fri Nov 30 09:13:21 2012 +0100 Oops, forgot to git add mockup-config.cxx commit e59d87191a76e38956c57887177bd0765f47aeb2 Author: Bjoern Michaelsen Date: Fri Nov 30 09:00:00 2012 +0100 Fix printf format error for i386 commit a1ca9414c2a757a5df62abfe51c8736ee0218629 Author: Cédric Bosdonnat Date: Wed Nov 28 11:44:59 2012 +0100 mockup: migrated AtomTest::sessionCreationTest() and added a bad auth test commit 4c2eece3b195927d5a725c6f70b9e76ae4e5e511 Author: Cédric Bosdonnat Date: Wed Nov 28 11:44:27 2012 +0100 Oops, pushed a binary result by mistake commit 38bd015cd04c8ff294f5ff7c491e002c0c67eff3 Author: Cédric Bosdonnat Date: Tue Nov 27 09:50:25 2012 +0100 Moved libcmis-mockup to mockup commit 24c7c551d82b9f8e20276c5f4127774514e0b74d Author: Cédric Bosdonnat Date: Tue Nov 27 09:34:40 2012 +0100 Remove AtomPub getRepositories test: moved to mockup commit a01fda2642d63a58aa97f48135bf0e01d770f381 Author: Cédric Bosdonnat Date: Tue Nov 27 09:33:24 2012 +0100 Mockup: added getRepositoriesBadAuth test commit 9005604ab2de4030ec9f53eec2f8c02d14e9c3a8 Author: Cédric Bosdonnat Date: Tue Nov 27 09:32:19 2012 +0100 Missing equality check in BaseSession::operator= commit 8837275b38d496f3f92ae5d12be88ce5b70bb286 Author: Cédric Bosdonnat Date: Mon Nov 26 17:26:15 2012 +0100 mockup test: not a POC any longer, so change names commit c55c8e364fbc6d1dfaa85c96fb6fe1db698e583c Author: Cédric Bosdonnat Date: Mon Nov 26 17:11:02 2012 +0100 First simple test with mockup is working commit a6d42ec9c55e8eab6e5cf2e7dbd1421a0ea1f7e6 Author: Cédric Bosdonnat Date: Sat Nov 24 22:52:19 2012 +0100 Started to create a libcurl mockup to have better unit tests commit f2d21a2336b0a3203243717b0c9f6b7338a4b8ad Author: Cédric Bosdonnat Date: Fri Nov 23 23:49:33 2012 +0100 Extracted tests in qa folder commit 90dc202e5cb5d80b73c40145dcac792bfc5dabbd Author: Cédric Bosdonnat Date: Tue Nov 20 16:58:57 2012 +0100 Started implementing a shell script to test all operations on various servers The goal of this script is to have on test scenario to run against various servers to spot the server-specific implementation problems. commit 7cc3c8205652e1be4c231b0bb6c3a0562a4403b7 Author: Frederic Bor Date: Mon Nov 19 16:55:24 2012 +0100 Some optimizations related to createDocument commit 632b671e46cfc50318ee58c684975551c2d9132a Author: Cédric Bosdonnat Date: Thu Nov 15 13:52:06 2012 +0100 parse dateTime now handles invalid strings commit 16fa14ee9c328b1d3d67e2e7e5915ad65bb86f51 Author: Cédric Bosdonnat Date: Thu Nov 15 13:10:35 2012 +0100 Some more NULL pointers verifications commit 6e89f59e373da814a970ee22f5049274c5bbedbb Author: Cédric Bosdonnat Date: Wed Nov 7 13:57:02 2012 +0100 Soap binding: safer content output Getting a char* from a temporary string object isn't a good idea as we aren't sure what the pointer will point to later. commit 2965de85c937be11dfbed6c3c42b96b46720ac85 Author: Cédric Bosdonnat Date: Wed Nov 7 10:04:32 2012 +0100 WaE: fixed warnings reported with gcc/g++ 4.7.1 commit b217ee82214edbd84bce27953eae342686289e41 Author: Cédric Bosdonnat Date: Tue Nov 6 17:05:46 2012 +0100 Added some checks for NULL values commit 5463c8444e1fe41b22af1c9db9132ef3fee5e43c Author: Cédric Bosdonnat Date: Sat Oct 20 18:44:03 2012 -0700 Print allowable actions in toString if possible commit d245ad91d964a66880b40359a4335c4ec61f7556 Author: Luboš Luňák Date: Mon Sep 17 14:51:51 2012 +0200 Prevent clashes with some windows.h definitions commit 15194151431ce9af7f2d9881422897881b242807 Author: Cédric Bosdonnat Date: Mon Sep 17 14:04:12 2012 +0200 Fixed some more warnings commit 0348a0b77aad18a871cb4179a6a001f868ee2aa4 Author: Cédric Bosdonnat Date: Mon Sep 17 10:09:36 2012 +0200 fixed cppcheck errors commit 0b60c1e4dde7d82ff707c560132454df6a5a8c0e Author: Cédric Bosdonnat Date: Fri Sep 14 10:03:57 2012 +0200 Raise more warnings and fixed them commit c20c3531175677c242c49c68011a37cfee898750 Author: Cédric Bosdonnat Date: Fri Sep 14 09:32:10 2012 +0200 Forgot to remove now useless files commit f0903b355ec26d218833525c41ec235737811be1 Author: Cédric Bosdonnat Date: Thu Sep 13 14:06:08 2012 +0200 Updated NEWS commit 3122aa64eb0bca31bbba3973aa1db686b0691f3b Author: Cédric Bosdonnat Date: Thu Sep 13 13:42:35 2012 +0200 Add Document::getAllVersions and its unit tests commit 6dc474e9e7422609ff9038f2c391a831d46f0c90 Author: Cédric Bosdonnat Date: Wed Sep 12 16:22:00 2012 +0200 fixed libcmis-c library name to be libcmis-c instead of libcmis_c commit b2b0f7b2d238386d286dbde96401eb633b93f332 Author: Cédric Bosdonnat Date: Wed Sep 12 14:07:48 2012 +0200 fixed make distcheck: clean some files and fix the libcmis-c build commit d0c5f6df9352f3bc3e46c833473c06c862afa37d Author: Cédric Bosdonnat Date: Wed Sep 12 10:49:36 2012 +0200 fixed run-test.sh execution in make distcheck commit 1f5d6de81801573620712f10bb6b536ad0ba7aaf Author: Cédric Bosdonnat Date: Tue Sep 11 17:06:23 2012 +0200 bumped -version-info to 3:0:0 commit 932ef9bfd0b338e73f95a8a9281406e0529ca59d Author: Cédric Bosdonnat Date: Tue Sep 11 16:34:55 2012 +0200 Completed NEWS file commit 12a29492172a34ff6ed07ea22b8c14bb88105d17 Author: Cédric Bosdonnat Date: Tue Sep 11 16:17:47 2012 +0200 Added filename to the content stream operations and fixed SharePoint checkin SharePoint checkin requires to have no stream in the checkIn call, but set the content stream on the PWC. If we get that exception, then try out the SharePoint way to do it. Added the filename parameter in createDocument, setContentStream and checkIn as I first though that may fix the SharePoint problem. commit b12d470a2fda1fff14cf56b50c5418427adfe045 Author: Cédric Bosdonnat Date: Mon Sep 10 17:40:03 2012 +0200 cmis-client fixed checkIn: the file wasn't properly provided commit b3c2fb5b0ac7dd3db96a1f571fde243ac895b13f Author: Cédric Bosdonnat Date: Mon Sep 10 17:38:36 2012 +0200 API fix: checkin needs to return a document Some servers like Alfresco have a different ID for the object with the new version. commit b628d6c321459a4ead9e07a6672fe306e5c4fa8c Author: Cédric Bosdonnat Date: Mon Sep 10 15:01:41 2012 +0200 url-decode the part id in xop:Include href attribute commit 34c3400aa67d1d6e32e9e4c53dff39ea9a91abd2 Author: Cédric Bosdonnat Date: Mon Sep 10 14:06:34 2012 +0200 xcmis.org sends back text/xml responses to Soap requests... support them now commit 6744da06a787081ea26bedb95a87f60aefc4e197 Author: Cédric Bosdonnat Date: Mon Sep 10 13:39:02 2012 +0200 Fixed obsolete comment commit 888c9385d582631455f58b741331c4ec87da9f58 Author: Cédric Bosdonnat Date: Fri Sep 7 18:44:40 2012 +0200 Fixed multipart/related parsing received from SharePoint commit fb0182e93eba9105d5fab23b282d5a389770b6a5 Author: Cédric Bosdonnat Date: Fri Sep 7 18:25:49 2012 +0200 Fixed RelatedMultipart for SharePoint to parse it properly commit 42e09dbfb55d6b1ca046fba51e3e275dd2d69e1c Author: Cédric Bosdonnat Date: Thu Sep 6 17:53:44 2012 +0200 updated NEWS file commit 7151924bd1b548a97c5329d3e5766ddf7038ad7e Author: Cédric Bosdonnat Date: Thu Sep 6 17:45:47 2012 +0200 SessionFactory: got rid of that stupid param map for creating sessions commit edaf7ffe17b3979469789f706b7e7cf899990e6f Author: Cédric Bosdonnat Date: Thu Sep 6 17:15:17 2012 +0200 Make the -r parameter optional if there is only one repo on the server commit 6189752de75f760a76b6b502fabb65f696bd0e56 Author: Cédric Bosdonnat Date: Thu Sep 6 16:39:04 2012 +0200 SessionFactory now can decide alone whether to create Atom or WS Session commit ecc21a39219d0c81e212ff190d28d205a3f25451 Author: Cédric Bosdonnat Date: Thu Sep 6 13:51:31 2012 +0200 WSSession: turn all services into members to avoid creating them often commit 50d644e2092e3bb34dfd3b85c26c661e2531955d Author: Cédric Bosdonnat Date: Thu Sep 6 13:39:41 2012 +0200 Implemented WSDocument::checkIn and its test commit d253fce091467ec6b7187055ab6d61345d0ddf1e Author: Cédric Bosdonnat Date: Thu Sep 6 11:31:00 2012 +0200 Implemented WSDocument::cancelCheckOut and its test commit 766e075732786c92220131eab8eaca80db6d4819 Author: Cédric Bosdonnat Date: Thu Sep 6 11:19:03 2012 +0200 Implemented WSDocument::checkOut and its test commit dd8bdad46b08663b9473a4cc99bdc91ec3a0905e Author: Cédric Bosdonnat Date: Thu Sep 6 10:35:21 2012 +0200 Implemented WSFolder::createDocument and its test commit 79f80cdaba18c7e1dee35e217064321524466875 Author: Cédric Bosdonnat Date: Wed Sep 5 17:52:40 2012 +0200 Implemented WSDocument::setContentStream The common part to send a document stream is in a writeCmismStream( ) function so that it could be used by createDocument and checkIn. Fixed the RelatedMultipart parsing to strip the '<' and '>' of the content-Id's in case there are some as this would prevent to match thexop:Include href and the corresponding part. commit 5d98e9473acc3129b3b778ed3cc7c4f03151d1c4 Author: Cédric Bosdonnat Date: Wed Sep 5 10:27:10 2012 +0200 Implement WSFolder::createFolder and is unit tests commit 2c399e3ad9e56edbda80b8b703ada1cd1ce24f1e Author: Cédric Bosdonnat Date: Tue Sep 4 17:05:15 2012 +0200 Implemented WSFolder::getChildren( ) and its test commit ea24f5d4d7cdff7f33215ffce7d18f72971a6bd7 Author: Cédric Bosdonnat Date: Tue Sep 4 15:59:38 2012 +0200 Implemented WSDocument::getFolderParents and its tests commit d96a641f4e7fd2355e446ac7ffa6263d897fcd0c Author: Cédric Bosdonnat Date: Tue Sep 4 14:44:55 2012 +0200 Implemented WSObject::move and its test. NB: the unit test fails due to WSDocument::getParents not being implemented ATM. commit a7ec3188863f5c6feeabc7d263a668c15bcafad1 Author: Cédric Bosdonnat Date: Tue Sep 4 14:03:17 2012 +0200 Implemented WSDocument::getContentStream commit acc5f2fd928169681caa21735a8485acee04cdda Author: Cédric Bosdonnat Date: Mon Sep 3 17:37:08 2012 +0200 WS binding: implemented getObjectByPath commit ad742f453d5e251dd9444a45bdef3c18385d8bb4 Author: Cédric Bosdonnat Date: Mon Sep 3 10:53:00 2012 +0200 WS binding: implemented Folder::removeTree commit 297cf8add3b3814f321aad8dec22c09c09271cbd Author: Cédric Bosdonnat Date: Fri Aug 31 17:18:32 2012 +0200 Added WSDocument creation in getObject and the corresponding tests commit 1c25e90a5181263d2a96abf6e17f15254677292c Author: Cédric Bosdonnat Date: Thu Aug 30 17:07:18 2012 +0200 Added WSFolder and created it in getObjectResponse commit 9f75e2e61bd772b083380bdf41aeb4eb43d81bc6 Author: Cédric Bosdonnat Date: Tue Aug 28 16:22:21 2012 +0200 Moved common parts of AtomDocument and AtomFolder to Document and Folder This is to prepare the arrival of the WS Document and Folder implementation. commit b9459e85ae7a4a91dbde202f77bd3cddfae2a427 Author: Cédric Bosdonnat Date: Fri Aug 24 11:46:04 2012 +0200 WebService: implemented Object::remove commit c8a6957c81a908c420a6562c1ed4a5fbf621712f Author: Cédric Bosdonnat Date: Fri Aug 24 11:13:57 2012 +0200 Object::updateProperties: update with the properties given as parameter This will fix the API problem forcing us to push all the properties of the object during updateProperties (even the ones that didn't change). commit 121cd97f661aa92c9080666e43cb92e8ee38b3ee Author: Cédric Bosdonnat Date: Fri Aug 24 07:40:13 2012 +0200 WebService binding: implement updateProperties The Object::updateProperties( ) API isn't really good: pushing all the object properties to the server may have some bad aspect. For example, when adding an unchanged cmis:name to the request, the server may try to rename the object with the same name... and throw an exception. commit 1fafc8cb21515166c2784dd1793858cedccda556 Author: Cédric Bosdonnat Date: Wed Aug 22 09:16:27 2012 +0200 Object::updateProperties should return the updated object Section "2.2.4.12 updateProperties" of the CMIS specifications says that the returned object may be different from the input one... we need to reflect this in the API as well. commit 9f4c39ffb74ecccc3af38315a3270d511504ea1f Author: Cédric Bosdonnat Date: Mon Aug 20 05:13:10 2012 +0200 Added unit test for WSObject construction commit c1df131ec7ea5313547bd8f1722b0e4610f0119e Author: Cédric Bosdonnat Date: Mon Aug 20 04:51:53 2012 +0200 Object: merged the m_session members of Atom and WS classes commit 4436c0e06941d374c464ebe8395e14d8278d79f2 Author: Cédric Bosdonnat Date: Fri Aug 17 18:15:11 2012 +0200 WebService binding: added ObjectService and WSObject Started AtomObject refactoring to extract the common bits commit 5ab06c01aa58569e6f6c0edd61d4f8e321269d28 Author: Cédric Bosdonnat Date: Fri Aug 17 16:44:12 2012 +0200 Soap binding: added getTypeChildren and its unit test commit 51ba78dfae5d82b97031cb7bf5aa43728a27e361 Author: Cédric Bosdonnat Date: Fri Aug 17 14:31:20 2012 +0200 Added C wrapper and unit tests for Object::move commit d23da90759923bcddf7fe330f6df02c4d81e13ba Author: Alexander Slipchenko Date: Thu Aug 16 18:29:13 2012 +0300 implementation of moveObject service commit 57b5ed7ce1111d1065718de2a6e67aaaaa0d7eb9 Author: Alexander Slipchenko Date: Thu Aug 16 17:51:45 2012 +0300 fix extractInfos. extractInfos did not overwrite object state from the given xml - this causes problems for e.g. the move functionality because parent and path should be updated from service response. commit e3a97126787fb722119819086068d62281e8f898 Author: Alexander Slipchenko Date: Thu Aug 16 17:40:47 2012 +0300 interop with xcmis: ignore spaces in link type attribute commit 4aaaf87891ddfdef4fc443b163c7cd05b40c92de Author: Alexander Slipchenko Date: Thu Aug 16 14:34:55 2012 +0300 fix Cloudoku too many redirects error commit 64e9060c0cefef22277c1d69908ac5ed57d69ee1 Author: Cédric Bosdonnat Date: Fri Aug 17 10:19:28 2012 +0200 WS binding: added the getTypeDefinition implementation This needed a code refactoring to get the common bits between Atom and WS bindings. commit 5d1f22b3b3a70bc1f2fb0e3d41144344bbf143df Author: Cédric Bosdonnat Date: Thu Aug 16 12:32:51 2012 +0200 tests: don't download the server pieces if we don't need them commit 39dfe01cf28007010bf3257c23ec6268e2a77ceb Author: Cédric Bosdonnat Date: Thu Aug 16 12:08:53 2012 +0200 Testing: allow to disable the tests needing a running server only This will allow to run the unit tests that don't need the running server during the packaging process and run the others during the development process. See the --disable-long-tests configure option commit 8a91b159e20d8050c366bd36fb4de194397e5770 Author: Cédric Bosdonnat Date: Thu Aug 16 11:05:21 2012 +0200 Added a type string to libcmis::Exception Getting that error type from the AtomPub binding isn't easy as some HTTP status codes are mapped to several exception types, but this is used in the WebService binding. commit 59278289168ebf69a083e5666b40ca284e9c3b02 Author: Cédric Bosdonnat Date: Mon Aug 13 11:15:45 2012 +0200 libcmis-c: forgot libcmis_folder_getPath unit test commit 08c9bd67ad5d7ea28f2b547c50d54bbe52d8c70f Author: Cédric Bosdonnat Date: Mon Aug 13 11:13:31 2012 +0200 libcmis-c: added document and folder casts from object commit 688a4ffbf9bdfde3743aba54778fa023bea4fb0b Author: Cédric Bosdonnat Date: Fri Aug 10 18:02:24 2012 +0200 libcmis-c: added folder createDocument and its unit tests commit 90d0ad8826d6cb261f1879fa28a53c2ce0ca6c68 Author: Cédric Bosdonnat Date: Fri Aug 10 17:43:30 2012 +0200 libcmis-c: added Document checkin and its unit tests commit f961a15f1449a1ad27f78aba69a86cf66066f599 Author: Cédric Bosdonnat Date: Fri Aug 10 17:11:47 2012 +0200 libcmis-c: added document setContentStream and its tests commit 1f0809297e9f3fb057b1c3c39c15c0eba35aea74 Author: Cédric Bosdonnat Date: Fri Aug 10 15:40:36 2012 +0200 libcmis-c: added document getContentStream and its tests commit 18d43c4afcaae3fd043da5079abd37f9156287ac Author: Cédric Bosdonnat Date: Fri Aug 10 11:57:00 2012 +0200 libcmis-c: add document without stream support commit 91a3dc3389610baa5d223a545bf535decf76990b Author: Cédric Bosdonnat Date: Fri Aug 10 10:23:37 2012 +0200 libcmis-c: added extern "C" blockon headers to link from pure C code commit b6e8f77eb99760c4aa58afdcfd145872749e8b36 Author: Cédric Bosdonnat Date: Fri Aug 10 10:22:59 2012 +0200 Build silently if AM_SILENT_RULES is defined commit bb551a9084f093ba22abfb5b3355414420e21605 Author: Cédric Bosdonnat Date: Thu Aug 9 18:15:56 2012 +0200 libcmis-c: test compilation and link in C Refactored vector types names while fixing them for C compilation commit 4b2a84ad0a2eb2fbf976555ec6551d5c8bc96ee1 Author: Cédric Bosdonnat Date: Thu Aug 9 16:33:06 2012 +0200 libcmis-c: added folder unit tests commit 6d77ff9fb8ac493d118b2e001648a1a07a2812ea Author: Cédric Bosdonnat Date: Thu Aug 9 12:22:06 2012 +0200 libcmis-c: added unit tests for object commit 1ba2d9dd53d88c13578a3fe6e7a85bc663425b24 Author: Cédric Bosdonnat Date: Wed Aug 8 17:15:07 2012 +0200 libcmis-c: copy the strings, and have them free'd This will help libcmis-c to keep indenpendant from the string management of the libcmis implementation: each time we give a string to the user it's strdup'ed, but the user needs to free it. commit 2026b382244dbdbf75dd48cdb5ef6720d8f30d08 Author: Cédric Bosdonnat Date: Wed Aug 8 17:03:02 2012 +0200 libcmis-c: added unit tests for AllowableActions and ObjectType commit b7101af8d5ed14d8f397b40c19463a3e639bed89 Author: Cédric Bosdonnat Date: Wed Aug 8 10:42:18 2012 +0200 libcmis-c: completed unit tests for property commit 8c7af53b077f27a0d83a742859bdfa7d8bc5f3d0 Author: Cédric Bosdonnat Date: Tue Aug 7 18:40:31 2012 +0200 libcmis-c: added unit tests for property Added libcmis_vector_* types to ease handling the mapping of vectors to C commit be45299327728ce7eb7e84c67c508c809ab56890 Author: Cédric Bosdonnat Date: Tue Aug 7 14:32:01 2012 +0200 libcmis-c: unit tests for PropertyType commit 9b0b07292e0f8a411edd305e7ed456802f6d4231 Author: Cédric Bosdonnat Date: Tue Aug 7 11:17:56 2012 +0200 libcmis-c: added foundations for Document commit f5f788f513461a261a2a9e060b2fee28f624af26 Author: Cédric Bosdonnat Date: Tue Aug 7 11:16:48 2012 +0200 libcmis-c: added unit testing for Repository commit a68ddf8f3314b04e0e36d8976ca2036ed2ecc17a Author: Cédric Bosdonnat Date: Tue Aug 7 09:17:32 2012 +0200 libcmis-c: added Folder commit 21afc7c13aa45c1925ff53842b911bf525a877b4 Author: Cédric Bosdonnat Date: Mon Aug 6 17:31:23 2012 +0200 libcmis-c: completed Session commit 73cc1758958595db2e83cd2f0387af316e4dea6a Author: Cédric Bosdonnat Date: Mon Aug 6 17:02:09 2012 +0200 libcmis-c: added Property commit 341d258b4dfc9e76c9d06a506d722251b28a7ccf Author: Cédric Bosdonnat Date: Mon Aug 6 13:40:54 2012 +0200 libcmis-c: added PropertyType commit a79f77063b0f4a9681a4472852ca35c4a24eb2ed Author: Cédric Bosdonnat Date: Sat Aug 4 11:56:48 2012 +0200 libcmis-c: added Object, ObjectType and AllowableActions commit 9dbee4f9612a9a7b9652dd708c56660b8503c998 Author: Cédric Bosdonnat Date: Fri Aug 3 16:05:47 2012 +0200 Started libcmis-c wrapper for use of the library in C programs commit 37c28b19d579e6d91cbb50ca42a38196d33019c5 Author: Cédric Bosdonnat Date: Mon Jul 9 17:39:02 2012 +0200 removed some warnings commit 64b395df637a3680bbdb96f39e6c110cbd59316e Author: Cédric Bosdonnat Date: Thu Jul 5 12:19:45 2012 +0200 SessionFactory::getRepositories, now returns repository objects instead of id commit c8cc343414da65bbe8a766a02844971071d20d48 Author: Cédric Bosdonnat Date: Tue Jul 3 17:01:24 2012 +0200 Allowable actions: read them directly with the object The original aim of this patch is to workaround Alfresco's bug where allowable actions aren't correct when extracted from the Atom entry link. It turns out that this fix is also a nice refactoring allowing to share the allowable actions parsing code between Atom and SOAP bindings. We are also avoiding one more HTTP request when getting an object! commit 2f1d9ea75bba37ce43644ad751e4613815ead4d5 Author: Cédric Bosdonnat Date: Mon Jul 2 14:45:36 2012 +0200 Atom: Document::getPaths() could throw exception when getParents() is not allowed commit 80e2cec16f08b0d5e5c31816e6b18a3c11cbde31 Author: Cédric Bosdonnat Date: Mon Jul 2 10:04:49 2012 +0200 Fixed build errors commit c7b00511e21c9fba1b3e8ddcae4e54add9578129 Author: David Tardon Date: Sat Jun 30 17:18:26 2012 +0200 coverity: return value is destroyed when it exits scope commit 4ffef50019695334d253837cbc5355a0100515ad Author: David Tardon Date: Sat Jun 30 17:04:06 2012 +0200 coverity: protect against self-assignment commit a689e398280ebf5147591c529742d50051a431a7 Author: David Tardon Date: Sat Jun 30 16:51:36 2012 +0200 coverity: possible null dereference commit 33f39fff73a3a858057499e4500c55a592bb8534 Author: David Tardon Date: Sat Jun 30 16:41:50 2012 +0200 coverity: operator= should return non-const ref commit 8df9b5df6ef614ea29a5d2b70114942b5796ebad Author: David Tardon Date: Sat Jun 30 16:37:04 2012 +0200 set language for configure checks Otherwise tests for mode_t and size_t fail here, which results in size_t and mode_t defines on compiler command line, which breaks the build. commit d8bfaaedb4238be14e742b2bfcbfab25ca8567c9 Author: Cédric Bosdonnat Date: Tue Jun 26 10:20:31 2012 +0200 WebService: Use PasswordDigest as specified in WS-I Security Profile See sections 11.1 and 11.3 of WS-I Security Profile 1.0 specification commit 8f8ce16a86d2f0ef2b0a3c9b3c726ef21c1e8905 Author: Cédric Bosdonnat Date: Mon Jun 25 21:28:33 2012 +0200 WebService: fixed the SoapFault processing Here are the changes: * Don't throw CurlException instead of SoapFault. * Added support for fault detail (and cmism:cmisFault detail tag) commit 07cf8bd021640aa6bb2824019cd0829382de2243 Author: Cédric Bosdonnat Date: Thu Jun 21 17:09:53 2012 +0200 Web Services binding: implemented RepositoryService::getRepositoryInfo() This also was the occasion to move the repository infos parsing code to the libcmis::Repository class: this way it benefits both Atom and WebService bindings. commit ed80072ec4ea7302fd36a8e77696f4ec90c0a9b9 Author: Cédric Bosdonnat Date: Thu Jun 21 14:08:34 2012 +0200 Update NEWS file commit b936d117b3b2f366db25334b3a053b0173adb767 Author: Cédric Bosdonnat Date: Thu Jun 21 14:04:06 2012 +0200 Wired pieces together to get SOAP request executed and parsed. Needed changes: * all BaseSession::http*Request methods are now returning a libcmis::HttpResponsePtr containing both the data and HTTP headers * SoapResponses now need the RelatedMultipart object in case there is an attachment to read insise. * WSSession::getRepositories() is working commit 5303784a19126fc70a6a75caf5cc4b9ab50ef6da Author: Cédric Bosdonnat Date: Wed Jun 20 18:32:27 2012 +0200 Started implementing SOAP requests Started implementing RepositoryService::getRepositories, reading and writing SOAP envelopes. As libcurl is not capable to send proper multipart/related content, I had to implement parsing and dumping those. Warning: the whole chain is still not working. commit 634ce90a5fe337745c5b92dac06ea36ee544ec1e Author: Cédric Bosdonnat Date: Fri Jun 15 18:28:41 2012 +0200 WebService binding: initial session implementation WSSession can read the Service URLs from the WSDL file. ws-soap.{hc}xx contains the base logic to generate and parse SOAP messages while ws-requests.{hc}xx contains the CMIS-specific requests and response objects. ATM no service is implemented. commit 2e81df09be4ee0f1592fe9705a48b9036f2bc708 Author: Cédric Bosdonnat Date: Fri Jun 15 10:44:54 2012 +0200 Create a libcmis::Repository API to extract repository infos commit 56ff28be3742e6110936f142d79d6bd5ac8cc81c Author: Cédric Bosdonnat Date: Thu Jun 14 16:48:16 2012 +0200 Split the AtomPubSession in pieces to share with a future WSSession commit 1aad1a7092fba2bb3b78d301c40a33de2aec3368 Author: Cédric Bosdonnat Date: Thu Jun 14 14:23:03 2012 +0200 getChildren: support paged results commit a4d6f4416938e3522dbc366eedc77920d411b479 Author: Cédric Bosdonnat Date: Thu Jun 14 14:22:25 2012 +0200 cmis-client: return 1 on all errors for easier scriptability commit 05178b8c54fd3a381b0e04457b6430323061548b Author: Cédric Bosdonnat Date: Wed Jun 13 17:42:06 2012 +0200 Added Document::checkIn() commit cecf98b5667842c226e9c64105611014551eb8d8 Author: Cédric Bosdonnat Date: Mon Jun 11 20:21:45 2012 +0200 Added Document::cancelCheckout The Unit test for cancelCheckout needed to update InMemory server to a more recent version due to a bug on the server side: update to 0.7.0 commit dd7135c79a80dfc9a71030b5bde68f2931e819fa Author: Cédric Bosdonnat Date: Mon Jun 11 14:21:29 2012 +0200 checkout: fixed it to work for SharePoint commit 7bba87b0496b7d480844538b271f1dee76571ed5 Author: Cédric Bosdonnat Date: Fri Jun 8 18:49:51 2012 +0200 Implemented checkout commit d36a1a935f51916ed4263356bea34cef4a547e2e Author: Cédric Bosdonnat Date: Fri Jun 8 12:44:59 2012 +0200 setContentStream: SharePoint wants base64 encoded content In order to satisfy SharePoint and not break the others, first try to send raw data, and send base64 encoded data only if we got a 400 error. SharePoint also sends a 302 with a Location pointing to an error page when setting content on a non-checkout document: handled all non 2xx statuses as errors. commit 70c820eb62598e5818f7930e598aa2aa4e4ed733 Author: Cédric Bosdonnat Date: Thu Jun 7 11:53:41 2012 +0200 setContentStream: url-encode request params as changeToken is an obscure string commit c10d190b208cdecf9729aa482b5ef2e6cf7e7daf Author: Cédric Bosdonnat Date: Thu Jun 7 11:26:41 2012 +0200 SharePoint: some links have no type, fixed how these are handled commit 36d1027c77216ab823d4c00dc5b4e3b1bf085b7f Author: Cédric Bosdonnat Date: Wed Jun 6 18:09:06 2012 +0200 SharePoint repository id is case insensitive It may not be the best thing to do to always check lowercased strings as IDs are obscure strings commit 321b2dc94b07031b79e0f2932877be1195d02a44 Author: Tomas Chvatal Date: Wed Jun 6 11:08:07 2012 +0200 Add libs/includes that are required when we try to build against cmis and use pc file. commit e351df6bb4c05d2cffa4f3a22688f04e9a83f8f4 Author: Tomas Chvatal Date: Wed Jun 6 11:03:29 2012 +0200 Create the manpage conditionaly, and also install it when needed. Signed-off-by: Tomas Chvatal commit a9e6c907077486b70760e4b26f5e6e98ac107eb9 Author: Cédric Bosdonnat Date: Tue Jun 5 17:24:12 2012 +0200 base64 encoder: fixed signed values encoding The problem is typical the following. Encoding 0x3F 0xEB 0xEF, the values for 0xEB and 0xEF were used as negative values. Casting to an unsigned char will give us the proper 0xEB and 0xEF values to be used in the base64 encoding algorithm. commit f385049ffc9a249e79c71def5804d2cd3da92ebd Author: Cédric Bosdonnat Date: Mon Jun 4 20:39:39 2012 +0200 libcurl version test was wrong... commit 10c765aec2c09fd5746464d5d8c33f19d18e0035 Author: Cédric Bosdonnat Date: Mon Jun 4 18:48:54 2012 +0200 Fixed soname to fit library version commit fed9ebdaa185ab31fe074f18cc6556f2ae73eb4a Author: Cédric Bosdonnat Date: Mon Jun 4 18:40:44 2012 +0200 Changed soname commit a1e2772541ab039c356b09ccb49b048e980aa5bd Author: Cédric Bosdonnat Date: Mon Jun 4 18:23:55 2012 +0200 libcurl: use curl_escape and CURLOPT_USERPWD if version is too old commit 0996ff687d2973b03604153ed2f13debf023bc90 Author: Cédric Bosdonnat Date: Mon Jun 4 13:08:17 2012 +0200 Updated NEWS commit 08e174bb9692f2fa2db58918f20c632baf4f08bd Author: Cédric Bosdonnat Date: Mon Jun 4 12:17:10 2012 +0200 Fixed man dist and install once for good commit 21e23936453273bc5c61b809c08f5cdae99059bc Author: Cédric Bosdonnat Date: Mon Jun 4 11:54:25 2012 +0200 Wrong file to put in dist tarball: put cmis-client.xml instead of .1 commit 05159396dae51ef7cfc3c66dc98d78599ab9b4c4 Author: Cédric Bosdonnat Date: Mon Jun 4 11:59:57 2012 +0200 configure.ac: updated version to 0.3.0 commit 826b141ec822d5f2f700ae09edf019aeaea37258 Author: Cédric Bosdonnat Date: Mon Jun 4 10:18:56 2012 +0200 Added getPaths() convenience method in API commit 7e03d66771f1cb4f53dd4a7f35f84b0d59900430 Author: Cédric Bosdonnat Date: Wed May 30 16:31:41 2012 +0200 Updated README to show the remove and removeTree commit 5e05142716cbfe363ab4751c5a951295821208e6 Author: Cédric Bosdonnat Date: Wed May 30 16:30:07 2012 +0200 cmis-client: use removeTree when possible instead of remove commit a684300a90b6ae2451bfd08a69edd9150c51072f Author: Cédric Bosdonnat Date: Wed May 30 16:20:54 2012 +0200 Folder: implemented removeTree This commit also changed a few URLs in AtomFolder to use the link AtomLink API. commit d5cac575828eacdae066b60b7831589ff9ab7de9 Author: Cédric Bosdonnat Date: Wed May 30 16:20:48 2012 +0200 Atom links: removed a few more URLs extraction to use the new links feature commit 8e78ff35ad5179ea9a6e4406ceae73d4c5284354 Author: Cédric Bosdonnat Date: Wed May 30 15:19:02 2012 +0200 AtomSession: made http request helpers clean their stuffs if there was an exception commit 6d82a61b3eaef6d35512c1eaaae12132d5a30f03 Author: Cédric Bosdonnat Date: Wed May 30 15:17:45 2012 +0200 AtomObject: read all links and store them for later use commit d90b3ca57390bbd2c7901172873f53ff4c34a74a Author: Cédric Bosdonnat Date: Tue May 29 14:19:10 2012 +0200 Implemented object::remove() commit ab71ea5785a0993aa4c796e093874ddcb1057d99 Author: Cédric Bosdonnat Date: Tue May 29 11:39:35 2012 +0200 Escaped URLs as the IDs may contain characters that won't fit in URLs Using curl_easy_escape() was requesting a working CURL handle and works only a chunks of URLs. Escaping the URL happens in the URL creation to ease the work (and avoid parsing URLs). This required to move the CURL handle to a session member. Among the impacts of that change: * Removed the duplicated code to get encoded content * Had to reset the CURL handle before the next use commit c2c9fcce71489e8cfa4fce4736b5df155ef202a8 Author: Cédric Bosdonnat Date: Tue May 29 10:50:43 2012 +0200 Fixed createDocument test commit b19548fc7330d6d229cec54a24a34a7b72a54cd5 Author: Cédric Bosdonnat Date: Thu May 24 22:03:28 2012 +0200 Added and implemented Folder::createDocument() commit 0977eeee3e6d38358e7680885ba93cb7375b3f81 Author: Cédric Bosdonnat Date: Mon May 21 17:02:14 2012 +0200 make more sense in the API: ask for output stream to set content commit 52afd052580cefc0286ac3d04ca8dcf4d24513cb Author: Cédric Bosdonnat Date: Mon May 21 17:01:48 2012 +0200 Declared a few missing exceptions commit fc9c2b3da9bddbee6948b2be86780b9da11eee08 Author: Cédric Bosdonnat Date: Fri May 11 23:12:41 2012 +0200 Silenced unused parameter warning commit 0313d7141a59ee58722bc417267196540bf9ef8c Author: Cédric Bosdonnat Date: Fri May 11 22:36:49 2012 +0200 Added rewind support for Put and Post. Define a CURLOPT_IOCTLFUNCTION callback to rewind in multipass authentication cases (i.e for SharePoint or Alfresco) commit fccae8881c39e56c96283cd9cfd35ce46c61af5d Author: Cédric Bosdonnat Date: Fri May 11 21:12:13 2012 +0200 More robust XML parsing cases: allows getting nodes from Alfresco commit 2769d2eba3da597d832448c59d6db143ef15d0ea Author: Cédric Bosdonnat Date: Fri May 11 10:14:53 2012 +0200 Use a provider class instead of a function pointer to the auth callback commit f360f5fd679a10053f9d05512f629368d8373378 Author: Cédric Bosdonnat Date: Thu May 10 17:16:57 2012 +0200 Added a connection callback to allow providing authentication interactively commit 76f6ae95563b82bc7e4e9e1c737c7e0a1ce213ea Author: Cédric Bosdonnat Date: Wed May 9 16:04:16 2012 +0200 Don't use boost and std namespaces at the same time or you may have conflicts commit e12868c1326a88f39149da632c9139359ef61c7d Author: Cédric Bosdonnat Date: Wed May 9 16:03:26 2012 +0200 Added missing header files... to fix make dist commit c3afde2d1129f203d6b07d4c3560f39f03abc540 Author: Cédric Bosdonnat Date: Wed May 9 12:21:20 2012 +0200 Updated LibreOffice dmake script commit a53e29686b8d44ea67ad2b994b8f6b09cda32d23 Author: Cédric Bosdonnat Date: Wed Feb 22 18:48:33 2012 +0100 cmis-client: added update-object command to allow updating object properties commit f5bc867f2430acdd21515f72887944fe7281739e Author: Cédric Bosdonnat Date: Wed Feb 22 16:36:28 2012 +0100 Implemented a Base64 encoder to be used for the document creation requests commit 40c71f5194354d4644a2ae84b8a094dcd4c098f2 Author: Cédric Bosdonnat Date: Tue Feb 21 17:39:12 2012 +0100 Folder::createFolder( ) implemented commit fae5e2b10ce8083e1c71e016cf623b2498a8045b Author: Cédric Bosdonnat Date: Mon Feb 20 14:35:25 2012 +0100 Updated NEWS file for properties update commit e99ad62bf767fc730b17f3501bd71c1df2d09dae Author: Cédric Bosdonnat Date: Mon Feb 20 13:58:32 2012 +0100 AtomObject::getTypeDescription( ) now caching the result to avoid too frequent requests commit c2917dd80d200b1de07b725045457a4211136f93 Author: Cédric Bosdonnat Date: Mon Feb 20 13:54:58 2012 +0100 AtomObject::updateProperties() implementation complete commit 197915b37c33aef8f877c4b5583ff1bceb89863a Author: Cédric Bosdonnat Date: Fri Feb 17 18:45:37 2012 +0100 ObjectType: forgot 2 properties to read commit 424956dff0f9bc6e548b99f8a0f871f5072f0ece Author: Cédric Bosdonnat Date: Fri Feb 17 17:40:44 2012 +0100 Added libcmis::PropertyType to extract more data from the properties commit 3a0649ad390b7feabd95479a1f6846458b458207 Author: Cédric Bosdonnat Date: Fri Feb 17 10:40:44 2012 +0100 cmis-client: added type-by-id command to fetch types commit 4570916c37cc7137ddc4c71ae2b57b19e176d737 Author: Cédric Bosdonnat Date: Thu Feb 16 19:09:27 2012 +0100 code cleanup commit a61932147d2b641775a8593ee6afc2f54c4fdda4 Author: Cédric Bosdonnat Date: Thu Feb 16 19:01:11 2012 +0100 libcmis::ObjectType first implementation commit e4985599ea6bbe8651691c5fac96d2446114d79c Author: Cédric Bosdonnat Date: Thu Feb 16 13:33:00 2012 +0100 Object::updateProperties( ): first implementation - missing readwrite properties filtering commit 778ad539456f965c4ebc4278ae44405f34c5fcd5 Author: Cédric Bosdonnat Date: Wed Feb 15 16:56:52 2012 +0100 Implement object to XML serialization commit 0d7586ce384d75150200dce89c22e5633a2f4952 Author: Cédric Bosdonnat Date: Mon Feb 6 14:17:45 2012 +0100 libcmis::Property::toXml() implemented commit e4aecc2e44f106460e7371dd22af9b2f15318182 Author: Cédric Bosdonnat Date: Mon Feb 6 00:20:46 2012 +0100 Refactored object properties to catch'em all commit 66287244a7dded08e12e1eb9c6a73a48249a0d0e Author: Cédric Bosdonnat Date: Fri Feb 3 15:58:10 2012 +0100 Implemented Document::getParents() commit 53d9cda7f482b97f4233372185fa8be544a7d47a Author: Cédric Bosdonnat Date: Thu Feb 2 20:43:10 2012 +0100 Updated man page to include set-content command commit a0115995fa2b5979d8ba6b7e0b2d230565ff812a Author: Cédric Bosdonnat Date: Thu Feb 2 18:03:48 2012 +0100 setContentStream fixes: send changeToken and mime type in the query commit 2386e2d5325c55d05abd770d9bf00f04b1060d11 Author: Cédric Bosdonnat Date: Thu Feb 2 18:02:53 2012 +0100 cmis-client: added set-content command commit b50786d6a94b8ac72ceb66dc63a81453189812a5 Author: Cédric Bosdonnat Date: Wed Feb 1 12:15:59 2012 +0100 removed unreliable test commit 6b123d6885a729b500b7d3291e8bf72ff5d72433 Author: Cédric Bosdonnat Date: Wed Feb 1 11:30:45 2012 +0100 Added Folder::isRootFolder() commit 410792a504c0e10daff0ad7e888baaf8eaf22b42 Author: Cédric Bosdonnat Date: Wed Feb 1 11:21:15 2012 +0100 Added Folder::getFolderParent() commit 15c442b449230a8d66e2d4f823da76baa9191120 Author: Cédric Bosdonnat Date: Tue Jan 31 18:16:09 2012 +0100 Added a few AllowedActions checks before doing things commit 6c6b6dcb13df5e5950ad81077dc7885aebdb9070 Author: Cédric Bosdonnat Date: Tue Jan 31 18:09:33 2012 +0100 AtomPub: Fixed AllowableActions reading commit 371d6aa0990bb434c6a36344b659ba0644ee9dcb Author: David Tardon Date: Fri Jan 27 17:37:03 2012 +0100 update COPYING.LGPL to v. 2.1 commit bfd463f3ef3b2e372a110b1b3cbe83213abe1c27 Author: Cédric Bosdonnat Date: Fri Jan 27 17:17:05 2012 +0100 Added cmis-client man page commit 77c4049861553f1e2b70293a2da1f26a219d8039 Author: Cédric Bosdonnat Date: Fri Jan 27 11:19:12 2012 +0100 Updated NEWS file commit 7b604c01a9df770e1224cbab13215de533b07391 Author: Cédric Bosdonnat Date: Thu Jan 19 17:43:14 2012 +0100 Read the allowable actions document to help know what is permitted before doing it commit d90c5a6c2ee6c874c4e77b8e578deea7733ff57b Author: Cédric Bosdonnat Date: Thu Jan 19 10:41:33 2012 +0100 Implemented fetching nodes by path commit 85ecb0f3c77e1590014ce0cccfd613865018d0e0 Author: Cédric Bosdonnat Date: Wed Nov 16 11:03:19 2011 +0100 Implemented AtomDocument::setContentStream method commit 0e96644152ed1f275827f68d968c4a4faf80e0b2 Author: Cédric Bosdonnat Date: Tue Nov 15 12:55:55 2011 +0100 Same code for run an HTTP request everywhere commit 729b16fe03d91bd8373113a41a14ed07dd36280b Author: Cédric Bosdonnat Date: Tue Nov 15 12:18:44 2011 +0100 Moved httpGetRequest to AtomPubSession commit 471099b8f81d50c1534f940af895d91043fa3b9b Author: Cédric Bosdonnat Date: Tue Nov 15 11:45:28 2011 +0100 AtomPubSession::getRepositoriesIds to reuse service document handling The AtomPubSession constructor is fetching and parsing the service document: let's reuse that code for getting the repositories as well. commit 7b0175accf158a39c2563faa03cd3604eb64af87 Author: Cédric Bosdonnat Date: Mon Nov 14 10:06:48 2011 +0100 added API for setContentStream, implementation still missing Reworked the ServiceDocument parsing to ease the move of the httpGetRequest inside the AtomPubSession class. commit de493152741862d7e519abd7d013dc4d709164fa Author: Cédric Bosdonnat Date: Fri Nov 4 11:26:38 2011 +0100 Added Document::getContentStream and deprecated Document::getContent This new method uses the C++ I/O libraries and avoids storing the content as a temporary file. This locks the security to access the document data a bit more. The old Document::getContent method is kept only for compatibility with LibreOffice libcmis usage and will be removed when that code will be updated. Exceptions cleanup: provide better messages in the libcmis::Exception. commit e98747ecc977a996c1a3de55734a189d9092c01c Author: Cédric Bosdonnat Date: Thu Nov 3 22:10:46 2011 +0100 Document: add a C++ stream getter for the content to avoid temp files commit 2aa545f4200dcb9b835779017a7c01b0b356af5b Author: Cédric Bosdonnat Date: Thu Oct 27 18:14:00 2011 +0200 added verbose option to ease debugging commit 29da344391cb93cc6f5ddfc1a51a44eab3a34032 Author: Cédric Bosdonnat Date: Thu Oct 27 17:21:50 2011 +0200 Added libcmis::Exception with message for better user feedback The error message reports libcurl error messages. Libcurl is also now failing when an HTTP error more than 400 is reported (though it doesn't affect authentication). commit e56107d1bf06a65d7765a61f822d8d2275a560d0 Author: Cédric Bosdonnat Date: Wed Oct 26 15:50:13 2011 +0200 cmis-client: print help for unknown command commit edc2fc6415ef025829fcbd1e77239990811f92c0 Author: Cédric Bosdonnat Date: Sat Oct 22 07:30:16 2011 -0700 Added more unit tests for getFolder() and getObject() commit 284eeb6453963c80be1cbe8ef26cbe9bf7c8a6e9 Author: Cédric Bosdonnat Date: Thu Oct 20 14:40:21 2011 +0200 Actually filled the NEWS file commit 36c70303eacc45b90e6e4941859df130cecd75b0 Author: Cédric Bosdonnat Date: Wed Oct 19 17:25:48 2011 +0200 test-decoder.cxx: mention the source of the Base64 test values. commit 68f218f3866a05db77b3e7c27b19169c36c6e13f Author: Cédric Bosdonnat Date: Wed Oct 19 17:22:10 2011 +0200 Content extraction: decode base64 encoded transmitted files This feature is needed for SharePoint implementation of CMIS. commit 2aa6e964fdee4b5c6d14418ae59015a3708b62ec Author: Cédric Bosdonnat Date: Tue Oct 18 17:34:22 2011 +0200 Added authentication support, delegates the method choice to libcurl commit 9e393ab0201086819998b0343389a28aabc3fa62 Author: Cédric Bosdonnat Date: Fri Oct 14 01:28:41 2011 +0200 cmis-client: added show-root command commit 5872b14537e7ff2ae675c16a05757a90a05cb9f6 Author: Fridrich Štrba Date: Sat Oct 8 15:42:55 2011 +0200 Define CmisObject and CmisObjectPtr for temporary backward compatibility commit e7283f6750e3e1a36fbfde842f21594b5b8dc7cd Author: Fridrich Štrba Date: Sat Oct 8 15:28:56 2011 +0200 Some fixage of pkg-config stuff and includes commit 6a939b9e33ff5d5ef470aba62b5e6dc93f86bd84 Author: Cédric Bosdonnat Date: Thu Oct 6 15:19:59 2011 +0200 Fixed version scheme commit de3b3ab93948c5623565175a7552855d5a59deb1 Author: Fridrich Štrba Date: Thu Oct 6 13:39:28 2011 +0200 Trying to make -Weffc++ build link commit c9c7cccd592499bb8d95184a5ad14b19a6d0935a Author: Cédric Bosdonnat Date: Thu Oct 6 13:13:01 2011 +0200 libcmis::Object: added the possibility to refresh the data in the API commit 822840832921b03f12511d747b39cea34aca023a Author: Cédric Bosdonnat Date: Thu Oct 6 12:31:29 2011 +0200 Fixed the warnings when building with -Weffc++ commit 0c1794a03e90cb3c6bb6d861112089cea1fa68e2 Author: Cédric Bosdonnat Date: Wed Oct 5 16:15:56 2011 +0200 -with-libxml2 is now useless commit adf6d2ca7fd3e771590ff22e24275e33f5bef481 Author: Fridrich Štrba Date: Wed Oct 5 16:10:49 2011 +0200 reverted libcurl checking to pkg-config commit 27ae1df24734577fb56e0524ca585b47d09f098e Author: Cédric Bosdonnat Date: Wed Oct 5 15:36:17 2011 +0200 Revert libxml check to pkg_config for windows cross-building commit 84d368a23315f81193bec057704adfbefba79b9c Author: Fridrich Štrba Date: Wed Oct 5 15:20:39 2011 +0200 dmake file for building libcmis in LibreOffice commit 8d809f7f53e152f0b0af714717f7b717a913cba9 Author: Jan Holesovsky Date: Wed Oct 5 11:41:20 2011 +0200 Introduce --with-libxml2, to be able to set the right prefix. commit 47286032a5d29d9e865d4ca2fee986d1825587c4 Author: Cédric Bosdonnat Date: Wed Oct 5 11:20:47 2011 +0200 Object: get all the mandatory properties commit 199133863e2b116f8cb0f8ccc4479252436ee049 Author: Cédric Bosdonnat Date: Tue Oct 4 15:44:19 2011 +0200 Renamed the stupid CmisObject to Object: no confusion possible with namespaces commit f071d7b720fa9c24ac6cdd4b22e365c847fba374 Author: Cédric Bosdonnat Date: Tue Oct 4 12:21:48 2011 +0200 Fixed the LGPL licence file commit d4285bd08ed308a96016fc9a7716424d1062d486 Author: Dominique Leuenberger Date: Tue Oct 4 10:47:03 2011 +0200 m4: Use x in order to avoid variable 'x' set but not used [-Werror=unused-but-set-variable] This error could be caused by configure scripts being run with -Werror -Wall, which would lead to libcurl being detected as unusable. commit be66250ad9c2b10a74364aad18927d6b213aa1cf Author: Miklos Vajna Date: Mon Oct 3 19:00:05 2011 +0200 Spelling fixes commit 7cd26ce3e85374aa9db812760edea78ff97a0ff9 Author: Cédric Bosdonnat Date: Mon Oct 3 16:52:12 2011 +0200 Removed dead code commit 904b4fd3a97f3ec0b8247cbab50cfdd9179c7893 Author: Cédric Bosdonnat Date: Mon Oct 3 15:28:03 2011 +0200 Added a configure --disable-tests switch to skip tests build commit 803cbdb6b3c7105f28bdf3d72ca87c27f4e4c564 Author: Cédric Bosdonnat Date: Mon Oct 3 15:27:45 2011 +0200 Added missing files to the dist tarball commit f8352b06958e1f10eff95bcc589b70c581c987e8 Author: Tomáš Chvátal Date: Mon Oct 3 14:54:41 2011 +0200 Add werror and some gcc flags from libvisio. Whitespace, tabify everywhere. commit cf18961932ba1e62ced469ca844a606dd6abbc14 Author: Cédric Bosdonnat Date: Mon Oct 3 12:09:57 2011 +0200 Make use of BOOST_CPPFLAGS commit 91fcb919b8f8acc1f1142c4506624c5916a2be38 Author: Cédric Bosdonnat Date: Mon Oct 3 10:55:20 2011 +0200 configure: don't check for program_options if client is disabled commit e2d7637080eed924e57ce7b1cfba568a00ec0cf8 Author: Cédric Bosdonnat Date: Mon Oct 3 09:59:28 2011 +0200 configure: use xml2-config instead of pkg-config commit c95aaa42ba9370995b0787f9388a0805e4c272d5 Author: Rene Engelhard Date: Mon Oct 3 09:34:06 2011 +0200 add DEP_CFLAGS, so that those get picked up commit d2cdb314e2613dd6ff166735ace1dcec46922f25 Author: Rene Engelhard Date: Mon Oct 3 09:30:04 2011 +0200 fix libcmis.pc There's no liblibcmis and the Cflags don't match the installed headers commit cedbf4bedc9f51bdb757a14af0b209ce41dcd4ed Author: Cédric Bosdonnat Date: Sun Oct 2 15:55:32 2011 +0200 Iproved configure to build on Macos and inside LibreOffice + Use libcurl.m4 instead of pkg-config as that one isn't available on MacOS X. + Add --disable-client and enable the building cmis-client only if Boost program_options can be found. That library isn't provided by LibreOffice insternal boost. + Add some summary message at the end of the configure to show what will happen. commit 78e0cf1172d30a2a9777558935fb8104980bcea9 Author: Caolán McNamara Date: Sun Oct 2 14:31:34 2011 +0200 Properly add the includes commit 79f208773c0f7b90a3ceaa8d9a290d40f0782216 Author: Cédric Bosdonnat Date: Sat Oct 1 15:06:58 2011 +0200 Changed the API for the Document::getContent() to return a FILE* commit e4f073cce1c9f7d16816fb17a029d1f6f984d172 Author: Cédric Bosdonnat Date: Fri Sep 30 21:01:46 2011 +0200 Types names refactoring: introduced namespace libcmis + Renamed Content to Document in order to match the CMIS specifications terminology. + Added a libcmis namespace to avoid name clashes commit 05093f7e0dab17a7cabd7c509023efd7eb12850e Author: Cédric Bosdonnat Date: Fri Sep 30 15:38:07 2011 +0200 cmis-client: enhanced the help message and options commit 72876a7004b528f81c313d540161f8d168e82fd5 Author: Cédric Bosdonnat Date: Fri Sep 30 12:11:20 2011 +0200 cmis-client: added a get-content command to download the content data commit 0366d8a2515c5bc112790e8290575524369566a5 Author: Cédric Bosdonnat Date: Fri Sep 30 11:21:55 2011 +0200 cmis-client: added a show-by-id command to dump nodes infos Libcmis API additions: + CmisObject::toString method to dump the objects + Content::getContentFilename() to get the filename of the data stream commit 58a2e1e34e544792db739f9c0f142b8ae9761f0f Author: Cédric Bosdonnat Date: Wed Sep 28 16:20:52 2011 +0200 Removed the old bloated test-atom and started some more useful CLI client cmis-client is intended to be a command line client showing what the library can do and hopefuly being useful in some basic CMIS tests. commit c5eaa0006db26735aac94261072f3a76c32c3496 Author: Cédric Bosdonnat Date: Wed Sep 28 15:10:22 2011 +0200 Implemented unit tests using cppunit. commit 42ac4af71b4d4de74b19caf980403780a9a9362d Author: Cédric Bosdonnat Date: Wed Sep 28 10:23:05 2011 +0200 Code cleanup: removed the atom-* headers from the public headers Among the other improvements: moved the test-server directory to the top folder of the libcmis sources: this helps to use that server for the tests of any subdirectory. commit 661951950bea8d767b3188e1be4d28326fb93932 Author: Cédric Bosdonnat Date: Wed Sep 28 08:53:14 2011 +0200 Fixed tests and cmis:name property XPath query commit 0b99f7d6cae059d6b1380b2fc45a153a9cdb4b51 Author: Cédric Bosdonnat Date: Tue Sep 27 18:46:58 2011 +0200 User propertyDefinitionId instead of queryName to get properties commit c55f154bf7c5b80a18f2448ab74e3769f5aee50b Author: Cédric Bosdonnat Date: Tue Sep 27 18:45:33 2011 +0200 Content class: provide the value of cmis:contentStreamLength commit 69ab41fc3714b7f17d53e59637978fa85d153080 Author: Cédric Bosdonnat Date: Tue Sep 27 17:05:01 2011 +0200 Properly set the license of the library commit 521335d638e9872cd9889dd830395ac1dca1d552 Author: Cédric Bosdonnat Date: Tue Sep 27 16:46:09 2011 +0200 Memory leaks fixes Added a missing xmlFree( ) and use boost::shared_ptr for getRootFolder() to avoid leaking the resulting folder. commit ef4afcc25fd5666c7d5bf1b33b5bc94a578b1fef Author: Cédric Bosdonnat Date: Tue Sep 27 16:37:54 2011 +0200 Added the AtomContent class and moved the path to the Folder In CMIS, only the folder objects have a path. commit 315bc3f83870e6731b5d8329937847b22754758f Author: Cédric Bosdonnat Date: Tue Sep 27 15:17:51 2011 +0200 AtomFolder::getChildren - Getting the folders now properly commit c190930ecfc6b2d7c2afb1ba7861dd95656d3e45 Author: Cédric Bosdonnat Date: Tue Sep 27 11:13:40 2011 +0200 AtomFolder::getChildren, basic implementation This has the following limits: + The AtomContent type isn't defined, so only folder children are returned ATM. + The children xml file may be too long. The atom::http_request function needs to use a buffer in order to get the whole content before parsing it. commit 0c772587b06d4d230073643f64593d0d231961b6 Author: Cédric Bosdonnat Date: Mon Sep 26 15:27:37 2011 +0200 Resources: setup the Atom resources classes commit 87dac1fe48c38d8cb554b5cf2d39fbd80a7ad726 Author: Cédric Bosdonnat Date: Mon Sep 26 10:56:49 2011 +0200 AtomSession: get the UriTemplates and root Id commit 18ef944861756924ef7a9585f35c577dc65590ef Author: Cédric Bosdonnat Date: Mon Sep 26 09:33:55 2011 +0200 Session improvements, added a factory and support of multiple repos commit a9664cd909ff0542cb55e3a4532faa9809d8c175 Author: Cédric Bosdonnat Date: Sat Sep 24 13:27:08 2011 +0200 Created a Session base class and started defining the resource classes commit b0a555b8f8b2f7d713608f64fd1a72ba25d6801f Author: Cédric Bosdonnat Date: Thu Sep 22 12:25:31 2011 +0200 Automated tests using an Apache Chemistry InMemory server commit f73aa0f20d17efcb046d9844baa03ec92e4bb2ec Author: Cédric Bosdonnat Date: Wed Sep 21 21:58:26 2011 +0200 Service Document parsing: fixed the collections reading and tested it commit a7a60527c743a39ee6c78facd2d8a80cf23bde82 Author: Cédric Bosdonnat Date: Wed Sep 21 12:09:47 2011 +0200 Finished reading the collections from the Service Document commit dc4b2c84d1f475d771ea3c51cc401db7bb24f1a4 Author: Cédric Bosdonnat Date: Mon Sep 19 21:04:05 2011 +0200 Created AtomPub session class and libtoolized the project libcmis-0.5.2/inc/0000775000175000017500000000000013411152375010716 500000000000000libcmis-0.5.2/inc/Makefile.in0000664000175000017500000004620713407705040012712 00000000000000# Makefile.in generated by automake 1.16.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2018 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = inc ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \ $(top_srcdir)/m4/ax_cxx_compile_stdcxx_11.m4 \ $(top_srcdir)/m4/ax_gcc_func_attribute.m4 \ $(top_srcdir)/m4/boost.m4 $(top_srcdir)/m4/libtool.m4 \ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = SOURCES = DIST_SOURCES = RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ ctags-recursive dvi-recursive html-recursive info-recursive \ install-data-recursive install-dvi-recursive \ install-exec-recursive install-html-recursive \ install-info-recursive install-pdf-recursive \ install-ps-recursive install-recursive installcheck-recursive \ installdirs-recursive pdf-recursive ps-recursive \ tags-recursive uninstall-recursive am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ distclean-recursive maintainer-clean-recursive am__recursive_targets = \ $(RECURSIVE_TARGETS) \ $(RECURSIVE_CLEAN_TARGETS) \ $(am__extra_recursive_targets) AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ distdir distdir-am am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is # *not* preserved. am__uniquify_input = $(AWK) '\ BEGIN { nonempty = 0; } \ { items[$$0] = 1; nonempty = 1; } \ END { if (nonempty) { for (i in items) print i; }; } \ ' # Make sure the list of sources is unique. This is necessary because, # e.g., the same source file might be shared among _SOURCES variables # for different programs/libraries. am__define_uniq_tagged_files = \ list='$(am__tagged_files)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags DIST_SUBDIRS = $(SUBDIRS) am__DIST_COMMON = $(srcdir)/Makefile.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) am__relativize = \ dir0=`pwd`; \ sed_first='s,^\([^/]*\)/.*$$,\1,'; \ sed_rest='s,^[^/]*/*,,'; \ sed_last='s,^.*/\([^/]*\)$$,\1,'; \ sed_butlast='s,/*[^/]*$$,,'; \ while test -n "$$dir1"; do \ first=`echo "$$dir1" | sed -e "$$sed_first"`; \ if test "$$first" != "."; then \ if test "$$first" = ".."; then \ dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ else \ first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ if test "$$first2" = "$$first"; then \ dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ else \ dir2="../$$dir2"; \ fi; \ dir0="$$dir0"/"$$first"; \ fi; \ fi; \ dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ done; \ reldir="$$dir2" ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ BOOST_CPPFLAGS = @BOOST_CPPFLAGS@ BOOST_DATE_TIME_LDFLAGS = @BOOST_DATE_TIME_LDFLAGS@ BOOST_DATE_TIME_LDPATH = @BOOST_DATE_TIME_LDPATH@ BOOST_DATE_TIME_LIBS = @BOOST_DATE_TIME_LIBS@ BOOST_LDPATH = @BOOST_LDPATH@ BOOST_PROGRAM_OPTIONS_LDFLAGS = @BOOST_PROGRAM_OPTIONS_LDFLAGS@ BOOST_PROGRAM_OPTIONS_LDPATH = @BOOST_PROGRAM_OPTIONS_LDPATH@ BOOST_PROGRAM_OPTIONS_LIBS = @BOOST_PROGRAM_OPTIONS_LIBS@ BOOST_ROOT = @BOOST_ROOT@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPCHECK = @CPPCHECK@ CPPCHECK_PARALLELISM = @CPPCHECK_PARALLELISM@ CPPFLAGS = @CPPFLAGS@ CPPUNIT_CFLAGS = @CPPUNIT_CFLAGS@ CPPUNIT_LIBS = @CPPUNIT_LIBS@ CURL_CFLAGS = @CURL_CFLAGS@ CURL_LIBS = @CURL_LIBS@ CXX = @CXX@ CXXCPP = @CXXCPP@ CXXDEPMODE = @CXXDEPMODE@ CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DISTCHECK_CONFIGURE_FLAGS = @DISTCHECK_CONFIGURE_FLAGS@ DLLTOOL = @DLLTOOL@ DOCBOOK2MAN = @DOCBOOK2MAN@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ GENHTML = @GENHTML@ GREP = @GREP@ HAVE_CXX11 = @HAVE_CXX11@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LCOV = @LCOV@ LD = @LD@ LDFLAGS = @LDFLAGS@ LIBCMIS_API_VERSION = @LIBCMIS_API_VERSION@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ NPROC = @NPROC@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SRCDIR = @SRCDIR@ STRIP = @STRIP@ VERSION = @VERSION@ XML2_CFLAGS = @XML2_CFLAGS@ XML2_LIBS = @XML2_LIBS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ SUBDIRS = libcmis libcmis-c all: all-recursive .SUFFIXES: $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign inc/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign inc/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs # This directory's subdirectories are mostly independent; you can cd # into them and run 'make' without going through this Makefile. # To change the values of 'make' variables: instead of editing Makefiles, # (1) if the variable is set in 'config.status', edit 'config.status' # (which will cause the Makefiles to be regenerated when you run 'make'); # (2) otherwise, pass the desired values on the 'make' command line. $(am__recursive_targets): @fail=; \ if $(am__make_keepgoing); then \ failcom='fail=yes'; \ else \ failcom='exit 1'; \ fi; \ dot_seen=no; \ target=`echo $@ | sed s/-recursive//`; \ case "$@" in \ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ *) list='$(SUBDIRS)' ;; \ esac; \ for subdir in $$list; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ dot_seen=yes; \ local_target="$$target-am"; \ else \ local_target="$$target"; \ fi; \ ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ || eval $$failcom; \ done; \ if test "$$dot_seen" = "no"; then \ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ fi; test -z "$$fail" ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique tags: tags-recursive TAGS: tags tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ include_option=--etags-include; \ empty_fix=.; \ else \ include_option=--include; \ empty_fix=; \ fi; \ list='$(SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ test ! -f $$subdir/TAGS || \ set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ fi; \ done; \ $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ if test $$# -gt 0; then \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ "$$@" $$unique; \ else \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$unique; \ fi; \ fi ctags: ctags-recursive CTAGS: ctags ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" cscopelist: cscopelist-recursive cscopelist-am: $(am__tagged_files) list='$(am__tagged_files)'; \ case "$(srcdir)" in \ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ *) sdir=$(subdir)/$(srcdir) ;; \ esac; \ for i in $$list; do \ if test -f "$$i"; then \ echo "$(subdir)/$$i"; \ else \ echo "$$sdir/$$i"; \ fi; \ done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ $(am__make_dryrun) \ || test -d "$(distdir)/$$subdir" \ || $(MKDIR_P) "$(distdir)/$$subdir" \ || exit 1; \ dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ $(am__relativize); \ new_distdir=$$reldir; \ dir1=$$subdir; dir2="$(top_distdir)"; \ $(am__relativize); \ new_top_distdir=$$reldir; \ echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ ($(am__cd) $$subdir && \ $(MAKE) $(AM_MAKEFLAGS) \ top_distdir="$$new_top_distdir" \ distdir="$$new_distdir" \ am__remove_distdir=: \ am__skip_length_check=: \ am__skip_mode_fix=: \ distdir) \ || exit 1; \ fi; \ done check-am: all-am check: check-recursive all-am: Makefile installdirs: installdirs-recursive installdirs-am: install: install-recursive install-exec: install-exec-recursive install-data: install-data-recursive uninstall: uninstall-recursive install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-recursive install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-recursive clean-am: clean-generic clean-libtool mostlyclean-am distclean: distclean-recursive -rm -f Makefile distclean-am: clean-am distclean-generic distclean-tags dvi: dvi-recursive dvi-am: html: html-recursive html-am: info: info-recursive info-am: install-data-am: install-dvi: install-dvi-recursive install-dvi-am: install-exec-am: install-html: install-html-recursive install-html-am: install-info: install-info-recursive install-info-am: install-man: install-pdf: install-pdf-recursive install-pdf-am: install-ps: install-ps-recursive install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-recursive -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-recursive mostlyclean-am: mostlyclean-generic mostlyclean-libtool pdf: pdf-recursive pdf-am: ps: ps-recursive ps-am: uninstall-am: .MAKE: $(am__recursive_targets) install-am install-strip .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ check-am clean clean-generic clean-libtool cscopelist-am ctags \ ctags-am distclean distclean-generic distclean-libtool \ distclean-tags distdir dvi dvi-am html html-am info info-am \ install install-am install-data install-data-am install-dvi \ install-dvi-am install-exec install-exec-am install-html \ install-html-am install-info install-info-am install-man \ install-pdf install-pdf-am install-ps install-ps-am \ install-strip installcheck installcheck-am installdirs \ installdirs-am maintainer-clean maintainer-clean-generic \ mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ ps ps-am tags tags-am uninstall uninstall-am .PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: libcmis-0.5.2/inc/libcmis/0000775000175000017500000000000013411152375012340 500000000000000libcmis-0.5.2/inc/libcmis/Makefile.in0000664000175000017500000004312213407705040014325 00000000000000# Makefile.in generated by automake 1.16.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2018 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = inc/libcmis ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \ $(top_srcdir)/m4/ax_cxx_compile_stdcxx_11.m4 \ $(top_srcdir)/m4/ax_gcc_func_attribute.m4 \ $(top_srcdir)/m4/boost.m4 $(top_srcdir)/m4/libtool.m4 \ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(dist_libcmis_HEADERS) \ $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = SOURCES = DIST_SOURCES = am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; am__install_max = 40 am__nobase_strip_setup = \ srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` am__nobase_strip = \ for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" am__nobase_list = $(am__nobase_strip_setup); \ for p in $$list; do echo "$$p $$p"; done | \ sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ if (++n[$$2] == $(am__install_max)) \ { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ END { for (dir in files) print dir, files[dir] }' am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' am__uninstall_files_from_dir = { \ test -z "$$files" \ || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ $(am__cd) "$$dir" && rm -f $$files; }; \ } am__installdirs = "$(DESTDIR)$(libcmisdir)" HEADERS = $(dist_libcmis_HEADERS) am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is # *not* preserved. am__uniquify_input = $(AWK) '\ BEGIN { nonempty = 0; } \ { items[$$0] = 1; nonempty = 1; } \ END { if (nonempty) { for (i in items) print i; }; } \ ' # Make sure the list of sources is unique. This is necessary because, # e.g., the same source file might be shared among _SOURCES variables # for different programs/libraries. am__define_uniq_tagged_files = \ list='$(am__tagged_files)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags am__DIST_COMMON = $(srcdir)/Makefile.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ BOOST_CPPFLAGS = @BOOST_CPPFLAGS@ BOOST_DATE_TIME_LDFLAGS = @BOOST_DATE_TIME_LDFLAGS@ BOOST_DATE_TIME_LDPATH = @BOOST_DATE_TIME_LDPATH@ BOOST_DATE_TIME_LIBS = @BOOST_DATE_TIME_LIBS@ BOOST_LDPATH = @BOOST_LDPATH@ BOOST_PROGRAM_OPTIONS_LDFLAGS = @BOOST_PROGRAM_OPTIONS_LDFLAGS@ BOOST_PROGRAM_OPTIONS_LDPATH = @BOOST_PROGRAM_OPTIONS_LDPATH@ BOOST_PROGRAM_OPTIONS_LIBS = @BOOST_PROGRAM_OPTIONS_LIBS@ BOOST_ROOT = @BOOST_ROOT@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPCHECK = @CPPCHECK@ CPPCHECK_PARALLELISM = @CPPCHECK_PARALLELISM@ CPPFLAGS = @CPPFLAGS@ CPPUNIT_CFLAGS = @CPPUNIT_CFLAGS@ CPPUNIT_LIBS = @CPPUNIT_LIBS@ CURL_CFLAGS = @CURL_CFLAGS@ CURL_LIBS = @CURL_LIBS@ CXX = @CXX@ CXXCPP = @CXXCPP@ CXXDEPMODE = @CXXDEPMODE@ CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DISTCHECK_CONFIGURE_FLAGS = @DISTCHECK_CONFIGURE_FLAGS@ DLLTOOL = @DLLTOOL@ DOCBOOK2MAN = @DOCBOOK2MAN@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ GENHTML = @GENHTML@ GREP = @GREP@ HAVE_CXX11 = @HAVE_CXX11@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LCOV = @LCOV@ LD = @LD@ LDFLAGS = @LDFLAGS@ LIBCMIS_API_VERSION = @LIBCMIS_API_VERSION@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ NPROC = @NPROC@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SRCDIR = @SRCDIR@ STRIP = @STRIP@ VERSION = @VERSION@ XML2_CFLAGS = @XML2_CFLAGS@ XML2_LIBS = @XML2_LIBS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ libcmisdir = $(includedir)/libcmis-@LIBCMIS_API_VERSION@/libcmis dist_libcmis_HEADERS = \ allowable-actions.hxx \ document.hxx \ exception.hxx \ folder.hxx \ libcmis-api.h \ libcmis.hxx \ oauth2-data.hxx \ object-type.hxx \ object.hxx \ property-type.hxx \ property.hxx \ rendition.hxx \ repository.hxx \ session-factory.hxx \ session.hxx \ xml-utils.hxx \ xmlserializable.hxx all: all-am .SUFFIXES: $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign inc/libcmis/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign inc/libcmis/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs install-dist_libcmisHEADERS: $(dist_libcmis_HEADERS) @$(NORMAL_INSTALL) @list='$(dist_libcmis_HEADERS)'; test -n "$(libcmisdir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(libcmisdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(libcmisdir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(libcmisdir)'"; \ $(INSTALL_HEADER) $$files "$(DESTDIR)$(libcmisdir)" || exit $$?; \ done uninstall-dist_libcmisHEADERS: @$(NORMAL_UNINSTALL) @list='$(dist_libcmis_HEADERS)'; test -n "$(libcmisdir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(libcmisdir)'; $(am__uninstall_files_from_dir) ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique tags: tags-am TAGS: tags tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ if test $$# -gt 0; then \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ "$$@" $$unique; \ else \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$unique; \ fi; \ fi ctags: ctags-am CTAGS: ctags ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" cscopelist: cscopelist-am cscopelist-am: $(am__tagged_files) list='$(am__tagged_files)'; \ case "$(srcdir)" in \ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ *) sdir=$(subdir)/$(srcdir) ;; \ esac; \ for i in $$list; do \ if test -f "$$i"; then \ echo "$(subdir)/$$i"; \ else \ echo "$$sdir/$$i"; \ fi; \ done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(HEADERS) installdirs: for dir in "$(DESTDIR)$(libcmisdir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic clean-libtool mostlyclean-am distclean: distclean-am -rm -f Makefile distclean-am: clean-am distclean-generic distclean-tags dvi: dvi-am dvi-am: html: html-am html-am: info: info-am info-am: install-data-am: install-dist_libcmisHEADERS install-dvi: install-dvi-am install-dvi-am: install-exec-am: install-html: install-html-am install-html-am: install-info: install-info-am install-info-am: install-man: install-pdf: install-pdf-am install-pdf-am: install-ps: install-ps-am install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-generic mostlyclean-libtool pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-dist_libcmisHEADERS .MAKE: install-am install-strip .PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ clean-libtool cscopelist-am ctags ctags-am distclean \ distclean-generic distclean-libtool distclean-tags distdir dvi \ dvi-am html html-am info info-am install install-am \ install-data install-data-am install-dist_libcmisHEADERS \ install-dvi install-dvi-am install-exec install-exec-am \ install-html install-html-am install-info install-info-am \ install-man install-pdf install-pdf-am install-ps \ install-ps-am install-strip installcheck installcheck-am \ installdirs maintainer-clean maintainer-clean-generic \ mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ ps ps-am tags tags-am uninstall uninstall-am \ uninstall-dist_libcmisHEADERS .PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: libcmis-0.5.2/inc/libcmis/rendition.hxx0000664000175000017500000000542513407453615015020 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _RENDITION_HXX_ #define _RENDITION_HXX_ #include #include #include #include "libcmis/libcmis-api.h" namespace libcmis { class LIBCMIS_API Rendition { private: Rendition( ); std::string m_streamId; std::string m_mimeType; std::string m_kind; std::string m_href; std::string m_title; long m_length; long m_width; long m_height; std::string m_renditionDocumentId; public: Rendition( std::string streamId, std::string mimeType, std::string kind, std::string href, std::string title = std::string( ), long length = -1, long width = -1, long height = -1, std::string renditionDocumentId = std::string( ) ); /** Parse an XML node of type cmisRenditionType */ Rendition( xmlNodePtr node ); ~Rendition( ); bool isThumbnail( ); const std::string& getStreamId( ) const; const std::string& getMimeType( ) const; const std::string& getKind( ) const; const std::string& getUrl( ) const; const std::string& getTitle( ) const; /** Provides the stream length in bytes or a negative value if missing. */ long getLength( ) const; long getWidth( ) const; long getHeight( ) const; const std::string& getRenditionDocumentId( ); std::string toString( ); }; typedef boost::shared_ptr< Rendition > RenditionPtr; } #endif libcmis-0.5.2/inc/libcmis/session-factory.hxx0000664000175000017500000001401613407757661016161 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _SESSION_FACTORY_HXX_ #define _SESSION_FACTORY_HXX_ #include #include #include #include "libcmis/exception.hxx" #include "libcmis/libcmis-api.h" #include "libcmis/oauth2-data.hxx" #include "libcmis/repository.hxx" #include "libcmis/session.hxx" namespace libcmis { /** This callback provides the OAuth2 code or NULL. The returned string must be free()d by the caller. */ typedef char* ( *OAuth2AuthCodeProvider )( const char* authUrl, const char* username, const char* password ); class LIBCMIS_API AuthProvider { public: virtual ~AuthProvider() { }; /** The function implementing it needs to fill the username and password parameters and return true. Returning false means that the user cancelled the authentication and will fail the query. */ virtual bool authenticationQuery( std::string& username, std::string& password ) = 0; }; typedef boost::shared_ptr< AuthProvider > AuthProviderPtr; /** Handler class used to request user input when an invalid SSL certificate is encountered. */ class LIBCMIS_API CertValidationHandler { public: virtual ~CertValidationHandler( ){ }; /** This function is provided a vector of X509 certificates encoded in base64, with the first certificate being the one to validate, and the others are the issuers chain. The result will be stored in the session object to avoid asking several times to validate the same certificate. \result true if the certificate should be ignored, false to fail the request. */ virtual bool validateCertificate( std::vector< std::string > certificatesChain ) = 0; }; typedef boost::shared_ptr< CertValidationHandler > CertValidationHandlerPtr; class LIBCMIS_API SessionFactory { private: static AuthProviderPtr s_authProvider; static std::string s_proxy; static std::string s_noProxy; static std::string s_proxyUser; static std::string s_proxyPass; static OAuth2AuthCodeProvider s_oauth2AuthCodeProvider; static CertValidationHandlerPtr s_certValidationHandler; public: static void setAuthenticationProvider( AuthProviderPtr provider ) { s_authProvider = provider; } static AuthProviderPtr getAuthenticationProvider( ) { return s_authProvider; } static void setOAuth2AuthCodeProvider( OAuth2AuthCodeProvider provider ) { s_oauth2AuthCodeProvider = provider; } static OAuth2AuthCodeProvider getOAuth2AuthCodeProvider( ) { return s_oauth2AuthCodeProvider; } /** Set the handler to ask the user what to do with invalid SSL certificates. If not set, every invalid certificate will raise an exception. */ static void setCertificateValidationHandler( CertValidationHandlerPtr handler ) { s_certValidationHandler = handler; } static CertValidationHandlerPtr getCertificateValidationHandler( ) { return s_certValidationHandler; } static void setProxySettings( std::string proxy, std::string noProxy, std::string proxyUser, std::string proxyPass ); static const std::string& getProxy() { return s_proxy; } static const std::string& getNoProxy() { return s_noProxy; } static const std::string& getProxyUser() { return s_proxyUser; } static const std::string& getProxyPass() { return s_proxyPass; } /** Create a session from the given parameters. The binding type is automatically detected based on the provided URL. The resulting pointer should be deleted by the caller. */ static Session* createSession( std::string bindingUrl, std::string username = std::string( ), std::string password = std::string( ), std::string repositoryId = std::string( ), bool noSslCheck = false, OAuth2DataPtr oauth2 = OAuth2DataPtr(), bool verbose = false ); /** Gets the informations of the repositories on the server. \deprecated Since libcmis 0.4.0, this helper function simply creates a session using the createSession function with no repository and then calls getRepositories on the resulting session. Kept only for backward API compatibility. */ static std::vector< RepositoryPtr > getRepositories( std::string bindingUrl, std::string username = std::string( ), std::string password = std::string( ), bool verbose = false ); }; } #endif libcmis-0.5.2/inc/libcmis/xmlserializable.hxx0000664000175000017500000000265413407453740016214 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _XMLSERIALIZABLE_HXX_ #define _XMLSERIALIZABLE_HXX_ #include #include "libcmis/libcmis-api.h" namespace libcmis { /// Interface for objects dumpable as XML class LIBCMIS_API XmlSerializable { public: virtual ~XmlSerializable( ) { } virtual void toXml( xmlTextWriterPtr writer ) = 0; }; } #endif libcmis-0.5.2/inc/libcmis/object.hxx0000664000175000017500000001757213407453734014303 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _OBJECT_HXX_ #define _OBJECT_HXX_ #include #include #include #include #ifndef __cplusplus #include #endif #include #include #include #include "libcmis/allowable-actions.hxx" #include "libcmis/exception.hxx" #include "libcmis/libcmis-api.h" #include "libcmis/object-type.hxx" #include "libcmis/property.hxx" #include "libcmis/xmlserializable.hxx" #include "libcmis/rendition.hxx" namespace libcmis { class Folder; class Session; /** Class representing any CMIS object. */ class LIBCMIS_API Object : public XmlSerializable { protected: Session* m_session; ObjectTypePtr m_typeDescription; time_t m_refreshTimestamp; /** Type id used as cache before we get it as a property */ std::string m_typeId; std::map< std::string, PropertyPtr > m_properties; boost::shared_ptr< AllowableActions > m_allowableActions; std::vector< RenditionPtr > m_renditions; void initializeFromNode( xmlNodePtr node ); public: Object( Session* session ); Object( Session* session, xmlNodePtr node ); Object( const Object& copy ); virtual ~Object( ) { } Object& operator=( const Object& copy ); virtual std::string getId( ); virtual std::string getName( ); virtual std::string getStringProperty( const std::string& propertyName ); /** Computes the paths for the objects. Note that folders will have only path, documents may have several ones and there may be cases where there is no path at all (unfilled objects); */ virtual std::vector< std::string > getPaths( ); virtual std::string getBaseType( ); virtual std::string getType( ); virtual std::string getCreatedBy( ); virtual boost::posix_time::ptime getCreationDate( ); virtual std::string getLastModifiedBy( ); virtual boost::posix_time::ptime getLastModificationDate( ); virtual std::string getChangeToken( ); virtual bool isImmutable( ); virtual std::vector< std::string > getSecondaryTypes(); /** Convenience function adding a secondary type to the object. Behind the scene this function is basically computing the properties and sets them for you to avoid reading the CMIS 1.1 specification, section 2.1.9. \param id the identifier of the secondary type to add \param properties the properties coming with the secondary type \return the updated object. Note that it may represent the same object on the server but it still is a different object instance (see updateProperties method). \throw Exception if anything wrong happens. Note that the server is likely to throw a constraint exception if it doesn't allow the operation. */ virtual boost::shared_ptr< Object > addSecondaryType( std::string id, PropertyPtrMap properties ); /** Convenience function removing a secondary type from the object. Behind the scene this function is basically computing the correct property and sets it for you to avoid reading the CMIS 1.1 specification, section 2.1.9. The server should remove the related properties, there is normally no need to worry about them. \param id the identifier of the secondary type to remove \return the updated object. Note that it may represent the same object on the server but it still is a different object instance (see updateProperties method). \throw Exception if anything wrong happens. Note that the server is likely to throw a constraint exception if it doesn't allow the operation. */ virtual boost::shared_ptr< Object > removeSecondaryType( std::string id ); /** Gives access to the properties of the object. \attention API users should consider this method as read-only as the changed properties won't be updated to the server. Updating the returned map may lead to changes loss when calling updateProperties. \sa updateProperties to change properties on the server */ virtual libcmis::PropertyPtrMap& getProperties( ); /** Get the renditions of the object. \param filter is defined by the CMIS spec section 2.2.1.2.4.1. By default, this value is just ignored, but some bindings and servers may use it. \attention The streamId of the rendition is used in getContentStream( ) */ virtual std::vector< RenditionPtr> getRenditions( std::string filter = std::string( ) ); virtual AllowableActionsPtr getAllowableActions( ) { return m_allowableActions; } /** Update the object properties and return the updated object. \attention even if the returned object may have the same Id than 'this' and thus representing the same object on the server, those are still two different instances to ease memory handling. */ virtual boost::shared_ptr< Object > updateProperties( const PropertyPtrMap& properties ) = 0; virtual ObjectTypePtr getTypeDescription( ); /** Reload the data from the server. */ virtual void refresh( ) = 0; virtual time_t getRefreshTimestamp( ) { return m_refreshTimestamp; } virtual void remove( bool allVersions = true ) = 0; virtual void move( boost::shared_ptr< Folder > source, boost::shared_ptr< Folder > destination ) = 0; virtual std::string getThumbnailUrl( ); /** Dump the object as a string for debugging or display purpose. */ virtual std::string toString( ); void toXml( xmlTextWriterPtr writer ); }; typedef boost::shared_ptr< Object > ObjectPtr; } #endif libcmis-0.5.2/inc/libcmis/object-type.hxx0000664000175000017500000001110513407453743015244 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _OBJECT_TYPE_HXX_ #define _OBJECT_TYPE_HXX_ #include #include #include #include #include "libcmis/exception.hxx" #include "libcmis/libcmis-api.h" #include "libcmis/property-type.hxx" namespace libcmis { /** Class representing a CMIS object type definition. */ class LIBCMIS_API ObjectType { public: enum ContentStreamAllowed { NotAllowed, Allowed, Required }; protected: time_t m_refreshTimestamp; std::string m_id; std::string m_localName; std::string m_localNamespace; std::string m_displayName; std::string m_queryName; std::string m_description; std::string m_parentTypeId; std::string m_baseTypeId; bool m_creatable; bool m_fileable; bool m_queryable; bool m_fulltextIndexed; bool m_includedInSupertypeQuery; bool m_controllablePolicy; bool m_controllableAcl; bool m_versionable; libcmis::ObjectType::ContentStreamAllowed m_contentStreamAllowed; std::map< std::string, libcmis::PropertyTypePtr > m_propertiesTypes; ObjectType( ); void initializeFromNode( xmlNodePtr node ); public: ObjectType( xmlNodePtr node ); ObjectType( const ObjectType& copy ); virtual ~ObjectType() { } ObjectType& operator=( const ObjectType& copy ); /** Reload the data from the server. \attention This method needs to be implemented in subclasses or it will do nothing */ virtual void refresh( ); virtual time_t getRefreshTimestamp( ) const; std::string getId( ) const; std::string getLocalName( ) const; std::string getLocalNamespace( ) const; std::string getDisplayName( ) const; std::string getQueryName( ) const; std::string getDescription( ) const; virtual boost::shared_ptr< ObjectType > getParentType( ); virtual boost::shared_ptr< ObjectType > getBaseType( ); virtual std::vector< boost::shared_ptr< ObjectType > > getChildren( ); /** Get the parent type id without extracting the complete parent type from the repository. This is mainly provided for performance reasons. \since libcmis 0.4 */ std::string getParentTypeId( ) const; /** Get the base type id without extracting the complete base type from the repository. This is mainly provided for performance reasons. \since libcmis 0.4 */ std::string getBaseTypeId( ) const; bool isCreatable( ) const; bool isFileable( ) const; bool isQueryable( ) const; bool isFulltextIndexed( ) const; bool isIncludedInSupertypeQuery( ) const; bool isControllablePolicy( ) const; bool isControllableACL( ) const; bool isVersionable( ) const; ContentStreamAllowed getContentStreamAllowed( ) const; std::map< std::string, PropertyTypePtr >& getPropertiesTypes( ); virtual std::string toString( ); }; typedef boost::shared_ptr< ObjectType > ObjectTypePtr; } #endif libcmis-0.5.2/inc/libcmis/libcmis-api.h0000664000175000017500000000260513407453152014627 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_API_H_ #define _LIBCMIS_API_H_ #ifdef DLL_EXPORT #ifdef LIBCMIS_BUILD #define LIBCMIS_API __declspec(dllexport) #else #define LIBCMIS_API __declspec(dllimport) #endif #else // !DLL_EXPORT #ifdef LIBCMIS_VISIBILITY #define LIBCMIS_API __attribute__((visibility("default"))) #else #define LIBCMIS_API #endif #endif #endif libcmis-0.5.2/inc/libcmis/repository.hxx0000664000175000017500000000745513407453722015250 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 Cédric Bosdonnat * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _REPOSITORY_HXX_ #define _REPOSITORY_HXX_ #include #include #include #include #include "libcmis/libcmis-api.h" namespace libcmis { /** Class representing a repository and its infos. \sa 2.2.2.2 section of the CMIS specifications */ class LIBCMIS_API Repository { public: enum Capability { ACL, AllVersionsSearchable, Changes, ContentStreamUpdatability, GetDescendants, GetFolderTree, OrderBy, Multifiling, PWCSearchable, PWCUpdatable, Query, Renditions, Unfiling, VersionSpecificFiling, Join }; protected: std::string m_id; std::string m_name; std::string m_description; std::string m_vendorName; std::string m_productName; std::string m_productVersion; std::string m_rootId; std::string m_cmisVersionSupported; boost::shared_ptr< std::string > m_thinClientUri; boost::shared_ptr< std::string > m_principalAnonymous; boost::shared_ptr< std::string > m_principalAnyone; std::map< Capability, std::string > m_capabilities ; Repository( ); void initializeFromNode( xmlNodePtr node ); public: Repository( xmlNodePtr node ); virtual ~Repository( ) { }; std::string getId( ) const; std::string getName( ) const; std::string getDescription( ) const; std::string getVendorName( ) const; std::string getProductName( ) const; std::string getProductVersion( ) const; std::string getRootId( ) const; std::string getCmisVersionSupported( ) const; boost::shared_ptr< std::string > getThinClientUri( ) const; boost::shared_ptr< std::string > getPrincipalAnonymous( ) const; boost::shared_ptr< std::string > getPrincipalAnyone( ) const; std::string getCapability( Capability capability ) const; /** Wrapper function providing the capability as a boolean value. If the capability value is not a boolean, returns false. */ bool getCapabilityAsBool( Capability capability ) const; std::string toString( ) const; private: static std::map< Capability, std::string > parseCapabilities( xmlNodePtr node ); }; typedef boost::shared_ptr< Repository > RepositoryPtr; } #endif libcmis-0.5.2/inc/libcmis/allowable-actions.hxx0000664000175000017500000000753613407453610016425 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _ALLOWABLE_ACTIONS_HXX_ #define _ALLOWABLE_ACTIONS_HXX_ #include #include #include #include #include "libcmis/exception.hxx" #include "libcmis/libcmis-api.h" namespace libcmis { class Object; class LIBCMIS_API ObjectAction { public: enum Type { DeleteObject, UpdateProperties, GetFolderTree, GetProperties, GetObjectRelationships, GetObjectParents, GetFolderParent, GetDescendants, MoveObject, DeleteContentStream, CheckOut, CancelCheckOut, CheckIn, SetContentStream, GetAllVersions, AddObjectToFolder, RemoveObjectFromFolder, GetContentStream, ApplyPolicy, GetAppliedPolicies, RemovePolicy, GetChildren, CreateDocument, CreateFolder, CreateRelationship, DeleteTree, GetRenditions, GetACL, ApplyACL }; private: Type m_type; bool m_enabled; bool m_valid; public: ObjectAction( xmlNodePtr node ); virtual ~ObjectAction( ){ } Type getType( ) { return m_type; } bool isEnabled( ) { return m_enabled; } bool isValid( ) { return m_valid; } /** Parses the permission name into one of the enum values or throws an exception for invalid input strings. */ static Type parseType( std::string type ); }; /** Class providing access to the allowed actions on an object. */ class LIBCMIS_API AllowableActions { protected: std::map< ObjectAction::Type, bool > m_states; public: /** Default constructor for testing purpose */ AllowableActions( ); AllowableActions( xmlNodePtr node ); AllowableActions( const AllowableActions& copy ); virtual ~AllowableActions( ); AllowableActions& operator=( const AllowableActions& copy ); /** Returns the permissions for the corresponding actions. */ bool isAllowed( ObjectAction::Type action ); /** Returns true if the action was defined, false if the default value is used. */ bool isDefined( ObjectAction::Type action ); std::string toString( ); }; typedef boost::shared_ptr< AllowableActions > AllowableActionsPtr; } #endif libcmis-0.5.2/inc/libcmis/exception.hxx0000664000175000017500000000344313407453646015025 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _EXCEPTION_HXX_ #define _EXCEPTION_HXX_ #include #include #include "libcmis/libcmis-api.h" namespace libcmis { class LIBCMIS_API Exception : public std::exception { private: std::string m_message; std::string m_type; public: Exception( std::string message, std::string type = "runtime" ) : exception( ), m_message( message ), m_type( type ) { } ~Exception( ) noexcept { } virtual const char* what() const noexcept { return m_message.c_str( ); } std::string getType( ) const { return m_type; } }; } #endif libcmis-0.5.2/inc/libcmis/oauth2-data.hxx0000664000175000017500000000514513407455237015137 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_OAUTH2_DATA_HXX_ #define _LIBCMIS_OAUTH2_DATA_HXX_ #include #include #include "libcmis/libcmis-api.h" namespace libcmis { /** Class storing the data needed for OAuth2 authentication. */ class LIBCMIS_API OAuth2Data { private: std::string m_authUrl; std::string m_tokenUrl; std::string m_clientId; std::string m_clientSecret; std::string m_scope; std::string m_redirectUri; public: OAuth2Data( ); OAuth2Data( const std::string& authUrl, const std::string& tokenUrl, const std::string& scope, const std::string& redirectUri, const std::string& clientId, const std::string& clientSecret ); OAuth2Data( const OAuth2Data& copy ); ~OAuth2Data( ); OAuth2Data& operator=( const OAuth2Data& copy ); bool isComplete(); const std::string& getAuthUrl() { return m_authUrl; } const std::string& getTokenUrl() { return m_tokenUrl; } const std::string& getClientId() { return m_clientId; } const std::string& getClientSecret() { return m_clientSecret; } const std::string& getScope() { return m_scope; } const std::string& getRedirectUri() { return m_redirectUri; } }; typedef boost::shared_ptr< OAuth2Data > OAuth2DataPtr; } #endif //_LIBCMIS_OAUTH2_DATA_HXX_ libcmis-0.5.2/inc/libcmis/session.hxx0000664000175000017500000000663513407453717014517 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _SESSION_HXX_ #define _SESSION_HXX_ #include #include #include #include "libcmis/libcmis-api.h" #include "libcmis/object-type.hxx" #include "libcmis/object.hxx" #include "libcmis/folder.hxx" #include "libcmis/repository.hxx" namespace libcmis { class LIBCMIS_API Session { public: virtual ~Session() { }; /** Get the current repository. */ virtual RepositoryPtr getRepository( ) = 0; virtual std::vector< RepositoryPtr > getRepositories( ) = 0; /** Change the current repository. \return false if no repository with the provided id can be found on the server, true otherwise */ virtual bool setRepository( std::string repositoryId ) = 0; /** Get the Root folder of the repository */ virtual FolderPtr getRootFolder()= 0; /** Get a CMIS object from its ID. */ virtual ObjectPtr getObject( std::string id ) = 0; /** Get a CMIS object from one of its path. */ virtual ObjectPtr getObjectByPath( std::string path ) = 0; /** Get a CMIS folder from its ID. */ virtual libcmis::FolderPtr getFolder( std::string id ) = 0; /** Get a CMIS object type from its ID. */ virtual ObjectTypePtr getType( std::string id ) = 0; /** Get all the CMIS base object types known by the server. */ virtual std::vector< ObjectTypePtr > getBaseTypes( ) = 0; /** Enable or disable the SSL certificate verification. By default, SSL certificates are verified and errors are thrown in case of one is invalid. The user may decide to ignore the checks for this CMIS session to workaround self-signed certificates or other similar problems. As each session only handles the connection to one CMIS server, it should concern only one SSL certificate and should provide the same feature as the certificate exception feature available on common web browser. */ virtual void setNoSSLCertificateCheck( bool noCheck ) = 0; }; } #endif libcmis-0.5.2/inc/libcmis/xml-utils.hxx0000664000175000017500000001347413407453634014767 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _XML_UTILS_HXX_ #define _XML_UTILS_HXX_ #include #include #include #include #include #include #include #include #include "libcmis/exception.hxx" #include "libcmis/libcmis-api.h" #define NS_CMIS_PREFIX "cmis" #define NS_CMISRA_PREFIX "cmisra" #define NS_SOAP_ENV_PREFIX "soap-env" #define NS_CMIS_URL "http://docs.oasis-open.org/ns/cmis/core/200908/" #define NS_CMISRA_URL "http://docs.oasis-open.org/ns/cmis/restatom/200908/" #define NS_CMISM_URL "http://docs.oasis-open.org/ns/cmis/messaging/200908/" #define NS_CMISW_URL "http://docs.oasis-open.org/ns/cmis/ws/200908/" #define NS_APP_URL "http://www.w3.org/2007/app" #define NS_ATOM_URL "http://www.w3.org/2005/Atom" #define NS_SOAP_URL "http://schemas.xmlsoap.org/wsdl/soap/" #define NS_SOAP_ENV_URL "http://schemas.xmlsoap.org/soap/envelope/" #define LIBCURL_VERSION_VALUE ( \ ( LIBCURL_VERSION_MAJOR << 16 ) | ( LIBCURL_VERSION_MINOR << 8 ) | ( LIBCURL_VERSION_PATCH ) \ ) namespace libcmis { /** Class used to decode a stream. An instance of this class can hold remaining un-decoded data to use for a future decode call. */ class LIBCMIS_API EncodedData { private: xmlTextWriterPtr m_writer; FILE* m_stream; std::ostream* m_outStream; std::string m_encoding; bool m_decode; unsigned long m_pendingValue; int m_pendingRank; size_t m_missingBytes; public: EncodedData( FILE* stream ); EncodedData( std::ostream* stream ); EncodedData( const EncodedData& rCopy ); EncodedData( xmlTextWriterPtr writer ); EncodedData& operator=( const EncodedData& rCopy ); void setEncoding( std::string encoding ) { m_encoding = encoding; } void decode( void* buf, size_t size, size_t nmemb ); void encode( void* buf, size_t size, size_t nmemb ); void finish( ); private: void write( void* buf, size_t size, size_t nmemb ); void decodeBase64( const char* buf, size_t len ); void encodeBase64( const char* buf, size_t len ); }; class LIBCMIS_API HttpResponse { private: std::map< std::string, std::string > m_headers; boost::shared_ptr< std::stringstream > m_stream; boost::shared_ptr< EncodedData > m_data; public: HttpResponse( ); ~HttpResponse( ) { }; std::map< std::string, std::string >& getHeaders( ) { return m_headers; } boost::shared_ptr< EncodedData > getData( ) { return m_data; } boost::shared_ptr< std::stringstream > getStream( ) { return m_stream; } }; typedef boost::shared_ptr< HttpResponse > HttpResponsePtr; LIBCMIS_API void registerNamespaces( xmlXPathContextPtr xpathCtx ); /** Register the CMIS and WSDL / SOAP namespaces */ LIBCMIS_API void registerCmisWSNamespaces( xmlXPathContextPtr xpathCtx ); /** Register only the WSD / SOAP namespaces. */ LIBCMIS_API void registerSoapNamespaces( xmlXPathContextPtr xpathCtx ); LIBCMIS_API std::string getXPathValue( xmlXPathContextPtr xpathCtx, std::string req ); LIBCMIS_API xmlDocPtr wrapInDoc( xmlNodePtr entryNode ); /** Utility extracting an attribute value from an Xml Node, based on the attribute name. If the defaultValue is NULL and the attribute can't be found then throw an exception. */ LIBCMIS_API std::string getXmlNodeAttributeValue( xmlNodePtr node, const char* attributeName, const char* defaultValue = NULL ); /** Parse a xsd:dateTime string and return the corresponding UTC posix time. */ LIBCMIS_API boost::posix_time::ptime parseDateTime( std::string dateTimeStr ); /// Write a UTC time object to an xsd:dateTime string LIBCMIS_API std::string writeDateTime( boost::posix_time::ptime time ); LIBCMIS_API bool parseBool( std::string str ); LIBCMIS_API long parseInteger( std::string str ); LIBCMIS_API double parseDouble( std::string str ); /** Trim spaces on the left and right of a string. */ LIBCMIS_API std::string trim( const std::string& str ); LIBCMIS_API std::string base64encode( const std::string& str ); LIBCMIS_API std::string sha1( const std::string& str ); LIBCMIS_API int stringstream_write_callback(void * context, const char * s, int len); LIBCMIS_API std::string escape( std::string str ); LIBCMIS_API std::string unescape( std::string str ); } #endif libcmis-0.5.2/inc/libcmis/document.hxx0000664000175000017500000001305513407453643014642 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _DOCUMENT_HXX_ #define _DOCUMENT_HXX_ #include #include #include #include #include "libcmis/exception.hxx" #include "libcmis/libcmis-api.h" #include "libcmis/object.hxx" namespace libcmis { class Folder; class Session; /** Interface for a CMIS Document object. */ class LIBCMIS_API Document : public virtual Object { public: Document( Session* session ) : Object( session ) { } virtual ~Document( ) { } /** Get the folder parents for the document. Note that an unfiled document will have no parent folder. @return the parents folder if any. */ virtual std::vector< boost::shared_ptr< Folder > > getParents( ) = 0; /** Get the content stream without using a temporary file.

The stream may not contain anything if there is no content or if something wrong happened during the download.

@param streamId of the rendition @return An input stream to read the data from. @throws Exception if anything wrong happened during the file transfer. In such a case, the content of the stream can't be guaranteed. */ virtual boost::shared_ptr< std::istream > getContentStream( std::string streamId = std::string( ) ) = 0; /** Set or replace the content stream of the document. @param is the output stream containing the new data for the content stream @param contentType the mime-type of the new content stream @param filename the filename to set for the file @param overwrite if set to false, don't overwrite the content stream if one is already set. @throw Exception if anything happens during the upload like a wrong authentication, no rights to set the stream, server doesn't have the ContentStreamUpdatability capability. */ virtual void setContentStream( boost::shared_ptr< std::ostream > os, std::string contentType, std::string filename, bool overwrite = true ) = 0; /** Get the content mime type. */ virtual std::string getContentType( ); /** Get the content stream filename. */ virtual std::string getContentFilename( ); /** Get the content length in bytes. */ virtual long getContentLength( ); /** Checks out the document and returns the object corresponding to the created Private Working Copy. \return the Private Working Copy document */ virtual boost::shared_ptr< Document > checkOut( ) = 0; /** Cancels the checkout if the document is a private working copy, or throws an exception. */ virtual void cancelCheckout( ) = 0; /** Check in the private working copy and create a new version or throw an exception. The current object will be updated to reflect the changes performed on the server side. \param isMajor defines it the version to create is a major or minor one \param comment contains the checkin comment \param properties the properties to set the new version \param stream the content stream to set for the new version \param contentType the mime type of the stream to set \return the document with the new version */ virtual boost::shared_ptr< Document > checkIn( bool isMajor, std::string comment, const std::map< std::string, PropertyPtr >& properties, boost::shared_ptr< std::ostream > stream, std::string contentType, std::string fileName ) = 0; virtual std::vector< boost::shared_ptr< Document > > getAllVersions( ) = 0; // virtual methods form Object virtual std::vector< std::string > getPaths( ); virtual std::string toString( ); }; typedef boost::shared_ptr< Document > DocumentPtr; } #endif libcmis-0.5.2/inc/libcmis/property.hxx0000664000175000017500000000573613407453622014714 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _PROPERTY_HXX_ #define _PROPERTY_HXX_ #include #include #include #include #include #include #include "libcmis/libcmis-api.h" #include "libcmis/property-type.hxx" #include "libcmis/xmlserializable.hxx" namespace libcmis { class ObjectType; class LIBCMIS_API Property : public XmlSerializable { private: PropertyTypePtr m_propertyType; std::vector< std::string > m_strValues; std::vector< bool > m_boolValues; std::vector< long > m_longValues; std::vector< double > m_doubleValues; std::vector< boost::posix_time::ptime > m_dateTimeValues; protected: Property( ); public: /** Property constructor allowing to use different values for the id and names. */ Property( PropertyTypePtr propertyType, std::vector< std::string > strValues ); ~Property( ){ } PropertyTypePtr getPropertyType( ) { return m_propertyType; } std::vector< boost::posix_time::ptime > getDateTimes( ) { return m_dateTimeValues; } std::vector< bool > getBools( ) { return m_boolValues; } std::vector< std::string > getStrings( ) { return m_strValues; } std::vector< long > getLongs( ) { return m_longValues; } std::vector< double > getDoubles( ) { return m_doubleValues; } void setPropertyType( PropertyTypePtr propertyType); void setValues( std::vector< std::string > strValues ); void toXml( xmlTextWriterPtr writer ); std::string toString( ); }; typedef boost::shared_ptr< Property > PropertyPtr; typedef std::map< std::string, libcmis::PropertyPtr > PropertyPtrMap; PropertyPtr parseProperty( xmlNodePtr node, boost::shared_ptr< ObjectType > objectType ); } #endif libcmis-0.5.2/inc/libcmis/libcmis.hxx0000664000175000017500000000321313407460623014435 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_HXX_ #define _LIBCMIS_HXX_ #include "libcmis/libcmis-api.h" #include "libcmis/allowable-actions.hxx" #include "libcmis/document.hxx" #include "libcmis/exception.hxx" #include "libcmis/folder.hxx" #include "libcmis/oauth2-data.hxx" #include "libcmis/object-type.hxx" #include "libcmis/object.hxx" #include "libcmis/property-type.hxx" #include "libcmis/property.hxx" #include "libcmis/rendition.hxx" #include "libcmis/repository.hxx" #include "libcmis/session-factory.hxx" #include "libcmis/session.hxx" #include "libcmis/xml-utils.hxx" #include "libcmis/xmlserializable.hxx" #endif libcmis-0.5.2/inc/libcmis/property-type.hxx0000664000175000017500000001131213407453626015662 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _PROPERTY_TYPE_HXX_ #define _PROPERTY_TYPE_HXX_ #include #include #include #include "libcmis/libcmis-api.h" namespace libcmis { class ObjectType; typedef boost::shared_ptr< ObjectType > ObjectTypePtr; class LIBCMIS_API PropertyType { public: enum Type { String, Integer, Decimal, Bool, DateTime }; private: std::string m_id; std::string m_localName; std::string m_localNamespace; std::string m_displayName; std::string m_queryName; Type m_type; std::string m_xmlType; bool m_multiValued; bool m_updatable; bool m_inherited; bool m_required; bool m_queryable; bool m_orderable; bool m_openChoice; bool m_temporary; public: /// Default constructor, mostly present for testing. PropertyType( ); PropertyType( xmlNodePtr node ); PropertyType( const PropertyType& copy ); /// constructor for temporary type definitions PropertyType( std::string type, std::string id, std::string localName, std::string displayName, std::string queryName ); virtual ~PropertyType( ) { }; PropertyType& operator=( const PropertyType& copy ); std::string getId( ) { return m_id; } std::string getLocalName( ) { return m_localName; } std::string getLocalNamespace( ) { return m_localNamespace; } std::string getDisplayName( ) { return m_displayName; } std::string getQueryName( ) { return m_queryName; } Type getType( ) { return m_type; } std::string getXmlType( ) { return m_xmlType; } bool isMultiValued( ) { return m_multiValued; } bool isUpdatable( ) { return m_updatable; } bool isInherited( ) { return m_inherited; } bool isRequired( ) { return m_required; } bool isQueryable( ) { return m_queryable; } bool isOrderable( ) { return m_orderable; } bool isOpenChoice( ) { return m_openChoice; } void setId( std::string id ) { m_id = id; } void setLocalName( std::string localName ) { m_localName = localName; } void setLocalNamespace( std::string localNamespace ) { m_localNamespace = localNamespace; } void setDisplayName( std::string displayName ) { m_displayName = displayName; } void setQueryName( std::string queryName ) { m_queryName = queryName; } void setType( Type type ) { m_type = type; } void setMultiValued( bool multivalued ) { m_multiValued = multivalued; } void setUpdatable( bool updatable ) { m_updatable = updatable; } void setInherited( bool inherited ) { m_inherited = inherited; } void setRequired( bool required ) { m_required = required; } void setQueryable( bool queryable ) { m_queryable = queryable; } void setOrderable( bool orderable ) { m_orderable = orderable; } void setOpenChoice( bool openChoice ) { m_openChoice = openChoice; } void setTypeFromXml( std::string typeStr ); void setTypeFromJsonType( std::string jsonType ); void update( std::vector< ObjectTypePtr > typesDefs ); }; typedef boost::shared_ptr< PropertyType > PropertyTypePtr; } #endif libcmis-0.5.2/inc/libcmis/Makefile.am0000664000175000017500000000061313407453530014316 00000000000000libcmisdir = $(includedir)/libcmis-@LIBCMIS_API_VERSION@/libcmis dist_libcmis_HEADERS = \ allowable-actions.hxx \ document.hxx \ exception.hxx \ folder.hxx \ libcmis-api.h \ libcmis.hxx \ oauth2-data.hxx \ object-type.hxx \ object.hxx \ property-type.hxx \ property.hxx \ rendition.hxx \ repository.hxx \ session-factory.hxx \ session.hxx \ xml-utils.hxx \ xmlserializable.hxx libcmis-0.5.2/inc/libcmis/folder.hxx0000664000175000017500000000531013407453726014274 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _FOLDER_HXX_ #define _FOLDER_HXX_ #include #include #include #include "libcmis/exception.hxx" #include "libcmis/libcmis-api.h" #include "libcmis/object.hxx" namespace libcmis { class Document; class Session; struct LIBCMIS_API UnfileObjects { enum Type { Unfile, DeleteSingleFiled, Delete }; }; /** Class representing a CMIS folder. */ class LIBCMIS_API Folder : public virtual Object { public: Folder( Session* session ) : Object( session ) { } virtual ~Folder() { } virtual std::vector< std::string > getPaths( ); virtual boost::shared_ptr< Folder > getFolderParent( ); virtual std::vector< ObjectPtr > getChildren( ) = 0; virtual std::string getParentId( ); virtual std::string getPath( ); virtual bool isRootFolder( ); virtual boost::shared_ptr< Folder > createFolder( const std::map< std::string, PropertyPtr >& properties ) = 0; virtual boost::shared_ptr< Document > createDocument( const std::map< std::string, PropertyPtr >& properties, boost::shared_ptr< std::ostream > os, std::string contentType, std::string fileName ) = 0; virtual std::vector< std::string > removeTree( bool allVersion = true, UnfileObjects::Type unfile = UnfileObjects::Delete, bool continueOnError = false ) = 0; virtual std::string toString( ); }; typedef boost::shared_ptr< Folder > FolderPtr; } #endif libcmis-0.5.2/inc/libcmis-c/0000775000175000017500000000000013411152375012560 500000000000000libcmis-0.5.2/inc/libcmis-c/object.h0000664000175000017500000001170313407460303014117 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_OBJECT_H_ #define _LIBCMIS_OBJECT_H_ #include #include "libcmis-c/libcmis-c-api.h" #include "libcmis-c/types.h" #ifdef __cplusplus extern "C" { #endif LIBCMIS_C_API void libcmis_vector_object_free( libcmis_vector_object_Ptr vector ); LIBCMIS_C_API size_t libcmis_vector_object_size( libcmis_vector_object_Ptr vector ); LIBCMIS_C_API libcmis_ObjectPtr libcmis_vector_object_get( libcmis_vector_object_Ptr vector, size_t i ); LIBCMIS_C_API void libcmis_object_free( libcmis_ObjectPtr object ); /** The resulting value needs to be free'd. */ LIBCMIS_C_API char* libcmis_object_getId( libcmis_ObjectPtr object ); /** The resulting value needs to be free'd. */ LIBCMIS_C_API char* libcmis_object_getName( libcmis_ObjectPtr object ); LIBCMIS_C_API libcmis_vector_string_Ptr libcmis_object_getPaths( libcmis_ObjectPtr object ); /** The resulting value needs to be free'd. */ LIBCMIS_C_API char* libcmis_object_getBaseType( libcmis_ObjectPtr object ); /** The resulting value needs to be free'd. */ LIBCMIS_C_API char* libcmis_object_getType( libcmis_ObjectPtr object ); /** The resulting value needs to be free'd. */ LIBCMIS_C_API char* libcmis_object_getCreatedBy( libcmis_ObjectPtr object ); LIBCMIS_C_API time_t libcmis_object_getCreationDate( libcmis_ObjectPtr object ); /** The resulting value needs to be free'd. */ LIBCMIS_C_API char* libcmis_object_getLastModifiedBy( libcmis_ObjectPtr object ); LIBCMIS_C_API time_t libcmis_object_getLastModificationDate( libcmis_ObjectPtr object ); /** The resulting value needs to be free'd. */ LIBCMIS_C_API char* libcmis_object_getChangeToken( libcmis_ObjectPtr object ); LIBCMIS_C_API bool libcmis_object_isImmutable( libcmis_ObjectPtr object ); /** The resulting value needs to be free'd. */ LIBCMIS_C_API libcmis_vector_string_Ptr libcmis_object_getSecondaryTypes( libcmis_ObjectPtr object ); /** The resulting value needs to be free'd. */ LIBCMIS_C_API char* libcmis_object_getThumbnailUrl( libcmis_ObjectPtr object ); LIBCMIS_C_API libcmis_vector_rendition_Ptr libcmis_object_getRenditions( libcmis_ObjectPtr object, libcmis_ErrorPtr error ); LIBCMIS_C_API libcmis_ObjectPtr LIBCMIS_C_API libcmis_object_addSecondaryType( libcmis_ObjectPtr object, const char* id, libcmis_vector_property_Ptr properties, libcmis_ErrorPtr error ); LIBCMIS_C_API libcmis_ObjectPtr LIBCMIS_C_API libcmis_object_removeSecondaryType( libcmis_ObjectPtr object, const char* id, libcmis_ErrorPtr error ); LIBCMIS_C_API libcmis_vector_property_Ptr libcmis_object_getProperties( libcmis_ObjectPtr object ); LIBCMIS_C_API libcmis_PropertyPtr libcmis_object_getProperty( libcmis_ObjectPtr object, const char* name ); LIBCMIS_C_API void libcmis_object_setProperty( libcmis_ObjectPtr object, libcmis_PropertyPtr property ); LIBCMIS_C_API libcmis_ObjectPtr libcmis_object_updateProperties( libcmis_ObjectPtr object, libcmis_vector_property_Ptr properties, libcmis_ErrorPtr error ); LIBCMIS_C_API libcmis_ObjectTypePtr libcmis_object_getTypeDescription( libcmis_ObjectPtr object ); LIBCMIS_C_API libcmis_AllowableActionsPtr libcmis_object_getAllowableActions( libcmis_ObjectPtr object ); LIBCMIS_C_API void libcmis_object_refresh( libcmis_ObjectPtr object, libcmis_ErrorPtr error ); LIBCMIS_C_API time_t libcmis_object_getRefreshTimestamp( libcmis_ObjectPtr object ); LIBCMIS_C_API void libcmis_object_remove( libcmis_ObjectPtr object, bool allVersions, libcmis_ErrorPtr error ); LIBCMIS_C_API void libcmis_object_move( libcmis_ObjectPtr object, libcmis_FolderPtr source, libcmis_FolderPtr dest, libcmis_ErrorPtr error ); /** The resulting value needs to be free'd. */ LIBCMIS_C_API char* libcmis_object_toString( libcmis_ObjectPtr object ); #ifdef __cplusplus } #endif #endif libcmis-0.5.2/inc/libcmis-c/oauth2-data.h0000664000175000017500000000417113407460303014763 00000000000000 /* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_OAUTH2_DATA_H_ #define _LIBCMIS_OAUTH2_DATA_H_ #ifdef __cplusplus extern "C" { #endif #include "libcmis-c/libcmis-c-api.h" #include "libcmis-c/types.h" LIBCMIS_C_API libcmis_OAuth2DataPtr libcmis_oauth2data_create( char* authUrl, char* tokenUrl, char* scopes, char* redirectUri, char* clientId, char* clientSecret ); LIBCMIS_C_API void libcmis_oauth2data_free( libcmis_OAuth2DataPtr oauth2 ); LIBCMIS_C_API bool libcmis_oauth2data_isComplete( libcmis_OAuth2DataPtr oauth2 ); LIBCMIS_C_API const char* libcmis_oauth2data_getAuthUrl( libcmis_OAuth2DataPtr oauth2 ); LIBCMIS_C_API const char* libcmis_oauth2data_getTokenUrl( libcmis_OAuth2DataPtr oauth2 ); LIBCMIS_C_API const char* libcmis_oauth2data_getClientId( libcmis_OAuth2DataPtr oauth2 ); LIBCMIS_C_API const char* libcmis_oauth2data_getClientSecret( libcmis_OAuth2DataPtr oauth2 ); LIBCMIS_C_API const char* libcmis_oauth2data_getScope( libcmis_OAuth2DataPtr oauth2 ); LIBCMIS_C_API const char* libcmis_oauth2data_getRedirectUri( libcmis_OAuth2DataPtr oauth2 ); #ifdef __cplusplus } #endif #endif libcmis-0.5.2/inc/libcmis-c/Makefile.in0000664000175000017500000004313413407705040014550 00000000000000# Makefile.in generated by automake 1.16.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2018 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = inc/libcmis-c ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \ $(top_srcdir)/m4/ax_cxx_compile_stdcxx_11.m4 \ $(top_srcdir)/m4/ax_gcc_func_attribute.m4 \ $(top_srcdir)/m4/boost.m4 $(top_srcdir)/m4/libtool.m4 \ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(dist_libcmis_c_HEADERS) \ $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = SOURCES = DIST_SOURCES = am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; am__install_max = 40 am__nobase_strip_setup = \ srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` am__nobase_strip = \ for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" am__nobase_list = $(am__nobase_strip_setup); \ for p in $$list; do echo "$$p $$p"; done | \ sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ if (++n[$$2] == $(am__install_max)) \ { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ END { for (dir in files) print dir, files[dir] }' am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' am__uninstall_files_from_dir = { \ test -z "$$files" \ || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ $(am__cd) "$$dir" && rm -f $$files; }; \ } am__installdirs = "$(DESTDIR)$(libcmis_cdir)" HEADERS = $(dist_libcmis_c_HEADERS) am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is # *not* preserved. am__uniquify_input = $(AWK) '\ BEGIN { nonempty = 0; } \ { items[$$0] = 1; nonempty = 1; } \ END { if (nonempty) { for (i in items) print i; }; } \ ' # Make sure the list of sources is unique. This is necessary because, # e.g., the same source file might be shared among _SOURCES variables # for different programs/libraries. am__define_uniq_tagged_files = \ list='$(am__tagged_files)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags am__DIST_COMMON = $(srcdir)/Makefile.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ BOOST_CPPFLAGS = @BOOST_CPPFLAGS@ BOOST_DATE_TIME_LDFLAGS = @BOOST_DATE_TIME_LDFLAGS@ BOOST_DATE_TIME_LDPATH = @BOOST_DATE_TIME_LDPATH@ BOOST_DATE_TIME_LIBS = @BOOST_DATE_TIME_LIBS@ BOOST_LDPATH = @BOOST_LDPATH@ BOOST_PROGRAM_OPTIONS_LDFLAGS = @BOOST_PROGRAM_OPTIONS_LDFLAGS@ BOOST_PROGRAM_OPTIONS_LDPATH = @BOOST_PROGRAM_OPTIONS_LDPATH@ BOOST_PROGRAM_OPTIONS_LIBS = @BOOST_PROGRAM_OPTIONS_LIBS@ BOOST_ROOT = @BOOST_ROOT@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPCHECK = @CPPCHECK@ CPPCHECK_PARALLELISM = @CPPCHECK_PARALLELISM@ CPPFLAGS = @CPPFLAGS@ CPPUNIT_CFLAGS = @CPPUNIT_CFLAGS@ CPPUNIT_LIBS = @CPPUNIT_LIBS@ CURL_CFLAGS = @CURL_CFLAGS@ CURL_LIBS = @CURL_LIBS@ CXX = @CXX@ CXXCPP = @CXXCPP@ CXXDEPMODE = @CXXDEPMODE@ CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DISTCHECK_CONFIGURE_FLAGS = @DISTCHECK_CONFIGURE_FLAGS@ DLLTOOL = @DLLTOOL@ DOCBOOK2MAN = @DOCBOOK2MAN@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ GENHTML = @GENHTML@ GREP = @GREP@ HAVE_CXX11 = @HAVE_CXX11@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LCOV = @LCOV@ LD = @LD@ LDFLAGS = @LDFLAGS@ LIBCMIS_API_VERSION = @LIBCMIS_API_VERSION@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ NPROC = @NPROC@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SRCDIR = @SRCDIR@ STRIP = @STRIP@ VERSION = @VERSION@ XML2_CFLAGS = @XML2_CFLAGS@ XML2_LIBS = @XML2_LIBS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ libcmis_cdir = $(includedir)/libcmis-c-@LIBCMIS_API_VERSION@/libcmis-c dist_libcmis_c_HEADERS = \ allowable-actions.h \ document.h \ error.h \ folder.h \ libcmis-c-api.h \ libcmis-c.h \ oauth2-data.h \ object-type.h \ object.h \ property-type.h \ property.h \ rendition.h \ repository.h \ session-factory.h \ session.h \ types.h \ vectors.h all: all-am .SUFFIXES: $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign inc/libcmis-c/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign inc/libcmis-c/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs install-dist_libcmis_cHEADERS: $(dist_libcmis_c_HEADERS) @$(NORMAL_INSTALL) @list='$(dist_libcmis_c_HEADERS)'; test -n "$(libcmis_cdir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(libcmis_cdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(libcmis_cdir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(libcmis_cdir)'"; \ $(INSTALL_HEADER) $$files "$(DESTDIR)$(libcmis_cdir)" || exit $$?; \ done uninstall-dist_libcmis_cHEADERS: @$(NORMAL_UNINSTALL) @list='$(dist_libcmis_c_HEADERS)'; test -n "$(libcmis_cdir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(libcmis_cdir)'; $(am__uninstall_files_from_dir) ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique tags: tags-am TAGS: tags tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ if test $$# -gt 0; then \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ "$$@" $$unique; \ else \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$unique; \ fi; \ fi ctags: ctags-am CTAGS: ctags ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" cscopelist: cscopelist-am cscopelist-am: $(am__tagged_files) list='$(am__tagged_files)'; \ case "$(srcdir)" in \ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ *) sdir=$(subdir)/$(srcdir) ;; \ esac; \ for i in $$list; do \ if test -f "$$i"; then \ echo "$(subdir)/$$i"; \ else \ echo "$$sdir/$$i"; \ fi; \ done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(HEADERS) installdirs: for dir in "$(DESTDIR)$(libcmis_cdir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic clean-libtool mostlyclean-am distclean: distclean-am -rm -f Makefile distclean-am: clean-am distclean-generic distclean-tags dvi: dvi-am dvi-am: html: html-am html-am: info: info-am info-am: install-data-am: install-dist_libcmis_cHEADERS install-dvi: install-dvi-am install-dvi-am: install-exec-am: install-html: install-html-am install-html-am: install-info: install-info-am install-info-am: install-man: install-pdf: install-pdf-am install-pdf-am: install-ps: install-ps-am install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-generic mostlyclean-libtool pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-dist_libcmis_cHEADERS .MAKE: install-am install-strip .PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \ clean-libtool cscopelist-am ctags ctags-am distclean \ distclean-generic distclean-libtool distclean-tags distdir dvi \ dvi-am html html-am info info-am install install-am \ install-data install-data-am install-dist_libcmis_cHEADERS \ install-dvi install-dvi-am install-exec install-exec-am \ install-html install-html-am install-info install-info-am \ install-man install-pdf install-pdf-am install-ps \ install-ps-am install-strip installcheck installcheck-am \ installdirs maintainer-clean maintainer-clean-generic \ mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ ps ps-am tags tags-am uninstall uninstall-am \ uninstall-dist_libcmis_cHEADERS .PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: libcmis-0.5.2/inc/libcmis-c/error.h0000664000175000017500000000301013407460372014000 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_ERROR_H_ #define _LIBCMIS_ERROR_H_ #ifdef __cplusplus extern "C" { #endif #include "libcmis-c/libcmis-c-api.h" #include "libcmis-c/types.h" LIBCMIS_C_API libcmis_ErrorPtr libcmis_error_create( ); LIBCMIS_C_API void libcmis_error_free( libcmis_ErrorPtr e ); LIBCMIS_C_API const char* libcmis_error_getMessage( libcmis_ErrorPtr e ); LIBCMIS_C_API const char* libcmis_error_getType( libcmis_ErrorPtr e ); #ifdef __cplusplus } #endif #endif libcmis-0.5.2/inc/libcmis-c/property.h0000664000175000017500000000527613407460313014546 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_PROPERTY_HXX_ #define _LIBCMIS_PROPERTY_HXX_ #ifdef __cplusplus extern "C" { #endif #include "libcmis-c/libcmis-c-api.h" #include "libcmis-c/types.h" LIBCMIS_C_API libcmis_vector_property_Ptr libcmis_vector_property_create( ); LIBCMIS_C_API void libcmis_vector_property_free( libcmis_vector_property_Ptr vector ); LIBCMIS_C_API size_t libcmis_vector_property_size( libcmis_vector_property_Ptr vector ); LIBCMIS_C_API libcmis_PropertyPtr libcmis_vector_property_get( libcmis_vector_property_Ptr vector, size_t i ); /** The item object can be deleted after this call safely. */ LIBCMIS_C_API void libcmis_vector_property_append( libcmis_vector_property_Ptr vector, libcmis_PropertyPtr item ); LIBCMIS_C_API libcmis_PropertyPtr libcmis_property_create( libcmis_PropertyTypePtr type, const char** strValues, size_t size ); LIBCMIS_C_API void libcmis_property_free( libcmis_PropertyPtr property ); LIBCMIS_C_API libcmis_PropertyTypePtr libcmis_property_getPropertyType( libcmis_PropertyPtr property ); LIBCMIS_C_API libcmis_vector_time_Ptr libcmis_property_getDateTimes( libcmis_PropertyPtr property ); LIBCMIS_C_API libcmis_vector_bool_Ptr libcmis_property_getBools( libcmis_PropertyPtr property ); LIBCMIS_C_API libcmis_vector_string_Ptr libcmis_property_getStrings( libcmis_PropertyPtr property ); LIBCMIS_C_API libcmis_vector_long_Ptr libcmis_property_getLongs( libcmis_PropertyPtr property ); LIBCMIS_C_API libcmis_vector_double_Ptr libcmis_property_getDoubles( libcmis_PropertyPtr property ); LIBCMIS_C_API void libcmis_property_setValues( libcmis_PropertyPtr property, const char** strValues, size_t size ); #ifdef __cplusplus } #endif #endif libcmis-0.5.2/inc/libcmis-c/repository.h0000664000175000017500000000711513407460322015073 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _REPOSITORY_H_ #define _REPOSITORY_H_ #ifdef __cplusplus extern "C" { #endif #include #include "libcmis-c/libcmis-c-api.h" #include "libcmis-c/types.h" LIBCMIS_C_API void libcmis_vector_repository_free( libcmis_vector_Repository_Ptr vector ); LIBCMIS_C_API size_t libcmis_vector_repository_size( libcmis_vector_Repository_Ptr vector ); LIBCMIS_C_API libcmis_RepositoryPtr libcmis_vector_repository_get( libcmis_vector_Repository_Ptr vector, size_t i ); LIBCMIS_C_API libcmis_RepositoryPtr libcmis_repository_create( xmlNodePtr node ); LIBCMIS_C_API void libcmis_repository_free( libcmis_RepositoryPtr repository ); /** The resulting value needs to be freed. */ LIBCMIS_C_API char* libcmis_repository_getId( libcmis_RepositoryPtr repository ); /** The resulting value needs to be freed. */ LIBCMIS_C_API char* libcmis_repository_getName( libcmis_RepositoryPtr repository ); /** The resulting value needs to be freed. */ LIBCMIS_C_API char* libcmis_repository_getDescription( libcmis_RepositoryPtr repository ); /** The resulting value needs to be freed. */ LIBCMIS_C_API char* libcmis_repository_getVendorName( libcmis_RepositoryPtr repository ); /** The resulting value needs to be freed. */ LIBCMIS_C_API char* libcmis_repository_getProductName( libcmis_RepositoryPtr repository ); /** The resulting value needs to be freed. */ LIBCMIS_C_API char* libcmis_repository_getProductVersion( libcmis_RepositoryPtr repository ); /** The resulting value needs to be freed. */ LIBCMIS_C_API char* libcmis_repository_getRootId( libcmis_RepositoryPtr repository ); /** The resulting value needs to be freed. */ LIBCMIS_C_API char* libcmis_repository_getCmisVersionSupported( libcmis_RepositoryPtr repository ); /** The resulting value needs to be freed. */ LIBCMIS_C_API char* libcmis_repository_getThinClientUri( libcmis_RepositoryPtr repository ); /** The resulting value needs to be freed. */ LIBCMIS_C_API char* libcmis_repository_getPrincipalAnonymous( libcmis_RepositoryPtr repository ); /** The resulting value needs to be freed. */ LIBCMIS_C_API char* libcmis_repository_getPrincipalAnyone( libcmis_RepositoryPtr repository ); /** The resulting value needs to be freed. */ LIBCMIS_C_API char* libcmis_repository_getCapability( libcmis_RepositoryPtr repository, libcmis_repository_capability_Type capability ); LIBCMIS_C_API bool libcmis_repository_getCapabilityAsBool( libcmis_RepositoryPtr repository, libcmis_repository_capability_Type capability ); #ifdef __cplusplus } #endif #endif libcmis-0.5.2/inc/libcmis-c/allowable-actions.h0000664000175000017500000000321513407460364016257 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_ALLOWABLE_ACTIONS_H_ #define _LIBCMIS_ALLOWABLE_ACTIONS_H_ #ifdef __cplusplus extern "C" { #endif #include "libcmis-c/libcmis-c-api.h" #include "libcmis-c/types.h" LIBCMIS_C_API void libcmis_allowable_actions_free( libcmis_AllowableActionsPtr allowable ); LIBCMIS_C_API bool libcmis_allowable_actions_isAllowed( libcmis_AllowableActionsPtr allowable, libcmis_allowable_actions_Type action ); LIBCMIS_C_API bool libcmis_allowable_actions_isDefined( libcmis_AllowableActionsPtr allowable, libcmis_allowable_actions_Type action ); #ifdef __cplusplus } #endif #endif libcmis-0.5.2/inc/libcmis-c/vectors.h0000664000175000017500000000502513407460357014347 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_VECTORS_HXX_ #define _LIBCMIS_VECTORS_HXX_ #ifdef __cplusplus extern "C" { #endif #include #include "libcmis-c/libcmis-c-api.h" #include "libcmis-c/types.h" LIBCMIS_C_API void libcmis_vector_bool_free( libcmis_vector_bool_Ptr vector ); LIBCMIS_C_API size_t libcmis_vector_bool_size( libcmis_vector_bool_Ptr vector ); LIBCMIS_C_API bool libcmis_vector_bool_get( libcmis_vector_bool_Ptr vector, size_t i ); LIBCMIS_C_API void libcmis_vector_string_free( libcmis_vector_string_Ptr vector ); LIBCMIS_C_API size_t libcmis_vector_string_size( libcmis_vector_string_Ptr vector ); LIBCMIS_C_API const char* libcmis_vector_string_get( libcmis_vector_string_Ptr vector, size_t i ); LIBCMIS_C_API void libcmis_vector_long_free( libcmis_vector_long_Ptr vector ); LIBCMIS_C_API size_t libcmis_vector_long_size( libcmis_vector_long_Ptr vector ); LIBCMIS_C_API long libcmis_vector_long_get( libcmis_vector_long_Ptr vector, size_t i ); LIBCMIS_C_API void libcmis_vector_double_free( libcmis_vector_double_Ptr vector ); LIBCMIS_C_API size_t libcmis_vector_double_size( libcmis_vector_double_Ptr vector ); LIBCMIS_C_API double libcmis_vector_double_get( libcmis_vector_double_Ptr vector, size_t i ); LIBCMIS_C_API void libcmis_vector_time_free( libcmis_vector_time_Ptr vector ); LIBCMIS_C_API size_t libcmis_vector_time_size( libcmis_vector_time_Ptr vector ); LIBCMIS_C_API time_t libcmis_vector_time_get( libcmis_vector_time_Ptr vector, size_t i ); #ifdef __cplusplus } #endif #endif libcmis-0.5.2/inc/libcmis-c/object-type.h0000664000175000017500000001045713407460303015103 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_OBJECT_TYPE_H_ #define _LIBCMIS_OBJECT_TYPE_H_ #ifdef __cplusplus extern "C" { #endif #include "libcmis-c/libcmis-c-api.h" #include "libcmis-c/types.h" LIBCMIS_C_API void libcmis_vector_object_type_free( libcmis_vector_object_type_Ptr vector ); LIBCMIS_C_API size_t libcmis_vector_object_type_size( libcmis_vector_object_type_Ptr vector ); LIBCMIS_C_API libcmis_ObjectTypePtr libcmis_vector_object_type_get( libcmis_vector_object_type_Ptr vector, size_t i ); LIBCMIS_C_API void libcmis_object_type_free( libcmis_ObjectTypePtr type ); /** The resulting value needs to be freed */ LIBCMIS_C_API char* libcmis_object_type_getId( libcmis_ObjectTypePtr type ); /** The resulting value needs to be freed */ LIBCMIS_C_API char* libcmis_object_type_getLocalName( libcmis_ObjectTypePtr type ); /** The resulting value needs to be freed */ LIBCMIS_C_API char* libcmis_object_type_getLocalNamespace( libcmis_ObjectTypePtr type ); /** The resulting value needs to be freed */ LIBCMIS_C_API char* libcmis_object_type_getQueryName( libcmis_ObjectTypePtr type ); /** The resulting value needs to be freed */ LIBCMIS_C_API char* libcmis_object_type_getDisplayName( libcmis_ObjectTypePtr type ); /** The resulting value needs to be freed */ LIBCMIS_C_API char* libcmis_object_type_getDescription( libcmis_ObjectTypePtr type ); LIBCMIS_C_API libcmis_ObjectTypePtr libcmis_object_type_getParentType( libcmis_ObjectTypePtr type, libcmis_ErrorPtr error ); LIBCMIS_C_API libcmis_ObjectTypePtr libcmis_object_type_getBaseType( libcmis_ObjectTypePtr type, libcmis_ErrorPtr error ); LIBCMIS_C_API libcmis_vector_object_type_Ptr libcmis_object_type_getChildren( libcmis_ObjectTypePtr type, libcmis_ErrorPtr error ); /** The resulting value needs to be freed \since libcmis 0.4 */ LIBCMIS_C_API char* libcmis_object_type_getParentTypeId( libcmis_ObjectTypePtr type ); /** The resulting value needs to be freed \since libcmis 0.4 */ LIBCMIS_C_API char* libcmis_object_type_getBaseTypeId( libcmis_ObjectTypePtr type ); LIBCMIS_C_API bool libcmis_object_type_isCreatable( libcmis_ObjectTypePtr type ); LIBCMIS_C_API bool libcmis_object_type_isFileable( libcmis_ObjectTypePtr type ); LIBCMIS_C_API bool libcmis_object_type_isQueryable( libcmis_ObjectTypePtr type ); LIBCMIS_C_API bool libcmis_object_type_isFulltextIndexed( libcmis_ObjectTypePtr type ); LIBCMIS_C_API bool libcmis_object_type_isIncludedInSupertypeQuery( libcmis_ObjectTypePtr type ); LIBCMIS_C_API bool libcmis_object_type_isControllablePolicy( libcmis_ObjectTypePtr type ); LIBCMIS_C_API bool libcmis_object_type_isControllableACL( libcmis_ObjectTypePtr type ); LIBCMIS_C_API bool libcmis_object_type_isVersionable( libcmis_ObjectTypePtr type ); LIBCMIS_C_API libcmis_object_type_ContentStreamAllowed libcmis_object_type_getContentStreamAllowed( libcmis_ObjectTypePtr type ); LIBCMIS_C_API libcmis_vector_property_type_Ptr libcmis_object_type_getPropertiesTypes( libcmis_ObjectTypePtr type ); LIBCMIS_C_API libcmis_PropertyTypePtr libcmis_object_type_getPropertyType( libcmis_ObjectTypePtr type, const char* id ); /** The resulting value needs to be freed */ LIBCMIS_C_API char* libcmis_object_type_toString( libcmis_ObjectTypePtr type ); #ifdef __cplusplus } #endif #endif libcmis-0.5.2/inc/libcmis-c/session.h0000664000175000017500000000510513407460334014337 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_SESSION_H_ #define _LIBCMIS_SESSION_H_ #ifdef __cplusplus extern "C" { #endif #include "libcmis-c/libcmis-c-api.h" #include "libcmis-c/types.h" LIBCMIS_C_API void libcmis_session_free( libcmis_SessionPtr session ); LIBCMIS_C_API libcmis_RepositoryPtr libcmis_session_getRepository( libcmis_SessionPtr session, libcmis_ErrorPtr error ); LIBCMIS_C_API libcmis_vector_Repository_Ptr libcmis_session_getRepositories( libcmis_SessionPtr session ); LIBCMIS_C_API bool libcmis_session_setRepository( libcmis_SessionPtr session, const char* repositoryId ); LIBCMIS_C_API libcmis_FolderPtr libcmis_session_getRootFolder( libcmis_SessionPtr session, libcmis_ErrorPtr error ); LIBCMIS_C_API libcmis_ObjectPtr libcmis_session_getObject( libcmis_SessionPtr session, const char* id, libcmis_ErrorPtr error ); LIBCMIS_C_API libcmis_ObjectPtr libcmis_session_getObjectByPath( libcmis_SessionPtr session, const char* path, libcmis_ErrorPtr error ); LIBCMIS_C_API libcmis_FolderPtr libcmis_session_getFolder( libcmis_SessionPtr session, const char* id, libcmis_ErrorPtr error ); LIBCMIS_C_API libcmis_ObjectTypePtr libcmis_session_getType( libcmis_SessionPtr session, const char* id, libcmis_ErrorPtr error ); LIBCMIS_C_API libcmis_vector_object_type_Ptr libcmis_session_getBaseTypes( libcmis_SessionPtr session, libcmis_ErrorPtr error ); #ifdef __cplusplus } #endif #endif libcmis-0.5.2/inc/libcmis-c/session-factory.h0000664000175000017500000000501513407460325016004 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _SESSION_FACTORY_H_ #define _SESSION_FACTORY_H_ #ifdef __cplusplus extern "C" { #endif #include "libcmis-c/libcmis-c-api.h" #include "libcmis-c/types.h" LIBCMIS_C_API void libcmis_setAuthenticationCallback( libcmis_authenticationCallback callback ); LIBCMIS_C_API void libcmis_setCertValidationCallback( libcmis_certValidationCallback callback ); LIBCMIS_C_API void libcmis_setOAuth2AuthCodeProvider( libcmis_oauth2AuthCodeProvider callback ); LIBCMIS_C_API libcmis_oauth2AuthCodeProvider libcmis_getOAuth2AuthCodeProvider( ); LIBCMIS_C_API void libcmis_setProxySettings( char* proxy, char* noProxy, char* proxyUser, char* proxyPass ); LIBCMIS_C_API const char* libcmis_getProxy( ); LIBCMIS_C_API const char* libcmis_getNoProxy( ); LIBCMIS_C_API const char* libcmis_getProxyUser( ); LIBCMIS_C_API const char* libcmis_getProxyPass( ); LIBCMIS_C_API libcmis_SessionPtr libcmis_createSession( char* bindingUrl, char* repositoryId, char* username, char* password, bool noSslCheck, libcmis_OAuth2DataPtr oauth2, bool verbose, libcmis_ErrorPtr error ); /** \deprecated use libcmis_createSession and libcmis_session_getRepositories instead */ LIBCMIS_C_API libcmis_vector_Repository_Ptr libcmis_getRepositories( char* bindingUrl, char* username, char* password, bool verbose, libcmis_ErrorPtr error ); #ifdef __cplusplus } #endif #endif libcmis-0.5.2/inc/libcmis-c/types.h0000664000175000017500000001261513407414352014023 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_TYPES_H_ #define _LIBCMIS_TYPES_H_ #ifndef __cplusplus #include #else extern "C" { #endif #include /* Vectors of simple types */ typedef struct libcmis_vector_bool* libcmis_vector_bool_Ptr; typedef struct libcmis_vector_string* libcmis_vector_string_Ptr; typedef struct libcmis_vector_long* libcmis_vector_long_Ptr; typedef struct libcmis_vector_double* libcmis_vector_double_Ptr; typedef struct libcmis_vector_time* libcmis_vector_time_Ptr; typedef struct libcmis_vector_repository* libcmis_vector_Repository_Ptr; /* AllowableActions */ typedef struct libcmis_allowable_actions* libcmis_AllowableActionsPtr; typedef enum { libcmis_DeleteObject, libcmis_UpdateProperties, libcmis_GetFolderTree, libcmis_GetProperties, libcmis_GetObjectRelationships, libcmis_GetObjectParents, libcmis_GetFolderParent, libcmis_GetDescendants, libcmis_MoveObject, libcmis_DeleteContentStream, libcmis_CheckOut, libcmis_CancelCheckOut, libcmis_CheckIn, libcmis_SetContentStream, libcmis_GetAllVersions, libcmis_AddObjectToFolder, libcmis_RemoveObjectFromFolder, libcmis_GetContentStream, libcmis_ApplyPolicy, libcmis_GetAppliedPolicies, libcmis_RemovePolicy, libcmis_GetChildren, libcmis_CreateDocument, libcmis_CreateFolder, libcmis_CreateRelationship, libcmis_DeleteTree, libcmis_GetRenditions, libcmis_GetACL, libcmis_ApplyACL } libcmis_allowable_actions_Type; /* Document */ typedef struct libcmis_document* libcmis_DocumentPtr; typedef size_t ( *libcmis_writeFn )( const void*, size_t, size_t, void* ); typedef size_t ( *libcmis_readFn )( void*, size_t, size_t, void* ); typedef struct libcmis_vector_document* libcmis_vector_document_Ptr; /* Error */ typedef struct libcmis_error* libcmis_ErrorPtr; /* Folder */ typedef struct libcmis_folder* libcmis_FolderPtr; typedef struct libcmis_vector_folder* libcmis_vector_folder_Ptr; typedef enum { libcmis_Unfile, libcmis_DeleteSingleFiled, libcmis_Delete } libcmis_folder_UnfileObjects; /* ObjectType */ typedef struct libcmis_object_type* libcmis_ObjectTypePtr; typedef struct libcmis_vector_object_type* libcmis_vector_object_type_Ptr; typedef enum { libcmis_NotAllowed, libcmis_Allowed, libcmis_Required } libcmis_object_type_ContentStreamAllowed; /* Object */ typedef struct libcmis_object* libcmis_ObjectPtr; typedef struct libcmis_vector_object* libcmis_vector_object_Ptr; /* Property */ typedef struct libcmis_property* libcmis_PropertyPtr; typedef struct libcmis_vector_property* libcmis_vector_property_Ptr; /* PropertyType */ typedef struct libcmis_property_type* libcmis_PropertyTypePtr; typedef struct libcmis_vector_property_type* libcmis_vector_property_type_Ptr; typedef enum { libcmis_String, libcmis_Integer, libcmis_Decimal, libcmis_Bool, libcmis_DateTime } libcmis_property_type_Type; /* Repository */ typedef enum { libcmis_capability_ACL, libcmis_capability_AllVersionsSearchable, libcmis_capability_Changes, libcmis_capability_ContentStreamUpdatability, libcmis_capability_GetDescendants, libcmis_capability_GetFolderTree, libcmis_capability_OrderBy, libcmis_capability_Multifiling, libcmis_capability_PWCSearchable, libcmis_capability_PWCUpdatable, libcmis_capability_Query, libcmis_capability_Renditions, libcmis_capability_Unfiling, libcmis_capability_VersionSpecificFiling, libcmis_capability_Join } libcmis_repository_capability_Type; typedef struct libcmis_repository* libcmis_RepositoryPtr; /* Session */ typedef struct libcmis_session* libcmis_SessionPtr; typedef bool ( *libcmis_authenticationCallback )( char* username, char* password ); typedef bool ( *libcmis_certValidationCallback )( libcmis_vector_string_Ptr certificatesChain ); typedef char * ( *libcmis_oauth2AuthCodeProvider ) ( const char* authUrl, const char* username, const char* password ); /* OAuth2Data */ typedef struct libcmis_oauth2data* libcmis_OAuth2DataPtr; typedef char* ( *libcmis_OAuth2AuthCodeProvider )( const char* authUrl, const char* username, const char* password ); /* Rendition */ typedef struct libcmis_rendition* libcmis_RenditionPtr; typedef struct libcmis_vector_rendition* libcmis_vector_rendition_Ptr; #ifdef __cplusplus } #endif #endif libcmis-0.5.2/inc/libcmis-c/rendition.h0000664000175000017500000000431013407460316014644 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_RENDITION_H_ #define _LIBCMIS_RENDITION_H_ #ifdef __cplusplus extern "C" { #endif #include "libcmis-c/libcmis-c-api.h" #include "libcmis-c/types.h" LIBCMIS_C_API void libcmis_rendition_free( libcmis_RenditionPtr rendition ); LIBCMIS_C_API bool libcmis_rendition_isThumbnail( libcmis_RenditionPtr rendition ); LIBCMIS_C_API const char* libcmis_rendition_getStreamId( libcmis_RenditionPtr rendition ); LIBCMIS_C_API const char* libcmis_rendition_getMimeType( libcmis_RenditionPtr rendition ); LIBCMIS_C_API const char* libcmis_rendition_getKind( libcmis_RenditionPtr rendition ); LIBCMIS_C_API const char* libcmis_rendition_getUrl( libcmis_RenditionPtr rendition ); LIBCMIS_C_API const char* libcmis_rendition_getTitle( libcmis_RenditionPtr rendition ); LIBCMIS_C_API long libcmis_rendition_getLength( libcmis_RenditionPtr rendition ); LIBCMIS_C_API long libcmis_rendition_getWidth( libcmis_RenditionPtr rendition ); LIBCMIS_C_API long libcmis_rendition_getHeight( libcmis_RenditionPtr rendition ); LIBCMIS_C_API const char* libcmis_rendition_getRenditionDocumentId( libcmis_RenditionPtr rendition ); #ifdef __cplusplus } #endif #endif libcmis-0.5.2/inc/libcmis-c/libcmis-c.h0000664000175000017500000000323413407460303014513 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_C_H_ #define _LIBCMIS_C_H_ #include "libcmis-c/libcmis-c-api.h" #include "libcmis-c/types.h" #include "libcmis-c/allowable-actions.h" #include "libcmis-c/document.h" #include "libcmis-c/error.h" #include "libcmis-c/folder.h" #include "libcmis-c/object.h" #include "libcmis-c/object-type.h" #include "libcmis-c/property.h" #include "libcmis-c/property-type.h" #include "libcmis-c/oauth2-data.h" #include "libcmis-c/rendition.h" #include "libcmis-c/repository.h" #include "libcmis-c/types.h" #include "libcmis-c/session.h" #include "libcmis-c/session-factory.h" #include "libcmis-c/vectors.h" #endif libcmis-0.5.2/inc/libcmis-c/Makefile.am0000664000175000017500000000054713407661256014552 00000000000000libcmis_cdir = $(includedir)/libcmis-c-@LIBCMIS_API_VERSION@/libcmis-c dist_libcmis_c_HEADERS = \ allowable-actions.h \ document.h \ error.h \ folder.h \ libcmis-c-api.h \ libcmis-c.h \ oauth2-data.h \ object-type.h \ object.h \ property-type.h \ property.h \ rendition.h \ repository.h \ session-factory.h \ session.h \ types.h \ vectors.h libcmis-0.5.2/inc/libcmis-c/document.h0000664000175000017500000000657113407460367014510 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_DOCUMENT_H_ #define _LIBCMIS_DOCUMENT_H_ #ifdef __cplusplus extern "C" { #endif #include "libcmis-c/libcmis-c-api.h" #include "libcmis-c/types.h" LIBCMIS_C_API void libcmis_vector_document_free( libcmis_vector_document_Ptr vector ); LIBCMIS_C_API size_t libcmis_vector_document_size( libcmis_vector_document_Ptr vector ); LIBCMIS_C_API libcmis_DocumentPtr libcmis_vector_document_get( libcmis_vector_document_Ptr vector, size_t i ); LIBCMIS_C_API bool libcmis_is_document( libcmis_ObjectPtr object ); LIBCMIS_C_API libcmis_DocumentPtr libcmis_document_cast( libcmis_ObjectPtr object ); LIBCMIS_C_API void libcmis_document_free( libcmis_DocumentPtr document ); LIBCMIS_C_API libcmis_vector_folder_Ptr libcmis_document_getParents( libcmis_DocumentPtr document, libcmis_ErrorPtr error ); LIBCMIS_C_API void libcmis_document_getContentStream( libcmis_DocumentPtr document, libcmis_writeFn writeFn, void* userData, libcmis_ErrorPtr error ); LIBCMIS_C_API void libcmis_document_setContentStream( libcmis_DocumentPtr document, libcmis_readFn readFn, void* userData, const char* contentType, const char* filename, bool overwrite, libcmis_ErrorPtr ); /** The resulting value needs to be free'd */ LIBCMIS_C_API char* libcmis_document_getContentType( libcmis_DocumentPtr document ); /** The resulting value needs to be free'd */ LIBCMIS_C_API char* libcmis_document_getContentFilename( libcmis_DocumentPtr document ); LIBCMIS_C_API long libcmis_document_getContentLength( libcmis_DocumentPtr document ); LIBCMIS_C_API libcmis_DocumentPtr libcmis_document_checkOut( libcmis_DocumentPtr document, libcmis_ErrorPtr error ); LIBCMIS_C_API void libcmis_document_cancelCheckout( libcmis_DocumentPtr document, libcmis_ErrorPtr error ); LIBCMIS_C_API libcmis_DocumentPtr libcmis_document_checkIn( libcmis_DocumentPtr document, bool isMajor, const char* comment, libcmis_vector_property_Ptr properties, libcmis_readFn readFn, void* userData, const char* contentType, const char* filename, libcmis_ErrorPtr error ); LIBCMIS_C_API libcmis_vector_document_Ptr libcmis_document_getAllVersions( libcmis_DocumentPtr document, libcmis_ErrorPtr error ); #ifdef __cplusplus } #endif #endif libcmis-0.5.2/inc/libcmis-c/property-type.h0000664000175000017500000000646713407460303015527 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_PROPERTY_TYPE_H_ #define _LIBCMIS_PROPERTY_TYPE_H_ #ifdef __cplusplus extern "C" { #endif #include "libcmis-c/libcmis-c-api.h" #include "libcmis-c/types.h" LIBCMIS_C_API void libcmis_vector_property_type_free( libcmis_vector_property_type_Ptr vector ); LIBCMIS_C_API size_t libcmis_vector_property_type_size( libcmis_vector_property_type_Ptr vector ); LIBCMIS_C_API libcmis_PropertyTypePtr libcmis_vector_property_type_get( libcmis_vector_property_type_Ptr vector, size_t i ); LIBCMIS_C_API void libcmis_property_type_free( libcmis_PropertyTypePtr type ); /** The resulting value needs to be free'd. */ LIBCMIS_C_API char* libcmis_property_type_getId( libcmis_PropertyTypePtr type ); /** The resulting value needs to be free'd. */ LIBCMIS_C_API char* libcmis_property_type_getLocalName( libcmis_PropertyTypePtr type ); /** The resulting value needs to be free'd. */ LIBCMIS_C_API char* libcmis_property_type_getLocalNamespace( libcmis_PropertyTypePtr type ); /** The resulting value needs to be free'd. */ LIBCMIS_C_API char* libcmis_property_type_getDisplayName( libcmis_PropertyTypePtr type ); /** The resulting value needs to be free'd. */ LIBCMIS_C_API char* libcmis_property_type_getQueryName( libcmis_PropertyTypePtr type ); LIBCMIS_C_API libcmis_property_type_Type libcmis_property_type_getType( libcmis_PropertyTypePtr type ); /** The resulting value needs to be free'd. */ LIBCMIS_C_API char* libcmis_property_type_getXmlType( libcmis_PropertyTypePtr type ); LIBCMIS_C_API bool libcmis_property_type_isMultiValued( libcmis_PropertyTypePtr type ); LIBCMIS_C_API bool libcmis_property_type_isUpdatable( libcmis_PropertyTypePtr type ); LIBCMIS_C_API bool libcmis_property_type_isInherited( libcmis_PropertyTypePtr type ); LIBCMIS_C_API bool libcmis_property_type_isRequired( libcmis_PropertyTypePtr type ); LIBCMIS_C_API bool libcmis_property_type_isQueryable( libcmis_PropertyTypePtr type ); LIBCMIS_C_API bool libcmis_property_type_isOrderable( libcmis_PropertyTypePtr type ); LIBCMIS_C_API bool libcmis_property_type_isOpenChoice( libcmis_PropertyTypePtr type ); LIBCMIS_C_API void libcmis_property_type_update( libcmis_PropertyTypePtr propDef, libcmis_vector_object_type_Ptr types ); #ifdef __cplusplus } #endif #endif libcmis-0.5.2/inc/libcmis-c/libcmis-c-api.h0000664000175000017500000000263013407501053015257 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_C_API_H_ #define _LIBCMIS_C_API_H_ #ifdef DLL_EXPORT #ifdef LIBCMIS_C_BUILD #define LIBCMIS_C_API __declspec(dllexport) #else #define LIBCMIS_C_API __declspec(dllimport) #endif #else /* !DLL_EXPORT */ #ifdef LIBCMIS_C_VISIBILITY #define LIBCMIS_C_API __attribute__((visibility("default"))) #else #define LIBCMIS_C_API #endif #endif #endif libcmis-0.5.2/inc/libcmis-c/folder.h0000664000175000017500000000555713407460375014147 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_FOLDER_H_ #define _LIBCMIS_FOLDER_H_ #ifdef __cplusplus extern "C" { #endif #include "libcmis-c/libcmis-c-api.h" #include "libcmis-c/types.h" LIBCMIS_C_API void libcmis_vector_folder_free( libcmis_vector_folder_Ptr vector ); LIBCMIS_C_API size_t libcmis_vector_folder_size( libcmis_vector_folder_Ptr vector ); LIBCMIS_C_API libcmis_FolderPtr libcmis_vector_folder_get( libcmis_vector_folder_Ptr vector, size_t i ); LIBCMIS_C_API bool libcmis_is_folder( libcmis_ObjectPtr object ); LIBCMIS_C_API libcmis_FolderPtr libcmis_folder_cast( libcmis_ObjectPtr object ); LIBCMIS_C_API void libcmis_folder_free( libcmis_FolderPtr folder ); LIBCMIS_C_API libcmis_FolderPtr libcmis_folder_getParent( libcmis_FolderPtr folder, libcmis_ErrorPtr error ); LIBCMIS_C_API libcmis_vector_object_Ptr libcmis_folder_getChildren( libcmis_FolderPtr folder, libcmis_ErrorPtr error ); /** Get the path of the folder. The returned string needs to be freed. */ LIBCMIS_C_API char* libcmis_folder_getPath( libcmis_FolderPtr folder ); LIBCMIS_C_API bool libcmis_folder_isRootFolder( libcmis_FolderPtr folder ); LIBCMIS_C_API libcmis_FolderPtr libcmis_folder_createFolder( libcmis_FolderPtr folder, libcmis_vector_property_Ptr properties, libcmis_ErrorPtr error ); LIBCMIS_C_API libcmis_DocumentPtr libcmis_folder_createDocument( libcmis_FolderPtr folder, libcmis_vector_property_Ptr properties, libcmis_readFn readFn, void* userData, const char* contentType, const char* filename, libcmis_ErrorPtr error ); LIBCMIS_C_API libcmis_vector_string_Ptr libcmis_folder_removeTree( libcmis_FolderPtr folder, bool allVersion, libcmis_folder_UnfileObjects unfile, bool continueOnError, libcmis_ErrorPtr error ); #ifdef __cplusplus } #endif #endif libcmis-0.5.2/inc/Makefile.am0000664000175000017500000000003413407414352012670 00000000000000SUBDIRS = libcmis libcmis-c libcmis-0.5.2/Makefile.in0000664000175000017500000007767313407705040012154 00000000000000# Makefile.in generated by automake 1.16.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2018 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ @ENABLE_TESTS_TRUE@am__append_1 = qa subdir = . ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \ $(top_srcdir)/m4/ax_cxx_compile_stdcxx_11.m4 \ $(top_srcdir)/m4/ax_gcc_func_attribute.m4 \ $(top_srcdir)/m4/boost.m4 $(top_srcdir)/m4/libtool.m4 \ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(top_srcdir)/configure \ $(am__configure_deps) $(am__DIST_COMMON) am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ configure.lineno config.status.lineno mkinstalldirs = $(install_sh) -d CONFIG_CLEAN_FILES = doc/cmis-client.xml CONFIG_CLEAN_VPATH_FILES = AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = SOURCES = DIST_SOURCES = RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ ctags-recursive dvi-recursive html-recursive info-recursive \ install-data-recursive install-dvi-recursive \ install-exec-recursive install-html-recursive \ install-info-recursive install-pdf-recursive \ install-ps-recursive install-recursive installcheck-recursive \ installdirs-recursive pdf-recursive ps-recursive \ tags-recursive uninstall-recursive am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; am__install_max = 40 am__nobase_strip_setup = \ srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` am__nobase_strip = \ for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" am__nobase_list = $(am__nobase_strip_setup); \ for p in $$list; do echo "$$p $$p"; done | \ sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ if (++n[$$2] == $(am__install_max)) \ { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ END { for (dir in files) print dir, files[dir] }' am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' am__uninstall_files_from_dir = { \ test -z "$$files" \ || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ $(am__cd) "$$dir" && rm -f $$files; }; \ } man1dir = $(mandir)/man1 am__installdirs = "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(pkgconfigdir)" NROFF = nroff MANS = $(man_MANS) DATA = $(pkgconfig_DATA) RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ distclean-recursive maintainer-clean-recursive am__recursive_targets = \ $(RECURSIVE_TARGETS) \ $(RECURSIVE_CLEAN_TARGETS) \ $(am__extra_recursive_targets) AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ cscope distdir distdir-am dist dist-all distcheck am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is # *not* preserved. am__uniquify_input = $(AWK) '\ BEGIN { nonempty = 0; } \ { items[$$0] = 1; nonempty = 1; } \ END { if (nonempty) { for (i in items) print i; }; } \ ' # Make sure the list of sources is unique. This is necessary because, # e.g., the same source file might be shared among _SOURCES variables # for different programs/libraries. am__define_uniq_tagged_files = \ list='$(am__tagged_files)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags CSCOPE = cscope DIST_SUBDIRS = inc src qa am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/libcmis-c.pc.in \ $(srcdir)/libcmis.pc.in $(top_srcdir)/coverage.mk \ $(top_srcdir)/doc/cmis-client.xml.in AUTHORS ChangeLog NEWS \ compile config.guess config.sub depcomp install-sh ltmain.sh \ missing DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) distdir = $(PACKAGE)-$(VERSION) top_distdir = $(distdir) am__remove_distdir = \ if test -d "$(distdir)"; then \ find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \ && rm -rf "$(distdir)" \ || { sleep 5 && rm -rf "$(distdir)"; }; \ else :; fi am__post_remove_distdir = $(am__remove_distdir) am__relativize = \ dir0=`pwd`; \ sed_first='s,^\([^/]*\)/.*$$,\1,'; \ sed_rest='s,^[^/]*/*,,'; \ sed_last='s,^.*/\([^/]*\)$$,\1,'; \ sed_butlast='s,/*[^/]*$$,,'; \ while test -n "$$dir1"; do \ first=`echo "$$dir1" | sed -e "$$sed_first"`; \ if test "$$first" != "."; then \ if test "$$first" = ".."; then \ dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ else \ first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ if test "$$first2" = "$$first"; then \ dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ else \ dir2="../$$dir2"; \ fi; \ dir0="$$dir0"/"$$first"; \ fi; \ fi; \ dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ done; \ reldir="$$dir2" DIST_ARCHIVES = $(distdir).tar.gz $(distdir).tar.xz GZIP_ENV = --best DIST_TARGETS = dist-xz dist-gzip distuninstallcheck_listfiles = find . -type f -print am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \ | sed 's|^\./|$(prefix)/|' | grep -v '$(infodir)/dir$$' distcleancheck_listfiles = find . -type f -print ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ BOOST_CPPFLAGS = @BOOST_CPPFLAGS@ BOOST_DATE_TIME_LDFLAGS = @BOOST_DATE_TIME_LDFLAGS@ BOOST_DATE_TIME_LDPATH = @BOOST_DATE_TIME_LDPATH@ BOOST_DATE_TIME_LIBS = @BOOST_DATE_TIME_LIBS@ BOOST_LDPATH = @BOOST_LDPATH@ BOOST_PROGRAM_OPTIONS_LDFLAGS = @BOOST_PROGRAM_OPTIONS_LDFLAGS@ BOOST_PROGRAM_OPTIONS_LDPATH = @BOOST_PROGRAM_OPTIONS_LDPATH@ BOOST_PROGRAM_OPTIONS_LIBS = @BOOST_PROGRAM_OPTIONS_LIBS@ BOOST_ROOT = @BOOST_ROOT@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPCHECK = @CPPCHECK@ CPPCHECK_PARALLELISM = @CPPCHECK_PARALLELISM@ CPPFLAGS = @CPPFLAGS@ CPPUNIT_CFLAGS = @CPPUNIT_CFLAGS@ CPPUNIT_LIBS = @CPPUNIT_LIBS@ CURL_CFLAGS = @CURL_CFLAGS@ CURL_LIBS = @CURL_LIBS@ CXX = @CXX@ CXXCPP = @CXXCPP@ CXXDEPMODE = @CXXDEPMODE@ CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DISTCHECK_CONFIGURE_FLAGS = @DISTCHECK_CONFIGURE_FLAGS@ DLLTOOL = @DLLTOOL@ DOCBOOK2MAN = @DOCBOOK2MAN@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ GENHTML = @GENHTML@ GREP = @GREP@ HAVE_CXX11 = @HAVE_CXX11@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LCOV = @LCOV@ LD = @LD@ LDFLAGS = @LDFLAGS@ LIBCMIS_API_VERSION = @LIBCMIS_API_VERSION@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ NPROC = @NPROC@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SRCDIR = @SRCDIR@ STRIP = @STRIP@ VERSION = @VERSION@ XML2_CFLAGS = @XML2_CFLAGS@ XML2_LIBS = @XML2_LIBS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ infos = libcmis-lcov.info libcmis-c-lcov.info SUBDIRS = inc src $(am__append_1) ACLOCAL_AMFLAGS = -I m4 pkgconfig_DATA = \ libcmis-@LIBCMIS_API_VERSION@.pc \ libcmis-c-@LIBCMIS_API_VERSION@.pc pkgconfigdir = $(libdir)/pkgconfig @ENABLE_MAN_TRUE@man_MANS = cmis-client.1 EXTRA_DIST = \ libcmis.pc.in \ libcmis-c.pc.in \ COPYING.MPL \ COPYING.GPL \ COPYING.LGPL \ doc/cmis-client.xml.in \ cppcheck-suppress \ qa/libcmis/data DISTCLEANFILES = \ cmis-client.1 \ libcmis-@LIBCMIS_API_VERSION@.pc \ libcmis-c-@LIBCMIS_API_VERSION@.pc all: all-recursive .SUFFIXES: am--refresh: Makefile @: $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(top_srcdir)/coverage.mk $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \ $(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \ && exit 0; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ echo ' $(SHELL) ./config.status'; \ $(SHELL) ./config.status;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__maybe_remake_depfiles);; \ esac; $(top_srcdir)/coverage.mk $(am__empty): $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) $(SHELL) ./config.status --recheck $(top_srcdir)/configure: $(am__configure_deps) $(am__cd) $(srcdir) && $(AUTOCONF) $(ACLOCAL_M4): $(am__aclocal_m4_deps) $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) $(am__aclocal_m4_deps): doc/cmis-client.xml: $(top_builddir)/config.status $(top_srcdir)/doc/cmis-client.xml.in cd $(top_builddir) && $(SHELL) ./config.status $@ mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs distclean-libtool: -rm -f libtool config.lt install-man1: $(man_MANS) @$(NORMAL_INSTALL) @list1=''; \ list2='$(man_MANS)'; \ test -n "$(man1dir)" \ && test -n "`echo $$list1$$list2`" \ || exit 0; \ echo " $(MKDIR_P) '$(DESTDIR)$(man1dir)'"; \ $(MKDIR_P) "$(DESTDIR)$(man1dir)" || exit 1; \ { for i in $$list1; do echo "$$i"; done; \ if test -n "$$list2"; then \ for i in $$list2; do echo "$$i"; done \ | sed -n '/\.1[a-z]*$$/p'; \ fi; \ } | while read p; do \ if test -f $$p; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; echo "$$p"; \ done | \ sed -e 'n;s,.*/,,;p;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,' | \ sed 'N;N;s,\n, ,g' | { \ list=; while read file base inst; do \ if test "$$base" = "$$inst"; then list="$$list $$file"; else \ echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man1dir)/$$inst'"; \ $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man1dir)/$$inst" || exit $$?; \ fi; \ done; \ for i in $$list; do echo "$$i"; done | $(am__base_list) | \ while read files; do \ test -z "$$files" || { \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(man1dir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(man1dir)" || exit $$?; }; \ done; } uninstall-man1: @$(NORMAL_UNINSTALL) @list=''; test -n "$(man1dir)" || exit 0; \ files=`{ for i in $$list; do echo "$$i"; done; \ l2='$(man_MANS)'; for i in $$l2; do echo "$$i"; done | \ sed -n '/\.1[a-z]*$$/p'; \ } | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \ -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \ dir='$(DESTDIR)$(man1dir)'; $(am__uninstall_files_from_dir) install-pkgconfigDATA: $(pkgconfig_DATA) @$(NORMAL_INSTALL) @list='$(pkgconfig_DATA)'; test -n "$(pkgconfigdir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(pkgconfigdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(pkgconfigdir)" || exit 1; \ fi; \ for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ echo "$$d$$p"; \ done | $(am__base_list) | \ while read files; do \ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(pkgconfigdir)'"; \ $(INSTALL_DATA) $$files "$(DESTDIR)$(pkgconfigdir)" || exit $$?; \ done uninstall-pkgconfigDATA: @$(NORMAL_UNINSTALL) @list='$(pkgconfig_DATA)'; test -n "$(pkgconfigdir)" || list=; \ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ dir='$(DESTDIR)$(pkgconfigdir)'; $(am__uninstall_files_from_dir) # This directory's subdirectories are mostly independent; you can cd # into them and run 'make' without going through this Makefile. # To change the values of 'make' variables: instead of editing Makefiles, # (1) if the variable is set in 'config.status', edit 'config.status' # (which will cause the Makefiles to be regenerated when you run 'make'); # (2) otherwise, pass the desired values on the 'make' command line. $(am__recursive_targets): @fail=; \ if $(am__make_keepgoing); then \ failcom='fail=yes'; \ else \ failcom='exit 1'; \ fi; \ dot_seen=no; \ target=`echo $@ | sed s/-recursive//`; \ case "$@" in \ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ *) list='$(SUBDIRS)' ;; \ esac; \ for subdir in $$list; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ dot_seen=yes; \ local_target="$$target-am"; \ else \ local_target="$$target"; \ fi; \ ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ || eval $$failcom; \ done; \ if test "$$dot_seen" = "no"; then \ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ fi; test -z "$$fail" ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique tags: tags-recursive TAGS: tags tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ include_option=--etags-include; \ empty_fix=.; \ else \ include_option=--include; \ empty_fix=; \ fi; \ list='$(SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ test ! -f $$subdir/TAGS || \ set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ fi; \ done; \ $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ if test $$# -gt 0; then \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ "$$@" $$unique; \ else \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$unique; \ fi; \ fi ctags: ctags-recursive CTAGS: ctags ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" cscope: cscope.files test ! -s cscope.files \ || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS) clean-cscope: -rm -f cscope.files cscope.files: clean-cscope cscopelist cscopelist: cscopelist-recursive cscopelist-am: $(am__tagged_files) list='$(am__tagged_files)'; \ case "$(srcdir)" in \ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ *) sdir=$(subdir)/$(srcdir) ;; \ esac; \ for i in $$list; do \ if test -f "$$i"; then \ echo "$(subdir)/$$i"; \ else \ echo "$$sdir/$$i"; \ fi; \ done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags -rm -f cscope.out cscope.in.out cscope.po.out cscope.files distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) $(am__remove_distdir) test -d "$(distdir)" || mkdir "$(distdir)" @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ $(am__make_dryrun) \ || test -d "$(distdir)/$$subdir" \ || $(MKDIR_P) "$(distdir)/$$subdir" \ || exit 1; \ dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ $(am__relativize); \ new_distdir=$$reldir; \ dir1=$$subdir; dir2="$(top_distdir)"; \ $(am__relativize); \ new_top_distdir=$$reldir; \ echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ ($(am__cd) $$subdir && \ $(MAKE) $(AM_MAKEFLAGS) \ top_distdir="$$new_top_distdir" \ distdir="$$new_distdir" \ am__remove_distdir=: \ am__skip_length_check=: \ am__skip_mode_fix=: \ distdir) \ || exit 1; \ fi; \ done $(MAKE) $(AM_MAKEFLAGS) \ top_distdir="$(top_distdir)" distdir="$(distdir)" \ dist-hook -test -n "$(am__skip_mode_fix)" \ || find "$(distdir)" -type d ! -perm -755 \ -exec chmod u+rwx,go+rx {} \; -o \ ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ || chmod -R a+r "$(distdir)" dist-gzip: distdir tardir=$(distdir) && $(am__tar) | eval GZIP= gzip $(GZIP_ENV) -c >$(distdir).tar.gz $(am__post_remove_distdir) dist-bzip2: distdir tardir=$(distdir) && $(am__tar) | BZIP2=$${BZIP2--9} bzip2 -c >$(distdir).tar.bz2 $(am__post_remove_distdir) dist-lzip: distdir tardir=$(distdir) && $(am__tar) | lzip -c $${LZIP_OPT--9} >$(distdir).tar.lz $(am__post_remove_distdir) dist-xz: distdir tardir=$(distdir) && $(am__tar) | XZ_OPT=$${XZ_OPT--e} xz -c >$(distdir).tar.xz $(am__post_remove_distdir) dist-tarZ: distdir @echo WARNING: "Support for distribution archives compressed with" \ "legacy program 'compress' is deprecated." >&2 @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z $(am__post_remove_distdir) dist-shar: distdir @echo WARNING: "Support for shar distribution archives is" \ "deprecated." >&2 @echo WARNING: "It will be removed altogether in Automake 2.0" >&2 shar $(distdir) | eval GZIP= gzip $(GZIP_ENV) -c >$(distdir).shar.gz $(am__post_remove_distdir) dist-zip: distdir -rm -f $(distdir).zip zip -rq $(distdir).zip $(distdir) $(am__post_remove_distdir) dist dist-all: $(MAKE) $(AM_MAKEFLAGS) $(DIST_TARGETS) am__post_remove_distdir='@:' $(am__post_remove_distdir) # This target untars the dist file and tries a VPATH configuration. Then # it guarantees that the distribution is self-contained by making another # tarfile. distcheck: dist case '$(DIST_ARCHIVES)' in \ *.tar.gz*) \ eval GZIP= gzip $(GZIP_ENV) -dc $(distdir).tar.gz | $(am__untar) ;;\ *.tar.bz2*) \ bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\ *.tar.lz*) \ lzip -dc $(distdir).tar.lz | $(am__untar) ;;\ *.tar.xz*) \ xz -dc $(distdir).tar.xz | $(am__untar) ;;\ *.tar.Z*) \ uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ *.shar.gz*) \ eval GZIP= gzip $(GZIP_ENV) -dc $(distdir).shar.gz | unshar ;;\ *.zip*) \ unzip $(distdir).zip ;;\ esac chmod -R a-w $(distdir) chmod u+w $(distdir) mkdir $(distdir)/_build $(distdir)/_build/sub $(distdir)/_inst chmod a-w $(distdir) test -d $(distdir)/_build || exit 0; \ dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ && am__cwd=`pwd` \ && $(am__cd) $(distdir)/_build/sub \ && ../../configure \ $(AM_DISTCHECK_CONFIGURE_FLAGS) \ $(DISTCHECK_CONFIGURE_FLAGS) \ --srcdir=../.. --prefix="$$dc_install_base" \ && $(MAKE) $(AM_MAKEFLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) dvi \ && $(MAKE) $(AM_MAKEFLAGS) check \ && $(MAKE) $(AM_MAKEFLAGS) install \ && $(MAKE) $(AM_MAKEFLAGS) installcheck \ && $(MAKE) $(AM_MAKEFLAGS) uninstall \ && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ distuninstallcheck \ && chmod -R a-w "$$dc_install_base" \ && ({ \ (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ } || { rm -rf "$$dc_destdir"; exit 1; }) \ && rm -rf "$$dc_destdir" \ && $(MAKE) $(AM_MAKEFLAGS) dist \ && rm -rf $(DIST_ARCHIVES) \ && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \ && cd "$$am__cwd" \ || exit 1 $(am__post_remove_distdir) @(echo "$(distdir) archives ready for distribution: "; \ list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x' distuninstallcheck: @test -n '$(distuninstallcheck_dir)' || { \ echo 'ERROR: trying to run $@ with an empty' \ '$$(distuninstallcheck_dir)' >&2; \ exit 1; \ }; \ $(am__cd) '$(distuninstallcheck_dir)' || { \ echo 'ERROR: cannot chdir into $(distuninstallcheck_dir)' >&2; \ exit 1; \ }; \ test `$(am__distuninstallcheck_listfiles) | wc -l` -eq 0 \ || { echo "ERROR: files left after uninstall:" ; \ if test -n "$(DESTDIR)"; then \ echo " (check DESTDIR support)"; \ fi ; \ $(distuninstallcheck_listfiles) ; \ exit 1; } >&2 distcleancheck: distclean @if test '$(srcdir)' = . ; then \ echo "ERROR: distcleancheck can only run from a VPATH build" ; \ exit 1 ; \ fi @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ || { echo "ERROR: files left in build directory after distclean:" ; \ $(distcleancheck_listfiles) ; \ exit 1; } >&2 check-am: all-am check: check-recursive all-am: Makefile $(MANS) $(DATA) installdirs: installdirs-recursive installdirs-am: for dir in "$(DESTDIR)$(man1dir)" "$(DESTDIR)$(pkgconfigdir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-recursive install-exec: install-exec-recursive install-data: install-data-recursive uninstall: uninstall-recursive install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-recursive install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-recursive clean-am: clean-generic clean-libtool mostlyclean-am distclean: distclean-recursive -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -f Makefile distclean-am: clean-am distclean-generic distclean-libtool \ distclean-tags dvi: dvi-recursive dvi-am: html: html-recursive html-am: info: info-recursive info-am: install-data-am: install-man install-pkgconfigDATA install-dvi: install-dvi-recursive install-dvi-am: install-exec-am: install-html: install-html-recursive install-html-am: install-info: install-info-recursive install-info-am: install-man: install-man1 install-pdf: install-pdf-recursive install-pdf-am: install-ps: install-ps-recursive install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-recursive -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -rf $(top_srcdir)/autom4te.cache -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-recursive mostlyclean-am: mostlyclean-generic mostlyclean-libtool pdf: pdf-recursive pdf-am: ps: ps-recursive ps-am: uninstall-am: uninstall-man uninstall-pkgconfigDATA uninstall-man: uninstall-man1 .MAKE: $(am__recursive_targets) install-am install-strip .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \ am--refresh check check-am clean clean-cscope clean-generic \ clean-libtool cscope cscopelist-am ctags ctags-am dist \ dist-all dist-bzip2 dist-gzip dist-hook dist-lzip dist-shar \ dist-tarZ dist-xz dist-zip distcheck distclean \ distclean-generic distclean-libtool distclean-tags \ distcleancheck distdir distuninstallcheck dvi dvi-am html \ html-am info info-am install install-am install-data \ install-data-am install-dvi install-dvi-am install-exec \ install-exec-am install-html install-html-am install-info \ install-info-am install-man install-man1 install-pdf \ install-pdf-am install-pkgconfigDATA install-ps install-ps-am \ install-strip installcheck installcheck-am installdirs \ installdirs-am maintainer-clean maintainer-clean-generic \ mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ ps ps-am tags tags-am uninstall uninstall-am uninstall-man \ uninstall-man1 uninstall-pkgconfigDATA .PRECIOUS: Makefile .PHONY: coverage genlcov coverage-clean coverage: -$(MAKE) $(AM_MAKEFLAGS) -k check $(MAKE) $(AM_MAKEFLAGS) genlcov $(infos): %-lcov.info: $(LCOV) --directory $(top_builddir)/src/$* \ --base-directory $(top_builddir)/src/$* \ --capture \ --output-file $@ \ --no-external \ --compat-libtool genlcov: $(infos) LANG=C $(GENHTML) --output-directory libcmis-lcov --title "Libcmis Code Coverage" --legend --show-details $^ @echo "file://$(abs_top_builddir)/libcmis-lcov/index.html" coverage-clean: -$(LCOV) --directory $(top_builddir) -z -rm -rf $(infos) libcmis-lcov -find $(top_builddir) -type f -name "*.gcda" -o -name "*.gcno" -o -name "*.gcov" -exec rm "{}" \; @ENABLE_MAN_TRUE@cmis-client.1: doc/cmis-client.xml @ENABLE_MAN_TRUE@ $(DOCBOOK2MAN) $< dist-hook: @if test -d "$(srcdir)/.git"; \ then \ echo Creating ChangeLog && \ ( cd "$(top_srcdir)" && \ echo '# Generated by Makefile. Do not edit.'; echo; \ $(top_srcdir)/missing --run git log --pretty=medium ) > ChangeLog.tmp \ && mv -f ChangeLog.tmp $(top_distdir)/ChangeLog \ || ( rm -f ChangeLog.tmp ; \ echo Failed to generate ChangeLog >&2 ); \ else \ echo A git clone is required to generate a ChangeLog >&2; \ fi cppcheck: @CPPCHECK@ -q --enable=style,performance,portability \ -j @CPPCHECK_PARALLELISM@ \ --suppressions-list=@SRCDIR@/cppcheck-suppress \ --error-exitcode=1 @SRCDIR@ # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: libcmis-0.5.2/src/0000775000175000017500000000000013411152377010736 500000000000000libcmis-0.5.2/src/Makefile.in0000664000175000017500000006263313407705041012732 00000000000000# Makefile.in generated by automake 1.16.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2018 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ @ENABLE_CLIENT_TRUE@bin_PROGRAMS = cmis-client$(EXEEXT) subdir = src ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \ $(top_srcdir)/m4/ax_cxx_compile_stdcxx_11.m4 \ $(top_srcdir)/m4/ax_gcc_func_attribute.m4 \ $(top_srcdir)/m4/boost.m4 $(top_srcdir)/m4/libtool.m4 \ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = am__installdirs = "$(DESTDIR)$(bindir)" PROGRAMS = $(bin_PROGRAMS) am__cmis_client_SOURCES_DIST = cmis-client.cxx @ENABLE_CLIENT_TRUE@am_cmis_client_OBJECTS = cmis-client.$(OBJEXT) cmis_client_OBJECTS = $(am_cmis_client_OBJECTS) am__DEPENDENCIES_1 = @ENABLE_CLIENT_TRUE@cmis_client_DEPENDENCIES = $(top_builddir)/src/libcmis/libcmis-@LIBCMIS_API_VERSION@.la \ @ENABLE_CLIENT_TRUE@ $(am__DEPENDENCIES_1) \ @ENABLE_CLIENT_TRUE@ $(am__DEPENDENCIES_1) \ @ENABLE_CLIENT_TRUE@ $(am__DEPENDENCIES_1) AM_V_lt = $(am__v_lt_@AM_V@) am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) am__v_lt_0 = --silent am__v_lt_1 = AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ depcomp = $(SHELL) $(top_srcdir)/depcomp am__maybe_remake_depfiles = depfiles am__depfiles_remade = ./$(DEPDIR)/cmis-client.Po am__mv = mv -f CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ $(AM_CXXFLAGS) $(CXXFLAGS) AM_V_CXX = $(am__v_CXX_@AM_V@) am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@) am__v_CXX_0 = @echo " CXX " $@; am__v_CXX_1 = CXXLD = $(CXX) CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \ $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ AM_V_CXXLD = $(am__v_CXXLD_@AM_V@) am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@) am__v_CXXLD_0 = @echo " CXXLD " $@; am__v_CXXLD_1 = SOURCES = $(cmis_client_SOURCES) DIST_SOURCES = $(am__cmis_client_SOURCES_DIST) RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ ctags-recursive dvi-recursive html-recursive info-recursive \ install-data-recursive install-dvi-recursive \ install-exec-recursive install-html-recursive \ install-info-recursive install-pdf-recursive \ install-ps-recursive install-recursive installcheck-recursive \ installdirs-recursive pdf-recursive ps-recursive \ tags-recursive uninstall-recursive am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ distclean-recursive maintainer-clean-recursive am__recursive_targets = \ $(RECURSIVE_TARGETS) \ $(RECURSIVE_CLEAN_TARGETS) \ $(am__extra_recursive_targets) AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ distdir distdir-am am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is # *not* preserved. am__uniquify_input = $(AWK) '\ BEGIN { nonempty = 0; } \ { items[$$0] = 1; nonempty = 1; } \ END { if (nonempty) { for (i in items) print i; }; } \ ' # Make sure the list of sources is unique. This is necessary because, # e.g., the same source file might be shared among _SOURCES variables # for different programs/libraries. am__define_uniq_tagged_files = \ list='$(am__tagged_files)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags DIST_SUBDIRS = $(SUBDIRS) am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) am__relativize = \ dir0=`pwd`; \ sed_first='s,^\([^/]*\)/.*$$,\1,'; \ sed_rest='s,^[^/]*/*,,'; \ sed_last='s,^.*/\([^/]*\)$$,\1,'; \ sed_butlast='s,/*[^/]*$$,,'; \ while test -n "$$dir1"; do \ first=`echo "$$dir1" | sed -e "$$sed_first"`; \ if test "$$first" != "."; then \ if test "$$first" = ".."; then \ dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ else \ first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ if test "$$first2" = "$$first"; then \ dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ else \ dir2="../$$dir2"; \ fi; \ dir0="$$dir0"/"$$first"; \ fi; \ fi; \ dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ done; \ reldir="$$dir2" ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ BOOST_CPPFLAGS = @BOOST_CPPFLAGS@ BOOST_DATE_TIME_LDFLAGS = @BOOST_DATE_TIME_LDFLAGS@ BOOST_DATE_TIME_LDPATH = @BOOST_DATE_TIME_LDPATH@ BOOST_DATE_TIME_LIBS = @BOOST_DATE_TIME_LIBS@ BOOST_LDPATH = @BOOST_LDPATH@ BOOST_PROGRAM_OPTIONS_LDFLAGS = @BOOST_PROGRAM_OPTIONS_LDFLAGS@ BOOST_PROGRAM_OPTIONS_LDPATH = @BOOST_PROGRAM_OPTIONS_LDPATH@ BOOST_PROGRAM_OPTIONS_LIBS = @BOOST_PROGRAM_OPTIONS_LIBS@ BOOST_ROOT = @BOOST_ROOT@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPCHECK = @CPPCHECK@ CPPCHECK_PARALLELISM = @CPPCHECK_PARALLELISM@ CPPFLAGS = @CPPFLAGS@ CPPUNIT_CFLAGS = @CPPUNIT_CFLAGS@ CPPUNIT_LIBS = @CPPUNIT_LIBS@ CURL_CFLAGS = @CURL_CFLAGS@ CURL_LIBS = @CURL_LIBS@ CXX = @CXX@ CXXCPP = @CXXCPP@ CXXDEPMODE = @CXXDEPMODE@ CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DISTCHECK_CONFIGURE_FLAGS = @DISTCHECK_CONFIGURE_FLAGS@ DLLTOOL = @DLLTOOL@ DOCBOOK2MAN = @DOCBOOK2MAN@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ GENHTML = @GENHTML@ GREP = @GREP@ HAVE_CXX11 = @HAVE_CXX11@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LCOV = @LCOV@ LD = @LD@ LDFLAGS = @LDFLAGS@ LIBCMIS_API_VERSION = @LIBCMIS_API_VERSION@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ NPROC = @NPROC@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SRCDIR = @SRCDIR@ STRIP = @STRIP@ VERSION = @VERSION@ XML2_CFLAGS = @XML2_CFLAGS@ XML2_LIBS = @XML2_LIBS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ SUBDIRS = libcmis libcmis-c @ENABLE_CLIENT_TRUE@AM_CXXFLAGS = \ @ENABLE_CLIENT_TRUE@ -I$(top_srcdir)/inc \ @ENABLE_CLIENT_TRUE@ $(XML2_CFLAGS) \ @ENABLE_CLIENT_TRUE@ $(BOOST_CPPFLAGS) @ENABLE_CLIENT_TRUE@cmis_client_SOURCES = cmis-client.cxx @ENABLE_CLIENT_TRUE@cmis_client_LDADD = $(top_builddir)/src/libcmis/libcmis-@LIBCMIS_API_VERSION@.la \ @ENABLE_CLIENT_TRUE@ $(XML2_LIBS) \ @ENABLE_CLIENT_TRUE@ $(BOOST_PROGRAM_OPTIONS_LIBS) \ @ENABLE_CLIENT_TRUE@ $(BOOST_DATE_TIME_LIBS) \ @ENABLE_CLIENT_TRUE@ $(JSON_LIBS) all: all-recursive .SUFFIXES: .SUFFIXES: .cxx .lo .o .obj $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign src/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): install-binPROGRAMS: $(bin_PROGRAMS) @$(NORMAL_INSTALL) @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ if test -n "$$list"; then \ echo " $(MKDIR_P) '$(DESTDIR)$(bindir)'"; \ $(MKDIR_P) "$(DESTDIR)$(bindir)" || exit 1; \ fi; \ for p in $$list; do echo "$$p $$p"; done | \ sed 's/$(EXEEXT)$$//' | \ while read p p1; do if test -f $$p \ || test -f $$p1 \ ; then echo "$$p"; echo "$$p"; else :; fi; \ done | \ sed -e 'p;s,.*/,,;n;h' \ -e 's|.*|.|' \ -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ sed 'N;N;N;s,\n, ,g' | \ $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ if ($$2 == $$4) files[d] = files[d] " " $$1; \ else { print "f", $$3 "/" $$4, $$1; } } \ END { for (d in files) print "f", d, files[d] }' | \ while read type dir files; do \ if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ test -z "$$files" || { \ echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(bindir)$$dir'"; \ $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \ } \ ; done uninstall-binPROGRAMS: @$(NORMAL_UNINSTALL) @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ files=`for p in $$list; do echo "$$p"; done | \ sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ -e 's/$$/$(EXEEXT)/' \ `; \ test -n "$$list" || exit 0; \ echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \ cd "$(DESTDIR)$(bindir)" && rm -f $$files clean-binPROGRAMS: @list='$(bin_PROGRAMS)'; test -n "$$list" || exit 0; \ echo " rm -f" $$list; \ rm -f $$list || exit $$?; \ test -n "$(EXEEXT)" || exit 0; \ list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list cmis-client$(EXEEXT): $(cmis_client_OBJECTS) $(cmis_client_DEPENDENCIES) $(EXTRA_cmis_client_DEPENDENCIES) @rm -f cmis-client$(EXEEXT) $(AM_V_CXXLD)$(CXXLINK) $(cmis_client_OBJECTS) $(cmis_client_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cmis-client.Po@am__quote@ # am--include-marker $(am__depfiles_remade): @$(MKDIR_P) $(@D) @echo '# dummy' >$@-t && $(am__mv) $@-t $@ am--depfiles: $(am__depfiles_remade) .cxx.o: @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $< .cxx.obj: @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .cxx.lo: @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LTCXXCOMPILE) -c -o $@ $< mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs # This directory's subdirectories are mostly independent; you can cd # into them and run 'make' without going through this Makefile. # To change the values of 'make' variables: instead of editing Makefiles, # (1) if the variable is set in 'config.status', edit 'config.status' # (which will cause the Makefiles to be regenerated when you run 'make'); # (2) otherwise, pass the desired values on the 'make' command line. $(am__recursive_targets): @fail=; \ if $(am__make_keepgoing); then \ failcom='fail=yes'; \ else \ failcom='exit 1'; \ fi; \ dot_seen=no; \ target=`echo $@ | sed s/-recursive//`; \ case "$@" in \ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ *) list='$(SUBDIRS)' ;; \ esac; \ for subdir in $$list; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ dot_seen=yes; \ local_target="$$target-am"; \ else \ local_target="$$target"; \ fi; \ ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ || eval $$failcom; \ done; \ if test "$$dot_seen" = "no"; then \ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ fi; test -z "$$fail" ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique tags: tags-recursive TAGS: tags tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ include_option=--etags-include; \ empty_fix=.; \ else \ include_option=--include; \ empty_fix=; \ fi; \ list='$(SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ test ! -f $$subdir/TAGS || \ set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ fi; \ done; \ $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ if test $$# -gt 0; then \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ "$$@" $$unique; \ else \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$unique; \ fi; \ fi ctags: ctags-recursive CTAGS: ctags ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" cscopelist: cscopelist-recursive cscopelist-am: $(am__tagged_files) list='$(am__tagged_files)'; \ case "$(srcdir)" in \ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ *) sdir=$(subdir)/$(srcdir) ;; \ esac; \ for i in $$list; do \ if test -f "$$i"; then \ echo "$(subdir)/$$i"; \ else \ echo "$$sdir/$$i"; \ fi; \ done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ $(am__make_dryrun) \ || test -d "$(distdir)/$$subdir" \ || $(MKDIR_P) "$(distdir)/$$subdir" \ || exit 1; \ dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ $(am__relativize); \ new_distdir=$$reldir; \ dir1=$$subdir; dir2="$(top_distdir)"; \ $(am__relativize); \ new_top_distdir=$$reldir; \ echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ ($(am__cd) $$subdir && \ $(MAKE) $(AM_MAKEFLAGS) \ top_distdir="$$new_top_distdir" \ distdir="$$new_distdir" \ am__remove_distdir=: \ am__skip_length_check=: \ am__skip_mode_fix=: \ distdir) \ || exit 1; \ fi; \ done check-am: all-am check: check-recursive all-am: Makefile $(PROGRAMS) installdirs: installdirs-recursive installdirs-am: for dir in "$(DESTDIR)$(bindir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-recursive install-exec: install-exec-recursive install-data: install-data-recursive uninstall: uninstall-recursive install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-recursive install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-recursive clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am distclean: distclean-recursive -rm -f ./$(DEPDIR)/cmis-client.Po -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-tags dvi: dvi-recursive dvi-am: html: html-recursive html-am: info: info-recursive info-am: install-data-am: install-dvi: install-dvi-recursive install-dvi-am: install-exec-am: install-binPROGRAMS install-html: install-html-recursive install-html-am: install-info: install-info-recursive install-info-am: install-man: install-pdf: install-pdf-recursive install-pdf-am: install-ps: install-ps-recursive install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-recursive -rm -f ./$(DEPDIR)/cmis-client.Po -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-recursive mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-recursive pdf-am: ps: ps-recursive ps-am: uninstall-am: uninstall-binPROGRAMS .MAKE: $(am__recursive_targets) install-am install-strip .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \ am--depfiles check check-am clean clean-binPROGRAMS \ clean-generic clean-libtool cscopelist-am ctags ctags-am \ distclean distclean-compile distclean-generic \ distclean-libtool distclean-tags distdir dvi dvi-am html \ html-am info info-am install install-am install-binPROGRAMS \ install-data install-data-am install-dvi install-dvi-am \ install-exec install-exec-am install-html install-html-am \ install-info install-info-am install-man install-pdf \ install-pdf-am install-ps install-ps-am install-strip \ installcheck installcheck-am installdirs installdirs-am \ maintainer-clean maintainer-clean-generic mostlyclean \ mostlyclean-compile mostlyclean-generic mostlyclean-libtool \ pdf pdf-am ps ps-am tags tags-am uninstall uninstall-am \ uninstall-binPROGRAMS .PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: libcmis-0.5.2/src/libcmis/0000775000175000017500000000000013411152377012360 500000000000000libcmis-0.5.2/src/libcmis/oauth2-providers.cxx0000664000175000017500000003546613407757661016273 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "oauth2-providers.hxx" #include #include #include #include #include #include "http-session.hxx" #define CHALLENGE_PAGE_ACTION "/signin" #define CHALLENGE_PAGE_ACTION_LEN sizeof( CHALLENGE_PAGE_ACTION ) - 1 #define PIN_FORM_ACTION "/signin/challenge/ipp" #define PIN_FORM_ACTION_LEN sizeof( PIN_FORM_ACTION ) - 1 #define PIN_INPUT_NAME "Pin" using namespace std; namespace { // Encodes the given data according to the application/x-www-form-urlencoded format, see // : std::string escapeForm(const std::string& data) { std::string res; for ( string::const_iterator i = data.begin(); i != data.end(); ++i ) { unsigned char c = static_cast( *i ); if ( c == ' ' || c == '*' || c == '-' || c == '.' || ( c >= '0' && c <= '9' ) || ( c >= 'A' && c <= 'Z' ) || c == '_' || ( c >= 'a' && c <= 'z' ) ) { res += static_cast( c ); } else { static const char hex[16] = { '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F' }; res += '%'; res += hex[c >> 4]; res += hex[c & 0xF]; } } return res; } } string OAuth2Providers::OAuth2Gdrive( HttpSession* session, const string& authUrl, const string& username, const string& password ) { /* This member function implements 'Google OAuth 2.0' * * The interaction is carried out by libcmis, with no web browser involved. * * Normal sequence (without 2FA) is: * 1) a get to activate login page * receive first login page, html format * 2) subsequent post to sent email * receive html page for password input * 3) subsequent post to send password * receive html page for application consent * 4) subsequent post to send a consent for the application * receive a single-use authorization code * this code is returned as a string * * Sequence with 2FA is: * 1) a get to activate login page * receive first login page, html format * 2) subsequent post to sent email * receive html page for password input * 3) subsequent post to send password * receive html page for pin input * 3b) subsequent post to send pin number * receive html page for application consent * 4) subsequent post to send a consent for the application * receive a single-use authorization code * this code is returned as a string */ static const string CONTENT_TYPE( "application/x-www-form-urlencoded" ); // STEP 1: get login page string res; try { // send the first get, receive the html login page res = session->httpGetRequest( authUrl )->getStream( )->str( ); } catch ( const CurlException& ) { return string( ); } // STEP 2: send email string loginEmailPost, loginEmailLink; if ( !parseResponse( res.c_str( ), loginEmailPost, loginEmailLink ) ) return string( ); loginEmailPost += "Email="; loginEmailPost += escapeForm( username ); istringstream loginEmailIs( loginEmailPost ); string loginEmailRes; try { // send a post with user email, receive the html page for password input loginEmailRes = session->httpPostRequest ( loginEmailLink, loginEmailIs, CONTENT_TYPE ) ->getStream( )->str( ); } catch ( const CurlException& ) { return string( ); } // STEP 3: password page string loginPasswdPost, loginPasswdLink; if ( !parseResponse( loginEmailRes.c_str( ), loginPasswdPost, loginPasswdLink ) ) return string( ); loginPasswdPost += "Passwd="; loginPasswdPost += escapeForm( password ); istringstream loginPasswdIs( loginPasswdPost ); string loginPasswdRes; try { // send a post with user password, receive the application consent page loginPasswdRes = session->httpPostRequest ( loginPasswdLink, loginPasswdIs, CONTENT_TYPE ) ->getStream( )->str( ); } catch ( const CurlException& ) { return string( ); } string approvalPost, approvalLink; if ( !parseResponse( loginPasswdRes. c_str( ), approvalPost, approvalLink) ) return string( ); // when 2FA is enabled, link doesn't start with 'http' if ( approvalLink.compare(0, 4, "http") != 0 ) { // STEP 3b: 2 Factor Authentication, pin code request string loginChallengePost( approvalPost ); string loginChallengeLink( approvalLink ); libcmis::OAuth2AuthCodeProvider fallbackProvider = libcmis::SessionFactory::getOAuth2AuthCodeProvider( ); unique_ptr< char, void (*)( void * ) > pin{ fallbackProvider( "", "", "" ), free }; if( !pin ) { // unset OAuth2AuthCode Provider to avoid showing pin request again in the HttpSession::oauth2Authenticate libcmis::SessionFactory::setOAuth2AuthCodeProvider( NULL ); return string( ); } loginChallengeLink = "https://accounts.google.com" + loginChallengeLink; loginChallengePost += string( PIN_INPUT_NAME ) + "="; loginChallengePost += string( pin.get() ); istringstream loginChallengeIs( loginChallengePost ); string loginChallengeRes; try { // send a post with pin, receive the application consent page loginChallengeRes = session->httpPostRequest ( loginChallengeLink, loginChallengeIs, CONTENT_TYPE ) ->getStream( )->str( ); } catch ( const CurlException& ) { return string( ); } approvalPost = string(); approvalLink = string(); if ( !parseResponse( loginChallengeRes. c_str( ), approvalPost, approvalLink) ) return string( ); } else if( approvalLink.compare( "https://accounts.google.com/ServiceLoginAuth" ) == 0 ) { // wrong password, // unset OAuth2AuthCode Provider to avoid showing pin request again in the HttpSession::oauth2Authenticate libcmis::SessionFactory::setOAuth2AuthCodeProvider( NULL ); return string( ); } // STEP 4: allow libcmis to access google drive approvalPost += "submit_access=true"; istringstream approvalIs( approvalPost ); string approvalRes; try { // send a post with application consent approvalRes = session->httpPostRequest ( approvalLink, approvalIs, CONTENT_TYPE) ->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } // Take the authentication code from the text bar string code = parseCode( approvalRes.c_str( ) ); return code; } string OAuth2Providers::OAuth2Onedrive( HttpSession* /*session*/, const string& /*authUrl*/, const string& /*username*/, const string& /*password*/ ) { return string( ); } string OAuth2Providers::OAuth2Alfresco( HttpSession* session, const string& authUrl, const string& username, const string& password ) { static const string CONTENT_TYPE( "application/x-www-form-urlencoded" ); // Log in string res; try { res = session->httpGetRequest( authUrl )->getStream( )->str( ); } catch ( const CurlException& ) { return string( ); } string loginPost, loginLink; if ( !parseResponse( res.c_str( ), loginPost, loginLink ) ) return string( ); loginPost += "username="; loginPost += string( username ); loginPost += "&password="; loginPost += string( password ); loginPost += "&action=Grant"; istringstream loginIs( loginPost ); libcmis::HttpResponsePtr resp; // Get the code try { // Alfresco code is in the redirect link resp = session->httpPostRequest( loginLink, loginIs, CONTENT_TYPE, false ); } catch ( const CurlException& ) { return string( ); } string header = resp->getHeaders()["Location"]; string code; int start = header.find("code="); int notFound = ( int ) ( string::npos ); if ( start != notFound ) { start += 5; int end = header.find("&"); if ( end != notFound ) code = header.substr( start, end - start ); else code = header.substr( start ); } return code; } OAuth2Parser OAuth2Providers::getOAuth2Parser( const std::string& url ) { if ( boost::starts_with( url, "https://api.alfresco.com/" ) ) // For Alfresco in the cloud, only match the hostname as there can be several // binding URLs created with it. return OAuth2Alfresco; else if ( boost::starts_with( url, "https://www.googleapis.com/drive/v2" ) ) return OAuth2Gdrive; else if ( boost::starts_with( url, "https://apis.live.net/v5.0" ) ) return OAuth2Onedrive; return OAuth2Gdrive; } int OAuth2Providers::parseResponse ( const char* response, string& post, string& link ) { xmlDoc *doc = htmlReadDoc ( BAD_CAST( response ), NULL, 0, HTML_PARSE_NOWARNING | HTML_PARSE_RECOVER | HTML_PARSE_NOERROR ); if ( doc == NULL ) return 0; xmlTextReaderPtr reader = xmlReaderWalker( doc ); if ( reader == NULL ) return 0; bool readInputField = false; bool bIsRightForm = false; bool bHasPinField = false; while ( true ) { // Go to the next node, quit if not found if ( xmlTextReaderRead ( reader ) != 1) break; xmlChar* nodeName = xmlTextReaderName ( reader ); if ( nodeName == NULL ) continue; // Find the redirect link if ( xmlStrEqual( nodeName, BAD_CAST( "form" ) ) ) { // 2FA: Don't add fields form other forms not having pin field if ( bIsRightForm && !bHasPinField ) post = string( "" ); if ( bIsRightForm && bHasPinField ) break; xmlChar* action = xmlTextReaderGetAttribute( reader, BAD_CAST( "action" )); // GDrive pin code page contains many forms. // We have to parse only the form with pin field. if ( action != NULL ) { bool bChallengePage = ( strncmp( (char*)action, CHALLENGE_PAGE_ACTION, CHALLENGE_PAGE_ACTION_LEN ) == 0 ); bIsRightForm = ( strncmp( (char*)action, PIN_FORM_ACTION, PIN_FORM_ACTION_LEN ) == 0 ); if ( ( xmlStrlen( action ) > 0 ) && ( ( bChallengePage && bIsRightForm ) || !bChallengePage ) ) { link = string ( (char*) action); readInputField = true; } else readInputField = false; xmlFree (action); } } // Find input values if ( readInputField && !xmlStrcmp( nodeName, BAD_CAST( "input" ) ) ) { xmlChar* name = xmlTextReaderGetAttribute( reader, BAD_CAST( "name" )); xmlChar* value = xmlTextReaderGetAttribute( reader, BAD_CAST( "value" )); if ( name != NULL && strcmp( (char*)name, PIN_INPUT_NAME ) == 0 ) bHasPinField = true; if ( ( name != NULL ) && ( value!= NULL ) ) { if ( ( xmlStrlen( name ) > 0) && ( xmlStrlen( value ) > 0) ) { post += libcmis::escape( ( char * ) name ); post += string ( "=" ); post += libcmis::escape( ( char * ) value ); post += string ( "&" ); } } xmlFree( name ); xmlFree( value ); } xmlFree( nodeName ); } xmlFreeTextReader( reader ); xmlFreeDoc( doc ); if ( link.empty( ) || post.empty () ) return 0; return 1; } string OAuth2Providers::parseCode( const char* response ) { string authCode; xmlDoc *doc = htmlReadDoc ( BAD_CAST( response ), NULL, 0, HTML_PARSE_NOWARNING | HTML_PARSE_RECOVER | HTML_PARSE_NOERROR ); if ( doc == NULL ) return authCode; xmlTextReaderPtr reader = xmlReaderWalker( doc ); if ( reader == NULL ) return authCode; while ( true ) { // Go to the next node, quit if not found if ( xmlTextReaderRead ( reader ) != 1) break; xmlChar* nodeName = xmlTextReaderName ( reader ); if ( nodeName == NULL ) continue; // Find the code if ( xmlStrEqual( nodeName, BAD_CAST ( "input" ) ) ) { xmlChar* id = xmlTextReaderGetAttribute( reader, BAD_CAST( "id" )); if ( id != NULL ) { if ( xmlStrEqual( id, BAD_CAST ( "code" ) ) ) { xmlChar* code = xmlTextReaderGetAttribute( reader, BAD_CAST("value") ); if ( code!= NULL ) { authCode = string ( (char*) code ); xmlFree( code ); } } xmlFree ( id ); } } xmlFree( nodeName ); } xmlFreeTextReader( reader ); xmlFreeDoc( doc ); return authCode; } libcmis-0.5.2/src/libcmis/gdrive-session.cxx0000664000175000017500000001305413407414352015767 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "gdrive-session.hxx" #include #include "oauth2-handler.hxx" #include "gdrive-document.hxx" #include "gdrive-folder.hxx" #include "gdrive-repository.hxx" #include "gdrive-object-type.hxx" #include "gdrive-utils.hxx" using namespace std; GDriveSession::GDriveSession ( string baseUrl, string username, string password, libcmis::OAuth2DataPtr oauth2, bool verbose ) : BaseSession( baseUrl, string(), username, password, false, libcmis::OAuth2DataPtr(), verbose ) { // Add the dummy repository, even if we don't have OAuth2 m_repositories.push_back( getRepository( ) ); if ( oauth2 && oauth2->isComplete( ) ){ setOAuth2Data( oauth2 ); } } GDriveSession::GDriveSession( const GDriveSession& copy ) : BaseSession( copy ) { } GDriveSession::GDriveSession() : BaseSession() { } GDriveSession::~GDriveSession() { } libcmis::RepositoryPtr GDriveSession::getRepository( ) { // Return a dummy repository since GDrive doesn't have that notion libcmis::RepositoryPtr repo( new GdriveRepository( ) ); return repo; } bool GDriveSession::setRepository( std::string ) { return true; } libcmis::ObjectPtr GDriveSession::getObject( string objectId ) { // Run the http request to get the properties definition string res; string objectLink = m_bindingUrl + "/files/" + objectId; try { res = httpGetRequest( objectLink )->getStream()->str(); } catch ( const CurlException& e ) { throw e.getCmisException( ); } Json jsonRes = Json::parse( res ); // If we have a folder, then convert the object // into a GDriveFolder otherwise, convert it // into a GDriveDocument libcmis::ObjectPtr object; string kind = jsonRes["kind"].toString( ); if ( kind == "drive#file" ) { string mimeType = jsonRes["mimeType"].toString( ); // Folder is a file with a special mimeType if ( mimeType == GDRIVE_FOLDER_MIME_TYPE ) object.reset( new GDriveFolder( this, jsonRes ) ); else object.reset( new GDriveDocument( this, jsonRes ) ); } else if ( kind == "drive#revision" ) // A revision is a document too { object.reset( new GDriveDocument( this, jsonRes ) ); } else // not a folder nor file, maybe a permission or changes,... object.reset( new GDriveObject( this, jsonRes ) ); return object; } libcmis::ObjectPtr GDriveSession::getObjectByPath( string path ) { size_t pos = 0; size_t endpos = 0; string objectId; libcmis::ObjectPtr object; do { endpos = path.find( "/", pos ); size_t len = path.length( ) - pos; if ( endpos != string::npos ) len = endpos - pos; string segment = path.substr( pos, len ); if ( segment.empty( ) ) { // Root case or ignore double slashes if ( pos == 0 ) objectId = "root"; else continue; } else { // Normal child case // Ask for the ID of the child if there is any string childIdUrl = m_bindingUrl + "/files/" + objectId + "/children/?q=title+=+'" + segment + "'&fields=items:id"; string res; try { res = httpGetRequest( childIdUrl )->getStream()->str(); } catch ( const CurlException& e ) { throw e.getCmisException( ); } Json jsonRes = Json::parse( res ); // Did we get an id? Json::JsonVector items = jsonRes["items"].getList(); if ( items.empty( ) ) throw libcmis::Exception( "Object not found: " + path, "objectNotFound" ); objectId = items[0]["id"].toString( ); if ( objectId.empty( ) ) throw libcmis::Exception( "Object not found: " + path, "objectNotFound" ); } pos = endpos + 1; } while ( endpos != string::npos ); return getObject( objectId ); } libcmis::ObjectTypePtr GDriveSession::getType( string id ) { libcmis::ObjectTypePtr type( new GdriveObjectType( id ) ); return type; } vector< libcmis::ObjectTypePtr > GDriveSession::getBaseTypes( ) { vector< libcmis::ObjectTypePtr > types; // TODO Implement me return types; } libcmis-0.5.2/src/libcmis/dummy.cxx0000664000175000017500000000000013407173247014151 00000000000000libcmis-0.5.2/src/libcmis/ws-session.cxx0000664000175000017500000003510713407414352015143 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "ws-session.hxx" #include #include #include #include #include #include #include "ws-requests.hxx" using namespace std; WSSession::WSSession( string bindingUrl, string repositoryId, string username, string password, bool noSslCheck, libcmis::OAuth2DataPtr oauth2, bool verbose ) : BaseSession( bindingUrl, repositoryId, username, password, noSslCheck, oauth2, verbose ), m_servicesUrls( ), m_navigationService( NULL ), m_objectService( NULL ), m_repositoryService( NULL ), m_versioningService( NULL ), m_responseFactory( ) { // We don't want to have the HTTP exceptions as the errors are coming // back as SoapFault elements. setNoHttpErrors( true ); initialize( ); } WSSession::WSSession( string bindingUrl, string repositoryId, const HttpSession& httpSession, libcmis::HttpResponsePtr response ) : BaseSession( bindingUrl, repositoryId, httpSession ), m_servicesUrls( ), m_navigationService( NULL ), m_objectService( NULL ), m_repositoryService( NULL ), m_versioningService( NULL ), m_responseFactory( ) { // We don't want to have the HTTP exceptions as the errors are coming // back as SoapFault elements. setNoHttpErrors( true ); initialize( response ); } WSSession::WSSession( const WSSession& copy ) : BaseSession( copy ), m_servicesUrls( copy.m_servicesUrls ), m_navigationService( NULL ), m_objectService( NULL ), m_repositoryService( NULL ), m_versioningService( NULL ), m_responseFactory( copy.m_responseFactory ) { } WSSession::WSSession( ) : BaseSession( ), m_servicesUrls( ), m_navigationService( NULL ), m_objectService( NULL ), m_repositoryService( NULL ), m_versioningService( NULL ), m_responseFactory( ) { setNoHttpErrors( true ); } WSSession& WSSession::operator=( const WSSession& copy ) { if ( this != © ) { BaseSession::operator=( copy ); m_servicesUrls = copy.m_servicesUrls; m_responseFactory = copy.m_responseFactory; delete m_navigationService; m_navigationService = NULL; delete m_objectService; m_objectService = NULL; delete m_repositoryService; m_repositoryService = NULL; delete m_versioningService; m_versioningService = NULL; } return *this; } WSSession::~WSSession( ) { delete m_navigationService; delete m_objectService; delete m_repositoryService; delete m_versioningService; } string WSSession::getWsdl( string url, libcmis::HttpResponsePtr response ) { string buf; if ( response ) buf = response->getStream( )->str( ); else buf = httpGetRequest( url )->getStream( )->str( ); // Do we have a wsdl file? bool isWsdl = false; xmlDocPtr doc = xmlReadMemory( buf.c_str(), buf.size(), m_bindingUrl.c_str(), NULL, 0 ); if ( NULL != doc ) { xmlXPathContextPtr xpathCtx = xmlXPathNewContext( doc ); libcmis::registerCmisWSNamespaces( xpathCtx ); if ( NULL != xpathCtx ) { string definitionsXPath( "/wsdl:definitions" ); xmlXPathObjectPtr xpathObj = xmlXPathEvalExpression( BAD_CAST( definitionsXPath.c_str() ), xpathCtx ); isWsdl = ( xpathObj != NULL ) && ( xpathObj->nodesetval != NULL ) && ( xpathObj->nodesetval->nodeNr > 0 ); xmlXPathFreeObject( xpathObj ); } xmlXPathFreeContext( xpathCtx ); } xmlFreeDoc( doc ); // If we don't have a wsdl file we may have received an HTML explanation for it, // try to add ?wsdl to the URL (last chance to get something) if ( !isWsdl ) { if ( url.find( "?" ) == string::npos ) url += "?"; else url += "&"; url += "wsdl"; buf = httpGetRequest( url )->getStream( )->str( ); } return buf; } vector< SoapResponsePtr > WSSession::soapRequest( string& url, SoapRequest& request ) { vector< SoapResponsePtr > responses; try { // Place the request in an envelope RelatedMultipart& multipart = request.getMultipart( getUsername( ), getPassword( ) ); libcmis::HttpResponsePtr response = httpPostRequest( url, *multipart.toStream( ).get( ), multipart.getContentType( ) ); string responseType; map< string, string >::iterator it = response->getHeaders( ).find( "Content-Type" ); if ( it != response->getHeaders( ).end( ) ) { responseType = it->second; if ( string::npos != responseType.find( "multipart/related" ) ) { RelatedMultipart answer( response->getStream( )->str( ), responseType ); responses = getResponseFactory( ).parseResponse( answer ); } else if ( string::npos != responseType.find( "text/xml" ) ) { // Parse the envelope string xml = response->getStream( )->str( ); responses = getResponseFactory( ).parseResponse( xml ); } } } catch ( const SoapFault& fault ) { boost::shared_ptr< libcmis::Exception > cmisException = getCmisException( fault ); if ( cmisException ) { throw *cmisException; } throw libcmis::Exception( fault.what( ), "runtime" ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } return responses; } void WSSession::parseWsdl( string buf ) { // parse the content const boost::shared_ptr< xmlDoc > doc( xmlReadMemory( buf.c_str(), buf.size(), m_bindingUrl.c_str(), NULL, 0 ), xmlFreeDoc ); if ( bool( doc ) ) { // Check that we have a WSDL document xmlNodePtr root = xmlDocGetRootElement( doc.get() ); if ( !xmlStrEqual( root->name, BAD_CAST( "definitions" ) ) ) throw libcmis::Exception( "Not a WSDL document" ); // Get all the services soap URLs m_servicesUrls.clear( ); xmlXPathContextPtr xpathCtx = xmlXPathNewContext( doc.get() ); libcmis::registerCmisWSNamespaces( xpathCtx ); if ( NULL != xpathCtx ) { string serviceXPath( "//wsdl:service" ); xmlXPathObjectPtr xpathObj = xmlXPathEvalExpression( BAD_CAST( serviceXPath.c_str() ), xpathCtx ); if ( xpathObj != NULL ) { int nbServices = 0; if ( xpathObj->nodesetval ) nbServices = xpathObj->nodesetval->nodeNr; for ( int i = 0; i < nbServices; i++ ) { // What service do we have here? xmlNodePtr node = xpathObj->nodesetval->nodeTab[i]; string name = libcmis::getXmlNodeAttributeValue( node, "name" ); // Gimme you soap:address location attribute string locationXPath = serviceXPath + "[@name='" + name + "']/wsdl:port/soap:address/attribute::location"; string location = libcmis::getXPathValue( xpathCtx, locationXPath ); m_servicesUrls[name] = location; } } xmlXPathFreeObject( xpathObj ); } xmlXPathFreeContext( xpathCtx ); } else throw libcmis::Exception( "Failed to parse service document" ); } void WSSession::initializeResponseFactory( ) { map< string, string > ns; ns[ "wsssecurity" ] = "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"; ns[ NS_SOAP_ENV_PREFIX ] = NS_SOAP_ENV_URL; ns[ "cmism" ] = NS_CMISM_URL; ns[ "cmisw" ] = NS_CMISW_URL; ns[ "cmis" ] = NS_CMIS_URL; m_responseFactory.setNamespaces( ns ); m_responseFactory.setMapping( getResponseMapping() ); m_responseFactory.setDetailMapping( getDetailMapping( ) ); m_responseFactory.setSession( this ); } void WSSession::initializeRepositories( map< string, string > repositories ) { for ( map< string, string >::iterator it = repositories.begin( ); it != repositories.end( ); ++it ) { string repoId = it->first; m_repositories.push_back( getRepositoryService( ).getRepositoryInfo( repoId ) ); } } void WSSession::initialize( libcmis::HttpResponsePtr response ) { if ( m_repositories.empty() ) { // Get the wsdl file string buf; try { buf = getWsdl( m_bindingUrl, response ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } parseWsdl( buf ); initializeResponseFactory( ); map< string, string > repositories = getRepositoryService( ).getRepositories( ); initializeRepositories( repositories ); } } map< string, SoapResponseCreator > WSSession::getResponseMapping( ) { map< string, SoapResponseCreator > mapping; mapping[ "{" + string( NS_CMISM_URL ) + "}getRepositoriesResponse" ] = &GetRepositoriesResponse::create; mapping[ "{" + string( NS_CMISM_URL ) + "}getRepositoryInfoResponse" ] = &GetRepositoryInfoResponse::create; mapping[ "{" + string( NS_CMISM_URL ) + "}getTypeDefinitionResponse" ] = &GetTypeDefinitionResponse::create; mapping[ "{" + string( NS_CMISM_URL ) + "}getTypeChildrenResponse" ] = &GetTypeChildrenResponse::create; mapping[ "{" + string( NS_CMISM_URL ) + "}getObjectResponse" ] = &GetObjectResponse::create; // No need to create a GetObjectByPathResponse as it would do the same than GetObjectResponse mapping[ "{" + string( NS_CMISM_URL ) + "}getObjectByPathResponse" ] = &GetObjectResponse::create; mapping[ "{" + string( NS_CMISM_URL ) + "}updatePropertiesResponse" ] = &UpdatePropertiesResponse::create; mapping[ "{" + string( NS_CMISM_URL ) + "}deleteTreeResponse" ] = &DeleteTreeResponse::create; mapping[ "{" + string( NS_CMISM_URL ) + "}getContentStreamResponse" ] = &GetContentStreamResponse::create; mapping[ "{" + string( NS_CMISM_URL ) + "}getObjectParentsResponse" ] = &GetObjectParentsResponse::create; mapping[ "{" + string( NS_CMISM_URL ) + "}getChildrenResponse" ] = &GetChildrenResponse::create; mapping[ "{" + string( NS_CMISM_URL ) + "}createFolderResponse" ] = &CreateFolderResponse::create; // Use the same response object than folders as it contains the same elements mapping[ "{" + string( NS_CMISM_URL ) + "}createDocumentResponse" ] = &CreateFolderResponse::create; mapping[ "{" + string( NS_CMISM_URL ) + "}checkOutResponse" ] = &CheckOutResponse::create; mapping[ "{" + string( NS_CMISM_URL ) + "}checkInResponse" ] = &CheckInResponse::create; mapping[ "{" + string( NS_CMISM_URL ) + "}getAllVersionsResponse" ] = &GetAllVersionsResponse::create; mapping[ "{" + string( NS_CMISM_URL ) + "}getRenditionsResponse" ] = &GetRenditionsResponse::create; return mapping; } map< string, SoapFaultDetailCreator > WSSession::getDetailMapping( ) { map< string, SoapFaultDetailCreator > mapping; mapping[ "{" + string( NS_CMISM_URL ) + "}cmisFault" ] = &CmisSoapFaultDetail::create; return mapping; } string WSSession::getServiceUrl( string name ) { string url; map< string, string >::iterator it = m_servicesUrls.find( name ); if ( it != m_servicesUrls.end( ) ) url = it->second; return url; } RepositoryService& WSSession::getRepositoryService( ) { if ( m_repositoryService == NULL ) m_repositoryService = new RepositoryService( this ); return *m_repositoryService; } ObjectService& WSSession::getObjectService( ) { if ( m_objectService == NULL ) m_objectService = new ObjectService( this ); return *m_objectService; } NavigationService& WSSession::getNavigationService( ) { if ( m_navigationService == NULL ) m_navigationService = new NavigationService( this ); return *m_navigationService; } VersioningService& WSSession::getVersioningService( ) { if ( m_versioningService == NULL ) m_versioningService = new VersioningService( this ); return *m_versioningService; } libcmis::RepositoryPtr WSSession::getRepository( ) { // Check if we already have the repository libcmis::RepositoryPtr repo; vector< libcmis::RepositoryPtr >::iterator it = m_repositories.begin(); while ( !repo && it != m_repositories.end() ) { if ( ( *it )->getId() == m_repositoryId ) repo = *it; ++it; } // We found nothing cached, so try to get it from the server if ( !repo ) { repo = getRepositoryService( ).getRepositoryInfo( m_repositoryId ); if ( repo ) m_repositories.push_back( repo ); } return repo; } bool WSSession::setRepository( string repositoryId ) { bool success = false; try { libcmis::RepositoryPtr repo = getRepositoryService( ).getRepositoryInfo( repositoryId ); if (repo && repo->getId( ) == repositoryId ) m_repositoryId = repositoryId; success = true; } catch ( const libcmis::Exception& ) { } return success; } libcmis::ObjectPtr WSSession::getObject( string id ) { return getObjectService( ).getObject( getRepositoryId( ), id ); } libcmis::ObjectPtr WSSession::getObjectByPath( string path ) { return getObjectService( ).getObjectByPath( getRepositoryId( ), path ); } libcmis::ObjectTypePtr WSSession::getType( string id ) { return getRepositoryService( ).getTypeDefinition( m_repositoryId, id ); } vector< libcmis::ObjectTypePtr > WSSession::getBaseTypes( ) { return getRepositoryService().getTypeChildren( m_repositoryId, "" ); } libcmis-0.5.2/src/libcmis/ws-session.hxx0000664000175000017500000001041013407414352015136 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _WS_SESSION_HXX_ #define _WS_SESSION_HXX_ #include #include #include "base-session.hxx" #include "ws-navigationservice.hxx" #include "ws-objectservice.hxx" #include "ws-repositoryservice.hxx" #include "ws-soap.hxx" #include "ws-versioningservice.hxx" class WSSession : public BaseSession, public SoapSession { private: std::map< std::string, std::string > m_servicesUrls; NavigationService* m_navigationService; ObjectService* m_objectService; RepositoryService* m_repositoryService; VersioningService* m_versioningService; SoapResponseFactory m_responseFactory; public: WSSession( std::string bindingUrl, std::string repositoryId, std::string username, std::string password, bool noSslCheck = false, libcmis::OAuth2DataPtr oauth2 = libcmis::OAuth2DataPtr(), bool verbose = false ); /** This constructor uses the response of an HTTP request made before to spare some HTTP request. This constructor has mostly been designed for the SessionFactory use. */ WSSession( std::string bindingUrl, std::string repositoryId, const HttpSession& HttpSession, libcmis::HttpResponsePtr response ); WSSession( const WSSession& copy ); ~WSSession( ); WSSession& operator=( const WSSession& copy ); // Utility methods /** Get an instance of the SoapResponseFactory, setup with all the CMIS namespaces and function pointers. */ SoapResponseFactory& getResponseFactory( ) { return m_responseFactory; } /** Try hard to get a WSDL file at the given URL (tries to add ?wsdl if needed) */ std::string getWsdl( std::string url, libcmis::HttpResponsePtr response ); std::vector< SoapResponsePtr > soapRequest( std::string& url, SoapRequest& request ); /** Get the service location URL given its name. */ std::string getServiceUrl( std::string name ); RepositoryService& getRepositoryService( ); ObjectService& getObjectService( ); NavigationService& getNavigationService( ); VersioningService& getVersioningService( ); // Override session methods virtual libcmis::RepositoryPtr getRepository( ); virtual bool setRepository( std::string repositoryId ); virtual libcmis::ObjectPtr getObject( std::string id ); virtual libcmis::ObjectPtr getObjectByPath( std::string path ); virtual libcmis::ObjectTypePtr getType( std::string id ); virtual std::vector< libcmis::ObjectTypePtr > getBaseTypes( ); private: // Default constructor shouldn't be called WSSession( ); void parseWsdl( std::string buf ); void initializeResponseFactory( ); void initializeRepositories( std::map< std::string, std::string > repositories ); void initialize( libcmis::HttpResponsePtr response = libcmis::HttpResponsePtr() ); std::map< std::string, SoapResponseCreator > getResponseMapping( ); std::map< std::string, SoapFaultDetailCreator > getDetailMapping( ); }; #endif libcmis-0.5.2/src/libcmis/sharepoint-object.hxx0000664000175000017500000000527213407414352016456 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _SHAREPOINT_OBJECT_HXX_ #define _SHAREPOINT_OBJECT_HXX_ #include #include "sharepoint-session.hxx" #include "json-utils.hxx" // Class representing an object for SharePoint protocol. class SharePointObject : public virtual libcmis::Object { public: SharePointObject( SharePointSession* session ); // Create a SharePoint document from Json properties. SharePointObject( SharePointSession* session, Json json, std::string parentId = std::string( ), std::string name = std::string( ) ); SharePointObject( const SharePointObject& copy ); virtual ~SharePointObject( ) { } SharePointObject& operator=( const SharePointObject& copy ); void initializeFromJson( Json json, std::string parentId = std::string( ), std::string name = std::string( ) ); void refreshImpl( Json json ); virtual void refresh( ); virtual void remove( bool allVersions = true ); std::vector< std::string > getMultiStringProperty( const std::string& propertyName ); virtual boost::shared_ptr< Object > updateProperties( const libcmis::PropertyPtrMap& properties ); virtual std::vector< libcmis::RenditionPtr> getRenditions( std::string /*filter = std::string( )*/ ) {return std::vector< libcmis::RenditionPtr>( );} virtual void move( boost::shared_ptr< libcmis::Folder > source, boost::shared_ptr< libcmis::Folder > destination ); protected: SharePointSession* getSession( ); }; #endif libcmis-0.5.2/src/libcmis/gdrive-object.cxx0000664000175000017500000002212113407414352015545 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 SUSE * 2013 Cao Cuong Ngo * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "gdrive-object.hxx" #include "gdrive-property.hxx" #include "gdrive-allowable-actions.hxx" #include "gdrive-repository.hxx" #include "gdrive-utils.hxx" using namespace std; using namespace libcmis; GDriveObject::GDriveObject( GDriveSession* session ) : libcmis::Object( session ) { } GDriveObject::GDriveObject( GDriveSession* session, Json json, string id, string name ) : libcmis::Object( session ) { initializeFromJson( json, id, name ); } GDriveObject::GDriveObject( const GDriveObject& copy ) : libcmis::Object( copy ) { } GDriveObject& GDriveObject::operator=( const GDriveObject& copy ) { if ( this != © ) { libcmis::Object::operator=( copy ); } return *this; } void GDriveObject::initializeFromJson ( Json json, string id, string name ) { Json::JsonObject objs = json.getObjects( ); Json::JsonObject::iterator it; for ( it = objs.begin( ); it != objs.end( ); ++it) { PropertyPtr property; // in case of a revision, get the ID and name of the original file if ( !id.empty( ) && it->first == "id" ) { Json idJson( id.c_str( ) ); property.reset( new GDriveProperty( "id", idJson ) ); m_properties[ property->getPropertyType( )->getId()] = property; property.reset( new GDriveProperty( "revisionId", it->second ) ); m_properties[ property->getPropertyType( )->getId()] = property; Json nameJson( name.c_str( ) ); property.reset( new GDriveProperty( "cmis:name", nameJson) ); m_properties[ property->getPropertyType( )->getId()] = property; property.reset( new GDriveProperty( "cmis:contentStreamFileName", nameJson) ); m_properties[ property->getPropertyType( )->getId()] = property; } else { property.reset( new GDriveProperty( it->first, it->second ) ); m_properties[ property->getPropertyType( )->getId()] = property; // we map "title" to both "cmis:name" and "cmis:getContentStreamFileName" if ( it->first == "title" ) { property.reset( new GDriveProperty( "cmis:name", it->second) ); m_properties[ property->getPropertyType( )->getId()] = property; } // some revision keep the original file name. if ( it->first == "originalFilename" ) { property.reset( new GDriveProperty( "cmis:name", it->second ) ); m_properties[ property->getPropertyType( )->getId()] = property; property.reset( new GDriveProperty( "cmis:contentStreamFileName", it->second) ); m_properties[ property->getPropertyType( )->getId()] = property; } // In case of a revision, get the modified date as creation date if ( it->first == "modifiedDate" && !id.empty( ) ) { property.reset( new GDriveProperty( "cmis:creationDate", it->second) ); m_properties[ property->getPropertyType( )->getId()] = property; } // In case of a revision, get the last modifying user and the creator if ( it->first == "lastModifyingUserName" && !id.empty( ) ) { property.reset( new GDriveProperty( "cmis:createdBy", it->second) ); m_properties[ property->getPropertyType( )->getId()] = property; } } } m_refreshTimestamp = time( NULL ); // Create AllowableActions bool isFolder = json["mimeType"].toString( ) == GDRIVE_FOLDER_MIME_TYPE; m_allowableActions.reset( new GdriveAllowableActions( isFolder ) ); } GDriveSession* GDriveObject::getSession( ) { return dynamic_cast< GDriveSession* > ( m_session ); } void GDriveObject::refreshImpl( Json json ) { m_typeDescription.reset( ); m_properties.clear( ); initializeFromJson( json ); } vector< RenditionPtr> GDriveObject::getRenditions( string /* filter */ ) { if ( m_renditions.empty( ) ) { string downloadUrl = getStringProperty( "downloadUrl" ); if ( !downloadUrl.empty( ) ) { string mimeType = getStringProperty( "cmis:contentStreamMimeType" ); if ( !mimeType.empty( ) ) { RenditionPtr rendition( new Rendition( mimeType, mimeType, mimeType, downloadUrl )); m_renditions.push_back( rendition ); } } vector< string > exportLinks = getMultiStringProperty( "exportLinks" ); for ( vector::iterator it = exportLinks.begin( ); it != exportLinks.end( ); ++it) { int pos = (*it).find(":\""); if ( pos == -1 ) continue; string mimeType = (*it).substr( 0, pos ); string url = (*it).substr( pos + 2, (*it).length( ) - pos - 3 ); RenditionPtr rendition( new Rendition( mimeType, mimeType, mimeType, url ) ); m_renditions.push_back( rendition ); } // thumbnail link string thumbnailLink = getStringProperty( "thumbnailLink" ); if ( !thumbnailLink.empty( ) ) { string mimeType = "cmis:thumbnail"; RenditionPtr rendition( new Rendition( mimeType, mimeType, mimeType, thumbnailLink )); m_renditions.push_back( rendition ); } } return m_renditions; } libcmis::ObjectPtr GDriveObject::updateProperties( const PropertyPtrMap& properties ) { // Make Json object from properties Json json = GdriveUtils::toGdriveJson( properties ); istringstream is( json.toString( )); libcmis::HttpResponsePtr response; try { vector< string > headers; headers.push_back( "Content-Type: application/json" ); response = getSession( )->httpPutRequest( getUrl( ), is, headers ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } string res = response->getStream( )->str( ); Json jsonRes = Json::parse( res ); libcmis::ObjectPtr updated( new GDriveObject ( getSession( ), jsonRes ) ); if ( updated->getId( ) == getId( ) ) refreshImpl( jsonRes ); return updated; } void GDriveObject::refresh( ) { string res; try { res = getSession()->httpGetRequest( getUrl( ) )->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } Json json = Json::parse( res ); refreshImpl( json ); } void GDriveObject::remove( bool /*allVersions*/ ) { try { getSession( )->httpDeleteRequest( getUrl( ) ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } } void GDriveObject::move( FolderPtr /*source*/, FolderPtr destination ) { Json parentsJson; Json parentsValue = GdriveUtils::createJsonFromParentId( destination->getId( ) ); parentsJson.add( "parents", parentsValue ); istringstream is( parentsJson.toString( ) ); libcmis::HttpResponsePtr response; try { vector< string > headers; headers.push_back( "Content-Type: application/json" ); response = getSession( )->httpPutRequest( getUrl( ), is, headers ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } string res = response->getStream( )->str( ); Json jsonRes = Json::parse( res ); refreshImpl( jsonRes ); } string GDriveObject::getUrl( ) { return getSession( )->getBindingUrl( ) + "/files/" + getId( ); } string GDriveObject::getUploadUrl( ) { return GDRIVE_UPLOAD_LINKS; } vector< string> GDriveObject::getMultiStringProperty( const string& propertyName ) { vector< string > values; PropertyPtrMap::const_iterator it = getProperties( ).find( string( propertyName ) ); if ( it != getProperties( ).end( ) && it->second != NULL && !it->second->getStrings( ).empty( ) ) values = it->second->getStrings( ); return values; } libcmis-0.5.2/src/libcmis/atom-object-type.cxx0000664000175000017500000001137013407414352016210 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "atom-object-type.hxx" #include #include using namespace std; using namespace boost; AtomObjectType::AtomObjectType( AtomPubSession* session, string id ) : libcmis::ObjectType( ), m_session( session ), m_selfUrl( ), m_childrenUrl( ) { m_id = id; refresh( ); } AtomObjectType::AtomObjectType( AtomPubSession* session, xmlNodePtr entryNd ) : libcmis::ObjectType( ), m_session( session ), m_selfUrl( ), m_childrenUrl( ) { xmlDocPtr doc = libcmis::wrapInDoc( entryNd ); refreshImpl( doc ); xmlFreeDoc( doc ); } AtomObjectType::AtomObjectType( const AtomObjectType& copy ) : libcmis::ObjectType( copy ), m_session( copy.m_session ), m_selfUrl( copy.m_selfUrl ), m_childrenUrl( copy.m_childrenUrl ) { } AtomObjectType::~AtomObjectType( ) { } AtomObjectType& AtomObjectType::operator=( const AtomObjectType& copy ) { if ( this != © ) { libcmis::ObjectType::operator=( copy ); m_session = copy.m_session; m_selfUrl = copy.m_selfUrl; m_childrenUrl = copy.m_childrenUrl; } return *this; } libcmis::ObjectTypePtr AtomObjectType::getParentType( ) { return m_session->getType( m_parentTypeId ); } libcmis::ObjectTypePtr AtomObjectType::getBaseType( ) { return m_session->getType( m_baseTypeId ); } vector< libcmis::ObjectTypePtr > AtomObjectType::getChildren( ) { return m_session->getChildrenTypes( m_childrenUrl ); } void AtomObjectType::refreshImpl( xmlDocPtr doc ) { bool createdDoc = ( NULL == doc ); if ( createdDoc ) { string pattern = m_session->getAtomRepository()->getUriTemplate( UriTemplate::TypeById ); map< string, string > vars; vars[URI_TEMPLATE_VAR_ID] = getId( ); string url = m_session->createUrl( pattern, vars ); string buf; try { buf = m_session->httpGetRequest( url )->getStream()->str(); } catch ( const CurlException& e ) { if ( ( e.getErrorCode( ) == CURLE_HTTP_RETURNED_ERROR ) && ( e.getHttpStatus( ) == 404 ) ) { string msg = "No such type: "; msg += getId( ); throw libcmis::Exception( msg, "objectNotFound" ); } else throw e.getCmisException( ); } doc = xmlReadMemory( buf.c_str(), buf.size(), m_selfUrl.c_str(), NULL, 0 ); if ( NULL == doc ) throw libcmis::Exception( "Failed to parse object infos" ); } extractInfos( doc ); if ( createdDoc ) xmlFreeDoc( doc ); } void AtomObjectType::extractInfos( xmlDocPtr doc ) { xmlXPathContextPtr xpathCtx = xmlXPathNewContext( doc ); // Register the Service Document namespaces libcmis::registerNamespaces( xpathCtx ); if ( NULL != xpathCtx ) { // Get the self URL string selfUrlReq( "//atom:link[@rel='self']/attribute::href" ); m_selfUrl = libcmis::getXPathValue( xpathCtx, selfUrlReq ); // Get the children URL string childrenUrlReq( "//atom:link[@rel='down' and @type='application/atom+xml;type=feed']/attribute::href" ); m_childrenUrl = libcmis::getXPathValue( xpathCtx, childrenUrlReq ); // Get the cmisra:type node xmlXPathObjectPtr xpathObj = xmlXPathEvalExpression( BAD_CAST( "//cmisra:type" ), xpathCtx ); if ( NULL != xpathObj && NULL != xpathObj->nodesetval && xpathObj->nodesetval->nodeNr ) { xmlNodePtr typeNode = xpathObj->nodesetval->nodeTab[0]; initializeFromNode( typeNode ); } xmlXPathFreeObject( xpathObj ); } xmlXPathFreeContext( xpathCtx ); } libcmis-0.5.2/src/libcmis/Makefile.in0000664000175000017500000033305313407705042014352 00000000000000# Makefile.in generated by automake 1.16.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2018 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ @ENABLE_VISIBILITY_TRUE@am__append_1 = -fvisibility=hidden @ENABLE_VISIBILITY_TRUE@am__append_2 = -DLIBCMIS_VISIBILITY subdir = src/libcmis ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \ $(top_srcdir)/m4/ax_cxx_compile_stdcxx_11.m4 \ $(top_srcdir)/m4/ax_gcc_func_attribute.m4 \ $(top_srcdir)/m4/boost.m4 $(top_srcdir)/m4/libtool.m4 \ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; am__install_max = 40 am__nobase_strip_setup = \ srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` am__nobase_strip = \ for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" am__nobase_list = $(am__nobase_strip_setup); \ for p in $$list; do echo "$$p $$p"; done | \ sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ if (++n[$$2] == $(am__install_max)) \ { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ END { for (dir in files) print dir, files[dir] }' am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' am__uninstall_files_from_dir = { \ test -z "$$files" \ || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ $(am__cd) "$$dir" && rm -f $$files; }; \ } am__installdirs = "$(DESTDIR)$(libdir)" LTLIBRARIES = $(lib_LTLIBRARIES) $(noinst_LTLIBRARIES) am__DEPENDENCIES_1 = libcmis_@LIBCMIS_API_VERSION@_la_DEPENDENCIES = libcmis.la \ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) am_libcmis_@LIBCMIS_API_VERSION@_la_OBJECTS = dummy.lo libcmis_@LIBCMIS_API_VERSION@_la_OBJECTS = \ $(am_libcmis_@LIBCMIS_API_VERSION@_la_OBJECTS) AM_V_lt = $(am__v_lt_@AM_V@) am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) am__v_lt_0 = --silent am__v_lt_1 = libcmis_@LIBCMIS_API_VERSION@_la_LINK = $(LIBTOOL) $(AM_V_lt) \ --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link \ $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) \ $(libcmis_@LIBCMIS_API_VERSION@_la_LDFLAGS) $(LDFLAGS) -o $@ libcmis_la_LIBADD = am_libcmis_la_OBJECTS = libcmis_la-allowable-actions.lo \ libcmis_la-atom-document.lo libcmis_la-atom-folder.lo \ libcmis_la-atom-object-type.lo libcmis_la-atom-object.lo \ libcmis_la-atom-session.lo libcmis_la-atom-workspace.lo \ libcmis_la-base-session.lo libcmis_la-document.lo \ libcmis_la-folder.lo libcmis_la-gdrive-document.lo \ libcmis_la-gdrive-folder.lo libcmis_la-gdrive-object-type.lo \ libcmis_la-gdrive-object.lo libcmis_la-gdrive-property.lo \ libcmis_la-gdrive-repository.lo libcmis_la-gdrive-session.lo \ libcmis_la-gdrive-utils.lo libcmis_la-http-session.lo \ libcmis_la-json-utils.lo libcmis_la-oauth2-data.lo \ libcmis_la-oauth2-handler.lo libcmis_la-oauth2-providers.lo \ libcmis_la-object-type.lo libcmis_la-object.lo \ libcmis_la-onedrive-document.lo libcmis_la-onedrive-folder.lo \ libcmis_la-onedrive-object-type.lo \ libcmis_la-onedrive-object.lo libcmis_la-onedrive-property.lo \ libcmis_la-onedrive-repository.lo \ libcmis_la-onedrive-session.lo libcmis_la-onedrive-utils.lo \ libcmis_la-property-type.lo libcmis_la-property.lo \ libcmis_la-rendition.lo libcmis_la-repository.lo \ libcmis_la-session-factory.lo \ libcmis_la-sharepoint-document.lo \ libcmis_la-sharepoint-folder.lo \ libcmis_la-sharepoint-object-type.lo \ libcmis_la-sharepoint-object.lo \ libcmis_la-sharepoint-property.lo \ libcmis_la-sharepoint-repository.lo \ libcmis_la-sharepoint-session.lo \ libcmis_la-sharepoint-utils.lo libcmis_la-ws-document.lo \ libcmis_la-ws-folder.lo libcmis_la-ws-navigationservice.lo \ libcmis_la-ws-object-type.lo libcmis_la-ws-object.lo \ libcmis_la-ws-objectservice.lo \ libcmis_la-ws-relatedmultipart.lo \ libcmis_la-ws-repositoryservice.lo libcmis_la-ws-requests.lo \ libcmis_la-ws-session.lo libcmis_la-ws-soap.lo \ libcmis_la-ws-versioningservice.lo libcmis_la-xml-utils.lo libcmis_la_OBJECTS = $(am_libcmis_la_OBJECTS) AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ depcomp = $(SHELL) $(top_srcdir)/depcomp am__maybe_remake_depfiles = depfiles am__depfiles_remade = ./$(DEPDIR)/dummy.Plo \ ./$(DEPDIR)/libcmis_la-allowable-actions.Plo \ ./$(DEPDIR)/libcmis_la-atom-document.Plo \ ./$(DEPDIR)/libcmis_la-atom-folder.Plo \ ./$(DEPDIR)/libcmis_la-atom-object-type.Plo \ ./$(DEPDIR)/libcmis_la-atom-object.Plo \ ./$(DEPDIR)/libcmis_la-atom-session.Plo \ ./$(DEPDIR)/libcmis_la-atom-workspace.Plo \ ./$(DEPDIR)/libcmis_la-base-session.Plo \ ./$(DEPDIR)/libcmis_la-document.Plo \ ./$(DEPDIR)/libcmis_la-folder.Plo \ ./$(DEPDIR)/libcmis_la-gdrive-document.Plo \ ./$(DEPDIR)/libcmis_la-gdrive-folder.Plo \ ./$(DEPDIR)/libcmis_la-gdrive-object-type.Plo \ ./$(DEPDIR)/libcmis_la-gdrive-object.Plo \ ./$(DEPDIR)/libcmis_la-gdrive-property.Plo \ ./$(DEPDIR)/libcmis_la-gdrive-repository.Plo \ ./$(DEPDIR)/libcmis_la-gdrive-session.Plo \ ./$(DEPDIR)/libcmis_la-gdrive-utils.Plo \ ./$(DEPDIR)/libcmis_la-http-session.Plo \ ./$(DEPDIR)/libcmis_la-json-utils.Plo \ ./$(DEPDIR)/libcmis_la-oauth2-data.Plo \ ./$(DEPDIR)/libcmis_la-oauth2-handler.Plo \ ./$(DEPDIR)/libcmis_la-oauth2-providers.Plo \ ./$(DEPDIR)/libcmis_la-object-type.Plo \ ./$(DEPDIR)/libcmis_la-object.Plo \ ./$(DEPDIR)/libcmis_la-onedrive-document.Plo \ ./$(DEPDIR)/libcmis_la-onedrive-folder.Plo \ ./$(DEPDIR)/libcmis_la-onedrive-object-type.Plo \ ./$(DEPDIR)/libcmis_la-onedrive-object.Plo \ ./$(DEPDIR)/libcmis_la-onedrive-property.Plo \ ./$(DEPDIR)/libcmis_la-onedrive-repository.Plo \ ./$(DEPDIR)/libcmis_la-onedrive-session.Plo \ ./$(DEPDIR)/libcmis_la-onedrive-utils.Plo \ ./$(DEPDIR)/libcmis_la-property-type.Plo \ ./$(DEPDIR)/libcmis_la-property.Plo \ ./$(DEPDIR)/libcmis_la-rendition.Plo \ ./$(DEPDIR)/libcmis_la-repository.Plo \ ./$(DEPDIR)/libcmis_la-session-factory.Plo \ ./$(DEPDIR)/libcmis_la-sharepoint-document.Plo \ ./$(DEPDIR)/libcmis_la-sharepoint-folder.Plo \ ./$(DEPDIR)/libcmis_la-sharepoint-object-type.Plo \ ./$(DEPDIR)/libcmis_la-sharepoint-object.Plo \ ./$(DEPDIR)/libcmis_la-sharepoint-property.Plo \ ./$(DEPDIR)/libcmis_la-sharepoint-repository.Plo \ ./$(DEPDIR)/libcmis_la-sharepoint-session.Plo \ ./$(DEPDIR)/libcmis_la-sharepoint-utils.Plo \ ./$(DEPDIR)/libcmis_la-ws-document.Plo \ ./$(DEPDIR)/libcmis_la-ws-folder.Plo \ ./$(DEPDIR)/libcmis_la-ws-navigationservice.Plo \ ./$(DEPDIR)/libcmis_la-ws-object-type.Plo \ ./$(DEPDIR)/libcmis_la-ws-object.Plo \ ./$(DEPDIR)/libcmis_la-ws-objectservice.Plo \ ./$(DEPDIR)/libcmis_la-ws-relatedmultipart.Plo \ ./$(DEPDIR)/libcmis_la-ws-repositoryservice.Plo \ ./$(DEPDIR)/libcmis_la-ws-requests.Plo \ ./$(DEPDIR)/libcmis_la-ws-session.Plo \ ./$(DEPDIR)/libcmis_la-ws-soap.Plo \ ./$(DEPDIR)/libcmis_la-ws-versioningservice.Plo \ ./$(DEPDIR)/libcmis_la-xml-utils.Plo am__mv = mv -f CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ $(AM_CXXFLAGS) $(CXXFLAGS) AM_V_CXX = $(am__v_CXX_@AM_V@) am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@) am__v_CXX_0 = @echo " CXX " $@; am__v_CXX_1 = CXXLD = $(CXX) CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \ $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ AM_V_CXXLD = $(am__v_CXXLD_@AM_V@) am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@) am__v_CXXLD_0 = @echo " CXXLD " $@; am__v_CXXLD_1 = COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ $(AM_CFLAGS) $(CFLAGS) AM_V_CC = $(am__v_CC_@AM_V@) am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) am__v_CC_0 = @echo " CC " $@; am__v_CC_1 = CCLD = $(CC) LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(AM_LDFLAGS) $(LDFLAGS) -o $@ AM_V_CCLD = $(am__v_CCLD_@AM_V@) am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) am__v_CCLD_0 = @echo " CCLD " $@; am__v_CCLD_1 = SOURCES = $(libcmis_@LIBCMIS_API_VERSION@_la_SOURCES) \ $(libcmis_la_SOURCES) DIST_SOURCES = $(libcmis_@LIBCMIS_API_VERSION@_la_SOURCES) \ $(libcmis_la_SOURCES) am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is # *not* preserved. am__uniquify_input = $(AWK) '\ BEGIN { nonempty = 0; } \ { items[$$0] = 1; nonempty = 1; } \ END { if (nonempty) { for (i in items) print i; }; } \ ' # Make sure the list of sources is unique. This is necessary because, # e.g., the same source file might be shared among _SOURCES variables # for different programs/libraries. am__define_uniq_tagged_files = \ list='$(am__tagged_files)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ BOOST_CPPFLAGS = @BOOST_CPPFLAGS@ BOOST_DATE_TIME_LDFLAGS = @BOOST_DATE_TIME_LDFLAGS@ BOOST_DATE_TIME_LDPATH = @BOOST_DATE_TIME_LDPATH@ BOOST_DATE_TIME_LIBS = @BOOST_DATE_TIME_LIBS@ BOOST_LDPATH = @BOOST_LDPATH@ BOOST_PROGRAM_OPTIONS_LDFLAGS = @BOOST_PROGRAM_OPTIONS_LDFLAGS@ BOOST_PROGRAM_OPTIONS_LDPATH = @BOOST_PROGRAM_OPTIONS_LDPATH@ BOOST_PROGRAM_OPTIONS_LIBS = @BOOST_PROGRAM_OPTIONS_LIBS@ BOOST_ROOT = @BOOST_ROOT@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPCHECK = @CPPCHECK@ CPPCHECK_PARALLELISM = @CPPCHECK_PARALLELISM@ CPPFLAGS = @CPPFLAGS@ CPPUNIT_CFLAGS = @CPPUNIT_CFLAGS@ CPPUNIT_LIBS = @CPPUNIT_LIBS@ CURL_CFLAGS = @CURL_CFLAGS@ CURL_LIBS = @CURL_LIBS@ CXX = @CXX@ CXXCPP = @CXXCPP@ CXXDEPMODE = @CXXDEPMODE@ CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DISTCHECK_CONFIGURE_FLAGS = @DISTCHECK_CONFIGURE_FLAGS@ DLLTOOL = @DLLTOOL@ DOCBOOK2MAN = @DOCBOOK2MAN@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ GENHTML = @GENHTML@ GREP = @GREP@ HAVE_CXX11 = @HAVE_CXX11@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LCOV = @LCOV@ LD = @LD@ LDFLAGS = @LDFLAGS@ LIBCMIS_API_VERSION = @LIBCMIS_API_VERSION@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ NPROC = @NPROC@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SRCDIR = @SRCDIR@ STRIP = @STRIP@ VERSION = @VERSION@ XML2_CFLAGS = @XML2_CFLAGS@ XML2_LIBS = @XML2_LIBS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ AM_CXXFLAGS = -I$(top_srcdir)/inc -I$(top_srcdir)/src/libcmis \ $(XML2_CFLAGS) $(CURL_CFLAGS) $(BOOST_CPPFLAGS) \ $(am__append_1) noinst_LTLIBRARIES = libcmis.la lib_LTLIBRARIES = libcmis-@LIBCMIS_API_VERSION@.la libcmis_@LIBCMIS_API_VERSION@_la_SOURCES = \ dummy.cxx libcmis_la_CPPFLAGS = -DLIBCMIS_BUILD $(am__append_2) libcmis_la_SOURCES = \ allowable-actions.cxx \ atom-document.cxx \ atom-document.hxx \ atom-folder.cxx \ atom-folder.hxx \ atom-object-type.cxx \ atom-object-type.hxx \ atom-object.cxx \ atom-object.hxx \ atom-session.cxx \ atom-session.hxx \ atom-workspace.cxx \ atom-workspace.hxx \ base-session.cxx \ base-session.hxx \ document.cxx \ folder.cxx \ gdrive-allowable-actions.hxx \ gdrive-document.cxx \ gdrive-document.hxx \ gdrive-folder.cxx \ gdrive-folder.hxx \ gdrive-object-type.cxx \ gdrive-object-type.hxx \ gdrive-object.cxx \ gdrive-object.hxx \ gdrive-property.cxx \ gdrive-property.hxx \ gdrive-repository.cxx \ gdrive-repository.hxx \ gdrive-session.cxx \ gdrive-session.hxx \ gdrive-utils.cxx \ gdrive-utils.hxx \ http-session.cxx \ http-session.hxx \ json-utils.cxx \ json-utils.hxx \ oauth2-data.cxx \ oauth2-handler.cxx \ oauth2-handler.hxx \ oauth2-providers.cxx \ oauth2-providers.hxx \ object-type.cxx \ object.cxx \ onedrive-allowable-actions.hxx \ onedrive-document.cxx \ onedrive-document.hxx \ onedrive-folder.cxx \ onedrive-folder.hxx \ onedrive-object-type.cxx \ onedrive-object-type.hxx \ onedrive-object.cxx \ onedrive-object.hxx \ onedrive-property.cxx \ onedrive-property.hxx \ onedrive-repository.cxx \ onedrive-repository.hxx \ onedrive-session.cxx \ onedrive-session.hxx \ onedrive-utils.cxx \ onedrive-utils.hxx \ property-type.cxx \ property.cxx \ rendition.cxx \ repository.cxx \ session-factory.cxx \ sharepoint-allowable-actions.hxx \ sharepoint-document.cxx \ sharepoint-document.hxx \ sharepoint-folder.cxx \ sharepoint-folder.hxx \ sharepoint-object-type.cxx \ sharepoint-object-type.hxx \ sharepoint-object.cxx \ sharepoint-object.hxx \ sharepoint-property.cxx \ sharepoint-property.hxx \ sharepoint-repository.cxx \ sharepoint-repository.hxx \ sharepoint-session.cxx \ sharepoint-session.hxx \ sharepoint-utils.cxx \ sharepoint-utils.hxx \ ws-document.cxx \ ws-document.hxx \ ws-folder.cxx \ ws-folder.hxx \ ws-navigationservice.cxx \ ws-navigationservice.hxx \ ws-object-type.cxx \ ws-object-type.hxx \ ws-object.cxx \ ws-object.hxx \ ws-objectservice.cxx \ ws-objectservice.hxx \ ws-relatedmultipart.cxx \ ws-relatedmultipart.hxx \ ws-repositoryservice.cxx \ ws-repositoryservice.hxx \ ws-requests.cxx \ ws-requests.hxx \ ws-session.cxx \ ws-session.hxx \ ws-soap.cxx \ ws-soap.hxx \ ws-versioningservice.cxx \ ws-versioningservice.hxx \ xml-utils.cxx libcmis_@LIBCMIS_API_VERSION@_la_LDFLAGS = -export-dynamic -no-undefined -version-info 5:0:0 libcmis_@LIBCMIS_API_VERSION@_la_LIBADD = \ libcmis.la \ $(XML2_LIBS) \ $(CURL_LIBS) \ $(BOOST_SMART_PTR_LIBS) \ $(BOOST_DATE_TIME_LDFLAGS) \ $(BOOST_DATE_TIME_LIBS) all: all-am .SUFFIXES: .SUFFIXES: .cxx .lo .o .obj $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/libcmis/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign src/libcmis/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): install-libLTLIBRARIES: $(lib_LTLIBRARIES) @$(NORMAL_INSTALL) @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ list2=; for p in $$list; do \ if test -f $$p; then \ list2="$$list2 $$p"; \ else :; fi; \ done; \ test -z "$$list2" || { \ echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \ echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \ $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \ } uninstall-libLTLIBRARIES: @$(NORMAL_UNINSTALL) @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ for p in $$list; do \ $(am__strip_dir) \ echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \ $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \ done clean-libLTLIBRARIES: -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES) @list='$(lib_LTLIBRARIES)'; \ locs=`for p in $$list; do echo $$p; done | \ sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ sort -u`; \ test -z "$$locs" || { \ echo rm -f $${locs}; \ rm -f $${locs}; \ } clean-noinstLTLIBRARIES: -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) @list='$(noinst_LTLIBRARIES)'; \ locs=`for p in $$list; do echo $$p; done | \ sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ sort -u`; \ test -z "$$locs" || { \ echo rm -f $${locs}; \ rm -f $${locs}; \ } libcmis-@LIBCMIS_API_VERSION@.la: $(libcmis_@LIBCMIS_API_VERSION@_la_OBJECTS) $(libcmis_@LIBCMIS_API_VERSION@_la_DEPENDENCIES) $(EXTRA_libcmis_@LIBCMIS_API_VERSION@_la_DEPENDENCIES) $(AM_V_CXXLD)$(libcmis_@LIBCMIS_API_VERSION@_la_LINK) -rpath $(libdir) $(libcmis_@LIBCMIS_API_VERSION@_la_OBJECTS) $(libcmis_@LIBCMIS_API_VERSION@_la_LIBADD) $(LIBS) libcmis.la: $(libcmis_la_OBJECTS) $(libcmis_la_DEPENDENCIES) $(EXTRA_libcmis_la_DEPENDENCIES) $(AM_V_CXXLD)$(CXXLINK) $(libcmis_la_OBJECTS) $(libcmis_la_LIBADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dummy.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-allowable-actions.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-atom-document.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-atom-folder.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-atom-object-type.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-atom-object.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-atom-session.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-atom-workspace.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-base-session.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-document.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-folder.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-gdrive-document.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-gdrive-folder.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-gdrive-object-type.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-gdrive-object.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-gdrive-property.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-gdrive-repository.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-gdrive-session.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-gdrive-utils.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-http-session.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-json-utils.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-oauth2-data.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-oauth2-handler.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-oauth2-providers.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-object-type.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-object.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-onedrive-document.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-onedrive-folder.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-onedrive-object-type.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-onedrive-object.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-onedrive-property.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-onedrive-repository.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-onedrive-session.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-onedrive-utils.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-property-type.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-property.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-rendition.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-repository.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-session-factory.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-sharepoint-document.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-sharepoint-folder.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-sharepoint-object-type.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-sharepoint-object.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-sharepoint-property.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-sharepoint-repository.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-sharepoint-session.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-sharepoint-utils.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-ws-document.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-ws-folder.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-ws-navigationservice.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-ws-object-type.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-ws-object.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-ws-objectservice.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-ws-relatedmultipart.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-ws-repositoryservice.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-ws-requests.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-ws-session.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-ws-soap.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-ws-versioningservice.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_la-xml-utils.Plo@am__quote@ # am--include-marker $(am__depfiles_remade): @$(MKDIR_P) $(@D) @echo '# dummy' >$@-t && $(am__mv) $@-t $@ am--depfiles: $(am__depfiles_remade) .cxx.o: @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $< .cxx.obj: @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .cxx.lo: @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LTCXXCOMPILE) -c -o $@ $< libcmis_la-allowable-actions.lo: allowable-actions.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-allowable-actions.lo -MD -MP -MF $(DEPDIR)/libcmis_la-allowable-actions.Tpo -c -o libcmis_la-allowable-actions.lo `test -f 'allowable-actions.cxx' || echo '$(srcdir)/'`allowable-actions.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-allowable-actions.Tpo $(DEPDIR)/libcmis_la-allowable-actions.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='allowable-actions.cxx' object='libcmis_la-allowable-actions.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-allowable-actions.lo `test -f 'allowable-actions.cxx' || echo '$(srcdir)/'`allowable-actions.cxx libcmis_la-atom-document.lo: atom-document.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-atom-document.lo -MD -MP -MF $(DEPDIR)/libcmis_la-atom-document.Tpo -c -o libcmis_la-atom-document.lo `test -f 'atom-document.cxx' || echo '$(srcdir)/'`atom-document.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-atom-document.Tpo $(DEPDIR)/libcmis_la-atom-document.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='atom-document.cxx' object='libcmis_la-atom-document.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-atom-document.lo `test -f 'atom-document.cxx' || echo '$(srcdir)/'`atom-document.cxx libcmis_la-atom-folder.lo: atom-folder.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-atom-folder.lo -MD -MP -MF $(DEPDIR)/libcmis_la-atom-folder.Tpo -c -o libcmis_la-atom-folder.lo `test -f 'atom-folder.cxx' || echo '$(srcdir)/'`atom-folder.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-atom-folder.Tpo $(DEPDIR)/libcmis_la-atom-folder.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='atom-folder.cxx' object='libcmis_la-atom-folder.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-atom-folder.lo `test -f 'atom-folder.cxx' || echo '$(srcdir)/'`atom-folder.cxx libcmis_la-atom-object-type.lo: atom-object-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-atom-object-type.lo -MD -MP -MF $(DEPDIR)/libcmis_la-atom-object-type.Tpo -c -o libcmis_la-atom-object-type.lo `test -f 'atom-object-type.cxx' || echo '$(srcdir)/'`atom-object-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-atom-object-type.Tpo $(DEPDIR)/libcmis_la-atom-object-type.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='atom-object-type.cxx' object='libcmis_la-atom-object-type.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-atom-object-type.lo `test -f 'atom-object-type.cxx' || echo '$(srcdir)/'`atom-object-type.cxx libcmis_la-atom-object.lo: atom-object.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-atom-object.lo -MD -MP -MF $(DEPDIR)/libcmis_la-atom-object.Tpo -c -o libcmis_la-atom-object.lo `test -f 'atom-object.cxx' || echo '$(srcdir)/'`atom-object.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-atom-object.Tpo $(DEPDIR)/libcmis_la-atom-object.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='atom-object.cxx' object='libcmis_la-atom-object.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-atom-object.lo `test -f 'atom-object.cxx' || echo '$(srcdir)/'`atom-object.cxx libcmis_la-atom-session.lo: atom-session.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-atom-session.lo -MD -MP -MF $(DEPDIR)/libcmis_la-atom-session.Tpo -c -o libcmis_la-atom-session.lo `test -f 'atom-session.cxx' || echo '$(srcdir)/'`atom-session.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-atom-session.Tpo $(DEPDIR)/libcmis_la-atom-session.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='atom-session.cxx' object='libcmis_la-atom-session.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-atom-session.lo `test -f 'atom-session.cxx' || echo '$(srcdir)/'`atom-session.cxx libcmis_la-atom-workspace.lo: atom-workspace.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-atom-workspace.lo -MD -MP -MF $(DEPDIR)/libcmis_la-atom-workspace.Tpo -c -o libcmis_la-atom-workspace.lo `test -f 'atom-workspace.cxx' || echo '$(srcdir)/'`atom-workspace.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-atom-workspace.Tpo $(DEPDIR)/libcmis_la-atom-workspace.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='atom-workspace.cxx' object='libcmis_la-atom-workspace.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-atom-workspace.lo `test -f 'atom-workspace.cxx' || echo '$(srcdir)/'`atom-workspace.cxx libcmis_la-base-session.lo: base-session.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-base-session.lo -MD -MP -MF $(DEPDIR)/libcmis_la-base-session.Tpo -c -o libcmis_la-base-session.lo `test -f 'base-session.cxx' || echo '$(srcdir)/'`base-session.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-base-session.Tpo $(DEPDIR)/libcmis_la-base-session.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='base-session.cxx' object='libcmis_la-base-session.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-base-session.lo `test -f 'base-session.cxx' || echo '$(srcdir)/'`base-session.cxx libcmis_la-document.lo: document.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-document.lo -MD -MP -MF $(DEPDIR)/libcmis_la-document.Tpo -c -o libcmis_la-document.lo `test -f 'document.cxx' || echo '$(srcdir)/'`document.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-document.Tpo $(DEPDIR)/libcmis_la-document.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='document.cxx' object='libcmis_la-document.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-document.lo `test -f 'document.cxx' || echo '$(srcdir)/'`document.cxx libcmis_la-folder.lo: folder.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-folder.lo -MD -MP -MF $(DEPDIR)/libcmis_la-folder.Tpo -c -o libcmis_la-folder.lo `test -f 'folder.cxx' || echo '$(srcdir)/'`folder.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-folder.Tpo $(DEPDIR)/libcmis_la-folder.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='folder.cxx' object='libcmis_la-folder.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-folder.lo `test -f 'folder.cxx' || echo '$(srcdir)/'`folder.cxx libcmis_la-gdrive-document.lo: gdrive-document.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-gdrive-document.lo -MD -MP -MF $(DEPDIR)/libcmis_la-gdrive-document.Tpo -c -o libcmis_la-gdrive-document.lo `test -f 'gdrive-document.cxx' || echo '$(srcdir)/'`gdrive-document.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-gdrive-document.Tpo $(DEPDIR)/libcmis_la-gdrive-document.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='gdrive-document.cxx' object='libcmis_la-gdrive-document.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-gdrive-document.lo `test -f 'gdrive-document.cxx' || echo '$(srcdir)/'`gdrive-document.cxx libcmis_la-gdrive-folder.lo: gdrive-folder.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-gdrive-folder.lo -MD -MP -MF $(DEPDIR)/libcmis_la-gdrive-folder.Tpo -c -o libcmis_la-gdrive-folder.lo `test -f 'gdrive-folder.cxx' || echo '$(srcdir)/'`gdrive-folder.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-gdrive-folder.Tpo $(DEPDIR)/libcmis_la-gdrive-folder.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='gdrive-folder.cxx' object='libcmis_la-gdrive-folder.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-gdrive-folder.lo `test -f 'gdrive-folder.cxx' || echo '$(srcdir)/'`gdrive-folder.cxx libcmis_la-gdrive-object-type.lo: gdrive-object-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-gdrive-object-type.lo -MD -MP -MF $(DEPDIR)/libcmis_la-gdrive-object-type.Tpo -c -o libcmis_la-gdrive-object-type.lo `test -f 'gdrive-object-type.cxx' || echo '$(srcdir)/'`gdrive-object-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-gdrive-object-type.Tpo $(DEPDIR)/libcmis_la-gdrive-object-type.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='gdrive-object-type.cxx' object='libcmis_la-gdrive-object-type.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-gdrive-object-type.lo `test -f 'gdrive-object-type.cxx' || echo '$(srcdir)/'`gdrive-object-type.cxx libcmis_la-gdrive-object.lo: gdrive-object.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-gdrive-object.lo -MD -MP -MF $(DEPDIR)/libcmis_la-gdrive-object.Tpo -c -o libcmis_la-gdrive-object.lo `test -f 'gdrive-object.cxx' || echo '$(srcdir)/'`gdrive-object.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-gdrive-object.Tpo $(DEPDIR)/libcmis_la-gdrive-object.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='gdrive-object.cxx' object='libcmis_la-gdrive-object.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-gdrive-object.lo `test -f 'gdrive-object.cxx' || echo '$(srcdir)/'`gdrive-object.cxx libcmis_la-gdrive-property.lo: gdrive-property.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-gdrive-property.lo -MD -MP -MF $(DEPDIR)/libcmis_la-gdrive-property.Tpo -c -o libcmis_la-gdrive-property.lo `test -f 'gdrive-property.cxx' || echo '$(srcdir)/'`gdrive-property.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-gdrive-property.Tpo $(DEPDIR)/libcmis_la-gdrive-property.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='gdrive-property.cxx' object='libcmis_la-gdrive-property.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-gdrive-property.lo `test -f 'gdrive-property.cxx' || echo '$(srcdir)/'`gdrive-property.cxx libcmis_la-gdrive-repository.lo: gdrive-repository.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-gdrive-repository.lo -MD -MP -MF $(DEPDIR)/libcmis_la-gdrive-repository.Tpo -c -o libcmis_la-gdrive-repository.lo `test -f 'gdrive-repository.cxx' || echo '$(srcdir)/'`gdrive-repository.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-gdrive-repository.Tpo $(DEPDIR)/libcmis_la-gdrive-repository.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='gdrive-repository.cxx' object='libcmis_la-gdrive-repository.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-gdrive-repository.lo `test -f 'gdrive-repository.cxx' || echo '$(srcdir)/'`gdrive-repository.cxx libcmis_la-gdrive-session.lo: gdrive-session.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-gdrive-session.lo -MD -MP -MF $(DEPDIR)/libcmis_la-gdrive-session.Tpo -c -o libcmis_la-gdrive-session.lo `test -f 'gdrive-session.cxx' || echo '$(srcdir)/'`gdrive-session.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-gdrive-session.Tpo $(DEPDIR)/libcmis_la-gdrive-session.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='gdrive-session.cxx' object='libcmis_la-gdrive-session.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-gdrive-session.lo `test -f 'gdrive-session.cxx' || echo '$(srcdir)/'`gdrive-session.cxx libcmis_la-gdrive-utils.lo: gdrive-utils.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-gdrive-utils.lo -MD -MP -MF $(DEPDIR)/libcmis_la-gdrive-utils.Tpo -c -o libcmis_la-gdrive-utils.lo `test -f 'gdrive-utils.cxx' || echo '$(srcdir)/'`gdrive-utils.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-gdrive-utils.Tpo $(DEPDIR)/libcmis_la-gdrive-utils.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='gdrive-utils.cxx' object='libcmis_la-gdrive-utils.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-gdrive-utils.lo `test -f 'gdrive-utils.cxx' || echo '$(srcdir)/'`gdrive-utils.cxx libcmis_la-http-session.lo: http-session.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-http-session.lo -MD -MP -MF $(DEPDIR)/libcmis_la-http-session.Tpo -c -o libcmis_la-http-session.lo `test -f 'http-session.cxx' || echo '$(srcdir)/'`http-session.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-http-session.Tpo $(DEPDIR)/libcmis_la-http-session.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='http-session.cxx' object='libcmis_la-http-session.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-http-session.lo `test -f 'http-session.cxx' || echo '$(srcdir)/'`http-session.cxx libcmis_la-json-utils.lo: json-utils.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-json-utils.lo -MD -MP -MF $(DEPDIR)/libcmis_la-json-utils.Tpo -c -o libcmis_la-json-utils.lo `test -f 'json-utils.cxx' || echo '$(srcdir)/'`json-utils.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-json-utils.Tpo $(DEPDIR)/libcmis_la-json-utils.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='json-utils.cxx' object='libcmis_la-json-utils.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-json-utils.lo `test -f 'json-utils.cxx' || echo '$(srcdir)/'`json-utils.cxx libcmis_la-oauth2-data.lo: oauth2-data.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-oauth2-data.lo -MD -MP -MF $(DEPDIR)/libcmis_la-oauth2-data.Tpo -c -o libcmis_la-oauth2-data.lo `test -f 'oauth2-data.cxx' || echo '$(srcdir)/'`oauth2-data.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-oauth2-data.Tpo $(DEPDIR)/libcmis_la-oauth2-data.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='oauth2-data.cxx' object='libcmis_la-oauth2-data.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-oauth2-data.lo `test -f 'oauth2-data.cxx' || echo '$(srcdir)/'`oauth2-data.cxx libcmis_la-oauth2-handler.lo: oauth2-handler.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-oauth2-handler.lo -MD -MP -MF $(DEPDIR)/libcmis_la-oauth2-handler.Tpo -c -o libcmis_la-oauth2-handler.lo `test -f 'oauth2-handler.cxx' || echo '$(srcdir)/'`oauth2-handler.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-oauth2-handler.Tpo $(DEPDIR)/libcmis_la-oauth2-handler.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='oauth2-handler.cxx' object='libcmis_la-oauth2-handler.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-oauth2-handler.lo `test -f 'oauth2-handler.cxx' || echo '$(srcdir)/'`oauth2-handler.cxx libcmis_la-oauth2-providers.lo: oauth2-providers.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-oauth2-providers.lo -MD -MP -MF $(DEPDIR)/libcmis_la-oauth2-providers.Tpo -c -o libcmis_la-oauth2-providers.lo `test -f 'oauth2-providers.cxx' || echo '$(srcdir)/'`oauth2-providers.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-oauth2-providers.Tpo $(DEPDIR)/libcmis_la-oauth2-providers.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='oauth2-providers.cxx' object='libcmis_la-oauth2-providers.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-oauth2-providers.lo `test -f 'oauth2-providers.cxx' || echo '$(srcdir)/'`oauth2-providers.cxx libcmis_la-object-type.lo: object-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-object-type.lo -MD -MP -MF $(DEPDIR)/libcmis_la-object-type.Tpo -c -o libcmis_la-object-type.lo `test -f 'object-type.cxx' || echo '$(srcdir)/'`object-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-object-type.Tpo $(DEPDIR)/libcmis_la-object-type.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='object-type.cxx' object='libcmis_la-object-type.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-object-type.lo `test -f 'object-type.cxx' || echo '$(srcdir)/'`object-type.cxx libcmis_la-object.lo: object.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-object.lo -MD -MP -MF $(DEPDIR)/libcmis_la-object.Tpo -c -o libcmis_la-object.lo `test -f 'object.cxx' || echo '$(srcdir)/'`object.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-object.Tpo $(DEPDIR)/libcmis_la-object.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='object.cxx' object='libcmis_la-object.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-object.lo `test -f 'object.cxx' || echo '$(srcdir)/'`object.cxx libcmis_la-onedrive-document.lo: onedrive-document.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-onedrive-document.lo -MD -MP -MF $(DEPDIR)/libcmis_la-onedrive-document.Tpo -c -o libcmis_la-onedrive-document.lo `test -f 'onedrive-document.cxx' || echo '$(srcdir)/'`onedrive-document.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-onedrive-document.Tpo $(DEPDIR)/libcmis_la-onedrive-document.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='onedrive-document.cxx' object='libcmis_la-onedrive-document.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-onedrive-document.lo `test -f 'onedrive-document.cxx' || echo '$(srcdir)/'`onedrive-document.cxx libcmis_la-onedrive-folder.lo: onedrive-folder.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-onedrive-folder.lo -MD -MP -MF $(DEPDIR)/libcmis_la-onedrive-folder.Tpo -c -o libcmis_la-onedrive-folder.lo `test -f 'onedrive-folder.cxx' || echo '$(srcdir)/'`onedrive-folder.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-onedrive-folder.Tpo $(DEPDIR)/libcmis_la-onedrive-folder.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='onedrive-folder.cxx' object='libcmis_la-onedrive-folder.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-onedrive-folder.lo `test -f 'onedrive-folder.cxx' || echo '$(srcdir)/'`onedrive-folder.cxx libcmis_la-onedrive-object-type.lo: onedrive-object-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-onedrive-object-type.lo -MD -MP -MF $(DEPDIR)/libcmis_la-onedrive-object-type.Tpo -c -o libcmis_la-onedrive-object-type.lo `test -f 'onedrive-object-type.cxx' || echo '$(srcdir)/'`onedrive-object-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-onedrive-object-type.Tpo $(DEPDIR)/libcmis_la-onedrive-object-type.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='onedrive-object-type.cxx' object='libcmis_la-onedrive-object-type.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-onedrive-object-type.lo `test -f 'onedrive-object-type.cxx' || echo '$(srcdir)/'`onedrive-object-type.cxx libcmis_la-onedrive-object.lo: onedrive-object.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-onedrive-object.lo -MD -MP -MF $(DEPDIR)/libcmis_la-onedrive-object.Tpo -c -o libcmis_la-onedrive-object.lo `test -f 'onedrive-object.cxx' || echo '$(srcdir)/'`onedrive-object.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-onedrive-object.Tpo $(DEPDIR)/libcmis_la-onedrive-object.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='onedrive-object.cxx' object='libcmis_la-onedrive-object.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-onedrive-object.lo `test -f 'onedrive-object.cxx' || echo '$(srcdir)/'`onedrive-object.cxx libcmis_la-onedrive-property.lo: onedrive-property.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-onedrive-property.lo -MD -MP -MF $(DEPDIR)/libcmis_la-onedrive-property.Tpo -c -o libcmis_la-onedrive-property.lo `test -f 'onedrive-property.cxx' || echo '$(srcdir)/'`onedrive-property.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-onedrive-property.Tpo $(DEPDIR)/libcmis_la-onedrive-property.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='onedrive-property.cxx' object='libcmis_la-onedrive-property.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-onedrive-property.lo `test -f 'onedrive-property.cxx' || echo '$(srcdir)/'`onedrive-property.cxx libcmis_la-onedrive-repository.lo: onedrive-repository.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-onedrive-repository.lo -MD -MP -MF $(DEPDIR)/libcmis_la-onedrive-repository.Tpo -c -o libcmis_la-onedrive-repository.lo `test -f 'onedrive-repository.cxx' || echo '$(srcdir)/'`onedrive-repository.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-onedrive-repository.Tpo $(DEPDIR)/libcmis_la-onedrive-repository.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='onedrive-repository.cxx' object='libcmis_la-onedrive-repository.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-onedrive-repository.lo `test -f 'onedrive-repository.cxx' || echo '$(srcdir)/'`onedrive-repository.cxx libcmis_la-onedrive-session.lo: onedrive-session.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-onedrive-session.lo -MD -MP -MF $(DEPDIR)/libcmis_la-onedrive-session.Tpo -c -o libcmis_la-onedrive-session.lo `test -f 'onedrive-session.cxx' || echo '$(srcdir)/'`onedrive-session.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-onedrive-session.Tpo $(DEPDIR)/libcmis_la-onedrive-session.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='onedrive-session.cxx' object='libcmis_la-onedrive-session.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-onedrive-session.lo `test -f 'onedrive-session.cxx' || echo '$(srcdir)/'`onedrive-session.cxx libcmis_la-onedrive-utils.lo: onedrive-utils.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-onedrive-utils.lo -MD -MP -MF $(DEPDIR)/libcmis_la-onedrive-utils.Tpo -c -o libcmis_la-onedrive-utils.lo `test -f 'onedrive-utils.cxx' || echo '$(srcdir)/'`onedrive-utils.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-onedrive-utils.Tpo $(DEPDIR)/libcmis_la-onedrive-utils.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='onedrive-utils.cxx' object='libcmis_la-onedrive-utils.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-onedrive-utils.lo `test -f 'onedrive-utils.cxx' || echo '$(srcdir)/'`onedrive-utils.cxx libcmis_la-property-type.lo: property-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-property-type.lo -MD -MP -MF $(DEPDIR)/libcmis_la-property-type.Tpo -c -o libcmis_la-property-type.lo `test -f 'property-type.cxx' || echo '$(srcdir)/'`property-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-property-type.Tpo $(DEPDIR)/libcmis_la-property-type.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='property-type.cxx' object='libcmis_la-property-type.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-property-type.lo `test -f 'property-type.cxx' || echo '$(srcdir)/'`property-type.cxx libcmis_la-property.lo: property.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-property.lo -MD -MP -MF $(DEPDIR)/libcmis_la-property.Tpo -c -o libcmis_la-property.lo `test -f 'property.cxx' || echo '$(srcdir)/'`property.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-property.Tpo $(DEPDIR)/libcmis_la-property.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='property.cxx' object='libcmis_la-property.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-property.lo `test -f 'property.cxx' || echo '$(srcdir)/'`property.cxx libcmis_la-rendition.lo: rendition.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-rendition.lo -MD -MP -MF $(DEPDIR)/libcmis_la-rendition.Tpo -c -o libcmis_la-rendition.lo `test -f 'rendition.cxx' || echo '$(srcdir)/'`rendition.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-rendition.Tpo $(DEPDIR)/libcmis_la-rendition.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='rendition.cxx' object='libcmis_la-rendition.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-rendition.lo `test -f 'rendition.cxx' || echo '$(srcdir)/'`rendition.cxx libcmis_la-repository.lo: repository.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-repository.lo -MD -MP -MF $(DEPDIR)/libcmis_la-repository.Tpo -c -o libcmis_la-repository.lo `test -f 'repository.cxx' || echo '$(srcdir)/'`repository.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-repository.Tpo $(DEPDIR)/libcmis_la-repository.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='repository.cxx' object='libcmis_la-repository.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-repository.lo `test -f 'repository.cxx' || echo '$(srcdir)/'`repository.cxx libcmis_la-session-factory.lo: session-factory.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-session-factory.lo -MD -MP -MF $(DEPDIR)/libcmis_la-session-factory.Tpo -c -o libcmis_la-session-factory.lo `test -f 'session-factory.cxx' || echo '$(srcdir)/'`session-factory.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-session-factory.Tpo $(DEPDIR)/libcmis_la-session-factory.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='session-factory.cxx' object='libcmis_la-session-factory.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-session-factory.lo `test -f 'session-factory.cxx' || echo '$(srcdir)/'`session-factory.cxx libcmis_la-sharepoint-document.lo: sharepoint-document.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-sharepoint-document.lo -MD -MP -MF $(DEPDIR)/libcmis_la-sharepoint-document.Tpo -c -o libcmis_la-sharepoint-document.lo `test -f 'sharepoint-document.cxx' || echo '$(srcdir)/'`sharepoint-document.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-sharepoint-document.Tpo $(DEPDIR)/libcmis_la-sharepoint-document.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='sharepoint-document.cxx' object='libcmis_la-sharepoint-document.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-sharepoint-document.lo `test -f 'sharepoint-document.cxx' || echo '$(srcdir)/'`sharepoint-document.cxx libcmis_la-sharepoint-folder.lo: sharepoint-folder.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-sharepoint-folder.lo -MD -MP -MF $(DEPDIR)/libcmis_la-sharepoint-folder.Tpo -c -o libcmis_la-sharepoint-folder.lo `test -f 'sharepoint-folder.cxx' || echo '$(srcdir)/'`sharepoint-folder.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-sharepoint-folder.Tpo $(DEPDIR)/libcmis_la-sharepoint-folder.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='sharepoint-folder.cxx' object='libcmis_la-sharepoint-folder.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-sharepoint-folder.lo `test -f 'sharepoint-folder.cxx' || echo '$(srcdir)/'`sharepoint-folder.cxx libcmis_la-sharepoint-object-type.lo: sharepoint-object-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-sharepoint-object-type.lo -MD -MP -MF $(DEPDIR)/libcmis_la-sharepoint-object-type.Tpo -c -o libcmis_la-sharepoint-object-type.lo `test -f 'sharepoint-object-type.cxx' || echo '$(srcdir)/'`sharepoint-object-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-sharepoint-object-type.Tpo $(DEPDIR)/libcmis_la-sharepoint-object-type.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='sharepoint-object-type.cxx' object='libcmis_la-sharepoint-object-type.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-sharepoint-object-type.lo `test -f 'sharepoint-object-type.cxx' || echo '$(srcdir)/'`sharepoint-object-type.cxx libcmis_la-sharepoint-object.lo: sharepoint-object.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-sharepoint-object.lo -MD -MP -MF $(DEPDIR)/libcmis_la-sharepoint-object.Tpo -c -o libcmis_la-sharepoint-object.lo `test -f 'sharepoint-object.cxx' || echo '$(srcdir)/'`sharepoint-object.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-sharepoint-object.Tpo $(DEPDIR)/libcmis_la-sharepoint-object.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='sharepoint-object.cxx' object='libcmis_la-sharepoint-object.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-sharepoint-object.lo `test -f 'sharepoint-object.cxx' || echo '$(srcdir)/'`sharepoint-object.cxx libcmis_la-sharepoint-property.lo: sharepoint-property.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-sharepoint-property.lo -MD -MP -MF $(DEPDIR)/libcmis_la-sharepoint-property.Tpo -c -o libcmis_la-sharepoint-property.lo `test -f 'sharepoint-property.cxx' || echo '$(srcdir)/'`sharepoint-property.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-sharepoint-property.Tpo $(DEPDIR)/libcmis_la-sharepoint-property.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='sharepoint-property.cxx' object='libcmis_la-sharepoint-property.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-sharepoint-property.lo `test -f 'sharepoint-property.cxx' || echo '$(srcdir)/'`sharepoint-property.cxx libcmis_la-sharepoint-repository.lo: sharepoint-repository.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-sharepoint-repository.lo -MD -MP -MF $(DEPDIR)/libcmis_la-sharepoint-repository.Tpo -c -o libcmis_la-sharepoint-repository.lo `test -f 'sharepoint-repository.cxx' || echo '$(srcdir)/'`sharepoint-repository.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-sharepoint-repository.Tpo $(DEPDIR)/libcmis_la-sharepoint-repository.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='sharepoint-repository.cxx' object='libcmis_la-sharepoint-repository.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-sharepoint-repository.lo `test -f 'sharepoint-repository.cxx' || echo '$(srcdir)/'`sharepoint-repository.cxx libcmis_la-sharepoint-session.lo: sharepoint-session.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-sharepoint-session.lo -MD -MP -MF $(DEPDIR)/libcmis_la-sharepoint-session.Tpo -c -o libcmis_la-sharepoint-session.lo `test -f 'sharepoint-session.cxx' || echo '$(srcdir)/'`sharepoint-session.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-sharepoint-session.Tpo $(DEPDIR)/libcmis_la-sharepoint-session.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='sharepoint-session.cxx' object='libcmis_la-sharepoint-session.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-sharepoint-session.lo `test -f 'sharepoint-session.cxx' || echo '$(srcdir)/'`sharepoint-session.cxx libcmis_la-sharepoint-utils.lo: sharepoint-utils.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-sharepoint-utils.lo -MD -MP -MF $(DEPDIR)/libcmis_la-sharepoint-utils.Tpo -c -o libcmis_la-sharepoint-utils.lo `test -f 'sharepoint-utils.cxx' || echo '$(srcdir)/'`sharepoint-utils.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-sharepoint-utils.Tpo $(DEPDIR)/libcmis_la-sharepoint-utils.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='sharepoint-utils.cxx' object='libcmis_la-sharepoint-utils.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-sharepoint-utils.lo `test -f 'sharepoint-utils.cxx' || echo '$(srcdir)/'`sharepoint-utils.cxx libcmis_la-ws-document.lo: ws-document.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-ws-document.lo -MD -MP -MF $(DEPDIR)/libcmis_la-ws-document.Tpo -c -o libcmis_la-ws-document.lo `test -f 'ws-document.cxx' || echo '$(srcdir)/'`ws-document.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-ws-document.Tpo $(DEPDIR)/libcmis_la-ws-document.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='ws-document.cxx' object='libcmis_la-ws-document.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-ws-document.lo `test -f 'ws-document.cxx' || echo '$(srcdir)/'`ws-document.cxx libcmis_la-ws-folder.lo: ws-folder.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-ws-folder.lo -MD -MP -MF $(DEPDIR)/libcmis_la-ws-folder.Tpo -c -o libcmis_la-ws-folder.lo `test -f 'ws-folder.cxx' || echo '$(srcdir)/'`ws-folder.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-ws-folder.Tpo $(DEPDIR)/libcmis_la-ws-folder.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='ws-folder.cxx' object='libcmis_la-ws-folder.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-ws-folder.lo `test -f 'ws-folder.cxx' || echo '$(srcdir)/'`ws-folder.cxx libcmis_la-ws-navigationservice.lo: ws-navigationservice.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-ws-navigationservice.lo -MD -MP -MF $(DEPDIR)/libcmis_la-ws-navigationservice.Tpo -c -o libcmis_la-ws-navigationservice.lo `test -f 'ws-navigationservice.cxx' || echo '$(srcdir)/'`ws-navigationservice.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-ws-navigationservice.Tpo $(DEPDIR)/libcmis_la-ws-navigationservice.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='ws-navigationservice.cxx' object='libcmis_la-ws-navigationservice.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-ws-navigationservice.lo `test -f 'ws-navigationservice.cxx' || echo '$(srcdir)/'`ws-navigationservice.cxx libcmis_la-ws-object-type.lo: ws-object-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-ws-object-type.lo -MD -MP -MF $(DEPDIR)/libcmis_la-ws-object-type.Tpo -c -o libcmis_la-ws-object-type.lo `test -f 'ws-object-type.cxx' || echo '$(srcdir)/'`ws-object-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-ws-object-type.Tpo $(DEPDIR)/libcmis_la-ws-object-type.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='ws-object-type.cxx' object='libcmis_la-ws-object-type.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-ws-object-type.lo `test -f 'ws-object-type.cxx' || echo '$(srcdir)/'`ws-object-type.cxx libcmis_la-ws-object.lo: ws-object.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-ws-object.lo -MD -MP -MF $(DEPDIR)/libcmis_la-ws-object.Tpo -c -o libcmis_la-ws-object.lo `test -f 'ws-object.cxx' || echo '$(srcdir)/'`ws-object.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-ws-object.Tpo $(DEPDIR)/libcmis_la-ws-object.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='ws-object.cxx' object='libcmis_la-ws-object.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-ws-object.lo `test -f 'ws-object.cxx' || echo '$(srcdir)/'`ws-object.cxx libcmis_la-ws-objectservice.lo: ws-objectservice.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-ws-objectservice.lo -MD -MP -MF $(DEPDIR)/libcmis_la-ws-objectservice.Tpo -c -o libcmis_la-ws-objectservice.lo `test -f 'ws-objectservice.cxx' || echo '$(srcdir)/'`ws-objectservice.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-ws-objectservice.Tpo $(DEPDIR)/libcmis_la-ws-objectservice.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='ws-objectservice.cxx' object='libcmis_la-ws-objectservice.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-ws-objectservice.lo `test -f 'ws-objectservice.cxx' || echo '$(srcdir)/'`ws-objectservice.cxx libcmis_la-ws-relatedmultipart.lo: ws-relatedmultipart.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-ws-relatedmultipart.lo -MD -MP -MF $(DEPDIR)/libcmis_la-ws-relatedmultipart.Tpo -c -o libcmis_la-ws-relatedmultipart.lo `test -f 'ws-relatedmultipart.cxx' || echo '$(srcdir)/'`ws-relatedmultipart.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-ws-relatedmultipart.Tpo $(DEPDIR)/libcmis_la-ws-relatedmultipart.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='ws-relatedmultipart.cxx' object='libcmis_la-ws-relatedmultipart.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-ws-relatedmultipart.lo `test -f 'ws-relatedmultipart.cxx' || echo '$(srcdir)/'`ws-relatedmultipart.cxx libcmis_la-ws-repositoryservice.lo: ws-repositoryservice.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-ws-repositoryservice.lo -MD -MP -MF $(DEPDIR)/libcmis_la-ws-repositoryservice.Tpo -c -o libcmis_la-ws-repositoryservice.lo `test -f 'ws-repositoryservice.cxx' || echo '$(srcdir)/'`ws-repositoryservice.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-ws-repositoryservice.Tpo $(DEPDIR)/libcmis_la-ws-repositoryservice.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='ws-repositoryservice.cxx' object='libcmis_la-ws-repositoryservice.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-ws-repositoryservice.lo `test -f 'ws-repositoryservice.cxx' || echo '$(srcdir)/'`ws-repositoryservice.cxx libcmis_la-ws-requests.lo: ws-requests.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-ws-requests.lo -MD -MP -MF $(DEPDIR)/libcmis_la-ws-requests.Tpo -c -o libcmis_la-ws-requests.lo `test -f 'ws-requests.cxx' || echo '$(srcdir)/'`ws-requests.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-ws-requests.Tpo $(DEPDIR)/libcmis_la-ws-requests.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='ws-requests.cxx' object='libcmis_la-ws-requests.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-ws-requests.lo `test -f 'ws-requests.cxx' || echo '$(srcdir)/'`ws-requests.cxx libcmis_la-ws-session.lo: ws-session.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-ws-session.lo -MD -MP -MF $(DEPDIR)/libcmis_la-ws-session.Tpo -c -o libcmis_la-ws-session.lo `test -f 'ws-session.cxx' || echo '$(srcdir)/'`ws-session.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-ws-session.Tpo $(DEPDIR)/libcmis_la-ws-session.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='ws-session.cxx' object='libcmis_la-ws-session.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-ws-session.lo `test -f 'ws-session.cxx' || echo '$(srcdir)/'`ws-session.cxx libcmis_la-ws-soap.lo: ws-soap.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-ws-soap.lo -MD -MP -MF $(DEPDIR)/libcmis_la-ws-soap.Tpo -c -o libcmis_la-ws-soap.lo `test -f 'ws-soap.cxx' || echo '$(srcdir)/'`ws-soap.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-ws-soap.Tpo $(DEPDIR)/libcmis_la-ws-soap.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='ws-soap.cxx' object='libcmis_la-ws-soap.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-ws-soap.lo `test -f 'ws-soap.cxx' || echo '$(srcdir)/'`ws-soap.cxx libcmis_la-ws-versioningservice.lo: ws-versioningservice.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-ws-versioningservice.lo -MD -MP -MF $(DEPDIR)/libcmis_la-ws-versioningservice.Tpo -c -o libcmis_la-ws-versioningservice.lo `test -f 'ws-versioningservice.cxx' || echo '$(srcdir)/'`ws-versioningservice.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-ws-versioningservice.Tpo $(DEPDIR)/libcmis_la-ws-versioningservice.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='ws-versioningservice.cxx' object='libcmis_la-ws-versioningservice.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-ws-versioningservice.lo `test -f 'ws-versioningservice.cxx' || echo '$(srcdir)/'`ws-versioningservice.cxx libcmis_la-xml-utils.lo: xml-utils.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libcmis_la-xml-utils.lo -MD -MP -MF $(DEPDIR)/libcmis_la-xml-utils.Tpo -c -o libcmis_la-xml-utils.lo `test -f 'xml-utils.cxx' || echo '$(srcdir)/'`xml-utils.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_la-xml-utils.Tpo $(DEPDIR)/libcmis_la-xml-utils.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='xml-utils.cxx' object='libcmis_la-xml-utils.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_la_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_la-xml-utils.lo `test -f 'xml-utils.cxx' || echo '$(srcdir)/'`xml-utils.cxx mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique tags: tags-am TAGS: tags tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ if test $$# -gt 0; then \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ "$$@" $$unique; \ else \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$unique; \ fi; \ fi ctags: ctags-am CTAGS: ctags ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" cscopelist: cscopelist-am cscopelist-am: $(am__tagged_files) list='$(am__tagged_files)'; \ case "$(srcdir)" in \ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ *) sdir=$(subdir)/$(srcdir) ;; \ esac; \ for i in $$list; do \ if test -f "$$i"; then \ echo "$(subdir)/$$i"; \ else \ echo "$$sdir/$$i"; \ fi; \ done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(LTLIBRARIES) installdirs: for dir in "$(DESTDIR)$(libdir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \ clean-noinstLTLIBRARIES mostlyclean-am distclean: distclean-am -rm -f ./$(DEPDIR)/dummy.Plo -rm -f ./$(DEPDIR)/libcmis_la-allowable-actions.Plo -rm -f ./$(DEPDIR)/libcmis_la-atom-document.Plo -rm -f ./$(DEPDIR)/libcmis_la-atom-folder.Plo -rm -f ./$(DEPDIR)/libcmis_la-atom-object-type.Plo -rm -f ./$(DEPDIR)/libcmis_la-atom-object.Plo -rm -f ./$(DEPDIR)/libcmis_la-atom-session.Plo -rm -f ./$(DEPDIR)/libcmis_la-atom-workspace.Plo -rm -f ./$(DEPDIR)/libcmis_la-base-session.Plo -rm -f ./$(DEPDIR)/libcmis_la-document.Plo -rm -f ./$(DEPDIR)/libcmis_la-folder.Plo -rm -f ./$(DEPDIR)/libcmis_la-gdrive-document.Plo -rm -f ./$(DEPDIR)/libcmis_la-gdrive-folder.Plo -rm -f ./$(DEPDIR)/libcmis_la-gdrive-object-type.Plo -rm -f ./$(DEPDIR)/libcmis_la-gdrive-object.Plo -rm -f ./$(DEPDIR)/libcmis_la-gdrive-property.Plo -rm -f ./$(DEPDIR)/libcmis_la-gdrive-repository.Plo -rm -f ./$(DEPDIR)/libcmis_la-gdrive-session.Plo -rm -f ./$(DEPDIR)/libcmis_la-gdrive-utils.Plo -rm -f ./$(DEPDIR)/libcmis_la-http-session.Plo -rm -f ./$(DEPDIR)/libcmis_la-json-utils.Plo -rm -f ./$(DEPDIR)/libcmis_la-oauth2-data.Plo -rm -f ./$(DEPDIR)/libcmis_la-oauth2-handler.Plo -rm -f ./$(DEPDIR)/libcmis_la-oauth2-providers.Plo -rm -f ./$(DEPDIR)/libcmis_la-object-type.Plo -rm -f ./$(DEPDIR)/libcmis_la-object.Plo -rm -f ./$(DEPDIR)/libcmis_la-onedrive-document.Plo -rm -f ./$(DEPDIR)/libcmis_la-onedrive-folder.Plo -rm -f ./$(DEPDIR)/libcmis_la-onedrive-object-type.Plo -rm -f ./$(DEPDIR)/libcmis_la-onedrive-object.Plo -rm -f ./$(DEPDIR)/libcmis_la-onedrive-property.Plo -rm -f ./$(DEPDIR)/libcmis_la-onedrive-repository.Plo -rm -f ./$(DEPDIR)/libcmis_la-onedrive-session.Plo -rm -f ./$(DEPDIR)/libcmis_la-onedrive-utils.Plo -rm -f ./$(DEPDIR)/libcmis_la-property-type.Plo -rm -f ./$(DEPDIR)/libcmis_la-property.Plo -rm -f ./$(DEPDIR)/libcmis_la-rendition.Plo -rm -f ./$(DEPDIR)/libcmis_la-repository.Plo -rm -f ./$(DEPDIR)/libcmis_la-session-factory.Plo -rm -f ./$(DEPDIR)/libcmis_la-sharepoint-document.Plo -rm -f ./$(DEPDIR)/libcmis_la-sharepoint-folder.Plo -rm -f ./$(DEPDIR)/libcmis_la-sharepoint-object-type.Plo -rm -f ./$(DEPDIR)/libcmis_la-sharepoint-object.Plo -rm -f ./$(DEPDIR)/libcmis_la-sharepoint-property.Plo -rm -f ./$(DEPDIR)/libcmis_la-sharepoint-repository.Plo -rm -f ./$(DEPDIR)/libcmis_la-sharepoint-session.Plo -rm -f ./$(DEPDIR)/libcmis_la-sharepoint-utils.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-document.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-folder.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-navigationservice.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-object-type.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-object.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-objectservice.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-relatedmultipart.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-repositoryservice.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-requests.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-session.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-soap.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-versioningservice.Plo -rm -f ./$(DEPDIR)/libcmis_la-xml-utils.Plo -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-tags dvi: dvi-am dvi-am: html: html-am html-am: info: info-am info-am: install-data-am: install-dvi: install-dvi-am install-dvi-am: install-exec-am: install-libLTLIBRARIES install-html: install-html-am install-html-am: install-info: install-info-am install-info-am: install-man: install-pdf: install-pdf-am install-pdf-am: install-ps: install-ps-am install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am -rm -f ./$(DEPDIR)/dummy.Plo -rm -f ./$(DEPDIR)/libcmis_la-allowable-actions.Plo -rm -f ./$(DEPDIR)/libcmis_la-atom-document.Plo -rm -f ./$(DEPDIR)/libcmis_la-atom-folder.Plo -rm -f ./$(DEPDIR)/libcmis_la-atom-object-type.Plo -rm -f ./$(DEPDIR)/libcmis_la-atom-object.Plo -rm -f ./$(DEPDIR)/libcmis_la-atom-session.Plo -rm -f ./$(DEPDIR)/libcmis_la-atom-workspace.Plo -rm -f ./$(DEPDIR)/libcmis_la-base-session.Plo -rm -f ./$(DEPDIR)/libcmis_la-document.Plo -rm -f ./$(DEPDIR)/libcmis_la-folder.Plo -rm -f ./$(DEPDIR)/libcmis_la-gdrive-document.Plo -rm -f ./$(DEPDIR)/libcmis_la-gdrive-folder.Plo -rm -f ./$(DEPDIR)/libcmis_la-gdrive-object-type.Plo -rm -f ./$(DEPDIR)/libcmis_la-gdrive-object.Plo -rm -f ./$(DEPDIR)/libcmis_la-gdrive-property.Plo -rm -f ./$(DEPDIR)/libcmis_la-gdrive-repository.Plo -rm -f ./$(DEPDIR)/libcmis_la-gdrive-session.Plo -rm -f ./$(DEPDIR)/libcmis_la-gdrive-utils.Plo -rm -f ./$(DEPDIR)/libcmis_la-http-session.Plo -rm -f ./$(DEPDIR)/libcmis_la-json-utils.Plo -rm -f ./$(DEPDIR)/libcmis_la-oauth2-data.Plo -rm -f ./$(DEPDIR)/libcmis_la-oauth2-handler.Plo -rm -f ./$(DEPDIR)/libcmis_la-oauth2-providers.Plo -rm -f ./$(DEPDIR)/libcmis_la-object-type.Plo -rm -f ./$(DEPDIR)/libcmis_la-object.Plo -rm -f ./$(DEPDIR)/libcmis_la-onedrive-document.Plo -rm -f ./$(DEPDIR)/libcmis_la-onedrive-folder.Plo -rm -f ./$(DEPDIR)/libcmis_la-onedrive-object-type.Plo -rm -f ./$(DEPDIR)/libcmis_la-onedrive-object.Plo -rm -f ./$(DEPDIR)/libcmis_la-onedrive-property.Plo -rm -f ./$(DEPDIR)/libcmis_la-onedrive-repository.Plo -rm -f ./$(DEPDIR)/libcmis_la-onedrive-session.Plo -rm -f ./$(DEPDIR)/libcmis_la-onedrive-utils.Plo -rm -f ./$(DEPDIR)/libcmis_la-property-type.Plo -rm -f ./$(DEPDIR)/libcmis_la-property.Plo -rm -f ./$(DEPDIR)/libcmis_la-rendition.Plo -rm -f ./$(DEPDIR)/libcmis_la-repository.Plo -rm -f ./$(DEPDIR)/libcmis_la-session-factory.Plo -rm -f ./$(DEPDIR)/libcmis_la-sharepoint-document.Plo -rm -f ./$(DEPDIR)/libcmis_la-sharepoint-folder.Plo -rm -f ./$(DEPDIR)/libcmis_la-sharepoint-object-type.Plo -rm -f ./$(DEPDIR)/libcmis_la-sharepoint-object.Plo -rm -f ./$(DEPDIR)/libcmis_la-sharepoint-property.Plo -rm -f ./$(DEPDIR)/libcmis_la-sharepoint-repository.Plo -rm -f ./$(DEPDIR)/libcmis_la-sharepoint-session.Plo -rm -f ./$(DEPDIR)/libcmis_la-sharepoint-utils.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-document.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-folder.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-navigationservice.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-object-type.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-object.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-objectservice.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-relatedmultipart.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-repositoryservice.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-requests.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-session.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-soap.Plo -rm -f ./$(DEPDIR)/libcmis_la-ws-versioningservice.Plo -rm -f ./$(DEPDIR)/libcmis_la-xml-utils.Plo -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-libLTLIBRARIES .MAKE: install-am install-strip .PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \ clean-generic clean-libLTLIBRARIES clean-libtool \ clean-noinstLTLIBRARIES cscopelist-am ctags ctags-am distclean \ distclean-compile distclean-generic distclean-libtool \ distclean-tags distdir dvi dvi-am html html-am info info-am \ install install-am install-data install-data-am install-dvi \ install-dvi-am install-exec install-exec-am install-html \ install-html-am install-info install-info-am \ install-libLTLIBRARIES install-man install-pdf install-pdf-am \ install-ps install-ps-am install-strip installcheck \ installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ tags tags-am uninstall uninstall-am uninstall-libLTLIBRARIES .PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: libcmis-0.5.2/src/libcmis/property-type.cxx0000664000175000017500000002142713407414352015674 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include #include using namespace std; namespace libcmis { PropertyType::PropertyType( ) : m_id( ), m_localName( ), m_localNamespace( ), m_displayName( ), m_queryName( ), m_type( String ), m_xmlType( "String" ), m_multiValued( false ), m_updatable( false ), m_inherited( false ), m_required( false ), m_queryable( false ), m_orderable( false ), m_openChoice( false ), m_temporary( false ) { } PropertyType::PropertyType( xmlNodePtr node ) : m_id( ), m_localName( ), m_localNamespace( ), m_displayName( ), m_queryName( ), m_type( String ), m_xmlType( "String" ), m_multiValued( false ), m_updatable( false ), m_inherited( false ), m_required( false ), m_queryable( false ), m_orderable( false ), m_openChoice( false ), m_temporary( false ) { for ( xmlNodePtr child = node->children; child; child = child->next ) { xmlChar* content = xmlNodeGetContent( child ); string value( ( const char * ) content ); xmlFree( content ); if ( xmlStrEqual( child->name, BAD_CAST( "id" ) ) ) setId( value ); else if ( xmlStrEqual( child->name, BAD_CAST( "localName" ) ) ) setLocalName( value ); else if ( xmlStrEqual( child->name, BAD_CAST( "localNamespace" ) ) ) setLocalNamespace( value ); else if ( xmlStrEqual( child->name, BAD_CAST( "displayName" ) ) ) setDisplayName( value ); else if ( xmlStrEqual( child->name, BAD_CAST( "queryName" ) ) ) setQueryName( value ); else if ( xmlStrEqual( child->name, BAD_CAST( "propertyType" ) ) ) setTypeFromXml( value ); else if ( xmlStrEqual( child->name, BAD_CAST( "cardinality" ) ) ) setMultiValued( value == "multi" ); else if ( xmlStrEqual( child->name, BAD_CAST( "updatability" ) ) ) setUpdatable( value == "readwrite" ); else if ( xmlStrEqual( child->name, BAD_CAST( "inherited" ) ) ) setInherited( libcmis::parseBool( value ) ); else if ( xmlStrEqual( child->name, BAD_CAST( "required" ) ) ) setRequired( libcmis::parseBool( value ) ); else if ( xmlStrEqual( child->name, BAD_CAST( "queryable" ) ) ) setQueryable( libcmis::parseBool( value ) ); else if ( xmlStrEqual( child->name, BAD_CAST( "orderable" ) ) ) setOrderable( libcmis::parseBool( value ) ); else if ( xmlStrEqual( child->name, BAD_CAST( "openChoice" ) ) ) setOpenChoice( libcmis::parseBool( value ) ); } } PropertyType::PropertyType( const PropertyType& copy ) : m_id ( copy.m_id ), m_localName ( copy.m_localName ), m_localNamespace ( copy.m_localNamespace ), m_displayName ( copy.m_displayName ), m_queryName ( copy.m_queryName ), m_type ( copy.m_type ), m_xmlType( copy.m_xmlType ), m_multiValued ( copy.m_multiValued ), m_updatable ( copy.m_updatable ), m_inherited ( copy.m_inherited ), m_required ( copy.m_required ), m_queryable ( copy.m_queryable ), m_orderable ( copy.m_orderable ), m_openChoice ( copy.m_openChoice ), m_temporary( copy.m_temporary ) { } PropertyType::PropertyType( string type, string id, string localName, string displayName, string queryName ) : m_id ( id ), m_localName ( localName ), m_localNamespace ( ), m_displayName ( displayName ), m_queryName ( queryName ), m_type ( ), m_xmlType( type ), m_multiValued( false ), m_updatable( false ), m_inherited( false ), m_required( false ), m_queryable( false ), m_orderable( false ), m_openChoice( false ), m_temporary( true ) { setTypeFromXml( m_xmlType ); } PropertyType& PropertyType::operator=( const PropertyType& copy ) { if ( this != © ) { m_id = copy.m_id; m_localName = copy.m_localName; m_localNamespace = copy.m_localNamespace; m_displayName = copy.m_displayName; m_queryName = copy.m_queryName; m_type = copy.m_type; m_xmlType = copy.m_xmlType; m_multiValued = copy.m_multiValued; m_updatable = copy.m_updatable; m_inherited = copy.m_inherited; m_required = copy.m_required; m_queryable = copy.m_queryable; m_orderable = copy.m_orderable; m_openChoice = copy.m_openChoice; m_temporary = copy.m_temporary; } return *this; } void PropertyType::setTypeFromJsonType( string jsonType ) { if ( jsonType == "json_bool" ) m_type = Bool; else if ( jsonType == "json_double" ) m_type = Decimal; else if ( jsonType == "json_int" ) m_type = Integer; else if ( jsonType == "json_datetime" ) m_type = DateTime; else m_type = String; } void PropertyType::setTypeFromXml( string typeStr ) { // Default to string m_xmlType = string( "String" ); m_type = String; if ( typeStr == "datetime" ) { m_xmlType = string( "DateTime" ); m_type = DateTime; } else if ( typeStr == "integer" ) { m_xmlType = string( "Integer" ); m_type = Integer; } else if ( typeStr == "decimal" ) { m_xmlType = string( "Decimal" ); m_type = Decimal; } else if ( typeStr == "boolean" ) { m_xmlType = string( "Boolean" ); m_type = Bool; } // Special kinds of String else if ( typeStr == "html" ) m_xmlType = string( "Html" ); else if ( typeStr == "id" ) m_xmlType = string( "Id" ); else if ( typeStr == "uri" ) m_xmlType = string( "Uri" ); } void PropertyType::update( vector< ObjectTypePtr > typesDefs ) { for ( vector< ObjectTypePtr >::iterator it = typesDefs.begin(); it != typesDefs.end( ) && m_temporary; ++it ) { map< string, PropertyTypePtr >& propertyTypes = ( *it )->getPropertiesTypes( ); map< string, PropertyTypePtr >::iterator propIt = propertyTypes.find( getId( ) ); if ( propIt != propertyTypes.end() ) { PropertyTypePtr complete = propIt->second; m_localName = complete->m_localName; m_localNamespace = complete->m_localNamespace; m_displayName = complete->m_displayName; m_queryName = complete->m_queryName; m_type = complete->m_type; m_xmlType = complete->m_xmlType; m_multiValued = complete->m_multiValued; m_updatable = complete->m_updatable; m_inherited = complete->m_inherited; m_required = complete->m_required; m_queryable = complete->m_queryable; m_orderable = complete->m_orderable; m_openChoice = complete->m_openChoice; m_temporary = false; } } } } libcmis-0.5.2/src/libcmis/folder.cxx0000664000175000017500000000536713407414352014311 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include using namespace std; namespace libcmis { vector< string > Folder::getPaths( ) { vector< string > paths; paths.push_back( getPath( ) ); return paths; } libcmis::FolderPtr Folder::getFolderParent( ) { if ( getAllowableActions( ).get() && !getAllowableActions()->isAllowed( libcmis::ObjectAction::GetFolderParent ) ) throw libcmis::Exception( string( "GetFolderParent not allowed on node " ) + getId() ); if ( m_session == NULL ) throw libcmis::Exception( string( "Session not defined on the object... weird!" ) ); return m_session->getFolder( getParentId( ) ); } string Folder::getParentId( ) { return getStringProperty( "cmis:parentId" ); } string Folder::getPath( ) { return getStringProperty( "cmis:path" ); } bool Folder::isRootFolder( ) { return getParentId( ).empty( ); } // LCOV_EXCL_START string Folder::toString( ) { stringstream buf; buf << "Folder Object:" << endl << endl; buf << Object::toString(); buf << "Path: " << getPath() << endl; buf << "Folder Parent Id: " << getParentId( ) << endl; buf << "Children [Name (Id)]:" << endl; vector< libcmis::ObjectPtr > children = getChildren( ); for ( vector< libcmis::ObjectPtr >::iterator it = children.begin( ); it != children.end(); ++it ) { libcmis::ObjectPtr child = *it; buf << " " << child->getName() << " (" << child->getId() << ")" << endl; } return buf.str(); } // LCOV_EXCL_STOP } libcmis-0.5.2/src/libcmis/allowable-actions.cxx0000664000175000017500000002371113407414352016427 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include #include using namespace std; namespace libcmis { ObjectAction::ObjectAction( xmlNodePtr node ) : m_type( ObjectAction::DeleteObject ), m_enabled( false ), m_valid( false ) { try { m_type = parseType( string( ( char* ) node->name ) ); m_valid = true; } catch ( const Exception& ) { m_valid = false; } // Invalid xsd:bool will be mean false... not sure what the spec says try { xmlChar* content = xmlNodeGetContent( node ); m_enabled = parseBool( string( ( char* )content ) ); xmlFree( content ); } catch ( const Exception& ) { m_enabled = false; } } ObjectAction::Type ObjectAction::parseType( string type ) { Type value = DeleteObject; if ( type == "canDeleteObject" ) value = DeleteObject; else if ( type == "canUpdateProperties" ) value = UpdateProperties; else if ( type == "canGetFolderTree" ) value = GetFolderTree; else if ( type == "canGetProperties" ) value = GetProperties; else if ( type == "canGetObjectRelationships" ) value = GetObjectRelationships; else if ( type == "canGetObjectParents" ) value = GetObjectParents; else if ( type == "canGetFolderParent" ) value = GetFolderParent; else if ( type == "canGetDescendants" ) value = GetDescendants; else if ( type == "canMoveObject" ) value = MoveObject; else if ( type == "canDeleteContentStream" ) value = DeleteContentStream; else if ( type == "canCheckOut" ) value = CheckOut; else if ( type == "canCancelCheckOut" ) value = CancelCheckOut; else if ( type == "canCheckIn" ) value = CheckIn; else if ( type == "canSetContentStream" ) value = SetContentStream; else if ( type == "canGetAllVersions" ) value = GetAllVersions; else if ( type == "canAddObjectToFolder" ) value = AddObjectToFolder; else if ( type == "canRemoveObjectFromFolder" ) value = RemoveObjectFromFolder; else if ( type == "canGetContentStream" ) value = GetContentStream; else if ( type == "canApplyPolicy" ) value = ApplyPolicy; else if ( type == "canGetAppliedPolicies" ) value = GetAppliedPolicies; else if ( type == "canRemovePolicy" ) value = RemovePolicy; else if ( type == "canGetChildren" ) value = GetChildren; else if ( type == "canCreateDocument" ) value = CreateDocument; else if ( type == "canCreateFolder" ) value = CreateFolder; else if ( type == "canCreateRelationship" ) value = CreateRelationship; else if ( type == "canDeleteTree" ) value = DeleteTree; else if ( type == "canGetRenditions" ) value = GetRenditions; else if ( type == "canGetACL" ) value = GetACL; else if ( type == "canApplyACL" ) value = ApplyACL; else throw Exception( "Invalid AllowableAction type: " + type ); return value; } AllowableActions::AllowableActions( ) : m_states( ) { } AllowableActions::AllowableActions( xmlNodePtr node ) : m_states( ) { for ( xmlNodePtr child = node->children; child; child = child->next ) { // Check for non text children... "\n" is also a node ;) if ( !xmlNodeIsText( child ) ) { ObjectAction action( child ); if ( action.isValid( ) ) m_states.insert( pair< libcmis::ObjectAction::Type, bool >( action.getType( ), action.isEnabled() ) ); } } } AllowableActions::AllowableActions( const AllowableActions& copy ) : m_states( copy.m_states ) { } AllowableActions::~AllowableActions( ) { m_states.clear(); } AllowableActions& AllowableActions::operator=( const AllowableActions& copy ) { if ( this != © ) m_states = copy.m_states; return *this; } bool AllowableActions::isAllowed( ObjectAction::Type action ) { bool allowed = false; map< ObjectAction::Type, bool>::iterator it = m_states.find( action ); if ( it != m_states.end() ) allowed = it->second; return allowed; } bool AllowableActions::isDefined( ObjectAction::Type action ) { map< ObjectAction::Type, bool>::iterator it = m_states.find( action ); return it != m_states.end(); } // LCOV_EXCL_START string AllowableActions::toString( ) { stringstream buf; for ( map< ObjectAction::Type, bool >::iterator it = m_states.begin( ); it != m_states.end( ); ++it ) { switch ( it->first ) { case ObjectAction::DeleteObject: buf << "canDeleteObject"; break; case ObjectAction::UpdateProperties: buf << "canUpdateProperties"; break; case ObjectAction::GetFolderTree: buf << "canGetFolderTree"; break; case ObjectAction::GetProperties: buf << "canGetProperties"; break; case ObjectAction::GetObjectRelationships: buf << "canGetObjectRelationships"; break; case ObjectAction::GetObjectParents: buf << "canGetObjectParents"; break; case ObjectAction::GetFolderParent: buf << "canGetFolderParent"; break; case ObjectAction::GetDescendants: buf << "canGetDescendants"; break; case ObjectAction::MoveObject: buf << "canMoveObject"; break; case ObjectAction::DeleteContentStream: buf << "canDeleteContentStream"; break; case ObjectAction::CheckOut: buf << "canCheckOut"; break; case ObjectAction::CancelCheckOut: buf << "canCancelCheckOut"; break; case ObjectAction::CheckIn: buf << "canCheckIn"; break; case ObjectAction::SetContentStream: buf << "canSetContentStream"; break; case ObjectAction::GetAllVersions: buf << "canGetAllVersions"; break; case ObjectAction::AddObjectToFolder: buf << "canAddObjectToFolder"; break; case ObjectAction::RemoveObjectFromFolder: buf << "canRemoveObjectFromFolder"; break; case ObjectAction::GetContentStream: buf << "canGetContentStream"; break; case ObjectAction::ApplyPolicy: buf << "canApplyPolicy"; break; case ObjectAction::GetAppliedPolicies: buf << "canGetAppliedPolicies"; break; case ObjectAction::RemovePolicy: buf << "canRemovePolicy"; break; case ObjectAction::GetChildren: buf << "canGetChildren"; break; case ObjectAction::CreateDocument: buf << "canCreateDocument"; break; case ObjectAction::CreateFolder: buf << "canCreateFolder"; break; case ObjectAction::CreateRelationship: buf << "canCreateRelationship"; break; case ObjectAction::DeleteTree: buf << "canDeleteTree"; break; case ObjectAction::GetRenditions: buf << "canGetRenditions"; break; case ObjectAction::GetACL: buf << "canGetACL"; break; case ObjectAction::ApplyACL: buf << "canApplyACL"; break; } buf << ": " << it->second << endl; } return buf.str( ); } // LCOV_EXCL_STOP } libcmis-0.5.2/src/libcmis/atom-object.cxx0000664000175000017500000003744213411147221015232 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "atom-object.hxx" #include #include #include #include #include #include #include "atom-document.hxx" #include "atom-folder.hxx" #include "atom-object-type.hxx" #include "atom-session.hxx" using namespace std; using libcmis::PropertyPtrMap; namespace { class MatchLink { private: string m_rel; string m_type; public: MatchLink( string rel, string type ) : m_rel( rel ), m_type( type ) { } bool operator() ( const AtomLink &link ) { bool matchesRel = link.getRel( ) == m_rel; // Some implementations (xcmis) put extra spaces into the type attribute // (e.g. "application/atom+xml; type=feed" instead of "application/atom+xml;type=feed") string linkType = link.getType( ); linkType.erase( remove_if( linkType.begin(), linkType.end(), boost::is_space() ), linkType.end() ); // Some implementation (SharePoint) are omitting the type attribute bool matchesType = m_type.empty( ) || linkType.empty() || ( linkType == m_type ); return matchesRel && matchesType; } }; } AtomObject::AtomObject( AtomPubSession* session ) : libcmis::Object( session ), m_links( ) { } AtomObject::AtomObject( const AtomObject& copy ) : libcmis::Object( copy ), m_links( copy.m_links ) { } AtomObject& AtomObject::operator=( const AtomObject& copy ) { if ( this != © ) { libcmis::Object::operator=( copy ); m_links = copy.m_links; } return *this; } AtomObject::~AtomObject( ) { } libcmis::ObjectPtr AtomObject::updateProperties( const PropertyPtrMap& properties ) { if ( getAllowableActions().get() && !getAllowableActions()->isAllowed( libcmis::ObjectAction::UpdateProperties ) ) throw libcmis::Exception( string( "UpdateProperties is not allowed on object " ) + getId() ); // No need to send HTTP request if there is nothing to update if ( properties.empty( ) ) { libcmis::ObjectPtr object; if ( getBaseType( ) == "cmis:document" ) { const AtomDocument& thisDoc = dynamic_cast< const AtomDocument& >( *this ); object.reset( new AtomDocument( thisDoc ) ); } else if ( getBaseType( ) == "cmis:folder" ) { const AtomFolder& thisFolder = dynamic_cast< const AtomFolder& >( *this ); object.reset( new AtomFolder( thisFolder ) ); } return object; } xmlBufferPtr buf = xmlBufferCreate( ); xmlTextWriterPtr writer = xmlNewTextWriterMemory( buf, 0 ); xmlTextWriterStartDocument( writer, NULL, NULL, NULL ); // Copy and remove the readonly properties before serializing boost::shared_ptr< ostream > stream; AtomObject::writeAtomEntry( writer, properties, stream, string( ) ); xmlTextWriterEndDocument( writer ); string str( ( const char * )xmlBufferContent( buf ) ); istringstream is( str ); xmlFreeTextWriter( writer ); xmlBufferFree( buf ); libcmis::HttpResponsePtr response; try { vector< string > headers; headers.push_back( "Content-Type: application/atom+xml;type=entry" ); response = getSession( )->httpPutRequest( getInfosUrl( ), is, headers ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } string respBuf = response->getStream( )->str( ); xmlDocPtr doc = xmlReadMemory( respBuf.c_str(), respBuf.size(), getInfosUrl().c_str(), NULL, 0 ); if ( NULL == doc ) throw libcmis::Exception( "Failed to parse object infos" ); libcmis::ObjectPtr updated = getSession( )->createObjectFromEntryDoc( doc ); if ( updated->getId( ) == getId( ) ) refreshImpl( doc ); xmlFreeDoc( doc ); return updated; } libcmis::AllowableActionsPtr AtomObject::getAllowableActions( ) { if ( !m_allowableActions ) { // For some reason we had no allowable actions before, get them now. AtomLink* link = getLink( "http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions", "application/cmisallowableactions+xml" ); if ( link ) { try { libcmis::HttpResponsePtr response = getSession()->httpGetRequest( link->getHref() ); string buf = response->getStream()->str(); xmlDocPtr doc = xmlReadMemory( buf.c_str(), buf.size(), link->getHref().c_str(), NULL, 0 ); xmlNodePtr actionsNode = xmlDocGetRootElement( doc ); if ( actionsNode ) m_allowableActions.reset( new libcmis::AllowableActions( actionsNode ) ); xmlFreeDoc( doc ); } catch ( CurlException& ) { } } } return libcmis::Object::getAllowableActions(); } void AtomObject::refreshImpl( xmlDocPtr doc ) { bool createdDoc = ( NULL == doc ); if ( createdDoc ) { string buf; try { buf = getSession()->httpGetRequest( getInfosUrl() )->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } doc = xmlReadMemory( buf.c_str(), buf.size(), getInfosUrl().c_str(), NULL, 0 ); if ( NULL == doc ) throw libcmis::Exception( "Failed to parse object infos" ); } // Cleanup the structures before setting them again m_typeDescription.reset( ); m_properties.clear( ); m_allowableActions.reset( ); m_links.clear( ); m_renditions.clear( ); extractInfos( doc ); if ( createdDoc ) xmlFreeDoc( doc ); } void AtomObject::remove( bool allVersions ) { if ( getAllowableActions( ).get() && !getAllowableActions()->isAllowed( libcmis::ObjectAction::DeleteObject ) ) throw libcmis::Exception( string( "DeleteObject not allowed on object " ) + getId() ); try { string deleteUrl = getInfosUrl( ); if ( deleteUrl.find( '?' ) != string::npos ) deleteUrl += "&"; else deleteUrl += "?"; string allVersionsStr = "TRUE"; if ( !allVersions ) allVersionsStr = "FALSE"; deleteUrl += "allVersions=" + allVersionsStr; getSession( )->httpDeleteRequest( deleteUrl ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } } void AtomObject::move( boost::shared_ptr< libcmis::Folder > source, boost::shared_ptr< libcmis::Folder > destination ) { AtomFolder* atomDestination = dynamic_cast< AtomFolder* > ( destination.get() ); if ( NULL == atomDestination ) throw libcmis::Exception( string( "Destination is not an AtomFolder" ) ); AtomLink* destChildrenLink = atomDestination->getLink( "down", "application/atom+xml;type=feed" ); if ( ( NULL == destChildrenLink ) || ( getAllowableActions().get() && !getAllowableActions()->isAllowed( libcmis::ObjectAction::MoveObject ) ) ) throw libcmis::Exception( string( "MoveObject not allowed on object " ) + getId() ); // create object xml xmlBufferPtr buf = xmlBufferCreate( ); xmlTextWriterPtr writer = xmlNewTextWriterMemory( buf, 0 ); xmlTextWriterStartDocument( writer, NULL, NULL, NULL ); boost::shared_ptr< ostream > stream; AtomObject::writeAtomEntry( writer, getProperties( ), stream, string( ) ); xmlTextWriterEndDocument( writer ); string str( ( const char * )xmlBufferContent( buf ) ); istringstream is( str ); xmlFreeTextWriter( writer ); xmlBufferFree( buf ); // create post url string postUrl = destChildrenLink->getHref(); if ( postUrl.find( '?' ) != string::npos ) postUrl += "&"; else postUrl += "?"; postUrl += "sourceFolderId={sourceFolderId}"; // Session::CreateUrl is used to properly escape the id map< string, string > params; params[ "sourceFolderId" ] = source->getId(); postUrl = getSession( )->createUrl( postUrl, params ); // post it libcmis::HttpResponsePtr response; try { response = getSession( )->httpPostRequest( postUrl, is, "application/atom+xml;type=entry" ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } // refresh self from response string respBuf = response->getStream( )->str( ); xmlDocPtr doc = xmlReadMemory( respBuf.c_str(), respBuf.size(), getInfosUrl().c_str(), NULL, 0 ); if ( NULL == doc ) throw libcmis::Exception( "Failed to parse object infos" ); refreshImpl( doc ); xmlFreeDoc( doc ); } string AtomObject::getInfosUrl( ) { AtomLink* selfLink = getLink( "self", "application/atom+xml;type=entry" ); if ( NULL != selfLink ) return selfLink->getHref( ); return string( ); } void AtomObject::extractInfos( xmlDocPtr doc ) { xmlXPathContextPtr xpathCtx = xmlXPathNewContext( doc ); libcmis::registerNamespaces( xpathCtx ); if ( NULL != xpathCtx ) { m_links.clear( ); m_renditions.clear( ); // Get all the atom links string linksReq( "//atom:link" ); xmlXPathObjectPtr xpathObj = xmlXPathEvalExpression( BAD_CAST( linksReq.c_str() ), xpathCtx ); if ( NULL != xpathObj && NULL != xpathObj->nodesetval ) { int size = xpathObj->nodesetval->nodeNr; for ( int i = 0; i < size; i++ ) { xmlNodePtr node = xpathObj->nodesetval->nodeTab[i]; try { AtomLink link( node ); // Add to renditions if alternate link if ( link.getRel( ) == "alternate" ) { string kind; map< string, string >::iterator it = link.getOthers().find( "renditionKind" ); if ( it != link.getOthers( ).end() ) kind = it->second; string title; it = link.getOthers().find( "title" ); if ( it != link.getOthers( ).end( ) ) title = it->second; long length = -1; it = link.getOthers( ).find( "length" ); if ( it != link.getOthers( ).end( ) ) length = libcmis::parseInteger( it->second ); libcmis::RenditionPtr rendition( new libcmis::Rendition( string(), link.getType(), kind, link.getHref( ), title, length ) ); m_renditions.push_back( rendition ); } else m_links.push_back( node ); } catch ( const libcmis::Exception& ) { // Broken or incomplete link... don't add it } } } xmlXPathFreeObject( xpathObj ); xpathObj = xmlXPathEvalExpression( BAD_CAST( "//cmisra:object" ), xpathCtx ); if ( xpathObj && xpathObj->nodesetval && xpathObj->nodesetval->nodeNr > 0 ) { xmlNodePtr node = xpathObj->nodesetval->nodeTab[0]; initializeFromNode( node ); } xmlXPathFreeObject( xpathObj ); } xmlXPathFreeContext( xpathCtx ); } AtomPubSession* AtomObject::getSession( ) { return dynamic_cast< AtomPubSession* >( m_session ); } void AtomObject::writeAtomEntry( xmlTextWriterPtr writer, const PropertyPtrMap& properties, boost::shared_ptr< ostream > os, string contentType ) { AtomObject tmp( NULL ); PropertyPtrMap propertiesCopy( properties ); tmp.m_properties.swap( propertiesCopy ); xmlTextWriterStartElement( writer, BAD_CAST( "atom:entry" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:atom" ), BAD_CAST( NS_ATOM_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmisra" ), BAD_CAST( NS_CMISRA_URL ) ); if ( !tmp.getCreatedBy( ).empty( ) ) { xmlTextWriterStartElement( writer, BAD_CAST( "atom:author" ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "atom:name" ), BAD_CAST( tmp.getCreatedBy( ).c_str( ) ) ); xmlTextWriterEndElement( writer ); } xmlTextWriterWriteElement( writer, BAD_CAST( "atom:title" ), BAD_CAST( tmp.getName( ).c_str( ) ) ); boost::posix_time::ptime now( boost::posix_time::second_clock::universal_time( ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "atom:updated" ), BAD_CAST( libcmis::writeDateTime( now ).c_str( ) ) ); if ( os.get( ) ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmisra:content" ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmisra:mediatype" ), BAD_CAST( contentType.c_str() ) ); xmlTextWriterStartElement(writer, BAD_CAST( "cmisra:base64" ) ); libcmis::EncodedData encoder( writer ); encoder.setEncoding( "base64" ); istream is( os->rdbuf( ) ); int bufLength = 1000; char* buf = new char[ bufLength ]; do { is.read( buf, bufLength ); int size = is.gcount( ); encoder.encode( buf, 1, size ); } while ( !is.eof( ) && !is.fail( ) ); delete[] buf; encoder.finish( ); xmlTextWriterEndElement( writer ); // "cmisra:base64" xmlTextWriterEndElement( writer ); } xmlTextWriterStartElement( writer, BAD_CAST( "cmisra:object" ) ); tmp.toXml( writer ); xmlTextWriterEndElement( writer ); // cmisra:object xmlTextWriterEndElement( writer ); // atom:entry } AtomLink* AtomObject::getLink( std::string rel, std::string type ) { AtomLink* link = NULL; vector< AtomLink >::iterator it = find_if( m_links.begin(), m_links.end(), MatchLink( rel, type ) ); if ( it != m_links.end() ) link = &( *it ); return link; } AtomLink::AtomLink( xmlNodePtr node ): m_rel( ), m_type( ), m_id( ), m_href( ), m_others( ) { xmlAttrPtr prop = node->properties; while ( prop != NULL ) { xmlChar* xmlStr = xmlGetProp( node, prop->name ); string value( ( char * ) xmlStr ); if ( xmlStrEqual( prop->name, BAD_CAST( "id" ) ) ) m_id = value; else if ( xmlStrEqual( prop->name, BAD_CAST( "type" ) ) ) m_type = value; else if ( xmlStrEqual( prop->name, BAD_CAST( "rel" ) ) ) m_rel = value; else if ( xmlStrEqual( prop->name, BAD_CAST( "href" ) ) ) m_href = value; else m_others[ string( ( char * ) prop->name ) ] = value; free( xmlStr ); prop = prop->next; } } libcmis-0.5.2/src/libcmis/atom-session.hxx0000664000175000017500000000615413407414352015457 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _ATOM_SESSION_HXX_ #define _ATOM_SESSION_HXX_ #include "base-session.hxx" #include "atom-workspace.hxx" class AtomPubSession : public BaseSession { private: AtomRepositoryPtr m_repository; public: enum ResultObjectType { RESULT_DYNAMIC, RESULT_FOLDER, RESULT_DOCUMENT }; AtomPubSession( std::string sAtomPubUrl, std::string repositoryId, std::string username, std::string password, bool noSslCheck = false, libcmis::OAuth2DataPtr oauth2 = libcmis::OAuth2DataPtr(), bool verbose =false ); /** This constructor uses the response of an HTTP request made before to spare some HTTP request. This constructor has mostly been designed for the SessionFactory use. */ AtomPubSession( std::string sAtomPubUrl, std::string repositoryId, const HttpSession& httpSession, libcmis::HttpResponsePtr response ); AtomPubSession( const AtomPubSession& copy ); ~AtomPubSession( ); AtomPubSession& operator=( const AtomPubSession& copy ); AtomRepositoryPtr getAtomRepository( ); // Utility methods libcmis::ObjectPtr createObjectFromEntryDoc( xmlDocPtr doc, ResultObjectType res=RESULT_DYNAMIC ); std::vector< libcmis::ObjectTypePtr > getChildrenTypes( std::string url ); // Override session methods virtual libcmis::RepositoryPtr getRepository( ); virtual bool setRepository( std::string repositoryId ); virtual libcmis::ObjectPtr getObject( std::string id ); virtual libcmis::ObjectPtr getObjectByPath( std::string path ); virtual libcmis::ObjectTypePtr getType( std::string id ); virtual std::vector< libcmis::ObjectTypePtr > getBaseTypes( ); protected: /** Defaults constructor shouldn't be used */ AtomPubSession( ); void parseServiceDocument( const std::string& buf ); void initialize( libcmis::HttpResponsePtr response ); }; #endif libcmis-0.5.2/src/libcmis/property.cxx0000664000175000017500000002021113407414352014703 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include #include #include using namespace std; namespace libcmis { Property::Property( ): m_propertyType( ), m_strValues( ), m_boolValues( ), m_longValues( ), m_doubleValues( ), m_dateTimeValues( ) { } Property::Property( PropertyTypePtr propertyType, std::vector< std::string > strValues ) : m_propertyType( propertyType ), m_strValues( ), m_boolValues( ), m_longValues( ), m_doubleValues( ), m_dateTimeValues( ) { setValues( strValues ); } void Property::setValues( vector< string > strValues ) { m_strValues = strValues; m_boolValues.clear( ); m_longValues.clear( ); m_doubleValues.clear( ); m_dateTimeValues.clear( ); for ( vector< string >::iterator it = strValues.begin(); it != strValues.end( ); ++it ) { try { // If no PropertyType was provided at construction time, use String PropertyType::Type type = PropertyType::String; if ( getPropertyType( ) != NULL ) type = getPropertyType( )->getType( ); switch ( type ) { case PropertyType::Integer: m_longValues.push_back( parseInteger( *it ) ); break; case PropertyType::Decimal: m_doubleValues.push_back( parseDouble( *it ) ); break; case PropertyType::Bool: m_boolValues.push_back( parseBool( *it ) ); break; case PropertyType::DateTime: { boost::posix_time::ptime time = parseDateTime( *it ); if ( !time.is_not_a_date_time( ) ) m_dateTimeValues.push_back( time ); } break; default: case PropertyType::String: // Nothing to convert for strings break; } } catch( const Exception& ) { // Just ignore the unparsable values } } } void Property::setPropertyType( PropertyTypePtr propertyType) { m_propertyType = propertyType; } void Property::toXml( xmlTextWriterPtr writer ) { // Don't write the property if we have no type for it. if ( getPropertyType( ) != NULL ) { string xmlType = string( "cmis:property" ) + getPropertyType()->getXmlType( ); xmlTextWriterStartElement( writer, BAD_CAST( xmlType.c_str( ) ) ); // Write the attributes xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "propertyDefinitionId" ), "%s", BAD_CAST( getPropertyType()->getId( ).c_str( ) ) ); xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "localName" ), "%s", BAD_CAST( getPropertyType()->getLocalName( ).c_str( ) ) ); xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "displayName" ), "%s", BAD_CAST( getPropertyType()->getDisplayName( ).c_str( ) ) ); xmlTextWriterWriteFormatAttribute( writer, BAD_CAST( "queryName" ), "%s", BAD_CAST( getPropertyType()->getQueryName( ).c_str( ) ) ); // Write the values for ( vector< string >::iterator it = m_strValues.begin( ); it != m_strValues.end( ); ++it ) { xmlTextWriterWriteElement( writer, BAD_CAST( "cmis:value" ), BAD_CAST( it->c_str( ) ) ); } xmlTextWriterEndElement( writer ); } } string Property::toString( ) { string res; if ( getPropertyType( ) != NULL ) { for ( vector< string >::iterator it = m_strValues.begin( ); it != m_strValues.end( ); ++it ) { res.append( *it ); } } return res; } PropertyPtr parseProperty( xmlNodePtr node, ObjectTypePtr objectType ) { PropertyPtr property; if ( node != NULL ) { // Get the property definition Id string propDefinitionId; try { propDefinitionId = getXmlNodeAttributeValue( node, "propertyDefinitionId" ); } catch ( const Exception& ) { } // Try to get the property type definition PropertyTypePtr propType; if ( !propDefinitionId.empty() && objectType ) { map< string, PropertyTypePtr >::iterator it = objectType->getPropertiesTypes( ).find( propDefinitionId ); if ( it != objectType->getPropertiesTypes().end( ) ) propType = it->second; } // Try to construct a temporary type definition if ( !propDefinitionId.empty( ) && !propType ) { if ( node->name != NULL ) { string localName = getXmlNodeAttributeValue( node, "localName", "" ); string displayName = getXmlNodeAttributeValue( node, "displayName", "" ); string queryName = getXmlNodeAttributeValue( node, "queryName", "" ); string xmlType( ( char * )node->name ); string propStr( "property" ); size_t pos = xmlType.find( propStr ); if ( pos == 0 ) { xmlType = xmlType.substr( propStr.length( ) ); boost::to_lower( xmlType ); } propType.reset( new PropertyType( xmlType, propDefinitionId, localName, displayName, queryName ) ); } } if ( propType ) { try { // Find the value nodes vector< string > values; for ( xmlNodePtr child = node->children; child; child = child->next ) { if ( xmlStrEqual( child->name, BAD_CAST( "value" ) ) ) { xmlChar* content = xmlNodeGetContent( child ); values.push_back( string( ( char * ) content ) ); xmlFree( content ); } } property.reset( new Property( propType, values ) ); } catch ( const Exception& ) { // Ignore that non-property node } } } return property; } } libcmis-0.5.2/src/libcmis/sharepoint-session.cxx0000664000175000017500000003341713407414352016670 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "sharepoint-session.hxx" #include #include "sharepoint-document.hxx" #include "sharepoint-folder.hxx" #include "sharepoint-object.hxx" #include "sharepoint-object-type.hxx" #include "sharepoint-repository.hxx" #include "sharepoint-utils.hxx" using namespace std; SharePointSession::SharePointSession ( string baseUrl, string username, string password, bool verbose ) : BaseSession( baseUrl, string(), username, password, false, libcmis::OAuth2DataPtr(), verbose ), m_digestCode( string( ) ) { setAuthMethod( CURLAUTH_NTLM ); libcmis::HttpResponsePtr response; try { response = httpGetRequest( baseUrl + "/currentuser" ); } catch ( const CurlException& e ) { // It's not SharePoint or wrong username/passwd provided throw e.getCmisException( ); } // Add the dummy repository m_repositories.push_back( getRepository( ) ); fetchDigestCode( ); } SharePointSession::SharePointSession( string baseUrl, const HttpSession& httpSession, libcmis::HttpResponsePtr response ) : BaseSession( baseUrl, string(), httpSession ), m_digestCode( string( ) ) { if ( !SharePointUtils::isSharePoint( response->getStream( )->str( ) ) ) { throw libcmis::Exception( "Not a SharePoint service" ); } // Add the dummy repository m_repositories.push_back( getRepository( ) ); fetchDigestCode( ); } SharePointSession::SharePointSession( const SharePointSession& copy ) : BaseSession( copy ), m_digestCode( copy.m_digestCode ) { } SharePointSession::SharePointSession() : BaseSession(), m_digestCode( string( ) ) { } SharePointSession::~SharePointSession() { } bool SharePointSession::setRepository( string ) { return true; } libcmis::RepositoryPtr SharePointSession::getRepository( ) { // Return a dummy repository since SharePoint doesn't have that notion libcmis::RepositoryPtr repo( new SharePointRepository( getBindingUrl( ) ) ); return repo; } libcmis::ObjectPtr SharePointSession::getObject( string objectId ) { // objectId is uri for the file string res; try { res = httpGetRequest( objectId )->getStream()->str(); } catch ( const CurlException& e ) { throw e.getCmisException( ); } Json jsonRes = Json::parse( res ); return getObjectFromJson( jsonRes ); } libcmis::ObjectPtr SharePointSession::getObjectFromJson( Json& jsonRes, string parentId ) { libcmis::ObjectPtr object; if ( !jsonRes["d"].toString( ).empty( ) ) { jsonRes = jsonRes["d"]; } string kind = jsonRes["__metadata"]["type"].toString( ); // only SharePointObject available for now if ( kind == "SP.Folder" ) { object.reset( new SharePointFolder( this, jsonRes, parentId ) ); } else if ( kind == "SP.File" || kind == "SP.FileVersion" ) { object.reset( new SharePointDocument( this, jsonRes, parentId ) ); } else { object.reset( new SharePointObject( this, jsonRes, parentId ) ); } return object; } libcmis::ObjectPtr SharePointSession::getObjectByPath( string path ) { libcmis::ObjectPtr object; path = libcmis::escape( path ); // we don't know the object type so we try with Folder first try { string folderUrl = getBindingUrl( ) + "/getFolderByServerRelativeUrl"; folderUrl += "('" + path + "')"; object = getObject( folderUrl ); } catch ( const libcmis::Exception &e ) { // it's not a Folder, maybe it's a File string fileUrl = getBindingUrl( ) + "/getFileByServerRelativeUrl"; fileUrl += "('" + path + "')"; object = getObject( fileUrl ); } return object; } libcmis::ObjectTypePtr SharePointSession::getType( string id ) { libcmis::ObjectTypePtr type( new SharePointObjectType( id ) ); return type; } vector< libcmis::ObjectTypePtr > SharePointSession::getBaseTypes( ) { vector< libcmis::ObjectTypePtr > types; return types; } Json SharePointSession::getJsonFromUrl( string url ) { string response; try { response = httpGetRequest( url )->getStream()->str(); } catch ( const CurlException& e ) { throw e.getCmisException( ); } return Json::parse( response ); } /* Overwriting HttpSession::httpRunRequest to add the "accept:application/json" header */ void SharePointSession::httpRunRequest( string url, vector< string > headers, bool redirect ) { // Redirect curl_easy_setopt( m_curlHandle, CURLOPT_FOLLOWLOCATION, redirect); // Activate the cookie engine curl_easy_setopt( m_curlHandle, CURLOPT_COOKIEFILE, "" ); // Grab something from the web curl_easy_setopt( m_curlHandle, CURLOPT_URL, url.c_str() ); // Set the headers struct curl_slist *headers_slist = NULL; for ( vector< string >::iterator it = headers.begin( ); it != headers.end( ); ++it ) headers_slist = curl_slist_append( headers_slist, it->c_str( ) ); headers_slist = curl_slist_append( headers_slist, "accept:application/json; odata=verbose" ); headers_slist = curl_slist_append( headers_slist, ( "x-requestdigest:" + m_digestCode ).c_str( ) ); if ( !getUsername().empty() && !getPassword().empty() ) { curl_easy_setopt( m_curlHandle, CURLOPT_HTTPAUTH, m_authMethod ); #if LIBCURL_VERSION_VALUE >= 0x071301 curl_easy_setopt( m_curlHandle, CURLOPT_USERNAME, getUsername().c_str() ); curl_easy_setopt( m_curlHandle, CURLOPT_PASSWORD, getPassword().c_str() ); #else string userpwd = getUsername() + ":" + getPassword(); curl_easy_setopt( m_curlHandle, CURLOPT_USERPWD, userpwd.c_str( ) ); #endif } curl_easy_setopt( m_curlHandle, CURLOPT_HTTPHEADER, headers_slist ); // Set the proxy configuration if any if ( !libcmis::SessionFactory::getProxy( ).empty() ) { curl_easy_setopt( m_curlHandle, CURLOPT_PROXY, libcmis::SessionFactory::getProxy( ).c_str() ); #if LIBCURL_VERSION_VALUE >= 0x071304 curl_easy_setopt( m_curlHandle, CURLOPT_NOPROXY, libcmis::SessionFactory::getNoProxy( ).c_str() ); #endif const string& proxyUser = libcmis::SessionFactory::getProxyUser( ); const string& proxyPass = libcmis::SessionFactory::getProxyPass( ); if ( !proxyUser.empty( ) && !proxyPass.empty( ) ) { curl_easy_setopt( m_curlHandle, CURLOPT_PROXYAUTH, CURLAUTH_ANY ); #if LIBCURL_VERSION_VALUE >= 0X071301 curl_easy_setopt( m_curlHandle, CURLOPT_PROXYUSERNAME, proxyUser.c_str( ) ); curl_easy_setopt( m_curlHandle, CURLOPT_PROXYPASSWORD, proxyPass.c_str( ) ); #else string userpwd = proxyUser + ":" + proxyPass; curl_easy_setopt( m_curlHandle, CURLOPT_PROXYUSERPWD, userpwd.c_str( ) ); #endif } } // Get some feedback when something wrong happens char errBuff[CURL_ERROR_SIZE]; errBuff[0] = 0; curl_easy_setopt( m_curlHandle, CURLOPT_ERRORBUFFER, errBuff ); // We want to get the response even if there is an Http error if ( !m_noHttpErrors ) curl_easy_setopt( m_curlHandle, CURLOPT_FAILONERROR, 1 ); if ( m_verbose ) curl_easy_setopt( m_curlHandle, CURLOPT_VERBOSE, 1 ); // We want to get the certificate infos in error cases #if LIBCURL_VERSION_VALUE >= 0X071301 curl_easy_setopt( m_curlHandle, CURLOPT_CERTINFO, 1 ); #endif if ( m_noSSLCheck ) { #if LIBCURL_VERSION_VALUE >= 0x070801 curl_easy_setopt(m_curlHandle, CURLOPT_SSL_VERIFYHOST, 0); #endif #if LIBCURL_VERSION_VALUE >= 0x070402 curl_easy_setopt(m_curlHandle, CURLOPT_SSL_VERIFYPEER, 0); #endif } // Perform the query CURLcode errCode = curl_easy_perform( m_curlHandle ); // Free the headers list curl_slist_free_all( headers_slist ); // Process the response bool isHttpError = errCode == CURLE_HTTP_RETURNED_ERROR; if ( CURLE_OK != errCode && !( m_noHttpErrors && isHttpError ) ) { long httpError = 0; curl_easy_getinfo( m_curlHandle, CURLINFO_RESPONSE_CODE, &httpError ); bool errorFixed = false; #if LIBCURL_VERSION_VALUE >= 0X071301 // If we had a bad certificate, then try to get more details if ( CURLE_SSL_CACERT == errCode ) { vector< string > certificates; // We somehow need to rerun the request to get the certificate curl_easy_setopt(m_curlHandle, CURLOPT_SSL_VERIFYHOST, 0); curl_easy_setopt(m_curlHandle, CURLOPT_SSL_VERIFYPEER, 0); errCode = curl_easy_perform( m_curlHandle ); union { struct curl_slist *to_info; struct curl_certinfo *to_certinfo; } ptr; ptr.to_info = NULL; CURLcode res = curl_easy_getinfo(m_curlHandle, CURLINFO_CERTINFO, &ptr.to_info); if ( !res && ptr.to_info ) { // We need the first certificate in the chain only if ( ptr.to_certinfo->num_of_certs > 0 ) { struct curl_slist *slist; string certStart( "Cert:" ); for ( slist = ptr.to_certinfo->certinfo[0]; slist; slist = slist->next ) { string data( slist->data ); size_t startPos = data.find( certStart ); if ( startPos == 0 ) { startPos = certStart.length(); data = data.substr( startPos ); certificates.push_back( data ); } } } } if ( !certificates.empty() ) { libcmis::CertValidationHandlerPtr validationHandler = libcmis::SessionFactory::getCertificateValidationHandler( ); bool ignoreCert = validationHandler && validationHandler->validateCertificate( certificates ); if ( ignoreCert ) { m_noSSLCheck = true; isHttpError = errCode == CURLE_HTTP_RETURNED_ERROR; errorFixed = ( CURLE_OK == errCode || ( m_noHttpErrors && isHttpError ) ); if ( !errorFixed ) curl_easy_getinfo( m_curlHandle, CURLINFO_RESPONSE_CODE, &httpError ); } else { throw CurlException( "Invalid SSL certificate" ); } } } #endif if ( !errorFixed ) throw CurlException( string( errBuff ), errCode, url, httpError ); } } libcmis::HttpResponsePtr SharePointSession::httpPutRequest( std::string url, std::istream& is, std::vector< std::string > headers ) { libcmis::HttpResponsePtr response; try { response = HttpSession::httpPutRequest( url, is, headers ); } catch ( const CurlException& e ) { fetchDigestCodeCurl( ); response = HttpSession::httpPutRequest( url, is, headers ); } return response; } libcmis::HttpResponsePtr SharePointSession::httpPostRequest( const std::string& url, std::istream& is, const std::string& contentType, bool redirect ) { libcmis::HttpResponsePtr response; try { response = HttpSession::httpPostRequest( url, is, contentType, redirect ); } catch ( const CurlException& e ) { fetchDigestCodeCurl( ); response = HttpSession::httpPostRequest( url, is, contentType, redirect ); } return response; } void SharePointSession::httpDeleteRequest( std::string url ) { try { HttpSession::httpDeleteRequest( url ); } catch ( const CurlException& e ) { fetchDigestCodeCurl( ); HttpSession::httpDeleteRequest( url ); } } void SharePointSession::fetchDigestCode( ) try { fetchDigestCodeCurl( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } void SharePointSession::fetchDigestCodeCurl( ) { istringstream is( "empty" ); libcmis::HttpResponsePtr response; // url = http://host/_api/contextinfo, first we remove the '/web' part string url = m_bindingUrl.substr( 0, m_bindingUrl.size( ) - 4 ) + "/contextinfo"; response = HttpSession::httpPostRequest( url, is, "" ); string res = response->getStream( )->str( ); Json jsonRes = Json::parse( res ); m_digestCode = jsonRes["d"]["GetContextWebInformation"]["FormDigestValue"].toString( ); } libcmis-0.5.2/src/libcmis/ws-document.cxx0000664000175000017500000001123513407414352015272 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "ws-document.hxx" using namespace std; using libcmis::PropertyPtrMap; WSDocument::WSDocument( const WSObject& object ) : libcmis::Object( object ), libcmis::Document( const_cast< WSObject& >( object ).getSession( ) ), WSObject( object ) { } WSDocument::~WSDocument( ) { } vector< libcmis::FolderPtr > WSDocument::getParents( ) { string repoId = getSession( )->getRepositoryId( ); return getSession( )->getNavigationService( ).getObjectParents( repoId, getId( ) ); } boost::shared_ptr< istream > WSDocument::getContentStream( std::string /* streamId */ ) { string repoId = getSession( )->getRepositoryId( ); return getSession( )->getObjectService( ).getContentStream( repoId, getId( ) ); } void WSDocument::setContentStream( boost::shared_ptr< ostream > os, string contentType, string fileName, bool overwrite ) { string repoId = getSession( )->getRepositoryId( ); getSession( )->getObjectService( ).setContentStream( repoId, getId( ), overwrite, getChangeToken( ), os, contentType, fileName ); refresh( ); } libcmis::DocumentPtr WSDocument::checkOut( ) { string repoId = getSession( )->getRepositoryId( ); return getSession( )->getVersioningService( ).checkOut( repoId, getId( ) ); } void WSDocument::cancelCheckout( ) { string repoId = getSession( )->getRepositoryId( ); getSession( )->getVersioningService( ).cancelCheckOut( repoId, getId( ) ); } libcmis::DocumentPtr WSDocument::checkIn( bool isMajor, string comment, const PropertyPtrMap& properties, boost::shared_ptr< ostream > stream, string contentType, string fileName ) { string repoId = getSession( )->getRepositoryId( ); libcmis::DocumentPtr newVersion; // Try the normal request first, but if we have a server error, we may want to resend it // without the stream as SharePoint wants no stream in the request, but gets the one from // the PWC see the following discussion: // http://social.technet.microsoft.com/Forums/eu/sharepoint2010programming/thread/b30e4d82-5b7e-4ceb-b9ad-c6f0d4c59d11 bool tryNoStream = false; try { newVersion = getSession( )->getVersioningService( ).checkIn( repoId, getId( ), isMajor, properties, stream, contentType, fileName, comment ); } catch ( const libcmis::Exception& e ) { string spError( "Object reference not set to an instance of an object" ); if ( string( e.what( ) ).find( spError ) != string::npos ) tryNoStream = true; else throw; } if ( tryNoStream ) { // Set the content stream first setContentStream( stream, contentType, fileName ); // Then check-in boost::shared_ptr< ostream > nostream; newVersion = getSession( )->getVersioningService( ).checkIn( repoId, getId( ), isMajor, properties, nostream, string( ), string( ), comment ); } if ( newVersion->getId( ) == getId( ) ) refresh( ); return newVersion; } vector< libcmis::DocumentPtr > WSDocument::getAllVersions( ) { vector< libcmis::DocumentPtr > versions; string repoId = getSession( )->getRepositoryId( ); string versionSeries; PropertyPtrMap::const_iterator it = getProperties( ).find( string( "cmis:versionSeriesId" ) ); if ( it != getProperties( ).end( ) && !it->second->getStrings( ).empty( ) ) { versionSeries = it->second->getStrings( ).front( ); versions = getSession( )->getVersioningService( ).getAllVersions( repoId, versionSeries ); } return versions; } libcmis-0.5.2/src/libcmis/onedrive-object-type.cxx0000664000175000017500000001067413407414352017071 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "onedrive-object-type.hxx" OneDriveObjectType::OneDriveObjectType( const std::string& id ): ObjectType( ) { m_id = id; m_localName = "OneDrive Object Type"; m_localNamespace = "OneDrive Object Type"; m_displayName = "OneDrive Object Type"; m_queryName = id; m_description = "OneDrive Object Type"; m_parentTypeId = ""; m_baseTypeId = id; m_creatable = true; m_versionable = false; m_fileable = true; m_fulltextIndexed = ( id == "cmis:document" ); m_queryable = true; if ( id == "cmis:document" ) m_contentStreamAllowed = libcmis::ObjectType::Allowed; else m_contentStreamAllowed = libcmis::ObjectType::NotAllowed; libcmis::PropertyTypePtr idType(new libcmis::PropertyType( ) ); idType->setId( "cmis:objectTypeId" ); idType->setType( libcmis::PropertyType::String ); m_propertiesTypes[ idType->getId( ) ] = idType; // create PropertyTypes which are updatable. // name libcmis::PropertyTypePtr nameType( new libcmis::PropertyType( ) ); nameType->setId( "cmis:name" ); nameType->setType( libcmis::PropertyType::String ); nameType->setUpdatable( true ); m_propertiesTypes[ nameType->getId( ) ] = nameType; // description libcmis::PropertyTypePtr descriptionType( new libcmis::PropertyType( ) ); descriptionType->setId( "cmis:description" ); descriptionType->setType( libcmis::PropertyType::String ); descriptionType->setUpdatable( true ); m_propertiesTypes[ descriptionType->getId( ) ] = descriptionType; // modifiedDate libcmis::PropertyTypePtr modifiedDateType( new libcmis::PropertyType( ) ); modifiedDateType->setId( "cmis:lastModificationDate" ); modifiedDateType->setType( libcmis::PropertyType::DateTime ); modifiedDateType->setUpdatable( false ); m_propertiesTypes[ modifiedDateType->getId( ) ] = modifiedDateType; // creationDate libcmis::PropertyTypePtr creationDateType( new libcmis::PropertyType( ) ); creationDateType->setId( "cmis:creationDate" ); creationDateType->setType( libcmis::PropertyType::DateTime ); creationDateType->setUpdatable( false ); m_propertiesTypes[ creationDateType->getId( ) ] = creationDateType; if ( id == "cmis:document" ) { // size libcmis::PropertyTypePtr contentStreamLength( new libcmis::PropertyType( ) ); contentStreamLength->setId( "cmis:contentStreamLength" ); contentStreamLength->setType( libcmis::PropertyType::Integer ); contentStreamLength->setUpdatable( false ); m_propertiesTypes[ contentStreamLength->getId( ) ] = contentStreamLength; // streamFileName libcmis::PropertyTypePtr streamFileNameType( new libcmis::PropertyType( ) ); streamFileNameType->setId( "cmis:contentStreamFileName" ); streamFileNameType->setType( libcmis::PropertyType::String ); streamFileNameType->setUpdatable( true ); m_propertiesTypes[ streamFileNameType->getId( ) ] = streamFileNameType; } } libcmis::ObjectTypePtr OneDriveObjectType::getParentType( ) { libcmis::ObjectTypePtr parentTypePtr; if ( m_parentTypeId != "" ) { parentTypePtr.reset( new OneDriveObjectType( m_parentTypeId ) ); } return parentTypePtr; } libcmis::ObjectTypePtr OneDriveObjectType::getBaseType( ) { libcmis::ObjectTypePtr baseTypePtr( new OneDriveObjectType( m_baseTypeId ) ); return baseTypePtr; } libcmis-0.5.2/src/libcmis/onedrive-document.hxx0000664000175000017500000000562713407414352016471 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _ONEDRIVE_DOCUMENT_HXX_ #define _ONEDRIVE_DOCUMENT_HXX_ #include #include #include #include "onedrive-object.hxx" #include "json-utils.hxx" class OneDriveDocument : public libcmis::Document, public OneDriveObject { public: OneDriveDocument( OneDriveSession* session ); OneDriveDocument( OneDriveSession* session, Json json, std::string id = std::string( ), std::string name = std::string( ) ); ~OneDriveDocument( ); std::string getType( ) { return std::string( "cmis:document" );} std::string getBaseType( ) { return std::string( "cmis:document" );} virtual std::vector< libcmis::FolderPtr > getParents( ); virtual boost::shared_ptr< std::istream > getContentStream( std::string streamId = std::string( ) ); virtual void setContentStream( boost::shared_ptr< std::ostream > os, std::string contentType, std::string fileName, bool overwrite = true ); virtual libcmis::DocumentPtr checkOut( ); virtual void cancelCheckout( ); virtual libcmis::DocumentPtr checkIn( bool isMajor, std::string comment, const std::map< std::string,libcmis::PropertyPtr >& properties, boost::shared_ptr< std::ostream > stream, std::string contentType, std::string fileName ); virtual std::vector< libcmis::DocumentPtr > getAllVersions( ); }; #endif libcmis-0.5.2/src/libcmis/ws-objectservice.cxx0000664000175000017500000001710013407414352016300 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "ws-objectservice.hxx" #include "ws-requests.hxx" #include "ws-session.hxx" using namespace std; using libcmis::PropertyPtrMap; ObjectService::ObjectService( ) : m_session( NULL ), m_url( "" ) { } ObjectService::ObjectService( WSSession* session ) : m_session( session ), m_url( session->getServiceUrl( "ObjectService" ) ) { } ObjectService::ObjectService( const ObjectService& copy ) : m_session( copy.m_session ), m_url( copy.m_url ) { } ObjectService::~ObjectService( ) { } ObjectService& ObjectService::operator=( const ObjectService& copy ) { if ( this != © ) { m_session = copy.m_session; m_url = copy.m_url; } return *this; } libcmis::ObjectPtr ObjectService::getObject( string repoId, string id ) { libcmis::ObjectPtr object; class GetObject request( repoId, id ); vector< SoapResponsePtr > responses = m_session->soapRequest( m_url, request ); if ( responses.size( ) == 1 ) { SoapResponse* resp = responses.front( ).get( ); GetObjectResponse* response = dynamic_cast< GetObjectResponse* >( resp ); if ( response != NULL ) object = response->getObject( ); } return object; } libcmis::ObjectPtr ObjectService::getObjectByPath( string repoId, string path ) { libcmis::ObjectPtr object; GetObjectByPath request( repoId, path ); vector< SoapResponsePtr > responses = m_session->soapRequest( m_url, request ); if ( responses.size( ) == 1 ) { SoapResponse* resp = responses.front( ).get( ); GetObjectResponse* response = dynamic_cast< GetObjectResponse* >( resp ); if ( response != NULL ) object = response->getObject( ); } return object; } vector< libcmis::RenditionPtr > ObjectService::getRenditions( string repoId, string objectId, string filter ) { vector< libcmis::RenditionPtr > renditions; GetRenditions request( repoId, objectId, filter ); vector< SoapResponsePtr > responses = m_session->soapRequest( m_url, request ); if ( responses.size( ) == 1 ) { SoapResponse* resp = responses.front( ).get( ); GetRenditionsResponse* response = dynamic_cast< GetRenditionsResponse* >( resp ); if ( response != NULL ) { renditions = response->getRenditions( ); } } return renditions; } libcmis::ObjectPtr ObjectService::updateProperties( string repoId, string objectId, const PropertyPtrMap& properties, string changeToken ) { libcmis::ObjectPtr object; UpdateProperties request( repoId, objectId, properties, changeToken ); vector< SoapResponsePtr > responses = m_session->soapRequest( m_url, request ); if ( responses.size( ) == 1 ) { SoapResponse* resp = responses.front( ).get( ); UpdatePropertiesResponse* response = dynamic_cast< UpdatePropertiesResponse* >( resp ); if ( response != NULL ) { string id = response->getObjectId( ); object = getObject( repoId, id ); } } return object; } void ObjectService::deleteObject( string repoId, string id, bool allVersions ) { class DeleteObject request( repoId, id, allVersions ); m_session->soapRequest( m_url, request ); } vector< string > ObjectService::deleteTree( std::string repoId, std::string folderId, bool allVersions, libcmis::UnfileObjects::Type unfile, bool continueOnFailure ) { vector< string > failedIds; DeleteTree request( repoId, folderId, allVersions, unfile, continueOnFailure ); vector< SoapResponsePtr > responses = m_session->soapRequest( m_url, request ); if ( responses.size( ) == 1 ) { SoapResponse* resp = responses.front( ).get( ); DeleteTreeResponse* response = dynamic_cast< DeleteTreeResponse* >( resp ); if ( response != NULL ) failedIds = response->getFailedIds( ); } return failedIds; } void ObjectService::move( string repoId, string objectId, string destId, string srcId ) { MoveObject request( repoId, objectId, destId, srcId ); m_session->soapRequest( m_url, request ); } boost::shared_ptr< istream > ObjectService::getContentStream( string repoId, string objectId ) { boost::shared_ptr< istream > stream; GetContentStream request( repoId, objectId ); vector< SoapResponsePtr > responses = m_session->soapRequest( m_url, request ); if ( responses.size( ) == 1 ) { SoapResponse* resp = responses.front( ).get( ); GetContentStreamResponse* response = dynamic_cast< GetContentStreamResponse* >( resp ); if ( response != NULL ) stream = response->getStream( ); } return stream; } void ObjectService::setContentStream( std::string repoId, std::string objectId, bool overwrite, std::string changeToken, boost::shared_ptr< std::ostream > stream, std::string contentType, std::string fileName ) { SetContentStream request( repoId, objectId, overwrite, changeToken, stream, contentType, fileName ); m_session->soapRequest( m_url, request ); } libcmis::FolderPtr ObjectService::createFolder( string repoId, const PropertyPtrMap& properties, string folderId ) { libcmis::FolderPtr folder; CreateFolder request( repoId, properties, folderId ); vector< SoapResponsePtr > responses = m_session->soapRequest( m_url, request ); if ( responses.size( ) == 1 ) { SoapResponse* resp = responses.front( ).get( ); CreateFolderResponse* response = dynamic_cast< CreateFolderResponse* >( resp ); if ( response != NULL ) { string id = response->getObjectId( ); folder = m_session->getFolder( id ); } } return folder; } libcmis::DocumentPtr ObjectService::createDocument( string repoId, const PropertyPtrMap& properties, string folderId, boost::shared_ptr< ostream > stream, string contentType, string fileName ) { libcmis::DocumentPtr document; CreateDocument request( repoId, properties, folderId, stream, contentType, fileName ); vector< SoapResponsePtr > responses = m_session->soapRequest( m_url, request ); if ( responses.size( ) == 1 ) { SoapResponse* resp = responses.front( ).get( ); CreateFolderResponse* response = dynamic_cast< CreateFolderResponse* >( resp ); if ( response != NULL ) { string id = response->getObjectId( ); libcmis::ObjectPtr object = m_session->getObject( id ); document = boost::dynamic_pointer_cast< libcmis::Document >( object ); } } return document; } libcmis-0.5.2/src/libcmis/oauth2-handler.cxx0000664000175000017500000001152613407414352015645 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "oauth2-handler.hxx" #include #include #include "json-utils.hxx" #include "oauth2-providers.hxx" using namespace std; OAuth2Handler::OAuth2Handler(HttpSession* session, libcmis::OAuth2DataPtr data) : m_session( session ), m_data( data ), m_access( ), m_refresh( ), m_oauth2Parser( ) { if ( !m_data ) m_data.reset( new libcmis::OAuth2Data() ); } OAuth2Handler::OAuth2Handler( const OAuth2Handler& copy ) : m_session( copy.m_session ), m_data( copy.m_data ), m_access( copy.m_access ), m_refresh( copy.m_refresh ), m_oauth2Parser( copy.m_oauth2Parser ) { } OAuth2Handler::OAuth2Handler( ): m_session( NULL ), m_data( ), m_access( ), m_refresh( ), m_oauth2Parser( ) { m_data.reset( new libcmis::OAuth2Data() ); } OAuth2Handler& OAuth2Handler::operator=( const OAuth2Handler& copy ) { if ( this != © ) { m_session = copy.m_session; m_data = copy.m_data; m_access = copy.m_access; m_refresh = copy.m_refresh; m_oauth2Parser = copy.m_oauth2Parser; } return *this; } OAuth2Handler::~OAuth2Handler( ) { } void OAuth2Handler::fetchTokens( string authCode ) { string post = "code=" + authCode + "&client_id=" + m_data->getClientId() + "&client_secret=" + m_data->getClientSecret() + "&redirect_uri=" + m_data->getRedirectUri() + "&grant_type=authorization_code" ; istringstream is( post ); libcmis::HttpResponsePtr resp; try { resp = m_session->httpPostRequest ( m_data->getTokenUrl(), is, "application/x-www-form-urlencoded" ); } catch ( const CurlException& ) { throw libcmis::Exception( "Couldn't get tokens from the authorization code "); } Json jresp = Json::parse( resp->getStream( )->str( ) ); m_access = jresp[ "access_token" ].toString( ); m_refresh = jresp[ "refresh_token" ].toString( ); } void OAuth2Handler::refresh( ) { m_access = string( ); string post = "refresh_token=" + m_refresh + "&client_id=" + m_data->getClientId() + "&client_secret=" + m_data->getClientSecret() + "&grant_type=refresh_token" ; istringstream is( post ); libcmis::HttpResponsePtr resp; try { resp = m_session->httpPostRequest( m_data->getTokenUrl( ), is, "application/x-www-form-urlencoded" ); } catch (const CurlException& ) { throw libcmis::Exception( "Couldn't refresh token "); } Json jresp = Json::parse( resp->getStream( )->str( ) ); m_access = jresp[ "access_token" ].toString(); } string OAuth2Handler::getAuthURL( ) { return m_data->getAuthUrl() + "?scope=" + libcmis::escape( m_data->getScope( ) ) + "&redirect_uri="+ m_data->getRedirectUri( ) + "&response_type=code" + "&client_id=" + m_data->getClientId( ); } string OAuth2Handler::getAccessToken( ) { return m_access; } string OAuth2Handler::getRefreshToken( ) { return m_refresh; } string OAuth2Handler::getHttpHeader( ) { string header; if ( !m_access.empty() ) header = "Authorization: Bearer " + m_access ; return header; } string OAuth2Handler::oauth2Authenticate( ) { string code; if ( m_oauth2Parser ) { code = m_oauth2Parser( m_session, getAuthURL( ), m_session->getUsername( ), m_session->getPassword( ) ); } return code; } void OAuth2Handler::setOAuth2Parser( OAuth2Parser parser ) { m_oauth2Parser = parser; } libcmis-0.5.2/src/libcmis/sharepoint-object.cxx0000664000175000017500000001463013407414352016447 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "sharepoint-object.hxx" #include "sharepoint-allowable-actions.hxx" #include "sharepoint-property.hxx" #include "sharepoint-repository.hxx" #include "sharepoint-utils.hxx" using namespace std; using namespace libcmis; SharePointObject::SharePointObject( SharePointSession* session ) : libcmis::Object( session ) { } SharePointObject::SharePointObject( SharePointSession* session, Json json, string parentId, string name ) : libcmis::Object( session ) { initializeFromJson( json, parentId, name ); } SharePointObject::SharePointObject( const SharePointObject& copy ) : libcmis::Object( copy ) { } SharePointObject& SharePointObject::operator=( const SharePointObject& copy ) { if ( this != © ) { libcmis::Object::operator=( copy ); } return *this; } void SharePointObject::initializeFromJson ( Json json, string parentId, string /*name*/ ) { if ( !json["d"].toString( ).empty( ) ) { // Basic GET requests receive the data inside a "d" object, // but child listing doesn't, so this unifies the representation json = json["d"]; } Json::JsonObject objs = json.getObjects( ); Json::JsonObject::iterator it; PropertyPtr property; bool isFolder = json["__metadata"]["type"].toString( ) == "SP.Folder"; for ( it = objs.begin( ); it != objs.end( ); ++it) { property.reset( new SharePointProperty( it->first, it->second ) ); m_properties[ property->getPropertyType( )->getId()] = property; if ( it->first == "Name" && !isFolder ) { property.reset( new SharePointProperty( "cmis:contentStreamFileName", it->second ) ); m_properties[ property->getPropertyType( )->getId()] = property; } } if ( !parentId.empty( ) ) { // ParentId is not provided in the response property.reset( new SharePointProperty( "cmis:parentId", Json( parentId.c_str( ) ) ) ); m_properties[ property->getPropertyType( )->getId()] = property; } if ( !isFolder ) { string authorUrl = getStringProperty( "Author" ); if ( authorUrl.empty( ) ) { // it's a file version authorUrl = getStringProperty( "CreatedBy" ); } Json authorJson = getSession( )->getJsonFromUrl( authorUrl ); property.reset( new SharePointProperty( "cmis:createdBy", authorJson["d"]["Title"] ) ); m_properties[ property->getPropertyType( )->getId( ) ] = property; } else { // we need to get the creation and lastUpdate time which aren't // provided in the response Json propJson = getSession( )->getJsonFromUrl( getStringProperty( "Properties" ) ); property.reset( new SharePointProperty( "cmis:creationDate", propJson["d"]["vti_x005f_timecreated"] ) ); m_properties[ property->getPropertyType( )->getId( ) ] = property; property.reset( new SharePointProperty( "cmis:lastModificationDate", propJson["d"]["vti_x005f_timelastmodified"] ) ); m_properties[ property->getPropertyType( )->getId( ) ] = property; } m_refreshTimestamp = time( NULL ); m_allowableActions.reset( new SharePointAllowableActions( isFolder ) ); } SharePointSession* SharePointObject::getSession( ) { return dynamic_cast< SharePointSession* > ( m_session ); } void SharePointObject::refreshImpl( Json json ) { m_typeDescription.reset( ); m_properties.clear( ); initializeFromJson( json ); } void SharePointObject::refresh( ) { string res; try { res = getSession( )->httpGetRequest( getId( ) )->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } Json json = Json::parse( res ); refreshImpl( json ); } void SharePointObject::remove( bool /*allVersions*/ ) { try { getSession( )->httpDeleteRequest( getId( ) ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } } vector< string> SharePointObject::getMultiStringProperty( const string& propertyName ) { vector< string > values; PropertyPtrMap::const_iterator it = getProperties( ).find( string( propertyName ) ); if ( it != getProperties( ).end( ) && it->second != NULL && !it->second->getStrings( ).empty( ) ) values = it->second->getStrings( ); return values; } libcmis::ObjectPtr SharePointObject::updateProperties( const PropertyPtrMap& /*properties*/ ) { // there are no updateable properties so just return the same object libcmis::ObjectPtr updated = getSession( )->getObject( getId( ) ); return updated; } void SharePointObject::move( FolderPtr /*source*/, FolderPtr destination ) { if ( !getStringProperty( "cmis:checkinComment" ).empty( ) ) { // only documents can be moved and only documents have this property string url = getId( ) + "/moveto(newurl='"; url += libcmis::escape( destination->getStringProperty( "ServerRelativeUrl" ) ); url += "/" + getStringProperty( "cmis:name" ) + "'"; // overwrite flag url += ",flags=1)"; istringstream is( "" ); try { getSession( )->httpPostRequest( url, is, "" ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } refresh( ); } } libcmis-0.5.2/src/libcmis/oauth2-data.cxx0000664000175000017500000000540013407414352015133 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include using namespace std; namespace libcmis { OAuth2Data::OAuth2Data( ) : m_authUrl( ), m_tokenUrl( ), m_clientId( ), m_clientSecret( ), m_scope( ), m_redirectUri( ) { } OAuth2Data::OAuth2Data( const string& authUrl, const string& tokenUrl, const string& scope, const string& redirectUri, const string& clientId, const string& clientSecret ): m_authUrl( authUrl ), m_tokenUrl( tokenUrl ), m_clientId( clientId ), m_clientSecret( clientSecret ), m_scope( scope ), m_redirectUri( redirectUri ) { } OAuth2Data::OAuth2Data( const OAuth2Data& copy ) : m_authUrl( copy.m_authUrl ), m_tokenUrl( copy.m_tokenUrl ), m_clientId( copy.m_clientId ), m_clientSecret( copy.m_clientSecret ), m_scope( copy.m_scope ), m_redirectUri( copy.m_redirectUri ) { } OAuth2Data::~OAuth2Data( ) { } OAuth2Data& OAuth2Data::operator=( const OAuth2Data& copy ) { if ( this != © ) { m_authUrl = copy.m_authUrl; m_tokenUrl = copy.m_tokenUrl; m_clientId = copy.m_clientId; m_clientSecret = copy.m_clientSecret; m_scope = copy.m_scope; m_redirectUri = copy.m_redirectUri; } return *this; } bool OAuth2Data::isComplete() { return !m_authUrl.empty() && !m_tokenUrl.empty() && !m_clientId.empty() && !m_clientSecret.empty() && !m_scope.empty() && !m_redirectUri.empty(); } } libcmis-0.5.2/src/libcmis/ws-navigationservice.cxx0000664000175000017500000000562213407414352017177 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "ws-navigationservice.hxx" #include "ws-requests.hxx" #include "ws-session.hxx" using namespace std; NavigationService::NavigationService( ) : m_session( NULL ), m_url( "" ) { } NavigationService::NavigationService( WSSession* session ) : m_session( session ), m_url( session->getServiceUrl( "NavigationService" ) ) { } NavigationService::NavigationService( const NavigationService& copy ) : m_session( copy.m_session ), m_url( copy.m_url ) { } NavigationService::~NavigationService( ) { } NavigationService& NavigationService::operator=( const NavigationService& copy ) { if ( this != © ) { m_session = copy.m_session; m_url = copy.m_url; } return *this; } vector< libcmis::FolderPtr > NavigationService::getObjectParents( std::string repoId, std::string objectId ) { vector< libcmis::FolderPtr > parents; GetObjectParents request( repoId, objectId ); vector< SoapResponsePtr > responses = m_session->soapRequest( m_url, request ); if ( responses.size( ) == 1 ) { SoapResponse* resp = responses.front( ).get( ); GetObjectParentsResponse* response = dynamic_cast< GetObjectParentsResponse* >( resp ); if ( response != NULL ) parents = response->getParents( ); } return parents; } vector< libcmis::ObjectPtr > NavigationService::getChildren( string repoId, string folderId ) { vector< libcmis::ObjectPtr > children; GetChildren request( repoId, folderId ); vector< SoapResponsePtr > responses = m_session->soapRequest( m_url, request ); if ( responses.size( ) == 1 ) { SoapResponse* resp = responses.front( ).get( ); GetChildrenResponse* response = dynamic_cast< GetChildrenResponse* >( resp ); if ( response != NULL ) children = response->getChildren( ); } return children; } libcmis-0.5.2/src/libcmis/onedrive-property.cxx0000664000175000017500000000454713407414352016532 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "onedrive-property.hxx" #include #include "onedrive-utils.hxx" using namespace std; using namespace libcmis; OneDriveProperty::OneDriveProperty( ) { } OneDriveProperty::~OneDriveProperty( ) { } OneDriveProperty::OneDriveProperty( const string& key, Json json ): Property( ) { PropertyTypePtr propertyType( new PropertyType( ) ); string convertedKey = OneDriveUtils::toCmisKey( key ); propertyType->setId( convertedKey ); propertyType->setLocalName( convertedKey ); propertyType->setLocalNamespace( convertedKey ); propertyType->setQueryName( convertedKey ); propertyType->setDisplayName( key ); propertyType->setTypeFromJsonType( json.getStrType( ) ); propertyType->setUpdatable( OneDriveUtils::checkUpdatable( key ) ); propertyType->setMultiValued( OneDriveUtils::checkMultiValued( key ) ); setPropertyType( propertyType ); vector< string > values = OneDriveUtils::parseOneDriveProperty( key, json ); setValues( values ); } OneDriveProperty::OneDriveProperty( const OneDriveProperty& copy ) : libcmis::Property( copy ) { } OneDriveProperty& OneDriveProperty::operator=( const OneDriveProperty& copy ) { if ( this != © ) { libcmis::Property::operator=( copy ); } return *this; } libcmis-0.5.2/src/libcmis/sharepoint-repository.hxx0000664000175000017500000000245313407414352017425 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _SHAREPOINT_REPOSITORY_HXX_ #define _SHAREPOINT_REPOSITORY_HXX_ #include class SharePointRepository: public libcmis::Repository { public: SharePointRepository( std::string baseUrl ); }; #endif libcmis-0.5.2/src/libcmis/gdrive-repository.cxx0000664000175000017500000000372313407173247016532 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "gdrive-repository.hxx" GdriveRepository::GdriveRepository( ) : Repository( ) { m_id = "GoogleDrive"; m_name = "Google Drive"; m_description = "Google Drive repository"; m_productName = "Google Drive"; m_productVersion = "v2"; m_rootId = "root"; m_capabilities[ ACL ] = "discover"; m_capabilities[ AllVersionsSearchable ] = "true"; m_capabilities[ Changes ] = "all"; m_capabilities[ GetDescendants ] = "true"; m_capabilities[ GetFolderTree ] = "true"; m_capabilities[ OrderBy ] = "custom"; m_capabilities[ Multifiling ] = "true"; m_capabilities[ PWCSearchable ] = "true"; m_capabilities[ PWCUpdatable ] = "true"; m_capabilities[ Query ] = "bothcombined"; m_capabilities[ Renditions ] = "read"; m_capabilities[ Unfiling ] = "false"; m_capabilities[ VersionSpecificFiling ] = "false"; m_capabilities[ Join ] = "none"; } libcmis-0.5.2/src/libcmis/atom-object.hxx0000664000175000017500000000656313411147221015237 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _ATOM_OBJECT_HXX_ #define _ATOM_OBJECT_HXX_ #include #include #include class AtomPubSession; class AtomLink { private: std::string m_rel; std::string m_type; std::string m_id; std::string m_href; std::map< std::string, std::string > m_others; public: AtomLink( xmlNodePtr node ); std::string getRel( ) const { return m_rel; } std::string getType( ) const { return m_type; } std::string getId( ) const { return m_id; } bool hasId( ) const { return !m_id.empty( ); } std::string getHref( ) const { return m_href; } std::map< std::string, std::string >& getOthers( ) { return m_others; } }; class AtomObject : public virtual libcmis::Object { private: std::vector< AtomLink > m_links; public: AtomObject( AtomPubSession* session ); AtomObject( const AtomObject& copy ); ~AtomObject( ); AtomObject& operator=( const AtomObject& copy ); // Overridden methods from libcmis::Object virtual libcmis::ObjectPtr updateProperties( const std::map< std::string, libcmis::PropertyPtr >& properties ); virtual libcmis::AllowableActionsPtr getAllowableActions( ); /** Reload the data from the server. */ virtual void refresh( ) { refreshImpl( NULL ); } virtual void remove( bool allVersion = true ); virtual void move( boost::shared_ptr< libcmis::Folder > source, boost::shared_ptr< libcmis::Folder > destination ); static void writeAtomEntry( xmlTextWriterPtr writer, const std::map< std::string, libcmis::PropertyPtr >& properties, boost::shared_ptr< std::ostream > os, std::string contentType ); protected: std::string getInfosUrl( ); virtual void refreshImpl( xmlDocPtr doc ); virtual void extractInfos( xmlDocPtr doc ); AtomPubSession* getSession( ); /** Get the atom link corresponding to the given relation and type or NULL if no link matched those criteria. \param rel the relation to match \param type the type to match or the empty string to match all types. */ AtomLink* getLink( std::string rel, std::string type ); }; #endif libcmis-0.5.2/src/libcmis/sharepoint-session.hxx0000664000175000017500000000626613407414352016677 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _SHAREPOINT_SESSION_HXX_ #define _SHAREPOINT_SESSION_HXX_ #include #include "base-session.hxx" #include "json-utils.hxx" class SharePointSession : public BaseSession { public: SharePointSession( std::string baseUrl, std::string username, std::string password, bool verbose = false ); SharePointSession( std::string baseUrl, const HttpSession& httpSession, libcmis::HttpResponsePtr response ); SharePointSession( const SharePointSession& copy ); ~SharePointSession ( ); virtual libcmis::RepositoryPtr getRepository( ); virtual bool setRepository( std::string ); virtual libcmis::ObjectPtr getObject( std::string id ); virtual libcmis::ObjectPtr getObjectByPath( std::string path ); virtual libcmis::ObjectTypePtr getType( std::string id ); virtual std::vector< libcmis::ObjectTypePtr > getBaseTypes( ); libcmis::ObjectPtr getObjectFromJson( Json& jsonRes, std::string parentId = std::string( ) ); Json getJsonFromUrl( std::string url ); void fetchDigestCode( ); void httpRunRequest( std::string url, std::vector< std::string > headers, bool redirect ); libcmis::HttpResponsePtr httpPutRequest( std::string url, std::istream& is, std::vector< std::string > headers ); libcmis::HttpResponsePtr httpPostRequest( const std::string& url, std::istream& is, const std::string& contentType, bool redirect = true ); void httpDeleteRequest( std::string url ); private: SharePointSession( ); void fetchDigestCodeCurl( ); std::string m_digestCode; }; #endif /* _SHAREPONT_SESSION_HXX_ */ libcmis-0.5.2/src/libcmis/sharepoint-property.hxx0000664000175000017500000000333413407414352017071 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _SHAREPOINT_PROPERTY_HXX_ #define _SHAREPOINT_PROPERTY_HXX_ #include #include "json-utils.hxx" // reference: http://msdn.microsoft.com/en-us/library/hh243648.aspx class SharePointProperty : public libcmis::Property { public : // Create a SharePoint Property from a Json property with its key SharePointProperty( const std::string& key, Json json); ~SharePointProperty( ); SharePointProperty( const SharePointProperty& copy); SharePointProperty& operator=( const SharePointProperty& copy ); private : // Avoid calling default constructor SharePointProperty( ); }; #endif libcmis-0.5.2/src/libcmis/gdrive-property.cxx0000664000175000017500000000450713407414352016173 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "gdrive-property.hxx" #include #include "gdrive-utils.hxx" using namespace std; using namespace libcmis; GDriveProperty::GDriveProperty( ) { } GDriveProperty::~GDriveProperty( ) { } GDriveProperty::GDriveProperty( const string& key, Json json ): Property( ) { PropertyTypePtr propertyType( new PropertyType( ) ); string convertedKey = GdriveUtils::toCmisKey( key ); propertyType->setId( convertedKey ); propertyType->setLocalName( convertedKey ); propertyType->setLocalNamespace( convertedKey ); propertyType->setQueryName( convertedKey ); propertyType->setDisplayName( key ); propertyType->setTypeFromJsonType( json.getStrType( ) ); propertyType->setUpdatable( GdriveUtils::checkUpdatable( key ) ); propertyType->setMultiValued( GdriveUtils::checkMultiValued( key ) ); setPropertyType( propertyType ); vector< string > values = GdriveUtils::parseGdriveProperty( key, json ); setValues( values ); } GDriveProperty::GDriveProperty( const GDriveProperty& copy ) : libcmis::Property( copy ) { } GDriveProperty& GDriveProperty::operator=( const GDriveProperty& copy ) { if ( this != © ) { libcmis::Property::operator=( copy ); } return *this; } libcmis-0.5.2/src/libcmis/json-utils.cxx0000664000175000017500000001504313407723631015140 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "json-utils.hxx" #include #include #include #include #include using namespace std; using namespace libcmis; using namespace boost; using boost::property_tree::ptree; using boost::property_tree::json_parser::read_json; using boost::property_tree::json_parser::write_json; Json::Json( ) : m_tJson( ptree( ) ), m_type( json_object ) { } Json::Json( const char *str ) : m_tJson( ptree( ) ), m_type( json_string ) { m_tJson.put_value( str ); m_type = parseType( ); } Json::Json( ptree tJson ) : m_tJson( tJson ), m_type( json_object ) { m_type = parseType( ); } Json::Json( const PropertyPtr& property ): m_tJson( ), m_type( json_object ) { string str = property->toString( ); m_tJson.put("", str ); } Json::Json( const PropertyPtrMap& properties ) : m_tJson( ptree( ) ), m_type( json_array ) { for ( PropertyPtrMap::const_iterator it = properties.begin() ; it != properties.end() ; ++it ) { string key = it->first; string value = it->second->toString( ); m_tJson.put( key, value ); } } Json::Json( const Json& copy ) : m_tJson( copy.m_tJson ), m_type( copy.m_type ) { } Json::Json( const JsonObject& obj ) : m_tJson( ptree( ) ), m_type( json_array ) { for ( JsonObject::const_iterator i = obj.begin() ; i != obj.end() ; ++i ) add( i->first, i->second ) ; } Json::Json( const JsonVector& arr ) : m_tJson( ptree( ) ), m_type( json_array ) { for ( std::vector::const_iterator i = arr.begin(); i != arr.end(); ++i ) add( *i ) ; } Json::~Json( ) { } Json& Json::operator=( const Json& rhs ) { if ( this != &rhs ) { m_tJson = rhs.m_tJson; m_type = rhs.m_type; } return *this ; } void Json::swap( Json& rhs ) { std::swap( m_tJson, rhs.m_tJson ); std::swap( m_type, rhs.m_type ); } Json Json::operator[]( string key ) const { ptree tJson; try { tJson = m_tJson.get_child( key ); } catch ( boost::exception const& ) { return Json( "" ); } Json childJson( tJson ); return childJson ; } void Json::add( const std::string& key, const Json& json ) { try { m_tJson.add_child( key, json.getTree( ) ); } catch ( boost::exception const& ) { throw libcmis::Exception( "Couldn't add Json object" ); } } Json::JsonVector Json::getList() { JsonVector list; for ( const auto &v: m_tJson.get_child("") ) { list.push_back( Json( v.second ) ); } return list ; } void Json::add( const Json& json ) { try { m_tJson.push_back( ptree::value_type( "", json.getTree( )) ); } catch ( boost::exception const& ) { throw libcmis::Exception( "Couldn't add Json object" ); } } Json Json::parse( const string& str ) { ptree pTree; std::stringstream ss( str ); if ( ss.good( ) ) { try { property_tree::json_parser::read_json( ss, pTree ); } catch ( boost::exception const& ) { return Json( str.c_str( ) ); } } return Json( pTree ); } Json::JsonObject Json::getObjects( ) { JsonObject objs; for ( const auto &v: m_tJson.get_child("") ) { Json jsonValue( v.second ); objs.insert( JsonObject::value_type(v.first, jsonValue ) ); } return objs ; } Json::Type Json::parseType( ) { Type type = json_string; string str = toString( ); if ( str.empty( ) ) return type; try { boost::posix_time::ptime time = libcmis::parseDateTime( str ); if ( !time.is_not_a_date_time( ) ) return json_datetime; } catch (...) { // Try other types } Type backupType = type; type = json_bool; try { parseBool( str ); } catch (...) { type = backupType; } if ( type != json_bool ) { if ( str.find('.') == string::npos ) { backupType = type; type = json_int; try { parseInteger( str ); } catch(...) { type = backupType; } } else { backupType = type; type = json_double; try { parseDouble( str ); } catch(...) { type = backupType; } } } return type; } Json::Type Json::getDataType( ) const { return m_type; } string Json::getStrType( ) const { switch ( m_type ) { case json_null: return "json_null"; case json_bool: return "json_bool"; case json_int: return "json_int"; case json_double: return "json_double"; case json_string: return "json_string"; case json_datetime: return "json_datetime"; case json_object: return "json_object"; case json_array: return "json_array"; } return "json_string"; } string Json::toString( ) const { string str; try { stringstream ss; write_json( ss, m_tJson ); str = ss.str( ); } catch ( boost::exception const& ) { str = m_tJson.get_value( ); } // empty json if ( str == "{\n}\n" ) str = ""; return str; } libcmis-0.5.2/src/libcmis/ws-versioningservice.hxx0000664000175000017500000000420413407414352017223 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _WS_VERSIONINGSERVICE_HXX_ #define _WS_VERSIONINGSERVICE_HXX_ #include #include class WSSession; class VersioningService { private: WSSession* m_session; std::string m_url; public: VersioningService( WSSession* session ); VersioningService( const VersioningService& copy ); ~VersioningService( ); VersioningService& operator=( const VersioningService& copy ); libcmis::DocumentPtr checkOut( std::string repoId, std::string documentId ); void cancelCheckOut( std::string repoId, std::string documentId ); libcmis::DocumentPtr checkIn( std::string repoId, std::string objectId, bool isMajor, const std::map< std::string, libcmis::PropertyPtr >& properties, boost::shared_ptr< std::ostream > stream, std::string contentType, std::string fileName, std::string comment ); std::vector< libcmis::DocumentPtr > getAllVersions( std::string repoId, std::string objectId ); private: VersioningService( ); }; #endif libcmis-0.5.2/src/libcmis/ws-versioningservice.cxx0000664000175000017500000001023713407414352017221 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "ws-versioningservice.hxx" #include "ws-requests.hxx" #include "ws-session.hxx" using namespace std; using libcmis::PropertyPtrMap; VersioningService::VersioningService( ) : m_session( NULL ), m_url( "" ) { } VersioningService::VersioningService( WSSession* session ) : m_session( session ), m_url( session->getServiceUrl( "VersioningService" ) ) { } VersioningService::VersioningService( const VersioningService& copy ) : m_session( copy.m_session ), m_url( copy.m_url ) { } VersioningService::~VersioningService( ) { } VersioningService& VersioningService::operator=( const VersioningService& copy ) { if ( this != © ) { m_session = copy.m_session; m_url = copy.m_url; } return *this; } libcmis::DocumentPtr VersioningService::checkOut( string repoId, string documentId ) { libcmis::DocumentPtr pwc; CheckOut request( repoId, documentId ); vector< SoapResponsePtr > responses = m_session->soapRequest( m_url, request ); if ( responses.size( ) == 1 ) { SoapResponse* resp = responses.front( ).get( ); CheckOutResponse* response = dynamic_cast< CheckOutResponse* >( resp ); if ( response != NULL ) { string pwcId = response->getObjectId( ); libcmis::ObjectPtr object = m_session->getObject( pwcId ); pwc = boost::dynamic_pointer_cast< libcmis::Document >( object ); } } return pwc; } void VersioningService::cancelCheckOut( string repoId, string documentId ) { CancelCheckOut request( repoId, documentId ); m_session->soapRequest( m_url, request ); } libcmis::DocumentPtr VersioningService::checkIn( string repoId, string objectId, bool isMajor, const PropertyPtrMap& properties, boost::shared_ptr< ostream > stream, string contentType, string fileName, string comment ) { libcmis::DocumentPtr newVersion; CheckIn request( repoId, objectId, isMajor, properties, stream, contentType, fileName, comment ); vector< SoapResponsePtr > responses = m_session->soapRequest( m_url, request ); if ( responses.size( ) == 1 ) { SoapResponse* resp = responses.front( ).get( ); CheckInResponse* response = dynamic_cast< CheckInResponse* >( resp ); if ( response != NULL ) { string newId = response->getObjectId( ); libcmis::ObjectPtr object = m_session->getObject( newId ); newVersion = boost::dynamic_pointer_cast< libcmis::Document >( object ); } } return newVersion; } vector< libcmis::DocumentPtr > VersioningService::getAllVersions( string repoId, string objectId ) { vector< libcmis::DocumentPtr > versions; GetAllVersions request( repoId, objectId ); vector< SoapResponsePtr > responses = m_session->soapRequest( m_url, request ); if ( responses.size( ) == 1 ) { SoapResponse* resp = responses.front( ).get( ); GetAllVersionsResponse* response = dynamic_cast< GetAllVersionsResponse* >( resp ); if ( response != NULL ) { versions = response->getObjects( ); } } return versions; } libcmis-0.5.2/src/libcmis/ws-requests.cxx0000664000175000017500000010436313407414352015334 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "ws-requests.hxx" #include #include "ws-document.hxx" #include "ws-folder.hxx" #include "ws-object.hxx" #include "ws-object-type.hxx" using namespace std; using libcmis::PropertyPtrMap; CmisSoapFaultDetail::CmisSoapFaultDetail( xmlNodePtr node ) : SoapFaultDetail( ), m_type( ), m_code( 0 ), m_message( ) { // Extract the type, code and message for ( xmlNodePtr child = node->children; child; child = child->next ) { xmlChar* content = xmlNodeGetContent( child ); string value( ( char * )content ); xmlFree( content ); if ( xmlStrEqual( child->name, BAD_CAST( "type" ) ) ) { m_type = value; } else if ( xmlStrEqual( child->name, BAD_CAST( "code" ) ) ) { try { m_code = libcmis::parseInteger( value ); } catch ( const libcmis::Exception& ) { // Simply leave the default error code if unparsable } } else if ( xmlStrEqual( child->name, BAD_CAST( "message" ) ) ) { m_message = value; } } } libcmis::Exception CmisSoapFaultDetail::toException( ) { libcmis::Exception e( m_message, m_type ); return e; } boost::shared_ptr< libcmis::Exception > getCmisException( const SoapFault& fault ) { boost::shared_ptr< libcmis::Exception > exception; vector< SoapFaultDetailPtr > details = fault.getDetail( ); for ( vector< SoapFaultDetailPtr >::iterator it = details.begin( ); it != details.end( ) && exception.get( ) == NULL; ++ it ) { boost::shared_ptr< CmisSoapFaultDetail > cmisDetail = boost::dynamic_pointer_cast< CmisSoapFaultDetail >( *it ); if ( cmisDetail.get( ) != NULL ) exception.reset( new libcmis::Exception( cmisDetail->toException( ) ) ); } return exception; } void writeCmismStream( xmlTextWriterPtr writer, RelatedMultipart& multipart, boost::shared_ptr< ostream > os, string& contentType, string filename ) { // Get the stream as a string istream is( os->rdbuf( ) ); is.seekg( 0, ios::end ); long size = is.tellg( ); is.seekg( 0, ios::beg ); char* buf = new char[ size ]; is.read( buf, size ); string content( buf, size ); delete[ ] buf; xmlTextWriterWriteFormatElement( writer, BAD_CAST( "cmism:length" ), "%ld", static_cast(content.size( )) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:mimeType" ), BAD_CAST( contentType.c_str( ) ) ); if ( !filename.empty( ) ) xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:filename" ), BAD_CAST( filename.c_str( ) ) ); xmlTextWriterStartElement( writer, BAD_CAST( "cmism:stream" ) ); string name( "stream" ); RelatedPartPtr streamPart( new RelatedPart( name, contentType, content ) ); string partHref = "cid:"; partHref += multipart.addPart( streamPart ); xmlTextWriterStartElement( writer, BAD_CAST( "xop:Include" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:xop" ), BAD_CAST( "http://www.w3.org/2004/08/xop/include" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "href" ), BAD_CAST( partHref.c_str( ) ) ); xmlTextWriterEndElement( writer ); // xop:Include xmlTextWriterEndElement( writer ); // cmism:stream } SoapFaultDetailPtr CmisSoapFaultDetail::create( xmlNodePtr node ) { return SoapFaultDetailPtr( new CmisSoapFaultDetail( node ) ); } void GetRepositories::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:getRepositories" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterEndElement( writer ); } SoapResponsePtr GetRepositoriesResponse::create( xmlNodePtr node, RelatedMultipart&, SoapSession* ) { GetRepositoriesResponse* response = new GetRepositoriesResponse( ); // Look for the cmiss:repositories children for ( xmlNodePtr child = node->children; child; child = child->next ) { if ( xmlStrEqual( child->name, BAD_CAST( "repositories" ) ) ) { string id; string name; // Look for repositoryId and repositoryName for ( xmlNodePtr repoChild = child->children; repoChild; repoChild = repoChild->next ) { xmlChar* content = xmlNodeGetContent( repoChild ); string value( ( char* ) content ); xmlFree( content ); if ( xmlStrEqual( repoChild->name, BAD_CAST( "repositoryId" ) ) ) { id = value; } else if ( xmlStrEqual( repoChild->name, BAD_CAST( "repositoryName" ) ) ) { name = value; } } if ( !id.empty( ) ) response->m_repositories[ id ] = name; } } return SoapResponsePtr( response ); } void GetRepositoryInfo::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:getRepositoryInfo" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_id.c_str( ) ) ); xmlTextWriterEndElement( writer ); } SoapResponsePtr GetRepositoryInfoResponse::create( xmlNodePtr node, RelatedMultipart&, SoapSession* ) { GetRepositoryInfoResponse* response = new GetRepositoryInfoResponse( ); for ( xmlNodePtr child = node->children; child; child = child->next ) { if ( xmlStrEqual( child->name, BAD_CAST( "repositoryInfo" ) ) ) { libcmis::RepositoryPtr repository( new libcmis::Repository( child ) ); response->m_repository = repository; } } return SoapResponsePtr( response ); } void GetTypeDefinition::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:getTypeDefinition" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:typeId" ), BAD_CAST( m_typeId.c_str( ) ) ); xmlTextWriterEndElement( writer ); } SoapResponsePtr GetTypeDefinitionResponse::create( xmlNodePtr node, RelatedMultipart&, SoapSession* session ) { GetTypeDefinitionResponse* response = new GetTypeDefinitionResponse( ); WSSession* wsSession = dynamic_cast< WSSession* >( session ); for ( xmlNodePtr child = node->children; child; child = child->next ) { if ( xmlStrEqual( child->name, BAD_CAST( "type" ) ) ) { libcmis::ObjectTypePtr type( new WSObjectType( wsSession, child ) ); response->m_type = type; } } return SoapResponsePtr( response ); } void GetTypeChildren::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:getTypeChildren" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:typeId" ), BAD_CAST( m_typeId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:includePropertyDefinitions" ), BAD_CAST( "true" ) ); xmlTextWriterEndElement( writer ); } SoapResponsePtr GetTypeChildrenResponse::create( xmlNodePtr node, RelatedMultipart&, SoapSession* session ) { GetTypeChildrenResponse* response = new GetTypeChildrenResponse( ); WSSession* wsSession = dynamic_cast< WSSession* >( session ); for ( xmlNodePtr child = node->children; child; child = child->next ) { if ( xmlStrEqual( child->name, BAD_CAST( "types" ) ) ) { for ( xmlNodePtr gdchild = child->children; gdchild; gdchild = gdchild->next ) { if ( xmlStrEqual( gdchild->name, BAD_CAST( "types" ) ) ) { libcmis::ObjectTypePtr type( new WSObjectType( wsSession, gdchild ) ); response->m_children.push_back( type ); } } } } return SoapResponsePtr( response ); } void GetObject::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:getObject" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:objectId" ), BAD_CAST( m_id.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:includeAllowableActions" ), BAD_CAST( "true" ) ); // Ask for renditions... some servers like Alfresco are providing them only this way // and it saves time (another HTTP request) anyway. xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:renditionFilter" ), BAD_CAST( "*" ) ); xmlTextWriterEndElement( writer ); } SoapResponsePtr GetObjectResponse::create( xmlNodePtr node, RelatedMultipart&, SoapSession* session ) { GetObjectResponse* response = new GetObjectResponse( ); WSSession* wsSession = dynamic_cast< WSSession* >( session ); for ( xmlNodePtr child = node->children; child; child = child->next ) { if ( xmlStrEqual( child->name, BAD_CAST( "object" ) ) ) { libcmis::ObjectPtr object; WSObject tmp( wsSession, child ); if ( tmp.getBaseType( ) == "cmis:folder" ) { object.reset( new WSFolder( tmp ) ); } else if ( tmp.getBaseType( ) == "cmis:document" ) { object.reset( new WSDocument( tmp ) ); } else { // This should never happen... but who knows if the standard is 100% repected? object.reset( new WSObject( wsSession, child ) ); } response->m_object = object; } } return SoapResponsePtr( response ); } void GetObjectByPath::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:getObjectByPath" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:path" ), BAD_CAST( m_path.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:includeAllowableActions" ), BAD_CAST( "true" ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:renditionFilter" ), BAD_CAST( "*" ) ); xmlTextWriterEndElement( writer ); } void UpdateProperties::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:updateProperties" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:objectId" ), BAD_CAST( m_objectId.c_str( ) ) ); if ( !m_changeToken.empty( ) ) xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:changeToken" ), BAD_CAST( m_changeToken.c_str( ) ) ); xmlTextWriterStartElement( writer, BAD_CAST( "cmism:properties" ) ); for ( PropertyPtrMap::const_iterator it = m_properties.begin( ); it != m_properties.end( ); ++it ) { libcmis::PropertyPtr property = it->second; if( property->getPropertyType( )->isUpdatable( ) ) property->toXml( writer ); } xmlTextWriterEndElement( writer ); // cmis:properties xmlTextWriterEndElement( writer ); } SoapResponsePtr UpdatePropertiesResponse::create( xmlNodePtr node, RelatedMultipart&, SoapSession* ) { UpdatePropertiesResponse* response = new UpdatePropertiesResponse( ); for ( xmlNodePtr child = node->children; child; child = child->next ) { if ( xmlStrEqual( child->name, BAD_CAST( "objectId" ) ) ) { xmlChar* content = xmlNodeGetContent( child ); if ( content != NULL ) { string value( ( char* ) content ); xmlFree( content ); response->m_id = value; } } } return SoapResponsePtr( response ); } void DeleteObject::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:deleteObject" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:objectId" ), BAD_CAST( m_objectId.c_str( ) ) ); string allVersionsStr( "false" ); if ( m_allVersions ) allVersionsStr = "true"; xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:allVersions" ), BAD_CAST( allVersionsStr.c_str( ) ) ); xmlTextWriterEndElement( writer ); } void DeleteTree::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:deleteTree" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:folderId" ), BAD_CAST( m_folderId.c_str( ) ) ); string allVersionsStr( "false" ); if ( m_allVersions ) allVersionsStr = "true"; xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:allVersions" ), BAD_CAST( allVersionsStr.c_str( ) ) ); string unfileStr( "" ); switch ( m_unfile ) { case libcmis::UnfileObjects::Unfile: unfileStr = "unfile"; break; case libcmis::UnfileObjects::DeleteSingleFiled: unfileStr = "deletesinglefiled"; break; case libcmis::UnfileObjects::Delete: unfileStr = "delete"; break; default: break; } if ( !unfileStr.empty( ) ) xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:unfileObjects" ), BAD_CAST( unfileStr.c_str( ) ) ); string continueStr( "false" ); if ( m_continueOnFailure ) continueStr = "true"; xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:continueOnFailure" ), BAD_CAST( continueStr.c_str( ) ) ); xmlTextWriterEndElement( writer ); } SoapResponsePtr DeleteTreeResponse::create( xmlNodePtr node, RelatedMultipart&, SoapSession* ) { DeleteTreeResponse* response = new DeleteTreeResponse( ); for ( xmlNodePtr child = node->children; child; child = child->next ) { if ( xmlStrEqual( child->name, BAD_CAST( "failedToDelete" ) ) ) { for ( xmlNodePtr gdchild = child->children; gdchild; gdchild = gdchild->next ) { if ( xmlStrEqual( gdchild->name, BAD_CAST( "objectIds" ) ) ) { xmlChar* content = xmlNodeGetContent( gdchild ); if ( content != NULL ) { string value( ( char* ) content ); xmlFree( content ); response->m_failedIds.push_back( value ); } } } } } return SoapResponsePtr( response ); } void MoveObject::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:moveObject" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:objectId" ), BAD_CAST( m_objectId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:targetFolderId" ), BAD_CAST( m_destId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:sourceFolderId" ), BAD_CAST( m_srcId.c_str( ) ) ); xmlTextWriterEndElement( writer ); } void GetContentStream::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:getContentStream" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:objectId" ), BAD_CAST( m_objectId.c_str( ) ) ); xmlTextWriterEndElement( writer ); } SoapResponsePtr GetContentStreamResponse::create( xmlNodePtr node, RelatedMultipart& multipart, SoapSession* ) { GetContentStreamResponse* response = new GetContentStreamResponse( ); for ( xmlNodePtr child = node->children; child; child = child->next ) { if ( xmlStrEqual( child->name, BAD_CAST( "contentStream" ) ) ) { for ( xmlNodePtr gdchild = child->children; gdchild; gdchild = gdchild->next ) { if ( xmlStrEqual( gdchild->name, BAD_CAST( "stream" ) ) ) { xmlChar* content = xmlNodeGetContent( gdchild ); if ( content != NULL ) { // We can either have directly the base64 encoded data or // an pointing to another part of the multipart response->m_stream = getStreamFromNode( gdchild, multipart ); } xmlFree( content ); } } } } return SoapResponsePtr( response ); } void GetObjectParents::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:getObjectParents" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:objectId" ), BAD_CAST( m_objectId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:includeAllowableActions" ), BAD_CAST( "true" ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:renditionFilter" ), BAD_CAST( "*" ) ); xmlTextWriterEndElement( writer ); } SoapResponsePtr GetObjectParentsResponse::create( xmlNodePtr node, RelatedMultipart&, SoapSession* session ) { GetObjectParentsResponse* response = new GetObjectParentsResponse( ); WSSession* wsSession = dynamic_cast< WSSession* >( session ); for ( xmlNodePtr child = node->children; child; child = child->next ) { if ( xmlStrEqual( child->name, BAD_CAST( "parents" ) ) ) { for ( xmlNodePtr gdchild = child->children; gdchild; gdchild = gdchild->next ) { if ( xmlStrEqual( gdchild->name, BAD_CAST( "object" ) ) ) { libcmis::FolderPtr parent; WSObject tmp( wsSession, gdchild ); if ( tmp.getBaseType( ) == "cmis:folder" ) { parent.reset( new WSFolder( tmp ) ); response->m_parents.push_back( parent ); } } } } } return SoapResponsePtr( response ); } void GetChildren::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:getChildren" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:folderId" ), BAD_CAST( m_folderId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:includeAllowableActions" ), BAD_CAST( "true" ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:renditionFilter" ), BAD_CAST( "*" ) ); xmlTextWriterEndElement( writer ); } SoapResponsePtr GetChildrenResponse::create( xmlNodePtr node, RelatedMultipart&, SoapSession* session ) { GetChildrenResponse* response = new GetChildrenResponse( ); WSSession* wsSession = dynamic_cast< WSSession* >( session ); for ( xmlNodePtr child = node->children; child; child = child->next ) { if ( xmlStrEqual( child->name, BAD_CAST( "objects" ) ) ) { for ( xmlNodePtr gdchild = child->children; gdchild; gdchild = gdchild->next ) { if ( xmlStrEqual( gdchild->name, BAD_CAST( "objects" ) ) ) { for ( xmlNodePtr gdgdchild = gdchild->children; gdgdchild; gdgdchild = gdgdchild->next ) { if ( xmlStrEqual( gdgdchild->name, BAD_CAST( "object" ) ) ) { libcmis::ObjectPtr object; WSObject tmp( wsSession, gdgdchild ); if ( tmp.getBaseType( ) == "cmis:folder" ) { object.reset( new WSFolder( tmp ) ); } else if ( tmp.getBaseType( ) == "cmis:document" ) { object.reset( new WSDocument( tmp ) ); } else { // This should never happen... but who knows if the standard is 100% repected? object.reset( new WSObject( wsSession, gdgdchild ) ); } response->m_children.push_back( object ); } } } } } } return SoapResponsePtr( response ); } void CreateFolder::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:createFolder" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterStartElement( writer, BAD_CAST( "cmism:properties" ) ); for ( PropertyPtrMap::const_iterator it = m_properties.begin( ); it != m_properties.end( ); ++it ) { libcmis::PropertyPtr property = it->second; property->toXml( writer ); } xmlTextWriterEndElement( writer ); // cmis:properties xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:folderId" ), BAD_CAST( m_folderId.c_str( ) ) ); xmlTextWriterEndElement( writer ); } SoapResponsePtr CreateFolderResponse::create( xmlNodePtr node, RelatedMultipart&, SoapSession* ) { CreateFolderResponse* response = new CreateFolderResponse( ); for ( xmlNodePtr child = node->children; child; child = child->next ) { if ( xmlStrEqual( child->name, BAD_CAST( "objectId" ) ) ) { xmlChar* content = xmlNodeGetContent( child ); if ( content != NULL ) { string value( ( char* ) content ); xmlFree( content ); response->m_id = value; } } } return SoapResponsePtr( response ); } void CreateDocument::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:createDocument" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterStartElement( writer, BAD_CAST( "cmism:properties" ) ); for ( PropertyPtrMap::const_iterator it = m_properties.begin( ); it != m_properties.end( ); ++it ) { libcmis::PropertyPtr property = it->second; property->toXml( writer ); } xmlTextWriterEndElement( writer ); // cmis:properties xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:folderId" ), BAD_CAST( m_folderId.c_str( ) ) ); xmlTextWriterStartElement( writer, BAD_CAST( "cmism:contentStream" ) ); writeCmismStream( writer, m_multipart, m_stream, m_contentType, m_filename ); xmlTextWriterEndElement( writer ); // cmism:contentStream xmlTextWriterEndElement( writer ); } void SetContentStream::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:setContentStream" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:objectId" ), BAD_CAST( m_objectId.c_str( ) ) ); string overwrite( "false" ); if ( m_overwrite ) overwrite = "true"; xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:overwriteFlag" ), BAD_CAST( overwrite.c_str( ) ) ); if ( !m_changeToken.empty( ) ) xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:changeToken" ), BAD_CAST( m_changeToken.c_str( ) ) ); xmlTextWriterStartElement( writer, BAD_CAST( "cmism:contentStream" ) ); writeCmismStream( writer, m_multipart, m_stream, m_contentType, m_filename ); xmlTextWriterEndElement( writer ); // cmism:contentStream xmlTextWriterEndElement( writer ); } void GetRenditions::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:getRenditions" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:objectId" ), BAD_CAST( m_objectId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:renditionFilter" ), BAD_CAST( m_filter.c_str( ) ) ); xmlTextWriterEndElement( writer ); } SoapResponsePtr GetRenditionsResponse::create( xmlNodePtr node, RelatedMultipart&, SoapSession* ) { GetRenditionsResponse* response = new GetRenditionsResponse( ); for ( xmlNodePtr child = node->children; child; child = child->next ) { if ( xmlStrEqual( child->name, BAD_CAST( "renditions" ) ) ) { libcmis::RenditionPtr rendition( new libcmis::Rendition( child ) ); response->m_renditions.push_back( rendition ); } } return SoapResponsePtr( response ); } void CheckOut::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:checkOut" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:objectId" ), BAD_CAST( m_objectId.c_str( ) ) ); xmlTextWriterEndElement( writer ); } SoapResponsePtr CheckOutResponse::create( xmlNodePtr node, RelatedMultipart&, SoapSession* ) { CheckOutResponse* response = new CheckOutResponse( ); for ( xmlNodePtr child = node->children; child; child = child->next ) { if ( xmlStrEqual( child->name, BAD_CAST( "objectId" ) ) ) { xmlChar* content = xmlNodeGetContent( child ); if ( content != NULL ) { string value( ( char* ) content ); xmlFree( content ); response->m_objectId = value; } } } return SoapResponsePtr( response ); } void CancelCheckOut::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:cancelCheckOut" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:objectId" ), BAD_CAST( m_objectId.c_str( ) ) ); xmlTextWriterEndElement( writer ); } void CheckIn::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:checkIn" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:objectId" ), BAD_CAST( m_objectId.c_str( ) ) ); string major = "false"; if ( m_isMajor ) major = "true"; xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:major" ), BAD_CAST( major.c_str( ) ) ); if ( m_properties.empty( ) ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:properties" ) ); for ( PropertyPtrMap::const_iterator it = m_properties.begin( ); it != m_properties.end( ); ++it ) { libcmis::PropertyPtr property = it->second; property->toXml( writer ); } xmlTextWriterEndElement( writer ); // cmis:properties } if ( m_stream.get( ) ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:contentStream" ) ); writeCmismStream( writer, m_multipart, m_stream, m_contentType, m_fileName ); xmlTextWriterEndElement( writer ); // cmism:contentStream } xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:checkinComment" ), BAD_CAST( m_comment.c_str( ) ) ); xmlTextWriterEndElement( writer ); } SoapResponsePtr CheckInResponse::create( xmlNodePtr node, RelatedMultipart&, SoapSession* ) { CheckInResponse* response = new CheckInResponse( ); for ( xmlNodePtr child = node->children; child; child = child->next ) { if ( xmlStrEqual( child->name, BAD_CAST( "objectId" ) ) ) { xmlChar* content = xmlNodeGetContent( child ); if ( content != NULL ) { string value( ( char* ) content ); xmlFree( content ); response->m_objectId = value; } } } return SoapResponsePtr( response ); } void GetAllVersions::toXml( xmlTextWriterPtr writer ) { xmlTextWriterStartElement( writer, BAD_CAST( "cmism:getAllVersions" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:repositoryId" ), BAD_CAST( m_repositoryId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:objectId" ), BAD_CAST( m_objectId.c_str( ) ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "cmism:includeAllowableActions" ), BAD_CAST( "true" ) ); xmlTextWriterEndElement( writer ); } SoapResponsePtr GetAllVersionsResponse::create( xmlNodePtr node, RelatedMultipart&, SoapSession* session ) { GetAllVersionsResponse* response = new GetAllVersionsResponse( ); WSSession* wsSession = dynamic_cast< WSSession* >( session ); for ( xmlNodePtr child = node->children; child; child = child->next ) { if ( xmlStrEqual( child->name, BAD_CAST( "objects" ) ) ) { WSObject tmp( wsSession, child ); if ( tmp.getBaseType( ) == "cmis:document" ) { libcmis::DocumentPtr object( new WSDocument( tmp ) ); response->m_objects.push_back( object ); } } } return SoapResponsePtr( response ); } libcmis-0.5.2/src/libcmis/onedrive-allowable-actions.hxx0000664000175000017500000001354513407414352020251 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Varga Mihai * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _ONEDRIVE_ALLOWABLE_ACTIONS_HXX_ #define _ONEDRIVE_ALLOWABLE_ACTIONS_HXX_ #include class OneDriveAllowableActions: public libcmis::AllowableActions { public: OneDriveAllowableActions( bool isFolder ) : AllowableActions( ) { m_states.clear( ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::DeleteObject, true ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::UpdateProperties, true ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetProperties, true ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetObjectRelationships, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetObjectParents, true ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::MoveObject, true ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::CreateRelationship, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::ApplyPolicy, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetAppliedPolicies, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::RemovePolicy, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetACL, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::ApplyACL, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetFolderTree, isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetFolderParent, isFolder) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetDescendants, isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::DeleteContentStream, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::CheckOut, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::CancelCheckOut, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::CheckIn, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetContentStream, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::SetContentStream, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetAllVersions, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::AddObjectToFolder, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::RemoveObjectFromFolder, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetRenditions, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetChildren, isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::CreateDocument, isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::CreateFolder, isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::DeleteTree, isFolder ) ); } }; #endif libcmis-0.5.2/src/libcmis/ws-soap.hxx0000664000175000017500000001363513407414352014431 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _WS_SOAP_HXX_ #define _WS_SOAP_HXX_ #include #include #include #include #include #include #include "ws-relatedmultipart.hxx" /** Interface for soap sessions to communicate to response objects. \attention It currently doesn't provide anything, but it may later provide all useful methods for SOAP requests low level handling. */ class SoapSession { public: SoapSession( ) { } virtual ~SoapSession( ) { } }; /** Base class for all SOAP response objects. The factory will need to create the response objects using a static creator method in each class. */ class SoapResponse { public: virtual ~SoapResponse( ) { }; }; typedef boost::shared_ptr< SoapResponse > SoapResponsePtr; typedef SoapResponsePtr ( *SoapResponseCreator ) ( xmlNodePtr, RelatedMultipart&, SoapSession* session ); /** Base clas for SoapFault details parsed data. */ class SoapFaultDetail { public: virtual ~SoapFaultDetail() {}; virtual const std::string toString( ) const { return std::string( ); } }; typedef boost::shared_ptr< SoapFaultDetail > SoapFaultDetailPtr; typedef SoapFaultDetailPtr ( *SoapFaultDetailCreator ) ( xmlNodePtr ); class SoapResponseFactory; /** Class representing a SOAP Fault element, to be used as an exception. */ class SoapFault : public std::exception { private: std::string m_faultcode; std::string m_faultstring; std::vector< SoapFaultDetailPtr > m_detail; std::string m_message; public: SoapFault( xmlNodePtr faultNode, SoapResponseFactory* factory ); virtual ~SoapFault( ) noexcept { }; const std::string& getFaultcode ( ) const { return m_faultcode; } const std::string& getFaultstring ( ) const { return m_faultstring; } std::vector< SoapFaultDetailPtr > getDetail( ) const { return m_detail; } virtual const char* what() const noexcept; }; /** Class parsing the SOAP response message and extracting the SoapResponse objects. */ class SoapResponseFactory { private: std::map< std::string, SoapResponseCreator > m_mapping; std::map< std::string, std::string > m_namespaces; std::map< std::string, SoapFaultDetailCreator > m_detailMapping; SoapSession* m_session; public: SoapResponseFactory( ); SoapResponseFactory( const SoapResponseFactory& copy ); SoapResponseFactory& operator=( const SoapResponseFactory& copy ); void setMapping( std::map< std::string, SoapResponseCreator > mapping ) { m_mapping = mapping; } /** Set the additional namespaces to parse the responses. There is no need to add the soap / wsdl namespaces... they are automatically added. */ void setNamespaces( std::map< std::string, std::string > namespaces ) { m_namespaces = namespaces; } void setDetailMapping( std::map< std::string, SoapFaultDetailCreator > mapping ) { m_detailMapping = mapping; } void setSession( SoapSession* session ) { m_session = session; } /** Get the Soap envelope from the multipart and extract the response objects from it. This method will also read the possible related parts to construct the response. */ std::vector< SoapResponsePtr > parseResponse( RelatedMultipart& multipart ); /** Get the Soap envelope from an XML-only file and extract the response objects from it. */ std::vector< SoapResponsePtr > parseResponse( std::string& xml ); /** Create a SoapResponse object depending on the node we have. This shouldn't be used directly: only from parseResponse or unit tests. */ SoapResponsePtr createResponse( xmlNodePtr node, RelatedMultipart& multipart ); std::vector< SoapFaultDetailPtr > parseFaultDetail( xmlNodePtr detailNode ); }; /** Base class for all SOAP request objects. The implementer's toXml() method needs to take care of two things: \li generate the XML to put in the Soap envelope body \li add the potential attachement to the multipart. There is no need to add the envelope to the multipart: it will automatically be added as the start part of it by getMultipart(). This also means that adding parts to the multipart will have to be done directly on the m_multipart protected member. The RelatedMultipart object is the final result to be used. */ class SoapRequest : public libcmis::XmlSerializable { protected: RelatedMultipart m_multipart; public: SoapRequest( ) : m_multipart( ) { }; virtual ~SoapRequest( ) { }; RelatedMultipart& getMultipart( std::string& username, std::string& password ); protected: std::string createEnvelope( std::string& username, std::string& password ); }; #endif libcmis-0.5.2/src/libcmis/onedrive-property.hxx0000664000175000017500000000345313407414352016532 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _ONEDRIVE_PROPERTY_HXX_ #define _ONEDRIVE_PROPERTY_HXX_ #include #include "json-utils.hxx" // reference: http://msdn.microsoft.com/en-us/library/hh243648.aspx class OneDriveProperty : public libcmis::Property { public : // Create a OneDrive Property from a Json property with its key OneDriveProperty( const std::string& key, Json json); ~OneDriveProperty( ); OneDriveProperty( const OneDriveProperty& copy); OneDriveProperty& operator=( const OneDriveProperty& copy ); // Check if the property is updatable bool checkUpdatable( const std::string& key ); private : // Avoid calling default constructor OneDriveProperty( ); }; #endif libcmis-0.5.2/src/libcmis/atom-folder.hxx0000664000175000017500000000411513407414352015242 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _ATOM_FOLDER_HXX_ #define _ATOM_FOLDER_HXX_ #include #include #include #include "atom-object.hxx" class AtomFolder : public libcmis::Folder, public AtomObject { public: AtomFolder( AtomPubSession* session, xmlNodePtr entryNd ); ~AtomFolder( ); // virtual pure methods from Folder virtual std::vector< libcmis::ObjectPtr > getChildren( ); virtual libcmis::FolderPtr createFolder( const std::map< std::string, libcmis::PropertyPtr >& properties ); virtual libcmis::DocumentPtr createDocument( const std::map< std::string, libcmis::PropertyPtr >& properties, boost::shared_ptr< std::ostream > os, std::string contentType, std::string fileName ); virtual std::vector< std::string > removeTree( bool allVersion = true, libcmis::UnfileObjects::Type unfile = libcmis::UnfileObjects::Delete, bool continueOnError = false ); }; #endif libcmis-0.5.2/src/libcmis/ws-soap.cxx0000664000175000017500000003014213407414352014414 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "ws-soap.hxx" #include #include #include #include #include #include #include using namespace std; using namespace boost::uuids; SoapFault::SoapFault( xmlNodePtr node, SoapResponseFactory* factory ) : exception( ), m_faultcode( ), m_faultstring( ), m_detail( ), m_message( ) { for ( xmlNodePtr child = node->children; child; child = child->next ) { if ( xmlStrEqual( child->name, BAD_CAST( "faultcode" ) ) ) { xmlChar* content = xmlNodeGetContent( child ); xmlChar* prefix = NULL; xmlChar* localName = xmlSplitQName2( content, &prefix ); if (localName == NULL) localName = xmlStrdup( content ); m_faultcode = string( ( char* )localName ); xmlFree( content ); xmlFree( prefix ); xmlFree( localName ); } else if ( xmlStrEqual( child->name, BAD_CAST( "faultstring" ) ) ) { xmlChar* content = xmlNodeGetContent( child ); m_faultstring = string( ( char* )content ); xmlFree( content ); } else if ( xmlStrEqual( child->name, BAD_CAST( "detail" ) ) ) { m_detail = factory->parseFaultDetail( child ); } } m_message = getFaultcode() + ": " + getFaultstring(); for ( vector< SoapFaultDetailPtr >::const_iterator it = m_detail.begin( ); it != m_detail.end( ); ++it ) { m_message += "\n" + ( *it )->toString( ); } } // LCOV_EXCL_START const char* SoapFault::what( ) const noexcept { return m_message.c_str( ); } // LCOV_EXCL_STOP SoapResponseFactory::SoapResponseFactory( ) : m_mapping( ), m_namespaces( ), m_detailMapping( ), m_session( NULL ) { } SoapResponseFactory::SoapResponseFactory( const SoapResponseFactory& copy ) : m_mapping( copy.m_mapping ), m_namespaces( copy.m_namespaces ), m_detailMapping( copy.m_detailMapping ), m_session( copy.m_session ) { } SoapResponseFactory& SoapResponseFactory::operator=( const SoapResponseFactory& copy ) { if ( this != © ) { m_mapping = copy.m_mapping; m_namespaces = copy.m_namespaces; m_detailMapping = copy.m_detailMapping; m_session = copy.m_session; } return *this; } vector< SoapResponsePtr > SoapResponseFactory::parseResponse( string& xml ) { // Create a fake multipart RelatedMultipart multipart; string name = "root"; string type = "text/xml"; string info; RelatedPartPtr part( new RelatedPart( name, type, xml ) ); string cid = multipart.addPart( part ); multipart.setStart( cid, info ); // Then parse it normally return parseResponse( multipart ); } vector< SoapResponsePtr > SoapResponseFactory::parseResponse( RelatedMultipart& multipart ) { string xml; RelatedPartPtr part = multipart.getPart( multipart.getStartId( ) ); if ( part.get() != NULL ) xml = part->getContent( ); vector< SoapResponsePtr > responses; const boost::shared_ptr< xmlDoc > doc( xmlReadMemory( xml.c_str(), xml.size(), "", NULL, 0 ), xmlFreeDoc ); if ( bool( doc ) ) { const boost::shared_ptr< xmlXPathContext > xpathCtx( xmlXPathNewContext( doc.get() ), xmlXPathFreeContext ); libcmis::registerSoapNamespaces( xpathCtx.get() ); for ( map< string, string >::iterator it = m_namespaces.begin( ); it != m_namespaces.end( ); ++it ) { xmlXPathRegisterNs( xpathCtx.get(), BAD_CAST( it->first.c_str() ), BAD_CAST( it->second.c_str( ) ) ); } if ( bool( xpathCtx ) ) { string bodyXPath( "//soap-env:Body/*" ); const boost::shared_ptr< xmlXPathObject > xpathObj( xmlXPathEvalExpression( BAD_CAST( bodyXPath.c_str() ), xpathCtx.get() ), xmlXPathFreeObject ); if ( bool( xpathObj ) ) { int nbChildren = 0; if ( xpathObj->nodesetval ) nbChildren = xpathObj->nodesetval->nodeNr; for ( int i = 0; i < nbChildren; i++ ) { xmlNodePtr node = xpathObj->nodesetval->nodeTab[i]; // Is it a fault? if ( xmlStrEqual( BAD_CAST( NS_SOAP_ENV_URL ), node->ns->href ) && xmlStrEqual( BAD_CAST( "Fault" ), node->name ) ) { throw SoapFault( node, this ); } SoapResponsePtr response = createResponse( node, multipart ); if ( NULL != response.get( ) ) responses.push_back( response ); } } } } return responses; } SoapResponsePtr SoapResponseFactory::createResponse( xmlNodePtr node, RelatedMultipart& multipart ) { SoapResponsePtr response; string ns( ( const char* ) node->ns->href ); string name( ( const char* ) node->name ); string id = "{" + ns + "}" + name; map< string, SoapResponseCreator >::iterator it = m_mapping.find( id ); if ( it != m_mapping.end( ) ) { SoapResponseCreator creator = it->second; response = creator( node, multipart, m_session ); } return response; } vector< SoapFaultDetailPtr > SoapResponseFactory::parseFaultDetail( xmlNodePtr node ) { vector< SoapFaultDetailPtr > detail; for ( xmlNodePtr child = node->children; child; child = child->next ) { string ns; if ( child->ns != NULL ) ns = string( ( const char* ) child->ns->href ); string name( ( const char* ) child->name ); string id = "{" + ns + "}" + name; map< string, SoapFaultDetailCreator >::iterator it = m_detailMapping.find( id ); if ( it != m_detailMapping.end( ) ) { SoapFaultDetailCreator creator = it->second; detail.push_back( creator( child ) ); } } return detail; } RelatedMultipart& SoapRequest::getMultipart( string& username, string& password ) { // Generate the envelope and add it to the multipart string envelope = createEnvelope( username, password ); string name( "root" ); string type( "application/xop+xml;charset=UTF-8;type=\"text/xml\"" ); RelatedPartPtr envelopePart( new RelatedPart( name, type, envelope ) ); string rootId = m_multipart.addPart( envelopePart ); // Set the envelope as the start part of the multipart string startInfo( "text/xml" ); m_multipart.setStart( rootId, startInfo ); return m_multipart; } string SoapRequest::createEnvelope( string& username, string& password ) { xmlBufferPtr buf = xmlBufferCreate( ); xmlTextWriterPtr writer = xmlNewTextWriterMemory( buf, 0 ); xmlTextWriterStartDocument( writer, NULL, NULL, NULL ); /* Sample envelope: 2012-06-14T09:20:29Z 2012-06-15T09:20:29Z admin admin 2012-06-14T09:20:29Z */ xmlChar* wsseUrl = BAD_CAST( "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd" ); xmlChar* wsuUrl = BAD_CAST( "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" ); // Use an unsecure password transmission (PasswordText) because some clients can't support the PasswordDigest. xmlChar* passTypeStr = BAD_CAST( "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText" ); // Created must be a UTC time with no more than 3 digits fractional seconds. boost::posix_time::ptime created( boost::posix_time::second_clock::universal_time( ) ); boost::posix_time::ptime expires( created ); expires = expires + boost::gregorian::days( 1 ); string createdStr = libcmis::writeDateTime( created ); string expiresStr = libcmis::writeDateTime( expires ); xmlTextWriterStartElement( writer, BAD_CAST( "S:Envelope" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:S" ), BAD_CAST( NS_SOAP_ENV_URL ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:wsu" ), wsuUrl ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "xmlns:wsse" ), wsseUrl ); xmlTextWriterStartElement( writer, BAD_CAST( "S:Header" ) ); // Write out the Basic Security Profile 1.0 compliant headers xmlTextWriterStartElement( writer, BAD_CAST( "wsse:Security" ) ); xmlTextWriterStartElement( writer, BAD_CAST( "wsse:Timestamp" ) ); xmlTextWriterStartElement( writer, BAD_CAST( "wsse:Created" ) ); xmlTextWriterWriteRaw( writer, BAD_CAST( createdStr.c_str( ) ) ); xmlTextWriterEndElement( writer ); // End of Created xmlTextWriterStartElement( writer, BAD_CAST( "wsse:Expires" ) ); xmlTextWriterWriteRaw( writer, BAD_CAST( expiresStr.c_str( ) ) ); xmlTextWriterEndElement( writer ); // End of Expires xmlTextWriterEndElement( writer ); // End of Timestamp xmlTextWriterStartElement( writer, BAD_CAST( "wsse:UsernameToken" ) ); xmlTextWriterWriteElement( writer, BAD_CAST( "wsse:Username" ), BAD_CAST( username.c_str( ) ) ); xmlTextWriterStartElement( writer, BAD_CAST( "wsse:Password" ) ); xmlTextWriterWriteAttribute( writer, BAD_CAST( "Type" ), passTypeStr ); xmlTextWriterWriteRaw( writer, BAD_CAST( password.c_str( ) ) ); xmlTextWriterEndElement( writer ); // End of Password xmlTextWriterStartElement( writer, BAD_CAST( "wsu:Created" ) ); xmlTextWriterWriteRaw( writer, BAD_CAST( createdStr.c_str( ) ) ); xmlTextWriterEndElement( writer ); // End of Created xmlTextWriterEndElement( writer ); // End of UsernameToken xmlTextWriterEndElement( writer ); // End of Security xmlTextWriterEndElement( writer ); // End of S:Header xmlTextWriterStartElement( writer, BAD_CAST( "S:Body" ) ); toXml( writer ); xmlTextWriterEndElement( writer ); // End of S:Body xmlTextWriterEndElement( writer ); // End of S:Envelope xmlTextWriterEndDocument( writer ); string str( ( const char * )xmlBufferContent( buf ) ); xmlFreeTextWriter( writer ); xmlBufferFree( buf ); return str; } libcmis-0.5.2/src/libcmis/atom-workspace.hxx0000664000175000017500000000466413407414352015776 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 Cédric Bosdonnat * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _ATOM_WORKSPACE_HXX_ #define _ATOM_WORKSPACE_HXX_ #include #include #include #include #include #include #include #define URI_TEMPLATE_VAR_ID std::string( "id" ) #define URI_TEMPLATE_VAR_PATH std::string( "path" ) struct Collection { enum Type { Root, Types, Query, CheckedOut, Unfiled }; }; struct UriTemplate { enum Type { ObjectById, ObjectByPath, TypeById, Query }; }; class AtomRepository : public libcmis::Repository { private: /// Collections URLs std::map< Collection::Type, std::string > m_collections; /// URI templates std::map< UriTemplate::Type, std::string > m_uriTemplates; public: AtomRepository( xmlNodePtr wsNode = NULL ); AtomRepository( const AtomRepository& rCopy ); ~AtomRepository( ); AtomRepository& operator= ( const AtomRepository& rCopy ); std::string getCollectionUrl( Collection::Type ); std::string getUriTemplate( UriTemplate::Type ); private: void readCollections( xmlNodeSetPtr pNodeSet ); void readUriTemplates( xmlNodeSetPtr pNodeSet ); }; typedef boost::shared_ptr< AtomRepository > AtomRepositoryPtr; #endif libcmis-0.5.2/src/libcmis/ws-objectservice.hxx0000664000175000017500000000652213407414352016313 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _WS_OBJECTSERVICE_HXX_ #define _WS_OBJECTSERVICE_HXX_ #include #include #include #include #include #include #include "base-session.hxx" #include "ws-soap.hxx" class WSSession; class ObjectService { private: WSSession* m_session; std::string m_url; public: ObjectService( WSSession* session ); ObjectService( const ObjectService& copy ); ~ObjectService( ); ObjectService& operator=( const ObjectService& copy ); libcmis::ObjectPtr getObject( std::string repoId, std::string id ); libcmis::ObjectPtr getObjectByPath( std::string repoId, std::string path ); std::vector< libcmis::RenditionPtr > getRenditions( std::string repoId, std::string objectId, std::string filter ); libcmis::ObjectPtr updateProperties( std::string repoId, std::string objectId, const std::map< std::string, libcmis::PropertyPtr > & properties, std::string changeToken ); void deleteObject( std::string repoId, std::string id, bool allVersions ); std::vector< std::string > deleteTree( std::string repoId, std::string folderId, bool allVersions, libcmis::UnfileObjects::Type unfile, bool continueOnFailure ); void move( std::string repoId, std::string objectId, std::string destId, std::string srcId ); boost::shared_ptr< std::istream > getContentStream( std::string repoId, std::string objectId ); void setContentStream( std::string repoId, std::string objectId, bool overwrite, std::string changeToken, boost::shared_ptr< std::ostream > stream, std::string contentType, std::string fileName ); libcmis::FolderPtr createFolder( std::string repoId, const std::map< std::string, libcmis::PropertyPtr >& properties, std::string folderId ); libcmis::DocumentPtr createDocument( std::string repoId, const std::map< std::string, libcmis::PropertyPtr >& properties, std::string folderId, boost::shared_ptr< std::ostream > stream, std::string contentType, std::string fileName ); private: ObjectService( ); }; #endif libcmis-0.5.2/src/libcmis/sharepoint-document.cxx0000664000175000017500000001460113407414352017015 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "sharepoint-document.hxx" #include "sharepoint-session.hxx" #include "sharepoint-utils.hxx" #include "json-utils.hxx" using namespace std; using namespace libcmis; SharePointDocument::SharePointDocument( SharePointSession* session ) : libcmis::Object( session), libcmis::Document( session ), SharePointObject( session ) { } SharePointDocument::SharePointDocument( SharePointSession* session, Json json, string parentId, string name ) : libcmis::Object( session), libcmis::Document( session ), SharePointObject( session, json, parentId, name ) { } SharePointDocument::~SharePointDocument( ) { } vector< libcmis::FolderPtr > SharePointDocument::getParents( ) { vector< libcmis::FolderPtr > parents; string parentId = getStringProperty( "cmis:parentId" ); libcmis::ObjectPtr obj = getSession( )->getObject( parentId ); libcmis::FolderPtr parent = boost::dynamic_pointer_cast< libcmis::Folder >( obj ); parents.push_back( parent ); return parents; } boost::shared_ptr< istream > SharePointDocument::getContentStream( string /*streamId*/ ) { boost::shared_ptr< istream > stream; // file uri + /$value string streamUrl = getId( ) + "/%24value"; try { stream = getSession( )->httpGetRequest( streamUrl )->getStream( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } return stream; } void SharePointDocument::setContentStream( boost::shared_ptr< ostream > os, string contentType, string /*fileName*/, bool /*overwrite*/ ) { if ( !os.get( ) ) throw libcmis::Exception( "Missing stream" ); // file uri + /$value string putUrl = getId( ) + "/%24value"; // Upload stream boost::shared_ptr< istream> is ( new istream ( os->rdbuf( ) ) ); vector headers; headers.push_back( string( "Content-Type: " ) + contentType ); try { getSession()->httpPutRequest( putUrl, *is, headers ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } long httpStatus = getSession( )->getHttpStatus( ); if ( httpStatus < 200 || httpStatus >= 300 ) { throw libcmis::Exception( "Document content wasn't set for" "some reason" ); } refresh( ); } libcmis::DocumentPtr SharePointDocument::checkOut( ) { istringstream is( "" ); string url = getId( ) + "/checkout"; try { getSession( )->httpPostRequest( url, is, "" ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } libcmis::ObjectPtr obj = getSession( )->getObject( getId( ) ); libcmis::DocumentPtr checkout = boost::dynamic_pointer_cast< libcmis::Document > ( obj ); return checkout; } void SharePointDocument::cancelCheckout( ) { istringstream is( "" ); string url = getId( ) + "/undocheckout"; try { getSession( )->httpPostRequest( url, is, "" ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } } libcmis::DocumentPtr SharePointDocument::checkIn( bool isMajor, std::string comment, const PropertyPtrMap& /*properties*/, boost::shared_ptr< std::ostream > stream, std::string contentType, std::string fileName ) { setContentStream( stream, contentType, fileName ); comment = libcmis::escape( comment ); string url = getId( ) + "/checkin(comment='" + comment + "'"; if ( isMajor ) { url += ",checkintype=1)"; } else { url += ",checkintype=0)"; } istringstream is( "" ); try { getSession( )->httpPostRequest( url, is, "" ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } libcmis::ObjectPtr obj = getSession( )->getObject( getId( ) ); libcmis::DocumentPtr checkin = boost::dynamic_pointer_cast< libcmis::Document > ( obj ); return checkin; } vector< libcmis::DocumentPtr > SharePointDocument::getAllVersions( ) { string res; string url = getStringProperty( "Versions" ); vector< libcmis::DocumentPtr > allVersions; try { res = getSession( )->httpGetRequest( url )->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } // adding the latest version libcmis::ObjectPtr obj = getSession( )->getObject( getId( ) ); libcmis::DocumentPtr doc = boost::dynamic_pointer_cast< libcmis::Document > ( obj ); allVersions.push_back( doc ); Json jsonRes = Json::parse( res ); Json::JsonVector objs = jsonRes["d"]["results"].getList( ); for ( unsigned int i = 0; i < objs.size( ); i++) { string versionNumber = objs[i]["ID"].toString( ); string versionId = getId( ) + "/Versions(" + versionNumber + ")"; obj = getSession( )->getObject( versionId ); doc = boost::dynamic_pointer_cast< libcmis::Document > ( obj ); allVersions.push_back( doc ); } return allVersions; } libcmis-0.5.2/src/libcmis/atom-folder.cxx0000664000175000017500000002657713407414352015255 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "atom-folder.hxx" #include #include #include #include "atom-document.hxx" #include "atom-session.hxx" using namespace std; using libcmis::PropertyPtrMap; namespace { } AtomFolder::AtomFolder( AtomPubSession* session, xmlNodePtr entryNd ) : libcmis::Object( session ), libcmis::Folder( session ), AtomObject( session ) { xmlDocPtr doc = libcmis::wrapInDoc( entryNd ); refreshImpl( doc ); xmlFreeDoc( doc ); } AtomFolder::~AtomFolder( ) { } vector< libcmis::ObjectPtr > AtomFolder::getChildren( ) { AtomLink* childrenLink = getLink( "down", "application/atom+xml;type=feed" ); // Some servers aren't giving the GetChildren properly... if not defined, we need to try // as we may have the right to proceed. if ( ( NULL == childrenLink ) || ( getAllowableActions( ).get() && ( !getAllowableActions()->isAllowed( libcmis::ObjectAction::GetChildren ) && getAllowableActions()->isDefined( libcmis::ObjectAction::GetChildren ) ) ) ) throw libcmis::Exception( string( "GetChildren not allowed on node " ) + getId() ); vector< libcmis::ObjectPtr > children; string pageUrl = childrenLink->getHref( ); bool hasNext = true; while ( hasNext ) { string buf; try { buf = getSession()->httpGetRequest( pageUrl )->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } xmlDocPtr doc = xmlReadMemory( buf.c_str(), buf.size(), pageUrl.c_str(), NULL, 0 ); if ( NULL != doc ) { xmlXPathContextPtr xpathCtx = xmlXPathNewContext( doc ); libcmis::registerNamespaces( xpathCtx ); if ( NULL != xpathCtx ) { // Check if there is a next link to handled paged results const string& nextReq( "/atom:feed/atom:link[@rel='next']/attribute::href" ); string nextHref = libcmis::getXPathValue( xpathCtx, nextReq ); hasNext = !nextHref.empty( ); if ( hasNext ) pageUrl = nextHref; // Get the page entries const string& entriesReq( "//atom:entry" ); xmlXPathObjectPtr xpathObj = xmlXPathEvalExpression( BAD_CAST( entriesReq.c_str() ), xpathCtx ); if ( NULL != xpathObj && NULL != xpathObj->nodesetval ) { int size = xpathObj->nodesetval->nodeNr; for ( int i = 0; i < size; i++ ) { xmlNodePtr node = xpathObj->nodesetval->nodeTab[i]; xmlDocPtr entryDoc = libcmis::wrapInDoc( node ); libcmis::ObjectPtr cmisObject = getSession()->createObjectFromEntryDoc( entryDoc ); if ( cmisObject.get() ) children.push_back( cmisObject ); xmlFreeDoc( entryDoc ); } } xmlXPathFreeObject( xpathObj ); } xmlXPathFreeContext( xpathCtx ); } else { throw libcmis::Exception( "Failed to parse folder infos" ); } xmlFreeDoc( doc ); } return children; } libcmis::FolderPtr AtomFolder::createFolder( const PropertyPtrMap& properties ) { AtomLink* childrenLink = getLink( "down", "application/atom+xml;type=feed" ); if ( ( NULL == childrenLink ) || ( getAllowableActions( ).get() && !getAllowableActions()->isAllowed( libcmis::ObjectAction::CreateFolder ) ) ) throw libcmis::Exception( string( "CreateFolder not allowed on folder " ) + getId(), "permissionDenied" ); xmlBufferPtr buf = xmlBufferCreate( ); xmlTextWriterPtr writer = xmlNewTextWriterMemory( buf, 0 ); xmlTextWriterStartDocument( writer, NULL, NULL, NULL ); // Copy and remove the readonly properties before serializing boost::shared_ptr< ostream > stream; AtomObject::writeAtomEntry( writer, properties, stream, string( ) ); xmlTextWriterEndDocument( writer ); string str( ( const char * )xmlBufferContent( buf ) ); istringstream is( str ); xmlFreeTextWriter( writer ); xmlBufferFree( buf ); libcmis::HttpResponsePtr response; try { response = getSession( )->httpPostRequest( childrenLink->getHref( ), is, "application/atom+xml;type=entry" ); } catch ( const CurlException& e ) { /* 409 here is more likely to be a constraint error */ if ( e.getHttpStatus() == 409 ) { throw libcmis::Exception( e.what(), "constraint" ); } throw e.getCmisException( ); } string respBuf = response->getStream( )->str( ); xmlDocPtr doc = xmlReadMemory( respBuf.c_str(), respBuf.size(), getInfosUrl().c_str(), NULL, 0 ); if ( NULL == doc ) throw libcmis::Exception( "Failed to parse object infos" ); libcmis::ObjectPtr created = getSession( )->createObjectFromEntryDoc( doc, AtomPubSession::RESULT_FOLDER ); xmlFreeDoc( doc ); libcmis::FolderPtr newFolder = boost::dynamic_pointer_cast< libcmis::Folder >( created ); if ( !newFolder.get( ) ) throw libcmis::Exception( string( "Created object is not a folder: " ) + created->getId( ), "constraint" ); return newFolder; } libcmis::DocumentPtr AtomFolder::createDocument( const PropertyPtrMap& properties, boost::shared_ptr< ostream > os, string contentType, string ) { AtomLink* childrenLink = getLink( "down", "application/atom+xml;type=feed" ); if ( ( NULL == childrenLink ) || ( getAllowableActions( ).get() && !getAllowableActions()->isAllowed( libcmis::ObjectAction::CreateDocument ) && getAllowableActions()->isDefined( libcmis::ObjectAction::CreateDocument ) ) ) throw libcmis::Exception( string( "CreateDocument not allowed on folder " ) + getId() ); stringstream ss; xmlOutputBufferPtr buf = xmlOutputBufferCreateIO(libcmis::stringstream_write_callback, NULL, &ss, NULL); xmlTextWriterPtr writer = xmlNewTextWriter(buf); xmlTextWriterStartDocument( writer, NULL, NULL, NULL ); AtomObject::writeAtomEntry( writer, properties, os, contentType ); xmlTextWriterEndDocument( writer ); xmlFreeTextWriter( writer ); libcmis::HttpResponsePtr response; try { response = getSession( )->httpPostRequest( childrenLink->getHref( ), ss, "application/atom+xml;type=entry" ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } string respBuf = response->getStream( )->str( ); boost::shared_ptr< xmlDoc > doc( xmlReadMemory( respBuf.c_str(), respBuf.size(), getInfosUrl().c_str(), NULL, XML_PARSE_NOERROR ), xmlFreeDoc ); if ( !doc ) { // We may not have the created document entry in the response body: this is // the behaviour of some servers, but the standard says we need to look for // the Location header. map< string, string >& headers = response->getHeaders( ); map< string, string >::iterator it = headers.find( "Location" ); // Some servers like Lotus Live aren't sending Location header, but Content-Location if ( it == headers.end( ) ) it = headers.find( "Content-Location" ); if ( it != headers.end() ) { try { response = getSession( )->httpGetRequest( it->second ); respBuf = response->getStream( )->str( ); doc.reset( xmlReadMemory( respBuf.c_str(), respBuf.size(), getInfosUrl().c_str(), NULL, XML_PARSE_NOERROR ), xmlFreeDoc ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } } // if doc is still NULL after that, then throw an exception if ( !doc ) throw libcmis::Exception( "Missing expected response from server" ); } libcmis::ObjectPtr created = getSession( )->createObjectFromEntryDoc( doc.get(), AtomPubSession::RESULT_DOCUMENT ); libcmis::DocumentPtr newDocument = boost::dynamic_pointer_cast< libcmis::Document >( created ); if ( !newDocument.get( ) ) throw libcmis::Exception( string( "Created object is not a document: " ) + created->getId( ) ); return newDocument; } vector< string > AtomFolder::removeTree( bool allVersions, libcmis::UnfileObjects::Type unfile, bool continueOnError ) { AtomLink* treeLink = getLink( "down", "application/cmistree+xml" ); if ( NULL == treeLink ) treeLink = getLink( "http://docs.oasis-open.org/ns/cmis/link/200908/foldertree", "application/cmistree+xml" ); if ( ( NULL == treeLink ) || ( getAllowableActions( ).get() && !getAllowableActions()->isAllowed( libcmis::ObjectAction::DeleteTree ) ) ) throw libcmis::Exception( string( "DeleteTree not allowed on folder " ) + getId() ); try { string deleteUrl = treeLink->getHref( ); if ( deleteUrl.find( '?' ) != string::npos ) deleteUrl += "&"; else deleteUrl += "?"; // Add the all versions parameter string allVersionsStr = "TRUE"; if ( !allVersions ) allVersionsStr = "FALSE"; deleteUrl += "allVersions=" + allVersionsStr; // Add the unfileObjects parameter string unfileStr; switch ( unfile ) { case libcmis::UnfileObjects::Delete: unfileStr = "delete"; break; case libcmis::UnfileObjects::DeleteSingleFiled: unfileStr = "deletesinglefiled"; break; case libcmis::UnfileObjects::Unfile: unfileStr = "unfile"; break; default: break; } deleteUrl += "&unfileObjects=" + unfileStr; // Add the continueOnFailure parameter string continueOnErrorStr = "TRUE"; if ( !continueOnError ) continueOnErrorStr = "FALSE"; deleteUrl += "&continueOnFailure=" + continueOnErrorStr; getSession( )->httpDeleteRequest( deleteUrl ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } // TODO Implement getting the failedIDs using a GET request on the same URL return vector< string >( ); } libcmis-0.5.2/src/libcmis/onedrive-utils.cxx0000664000175000017500000000767213407414352016010 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "onedrive-utils.hxx" #include #include "json-utils.hxx" using namespace std; using libcmis::PropertyPtrMap; string OneDriveUtils::toCmisKey( const string& key ) { string convertedKey; if ( key == "id") convertedKey = "cmis:objectId"; else if ( key == "from" ) convertedKey = "cmis:createdBy"; else if ( key == "description" ) convertedKey = "cmis:description"; else if ( key == "created_time" ) convertedKey = "cmis:creationDate"; else if ( key == "updated_time" ) convertedKey = "cmis:lastModificationDate"; else if ( key == "name" ) convertedKey = "cmis:name"; else if ( key == "size" ) convertedKey = "cmis:contentStreamLength"; else if ( key == "parent_id" ) convertedKey = "cmis:parentId"; else convertedKey = key; return convertedKey; } string OneDriveUtils::toOneDriveKey( const string& key ) { string convertedKey; if ( key == "cmis:objectId") convertedKey = "id"; else if ( key == "cmis:createdBy" ) convertedKey = "from"; else if ( key == "cmis:creationDate" ) convertedKey = "created_time"; else if ( key == "cmis:description" ) convertedKey = "description"; else if ( key == "cmis:lastModificationDate" ) convertedKey = "updated_time"; else if ( key == "cmis:name" ) convertedKey = "name"; else if ( key == "cmis:contentStreamLength" ) convertedKey = "file_size"; else if ( key == "cmis:parentId" ) convertedKey = "parent_id"; else convertedKey = key; return convertedKey; } bool OneDriveUtils::checkUpdatable( const std::string& key) { bool updatable = ( key == "name" || key == "description" ); return updatable; } bool OneDriveUtils::checkMultiValued( const string& key ) { bool bMultiValued = ( key == "from" || key == "shared_with" ); return bMultiValued; } vector< string > OneDriveUtils::parseOneDriveProperty( string key, Json json ) { vector< string > values; if ( key == "from" ) { string ownerName = json["name"].toString( ); values.push_back( ownerName); } else if ( key == "shared_with" ) { string sharedWith = json["access"].toString( ); values.push_back( sharedWith ); } else values.push_back( json.toString( ) ); return values; } Json OneDriveUtils::toOneDriveJson( const PropertyPtrMap& properties ) { Json propsJson; for ( PropertyPtrMap::const_iterator it = properties.begin() ; it != properties.end() ; ++it ) { string key = toOneDriveKey( it->first ); Json value( it->second ); // Convert the key back to the onedrive key if ( checkUpdatable( key ) ) { propsJson.add( key, value ); } } return propsJson; } libcmis-0.5.2/src/libcmis/ws-object.cxx0000664000175000017500000000752713407414352014733 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "ws-object.hxx" #include "ws-document.hxx" #include "ws-folder.hxx" using namespace std; using libcmis::PropertyPtrMap; WSObject::WSObject( WSSession* session ) : libcmis::Object( session ) { } WSObject::WSObject( WSSession* session, xmlNodePtr node ) : libcmis::Object( session, node ) { } WSObject::WSObject( const WSObject& copy ) : libcmis::Object( copy ) { } WSObject::~WSObject( ) { } WSObject& WSObject::operator=( const WSObject& copy ) { if ( this != © ) { libcmis::Object::operator=( copy ); } return *this; } vector< libcmis::RenditionPtr > WSObject::getRenditions( string filter ) { // Check that the server supports that optional feature. There is no need to check it // when getting the object as we may get them by shear luck libcmis::RepositoryPtr repo = getSession( )->getRepository( ); bool isCapable = repo && repo->getCapability( libcmis::Repository::Renditions ) == "read"; if ( m_renditions.empty() && isCapable ) { string repoId = getSession( )->getRepositoryId( ); m_renditions = getSession( )->getObjectService( ).getRenditions( repoId, this->getId( ), filter ); } return m_renditions; } libcmis::ObjectPtr WSObject::updateProperties( const PropertyPtrMap& properties ) { // No need to send HTTP request if there is nothing to update if ( properties.empty( ) ) { libcmis::ObjectPtr object; if ( getBaseType( ) == "cmis:document" ) { const WSDocument& thisDoc = dynamic_cast< const WSDocument& >( *this ); object.reset( new WSDocument( thisDoc ) ); } else if ( getBaseType( ) == "cmis:folder" ) { const WSFolder& thisFolder = dynamic_cast< const WSFolder& >( *this ); object.reset( new WSFolder( thisFolder ) ); } return object; } string repoId = getSession( )->getRepositoryId( ); return getSession( )->getObjectService( ).updateProperties( repoId, this->getId( ), properties, this->getChangeToken( ) ); } void WSObject::refresh( ) { libcmis::ObjectPtr object = m_session->getObject( getId( ) ); WSObject* const other = dynamic_cast< WSObject* >( object.get( ) ); if ( other != NULL ) *this = *other; } void WSObject::remove( bool allVersions ) { string repoId = getSession( )->getRepositoryId( ); getSession( )->getObjectService( ).deleteObject( repoId, this->getId( ), allVersions ); } void WSObject::move( libcmis::FolderPtr source, libcmis::FolderPtr destination ) { string repoId = getSession( )->getRepositoryId( ); getSession( )->getObjectService( ).move( repoId, getId( ), destination->getId( ), source->getId( ) ); refresh( ); } WSSession* WSObject::getSession( ) { return dynamic_cast< WSSession* >( m_session ); } libcmis-0.5.2/src/libcmis/atom-session.cxx0000664000175000017500000002634313407414352015454 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "atom-session.hxx" #include #include #include #include #include #include #include #include "atom-document.hxx" #include "atom-folder.hxx" #include "atom-object-type.hxx" using namespace std; AtomPubSession::AtomPubSession( string atomPubUrl, string repositoryId, string username, string password, bool noSslCheck, libcmis::OAuth2DataPtr oauth2, bool verbose ) : BaseSession( atomPubUrl, repositoryId, username, password, noSslCheck, oauth2, verbose ), m_repository( ) { libcmis::HttpResponsePtr response; initialize( response ); } AtomPubSession::AtomPubSession( string atomPubUrl, string repositoryId, const HttpSession& httpSession, libcmis::HttpResponsePtr response ) : BaseSession( atomPubUrl, repositoryId, httpSession ), m_repository( ) { initialize( response ); } AtomPubSession::AtomPubSession( const AtomPubSession& copy ) : BaseSession( copy ), m_repository( copy.m_repository ) { } AtomPubSession::AtomPubSession( ) : BaseSession( ), m_repository( ) { } AtomPubSession& AtomPubSession::operator=( const AtomPubSession& copy ) { if ( this != © ) { BaseSession::operator=( copy ); m_repository = copy.m_repository; } return *this; } AtomPubSession::~AtomPubSession( ) { } void AtomPubSession::parseServiceDocument( const string& buf ) { // parse the content const boost::shared_ptr< xmlDoc > doc( xmlReadMemory( buf.c_str(), buf.size(), m_bindingUrl.c_str(), NULL, 0 ), xmlFreeDoc ); if ( bool( doc ) ) { // Check that we have an AtomPub service document xmlNodePtr root = xmlDocGetRootElement( doc.get() ); if ( !xmlStrEqual( root->name, BAD_CAST( "service" ) ) ) throw libcmis::Exception( "Not an atompub service document" ); xmlXPathContextPtr xpathCtx = xmlXPathNewContext( doc.get() ); // Register the Service Document namespaces libcmis::registerNamespaces( xpathCtx ); if ( NULL != xpathCtx ) { string workspacesXPath( "//app:workspace" ); xmlXPathObjectPtr xpathObj = xmlXPathEvalExpression( BAD_CAST( workspacesXPath.c_str() ), xpathCtx ); if ( xpathObj != NULL ) { int nbWorkspaces = 0; if ( xpathObj->nodesetval ) nbWorkspaces = xpathObj->nodesetval->nodeNr; for ( int i = 0; i < nbWorkspaces; i++ ) { try { AtomRepositoryPtr ws( new AtomRepository( xpathObj->nodesetval->nodeTab[i] ) ); // Check if we have a repository set if ( m_repositoryId.empty( ) && i == 0 ) m_repositoryId = ws->getId( ); // SharePoint is case insensitive for the id... if ( boost::to_lower_copy( ws->getId( ) ) == boost::to_lower_copy( m_repositoryId ) ) m_repository = ws; m_repositories.push_back( ws ); } catch ( const libcmis::Exception& ) { // Invalid repository, don't take care of this } } } xmlXPathFreeObject( xpathObj ); } xmlXPathFreeContext( xpathCtx ); } else throw libcmis::Exception( "Failed to parse service document" ); } void AtomPubSession::initialize( libcmis::HttpResponsePtr response ) { if ( m_repositories.empty() ) { // Pull the content from sAtomPubUrl string buf; if ( response ) { buf = response->getStream( )->str( ); } else { try { buf = httpGetRequest( m_bindingUrl )->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } } parseServiceDocument( buf ); } } AtomRepositoryPtr AtomPubSession::getAtomRepository( ) { return m_repository; } libcmis::RepositoryPtr AtomPubSession::getRepository( ) { return getAtomRepository( ); } bool AtomPubSession::setRepository( string repositoryId ) { vector< libcmis::RepositoryPtr > repos = getRepositories( ); bool found = false; for ( vector< libcmis::RepositoryPtr >::iterator it = repos.begin(); it != repos.end() && !found; ++it ) { libcmis::RepositoryPtr repo = *it; if ( repo->getId() == repositoryId ) { AtomRepositoryPtr atomRepo = boost::dynamic_pointer_cast< AtomRepository >( repo ); m_repository = atomRepo; m_repositoryId = repositoryId; found = true; } } return found; } libcmis::ObjectPtr AtomPubSession::createObjectFromEntryDoc( xmlDocPtr doc, ResultObjectType res ) { libcmis::ObjectPtr cmisObject; if ( NULL != doc ) { // Get the atom:entry node xmlXPathContextPtr xpathCtx = xmlXPathNewContext( doc ); libcmis::registerNamespaces( xpathCtx ); if ( NULL != xpathCtx ) { const string& entriesReq( "//atom:entry" ); xmlXPathObjectPtr xpathObj = xmlXPathEvalExpression( BAD_CAST( entriesReq.c_str() ), xpathCtx ); if ( NULL != xpathObj && NULL != xpathObj->nodesetval && ( 0 < xpathObj->nodesetval->nodeNr ) ) { // Get the entry's base type string baseTypeReq = "//atom:entry[1]//cmis:propertyId[@propertyDefinitionId='cmis:baseTypeId']/cmis:value/text()"; string baseType = libcmis::getXPathValue( xpathCtx, baseTypeReq ); xmlNodePtr node = xpathObj->nodesetval->nodeTab[0]; if ( res == RESULT_FOLDER || baseType == "cmis:folder" ) { cmisObject.reset( new AtomFolder( this, node ) ); } else if ( res == RESULT_DOCUMENT || baseType == "cmis:document" ) { cmisObject.reset( new AtomDocument( this, node ) ); } else { // Not a valid CMIS atom entry... weird } } xmlXPathFreeObject( xpathObj ); } xmlXPathFreeContext( xpathCtx ); } return cmisObject; } libcmis::ObjectPtr AtomPubSession::getObject( string id ) { string pattern = getAtomRepository()->getUriTemplate( UriTemplate::ObjectById ); map< string, string > vars; vars[URI_TEMPLATE_VAR_ID] = id; vars[string( "includeAllowableActions" )] = string( "true" ); string url = createUrl( pattern, vars ); try { string buf = httpGetRequest( url )->getStream( )->str( ); xmlDocPtr doc = xmlReadMemory( buf.c_str(), buf.size(), url.c_str(), NULL, 0 ); libcmis::ObjectPtr cmisObject = createObjectFromEntryDoc( doc ); xmlFreeDoc( doc ); return cmisObject; } catch ( const CurlException& e ) { if ( ( e.getErrorCode( ) == CURLE_HTTP_RETURNED_ERROR ) && ( e.getHttpStatus( ) == 404 ) ) { string msg = "No such node: "; msg += id; throw libcmis::Exception( msg, "objectNotFound" ); } else throw e.getCmisException(); } } libcmis::ObjectPtr AtomPubSession::getObjectByPath( string path ) { string pattern = getAtomRepository()->getUriTemplate( UriTemplate::ObjectByPath ); map< string, string > vars; vars[URI_TEMPLATE_VAR_PATH] = path; vars[string( "includeAllowableActions" )] = string( "true" ); string url = createUrl( pattern, vars ); try { string buf = httpGetRequest( url )->getStream( )->str( ); xmlDocPtr doc = xmlReadMemory( buf.c_str(), buf.size(), url.c_str(), NULL, 0 ); libcmis::ObjectPtr cmisObject = createObjectFromEntryDoc( doc ); xmlFreeDoc( doc ); return cmisObject; } catch ( const CurlException& e ) { if ( ( e.getErrorCode( ) == CURLE_HTTP_RETURNED_ERROR ) && ( e.getHttpStatus( ) == 404 ) ) { string msg = "No node corresponding to path: "; msg += path; throw libcmis::Exception( msg, "objectNotFound" ); } else throw e.getCmisException(); } } libcmis::ObjectTypePtr AtomPubSession::getType( string id ) { libcmis::ObjectTypePtr type( new AtomObjectType( this, id ) ); return type; } vector< libcmis::ObjectTypePtr > AtomPubSession::getBaseTypes( ) { string url = getAtomRepository( )->getCollectionUrl( Collection::Types ); return getChildrenTypes( url ); } vector< libcmis::ObjectTypePtr > AtomPubSession::getChildrenTypes( string url ) { vector< libcmis::ObjectTypePtr > children; string buf; try { buf = httpGetRequest( url )->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } xmlDocPtr doc = xmlReadMemory( buf.c_str(), buf.size(), url.c_str(), NULL, 0 ); if ( NULL != doc ) { xmlXPathContextPtr xpathCtx = xmlXPathNewContext( doc ); libcmis::registerNamespaces( xpathCtx ); if ( NULL != xpathCtx ) { const string& entriesReq( "//atom:entry" ); xmlXPathObjectPtr xpathObj = xmlXPathEvalExpression( BAD_CAST( entriesReq.c_str() ), xpathCtx ); if ( NULL != xpathObj && NULL != xpathObj->nodesetval ) { int size = xpathObj->nodesetval->nodeNr; for ( int i = 0; i < size; i++ ) { xmlNodePtr node = xpathObj->nodesetval->nodeTab[i]; libcmis::ObjectTypePtr type( new AtomObjectType( this, node ) ); children.push_back( type ); } } xmlXPathFreeObject( xpathObj ); } xmlXPathFreeContext( xpathCtx ); } else { throw libcmis::Exception( "Failed to parse type children infos" ); } xmlFreeDoc( doc ); return children; } libcmis-0.5.2/src/libcmis/session-factory.cxx0000664000175000017500000001265713407414352016166 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include "atom-session.hxx" #include "gdrive-session.hxx" #include "onedrive-session.hxx" #include "sharepoint-session.hxx" #include "ws-session.hxx" using namespace std; namespace libcmis { AuthProviderPtr SessionFactory::s_authProvider; OAuth2AuthCodeProvider SessionFactory::s_oauth2AuthCodeProvider; string SessionFactory::s_proxy; string SessionFactory::s_noProxy; string SessionFactory::s_proxyUser; string SessionFactory::s_proxyPass; CertValidationHandlerPtr SessionFactory::s_certValidationHandler; void SessionFactory::setProxySettings( string proxy, string noProxy, string proxyUser, string proxyPass ) { SessionFactory::s_proxy = proxy; SessionFactory::s_noProxy = noProxy; SessionFactory::s_proxyUser = proxyUser; SessionFactory::s_proxyPass = proxyPass; } Session* SessionFactory::createSession( string bindingUrl, string username, string password, string repository, bool noSslCheck, libcmis::OAuth2DataPtr oauth2, bool verbose ) { Session* session = NULL; if ( !bindingUrl.empty( ) ) { // Try the special cases based on the binding URL if ( bindingUrl == "https://www.googleapis.com/drive/v2" ) { session = new GDriveSession( bindingUrl, username, password, oauth2, verbose ); } else if ( bindingUrl == "https://apis.live.net/v5.0" ) { session = new OneDriveSession( bindingUrl, username, password, oauth2, verbose); } else { libcmis::HttpResponsePtr response; boost::shared_ptr< HttpSession> httpSession( new HttpSession( username, password, noSslCheck, oauth2, verbose ) ); try { response = httpSession->httpGetRequest( bindingUrl ); } catch ( const CurlException& ) { // Could be SharePoint - needs NTLM authentication session = new SharePointSession( bindingUrl, username, password, verbose ); } // Try the CMIS cases: we need to autodetect the binding type if ( session == NULL ) { try { session = new AtomPubSession( bindingUrl, repository, *httpSession, response ); } catch ( const Exception& ) { } } if ( session == NULL ) { // We couldn't get an AtomSession, we may have an URL for the WebService binding try { session = new WSSession( bindingUrl, repository, *httpSession, response ); } catch ( const Exception& ) { } } if ( session == NULL ) { // Maybe the first request didn't throw an exception and the authentication // succeeded so we need to double check for SharePoint try { session = new SharePointSession( bindingUrl, *httpSession, response ); } catch ( const Exception& ) { } } } } return session; } vector< RepositoryPtr > SessionFactory::getRepositories( string bindingUrl, string username, string password, bool verbose ) { vector< RepositoryPtr > repos; Session* session = createSession( bindingUrl, username, password, string(), false, OAuth2DataPtr(), verbose ); if ( session != NULL ) { repos = session->getRepositories( ); delete session; } return repos; } } libcmis-0.5.2/src/libcmis/atom-object-type.hxx0000664000175000017500000000376313407414352016224 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _ATOM_OBJECT_TYPE_HXX_ #define _ATOM_OBJECT_TYPE_HXX_ #include #include "atom-session.hxx" class AtomObjectType : public libcmis::ObjectType { private: AtomPubSession* m_session; std::string m_selfUrl; std::string m_childrenUrl; public: AtomObjectType( AtomPubSession* session, std::string id ); AtomObjectType( AtomPubSession* session, xmlNodePtr node ); AtomObjectType( const AtomObjectType& copy ); virtual ~AtomObjectType( ); AtomObjectType& operator=( const AtomObjectType& copy ); virtual void refresh( ) { refreshImpl( NULL ); } virtual libcmis::ObjectTypePtr getParentType( ); virtual libcmis::ObjectTypePtr getBaseType( ); virtual std::vector< libcmis::ObjectTypePtr > getChildren( ); private: void refreshImpl( xmlDocPtr doc ); void extractInfos( xmlDocPtr doc ); }; #endif libcmis-0.5.2/src/libcmis/base-session.cxx0000664000175000017500000001055113407414352015420 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "base-session.hxx" #include #include #include #include #include #include #include #include "oauth2-handler.hxx" using namespace std; BaseSession::BaseSession( string bindingUrl, string repositoryId, string username, string password, bool noSslCheck, libcmis::OAuth2DataPtr oauth2, bool verbose ) : Session( ), HttpSession( username, password, noSslCheck, oauth2, verbose ), m_bindingUrl( bindingUrl ), m_repositoryId( repositoryId ), m_repositories( ) { } BaseSession::BaseSession( string sBindingUrl, string repository, const HttpSession& httpSession ) : Session( ), HttpSession( httpSession ), m_bindingUrl( sBindingUrl ), m_repositoryId( repository ), m_repositories( ) { } BaseSession::BaseSession( const BaseSession& copy ) : Session( ), HttpSession( copy ), m_bindingUrl( copy.m_bindingUrl ), m_repositoryId( copy.m_repositoryId ), m_repositories( copy.m_repositories ) { } BaseSession::BaseSession( ) : Session( ), HttpSession( ), m_bindingUrl( ), m_repositoryId( ), m_repositories( ) { } BaseSession& BaseSession::operator=( const BaseSession& copy ) { if ( this != © ) { HttpSession::operator=( copy ); m_bindingUrl = copy.m_bindingUrl; m_repositoryId = copy.m_repositoryId; m_repositories = copy.m_repositories; } return *this; } BaseSession::~BaseSession( ) { } string BaseSession::createUrl( const string& pattern, map< string, string > variables ) { string url( pattern ); // Decompose the pattern and replace the variables by their values map< string, string >::iterator it = variables.begin( ); while ( it != variables.end( ) ) { string name = "{"; name += it->first; name += "}"; string value = it->second; // Search and replace the variable size_t pos = url.find( name ); if ( pos != string::npos ) { // Escape the URL by chunks url = url.replace( pos, name.size(), libcmis::escape( value ) ); } ++it; } // Cleanup the remaining unset variables size_t pos1 = url.find( '{' ); while ( pos1 != string::npos ) { // look for the closing bracket size_t pos2 = url.find( '}', pos1 ); if ( pos2 != string::npos ) url.erase( pos1, pos2 - pos1 + 1 ); pos1 = url.find( '{', pos1 - 1 ); } return url; } void BaseSession::setNoSSLCertificateCheck( bool noCheck ) { HttpSession::setNoSSLCertificateCheck( noCheck ); } void BaseSession::setOAuth2Data( libcmis::OAuth2DataPtr oauth2 ) { m_oauth2Handler = new OAuth2Handler( this, oauth2 ); m_oauth2Handler->setOAuth2Parser( OAuth2Providers::getOAuth2Parser( getBindingUrl( ) ) ); oauth2Authenticate( ); } vector< libcmis::RepositoryPtr > BaseSession::getRepositories( ) { return m_repositories; } libcmis::FolderPtr BaseSession::getRootFolder() { return getFolder( getRootId() ); } libcmis::FolderPtr BaseSession::getFolder( string id ) { libcmis::ObjectPtr object = getObject( id ); libcmis::FolderPtr folder = boost::dynamic_pointer_cast< libcmis::Folder >( object ); return folder; } libcmis-0.5.2/src/libcmis/onedrive-utils.hxx0000664000175000017500000000376513407414352016014 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _ONEDRIVE_UTILS_HXX_ #define _ONEDRIVE_UTILS_HXX_ #include #include #include "json-utils.hxx" class OneDriveUtils { public : // Convert a OneDrive Property key to a CMIS key static std::string toCmisKey( const std::string& key); // Convert a CMIS key to OneDrive key static std::string toOneDriveKey( const std::string& key ); // Check if a property is updatable static bool checkUpdatable( const std::string& key); // Check if a property has multiple values static bool checkMultiValued( const std::string& key); // Parse a OneDrive property value to CMIS values static std::vector< std::string > parseOneDriveProperty( std::string key, Json jsonValue ); // Convert CMIS properties to OneDrive properties static Json toOneDriveJson( const libcmis::PropertyPtrMap& properties ); }; #endif libcmis-0.5.2/src/libcmis/http-session.cxx0000664000175000017500000006505613407757661015514 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "http-session.hxx" #include #include #include #include #include #include #include #include #include "oauth2-handler.hxx" using namespace std; namespace { size_t lcl_getHeaders( void *ptr, size_t size, size_t nmemb, void *userdata ) { libcmis::HttpResponse* response = static_cast< libcmis::HttpResponse* >( userdata ); string buf( ( const char* ) ptr, size * nmemb ); size_t sepPos = buf.find( ':' ); if ( sepPos != string::npos ) { string name( buf, 0, sepPos ); string value = buf.substr( sepPos + 1 ); value = libcmis::trim( value ); response->getHeaders()[name] = value; if ( "Content-Transfer-Encoding" == name ) response->getData( )->setEncoding( value ); } return nmemb; } size_t lcl_bufferData( void* buffer, size_t size, size_t nmemb, void* data ) { libcmis::EncodedData* encoded = static_cast< libcmis::EncodedData* >( data ); encoded->decode( buffer, size, nmemb ); return nmemb; } size_t lcl_readStream( void* buffer, size_t size, size_t nmemb, void* data ) { istream& is = *( static_cast< istream* >( data ) ); char* out = ( char * ) buffer; is.read( out, size * nmemb ); return is.gcount( ) / size; } curlioerr lcl_ioctlStream( CURL* /*handle*/, int cmd, void* data ) { curlioerr errCode = CURLIOE_OK; switch ( cmd ) { case CURLIOCMD_RESTARTREAD: { istream& is = *( static_cast< istream* >( data ) ); is.clear( ); is.seekg( 0, ios::beg ); if ( !is.good() ) { fprintf ( stderr, "rewind failed\n" ); errCode = CURLIOE_FAILRESTART; } } break; case CURLIOCMD_NOP: break; default: errCode = CURLIOE_UNKNOWNCMD; } return errCode; } template class ScopeGuard { public: ScopeGuard(T &var, T newValue) : m_var(var) , m_origValue(var) { m_var = newValue; } ~ScopeGuard() { m_var = m_origValue; } private: T& m_var; const T m_origValue; }; } HttpSession::HttpSession( string username, string password, bool noSslCheck, libcmis::OAuth2DataPtr oauth2, bool verbose ) : m_curlHandle( NULL ), m_no100Continue( false ), m_oauth2Handler( NULL ), m_username( username ), m_password( password ), m_authProvided( false ), m_verbose( verbose ), m_noHttpErrors( false ), m_noSSLCheck( noSslCheck ), m_refreshedToken( false ), m_inOAuth2Authentication( false ), m_authMethod( CURLAUTH_ANY ) { curl_global_init( CURL_GLOBAL_ALL ); m_curlHandle = curl_easy_init( ); if ( oauth2 && oauth2->isComplete( ) ){ setOAuth2Data( oauth2 ); } } HttpSession::HttpSession( const HttpSession& copy ) : m_curlHandle( NULL ), m_no100Continue( copy.m_no100Continue ), m_oauth2Handler( copy.m_oauth2Handler ), m_username( copy.m_username ), m_password( copy.m_password ), m_authProvided( copy.m_authProvided ), m_verbose( copy.m_verbose ), m_noHttpErrors( copy.m_noHttpErrors ), m_noSSLCheck( copy.m_noSSLCheck ), m_refreshedToken( false ), m_inOAuth2Authentication( false ), m_authMethod( copy.m_authMethod ) { // Not sure how sharing curl handles is safe. curl_global_init( CURL_GLOBAL_ALL ); m_curlHandle = curl_easy_init( ); } HttpSession::HttpSession( ) : m_curlHandle( NULL ), m_no100Continue( false ), m_oauth2Handler( NULL ), m_username( ), m_password( ), m_authProvided( false ), m_verbose( false ), m_noHttpErrors( false ), m_noSSLCheck( false ), m_refreshedToken( false ), m_inOAuth2Authentication( false ), m_authMethod( CURLAUTH_ANY ) { curl_global_init( CURL_GLOBAL_ALL ); m_curlHandle = curl_easy_init( ); } HttpSession& HttpSession::operator=( const HttpSession& copy ) { if ( this != © ) { curl_easy_cleanup( m_curlHandle ); m_curlHandle = NULL; m_no100Continue = copy.m_no100Continue; m_oauth2Handler = copy.m_oauth2Handler; m_username = copy.m_username; m_password = copy.m_password; m_authProvided = copy.m_authProvided; m_verbose = copy.m_verbose; m_noHttpErrors = copy.m_noHttpErrors; m_noSSLCheck = copy.m_noSSLCheck; m_refreshedToken = copy.m_refreshedToken; m_inOAuth2Authentication = copy.m_inOAuth2Authentication; m_authMethod = copy.m_authMethod; // Not sure how sharing curl handles is safe. curl_global_init( CURL_GLOBAL_ALL ); m_curlHandle = curl_easy_init( ); } return *this; } HttpSession::~HttpSession( ) { if ( NULL != m_curlHandle ) curl_easy_cleanup( m_curlHandle ); delete( m_oauth2Handler ); } string& HttpSession::getUsername( ) { checkCredentials( ); return m_username; } string& HttpSession::getPassword( ) { checkCredentials( ); return m_password; } libcmis::HttpResponsePtr HttpSession::httpGetRequest( string url ) { checkOAuth2( url ); // Reset the handle for the request curl_easy_reset( m_curlHandle ); initProtocols( ); libcmis::HttpResponsePtr response( new libcmis::HttpResponse( ) ); curl_easy_setopt( m_curlHandle, CURLOPT_WRITEFUNCTION, lcl_bufferData ); curl_easy_setopt( m_curlHandle, CURLOPT_WRITEDATA, response->getData( ).get( ) ); curl_easy_setopt( m_curlHandle, CURLOPT_HEADERFUNCTION, &lcl_getHeaders ); curl_easy_setopt( m_curlHandle, CURLOPT_WRITEHEADER, response.get() ); // fix Cloudoku too many redirects error // note: though curl doc says -1 is the default for MAXREDIRS, the error i got // said it was 0 curl_easy_setopt( m_curlHandle, CURLOPT_MAXREDIRS, 20); try { httpRunRequest( url ); response->getData( )->finish( ); } catch ( const CurlException& ) { // If the access token is expired, we get 401 error, // Need to use the refresh token to get a new one. if ( getHttpStatus( ) == 401 && !getRefreshToken( ).empty( ) && !m_refreshedToken ) { // Refresh the token oauth2Refresh(); // Resend the query try { // Avoid infinite recursive call m_refreshedToken = true; response = httpGetRequest( url ); m_refreshedToken = false; } catch (const CurlException& ) { throw; } m_refreshedToken = false; } else throw; } m_refreshedToken = false; return response; } libcmis::HttpResponsePtr HttpSession::httpPutRequest( string url, istream& is, vector< string > headers ) { checkOAuth2( url ); // Duplicate istream in case we need to retry string isStr( static_cast< stringstream const&>( stringstream( ) << is.rdbuf( ) ).str( ) ); istringstream isOriginal( isStr ), isBackup( isStr ); // Reset the handle for the request curl_easy_reset( m_curlHandle ); initProtocols( ); libcmis::HttpResponsePtr response( new libcmis::HttpResponse( ) ); curl_easy_setopt( m_curlHandle, CURLOPT_WRITEFUNCTION, lcl_bufferData ); curl_easy_setopt( m_curlHandle, CURLOPT_WRITEDATA, response->getData( ).get( ) ); curl_easy_setopt( m_curlHandle, CURLOPT_HEADERFUNCTION, &lcl_getHeaders ); curl_easy_setopt( m_curlHandle, CURLOPT_WRITEHEADER, response.get() ); curl_easy_setopt( m_curlHandle, CURLOPT_MAXREDIRS, 20); // Get the stream length is.seekg( 0, ios::end ); long size = is.tellg( ); is.seekg( 0, ios::beg ); curl_easy_setopt( m_curlHandle, CURLOPT_INFILESIZE, size ); curl_easy_setopt( m_curlHandle, CURLOPT_READDATA, &isOriginal ); curl_easy_setopt( m_curlHandle, CURLOPT_READFUNCTION, lcl_readStream ); curl_easy_setopt( m_curlHandle, CURLOPT_UPLOAD, 1 ); curl_easy_setopt( m_curlHandle, CURLOPT_IOCTLFUNCTION, lcl_ioctlStream ); curl_easy_setopt( m_curlHandle, CURLOPT_IOCTLDATA, &isOriginal ); // If we know for sure that 100-Continue won't be accepted, // don't even try with it to save one HTTP request. if ( m_no100Continue ) headers.push_back( "Expect:" ); try { httpRunRequest( url, headers ); response->getData( )->finish(); } catch ( const CurlException& ) { long status = getHttpStatus( ); /** If we had a HTTP 417 response, this is likely to be due to some HTTP 1.0 proxy / server not accepting the "Expect: 100-continue" header. Try to disable this header and try again. */ if ( status == 417 && !m_no100Continue) { // Remember that we don't want 100-Continue for the future requests m_no100Continue = true; response = httpPutRequest( url, isBackup, headers ); } // If the access token is expired, we get 401 error, // Need to use the refresh token to get a new one. if ( status == 401 && !getRefreshToken( ).empty( ) && !m_refreshedToken ) { // Refresh the token oauth2Refresh(); // Resend the query try { // Avoid infinite recursive call m_refreshedToken = true; response = httpPutRequest( url, isBackup, headers ); m_refreshedToken = false; } catch (const CurlException& ) { m_refreshedToken = false; throw; } } // Has tried but failed if ( ( status != 417 || m_no100Continue ) && ( status != 401 || getRefreshToken( ).empty( ) || m_refreshedToken ) ) throw; } m_refreshedToken = false; return response; } libcmis::HttpResponsePtr HttpSession::httpPostRequest( const string& url, istream& is, const string& contentType, bool redirect ) { checkOAuth2( url ); // Duplicate istream in case we need to retry string isStr( static_cast< stringstream const&>( stringstream( ) << is.rdbuf( ) ).str( ) ); istringstream isOriginal( isStr ), isBackup( isStr ); // Reset the handle for the request curl_easy_reset( m_curlHandle ); initProtocols( ); libcmis::HttpResponsePtr response( new libcmis::HttpResponse( ) ); curl_easy_setopt( m_curlHandle, CURLOPT_WRITEFUNCTION, lcl_bufferData ); curl_easy_setopt( m_curlHandle, CURLOPT_WRITEDATA, response->getData( ).get( ) ); curl_easy_setopt( m_curlHandle, CURLOPT_HEADERFUNCTION, &lcl_getHeaders ); curl_easy_setopt( m_curlHandle, CURLOPT_WRITEHEADER, response.get() ); curl_easy_setopt( m_curlHandle, CURLOPT_MAXREDIRS, 20); // Get the stream length is.seekg( 0, ios::end ); long size = is.tellg( ); is.seekg( 0, ios::beg ); curl_easy_setopt( m_curlHandle, CURLOPT_POSTFIELDSIZE, size ); curl_easy_setopt( m_curlHandle, CURLOPT_READDATA, &isOriginal ); curl_easy_setopt( m_curlHandle, CURLOPT_READFUNCTION, lcl_readStream ); curl_easy_setopt( m_curlHandle, CURLOPT_POST, 1 ); curl_easy_setopt( m_curlHandle, CURLOPT_IOCTLFUNCTION, lcl_ioctlStream ); curl_easy_setopt( m_curlHandle, CURLOPT_IOCTLDATA, &isOriginal ); vector< string > headers; headers.push_back( string( "Content-Type:" ) + contentType ); // If we know for sure that 100-Continue won't be accepted, // don't even try with it to save one HTTP request. if ( m_no100Continue ) headers.push_back( "Expect:" ); try { httpRunRequest( url, headers, redirect ); response->getData( )->finish(); } catch ( const CurlException& ) { long status = getHttpStatus( ); /** If we had a HTTP 417 response, this is likely to be due to some HTTP 1.0 proxy / server not accepting the "Expect: 100-continue" header. Try to disable this header and try again. */ if ( status == 417 && !m_no100Continue ) { // Remember that we don't want 100-Continue for the future requests m_no100Continue = true; response = httpPostRequest( url, isBackup, contentType, redirect ); } // If the access token is expired, we get 401 error, // Need to use the refresh token to get a new one. if ( status == 401 && !getRefreshToken( ).empty( ) && !m_refreshedToken ) { // Refresh the token oauth2Refresh(); // Resend the query try { // Avoid infinite recursive call m_refreshedToken = true; response = httpPostRequest( url, isBackup, contentType, redirect ); m_refreshedToken = false; } catch (const CurlException& ) { m_refreshedToken = false; throw; } } // Has tried but failed if ( ( status != 417 || m_no100Continue ) && ( status != 401 || getRefreshToken( ).empty( ) || m_refreshedToken ) ) throw; } m_refreshedToken = false; return response; } void HttpSession::httpDeleteRequest( string url ) { checkOAuth2( url ); // Reset the handle for the request curl_easy_reset( m_curlHandle ); initProtocols( ); curl_easy_setopt( m_curlHandle, CURLOPT_CUSTOMREQUEST, "DELETE" ); try { httpRunRequest( url ); } catch ( const CurlException& ) { // If the access token is expired, we get 401 error, // Need to use the refresh token to get a new one. if ( getHttpStatus( ) == 401 && !getRefreshToken( ).empty( ) && !m_refreshedToken ) { // Refresh the token oauth2Refresh(); // Resend the query try { // Avoid infinite recursive call m_refreshedToken = true; httpDeleteRequest( url ); m_refreshedToken = false; } catch (const CurlException& ) { m_refreshedToken = false; throw; } } else throw; } m_refreshedToken = false; } void HttpSession::checkCredentials( ) { // Check that we have the complete credentials libcmis::AuthProviderPtr authProvider = libcmis::SessionFactory::getAuthenticationProvider(); if ( authProvider && !m_authProvided && ( m_username.empty() || m_password.empty() ) ) { m_authProvided = authProvider->authenticationQuery( m_username, m_password ); if ( !m_authProvided ) { throw CurlException( "User cancelled authentication request" ); } } } void HttpSession::httpRunRequest( string url, vector< string > headers, bool redirect ) { // Redirect curl_easy_setopt( m_curlHandle, CURLOPT_FOLLOWLOCATION, redirect); // Activate the cookie engine curl_easy_setopt( m_curlHandle, CURLOPT_COOKIEFILE, "" ); // Grab something from the web curl_easy_setopt( m_curlHandle, CURLOPT_URL, url.c_str() ); // Set the headers struct curl_slist *headers_slist = NULL; for ( vector< string >::iterator it = headers.begin( ); it != headers.end( ); ++it ) headers_slist = curl_slist_append( headers_slist, it->c_str( ) ); // If we are using OAuth2, then add the proper header with token to authenticate // Otherwise, just set the credentials normally using in libcurl options if ( m_oauth2Handler != NULL && !m_oauth2Handler->getHttpHeader( ).empty() ) { headers_slist = curl_slist_append( headers_slist, m_oauth2Handler->getHttpHeader( ).c_str( ) ); } else if ( !getUsername().empty() ) { curl_easy_setopt( m_curlHandle, CURLOPT_HTTPAUTH, m_authMethod ); #if LIBCURL_VERSION_VALUE >= 0x071301 curl_easy_setopt( m_curlHandle, CURLOPT_USERNAME, getUsername().c_str() ); curl_easy_setopt( m_curlHandle, CURLOPT_PASSWORD, getPassword().c_str() ); #else string userpwd = getUsername() + ":" + getPassword(); curl_easy_setopt( m_curlHandle, CURLOPT_USERPWD, userpwd.c_str( ) ); #endif } curl_easy_setopt( m_curlHandle, CURLOPT_HTTPHEADER, headers_slist ); // Set the proxy configuration if any if ( !libcmis::SessionFactory::getProxy( ).empty() ) { curl_easy_setopt( m_curlHandle, CURLOPT_PROXY, libcmis::SessionFactory::getProxy( ).c_str() ); #if LIBCURL_VERSION_VALUE >= 0x071304 curl_easy_setopt( m_curlHandle, CURLOPT_NOPROXY, libcmis::SessionFactory::getNoProxy( ).c_str() ); #endif const string& proxyUser = libcmis::SessionFactory::getProxyUser( ); const string& proxyPass = libcmis::SessionFactory::getProxyPass( ); if ( !proxyUser.empty( ) && !proxyPass.empty( ) ) { curl_easy_setopt( m_curlHandle, CURLOPT_PROXYAUTH, CURLAUTH_ANY ); #if LIBCURL_VERSION_VALUE >= 0X071301 curl_easy_setopt( m_curlHandle, CURLOPT_PROXYUSERNAME, proxyUser.c_str( ) ); curl_easy_setopt( m_curlHandle, CURLOPT_PROXYPASSWORD, proxyPass.c_str( ) ); #else string userpwd = proxyUser + ":" + proxyPass; curl_easy_setopt( m_curlHandle, CURLOPT_PROXYUSERPWD, userpwd.c_str( ) ); #endif } } // Get some feedback when something wrong happens char errBuff[CURL_ERROR_SIZE]; errBuff[0] = 0; curl_easy_setopt( m_curlHandle, CURLOPT_ERRORBUFFER, errBuff ); // We want to get the response even if there is an Http error if ( !m_noHttpErrors ) curl_easy_setopt( m_curlHandle, CURLOPT_FAILONERROR, 1 ); if ( m_verbose ) curl_easy_setopt( m_curlHandle, CURLOPT_VERBOSE, 1 ); // We want to get the certificate infos in error cases #if LIBCURL_VERSION_VALUE >= 0X071301 curl_easy_setopt( m_curlHandle, CURLOPT_CERTINFO, 1 ); #endif if ( m_noSSLCheck ) { #if LIBCURL_VERSION_VALUE >= 0x070801 curl_easy_setopt(m_curlHandle, CURLOPT_SSL_VERIFYHOST, 0); #endif #if LIBCURL_VERSION_VALUE >= 0x070402 curl_easy_setopt(m_curlHandle, CURLOPT_SSL_VERIFYPEER, 0); #endif } // Perform the query CURLcode errCode = curl_easy_perform( m_curlHandle ); // Free the headers list curl_slist_free_all( headers_slist ); // Process the response bool isHttpError = errCode == CURLE_HTTP_RETURNED_ERROR; if ( CURLE_OK != errCode && !( m_noHttpErrors && isHttpError ) ) { long httpError = 0; curl_easy_getinfo( m_curlHandle, CURLINFO_RESPONSE_CODE, &httpError ); bool errorFixed = false; #if LIBCURL_VERSION_VALUE >= 0X071301 // If we had a bad certificate, then try to get more details if ( CURLE_SSL_CACERT == errCode ) { vector< string > certificates; // We somehow need to rerun the request to get the certificate curl_easy_setopt(m_curlHandle, CURLOPT_SSL_VERIFYHOST, 0); curl_easy_setopt(m_curlHandle, CURLOPT_SSL_VERIFYPEER, 0); errCode = curl_easy_perform( m_curlHandle ); union { struct curl_slist *to_info; struct curl_certinfo *to_certinfo; } ptr; ptr.to_info = NULL; CURLcode res = curl_easy_getinfo(m_curlHandle, CURLINFO_CERTINFO, &ptr.to_info); if ( !res && ptr.to_info ) { // We need the first certificate in the chain only if ( ptr.to_certinfo->num_of_certs > 0 ) { struct curl_slist *slist; string certStart( "Cert:" ); for ( slist = ptr.to_certinfo->certinfo[0]; slist; slist = slist->next ) { string data( slist->data ); size_t startPos = data.find( certStart ); if ( startPos == 0 ) { startPos = certStart.length(); data = data.substr( startPos ); certificates.push_back( data ); } } } } if ( !certificates.empty() ) { libcmis::CertValidationHandlerPtr validationHandler = libcmis::SessionFactory::getCertificateValidationHandler( ); bool ignoreCert = validationHandler && validationHandler->validateCertificate( certificates ); if ( ignoreCert ) { m_noSSLCheck = true; isHttpError = errCode == CURLE_HTTP_RETURNED_ERROR; errorFixed = ( CURLE_OK == errCode || ( m_noHttpErrors && isHttpError ) ); if ( !errorFixed ) curl_easy_getinfo( m_curlHandle, CURLINFO_RESPONSE_CODE, &httpError ); } else { throw CurlException( "Invalid SSL certificate" ); } } } #endif if ( !errorFixed ) throw CurlException( string( errBuff ), errCode, url, httpError ); } } void HttpSession::checkOAuth2( string url ) try { if ( m_oauth2Handler ) { m_oauth2Handler->setOAuth2Parser( OAuth2Providers::getOAuth2Parser( url ) ); if ( m_oauth2Handler->getAccessToken().empty() && !m_inOAuth2Authentication ) oauth2Authenticate( ); } } catch ( const libcmis::Exception& e ) { throw CurlException( e.what( ) ); } long HttpSession::getHttpStatus( ) { long status = 0; curl_easy_getinfo( m_curlHandle, CURLINFO_RESPONSE_CODE, &status ); return status; } void HttpSession::setOAuth2Data( libcmis::OAuth2DataPtr oauth2 ) { m_oauth2Handler = new OAuth2Handler( this, oauth2 ); } void HttpSession::oauth2Authenticate( ) { string authCode; const ScopeGuard inOauth2Guard(m_inOAuth2Authentication, true); try { // Try to get the authentication code using the given provider. authCode = m_oauth2Handler->oauth2Authenticate( ); // If that didn't work, call the fallback provider from SessionFactory if ( authCode.empty( ) ) { libcmis::OAuth2AuthCodeProvider fallbackProvider = libcmis::SessionFactory::getOAuth2AuthCodeProvider( ); if ( fallbackProvider != NULL ) { unique_ptr< char, void (*)( void * ) > code{ fallbackProvider( m_oauth2Handler->getAuthURL().c_str(), getUsername().c_str(), getPassword().c_str() ), free }; if ( code ) authCode = string( code.get() ); } } } catch ( const CurlException& e ) { // Thrown by getUsername() and getPassword() if user cancels the credentials request throw e.getCmisException( ); } // If still no auth code, then raise an exception if ( authCode.empty( ) ) throw libcmis::Exception( "Couldn't get OAuth authentication code", "permissionDenied" ); m_oauth2Handler->fetchTokens( string( authCode ) ); } void HttpSession::setNoSSLCertificateCheck( bool noCheck ) { m_noSSLCheck = noCheck; } string HttpSession::getRefreshToken( ) { string refreshToken; if ( m_oauth2Handler ) refreshToken = m_oauth2Handler->getRefreshToken( ); return refreshToken; } void HttpSession::oauth2Refresh( ) try { const ScopeGuard inOauth2Guard(m_inOAuth2Authentication, true); m_oauth2Handler->refresh( ); } catch ( const libcmis::Exception& e ) { throw CurlException( e.what() ); } void HttpSession::initProtocols( ) { const unsigned long protocols = CURLPROTO_HTTP | CURLPROTO_HTTPS; curl_easy_setopt(m_curlHandle, CURLOPT_PROTOCOLS, protocols); curl_easy_setopt(m_curlHandle, CURLOPT_REDIR_PROTOCOLS, protocols); } const char* CurlException::what( ) const noexcept { if ( !isCancelled( ) ) { stringstream buf; buf << "CURL error - " << ( unsigned int ) m_code << ": "; buf << m_message; m_errorMessage = buf.str( ); return m_errorMessage.c_str( ); } return m_message.c_str( ); } libcmis::Exception CurlException::getCmisException( ) const { string msg; string type( "runtime" ); switch ( m_httpStatus ) { case 400: msg = string( what() ) + string( ": " ) + m_url; type = "invalidArgument"; break; case 401: msg = "Authentication failure"; type = "permissionDenied"; break; case 403: msg = "Invalid credentials"; type = "permissionDenied"; break; case 404: msg = "Invalid URL: " + m_url; type = "objectNotFound"; break; case 405: msg = string( what() ) + string( ": " ) + m_url; type = "notSupported"; break; case 409: msg = "Editing conflict error"; type = "updateConflict"; break; default: msg = what(); if ( !isCancelled( ) ) msg += ": " + m_url; else type = "permissionDenied"; break; } return libcmis::Exception( msg, type ); } libcmis-0.5.2/src/libcmis/gdrive-utils.hxx0000664000175000017500000000445013407414352015451 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _GDRIVE_UTILS_HXX_ #define _GDRIVE_UTILS_HXX_ #include #include #include "json-utils.hxx" static const std::string GDRIVE_FOLDER_MIME_TYPE = "application/vnd.google-apps.folder" ; static const std::string GDRIVE_UPLOAD_LINKS = "https://www.googleapis.com/upload/drive/v2/files/"; class GdriveUtils { public : // Convert a GDrive Property key to a CMIS key static std::string toCmisKey( const std::string& key); // Convert a CMIS key to GDrive key static std::string toGdriveKey( const std::string& key ); // Convert CMIS properties to GDrive properties static Json toGdriveJson( const libcmis::PropertyPtrMap& properties ); // Check if a property is updatable static bool checkUpdatable( const std::string& key); // Check if a property has multiple values static bool checkMultiValued( const std::string& key); // Create a Json array from a ParentId static Json createJsonFromParentId( const std::string& parentId ); // Parse a Gdrive property value to CMIS values static std::vector< std::string > parseGdriveProperty( std::string key, Json jsonValue ); }; #endif libcmis-0.5.2/src/libcmis/onedrive-repository.hxx0000664000175000017500000000242013407414352017056 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _ONEDRIVE_REPOSITORY_HXX_ #define _ONEDRIVE_REPOSITORY_HXX_ #include class OneDriveRepository: public libcmis::Repository { public: OneDriveRepository( ); }; #endif libcmis-0.5.2/src/libcmis/onedrive-object.hxx0000664000175000017500000000532213407414352016111 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _ONEDRIVE_OBJECT_HXX_ #define _ONEDRIVE_OBJECT_HXX_ #include #include "onedrive-session.hxx" #include "json-utils.hxx" // Class representing an object for OneDrive protocol. class OneDriveObject : public virtual libcmis::Object { public: OneDriveObject( OneDriveSession* session ); // Create a OneDrive document from Json properties. OneDriveObject( OneDriveSession* session, Json json, std::string id = std::string( ), std::string name = std::string( ) ); OneDriveObject( const OneDriveObject& copy ); virtual ~OneDriveObject( ) { } OneDriveObject& operator=( const OneDriveObject& copy ); void initializeFromJson( Json json, std::string id = std::string( ), std::string name = std::string( ) ); void refreshImpl( Json json ); virtual void refresh( ); virtual void remove( bool allVersions = true ); std::string getUrl( ); std::string getUploadUrl( ); std::vector< std::string > getMultiStringProperty( const std::string& propertyName ); virtual boost::shared_ptr< Object > updateProperties( const libcmis::PropertyPtrMap& properties ); virtual std::vector< libcmis::RenditionPtr> getRenditions( std::string /*filter = std::string( )*/ ) {return std::vector< libcmis::RenditionPtr>( );} virtual void move( boost::shared_ptr< libcmis::Folder > source, boost::shared_ptr< libcmis::Folder > destination ); protected: OneDriveSession* getSession( ); }; #endif libcmis-0.5.2/src/libcmis/gdrive-object-type.cxx0000664000175000017500000001255613407414352016537 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "gdrive-object-type.hxx" GdriveObjectType::GdriveObjectType( const std::string& id ): ObjectType( ) { m_id = id; m_localName = "GoogleDrive Object Type"; m_localNamespace = "GoogleDrive Object Type"; m_displayName = "GoogleDrive Object Type"; m_queryName = "GoogleDrive Object Type"; m_description = "GoogleDrive Object Type"; m_parentTypeId = id; m_baseTypeId = id; m_creatable = true; m_versionable = true; m_fulltextIndexed = true; libcmis::PropertyTypePtr idType(new libcmis::PropertyType( ) ); idType->setId( "cmis:objectTypeId" ); idType->setType( libcmis::PropertyType::String ); m_propertiesTypes[ idType->getId( ) ] = idType; // create PropertyTypes which are updatable. // title libcmis::PropertyTypePtr nameType( new libcmis::PropertyType( ) ); nameType->setId( "cmis:name" ); nameType->setType( libcmis::PropertyType::String ); nameType->setUpdatable( true ); m_propertiesTypes[ nameType->getId( ) ] = nameType; // mimeType libcmis::PropertyTypePtr mimeType( new libcmis::PropertyType( ) ); mimeType->setId( "cmis:contentStreamMimeType" ); mimeType->setType( libcmis::PropertyType::String ); mimeType->setUpdatable( false ); m_propertiesTypes[ mimeType->getId( ) ] = mimeType; // parents libcmis::PropertyTypePtr parentsType( new libcmis::PropertyType( ) ); parentsType->setId( "cmis:parentId" ); parentsType->setType( libcmis::PropertyType::String ); parentsType->setUpdatable( false ); parentsType->setMultiValued( true ); m_propertiesTypes[ parentsType->getId( ) ] = parentsType; // labels libcmis::PropertyTypePtr labelsType( new libcmis::PropertyType( ) ); labelsType->setId( "labels" ); labelsType->setType( libcmis::PropertyType::String ); labelsType->setUpdatable( false ); labelsType->setMultiValued( true ); m_propertiesTypes[ labelsType->getId( ) ] = labelsType; // ownerNames libcmis::PropertyTypePtr ownerNamesType( new libcmis::PropertyType( ) ); ownerNamesType->setId( "ownerNames" ); ownerNamesType->setType( libcmis::PropertyType::String ); ownerNamesType->setUpdatable( false ); ownerNamesType->setMultiValued( true ); m_propertiesTypes[ ownerNamesType->getId( ) ] = ownerNamesType; // owners libcmis::PropertyTypePtr ownersType( new libcmis::PropertyType( ) ); ownersType->setId( "owners" ); ownersType->setType( libcmis::PropertyType::String ); ownersType->setUpdatable( false ); ownersType->setMultiValued( true ); m_propertiesTypes[ ownersType->getId( ) ] = ownersType; // export links libcmis::PropertyTypePtr exportLinksType( new libcmis::PropertyType( ) ); exportLinksType->setId( "exportLinks" ); exportLinksType->setType( libcmis::PropertyType::String ); exportLinksType->setUpdatable( false ); exportLinksType->setMultiValued( true ); m_propertiesTypes[ exportLinksType->getId( ) ] = exportLinksType; // description libcmis::PropertyTypePtr descriptionType( new libcmis::PropertyType( ) ); descriptionType->setId( "cmis:description" ); descriptionType->setType( libcmis::PropertyType::String ); descriptionType->setUpdatable( true ); m_propertiesTypes[ descriptionType->getId( ) ] = descriptionType; // modifiedDate libcmis::PropertyTypePtr modifiedDateType( new libcmis::PropertyType( ) ); modifiedDateType->setId( "cmis:lastModificationDate" ); modifiedDateType->setType( libcmis::PropertyType::DateTime ); modifiedDateType->setUpdatable( true ); m_propertiesTypes[ modifiedDateType->getId( ) ] = modifiedDateType; // lastViewedByMeDate libcmis::PropertyTypePtr lastViewedByMeDateType( new libcmis::PropertyType( ) ); lastViewedByMeDateType->setId( "lastViewedByMeDate" ); lastViewedByMeDateType->setType( libcmis::PropertyType::DateTime ); lastViewedByMeDateType->setUpdatable( true ); m_propertiesTypes[ lastViewedByMeDateType->getId( ) ] = lastViewedByMeDateType; } libcmis::ObjectTypePtr GdriveObjectType::getParentType( ) { libcmis::ObjectTypePtr parentTypePtr( new GdriveObjectType( m_parentTypeId ) ); return parentTypePtr; } libcmis::ObjectTypePtr GdriveObjectType::getBaseType( ) { libcmis::ObjectTypePtr baseTypePtr( new GdriveObjectType( m_baseTypeId ) ); return baseTypePtr; } libcmis-0.5.2/src/libcmis/ws-requests.hxx0000664000175000017500000005230413407414352015336 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _WS_REQUESTS_HXX_ #define _WS_REQUESTS_HXX_ #include #include #include #include #include #include #include #include #include #include #include #include #include #include "ws-soap.hxx" class CmisSoapFaultDetail : public SoapFaultDetail { private: std::string m_type; long m_code; std::string m_message; CmisSoapFaultDetail( xmlNodePtr node ); public: ~CmisSoapFaultDetail( ) noexcept { }; std::string getType( ) { return m_type; } int getCode( ) { return m_code; } std::string getMessage( ) { return m_message; } libcmis::Exception toException( ); static SoapFaultDetailPtr create( xmlNodePtr node ); }; boost::shared_ptr< libcmis::Exception > getCmisException( const SoapFault& fault ); void writeCmismStream( xmlTextWriterPtr writer, RelatedMultipart& multipart, boost::shared_ptr< std::ostream >, std::string& contentType, std::string filename ); /** getRepositories request. */ class GetRepositories : public SoapRequest { public: GetRepositories( ) { }; ~GetRepositories( ) { }; void toXml( xmlTextWriterPtr writer ); }; class GetRepositoriesResponse : public SoapResponse { private: std::map< std::string, std::string > m_repositories; GetRepositoriesResponse( ) : SoapResponse( ), m_repositories( ) { }; public: /** Parse cmism:getRepositoriesResponse. This function assumes that the node is the expected one: this is normally ensured by the SoapResponseFactory. */ static SoapResponsePtr create( xmlNodePtr node, RelatedMultipart& multipart, SoapSession* session ); std::map< std::string, std::string > getRepositories( ) { return m_repositories; } }; class GetRepositoryInfo : public SoapRequest { private: std::string m_id; public: GetRepositoryInfo( std::string id ) : m_id( id ) { }; ~GetRepositoryInfo( ) { }; void toXml( xmlTextWriterPtr writer ); }; class GetRepositoryInfoResponse : public SoapResponse { private: libcmis::RepositoryPtr m_repository; GetRepositoryInfoResponse( ) : SoapResponse( ), m_repository( ) { }; public: /** Parse cmism:getRepositoriesResponse. This function assumes that the node is the expected one: this is normally ensured by the SoapResponseFactory. */ static SoapResponsePtr create( xmlNodePtr node, RelatedMultipart& multipart, SoapSession* session ); libcmis::RepositoryPtr getRepository( ) { return m_repository; } }; class GetTypeDefinition : public SoapRequest { private: std::string m_repositoryId; std::string m_typeId; public: GetTypeDefinition( std::string repoId, std::string typeId ) : m_repositoryId( repoId ), m_typeId( typeId ) { } ~GetTypeDefinition( ) { } void toXml( xmlTextWriterPtr writer ); }; class GetTypeDefinitionResponse : public SoapResponse { private: libcmis::ObjectTypePtr m_type; GetTypeDefinitionResponse( ) : SoapResponse( ), m_type( ) { } public: /** Parse cmism:getTypeDefinitionResponse. This function assumes that the node is the expected one: this is normally ensured by the SoapResponseFactory. */ static SoapResponsePtr create( xmlNodePtr node, RelatedMultipart& multipart, SoapSession* session ); libcmis::ObjectTypePtr getType( ) { return m_type; } }; class GetTypeChildren : public SoapRequest { private: std::string m_repositoryId; std::string m_typeId; public: GetTypeChildren( std::string repoId, std::string typeId ) : m_repositoryId( repoId ), m_typeId( typeId ) { } ~GetTypeChildren( ) { } void toXml( xmlTextWriterPtr writer ); }; class GetTypeChildrenResponse : public SoapResponse { private: std::vector< libcmis::ObjectTypePtr > m_children; GetTypeChildrenResponse( ) : SoapResponse( ), m_children( ) { } public: /** Parse cmism:getTypeChildrenResponse. This function assumes that the node is the expected one: this is normally ensured by the SoapResponseFactory. */ static SoapResponsePtr create( xmlNodePtr node, RelatedMultipart& multipart, SoapSession* session ); std::vector< libcmis::ObjectTypePtr > getChildren( ) { return m_children; } }; #undef GetObject class GetObject : public SoapRequest { private: std::string m_repositoryId; std::string m_id; public: GetObject( std::string repoId, std::string id ) : m_repositoryId( repoId ), m_id( id ) { } ~GetObject( ) { } void toXml( xmlTextWriterPtr writer ); }; class GetObjectResponse : public SoapResponse { private: libcmis::ObjectPtr m_object; GetObjectResponse( ) : SoapResponse( ), m_object( ) { } public: /** Parse cmism:getObjectResponse. This function assumes that the node is the expected one: this is normally ensured by the SoapResponseFactory. */ static SoapResponsePtr create( xmlNodePtr node, RelatedMultipart& multipart, SoapSession* session ); libcmis::ObjectPtr getObject( ) { return m_object; } }; class GetObjectByPath : public SoapRequest { private: std::string m_repositoryId; std::string m_path; public: GetObjectByPath( std::string repoId, std::string path ) : m_repositoryId( repoId ), m_path( path ) { } ~GetObjectByPath( ) { } void toXml( xmlTextWriterPtr writer ); }; class UpdateProperties : public SoapRequest { private: std::string m_repositoryId; std::string m_objectId; const std::map< std::string, libcmis::PropertyPtr >& m_properties; std::string m_changeToken; public: UpdateProperties( std::string repoId, std::string objectId, const std::map< std::string, libcmis::PropertyPtr >& properties, std::string changeToken ) : m_repositoryId( repoId ), m_objectId( objectId ), m_properties( properties ), m_changeToken( changeToken ) { } ~UpdateProperties( ) { } void toXml( xmlTextWriterPtr writer ); }; class UpdatePropertiesResponse : public SoapResponse { private: std::string m_id; UpdatePropertiesResponse( ) : SoapResponse( ), m_id( ) { } public: /** Parse cmism:updatePropertiesResponse. This function assumes that the node is the expected one: this is normally ensured by the SoapResponseFactory. */ static SoapResponsePtr create( xmlNodePtr node, RelatedMultipart& multipart, SoapSession* session ); std::string getObjectId( ) { return m_id; } }; class DeleteObject : public SoapRequest { private: std::string m_repositoryId; std::string m_objectId; bool m_allVersions; public: DeleteObject( std::string repoId, std::string objectId, bool allVersions ) : m_repositoryId( repoId ), m_objectId( objectId ), m_allVersions( allVersions ) { } ~DeleteObject( ) { } void toXml( xmlTextWriterPtr writer ); }; class DeleteTree : public SoapRequest { private: std::string m_repositoryId; std::string m_folderId; bool m_allVersions; libcmis::UnfileObjects::Type m_unfile; bool m_continueOnFailure; public: DeleteTree( std::string repoId, std::string folderId, bool allVersions, libcmis::UnfileObjects::Type unfile, bool continueOnFailure ) : m_repositoryId( repoId ), m_folderId( folderId ), m_allVersions( allVersions ), m_unfile( unfile ), m_continueOnFailure( continueOnFailure ) { } ~DeleteTree( ) { } void toXml( xmlTextWriterPtr writer ); }; class DeleteTreeResponse : public SoapResponse { private: std::vector< std::string > m_failedIds; DeleteTreeResponse( ) : SoapResponse( ), m_failedIds( ) { } public: /** Parse cmism:deleteTreeResponse. This function assumes that the node is the expected one: this is normally ensured by the SoapResponseFactory. */ static SoapResponsePtr create( xmlNodePtr node, RelatedMultipart& multipart, SoapSession* session ); std::vector< std::string > getFailedIds( ) { return m_failedIds; } }; class MoveObject : public SoapRequest { private: std::string m_repositoryId; std::string m_objectId; std::string m_destId; std::string m_srcId; public: MoveObject( std::string repoId, std::string objectId, std::string destId, std::string srcId ) : m_repositoryId( repoId ), m_objectId( objectId ), m_destId( destId ), m_srcId( srcId ) { } ~MoveObject( ) { } void toXml( xmlTextWriterPtr writer ); }; class GetContentStream : public SoapRequest { private: std::string m_repositoryId; std::string m_objectId; public: GetContentStream( std::string repoId, std::string objectId ) : m_repositoryId( repoId ), m_objectId( objectId ) { } ~GetContentStream( ) { } void toXml( xmlTextWriterPtr writer ); }; class GetContentStreamResponse : public SoapResponse { private: boost::shared_ptr< std::istream > m_stream; GetContentStreamResponse( ) : SoapResponse( ), m_stream( ) { } public: /** Parse cmism:getContentStreamResponse. This function assumes that the node is the expected one: this is normally ensured by the SoapResponseFactory. */ static SoapResponsePtr create( xmlNodePtr node, RelatedMultipart& multipart, SoapSession* session ); boost::shared_ptr< std::istream> getStream( ) { return m_stream; } }; class GetObjectParents : public SoapRequest { private: std::string m_repositoryId; std::string m_objectId; public: GetObjectParents( std::string repoId, std::string objectId ) : m_repositoryId( repoId ), m_objectId( objectId ) { } ~GetObjectParents( ) { } void toXml( xmlTextWriterPtr writer ); }; class GetObjectParentsResponse : public SoapResponse { private: std::vector< libcmis::FolderPtr > m_parents; GetObjectParentsResponse( ) : SoapResponse( ), m_parents( ) { } public: /** Parse cmism:getObjectParentsResponse. This function assumes that the node is the expected one: this is normally ensured by the SoapResponseFactory. */ static SoapResponsePtr create( xmlNodePtr node, RelatedMultipart& multipart, SoapSession* session ); std::vector< libcmis::FolderPtr > getParents( ) { return m_parents; } }; class GetChildren : public SoapRequest { private: std::string m_repositoryId; std::string m_folderId; public: GetChildren( std::string repoId, std::string folderId ) : m_repositoryId( repoId ), m_folderId( folderId ) { } ~GetChildren( ) { } void toXml( xmlTextWriterPtr writer ); }; class GetChildrenResponse : public SoapResponse { private: std::vector< libcmis::ObjectPtr > m_children; GetChildrenResponse( ) : SoapResponse( ), m_children( ) { } public: /** Parse cmism:getChildrenResponse. This function assumes that the node is the expected one: this is normally ensured by the SoapResponseFactory. */ static SoapResponsePtr create( xmlNodePtr node, RelatedMultipart& multipart, SoapSession* session ); std::vector< libcmis::ObjectPtr > getChildren( ) { return m_children; } }; class CreateFolder : public SoapRequest { private: std::string m_repositoryId; const std::map< std::string, libcmis::PropertyPtr >& m_properties; std::string m_folderId; public: CreateFolder( std::string repoId, const std::map< std::string, libcmis::PropertyPtr >& properties, std::string folderId ) : m_repositoryId( repoId ), m_properties( properties ), m_folderId( folderId ) { } ~CreateFolder( ) { } void toXml( xmlTextWriterPtr writer ); }; class CreateFolderResponse : public SoapResponse { private: std::string m_id; CreateFolderResponse( ) : SoapResponse( ), m_id( ) { } public: /** Parse cmism:createFolderResponse. This function assumes that the node is the expected one: this is normally ensured by the SoapResponseFactory. */ static SoapResponsePtr create( xmlNodePtr node, RelatedMultipart& multipart, SoapSession* session ); std::string getObjectId( ) { return m_id; } }; class CreateDocument : public SoapRequest { private: std::string m_repositoryId; const std::map< std::string, libcmis::PropertyPtr >& m_properties; std::string m_folderId; boost::shared_ptr< std::ostream > m_stream; std::string m_contentType; std::string m_filename; public: CreateDocument( std::string repoId, const std::map< std::string, libcmis::PropertyPtr >& properties, std::string folderId, boost::shared_ptr< std::ostream > stream, std::string contentType, std::string filename ) : m_repositoryId( repoId ), m_properties( properties ), m_folderId( folderId ), m_stream( stream ), m_contentType( contentType ), m_filename( filename ) { } ~CreateDocument( ) { } void toXml( xmlTextWriterPtr writer ); }; class SetContentStream : public SoapRequest { private: std::string m_repositoryId; std::string m_objectId; bool m_overwrite; std::string m_changeToken; boost::shared_ptr< std::ostream > m_stream; std::string m_contentType; std::string m_filename; public: SetContentStream( std::string repoId, std::string objectId, bool overwrite, std::string changeToken, boost::shared_ptr< std::ostream > stream, std::string contentType, std::string filename ) : m_repositoryId( repoId ), m_objectId( objectId ), m_overwrite( overwrite ), m_changeToken( changeToken ), m_stream( stream ), m_contentType( contentType ), m_filename( filename ) { } ~SetContentStream( ) { } void toXml( xmlTextWriterPtr writer ); }; class GetRenditions : public SoapRequest { private: std::string m_repositoryId; std::string m_objectId; std::string m_filter; public: GetRenditions( std::string repoId, std::string objectId, std::string filter ) : m_repositoryId( repoId ), m_objectId( objectId ), m_filter( filter ) { } ~GetRenditions( ) { } void toXml( xmlTextWriterPtr writer ); }; class GetRenditionsResponse : public SoapResponse { private: std::vector< libcmis::RenditionPtr > m_renditions; GetRenditionsResponse( ) : SoapResponse( ), m_renditions( ) { } public: /** Parse cmism:getRenditionsResponse. This function assumes that the node is the expected one: this is normally ensured by the SoapResponseFactory. */ static SoapResponsePtr create( xmlNodePtr node, RelatedMultipart& multipart, SoapSession* session ); std::vector< libcmis::RenditionPtr > getRenditions( ) { return m_renditions; } }; class CheckOut : public SoapRequest { private: std::string m_repositoryId; std::string m_objectId; public: CheckOut( std::string repoId, std::string objectId ) : m_repositoryId( repoId ), m_objectId( objectId ) { } ~CheckOut( ) { } void toXml( xmlTextWriterPtr writer ); }; class CheckOutResponse : public SoapResponse { private: std::string m_objectId; CheckOutResponse( ) : SoapResponse( ), m_objectId( ) { } public: /** Parse cmism:checkOutResponse. This function assumes that the node is the expected one: this is normally ensured by the SoapResponseFactory. */ static SoapResponsePtr create( xmlNodePtr node, RelatedMultipart& multipart, SoapSession* session ); std::string getObjectId( ) { return m_objectId; } }; class CancelCheckOut : public SoapRequest { private: std::string m_repositoryId; std::string m_objectId; public: CancelCheckOut( std::string repoId, std::string objectId ) : m_repositoryId( repoId ), m_objectId( objectId ) { } ~CancelCheckOut( ) { } void toXml( xmlTextWriterPtr writer ); }; class CheckIn : public SoapRequest { private: std::string m_repositoryId; std::string m_objectId; bool m_isMajor; const std::map< std::string, libcmis::PropertyPtr >& m_properties; boost::shared_ptr< std::ostream > m_stream; std::string m_contentType; std::string m_fileName; std::string m_comment; public: CheckIn( std::string repoId, std::string objectId, bool isMajor, const std::map< std::string, libcmis::PropertyPtr >& properties, boost::shared_ptr< std::ostream > stream, std::string contentType, std::string fileName, std::string comment ) : m_repositoryId( repoId ), m_objectId( objectId ), m_isMajor( isMajor ), m_properties( properties ), m_stream( stream ), m_contentType( contentType ), m_fileName( fileName ), m_comment( comment ) { } ~CheckIn( ) { } void toXml( xmlTextWriterPtr writer ); }; class CheckInResponse : public SoapResponse { private: std::string m_objectId; CheckInResponse( ) : SoapResponse( ), m_objectId( ) { } public: /** Parse cmism:checkInResponse. This function assumes that the node is the expected one: this is normally ensured by the SoapResponseFactory. */ static SoapResponsePtr create( xmlNodePtr node, RelatedMultipart& multipart, SoapSession* session ); std::string getObjectId( ) { return m_objectId; } }; class GetAllVersions : public SoapRequest { private: std::string m_repositoryId; std::string m_objectId; public: GetAllVersions( std::string repoId, std::string objectId ) : m_repositoryId( repoId ), m_objectId( objectId ) { } ~GetAllVersions( ) { } void toXml( xmlTextWriterPtr writer ); }; class GetAllVersionsResponse : public SoapResponse { private: std::vector< libcmis::DocumentPtr > m_objects; GetAllVersionsResponse( ) : SoapResponse( ), m_objects( ) { } public: /** Parse cmism:getAllVersionsResponse. This function assumes that the node is the expected one: this is normally ensured by the SoapResponseFactory. */ static SoapResponsePtr create( xmlNodePtr node, RelatedMultipart& multipart, SoapSession* session ); std::vector< libcmis::DocumentPtr > getObjects( ) { return m_objects; } }; #endif libcmis-0.5.2/src/libcmis/onedrive-repository.cxx0000664000175000017500000000371613407173247017067 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "onedrive-repository.hxx" OneDriveRepository::OneDriveRepository( ) : Repository( ) { m_id = "OneDrive"; m_name = "One Drive"; m_description = "One Drive repository"; m_productName = "One Drive"; m_productVersion = "v5"; m_rootId = "me/skydrive"; m_capabilities[ ACL ] = "discover"; m_capabilities[ AllVersionsSearchable ] = "true"; m_capabilities[ Changes ] = "all"; m_capabilities[ GetDescendants ] = "true"; m_capabilities[ GetFolderTree ] = "true"; m_capabilities[ OrderBy ] = "custom"; m_capabilities[ Multifiling ] = "true"; m_capabilities[ PWCSearchable ] = "true"; m_capabilities[ PWCUpdatable ] = "true"; m_capabilities[ Query ] = "bothcombined"; m_capabilities[ Renditions ] = "read"; m_capabilities[ Unfiling ] = "false"; m_capabilities[ VersionSpecificFiling ] = "false"; m_capabilities[ Join ] = "none"; } libcmis-0.5.2/src/libcmis/ws-relatedmultipart.cxx0000664000175000017500000002451113407444425017043 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "ws-relatedmultipart.hxx" #include #include #include #include #include #include #include using namespace std; using namespace boost::uuids; RelatedPart::RelatedPart( string& name, string& type, string& content ) : m_name( name ), m_contentType( type ), m_content( content ) { } // LCOV_EXCL_START string RelatedPart::toString( string cid ) { string buf; buf += "Content-Id: <" + cid + ">\r\n"; buf += "Content-Type: " + getContentType( ) + "\r\n"; buf += "Content-Transfer-Encoding: binary\r\n\r\n"; buf += getContent( ); return buf; } // LCOV_EXCL_STOP RelatedMultipart::RelatedMultipart( ) : m_startId( ), m_startInfo( ), m_parts( ), m_boundary( ) { stringstream tmpStream("--------uuid:"); tmpStream << random_generator()(); m_boundary = tmpStream.str(); } RelatedMultipart::RelatedMultipart( const string& body, const string& contentType ) : m_startId( ), m_startInfo( ), m_parts( ), m_boundary( ) { // Parse the content-type size_t lastPos = 0; size_t pos = contentType.find_first_of( ";\"" ); while ( pos != string::npos ) { bool escaped = contentType[pos] == '"'; if ( escaped ) { // Look for the closing quote and then look for the ; after it pos = contentType.find( "\"", pos + 1 ); pos = contentType.find( ";", pos + 1 ); } string param = contentType.substr( lastPos, pos - lastPos ); size_t eqPos = param.find( "=" ); if ( eqPos != string::npos ) { string name = param.substr( 0, eqPos ); string value = param.substr( eqPos + 1 ); if ( value[0] == '"' && value[value.length() - 1] == '"' ) value = value.substr( 1, value.length( ) - 2 ); name = libcmis::trim( name ); if ( name == "start" ) { m_startId = value; // Remove the '<' '>' around the id if any if ( m_startId[0] == '<' && m_startId[m_startId.size()-1] == '>' ) m_startId = m_startId.substr( 1, m_startId.size() - 2 ); } else if ( name == "boundary" ) m_boundary = value; else if ( name == "start-info" ) m_startInfo = value; } if ( pos != string::npos ) { lastPos = pos + 1; pos = contentType.find_first_of( ";\"", lastPos ); } } // Parse the multipart string bodyFixed( body ); if ( boost::starts_with( bodyFixed, "--" + m_boundary + "\r\n" ) ) bodyFixed = "\r\n" + bodyFixed; if ( bodyFixed[bodyFixed.length() - 1 ] != '\n' ) bodyFixed += '\n'; string lineEnd( "\n" ); string boundaryString( "--" + m_boundary ); string endBoundaryString( "--" + m_boundary + "--" ); pos = bodyFixed.find( lineEnd ); lastPos = 0; bool inPart = false; bool inHeaders = false; string cid; string name; string type; string partBody; while ( pos != string::npos ) { string line = bodyFixed.substr( lastPos, pos - lastPos ); if ( boost::starts_with( line, boundaryString ) ) { // Found a part start inPart = true; if ( !cid.empty() && !type.empty( ) ) { // Remove potential \r at the end of the body part if ( partBody[partBody.length() - 1] == '\r' ) partBody = partBody.substr( 0, partBody.length() - 1 ); RelatedPartPtr relatedPart( new RelatedPart( name, type, partBody ) ); m_parts[cid] = relatedPart; } cid.clear( ); type.clear( ); name.clear( ); partBody.clear( ); inHeaders = true; } else if ( inPart ) { if ( inHeaders ) { // Remove potential \r at the end if ( !line.empty() && line[line.length() - 1] == '\r' ) line = line.substr( 0, line.length() - 1 ); if ( line.empty( ) ) inHeaders = false; else { size_t colonPos = line.find( ":" ); string headerName = line.substr( 0, colonPos ); string headerValue = line.substr( colonPos + 1 ); if ( boost::to_lower_copy( headerName ) == "content-id" ) { cid = libcmis::trim( headerValue ); // Remove the '<' '>' around the id if any if ( cid[0] == '<' && cid[cid.size()-1] == '>' ) cid = cid.substr( 1, cid.size() - 2 ); } else if ( headerName == "Content-Type" ) type = libcmis::trim( headerValue ); // TODO Handle the Content-Transfer-Encoding } } else { if ( !partBody.empty() ) partBody += lineEnd; partBody += line; } } // If we found the end of the multipart, no need to continue looping if ( boost::starts_with( line, endBoundaryString ) ) break; lastPos = pos + lineEnd.length(); pos = bodyFixed.find( lineEnd, lastPos ); } } vector< string > RelatedMultipart::getIds( ) { vector< string > ids; for ( map< string, RelatedPartPtr >::iterator it = m_parts.begin( ); it != m_parts.end( ); ++it ) { ids.push_back( it->first ); } return ids; } RelatedPartPtr RelatedMultipart::getPart( string& cid ) { RelatedPartPtr part; map< string, RelatedPartPtr >::iterator it = m_parts.find( cid ); if ( it != m_parts.end( ) ) part = it->second; return part; } string RelatedMultipart::addPart( RelatedPartPtr part ) { string cid = createPartId( part->getName( ) ); m_parts[cid] = part; return cid; } void RelatedMultipart::setStart( string& cid, string& startInfo ) { RelatedPartPtr start = getPart( cid ); if ( start.get( ) != NULL ) { m_startId = cid; m_startInfo = startInfo; } } string RelatedMultipart::getContentType( ) { string type = "multipart/related;"; RelatedPartPtr start = getPart( getStartId( ) ); if ( start.get( ) != NULL ) { type += "start=\"" + getStartId( ) + "\";"; string startType = start->getContentType( ); size_t pos = startType.find( ";" ); if ( pos != string::npos ) startType = startType.substr( 0, pos ); type += "type=\"" + startType + "\";"; } type += "boundary=\"" + m_boundary + "\";"; type += "start-info=\"" + m_startInfo + "\""; return type; } boost::shared_ptr< istringstream > RelatedMultipart::toStream( ) { string buf; // Output the start part first buf += "\r\n--" + m_boundary + "\r\n"; RelatedPartPtr part = getPart( getStartId( ) ); if ( part.get( ) != NULL ) { buf += part->toString( getStartId( ) ); } for ( map< string, RelatedPartPtr >::iterator it = m_parts.begin( ); it != m_parts.end( ); ++it ) { if ( it->first != getStartId( ) ) { buf += "\r\n--" + m_boundary + "\r\n"; buf += it->second->toString( it->first ); } } buf += "\r\n--" + m_boundary + "--\r\n"; boost::shared_ptr< istringstream > is( new istringstream( buf ) ); return is; } string RelatedMultipart::createPartId( const string& name ) { stringstream tmpStream(name); tmpStream << "*"; tmpStream << random_generator()(); tmpStream << "@libcmis.sourceforge.net"; return tmpStream.str(); } boost::shared_ptr< istream > getStreamFromNode( xmlNodePtr node, RelatedMultipart& multipart ) { boost::shared_ptr< stringstream > stream; for ( xmlNodePtr child = node->children; child; child = child->next ) { if ( xmlStrEqual( child->name, BAD_CAST( "Include" ) ) ) { // Get the content from the multipart xmlChar* value = xmlGetProp( child, BAD_CAST( "href" ) ); string href( ( char* )value ); xmlFree( value ); // Get the Content ID from the href (cid:content-id) string id = href; if ( href.substr( 0, 4 ) == "cid:" ) { id = href.substr( 4 ); // URL-decode the id id = libcmis::unescape( id ); } RelatedPartPtr part = multipart.getPart( id ); if ( part != NULL ) stream.reset( new stringstream( part->getContent( ) ) ); } } // If there was no xop:Include, then use the content as base64 data if ( stream.get( ) == NULL ) { xmlChar* content = xmlNodeGetContent( node ); stream.reset( new stringstream( ) ); libcmis::EncodedData decoder( stream.get( ) ); decoder.setEncoding( "base64" ); decoder.decode( ( void* )content, 1, xmlStrlen( content ) ); decoder.finish( ); xmlFree( content ); } return stream; } libcmis-0.5.2/src/libcmis/sharepoint-repository.cxx0000664000175000017500000000525713407173247017432 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "sharepoint-repository.hxx" SharePointRepository::SharePointRepository( std::string baseUrl ) : Repository( ) { m_id = "SharePoint"; m_name = "SharePoint"; m_description = "SharePoint repository"; m_productName = "SharePoint"; m_productVersion = "2010/2013"; // getFolderByServerRelativeUrl() API expects path to be // *server-relative*, i.e. they must include site path. // Given the baseUrl like "https://sp2013/sites/mysite/_api/Web" // for a site "mysite" on sharepoint server "sp2013", // the site root is '/sites/mysite/', not '/'. // Trying to get folder '/' results in "Value does not fall // within expected range" error. // Preferrable here is to extract the root path from baseUrl, // stripping server and api parts. But it can be unreliable // if api part (_api/Web) is different for some server. // On the other side, just querying empty path '' gives the root folder. m_rootId = baseUrl + "/getFolderByServerRelativeUrl('')"; m_capabilities[ ACL ] = "discover"; m_capabilities[ AllVersionsSearchable ] = "true"; m_capabilities[ Changes ] = "all"; m_capabilities[ GetDescendants ] = "true"; m_capabilities[ GetFolderTree ] = "true"; m_capabilities[ OrderBy ] = "custom"; m_capabilities[ Multifiling ] = "true"; m_capabilities[ PWCSearchable ] = "true"; m_capabilities[ PWCUpdatable ] = "true"; m_capabilities[ Query ] = "bothcombined"; m_capabilities[ Renditions ] = "read"; m_capabilities[ Unfiling ] = "false"; m_capabilities[ VersionSpecificFiling ] = "false"; m_capabilities[ Join ] = "none"; } libcmis-0.5.2/src/libcmis/ws-object-type.hxx0000664000175000017500000000337013407414352015707 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _WS_OBJECT_TYPE_HXX_ #define _WS_OBJECT_TYPE_HXX_ #include #include "ws-session.hxx" class WSObjectType : public libcmis::ObjectType { private: WSSession* m_session; public: WSObjectType( WSSession* session, xmlNodePtr node ); WSObjectType( const WSObjectType& copy ); virtual ~WSObjectType( ); WSObjectType& operator=( const WSObjectType& copy ); virtual void refresh( ); virtual libcmis::ObjectTypePtr getParentType( ); virtual libcmis::ObjectTypePtr getBaseType( ); virtual std::vector< libcmis::ObjectTypePtr > getChildren( ); private: WSObjectType( ); }; #endif libcmis-0.5.2/src/libcmis/gdrive-object-type.hxx0000664000175000017500000000267513407414352016545 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _GDRIVE_OBJECT_TYPE_HXX_ #define _GDRIVE_OBJECT_TYPE_HXX_ #include #include "json-utils.hxx" class GdriveObjectType: public libcmis::ObjectType { public: GdriveObjectType( const std::string& id ); virtual libcmis::ObjectTypePtr getParentType( ); virtual libcmis::ObjectTypePtr getBaseType( ); }; #endif libcmis-0.5.2/src/libcmis/http-session.hxx0000664000175000017500000001243213407414352015472 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _HTTP_SESSION_HXX_ #define _HTTP_SESSION_HXX_ #include #include #include #include #include #include #include #include #include #include class OAuth2Handler; class CurlException : public std::exception { private: std::string m_message; CURLcode m_code; std::string m_url; long m_httpStatus; bool m_cancelled; mutable std::string m_errorMessage; public: CurlException( std::string message, CURLcode code, std::string url, long httpStatus ) : exception( ), m_message( message ), m_code( code ), m_url( url ), m_httpStatus( httpStatus ), m_cancelled( false ), m_errorMessage( ) { } CurlException( std::string message ) : exception( ), m_message( message ), m_code( CURLE_OK ), m_url( ), m_httpStatus( 0 ), m_cancelled( true ), m_errorMessage( ) { } ~CurlException( ) noexcept { } virtual const char* what( ) const noexcept; CURLcode getErrorCode( ) const { return m_code; } std::string getErrorMessage( ) const { return m_message; } bool isCancelled( ) const { return m_cancelled; } long getHttpStatus( ) const { return m_httpStatus; } libcmis::Exception getCmisException ( ) const; }; class HttpSession { protected: CURL* m_curlHandle; private: bool m_no100Continue; protected: OAuth2Handler* m_oauth2Handler; std::string m_username; std::string m_password; bool m_authProvided; bool m_verbose; bool m_noHttpErrors; bool m_noSSLCheck; bool m_refreshedToken; bool m_inOAuth2Authentication; unsigned long m_authMethod; public: HttpSession( std::string username, std::string password, bool noSslCheck = false, libcmis::OAuth2DataPtr oauth2 = libcmis::OAuth2DataPtr(), bool verbose = false ); HttpSession( const HttpSession& copy ); virtual ~HttpSession( ); HttpSession& operator=( const HttpSession& copy ); std::string& getUsername( ); std::string& getPassword( ); /** Don't throw the HTTP errors as CurlExceptions. */ void setNoHttpErrors( bool noHttpErrors ) { m_noHttpErrors = noHttpErrors; } /** Set the OAuth2 data and get the access / refresh tokens. */ virtual void setOAuth2Data( libcmis::OAuth2DataPtr oauth2 ); libcmis::HttpResponsePtr httpGetRequest( std::string url ); libcmis::HttpResponsePtr httpPutRequest( std::string url, std::istream& is, std::vector< std::string > headers ); libcmis::HttpResponsePtr httpPostRequest( const std::string& url, std::istream& is, const std::string& contentType, bool redirect = true ); void httpDeleteRequest( std::string url ); long getHttpStatus( ); void setNoSSLCertificateCheck( bool noCheck ); std::string getRefreshToken( ); protected: HttpSession( ); /** Helper function actually handling the oauth2 process. This function is provided for BaseSession to customize the OAuth2 login parser. */ void oauth2Authenticate( ); void setAuthMethod( unsigned long authMethod ) { m_authMethod = authMethod; } virtual void httpRunRequest( std::string url, std::vector< std::string > headers = std::vector< std::string > ( ), bool redirect = true ); private: void checkCredentials( ); void checkOAuth2( std::string url ); void oauth2Refresh( ); void initProtocols( ); }; #endif libcmis-0.5.2/src/libcmis/onedrive-object.cxx0000664000175000017500000001253613407414352016111 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "onedrive-object.hxx" #include "onedrive-allowable-actions.hxx" #include "onedrive-property.hxx" #include "onedrive-repository.hxx" #include "onedrive-utils.hxx" using namespace std; using namespace libcmis; OneDriveObject::OneDriveObject( OneDriveSession* session ) : libcmis::Object( session ) { } OneDriveObject::OneDriveObject( OneDriveSession* session, Json json, string id, string name ) : libcmis::Object( session ) { initializeFromJson( json, id, name ); } OneDriveObject::OneDriveObject( const OneDriveObject& copy ) : libcmis::Object( copy ) { } OneDriveObject& OneDriveObject::operator=( const OneDriveObject& copy ) { if ( this != © ) { libcmis::Object::operator=( copy ); } return *this; } void OneDriveObject::initializeFromJson ( Json json, string /*id*/, string /*name*/ ) { Json::JsonObject objs = json.getObjects( ); Json::JsonObject::iterator it; PropertyPtr property; bool isFolder = json["type"].toString( ) == "folder"; for ( it = objs.begin( ); it != objs.end( ); ++it) { property.reset( new OneDriveProperty( it->first, it->second ) ); m_properties[ property->getPropertyType( )->getId()] = property; if ( it->first == "name" && !isFolder ) { property.reset( new OneDriveProperty( "cmis:contentStreamFileName", it->second ) ); m_properties[ property->getPropertyType( )->getId()] = property; } } m_refreshTimestamp = time( NULL ); m_allowableActions.reset( new OneDriveAllowableActions( isFolder ) ); } OneDriveSession* OneDriveObject::getSession( ) { return dynamic_cast< OneDriveSession* > ( m_session ); } void OneDriveObject::refreshImpl( Json json ) { m_typeDescription.reset( ); m_properties.clear( ); initializeFromJson( json ); } void OneDriveObject::refresh( ) { string res; try { res = getSession()->httpGetRequest( getUrl( ) )->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } Json json = Json::parse( res ); refreshImpl( json ); } void OneDriveObject::remove( bool /*allVersions*/ ) { try { getSession( )->httpDeleteRequest( getUrl( ) ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } } string OneDriveObject::getUrl( ) { return getSession( )->getBindingUrl( ) + "/" + getId( ); } string OneDriveObject::getUploadUrl( ) { return getUrl( ) + "/files"; } vector< string> OneDriveObject::getMultiStringProperty( const string& propertyName ) { vector< string > values; PropertyPtrMap::const_iterator it = getProperties( ).find( string( propertyName ) ); if ( it != getProperties( ).end( ) && it->second != NULL && !it->second->getStrings( ).empty( ) ) values = it->second->getStrings( ); return values; } libcmis::ObjectPtr OneDriveObject::updateProperties( const PropertyPtrMap& properties ) { // Make Json object from properties Json json = OneDriveUtils::toOneDriveJson( properties ); istringstream is( json.toString( )); libcmis::HttpResponsePtr response; try { vector< string > headers; headers.push_back( "Content-Type: application/json" ); response = getSession( )->httpPutRequest( getUrl( ), is, headers ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } string res = response->getStream( )->str( ); Json jsonRes = Json::parse( res ); libcmis::ObjectPtr updated = getSession()->getObjectFromJson( jsonRes ); if ( updated->getId( ) == getId( ) ) refreshImpl( jsonRes ); return updated; } void OneDriveObject::move( FolderPtr /*source*/, FolderPtr destination ) { Json destJson; Json destId( destination->getId( ).c_str( ) ); destJson.add( "destination", destId ); istringstream is( destJson.toString( ) ); libcmis::HttpResponsePtr response; try { string url = getUrl( ) + "?method=MOVE"; response = getSession( )->httpPostRequest( url, is, "application/json" ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } string res = response->getStream( )->str( ); Json jsonRes = Json::parse( res ); refreshImpl( jsonRes ); } libcmis-0.5.2/src/libcmis/sharepoint-utils.cxx0000664000175000017500000001015413407414352016336 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "sharepoint-utils.hxx" #include #include #include "json-utils.hxx" using namespace std; using libcmis::PropertyPtrMap; string SharePointUtils::toCmisKey( const string& key ) { string convertedKey; if ( key == "__metadata") convertedKey = "cmis:objectId"; else if ( key == "CheckInComment" ) convertedKey = "cmis:checkinComment"; else if ( key == "TimeCreated" ) convertedKey = "cmis:creationDate"; else if ( key == "TimeLastModified" || key == "Created" ) convertedKey = "cmis:lastModificationDate"; else if ( key == "Name" ) convertedKey = "cmis:name"; else if ( key == "CheckOutType" ) convertedKey = "cmis:isVersionSeriesCheckedOut"; else if ( key == "UIVersionLabel" || key == "VersionLabel" ) convertedKey = "cmis:versionLabel"; else if ( key == "Length" || key == "Size" ) convertedKey = "cmis:contentStreamLength"; else convertedKey = key; return convertedKey; } libcmis::PropertyType::Type SharePointUtils::getPropertyType( const string& key ) { libcmis::PropertyType::Type propertyType; if ( key == "cmis:creationDate" || key == "cmis:lastModificationDate" ) { propertyType = libcmis::PropertyType::DateTime; } else if ( key == "cmis:contentStreamLength" ) { propertyType = libcmis::PropertyType::Integer; } else if ( key == "cmis:isVersionSeriesCheckedOut" ) { propertyType = libcmis::PropertyType::Bool; } else { propertyType = libcmis::PropertyType::String; } return propertyType; } vector< string > SharePointUtils::parseSharePointProperty( string key, Json json ) { vector< string > values; if ( key == "__metadata" ) { string id = json["uri"].toString( ); values.push_back( id ); } if ( key == "Author" || key == "CheckedOutByUser" || key == "CreatedBy" || key == "Files" || key == "Folders" || key == "ListItemAllFields" || key == "LockedByUser" || key == "ModifiedBy" || key == "ParentFolder" || key == "Properties" || key == "Versions" ) { string propertyUri = json["__deferred"]["uri"].toString( ); values.push_back( propertyUri ); } if ( key == "CheckOutType" ) { // Online = 0, Offline = 1, None = 2 if ( json.toString( ) == "2" ) { values.push_back( "false" ); } else { values.push_back( "true" ); } } else values.push_back( json.toString( ) ); return values; } bool SharePointUtils::isSharePoint( string response ) { const boost::shared_ptr< xmlDoc > doc( xmlReadMemory( response.c_str( ), response.size( ), "noname.xml", NULL, 0 ), xmlFreeDoc ); const boost::shared_ptr< xmlXPathContext > xpath( xmlXPathNewContext( doc.get() ), xmlXPathFreeContext ); return "SP.Web" == libcmis::getXPathValue( xpath.get(), "//@term" ); } libcmis-0.5.2/src/libcmis/sharepoint-allowable-actions.hxx0000664000175000017500000001355613407414352020614 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Varga Mihai * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _SHAREPOINT_ALLOWABLE_ACTIONS_HXX_ #define _SHAREPOINT_ALLOWABLE_ACTIONS_HXX_ #include class SharePointAllowableActions: public libcmis::AllowableActions { public: SharePointAllowableActions( bool isFolder ) : AllowableActions( ) { m_states.clear( ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::DeleteObject, true ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::UpdateProperties, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetProperties, true ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetObjectRelationships, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetObjectParents, true ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::MoveObject, true ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::CreateRelationship, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::ApplyPolicy, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetAppliedPolicies, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::RemovePolicy, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetACL, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::ApplyACL, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetFolderTree, isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetFolderParent, isFolder) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetDescendants, isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::DeleteContentStream, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::CheckOut, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::CancelCheckOut, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::CheckIn, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetContentStream, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::SetContentStream, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetAllVersions, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::AddObjectToFolder, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::RemoveObjectFromFolder, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetRenditions, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetChildren, isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::CreateDocument, isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::CreateFolder, isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::DeleteTree, isFolder ) ); } }; #endif libcmis-0.5.2/src/libcmis/ws-navigationservice.hxx0000664000175000017500000000342513407414352017203 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _WS_NAVIGATIONSERVICE_HXX_ #define _WS_NAVIGATIONSERVICE_HXX_ #include #include #include class WSSession; class NavigationService { private: WSSession* m_session; std::string m_url; public: NavigationService( WSSession* session ); NavigationService( const NavigationService& copy ); ~NavigationService( ); NavigationService& operator=( const NavigationService& copy ); std::vector< libcmis::FolderPtr > getObjectParents( std::string repoId, std::string objectId ); std::vector< libcmis::ObjectPtr > getChildren( std::string repoId, std::string folderId ); private: NavigationService( ); }; #endif libcmis-0.5.2/src/libcmis/onedrive-document.cxx0000664000175000017500000001317513407414352016461 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "onedrive-document.hxx" #include #include "onedrive-folder.hxx" #include "onedrive-session.hxx" #include "onedrive-utils.hxx" #include "json-utils.hxx" using namespace std; using namespace libcmis; OneDriveDocument::OneDriveDocument( OneDriveSession* session ) : libcmis::Object( session), libcmis::Document( session ), OneDriveObject( session ) { } OneDriveDocument::OneDriveDocument( OneDriveSession* session, Json json, string id, string name ) : libcmis::Object( session), libcmis::Document( session ), OneDriveObject( session, json, id, name ) { } OneDriveDocument::~OneDriveDocument( ) { } vector< libcmis::FolderPtr > OneDriveDocument::getParents( ) { vector< libcmis::FolderPtr > parents; string parentId = getStringProperty( "cmis:parentId" ); libcmis::ObjectPtr obj = getSession( )->getObject( parentId ); libcmis::FolderPtr parent = boost::dynamic_pointer_cast< libcmis::Folder >( obj ); parents.push_back( parent ); return parents; } boost::shared_ptr< istream > OneDriveDocument::getContentStream( string /*streamId*/ ) { boost::shared_ptr< istream > stream; string streamUrl = getStringProperty( "source" ); if ( streamUrl.empty( ) ) throw libcmis::Exception( "can not found stream url" ); try { stream = getSession( )->httpGetRequest( streamUrl )->getStream( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } return stream; } void OneDriveDocument::setContentStream( boost::shared_ptr< ostream > os, string /*contentType*/, string fileName, bool /*overwrite*/ ) { if ( !os.get( ) ) throw libcmis::Exception( "Missing stream" ); string metaUrl = getUrl( ); // Update file name meta information if ( !fileName.empty( ) && fileName != getContentFilename( ) ) { Json metaJson; Json fileJson( fileName.c_str( ) ); metaJson.add("name", fileJson ); std::istringstream is( metaJson.toString( ) ); vector headers; headers.push_back( "Content-Type: application/json" ); try { getSession()->httpPutRequest( metaUrl, is, headers ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } } fileName = libcmis::escape( getStringProperty( "cmis:name" ) ); string putUrl = getSession( )->getBindingUrl( ) + "/" + getStringProperty( "cmis:parentId" ) + "/files/" + fileName + "?overwrite=true"; // Upload stream boost::shared_ptr< istream> is ( new istream ( os->rdbuf( ) ) ); vector headers; try { getSession()->httpPutRequest( putUrl, *is, headers ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } long httpStatus = getSession( )->getHttpStatus( ); if ( httpStatus < 200 || httpStatus >= 300 ) throw libcmis::Exception( "Document content wasn't set for" "some reason" ); refresh( ); } libcmis::DocumentPtr OneDriveDocument::checkOut( ) { // OneDrive doesn't have CheckOut, so just return the same document here libcmis::ObjectPtr obj = getSession( )->getObject( getId( ) ); libcmis::DocumentPtr checkout = boost::dynamic_pointer_cast< libcmis::Document > ( obj ); return checkout; } void OneDriveDocument::cancelCheckout( ) { // Don't do anything since we don't have CheckOut } libcmis::DocumentPtr OneDriveDocument::checkIn( bool /*isMajor*/, std::string /*comment*/, const PropertyPtrMap& properties, boost::shared_ptr< std::ostream > stream, std::string contentType, std::string fileName ) { // OneDrive doesn't have CheckIn, so just upload the properties, // the content stream and fetch the new document resource. updateProperties( properties ); setContentStream( stream, contentType, fileName ); libcmis::ObjectPtr obj = getSession( )->getObject( getId( ) ); libcmis::DocumentPtr checkin = boost::dynamic_pointer_cast< libcmis::Document > ( obj ); return checkin; } vector< libcmis::DocumentPtr > OneDriveDocument::getAllVersions( ) { return vector< libcmis::DocumentPtr > ( ); } libcmis-0.5.2/src/libcmis/sharepoint-folder.cxx0000664000175000017500000001435013407414352016453 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "sharepoint-folder.hxx" #include "sharepoint-document.hxx" #include "sharepoint-session.hxx" #include "sharepoint-property.hxx" #include "sharepoint-utils.hxx" using namespace std; using namespace libcmis; SharePointFolder::SharePointFolder( SharePointSession* session ): libcmis::Object( session ), libcmis::Folder( session ), SharePointObject( session ) { } SharePointFolder::SharePointFolder( SharePointSession* session, Json json, string parentId ): libcmis::Object( session ), libcmis::Folder( session ), SharePointObject( session, json, parentId ) { } SharePointFolder::~SharePointFolder( ) { } string SharePointFolder::getParentId( ) { string parentId = getStringProperty( "cmis:parentId" ); if ( parentId.empty( ) ) { string parentUrl = getStringProperty( "ParentFolder" ); string res; try { res = getSession( )->httpGetRequest( parentUrl )->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } Json jsonRes = Json::parse( res ); parentId = jsonRes["d"]["__metadata"]["uri"].toString( ); PropertyPtr property; property.reset( new SharePointProperty( "cmis:parentId", Json( parentId.c_str( ) ) ) ); m_properties[ property->getPropertyType( )->getId()] = property; } return parentId; } vector< libcmis::ObjectPtr > SharePointFolder::getChildren( ) { vector< libcmis::ObjectPtr > children; string filesUrl = getStringProperty( "Files" ); string foldersUrl = getStringProperty( "Folders" ); Json::JsonVector objs = getChildrenImpl( filesUrl ); Json::JsonVector folders = getChildrenImpl( foldersUrl ); objs.insert( objs.begin( ), folders.begin( ), folders.end( ) ); for ( unsigned int i = 0; i < objs.size( ); i++) { children.push_back( getSession( )->getObjectFromJson( objs[i], getId( ) ) ); } return children; } Json::JsonVector SharePointFolder::getChildrenImpl( string url ) { string res; try { res = getSession( )->httpGetRequest( url )->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } Json jsonRes = Json::parse( res ); Json::JsonVector objs = jsonRes["d"]["results"].getList( ); return objs; } libcmis::FolderPtr SharePointFolder::createFolder( const PropertyPtrMap& properties ) { string folderName; for ( PropertyPtrMap::const_iterator it = properties.begin() ; it != properties.end() ; ++it ) { if ( it->first == "cmis:name" ) { folderName = it->second->toString( ); } } // bindingUrl/folders/add('/path/to/folder') string relativeUrl; if ( getStringProperty( "ServerRelativeUrl" ) == "/" ) { relativeUrl = "/" + folderName; } else { relativeUrl = getStringProperty( "ServerRelativeUrl" ) + "/" + folderName; } relativeUrl = libcmis::escape( relativeUrl ); string folderUrl = getSession( )->getBindingUrl( ); folderUrl += "/folders/add('" + relativeUrl + "')"; istringstream is( "" ); string res; try { res = getSession( )->httpPostRequest( folderUrl, is, "" )->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } Json jsonRes = Json::parse( res ); libcmis::FolderPtr newFolder( new SharePointFolder( getSession( ), jsonRes, getId( ) ) ); return newFolder; } libcmis::DocumentPtr SharePointFolder::createDocument( const PropertyPtrMap& properties, boost::shared_ptr< ostream > os, string contentType, string fileName ) { if ( !os.get( ) ) throw libcmis::Exception( "Missing stream" ); if ( fileName.empty( ) ) { for ( PropertyPtrMap::const_iterator it = properties.begin() ; it != properties.end() ; ++it ) { if ( it->first == "cmis:name" || it->first == "cmis:contentStreamFileName" ) { fileName = it->second->toString( ); } } } fileName = libcmis::escape( fileName ); string url = getId( ) + "/files/add(overwrite=true,"; url += "url='" + fileName + "')"; // Upload stream boost::shared_ptr< istream> is ( new istream ( os->rdbuf( ) ) ); string res; try { res = getSession( )->httpPostRequest( url, *is, contentType )->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } Json jsonRes = Json::parse( res ); DocumentPtr document( new SharePointDocument( getSession( ), jsonRes, getId( ) ) ); return document; } vector< string > SharePointFolder::removeTree( bool /*allVersions*/, libcmis::UnfileObjects::Type /*unfile*/, bool /*continueOnError*/ ) { remove( ); // Nothing to return here return vector< string >( ); } libcmis-0.5.2/src/libcmis/ws-object-type.cxx0000664000175000017500000000455013407414352015703 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "ws-object-type.hxx" using namespace std; WSObjectType::WSObjectType( WSSession* session, xmlNodePtr node ) : libcmis::ObjectType( node ), m_session( session ) { } WSObjectType::WSObjectType( ) : libcmis::ObjectType( ), m_session( NULL ) { } WSObjectType::WSObjectType( const WSObjectType& copy ) : libcmis::ObjectType( copy ), m_session( copy.m_session ) { } WSObjectType::~WSObjectType( ) { } WSObjectType& WSObjectType::operator=( const WSObjectType& copy ) { if ( this != © ) { libcmis::ObjectType::operator=( copy ); m_session = copy.m_session; } return *this; } void WSObjectType::refresh( ) { libcmis::ObjectTypePtr type = m_session->getType( m_id ); WSObjectType* const other = dynamic_cast< WSObjectType* >( type.get( ) ); if ( other != NULL ) *this = *other; } libcmis::ObjectTypePtr WSObjectType::getParentType( ) { return m_session->getType( m_parentTypeId ); } libcmis::ObjectTypePtr WSObjectType::getBaseType( ) { return m_session->getType( m_baseTypeId ); } vector< libcmis::ObjectTypePtr > WSObjectType::getChildren( ) { vector< libcmis::ObjectTypePtr > children; children = m_session->getRepositoryService( ).getTypeChildren( m_session->getRepositoryId( ), m_id ); return children; } libcmis-0.5.2/src/libcmis/oauth2-handler.hxx0000664000175000017500000000546713407414352015661 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _OAUTH2_HANDLER_HXX_ #define _OAUTH2_HANDLER_HXX_ #include #include "http-session.hxx" #include "oauth2-providers.hxx" namespace libcmis { class OAuth2Data; } class OAuth2Handler { private: HttpSession* m_session; libcmis::OAuth2DataPtr m_data; std::string m_access; std::string m_refresh; OAuth2Parser m_oauth2Parser; public: OAuth2Handler( HttpSession* session, libcmis::OAuth2DataPtr data ); OAuth2Handler( const OAuth2Handler& copy ); ~OAuth2Handler( ); OAuth2Handler& operator=( const OAuth2Handler& copy ); std::string getAuthURL(); std::string getAccessToken( ) ; std::string getRefreshToken( ) ; // adding HTTP auth header std::string getHttpHeader( ) ; /** Exchange the previously obtained authentication code with the access/refresh tokens. \param authCode the authentication code normally obtained from authenticate method. */ void fetchTokens( std::string authCode ); void refresh( ); /** Get the authentication code given credentials. This method should be overridden to parse the authentication URL response, authenticate using the form and get the token to avoid asking the user to launch a web browser and do it himself. \return the authentication code to transform into access/refresh tokens. If no code is found, an empty string is returned. */ std::string oauth2Authenticate( ); void setOAuth2Parser( OAuth2Parser parser ); protected: OAuth2Handler( ); }; #endif /* _OAUTH2_HANDLER_HXX_ */ libcmis-0.5.2/src/libcmis/ws-folder.hxx0000664000175000017500000000403113407414352014730 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _WS_FOLDER_HXX_ #define _WS_FOLDER_HXX_ #include #include #include "ws-object.hxx" #include "ws-session.hxx" class WSFolder : public libcmis::Folder, public WSObject { public: WSFolder( const WSObject& object ); virtual ~WSFolder( ); // virtual pure methods from Folder virtual std::vector< libcmis::ObjectPtr > getChildren( ); virtual libcmis::FolderPtr createFolder( const std::map< std::string, libcmis::PropertyPtr >& properties ); virtual libcmis::DocumentPtr createDocument( const std::map< std::string, libcmis::PropertyPtr >& properties, boost::shared_ptr< std::ostream > os, std::string contentType, std::string fileName ); virtual std::vector< std::string > removeTree( bool allVersion = true, libcmis::UnfileObjects::Type unfile = libcmis::UnfileObjects::Delete, bool continueOnError = false ); }; #endif libcmis-0.5.2/src/libcmis/sharepoint-object-type.hxx0000664000175000017500000000271013407414352017427 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _SHAREPOINT_OBJECT_TYPE_HXX_ #define _SHAREPOINT_OBJECT_TYPE_HXX_ #include #include "json-utils.hxx" class SharePointObjectType: public libcmis::ObjectType { public: SharePointObjectType( const std::string& id ); virtual libcmis::ObjectTypePtr getParentType( ); virtual libcmis::ObjectTypePtr getBaseType( ); }; #endif libcmis-0.5.2/src/libcmis/ws-object.hxx0000664000175000017500000000367513407414352014740 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _WS_OBJECT_HXX_ #define _WS_OBJECT_HXX_ #include #include #include "ws-session.hxx" class WSObject : public virtual libcmis::Object { protected: WSObject( WSSession* session ); public: WSObject( WSSession* session, xmlNodePtr node ); WSObject( const WSObject& copy ); virtual ~WSObject( ); WSObject& operator=( const WSObject& copy ); virtual std::vector< libcmis::RenditionPtr > getRenditions( std::string filter ); virtual libcmis::ObjectPtr updateProperties( const std::map< std::string, libcmis::PropertyPtr >& properties ); virtual void refresh( ); virtual void remove( bool allVersions = true ); virtual void move( libcmis::FolderPtr source, libcmis::FolderPtr destination ); WSSession* getSession( ); }; #endif libcmis-0.5.2/src/libcmis/sharepoint-object-type.cxx0000664000175000017500000001012513407414352017421 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "sharepoint-object-type.hxx" SharePointObjectType::SharePointObjectType( const std::string& id ): ObjectType( ) { m_id = id; m_localName = "SharePoint Object Type"; m_localNamespace = "SharePoint Object Type"; m_displayName = "SharePoint Object Type"; m_queryName = "SharePoint Object Type"; m_description = "SharePoint Object Type"; m_parentTypeId = id; m_baseTypeId = id; m_creatable = true; m_versionable = true; m_fulltextIndexed = true; libcmis::PropertyTypePtr idType(new libcmis::PropertyType( ) ); idType->setId( "cmis:objectTypeId" ); idType->setType( libcmis::PropertyType::String ); m_propertiesTypes[ idType->getId( ) ] = idType; // create PropertyTypes which are updatable. // name libcmis::PropertyTypePtr nameType( new libcmis::PropertyType( ) ); nameType->setId( "cmis:name" ); nameType->setType( libcmis::PropertyType::String ); nameType->setUpdatable( true ); m_propertiesTypes[ nameType->getId( ) ] = nameType; // streamFileName libcmis::PropertyTypePtr streamFileNameType( new libcmis::PropertyType( ) ); streamFileNameType->setId( "cmis:contentStreamFileName" ); streamFileNameType->setType( libcmis::PropertyType::String ); streamFileNameType->setUpdatable( true ); m_propertiesTypes[ streamFileNameType->getId( ) ] = streamFileNameType; // modifiedDate libcmis::PropertyTypePtr modifiedDateType( new libcmis::PropertyType( ) ); modifiedDateType->setId( "cmis:lastModificationDate" ); modifiedDateType->setType( libcmis::PropertyType::DateTime ); modifiedDateType->setUpdatable( false ); m_propertiesTypes[ modifiedDateType->getId( ) ] = modifiedDateType; // creationDate libcmis::PropertyTypePtr creationDateType( new libcmis::PropertyType( ) ); creationDateType->setId( "cmis:creationDate" ); creationDateType->setType( libcmis::PropertyType::DateTime ); creationDateType->setUpdatable( false ); m_propertiesTypes[ creationDateType->getId( ) ] = creationDateType; // size libcmis::PropertyTypePtr contentStreamLength( new libcmis::PropertyType( ) ); contentStreamLength->setId( "cmis:contentStreamLength" ); contentStreamLength->setType( libcmis::PropertyType::Integer ); contentStreamLength->setUpdatable( false ); m_propertiesTypes[ contentStreamLength->getId( ) ] = contentStreamLength; // checkinComment libcmis::PropertyTypePtr checkinComment( new libcmis::PropertyType( ) ); checkinComment->setId( "cmis:checkinComment" ); checkinComment->setType( libcmis::PropertyType::String ); checkinComment->setUpdatable( false ); m_propertiesTypes[ checkinComment->getId( ) ] = checkinComment; } libcmis::ObjectTypePtr SharePointObjectType::getParentType( ) { libcmis::ObjectTypePtr parentTypePtr( new SharePointObjectType( m_parentTypeId ) ); return parentTypePtr; } libcmis::ObjectTypePtr SharePointObjectType::getBaseType( ) { libcmis::ObjectTypePtr baseTypePtr( new SharePointObjectType( m_baseTypeId ) ); return baseTypePtr; } libcmis-0.5.2/src/libcmis/gdrive-utils.cxx0000664000175000017500000001625513410752465015456 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "gdrive-utils.hxx" #include #include "json-utils.hxx" using namespace std; using libcmis::PropertyPtrMap; string GdriveUtils::toCmisKey( const string& key ) { string convertedKey; if ( key == "id") convertedKey = "cmis:objectId"; else if ( key == "ownerNames" ) convertedKey = "cmis:createdBy"; else if ( key == "description" ) convertedKey = "cmis:description"; else if ( key == "createdDate" ) convertedKey = "cmis:creationDate"; else if ( key == "lastModifyingUserName" ) convertedKey = "cmis:lastModifiedBy"; else if ( key == "modifiedDate" ) convertedKey = "cmis:lastModificationDate"; else if ( key == "title" ) convertedKey = "cmis:contentStreamFileName"; else if ( key == "mimeType" ) convertedKey = "cmis:contentStreamMimeType"; else if ( key == "fileSize" ) convertedKey = "cmis:contentStreamLength"; else if ( key == "editable" ) convertedKey = "cmis:isImmutable"; else if ( key == "parents" ) convertedKey = "cmis:parentId"; else convertedKey = key; return convertedKey; } string GdriveUtils::toGdriveKey( const string& key ) { string convertedKey; if ( key == "cmis:objectId") convertedKey = "id"; else if ( key == "cmis:createdBy" ) convertedKey = "ownerNames"; else if ( key == "cmis:creationDate" ) convertedKey = "createdDate"; else if ( key == "cmis:description" ) convertedKey = "description"; else if ( key == "cmis:lastModifiedBy" ) convertedKey = "lastModifyingUserName"; else if ( key == "cmis:lastModificationDate" ) convertedKey = "modifiedDate"; else if ( key == "cmis:contentStreamFileName" ) convertedKey = "title"; else if ( key == "cmis:name" ) convertedKey = "title"; else if ( key == "cmis:contentStreamMimeType" ) convertedKey = "mimeType"; else if ( key == "cmis:contentStreamLength" ) convertedKey = "fileSize"; else if ( key == "cmis:isImmutable" ) convertedKey = "editable"; else if ( key == "cmis:parentId" ) convertedKey = "parents"; else convertedKey = key; return convertedKey; } Json GdriveUtils::toGdriveJson( const PropertyPtrMap& properties ) { Json propsJson; // check if cmis:name and cmis:contentStreamFileName has been duplicated bool duplicated = false; for ( PropertyPtrMap::const_iterator it = properties.begin() ; it != properties.end() ; ++it ) { string key = it->first; Json value( it->second ); // Convert the key back to the gdrive key // take one of the two: cmis:name and cmis:contentStreamFileName const bool isName = key == "cmis:name" || key == "cmis:contentStreamFileName"; if ( !isName || !duplicated ) propsJson.add( toGdriveKey( key ), value ); if ( isName ) duplicated = true; } return propsJson; } bool GdriveUtils::checkUpdatable( const string& key ) { // taken from https://developers.google.com/drive/v2/reference/files bool updatable = ( key == "title" || key == "description" || key == "modifiedDate" || key == "lastViewedByMeDate" ); return updatable; } bool GdriveUtils::checkMultiValued( const string& key ) { bool bMultiValued = ( key == "parents" || key == "exportLinks" || key == "labels" || key == "ownersName" || key == "owners"); return bMultiValued; } Json GdriveUtils::createJsonFromParentId( const string& parentId ) { Json parentValue( parentId.c_str( ) ); // parents is a Json array Json firstParent; firstParent.add( "id", parentValue ); Json::JsonVector parents; parents.insert( parents.begin( ), firstParent ); Json parentsValue( parents ); return parentsValue; } vector< string > GdriveUtils::parseGdriveProperty( string key, Json json ) { vector< string > values; if ( key == "owners" ) { Json::JsonVector owners = json.getList( ); for ( Json::JsonVector::iterator it = owners.begin( ); it != owners.end( ); ++it ) { string ownerName = ( *it )["displayName"].toString( ); values.push_back( ownerName); } } else if ( key == "lastModifyingUser" ) { string ownerName = json["displayName"].toString( ); values.push_back( ownerName); } else if ( key == "userPermission" ) { string ownerName = json["role"].toString( ); values.push_back( ownerName); } else if ( key == "ownerNames" ) { Json::JsonVector owners = json.getList( ); for ( Json::JsonVector::iterator it = owners.begin( ); it != owners.end( ); ++it ) { string ownerName = ( *it )[""].toString( ); values.push_back( ownerName); } } else if ( key == "parents" ) { Json::JsonVector owners = json.getList( ); for ( Json::JsonVector::iterator it = owners.begin( ); it != owners.end( ); ++it ) { string ownerName = ( *it )["id"].toString( ); values.push_back( ownerName); } } else if ( key == "exportLinks" ) { Json::JsonObject exportLinks = json.getObjects( ); for ( Json::JsonObject::iterator it = exportLinks.begin( ); it != exportLinks.end( ); ++it ) { string mimeType = it->first; string link = it->second.toString( ); values.push_back( mimeType + ":\"" + link +"\""); } } else if ( key == "labels" ) { Json::JsonObject labels = json.getObjects( ); for ( Json::JsonObject::iterator it = labels.begin( ); it != labels.end( ); ++it ) { string label = it->first; string isSet = it->second.toString( ); values.push_back( label + ": " + isSet ); } } else values.push_back( json.toString( ) ); return values; } libcmis-0.5.2/src/libcmis/sharepoint-utils.hxx0000664000175000017500000000346613407414352016353 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _SHAREPOINT_UTILS_HXX_ #define _SHAREPOINT_UTILS_HXX_ #include #include #include "json-utils.hxx" class SharePointUtils { public : // Convert a SharePoint Property key to a CMIS key static std::string toCmisKey( const std::string& key); // Returns the property type (String/Bool/Integer etc ) static libcmis::PropertyType::Type getPropertyType( const std::string& key ); // Parse a SharePoint property value to CMIS values static std::vector< std::string > parseSharePointProperty( std::string key, Json jsonValue ); // Checks if a response came from a SharePoint service static bool isSharePoint( std::string response ); }; #endif libcmis-0.5.2/src/libcmis/sharepoint-folder.hxx0000664000175000017500000000526113407414352016461 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _SHAREPOINT_FOLDER_HXX_ #define _SHAREPOINT_FOLDER_HXX_ #include #include #include "sharepoint-object.hxx" #include "json-utils.hxx" class SharePointFolder : public libcmis::Folder, public SharePointObject { public: SharePointFolder( SharePointSession* session ); SharePointFolder( SharePointSession* session, Json json, std::string parentId = std::string( ) ); ~SharePointFolder( ); std::string getType( ) { return std::string( "cmis:folder" );} std::string getBaseType( ) { return std::string( "cmis:folder" );} virtual std::string getParentId( ); virtual std::vector< libcmis::ObjectPtr > getChildren( ); Json::JsonVector getChildrenImpl( std::string url ); virtual libcmis::FolderPtr createFolder( const libcmis::PropertyPtrMap& properties ); virtual libcmis::DocumentPtr createDocument( const libcmis::PropertyPtrMap& properties, boost::shared_ptr< std::ostream > os, std::string contentType, std::string fileName ); virtual std::vector< std::string > removeTree( bool allVersion = true, libcmis::UnfileObjects::Type unfile = libcmis::UnfileObjects::Delete, bool continueOnError = false ); }; #endif libcmis-0.5.2/src/libcmis/gdrive-property.hxx0000664000175000017500000000337213407414352016177 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _GDRIVE_PROPERTY_HXX_ #define _GDRIVE_PROPERTY_HXX_ #include #include "json-utils.hxx" class GDriveProperty : public libcmis::Property { public : // Create a GDrive Property from a Json property with its key GDriveProperty( const std::string& key, Json json); ~GDriveProperty( ); GDriveProperty( const GDriveProperty& copy); GDriveProperty& operator=( const GDriveProperty& copy ); // Check if the property is updatable bool checkUpdatable( const std::string& key ); private : // Avoid calling default constructor GDriveProperty( ); }; #endif /* _GDRIVE_PROPERTY_HXX_ */ libcmis-0.5.2/src/libcmis/gdrive-folder.hxx0000664000175000017500000000443313407414352015565 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _GDRIVE_FOLDER_HXX_ #define _GDRIVE_FOLDER_HXX_ #include #include #include "gdrive-object.hxx" #include "json-utils.hxx" class GDriveFolder : public libcmis::Folder, public GDriveObject { public: GDriveFolder( GDriveSession* session ); GDriveFolder( GDriveSession* session, Json json ); ~GDriveFolder( ); std::string getType( ) { return std::string( "cmis:folder" );} std::string getBaseType( ) { return std::string( "cmis:folder" );} virtual std::vector< libcmis::ObjectPtr > getChildren( ); virtual libcmis::FolderPtr createFolder( const libcmis::PropertyPtrMap& properties ); virtual libcmis::DocumentPtr createDocument( const libcmis::PropertyPtrMap& properties, boost::shared_ptr< std::ostream > os, std::string contentType, std::string fileName ); virtual std::vector< std::string > removeTree( bool allVersion = true, libcmis::UnfileObjects::Type unfile = libcmis::UnfileObjects::Delete, bool continueOnError = false ); std::string uploadProperties( Json properties ); }; #endif libcmis-0.5.2/src/libcmis/gdrive-folder.cxx0000664000175000017500000001251513407414352015560 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "gdrive-folder.hxx" #include "gdrive-session.hxx" #include "gdrive-document.hxx" #include "gdrive-property.hxx" #include "gdrive-utils.hxx" using namespace std; using namespace libcmis; GDriveFolder::GDriveFolder( GDriveSession* session ): libcmis::Object( session ), libcmis::Folder( session ), GDriveObject( session ) { } GDriveFolder::GDriveFolder( GDriveSession* session, Json json ): libcmis::Object( session ), libcmis::Folder( session ), GDriveObject( session, json ) { } GDriveFolder::~GDriveFolder( ) { } vector< libcmis::ObjectPtr > GDriveFolder::getChildren( ) { vector< libcmis::ObjectPtr > children; // GDrive doesn't support fetch all the children in one query. // Instead of sending multiple queries for children, // we send a single query to search for objects where parents // include the folderID. string query = getSession( )->getBindingUrl( ) + "/files?q=\"" + getId( ) + "\"+in+parents+and+trashed+=+false"; string res; try { res = getSession( )->httpGetRequest( query )->getStream()->str(); } catch ( const CurlException& e ) { throw e.getCmisException( ); } Json jsonRes = Json::parse( res ); Json::JsonVector objs = jsonRes["items"].getList( ); // Create children objects from Json objects for(unsigned int i = 0; i < objs.size(); i++) { ObjectPtr child; if ( objs[i]["mimeType"].toString( ) == GDRIVE_FOLDER_MIME_TYPE ) child.reset( new GDriveFolder( getSession( ), objs[i] ) ); else child.reset( new GDriveDocument( getSession( ), objs[i] ) ); children.push_back( child ); } return children; } string GDriveFolder::uploadProperties( Json properties ) { // URL for uploading meta data string metaUrl = getSession()->getBindingUrl() + "/files/"; // add parents to the properties properties.add( "parents", GdriveUtils::createJsonFromParentId( getId( ) ) ); //upload metadata std::istringstream is( properties.toString( ) ); string response; try { response = getSession()->httpPostRequest( metaUrl, is, "application/json" ) ->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } return response; } libcmis::FolderPtr GDriveFolder::createFolder( const PropertyPtrMap& properties ) { Json propsJson = GdriveUtils::toGdriveJson( properties ); // GDrive folder is a file with a different mime type. string mimeType = GDRIVE_FOLDER_MIME_TYPE; // Add mimetype to the propsJson Json jsonMimeType( mimeType.c_str( ) ); propsJson.add( "mimeType", jsonMimeType ); // Upload meta-datas string response = uploadProperties( propsJson ); Json jsonRes = Json::parse( response ); libcmis::FolderPtr folderPtr( new GDriveFolder( getSession( ), jsonRes ) ); return folderPtr; } libcmis::DocumentPtr GDriveFolder::createDocument( const PropertyPtrMap& properties, boost::shared_ptr< ostream > os, string contentType, string fileName ) { if ( !os.get( ) ) throw libcmis::Exception( "Missing stream" ); Json propsJson = GdriveUtils::toGdriveJson( properties ); // Add filename to properties Json jsonFilename( fileName.c_str( ) ); propsJson.add( "title", jsonFilename ); // Upload meta-datas string res = uploadProperties( propsJson); // parse the document Json jsonRes = Json::parse( res ); boost::shared_ptr< GDriveDocument > gDocument( new GDriveDocument( getSession( ), jsonRes ) ); // Upload stream gDocument->uploadStream( os, contentType); return gDocument; } vector< string > GDriveFolder::removeTree( bool /*allVersions*/, libcmis::UnfileObjects::Type /*unfile*/, bool /*continueOnError*/ ) { // Object remove doesn't work with folder // Using trash instead try { istringstream is( "" ); getSession( )->httpPostRequest( getUrl( ) + "/trash", is, "" ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } // Nothing to return here return vector< string >( ); } libcmis-0.5.2/src/libcmis/ws-document.hxx0000664000175000017500000000430413407414352015276 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _WS_DOCUMENT_HXX_ #define _WS_DOCUMENT_HXX_ #include #include #include "ws-object.hxx" class WSDocument : public libcmis::Document, public WSObject { public: WSDocument( const WSObject& object ); virtual ~WSDocument( ); virtual std::vector< libcmis::FolderPtr > getParents( ); virtual boost::shared_ptr< std::istream > getContentStream( std::string streamId = std::string( ) ); virtual void setContentStream( boost::shared_ptr< std::ostream > os, std::string contentType, std::string fileName, bool overwrite = true ); virtual libcmis::DocumentPtr checkOut( ); virtual void cancelCheckout( ); virtual libcmis::DocumentPtr checkIn( bool isMajor, std::string comment, const std::map< std::string, libcmis::PropertyPtr >& properties, boost::shared_ptr< std::ostream > stream, std::string contentType, std::string fileName ); virtual std::vector< libcmis::DocumentPtr > getAllVersions( ); }; #endif libcmis-0.5.2/src/libcmis/gdrive-allowable-actions.hxx0000664000175000017500000001354313407414352017714 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _GDRIVE_ALLOWABLE_ACTIONS_HXX_ #define _GDRIVE_ALLOWABLE_ACTIONS_HXX_ #include class GdriveAllowableActions: public libcmis::AllowableActions { public: GdriveAllowableActions( bool isFolder ) : AllowableActions( ) { m_states.clear( ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::DeleteObject, true ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::UpdateProperties, true ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetProperties, true ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetObjectRelationships, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetObjectParents, true ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::MoveObject, true ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::CreateRelationship, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::ApplyPolicy, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetAppliedPolicies, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::RemovePolicy, false ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetACL, true ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::ApplyACL, true ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetFolderTree, isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetFolderParent, isFolder) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetDescendants, isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::DeleteContentStream, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::CheckOut, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::CancelCheckOut, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::CheckIn, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetContentStream, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::SetContentStream, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetAllVersions, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::AddObjectToFolder, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::RemoveObjectFromFolder, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetRenditions, !isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::GetChildren, isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::CreateDocument, isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::CreateFolder, isFolder ) ); m_states.insert( std::pair< libcmis::ObjectAction::Type, bool> ( libcmis::ObjectAction::DeleteTree, isFolder ) ); } }; #endif libcmis-0.5.2/src/libcmis/onedrive-folder.cxx0000664000175000017500000001133013407414352016105 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "onedrive-folder.hxx" #include "onedrive-document.hxx" #include "onedrive-session.hxx" #include "onedrive-property.hxx" #include "onedrive-utils.hxx" using namespace std; using namespace libcmis; OneDriveFolder::OneDriveFolder( OneDriveSession* session ): libcmis::Object( session ), libcmis::Folder( session ), OneDriveObject( session ) { } OneDriveFolder::OneDriveFolder( OneDriveSession* session, Json json ): libcmis::Object( session ), libcmis::Folder( session ), OneDriveObject( session, json ) { } OneDriveFolder::~OneDriveFolder( ) { } vector< libcmis::ObjectPtr > OneDriveFolder::getChildren( ) { vector< libcmis::ObjectPtr > children; string query = getSession( )->getBindingUrl( ) + "/" + getId( ) + "/files"; string res; try { res = getSession( )->httpGetRequest( query )->getStream()->str(); } catch ( const CurlException& e ) { throw e.getCmisException( ); } Json jsonRes = Json::parse( res ); Json::JsonVector objs = jsonRes["data"].getList( ); // Create children objects from Json objects for(unsigned int i = 0; i < objs.size(); i++) { children.push_back( getSession( )->getObjectFromJson( objs[i] ) ); } return children; } libcmis::FolderPtr OneDriveFolder::createFolder( const PropertyPtrMap& properties ) { Json propsJson = OneDriveUtils::toOneDriveJson( properties ); string uploadUrl = getSession( )->getBindingUrl( ) + "/" + getId( ); std::istringstream is( propsJson.toString( ) ); string response; try { response = getSession()->httpPostRequest( uploadUrl, is, "application/json" ) ->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } Json jsonRes = Json::parse( response ); libcmis::FolderPtr folderPtr( new OneDriveFolder( getSession( ), jsonRes ) ); refresh( ); return folderPtr; } libcmis::DocumentPtr OneDriveFolder::createDocument( const PropertyPtrMap& properties, boost::shared_ptr< ostream > os, string /*contentType*/, string fileName ) { if ( !os.get( ) ) throw libcmis::Exception( "Missing stream" ); if (fileName.empty( ) ) { for ( PropertyPtrMap::const_iterator it = properties.begin( ) ; it != properties.end( ) ; ++it ) { if ( it->first == "cmis:name" ) { fileName = it->second->toString( ); } } } fileName = libcmis::escape( fileName ); string newDocUrl = getSession( )->getBindingUrl( ) + "/" + getId( ) + "/files/" + fileName; boost::shared_ptr< istream> is ( new istream ( os->rdbuf( ) ) ); vector< string > headers; string res; // this will only create the file and return it's id, name and source url try { res = getSession( )->httpPutRequest( newDocUrl, *is, headers ) ->getStream( )->str( ); } catch (const CurlException& e) { throw e.getCmisException( ); } Json jsonRes = Json::parse( res ); DocumentPtr document( new OneDriveDocument( getSession( ), jsonRes ) ); // Upload the properties ObjectPtr object = document->updateProperties( properties ); document = boost::dynamic_pointer_cast< libcmis::Document >( object ); refresh( ); return document; } vector< string > OneDriveFolder::removeTree( bool /*allVersions*/, libcmis::UnfileObjects::Type /*unfile*/, bool /*continueOnError*/ ) { remove( ); // Nothing to return here return vector< string >( ); } libcmis-0.5.2/src/libcmis/xml-utils.cxx0000664000175000017500000004347113407451052014770 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include #include #include #include #include #include #if BOOST_VERSION >= 106800 #include #else #include #endif #include #if LIBCURL_VERSION_VALUE < 0x070F04 #define curl_easy_escape( dummy, str, len ) curl_escape( str, len ) #define curl_easy_unescape( dummy, str, len, dummy2 ) curl_unescape( str, len ) #endif using namespace std; namespace { static const char chars64[]= "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; bool lcl_getBufValue( char encoded, int* value ) { bool found = false; const char *i = chars64; while ( !found && *i ) { if ( *i == encoded ) { found = true; *value = ( i - chars64 ); } ++i; } return found; } } namespace libcmis { EncodedData::EncodedData( FILE* stream ) : m_writer( NULL ), m_stream( stream ), m_outStream( NULL ), m_encoding( ), m_decode( false ), m_pendingValue( 0 ), m_pendingRank( 0 ), m_missingBytes( 0 ) { } EncodedData::EncodedData( ostream* stream ) : m_writer( NULL ), m_stream( NULL ), m_outStream( stream ), m_encoding( ), m_decode( false ), m_pendingValue( 0 ), m_pendingRank( 0 ), m_missingBytes( 0 ) { } EncodedData::EncodedData( xmlTextWriterPtr writer ) : m_writer( writer ), m_stream( NULL ), m_outStream( NULL ), m_encoding( ), m_decode( false ), m_pendingValue( 0 ), m_pendingRank( 0 ), m_missingBytes( 0 ) { } EncodedData::EncodedData( const EncodedData& copy ) : m_writer( copy.m_writer ), m_stream( copy.m_stream ), m_outStream( copy.m_outStream ), m_encoding( copy.m_encoding ), m_decode( copy.m_decode ), m_pendingValue( copy.m_pendingValue ), m_pendingRank( copy.m_pendingRank ), m_missingBytes( copy.m_missingBytes ) { } EncodedData& EncodedData::operator=( const EncodedData& copy ) { if ( this != © ) { m_writer = copy.m_writer; m_stream = copy.m_stream; m_outStream = copy.m_outStream; m_encoding = copy.m_encoding; m_decode = copy.m_decode; m_pendingValue = copy.m_pendingValue; m_pendingRank = copy.m_pendingRank; m_missingBytes = copy.m_missingBytes; } return *this; } void EncodedData::write( void* buf, size_t size, size_t nmemb ) { if ( m_writer ) xmlTextWriterWriteRawLen( m_writer, ( xmlChar* )buf, size * nmemb ); else if ( m_stream ) fwrite( buf, size, nmemb, m_stream ); else if ( m_outStream ) m_outStream->write( ( const char* )buf, size * nmemb ); } void EncodedData::decode( void* buf, size_t size, size_t nmemb ) { m_decode = true; if ( 0 == m_encoding.compare( "base64" ) ) { decodeBase64( ( const char* )buf, size * nmemb ); } else write( buf, size, nmemb ); } void EncodedData::encode( void* buf, size_t size, size_t nmemb ) { m_decode = false; if ( 0 == m_encoding.compare( "base64" ) ) { encodeBase64( ( const char* )buf, size * nmemb ); } else write( buf, size, nmemb ); } void EncodedData::finish( ) { // Flushes the last bytes in base64 encoding / decoding if any if ( 0 == m_encoding.compare( "base64" ) ) { if ( m_decode && ( m_pendingValue != 0 || m_pendingRank != 0 || m_missingBytes != 0 ) ) { int missingBytes = m_missingBytes; if ( 0 == m_missingBytes ) missingBytes = 4 - m_pendingRank; char decoded[3]; decoded[0] = ( m_pendingValue & 0xFF0000 ) >> 16; decoded[1] = ( m_pendingValue & 0xFF00 ) >> 8; decoded[2] = ( m_pendingValue & 0xFF ); write( decoded, 1, 3 - missingBytes ); m_pendingRank = 0; m_pendingValue = 0; m_missingBytes = 0; } else if ( !m_decode && ( m_pendingValue != 0 || m_pendingRank != 0 ) ) { // Missing bytes should be zeroed: no need to do it char encoded[4]; encoded[0] = chars64[ ( m_pendingValue & 0xFC0000 ) >> 18 ]; encoded[1] = chars64[ ( m_pendingValue & 0x03F000 ) >> 12 ]; encoded[2] = chars64[ ( m_pendingValue & 0x000FC0 ) >> 6 ]; encoded[3] = chars64[ ( m_pendingValue & 0x00003F ) ]; // Output the padding int nEquals = 3 - m_pendingRank; for ( int i = 0; i < nEquals; ++i ) encoded[ 3 - i ] = '='; write( encoded, 1, 4 ); m_pendingRank = 0; m_pendingValue = 0; } } } void EncodedData::decodeBase64( const char* buf, size_t len ) { unsigned long blockValue = m_pendingValue; int byteRank = m_pendingRank; int missingBytes = m_missingBytes; size_t i = 0; while ( i < len ) { int value = 0; if ( lcl_getBufValue( buf[i], &value ) ) { blockValue += value << ( ( 3 - byteRank ) * 6 ); ++byteRank; } else if ( buf[i] == '=' ) { ++missingBytes; ++byteRank; } // Reached the end of a block, decode it if ( byteRank >= 4 ) { char decoded[3]; decoded[0] = ( blockValue & 0xFF0000 ) >> 16; decoded[1] = ( blockValue & 0xFF00 ) >> 8; decoded[2] = ( blockValue & 0xFF ); write( decoded, 1, 3 - missingBytes ); byteRank = 0; blockValue = 0; missingBytes = 0; } ++i; } // Store the values if the last block is incomplete: they may come later m_pendingValue = blockValue; m_pendingRank = byteRank; m_missingBytes = missingBytes; } void EncodedData::encodeBase64( const char* buf, size_t len ) { unsigned long blockValue = m_pendingValue; int byteRank = m_pendingRank; size_t i = 0; while ( i < len ) { // Cast the char to an unsigned char or we'll shift negative values blockValue += static_cast< unsigned char >( buf[i] ) << ( 2 - byteRank ) * 8; ++byteRank; // Reached the end of a block, encode it if ( byteRank >= 3 ) { char encoded[4]; encoded[0] = chars64[ ( blockValue & 0xFC0000 ) >> 18 ]; encoded[1] = chars64[ ( blockValue & 0x03F000 ) >> 12 ]; encoded[2] = chars64[ ( blockValue & 0x000FC0 ) >> 6 ]; encoded[3] = chars64[ ( blockValue & 0x00003F ) ]; write( encoded, 1, 4 ); byteRank = 0; blockValue = 0; } ++i; } // Store the values if the last block is incomplete: they may come later m_pendingValue = blockValue; m_pendingRank = byteRank; } HttpResponse::HttpResponse( ) : m_headers( ), m_stream( ), m_data( ) { m_stream.reset( new stringstream( ) ); m_data.reset( new EncodedData( m_stream.get( ) ) ); } void registerNamespaces( xmlXPathContextPtr xpathCtx ) { if ( xpathCtx != NULL ) { xmlXPathRegisterNs( xpathCtx, BAD_CAST( "app" ), BAD_CAST( NS_APP_URL ) ); xmlXPathRegisterNs( xpathCtx, BAD_CAST( "atom" ), BAD_CAST( NS_ATOM_URL ) ); xmlXPathRegisterNs( xpathCtx, BAD_CAST( "cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlXPathRegisterNs( xpathCtx, BAD_CAST( "cmisra" ), BAD_CAST( NS_CMISRA_URL ) ); xmlXPathRegisterNs( xpathCtx, BAD_CAST( "cmism" ), BAD_CAST( NS_CMISM_URL ) ); xmlXPathRegisterNs( xpathCtx, BAD_CAST( "xsi" ), BAD_CAST( "http://www.w3.org/2001/XMLSchema-instance" ) ); xmlXPathRegisterNs( xpathCtx, BAD_CAST( "type" ), BAD_CAST( "cmis:cmisTypeDocumentDefinitionType" ) ); } } void registerCmisWSNamespaces( xmlXPathContextPtr xpathCtx ) { if ( xpathCtx != NULL ) { xmlXPathRegisterNs( xpathCtx, BAD_CAST( "cmisw" ), BAD_CAST( NS_CMISW_URL ) ); xmlXPathRegisterNs( xpathCtx, BAD_CAST( "cmis" ), BAD_CAST( NS_CMIS_URL ) ); xmlXPathRegisterNs( xpathCtx, BAD_CAST( "cmisra" ), BAD_CAST( NS_CMISRA_URL ) ); xmlXPathRegisterNs( xpathCtx, BAD_CAST( "cmism" ), BAD_CAST( NS_CMISM_URL ) ); registerSoapNamespaces( xpathCtx ); } } void registerSoapNamespaces( xmlXPathContextPtr xpathCtx ) { if ( xpathCtx != NULL ) { xmlXPathRegisterNs( xpathCtx, BAD_CAST( "soap" ), BAD_CAST( NS_SOAP_URL ) ); xmlXPathRegisterNs( xpathCtx, BAD_CAST( "soap-env" ), BAD_CAST( NS_SOAP_ENV_URL ) ); xmlXPathRegisterNs( xpathCtx, BAD_CAST( "wsdl" ), BAD_CAST ( "http://schemas.xmlsoap.org/wsdl/" ) ); xmlXPathRegisterNs( xpathCtx, BAD_CAST( "ns" ), BAD_CAST ( "http://schemas.xmlsoap.org/soap/encoding/" ) ); xmlXPathRegisterNs( xpathCtx, BAD_CAST( "jaxws" ), BAD_CAST( "http://java.sun.com/xml/ns/jaxws" ) ); xmlXPathRegisterNs( xpathCtx, BAD_CAST( "xsd" ), BAD_CAST ( "http://www.w3.org/2001/XMLSchema" ) ); } } string getXPathValue( xmlXPathContextPtr xpathCtx, string req ) { string value; if ( xpathCtx != NULL ) { xmlXPathObjectPtr xpathObj = xmlXPathEvalExpression( BAD_CAST( req.c_str() ), xpathCtx ); if ( xpathObj && xpathObj->nodesetval && xpathObj->nodesetval->nodeNr > 0 ) { xmlChar* pContent = xmlNodeGetContent( xpathObj->nodesetval->nodeTab[0] ); value = string( ( char* )pContent ); xmlFree( pContent ); } xmlXPathFreeObject( xpathObj ); } return value; } xmlDocPtr wrapInDoc( xmlNodePtr entryNd ) { xmlDocPtr doc = xmlNewDoc(BAD_CAST "1.0"); if ( entryNd != NULL ) { xmlNodePtr entryCopy = xmlCopyNode( entryNd, 1 ); xmlDocSetRootElement( doc, entryCopy ); } return doc; } string getXmlNodeAttributeValue( xmlNodePtr node, const char* attributeName, const char* defaultValue ) { xmlChar* xmlStr = xmlGetProp( node, BAD_CAST( attributeName ) ); if ( xmlStr == NULL ) { if ( !defaultValue ) throw Exception( "Missing attribute" ); else return string( defaultValue ); } string value( ( char * ) xmlStr ); xmlFree( xmlStr ); return value; } boost::posix_time::ptime parseDateTime( string dateTimeStr ) { boost::posix_time::ptime t( boost::date_time::not_a_date_time ); // Get the time zone offset boost::posix_time::time_duration tzOffset( boost::posix_time::duration_from_string( "+00:00" ) ); if ( dateTimeStr.empty( ) ) return t; // obviously not a time size_t teePos = dateTimeStr.find( 'T' ); if ( teePos == string::npos || teePos == dateTimeStr.size() - 1 ) return t; // obviously not a time string noTzStr = dateTimeStr.substr( 0, teePos + 1 ); string timeStr = dateTimeStr.substr( teePos + 1 ); // Get the TZ if any if ( timeStr[ timeStr.size() - 1] == 'Z' ) { noTzStr += timeStr.substr( 0, timeStr.size() - 1 ); } else { size_t tzPos = timeStr.find( '+' ); if ( tzPos == string::npos ) tzPos = timeStr.find( '-' ); if ( tzPos != string::npos ) { noTzStr += timeStr.substr( 0, tzPos ); // Check the validity of the TZ value string tzStr = timeStr.substr( tzPos ); try { tzOffset = boost::posix_time::time_duration( boost::posix_time::duration_from_string( tzStr.c_str() ) ); } catch ( const std::exception& ) { // Error converting, not a datetime return t; } } else noTzStr += timeStr; } // Remove all the '-' and ':' size_t pos = noTzStr.find_first_of( ":-" ); while ( pos != string::npos ) { noTzStr.erase( pos, 1 ); pos = noTzStr.find_first_of( ":-" ); } try { t = boost::posix_time::from_iso_string( noTzStr.c_str( ) ); t = t + tzOffset; } catch ( const std::exception& ) { // Ignore boost parsing errors: will result in not_a_date_time } return t; } string writeDateTime( boost::posix_time::ptime time ) { string str; if ( !time.is_special( ) ) { str = boost::posix_time::to_iso_extended_string( time ); str += "Z"; } return str; } bool parseBool( string boolStr ) { bool value = false; if ( boolStr == "true" || boolStr == "1" ) value = true; else if ( boolStr == "false" || boolStr == "0" ) value = false; else throw Exception( string( "Invalid xsd:boolean input: " ) + boolStr ); return value; } long parseInteger( string intStr ) { char* end; errno = 0; long value = strtol( intStr.c_str(), &end, 0 ); if ( ( ERANGE == errno && ( LONG_MAX == value || LONG_MIN == value ) ) || ( errno != 0 && value == 0 ) ) { throw Exception( string( "xsd:integer input can't fit to long: " ) + intStr ); } else if ( !string( end ).empty( ) ) { throw Exception( string( "Invalid xsd:integer input: " ) + intStr ); } return value; } double parseDouble( string doubleStr ) { char* end; errno = 0; double value = strtod( doubleStr.c_str(), &end ); if ( ( ERANGE == errno ) || ( errno != 0 && value == 0 ) ) { throw Exception( string( "xsd:decimal input can't fit to double: " ) + doubleStr ); } else if ( !string( end ).empty( ) ) { throw Exception( string( "Invalid xsd:decimal input: " ) + doubleStr ); } return value; } string trim( const string& str ) { return boost::trim_copy_if( str, boost::is_any_of( " \t\r\n" ) ); } std::string base64encode( const std::string& str ) { stringstream stream; EncodedData data( &stream ); data.setEncoding( "base64" ); data.encode( ( void * )str.c_str( ), size_t( 1 ), str.size() ); data.finish( ); return stream.str(); } std::string sha1( const std::string& str ) { boost::uuids::detail::sha1 sha1; sha1.process_bytes( str.c_str(), str.size() ); unsigned int digest[5]; sha1.get_digest( digest ); stringstream out; // Setup writing mode. Every number must produce eight // hexadecimal digits, including possible leading 0s, or we get // less than 40 digits as result. out << hex << setfill('0') << right; for ( int i = 0; i < 5; ++i ) out << setw(8) << digest[i]; return out.str(); } int stringstream_write_callback( void * context, const char * s, int len ) { stringstream * ss=static_cast< stringstream * >( context ); if ( ss ) { ss->write( s, len ); return len; } return 0; } string escape( string str ) { std::unique_ptr< char, void(*)( void* ) > escaped{ curl_easy_escape( NULL, str.c_str(), str.length() ), curl_free }; return escaped.get(); } string unescape( string str ) { std::unique_ptr< char, void(*)( void* ) > unescaped{ curl_easy_unescape( NULL, str.c_str(), str.length(), NULL ), curl_free }; return unescaped.get(); } } libcmis-0.5.2/src/libcmis/atom-document.hxx0000664000175000017500000000460713407414352015613 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _ATOM_DOCUMENT_HXX_ #define _ATOM_DOCUMENT_HXX_ #include #include #include "atom-object.hxx" class AtomDocument : public libcmis::Document, public AtomObject { private: std::string m_contentUrl; public: AtomDocument( AtomPubSession* session ); AtomDocument( AtomPubSession* session, xmlNodePtr entryNd ); ~AtomDocument( ); virtual std::vector< libcmis::FolderPtr > getParents( ); virtual boost::shared_ptr< std::istream > getContentStream( std::string streamId = std::string( ) ); virtual void setContentStream( boost::shared_ptr< std::ostream > os, std::string contentType, std::string fileName, bool overwrite = true ); virtual libcmis::DocumentPtr checkOut( ); virtual void cancelCheckout( ); virtual libcmis::DocumentPtr checkIn( bool isMajor, std::string comment, const std::map< std::string, libcmis::PropertyPtr >& properties, boost::shared_ptr< std::ostream > stream, std::string contentType, std::string fileName ); virtual std::vector< libcmis::DocumentPtr > getAllVersions( ); protected: virtual void extractInfos( xmlDocPtr doc ); }; #endif libcmis-0.5.2/src/libcmis/onedrive-folder.hxx0000664000175000017500000000436013407414352016117 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _ONEDRIVE_FOLDER_HXX_ #define _ONEDRIVE_FOLDER_HXX_ #include #include #include "onedrive-object.hxx" #include "json-utils.hxx" class OneDriveFolder : public libcmis::Folder, public OneDriveObject { public: OneDriveFolder( OneDriveSession* session ); OneDriveFolder( OneDriveSession* session, Json json ); ~OneDriveFolder( ); std::string getType( ) { return std::string( "cmis:folder" );} std::string getBaseType( ) { return std::string( "cmis:folder" );} virtual std::vector< libcmis::ObjectPtr > getChildren( ); virtual libcmis::FolderPtr createFolder( const libcmis::PropertyPtrMap& properties ); virtual libcmis::DocumentPtr createDocument( const libcmis::PropertyPtrMap& properties, boost::shared_ptr< std::ostream > os, std::string contentType, std::string fileName ); virtual std::vector< std::string > removeTree( bool allVersion = true, libcmis::UnfileObjects::Type unfile = libcmis::UnfileObjects::Delete, bool continueOnError = false ); }; #endif libcmis-0.5.2/src/libcmis/ws-folder.cxx0000664000175000017500000000460213407414352014727 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "ws-folder.hxx" using namespace std; using libcmis::PropertyPtrMap; WSFolder::WSFolder( const WSObject& object ) : libcmis::Object( object ), libcmis::Folder( const_cast< WSObject& >( object ).getSession( ) ), WSObject( object ) { } WSFolder::~WSFolder( ) { } vector< libcmis::ObjectPtr > WSFolder::getChildren( ) { string repoId = getSession( )->getRepositoryId( ); return getSession( )->getNavigationService( ).getChildren( repoId, getId( ) ); } libcmis::FolderPtr WSFolder::createFolder( const PropertyPtrMap& properties ) { string repoId = getSession( )->getRepositoryId( ); return getSession( )->getObjectService( ).createFolder( repoId, properties, getId( ) ); } libcmis::DocumentPtr WSFolder::createDocument( const PropertyPtrMap& properties, boost::shared_ptr< ostream > os, string contentType, string fileName ) { string repoId = getSession( )->getRepositoryId( ); return getSession( )->getObjectService( ).createDocument( repoId, properties, getId( ), os, contentType, fileName ); } vector< string > WSFolder::removeTree( bool allVersion, libcmis::UnfileObjects::Type unfile, bool continueOnError ) { string repoId = getSession( )->getRepositoryId( ); return getSession( )->getObjectService( ).deleteTree( repoId, getId( ), allVersion, unfile, continueOnError ); } libcmis-0.5.2/src/libcmis/gdrive-document.hxx0000664000175000017500000000656613407414352016141 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _GDRIVE_DOCUMENT_HXX_ #define _GDRIVE_DOCUMENT_HXX_ #include #include #include #include "gdrive-object.hxx" #include "json-utils.hxx" class GDriveDocument : public libcmis::Document, public GDriveObject { public: GDriveDocument( GDriveSession* session ); // Create a GDrive document from Json properties. // In case it's a revision, keep the ID and the name of the original file. GDriveDocument( GDriveSession* session, Json json, std::string id = std::string( ), std::string name = std::string( ) ); ~GDriveDocument( ); std::string getType( ) { return std::string( "cmis:document" );} std::string getBaseType( ) { return std::string( "cmis:document" );} bool isGoogleDoc( ) { return m_isGoogleDoc; } /* Get the download Url associated to streamId, automatically find ODF then MS format if no streamId is specified. */ std::string getDownloadUrl( std::string streamId = std::string( ) ); void uploadStream( boost::shared_ptr< std::ostream > os, std::string contentType ); virtual std::vector< libcmis::FolderPtr > getParents( ); virtual boost::shared_ptr< std::istream > getContentStream( std::string streamId = std::string( ) ); virtual void setContentStream( boost::shared_ptr< std::ostream > os, std::string contentType, std::string fileName, bool overwrite = true ); virtual libcmis::DocumentPtr checkOut( ); virtual void cancelCheckout( ); virtual libcmis::DocumentPtr checkIn( bool isMajor, std::string comment, const std::map< std::string,libcmis::PropertyPtr >& properties, boost::shared_ptr< std::ostream > stream, std::string contentType, std::string fileName ); virtual std::vector< libcmis::DocumentPtr > getAllVersions( ); private: bool m_isGoogleDoc; }; #endif libcmis-0.5.2/src/libcmis/sharepoint-document.hxx0000664000175000017500000000562213407414352017025 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _SHAREPOINT_DOCUMENT_HXX_ #define _SHAREPOINT_DOCUMENT_HXX_ #include #include #include "sharepoint-object.hxx" #include "json-utils.hxx" class SharePointDocument : public libcmis::Document, public SharePointObject { public: SharePointDocument( SharePointSession* session ); SharePointDocument( SharePointSession* session, Json json, std::string parentId = std::string( ), std::string name = std::string( ) ); ~SharePointDocument( ); std::string getType( ) { return std::string( "cmis:document" );} std::string getBaseType( ) { return std::string( "cmis:document" );} virtual std::vector< libcmis::FolderPtr > getParents( ); virtual boost::shared_ptr< std::istream > getContentStream( std::string streamId = std::string( ) ); virtual void setContentStream( boost::shared_ptr< std::ostream > os, std::string contentType, std::string fileName, bool overwrite = true ); virtual libcmis::DocumentPtr checkOut( ); virtual void cancelCheckout( ); virtual libcmis::DocumentPtr checkIn( bool isMajor, std::string comment, const std::map< std::string,libcmis::PropertyPtr >& properties, boost::shared_ptr< std::ostream > stream, std::string contentType, std::string fileName ); virtual std::vector< libcmis::DocumentPtr > getAllVersions( ); }; #endif libcmis-0.5.2/src/libcmis/ws-repositoryservice.hxx0000664000175000017500000000405613407414352017264 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _WS_REPOSITORYSERVICE_HXX_ #define _WS_REPOSITORYSERVICE_HXX_ #include #include #include #include #include "base-session.hxx" #include "ws-soap.hxx" class WSSession; class RepositoryService { private: WSSession* m_session; std::string m_url; public: RepositoryService( WSSession* session ); RepositoryService( const RepositoryService& copy ); ~RepositoryService( ); RepositoryService& operator=( const RepositoryService& copy ); std::map< std::string, std::string > getRepositories( ); /** Get the repository information based on its identifier. */ libcmis::RepositoryPtr getRepositoryInfo( std::string id ); libcmis::ObjectTypePtr getTypeDefinition( std::string repoId, std::string typeId ); std::vector< libcmis::ObjectTypePtr > getTypeChildren( std::string repoId, std::string typeId ); private: RepositoryService(); }; #endif libcmis-0.5.2/src/libcmis/repository.cxx0000664000175000017500000002173213407414352015247 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 Cédric Bosdonnat * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include #include using namespace std; namespace libcmis { Repository::Repository( ) : m_id( ), m_name( ), m_description( ), m_vendorName( ), m_productName( ), m_productVersion( ), m_rootId( ), m_cmisVersionSupported( ), m_thinClientUri( ), m_principalAnonymous( ), m_principalAnyone( ), m_capabilities( ) { } Repository::Repository( xmlNodePtr node ) : m_id( ), m_name( ), m_description( ), m_vendorName( ), m_productName( ), m_productVersion( ), m_rootId( ), m_cmisVersionSupported( ), m_thinClientUri( ), m_principalAnonymous( ), m_principalAnyone( ), m_capabilities( ) { initializeFromNode( node ); } string Repository::getId( ) const { return m_id; } string Repository::getName( ) const { return m_name; } string Repository::getDescription( ) const { return m_description; } string Repository::getVendorName( ) const { return m_vendorName; } string Repository::getProductName( ) const { return m_productName; } string Repository::getProductVersion( ) const { return m_productVersion; } string Repository::getRootId( ) const { return m_rootId; } string Repository::getCmisVersionSupported( ) const { return m_cmisVersionSupported; } boost::shared_ptr< string > Repository::getThinClientUri( ) const { return m_thinClientUri; } boost::shared_ptr< string > Repository::getPrincipalAnonymous( ) const { return m_principalAnonymous; } boost::shared_ptr< string > Repository::getPrincipalAnyone( ) const { return m_principalAnyone; } void Repository::initializeFromNode( xmlNodePtr node ) { for ( xmlNodePtr child = node->children; child; child = child->next ) { string localName( ( char* ) child->name ); xmlChar* content = xmlNodeGetContent( child ); string value( ( char* )content ); xmlFree( content ); if ( localName == "repositoryId" ) m_id = value; else if ( localName == "repositoryName" ) m_name = value; else if ( localName == "repositoryDescription" ) m_description = value; else if ( localName == "vendorName" ) m_vendorName = value; else if ( localName == "productName" ) m_productName = value; else if ( localName == "productVersion" ) m_productVersion = value; else if ( localName == "rootFolderId" ) m_rootId = value; else if ( localName == "cmisVersionSupported" ) m_cmisVersionSupported = value; else if ( localName == "thinClientURI" ) m_thinClientUri.reset( new string( value ) ); else if ( localName == "principalAnonymous" ) m_principalAnonymous.reset( new string( value ) ); else if ( localName == "principalAnyone" ) m_principalAnyone.reset( new string( value ) ); else if ( localName == "capabilities" ) { m_capabilities = parseCapabilities( child ); } } } string Repository::getCapability( Capability capability ) const { string result; map< Capability, string >::const_iterator it = m_capabilities.find( capability ); if ( it != m_capabilities.end() ) result = it->second; return result; } bool Repository::getCapabilityAsBool( Capability capability ) const { string value = getCapability( capability ); bool result = false; try { result = libcmis::parseBool( value ); } catch ( const Exception& ) { } return result; } // LCOV_EXCL_START string Repository::toString( ) const { stringstream buf; buf << "Id: " << getId( ) << endl; buf << "Name: " << getName( ) << endl; buf << "Description: " << getDescription( ) << endl; buf << "Vendor: " << getVendorName( ) << endl; buf << "Product: " << getProductName( ) << " - version " << getProductVersion( ) << endl; buf << "Root Id: " << getRootId( ) << endl; buf << "Supported CMIS Version: " << getCmisVersionSupported( ) << endl; if ( getThinClientUri( ) ) buf << "Thin Client URI: " << *getThinClientUri( ) << endl; if ( getPrincipalAnonymous( ) ) buf << "Anonymous user: " << *getPrincipalAnonymous( ) << endl; if ( getPrincipalAnyone( ) ) buf << "Anyone user: " << *getPrincipalAnyone( ) << endl; buf << endl; buf << "Capabilities:" << endl; static string capabilitiesNames[] = { "ACL", "AllVersionsSearchable", "Changes", "ContentStreamUpdatability", "GetDescendants", "GetFolderTree", "OrderBy", "Multifiling", "PWCSearchable", "PWCUpdatable", "Query", "Renditions", "Unfiling", "VersionSpecificFiling", "Join" }; for ( int i = ACL; i < Join; ++i ) { buf << "\t" << capabilitiesNames[i] << ": " << getCapability( ( Capability )i ) << endl; } return buf.str(); } // LCOV_EXCL_STOP map< Repository::Capability, string > Repository::parseCapabilities( xmlNodePtr node ) { map< Capability, string > capabilities; for ( xmlNodePtr child = node->children; child; child = child->next ) { string localName( ( char* ) child->name ); xmlChar* content = xmlNodeGetContent( child ); string value( ( char* )content ); xmlFree( content ); Capability capability = ACL; bool ignore = false; if ( localName == "capabilityACL" ) capability = ACL; else if ( localName == "capabilityAllVersionsSearchable" ) capability = AllVersionsSearchable; else if ( localName == "capabilityChanges" ) capability = Changes; else if ( localName == "capabilityContentStreamUpdatability" ) capability = ContentStreamUpdatability; else if ( localName == "capabilityGetDescendants" ) capability = GetDescendants; else if ( localName == "capabilityGetFolderTree" ) capability = GetFolderTree; else if ( localName == "capabilityOrderBy" ) capability = OrderBy; else if ( localName == "capabilityMultifiling" ) capability = Multifiling; else if ( localName == "capabilityPWCSearchable" ) capability = PWCSearchable; else if ( localName == "capabilityPWCUpdatable" ) capability = PWCUpdatable; else if ( localName == "capabilityQuery" ) capability = Query; else if ( localName == "capabilityRenditions" ) capability = Renditions; else if ( localName == "capabilityUnfiling" ) capability = Unfiling; else if ( localName == "capabilityVersionSpecificFiling" ) capability = VersionSpecificFiling; else if ( localName == "capabilityJoin" ) capability = Join; else ignore = true; if ( !ignore ) capabilities[capability] = value; } return capabilities; } } libcmis-0.5.2/src/libcmis/json-utils.hxx0000664000175000017500000000507113407414352015142 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _JSON_UTILS_HXX_ #define _JSON_UTILS_HXX_ #include #include #include #include #include #include class Json { public : typedef std::map< std::string, Json > JsonObject ; typedef std::vector< Json > JsonVector ; enum Type { json_null, json_bool, json_double, json_int, json_object, json_array, json_string, json_datetime } ; Json( ); Json( const Json& copy ); Json( const char *str ); Json( const libcmis::PropertyPtr& property ); Json( const libcmis::PropertyPtrMap& properties ); Json( const JsonVector& arr ); Json( const JsonObject& obj ); ~Json( ) ; Json operator[]( std::string key ) const; Json& operator=( const Json& rhs ) ; void swap( Json& other ) ; void add( const Json& json); void add( const std::string& key, const Json& json); static Json parse( const std::string& str ); std::string toString( ) const; Type getDataType( ) const ; std::string getStrType( ) const ; JsonObject getObjects(); JsonVector getList(); boost::property_tree::ptree getTree( ) const{ return m_tJson; } private : Json( boost::property_tree::ptree tJson ) ; boost::property_tree::ptree m_tJson ; Type m_type; Type parseType( ); } ; #endif /* _JSON_UTILS_HXX_ */ libcmis-0.5.2/src/libcmis/onedrive-session.cxx0000664000175000017500000001267613407414352016333 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "onedrive-session.hxx" #include "oauth2-handler.hxx" #include "onedrive-object-type.hxx" #include "onedrive-document.hxx" #include "onedrive-folder.hxx" #include "onedrive-object.hxx" #include "onedrive-repository.hxx" using namespace std; OneDriveSession::OneDriveSession ( string baseUrl, string username, string password, libcmis::OAuth2DataPtr oauth2, bool verbose ) : BaseSession( baseUrl, string(), username, password, false, libcmis::OAuth2DataPtr(), verbose ) { // Add the dummy repository m_repositories.push_back( getRepository( ) ); if ( oauth2 && oauth2->isComplete( ) ){ setOAuth2Data( oauth2 ); } } OneDriveSession::OneDriveSession( const OneDriveSession& copy ) : BaseSession( copy ) { } OneDriveSession::OneDriveSession() : BaseSession() { } OneDriveSession::~OneDriveSession() { } libcmis::RepositoryPtr OneDriveSession::getRepository( ) { // Return a dummy repository since OneDrive doesn't have that notion libcmis::RepositoryPtr repo( new OneDriveRepository( ) ); return repo; } libcmis::ObjectPtr OneDriveSession::getObject( string objectId ) { // Run the http request to get the properties definition string res; string objectLink = m_bindingUrl + "/" + objectId; try { res = httpGetRequest( objectLink )->getStream()->str(); } catch ( const CurlException& e ) { throw e.getCmisException( ); } Json jsonRes = Json::parse( res ); return getObjectFromJson( jsonRes ); } libcmis::ObjectPtr OneDriveSession::getObjectFromJson( Json& jsonRes ) { libcmis::ObjectPtr object; string kind = jsonRes["type"].toString( ); if ( kind == "folder" || kind == "album" ) { object.reset( new OneDriveFolder( this, jsonRes ) ); } else if ( kind == "file" ) { object.reset( new OneDriveDocument( this, jsonRes ) ); } else { object.reset( new OneDriveObject( this, jsonRes ) ); } return object; } libcmis::ObjectPtr OneDriveSession::getObjectByPath( string path ) { string id; if ( path == "/" ) { id = "me/skydrive"; } else { path = "/SkyDrive" + path; size_t pos = path.rfind("/"); string name = libcmis::escape( path.substr( pos + 1, path.size( ) ) ); string res; string objectQuery = m_bindingUrl + "/me/skydrive/search?q=" + name; try { res = httpGetRequest( objectQuery )->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } Json jsonRes = Json::parse( res ); Json::JsonVector objs = jsonRes["data"].getList( ); // Searching for a match in the path to the object for ( unsigned int i = 0; i < objs.size( ); i++ ) { if ( isAPathMatch( objs[i], path ) ) { id = objs[i]["id"].toString( ); break; } } } if ( id.empty( ) ) { throw libcmis::Exception( "No file could be found" ); } return getObject( id ); } bool OneDriveSession::isAPathMatch( Json objectJson, string path ) { string parentId = objectJson["parent_id"].toString( ); string objectName = objectJson["name"].toString( ); size_t pos = path.rfind("/"); string pathName = path.substr( pos + 1, path.size( ) ); string truncatedPath = path.substr( 0, pos ); if ( truncatedPath.empty( ) && parentId == "null" && objectName == pathName ) { // match return true; } if ( truncatedPath.empty( ) || parentId == "null" || objectName != pathName ) { return false; } string res; string parentUrl = m_bindingUrl + "/" + parentId; try { res = httpGetRequest( parentUrl )->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } Json jsonRes = Json::parse( res ); return isAPathMatch( jsonRes, truncatedPath ); } libcmis::ObjectTypePtr OneDriveSession::getType( string id ) { libcmis::ObjectTypePtr type( new OneDriveObjectType( id ) ); return type; } vector< libcmis::ObjectTypePtr > OneDriveSession::getBaseTypes( ) { vector< libcmis::ObjectTypePtr > types; return types; } libcmis-0.5.2/src/libcmis/object.cxx0000664000175000017500000003327313407414352014301 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include #include #include using namespace std; namespace libcmis { Object::Object( Session* session ) : m_session( session ), m_typeDescription( ), m_refreshTimestamp( 0 ), m_typeId( ), m_properties( ), m_allowableActions( ), m_renditions( ) { } Object::Object( Session* session, xmlNodePtr node ) : m_session( session ), m_typeDescription( ), m_refreshTimestamp( 0 ), m_typeId( ), m_properties( ), m_allowableActions( ), m_renditions( ) { initializeFromNode( node ); } Object::Object( const Object& copy ) : m_session( copy.m_session ), m_typeDescription( copy.m_typeDescription ), m_refreshTimestamp( copy.m_refreshTimestamp ), m_typeId( copy.m_typeId ), m_properties( copy.m_properties ), m_allowableActions( copy.m_allowableActions ), m_renditions( copy.m_renditions ) { } Object& Object::operator=( const Object& copy ) { if ( this != © ) { m_session = copy.m_session; m_typeDescription = copy.m_typeDescription; m_refreshTimestamp = copy.m_refreshTimestamp; m_typeId = copy.m_typeId; m_properties = copy.m_properties; m_allowableActions = copy.m_allowableActions; m_renditions = copy.m_renditions; } return *this; } void Object::initializeFromNode( xmlNodePtr node ) { // Even if node is NULL we'll have an empty doc, so no need // to worry about it. xmlDocPtr doc = wrapInDoc( node ); xmlXPathContextPtr xpathCtx = xmlXPathNewContext( doc ); libcmis::registerNamespaces( xpathCtx ); if ( NULL != xpathCtx ) { // Get the allowableActions xmlXPathObjectPtr xpathObj = xmlXPathEvalExpression( BAD_CAST( "//cmis:allowableActions" ), xpathCtx ); if ( xpathObj && xpathObj->nodesetval && xpathObj->nodesetval->nodeNr > 0 ) { xmlNodePtr actionsNode = xpathObj->nodesetval->nodeTab[0]; m_allowableActions.reset( new libcmis::AllowableActions( actionsNode ) ); } xmlXPathFreeObject( xpathObj ); // TODO Get rid of this request: // * Too time consuming // * Makes secondary aspect properties annoying to create // * Prevents from getting Alfresco additional properties // First get the type id as it will give us the property definitions string typeIdReq( "/*/cmis:properties/cmis:propertyId[@propertyDefinitionId='cmis:objectTypeId']/cmis:value/text()" ); m_typeId = libcmis::getXPathValue( xpathCtx, typeIdReq ); string propertiesReq( "/*/cmis:properties/*" ); xpathObj = xmlXPathEvalExpression( BAD_CAST( propertiesReq.c_str() ), xpathCtx ); if ( NULL != xpathObj && NULL != xpathObj->nodesetval ) { int size = xpathObj->nodesetval->nodeNr; for ( int i = 0; i < size; i++ ) { xmlNodePtr propertyNode = xpathObj->nodesetval->nodeTab[i]; libcmis::PropertyPtr property = libcmis::parseProperty( propertyNode, getTypeDescription( ) ); if ( property != NULL ) m_properties[ property->getPropertyType( )->getId() ] = property; } } xmlXPathFreeObject( xpathObj ); } xmlXPathFreeContext( xpathCtx ); xmlFreeDoc( doc ); m_refreshTimestamp = time( NULL ); } string Object::getStringProperty( const string& propertyName ) { string name; PropertyPtrMap::const_iterator it = getProperties( ).find( string( propertyName ) ); if ( it != getProperties( ).end( ) && it->second != NULL && !it->second->getStrings( ).empty( ) ) name = it->second->getStrings( ).front( ); return name; } string Object::getId( ) { return getStringProperty( "cmis:objectId" ); } string Object::getName( ) { return getStringProperty( "cmis:name" ); } string Object::getBaseType( ) { return getStringProperty( "cmis:baseTypeId" ); } string Object::getType( ) { string value = getStringProperty( "cmis:objectTypeId" ); if ( value.empty( ) ) value = m_typeId; return value; } string Object::getCreatedBy( ) { return getStringProperty( "cmis:createdBy" ); } string Object::getLastModifiedBy( ) { return getStringProperty( "cmis:lastModifiedBy" ); } string Object::getChangeToken( ) { return getStringProperty( "cmis:changeToken" ); } vector< string > Object::getPaths( ) { return vector< string > ( ); } boost::posix_time::ptime Object::getCreationDate( ) { boost::posix_time::ptime value; PropertyPtrMap::const_iterator it = getProperties( ).find( string( "cmis:creationDate" ) ); if ( it != getProperties( ).end( ) && it->second != NULL && !it->second->getDateTimes( ).empty( ) ) value = it->second->getDateTimes( ).front( ); return value; } boost::posix_time::ptime Object::getLastModificationDate( ) { boost::posix_time::ptime value; PropertyPtrMap::const_iterator it = getProperties( ).find( string( "cmis:lastModificationDate" ) ); if ( it != getProperties( ).end( ) && it->second != NULL && !it->second->getDateTimes( ).empty( ) ) value = it->second->getDateTimes( ).front( ); return value; } bool Object::isImmutable( ) { bool value = false; PropertyPtrMap::const_iterator it = getProperties( ).find( string( "cmis:isImmutable" ) ); if ( it != getProperties( ).end( ) && it->second != NULL && !it->second->getBools( ).empty( ) ) value = it->second->getBools( ).front( ); return value; } vector< string > Object::getSecondaryTypes( ) { vector< string > types; PropertyPtrMap::const_iterator it = getProperties( ).find( string( "cmis:secondaryObjectTypeIds" ) ); if ( it != getProperties( ).end( ) && it->second != NULL ) types = it->second->getStrings( ); return types; } ObjectPtr Object::addSecondaryType( string id, PropertyPtrMap properties ) { // First make sure the cmis:secondaryObjectTypeIds property can be defined map< string, PropertyTypePtr >& propertyTypes = getTypeDescription( )-> getPropertiesTypes(); map< string, PropertyTypePtr >::iterator it = propertyTypes.find( "cmis:secondaryObjectTypeIds" ); if ( it == propertyTypes.end() ) throw ( Exception( "Secondary Types not supported", "constraint" ) ); // Copy all the new properties without checking they are // defined in the secondary type definition: that would // require one more HTTP request and the server will complain // anyway if it's not good. PropertyPtrMap newProperties( properties ); // Prepare the new cmis:secondaryObjectTypeIds property vector< string > secTypes = getSecondaryTypes( ); if ( find( secTypes.begin(), secTypes.end(), id ) == secTypes.end( ) ) { secTypes.push_back( id ); PropertyPtr newSecTypes( new Property( it->second, secTypes ) ); newProperties["cmis:secondaryObjectTypeIds"] = newSecTypes; } return updateProperties( newProperties ); } ObjectPtr Object::removeSecondaryType( string id ) { // First make sure the cmis:secondaryObjectTypeIds property can be defined map< string, PropertyTypePtr >& propertyTypes = getTypeDescription( )-> getPropertiesTypes(); map< string, PropertyTypePtr >::iterator it = propertyTypes.find( "cmis:secondaryObjectTypeIds" ); if ( it == propertyTypes.end() ) throw ( Exception( "Secondary Types not supported", "constraint" ) ); // Prepare the new cmis:secondaryObjectTypeIds property PropertyPtrMap newProperties; vector< string > secTypes = getSecondaryTypes( ); vector< string > newSecTypes; for ( vector< string >::iterator idIt = secTypes.begin( ); idIt != secTypes.end( ); ++idIt ) { if ( *idIt != id ) newSecTypes.push_back( *idIt ); } // No need to update the property if it didn't change if ( newSecTypes.size( ) != secTypes.size( ) ) { PropertyPtr property ( new Property( it->second, newSecTypes ) ); newProperties["cmis:secondaryObjectTypeIds"] = property; } return updateProperties( newProperties ); } PropertyPtrMap& Object::getProperties( ) { return m_properties; } libcmis::ObjectTypePtr Object::getTypeDescription( ) { if ( !m_typeDescription.get( ) && m_session != NULL ) m_typeDescription = m_session->getType( getType( ) ); return m_typeDescription; } vector< RenditionPtr> Object::getRenditions( string /*filter*/ ) { return m_renditions; } string Object::getThumbnailUrl( ) { string url; vector< RenditionPtr > renditions = getRenditions( ); for ( vector< RenditionPtr >::iterator it = renditions.begin( ); it != renditions.end( ); ++it) { if ( (*it)->getKind( ) == "cmis:thumbnail" ) return (*it)->getUrl( ); } return url; } // LCOV_EXCL_START string Object::toString( ) { stringstream buf; buf << "Id: " << getId() << endl; buf << "Name: " << getName() << endl; buf << "Type: " << getType() << endl; buf << "Base type: " << getBaseType() << endl; buf << "Created on " << boost::posix_time::to_simple_string( getCreationDate() ) << " by " << getCreatedBy() << endl; buf << "Last modified on " << boost::posix_time::to_simple_string( getLastModificationDate() ) << " by " << getLastModifiedBy() << endl; buf << "Change token: " << getChangeToken() << endl; // Write Allowable Actions if ( getAllowableActions( ) ) buf << endl << getAllowableActions( )->toString( ) << endl; // Write remaining properties static const char* skippedProps[] = { "cmis:name", "cmis:baseTypeId", "cmis:objectTypeId", "cmis:createdBy", "cmis:creationDate", "cmis:lastModifiedBy", "cmis:lastModificationDate", "cmis::changeToken" }; int skippedCount = sizeof( skippedProps ) / sizeof( char* ); for ( PropertyPtrMap::iterator it = getProperties( ).begin(); it != getProperties( ).end( ); ++it ) { string propId = it->first; bool toSkip = false; for ( int i = 0; i < skippedCount && !toSkip; ++i ) { toSkip = propId == skippedProps[i]; } if ( !toSkip ) { libcmis::PropertyPtr prop = it->second; if ( prop != NULL && prop->getPropertyType( ) != NULL ) { buf << prop->getPropertyType( )->getDisplayName( ) << "( " << prop->getPropertyType()->getId( ) << " ): " << endl; vector< string > strValues = prop->getStrings( ); for ( vector< string >::iterator valueIt = strValues.begin( ); valueIt != strValues.end( ); ++valueIt ) { buf << "\t" << *valueIt << endl; } } } } vector< libcmis::RenditionPtr > renditions = getRenditions( ); if ( !renditions.empty() ) { buf << "Renditions: " << endl; for ( vector< libcmis::RenditionPtr >::iterator it = renditions.begin(); it != renditions.end(); ++it ) { buf << ( *it )->toString( ) << endl; } } return buf.str(); } // LCOV_EXCL_STOP void Object::toXml( xmlTextWriterPtr writer ) { // Output the properties xmlTextWriterStartElement( writer, BAD_CAST( "cmis:properties" ) ); for ( PropertyPtrMap::iterator it = getProperties( ).begin( ); it != getProperties( ).end( ); ++it ) { it->second->toXml( writer ); } xmlTextWriterEndElement( writer ); // cmis:properties } } libcmis-0.5.2/src/libcmis/onedrive-session.hxx0000664000175000017500000000427613407414352016335 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _ONEDRIVE_SESSION_HXX_ #define _ONEDRIVE_SESSION_HXX_ #include #include "base-session.hxx" #include "json-utils.hxx" class OneDriveSession : public BaseSession { public: OneDriveSession( std::string baseUrl, std::string username, std::string password, libcmis::OAuth2DataPtr oauth2, bool verbose = false ); OneDriveSession( const OneDriveSession& copy ); ~OneDriveSession ( ); virtual libcmis::RepositoryPtr getRepository( ); virtual bool setRepository( std::string ) { return true; } virtual libcmis::ObjectPtr getObject( std::string id ); virtual libcmis::ObjectPtr getObjectByPath( std::string path ); virtual libcmis::ObjectTypePtr getType( std::string id ); virtual std::vector< libcmis::ObjectTypePtr > getBaseTypes( ); libcmis::ObjectPtr getObjectFromJson( Json& jsonRes ); bool isAPathMatch( Json objectJson, std::string path ); private: OneDriveSession( ); }; #endif /* _ONEDRIVE_SESSION_HXX_ */ libcmis-0.5.2/src/libcmis/Makefile.am0000664000175000017500000000621613407475712014347 00000000000000AM_CXXFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ $(XML2_CFLAGS) \ $(CURL_CFLAGS) \ $(BOOST_CPPFLAGS) if ENABLE_VISIBILITY AM_CXXFLAGS += -fvisibility=hidden endif noinst_LTLIBRARIES = libcmis.la lib_LTLIBRARIES = libcmis-@LIBCMIS_API_VERSION@.la libcmis_@LIBCMIS_API_VERSION@_la_SOURCES = \ dummy.cxx libcmis_la_CPPFLAGS = -DLIBCMIS_BUILD if ENABLE_VISIBILITY libcmis_la_CPPFLAGS += -DLIBCMIS_VISIBILITY endif libcmis_la_SOURCES = \ allowable-actions.cxx \ atom-document.cxx \ atom-document.hxx \ atom-folder.cxx \ atom-folder.hxx \ atom-object-type.cxx \ atom-object-type.hxx \ atom-object.cxx \ atom-object.hxx \ atom-session.cxx \ atom-session.hxx \ atom-workspace.cxx \ atom-workspace.hxx \ base-session.cxx \ base-session.hxx \ document.cxx \ folder.cxx \ gdrive-allowable-actions.hxx \ gdrive-document.cxx \ gdrive-document.hxx \ gdrive-folder.cxx \ gdrive-folder.hxx \ gdrive-object-type.cxx \ gdrive-object-type.hxx \ gdrive-object.cxx \ gdrive-object.hxx \ gdrive-property.cxx \ gdrive-property.hxx \ gdrive-repository.cxx \ gdrive-repository.hxx \ gdrive-session.cxx \ gdrive-session.hxx \ gdrive-utils.cxx \ gdrive-utils.hxx \ http-session.cxx \ http-session.hxx \ json-utils.cxx \ json-utils.hxx \ oauth2-data.cxx \ oauth2-handler.cxx \ oauth2-handler.hxx \ oauth2-providers.cxx \ oauth2-providers.hxx \ object-type.cxx \ object.cxx \ onedrive-allowable-actions.hxx \ onedrive-document.cxx \ onedrive-document.hxx \ onedrive-folder.cxx \ onedrive-folder.hxx \ onedrive-object-type.cxx \ onedrive-object-type.hxx \ onedrive-object.cxx \ onedrive-object.hxx \ onedrive-property.cxx \ onedrive-property.hxx \ onedrive-repository.cxx \ onedrive-repository.hxx \ onedrive-session.cxx \ onedrive-session.hxx \ onedrive-utils.cxx \ onedrive-utils.hxx \ property-type.cxx \ property.cxx \ rendition.cxx \ repository.cxx \ session-factory.cxx \ sharepoint-allowable-actions.hxx \ sharepoint-document.cxx \ sharepoint-document.hxx \ sharepoint-folder.cxx \ sharepoint-folder.hxx \ sharepoint-object-type.cxx \ sharepoint-object-type.hxx \ sharepoint-object.cxx \ sharepoint-object.hxx \ sharepoint-property.cxx \ sharepoint-property.hxx \ sharepoint-repository.cxx \ sharepoint-repository.hxx \ sharepoint-session.cxx \ sharepoint-session.hxx \ sharepoint-utils.cxx \ sharepoint-utils.hxx \ ws-document.cxx \ ws-document.hxx \ ws-folder.cxx \ ws-folder.hxx \ ws-navigationservice.cxx \ ws-navigationservice.hxx \ ws-object-type.cxx \ ws-object-type.hxx \ ws-object.cxx \ ws-object.hxx \ ws-objectservice.cxx \ ws-objectservice.hxx \ ws-relatedmultipart.cxx \ ws-relatedmultipart.hxx \ ws-repositoryservice.cxx \ ws-repositoryservice.hxx \ ws-requests.cxx \ ws-requests.hxx \ ws-session.cxx \ ws-session.hxx \ ws-soap.cxx \ ws-soap.hxx \ ws-versioningservice.cxx \ ws-versioningservice.hxx \ xml-utils.cxx libcmis_@LIBCMIS_API_VERSION@_la_LDFLAGS = -export-dynamic -no-undefined -version-info 5:0:0 libcmis_@LIBCMIS_API_VERSION@_la_LIBADD = \ libcmis.la \ $(XML2_LIBS) \ $(CURL_LIBS) \ $(BOOST_SMART_PTR_LIBS) \ $(BOOST_DATE_TIME_LDFLAGS) \ $(BOOST_DATE_TIME_LIBS) libcmis-0.5.2/src/libcmis/gdrive-repository.hxx0000664000175000017500000000241613407414352016530 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _GDRIVE_REPOSITORY_HXX_ #define _GDRIVE_REPOSITORY_HXX_ #include class GdriveRepository: public libcmis::Repository { public: GdriveRepository( ); }; #endif libcmis-0.5.2/src/libcmis/atom-document.cxx0000664000175000017500000003731413407414352015607 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "atom-document.hxx" #include #include #include #include #include #include "atom-session.hxx" using namespace std; using namespace libcmis; AtomDocument::AtomDocument( AtomPubSession* session ) : libcmis::Object( session ), libcmis::Document( session ), AtomObject( session ), m_contentUrl( ) { } AtomDocument::AtomDocument( AtomPubSession* session, xmlNodePtr entryNd ) : libcmis::Object( session ), libcmis::Document( session ), AtomObject( session ), m_contentUrl( ) { xmlDocPtr doc = libcmis::wrapInDoc( entryNd ); refreshImpl( doc ); xmlFreeDoc( doc ); } AtomDocument::~AtomDocument( ) { } vector< libcmis::FolderPtr > AtomDocument::getParents( ) { AtomLink* parentsLink = getLink( "up", "" ); if ( ( NULL == parentsLink ) || ( getAllowableActions( ).get() && !getAllowableActions()->isAllowed( libcmis::ObjectAction::GetObjectParents ) ) ) throw libcmis::Exception( string( "GetObjectParents not allowed on node " ) + getId() ); vector< libcmis::FolderPtr > parents; string buf; try { buf = getSession()->httpGetRequest( parentsLink->getHref( ) )->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } xmlDocPtr doc = xmlReadMemory( buf.c_str(), buf.size(), parentsLink->getHref( ).c_str(), NULL, 0 ); if ( NULL != doc ) { xmlXPathContextPtr xpathCtx = xmlXPathNewContext( doc ); libcmis::registerNamespaces( xpathCtx ); if ( NULL != xpathCtx ) { const string& entriesReq( "//atom:entry" ); xmlXPathObjectPtr xpathObj = xmlXPathEvalExpression( BAD_CAST( entriesReq.c_str() ), xpathCtx ); if ( NULL != xpathObj && NULL != xpathObj->nodesetval ) { int size = xpathObj->nodesetval->nodeNr; for ( int i = 0; i < size; i++ ) { xmlNodePtr node = xpathObj->nodesetval->nodeTab[i]; xmlDocPtr entryDoc = libcmis::wrapInDoc( node ); libcmis::ObjectPtr object = getSession()->createObjectFromEntryDoc( entryDoc ); libcmis::FolderPtr folder = boost::dynamic_pointer_cast< libcmis::Folder >( object ); if ( folder.get() ) parents.push_back( folder ); xmlFreeDoc( entryDoc ); } } xmlXPathFreeObject( xpathObj ); } xmlXPathFreeContext( xpathCtx ); } else { throw libcmis::Exception( "Failed to parse folder infos" ); } xmlFreeDoc( doc ); return parents; } boost::shared_ptr< istream > AtomDocument::getContentStream( string /*streamId*/ ) { if ( getAllowableActions().get() && !getAllowableActions()->isAllowed( libcmis::ObjectAction::GetContentStream ) ) throw libcmis::Exception( string( "GetContentStream is not allowed on document " ) + getId() ); boost::shared_ptr< istream > stream; try { stream = getSession()->httpGetRequest( m_contentUrl )->getStream( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } return stream; } void AtomDocument::setContentStream( boost::shared_ptr< ostream > os, string contentType, string fileName, bool overwrite ) { if ( !os.get( ) ) throw libcmis::Exception( "Missing stream" ); if ( getAllowableActions().get() && !getAllowableActions()->isAllowed( libcmis::ObjectAction::GetContentStream ) ) throw libcmis::Exception( string( "SetContentStream is not allowed on document " ) + getId() ); string overwriteStr( "false" ); if ( overwrite ) overwriteStr = "true"; string urlPattern( m_contentUrl ); if ( urlPattern.find( '?' ) != string::npos ) urlPattern += "&"; else urlPattern += "?"; urlPattern += "overwriteFlag={overwriteFlag}"; map< string, string > params; params["overwriteFlag"] = overwriteStr; // Use the changeToken if set on the object if ( !getChangeToken().empty() ) { urlPattern += "&changeToken={changeToken}"; params["changeToken"] = getChangeToken(); } string putUrl = getSession()->createUrl( urlPattern, params ); bool tryBase64 = false; do { try { boost::shared_ptr< istream> is ( new istream ( os->rdbuf( ) ) ); if ( tryBase64 ) { tryBase64 = false; // Encode the content stringstream* encodedIn = new stringstream( ); libcmis::EncodedData encoder( encodedIn ); encoder.setEncoding( "base64" ); int bufLength = 1000; char* buf = new char[ bufLength ]; do { is->read( buf, bufLength ); int size = is->gcount( ); encoder.encode( buf, 1, size ); } while ( !is->eof( ) && !is->fail( ) ); delete[] buf; encoder.finish( ); encodedIn->seekg( 0, ios_base::beg ); encodedIn->clear( ); is.reset( encodedIn ); } vector< string > headers; headers.push_back( string( "Content-Type: " ) + contentType ); if ( !fileName.empty( ) ) headers.push_back( string( "Content-Disposition: attachment; filename=" ) + fileName ); getSession()->httpPutRequest( putUrl, *is, headers ); long httpStatus = getSession( )->getHttpStatus( ); if ( httpStatus < 200 || httpStatus >= 300 ) throw libcmis::Exception( "Document content wasn't set for some reason" ); refresh( ); } catch ( const CurlException& e ) { // SharePoint wants base64 encoded content... let's try to figure out // if we falled in that case. if ( !tryBase64 && e.getHttpStatus() == 400 ) tryBase64 = true; else throw e.getCmisException( ); } } while ( tryBase64 ); } libcmis::DocumentPtr AtomDocument::checkOut( ) { if ( ( getAllowableActions( ).get() && !getAllowableActions()->isAllowed( libcmis::ObjectAction::CheckOut ) ) ) throw libcmis::Exception( string( "CanCheckout not allowed on document " ) + getId() ); xmlBufferPtr buf = xmlBufferCreate( ); xmlTextWriterPtr writer = xmlNewTextWriterMemory( buf, 0 ); xmlTextWriterStartDocument( writer, NULL, NULL, NULL ); // Create a document with only the needed properties PropertyPtrMap props; PropertyPtrMap::iterator it = getProperties( ).find( string( "cmis:objectId" ) ); if ( it != getProperties( ).end( ) ) { props.insert( *it ); } boost::shared_ptr< ostream > stream; AtomObject::writeAtomEntry( writer, props, stream, string( ) ); xmlTextWriterEndDocument( writer ); string str( ( const char * )xmlBufferContent( buf ) ); istringstream is( str ); xmlFreeTextWriter( writer ); xmlBufferFree( buf ); libcmis::HttpResponsePtr resp; string urlPattern = getSession()->getAtomRepository( )->getCollectionUrl( Collection::CheckedOut ); if ( urlPattern.find( "?" ) != string::npos ) urlPattern += "&"; else urlPattern += "?"; urlPattern += "objectId={objectId}"; map< string, string > params; params[ "objectId" ] = getId( ); string checkedOutUrl = getSession( )->createUrl( urlPattern, params ); try { resp = getSession( )->httpPostRequest( checkedOutUrl, is, "application/atom+xml;type=entry" ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } string respBuf = resp->getStream( )->str(); xmlDocPtr doc = xmlReadMemory( respBuf.c_str(), respBuf.size(), checkedOutUrl.c_str(), NULL, 0 ); if ( NULL == doc ) throw libcmis::Exception( "Failed to parse object infos" ); libcmis::ObjectPtr created = getSession( )->createObjectFromEntryDoc( doc, AtomPubSession::RESULT_DOCUMENT ); xmlFreeDoc( doc ); libcmis::DocumentPtr pwc = boost::dynamic_pointer_cast< libcmis::Document >( created ); if ( !pwc.get( ) ) throw libcmis::Exception( string( "Created object is not a document: " ) + created->getId( ) ); return pwc; } void AtomDocument::cancelCheckout( ) { if ( ( getAllowableActions( ).get() && !getAllowableActions()->isAllowed( libcmis::ObjectAction::CancelCheckOut ) ) ) throw libcmis::Exception( string( "CanCancelCheckout not allowed on document " ) + getId() ); string url = getInfosUrl( ); // Use working-copy link if provided as a workaround // for some non-compliant repositories AtomLink* link = getLink( "working-copy", "application/atom+xml;type=entry" ); if ( link ) url = link->getHref( ); try { getSession( )->httpDeleteRequest( url ); } catch ( CurlException const& e ) { throw e.getCmisException( ); } } libcmis::DocumentPtr AtomDocument::checkIn( bool isMajor, string comment, const PropertyPtrMap& properties, boost::shared_ptr< ostream > stream, string contentType, string ) { if ( ( getAllowableActions( ).get() && !getAllowableActions()->isAllowed( libcmis::ObjectAction::CheckIn ) ) ) throw libcmis::Exception( string( "CanCheckIn not allowed on document " ) + getId() ); string urlPattern = getInfosUrl( ); // Use working-copy link if provided as a workaround // for some non-compliant repositories AtomLink* link = getLink( "working-copy", "application/atom+xml;type=entry" ); if ( link ) urlPattern = link->getHref( ); if ( urlPattern.find( "?" ) != string::npos ) urlPattern += "&"; else urlPattern += "?"; urlPattern += "checkin=true&major={major}&checkinComment={checkinComment}"; map< string, string > params; string majorStr = "false"; if ( isMajor ) majorStr = "true"; params[ "major" ] = majorStr; params[ "checkinComment" ] = comment; string checkInUrl = getSession( )->createUrl( urlPattern, params ); xmlBufferPtr buf = xmlBufferCreate( ); xmlTextWriterPtr writer = xmlNewTextWriterMemory( buf, 0 ); xmlTextWriterStartDocument( writer, NULL, NULL, NULL ); AtomObject::writeAtomEntry( writer, properties, stream, contentType ); xmlTextWriterEndDocument( writer ); string str( ( const char * )xmlBufferContent( buf ) ); istringstream is( str ); xmlFreeTextWriter( writer ); xmlBufferFree( buf ); // Run the request libcmis::HttpResponsePtr response; try { vector< string > headers; headers.push_back( string( "Content-Type: application/atom+xml;type=entry" ) ); response = getSession( )->httpPutRequest( checkInUrl, is, headers ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } // Get the returned entry and update using it string respBuf = response->getStream( )->str( ); xmlDocPtr doc = xmlReadMemory( respBuf.c_str(), respBuf.size(), checkInUrl.c_str(), NULL, 0 ); if ( NULL == doc ) throw libcmis::Exception( "Failed to parse object infos" ); libcmis::ObjectPtr newVersion = getSession( )->createObjectFromEntryDoc( doc, AtomPubSession::RESULT_DOCUMENT ); if ( newVersion->getId( ) == getId( ) ) refreshImpl( doc ); xmlFreeDoc( doc ); return boost::dynamic_pointer_cast< libcmis::Document >( newVersion ); } vector< libcmis::DocumentPtr > AtomDocument::getAllVersions( ) { if ( getAllowableActions( ).get() && !getAllowableActions()->isAllowed( libcmis::ObjectAction::GetAllVersions ) ) throw libcmis::Exception( string( "GetAllVersions not allowed on node " ) + getId() ); vector< libcmis::DocumentPtr > versions; AtomLink* link = getLink( "version-history", string( ) ); if ( link != NULL ) { string pageUrl = link->getHref( ); string buf; try { buf = getSession()->httpGetRequest( pageUrl )->getStream( )->str( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } xmlDocPtr doc = xmlReadMemory( buf.c_str(), buf.size(), pageUrl.c_str(), NULL, 0 ); if ( NULL != doc ) { xmlXPathContextPtr xpathCtx = xmlXPathNewContext( doc ); libcmis::registerNamespaces( xpathCtx ); if ( NULL != xpathCtx ) { // Get the entries const string& entriesReq( "//atom:entry" ); xmlXPathObjectPtr xpathObj = xmlXPathEvalExpression( BAD_CAST( entriesReq.c_str() ), xpathCtx ); if ( NULL != xpathObj && NULL != xpathObj->nodesetval ) { int size = xpathObj->nodesetval->nodeNr; for ( int i = 0; i < size; i++ ) { xmlNodePtr node = xpathObj->nodesetval->nodeTab[i]; xmlDocPtr entryDoc = libcmis::wrapInDoc( node ); libcmis::ObjectPtr cmisObject = getSession()->createObjectFromEntryDoc( entryDoc ); libcmis::DocumentPtr cmisDoc = boost::dynamic_pointer_cast< libcmis::Document >( cmisObject ); if ( cmisDoc.get() ) versions.push_back( cmisDoc ); xmlFreeDoc( entryDoc ); } } xmlXPathFreeObject( xpathObj ); } xmlXPathFreeContext( xpathCtx ); } else { throw libcmis::Exception( "Failed to parse versions infos" ); } xmlFreeDoc( doc ); } return versions; } void AtomDocument::extractInfos( xmlDocPtr doc ) { AtomObject::extractInfos( doc ); // Get the content url xmlXPathContextPtr xpathCtx = xmlXPathNewContext( doc ); if ( NULL != doc ) { libcmis::registerNamespaces( xpathCtx ); if ( NULL != xpathCtx ) { xmlXPathObjectPtr xpathObj = xmlXPathEvalExpression( BAD_CAST( "//atom:content" ), xpathCtx ); if ( xpathObj && xpathObj->nodesetval && xpathObj->nodesetval->nodeNr > 0 ) { xmlNodePtr contentNd = xpathObj->nodesetval->nodeTab[0]; xmlChar* src = xmlGetProp( contentNd, BAD_CAST( "src" ) ); m_contentUrl = string( ( char* ) src ); xmlFree( src ); } xmlXPathFreeObject( xpathObj ); } xmlXPathFreeContext( xpathCtx ); } } libcmis-0.5.2/src/libcmis/gdrive-session.hxx0000664000175000017500000000377713407414352016007 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _GDRIVE_SESSION_HXX_ #define _GDRIVE_SESSION_HXX_ #include #include "base-session.hxx" class GDriveSession : public BaseSession { public: GDriveSession( std::string baseUrl, std::string username, std::string password, libcmis::OAuth2DataPtr oauth2, bool verbose = false ); GDriveSession( const GDriveSession& copy ); ~GDriveSession ( ); virtual libcmis::RepositoryPtr getRepository( ); virtual bool setRepository( std::string ); virtual libcmis::ObjectPtr getObject( std::string id ); virtual libcmis::ObjectPtr getObjectByPath( std::string path ); virtual libcmis::ObjectTypePtr getType( std::string id ); virtual std::vector< libcmis::ObjectTypePtr > getBaseTypes( ); private: GDriveSession( ); }; #endif /* _GDRIVE_SESSION_HXX_ */ libcmis-0.5.2/src/libcmis/ws-relatedmultipart.hxx0000664000175000017500000001051613407173247017051 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _WS_RELATEDMULTIPART_HXX_ #define _WS_RELATEDMULTIPART_HXX_ #include #include #include #include #include #include #include class RelatedPart { private: std::string m_name; std::string m_contentType; std::string m_content; public: RelatedPart( std::string& name, std::string& type, std::string& content ); ~RelatedPart( ) { }; std::string getName( ) { return m_name; } std::string getContentType( ) { return m_contentType; } std::string getContent( ) { return m_content; } /** Create the string to place between the boundaries in the multipart. \param cid the content Id to output */ std::string toString( std::string cid ); }; typedef boost::shared_ptr< RelatedPart > RelatedPartPtr; /** Represents a multipart/related content as specified by RFC-2387. */ class RelatedMultipart { private: std::string m_startId; std::string m_startInfo; std::map< std::string, RelatedPartPtr > m_parts; std::string m_boundary; public: /** Create a multipart/related from scratch (most probably to output it later). */ RelatedMultipart( ); /** Parse a multipart body to extract the entries from it. */ RelatedMultipart( const std::string& body, const std::string& contentType ); /** Get the Content ids of all the parts; */ std::vector< std::string > getIds( ); /** Get the entry corresponding to the given ID. */ RelatedPartPtr getPart( std::string& cid ); /** Get the id of the multipart start entry. */ std::string& getStartId( ) { return m_startId; } std::string& getStartInfo( ) { return m_startInfo; } /** Add an entry to the multipart and returns the content ID that was created for it. */ std::string addPart( RelatedPartPtr part ); /** Define the start of the multipart. That method needs to be called before running toString(): the output order of the entries is not guaranteed. \param cid the Content-Id of the start entry \param startInfo the type to use as start-info in the Content-Type */ void setStart( std::string& cid, std::string& startInfo ); /** Compute the content type for the multipart object to set as the Content-Type HTTP header. */ std::string getContentType( ); /** Dump the multipart to an input stream: this can be provided as is as an HTTP post request body. */ boost::shared_ptr< std::istringstream > toStream( ); /** Provide an access to the boundary token for the unit tests. */ std::string getBoundary( ) { return m_boundary; } private: /** Generate a content id, using an entry name and some random uuid. */ std::string createPartId( const std::string& name ); }; /** Extract stream from xs:base64Binary node using either xop:Include or base64 encoded data. */ boost::shared_ptr< std::istream > getStreamFromNode( xmlNodePtr node, RelatedMultipart& multipart ); #endif libcmis-0.5.2/src/libcmis/onedrive-object-type.hxx0000664000175000017500000000270013407414352017065 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _ONEDRIVE_OBJECT_TYPE_HXX_ #define _ONEDRIVE_OBJECT_TYPE_HXX_ #include #include "json-utils.hxx" class OneDriveObjectType: public libcmis::ObjectType { public: OneDriveObjectType( const std::string& id ); virtual libcmis::ObjectTypePtr getParentType( ); virtual libcmis::ObjectTypePtr getBaseType( ); }; #endif libcmis-0.5.2/src/libcmis/gdrive-object.hxx0000664000175000017500000000610213407414352015553 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _GDRIVE_OBJECT_HXX_ #define _GDRIVE_OBJECT_HXX_ #include #include "gdrive-session.hxx" #include "json-utils.hxx" /** Class representing an object for Google Drive protocol. This class overrides quite a number of its parent class methods to git the Google Drive API into the libcmis API. In order to reuse more of the base Object class, this class needs to map the main properties (like id, name, etc) to CMIS property ids (cmis:id, cmis:name, etc). */ class GDriveObject : public virtual libcmis::Object { public: GDriveObject( GDriveSession* session ); // Create a GDrive document from Json properties. // In case it's a revision, keep the ID and the name of the original file. GDriveObject( GDriveSession* session, Json json, std::string id = std::string( ), std::string name = std::string( ) ); GDriveObject( const GDriveObject& copy ); virtual ~GDriveObject( ) { } GDriveObject& operator=( const GDriveObject& copy ); void initializeFromJson( Json json, std::string id = std::string( ), std::string name = std::string( ) ); void refreshImpl( Json json ); Json createJsonFromParentId( const std::string& parentId ); std::string getUrl( ); std::string getUploadUrl( ); std::vector< std::string > getMultiStringProperty( const std::string& propertyName ); virtual std::vector< libcmis::RenditionPtr> getRenditions( std::string filter = std::string( ) ); virtual boost::shared_ptr< Object > updateProperties( const libcmis::PropertyPtrMap& properties ); virtual void refresh( ); virtual void remove( bool allVersions = true ); virtual void move( boost::shared_ptr< libcmis::Folder > source, boost::shared_ptr< libcmis::Folder > destination ); protected: GDriveSession* getSession( ); }; #endif libcmis-0.5.2/src/libcmis/oauth2-providers.hxx0000664000175000017500000000501013407173247016246 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _OAUTH2_PROVIDERS_HXX_ #define _OAUTH2_PROVIDERS_HXX_ #include class HttpSession; typedef std::string ( *OAuth2Parser ) ( HttpSession* session, const std::string& authUrl, const std::string& username, const std::string& password ); class OAuth2Providers { public : static std::string OAuth2Gdrive( HttpSession* session, const std::string& authUrl, const std::string& username, const std::string& password ); static std::string OAuth2Onedrive( HttpSession* session, const std::string& authUrl, const std::string& username, const std::string& password ); static std::string OAuth2Alfresco( HttpSession* session, const std::string& authUrl, const std::string& username, const std::string& password ); static OAuth2Parser getOAuth2Parser( const std::string& baseUrl ); /* * Parse the authorization code from the response page * in the input tag, with id = code */ static std::string parseCode ( const char* response ); /* * Parse input values and redirect link from the response page */ static int parseResponse ( const char* response, std::string& post, std::string& link ); }; #endif /* _OAUTH2_PROVIDERS_HXX_ */ libcmis-0.5.2/src/libcmis/rendition.cxx0000664000175000017500000001134013407414352015015 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include #include using namespace std; namespace libcmis{ Rendition::Rendition( ): m_streamId( ), m_mimeType( ), m_kind( ), m_href( ), m_title( ), m_length( -1 ), m_width ( -1 ), m_height( -1 ), m_renditionDocumentId( ) { } Rendition::Rendition( string streamId, string mimeType, string kind, string href, string title, long length, long width, long height, string renditionDocumentId ): m_streamId( streamId ), m_mimeType( mimeType ), m_kind( kind ), m_href( href ), m_title( title ), m_length( length ), m_width ( width ), m_height( height ), m_renditionDocumentId( renditionDocumentId ) { } Rendition::Rendition( xmlNodePtr node ): m_streamId( ), m_mimeType( ), m_kind( ), m_href( ), m_title( ), m_length( -1 ), m_width ( -1 ), m_height( -1 ), m_renditionDocumentId( ) { for ( xmlNodePtr child = node->children; child; child = child->next ) { xmlChar* content = xmlNodeGetContent( child ); string value( ( char * ) content ); xmlFree( content ); if ( xmlStrEqual( child->name, BAD_CAST( "streamId" ) ) ) m_streamId = value; else if ( xmlStrEqual( child->name, BAD_CAST( "mimetype" ) ) ) m_mimeType = value; else if ( xmlStrEqual( child->name, BAD_CAST( "length" ) ) ) m_length = libcmis::parseInteger( value ); else if ( xmlStrEqual( child->name, BAD_CAST( "kind" ) ) ) m_kind = value; else if ( xmlStrEqual( child->name, BAD_CAST( "title" ) ) ) m_title = value; else if ( xmlStrEqual( child->name, BAD_CAST( "height" ) ) ) m_height = libcmis::parseInteger( value ); else if ( xmlStrEqual( child->name, BAD_CAST( "width" ) ) ) m_width = libcmis::parseInteger( value ); else if ( xmlStrEqual( child->name, BAD_CAST( "renditionDocumentId" ) ) ) m_renditionDocumentId = value; } } Rendition::~Rendition( ) { } bool Rendition::isThumbnail( ) { return m_kind == "cmis:thumbnail"; } const string& Rendition::getStreamId( ) const { return m_streamId; } const string& Rendition::getMimeType( ) const { return m_mimeType; } const string& Rendition::getKind( ) const { return m_kind; } const string& Rendition::getUrl( ) const { return m_href; } const string& Rendition::getTitle( ) const { return m_title; } long Rendition::getLength( ) const { return m_length; } long Rendition::getWidth( ) const { return m_width; } long Rendition::getHeight( ) const { return m_height; } const string& Rendition::getRenditionDocumentId( ) { return m_renditionDocumentId; } // LCOV_EXCL_START string Rendition::toString( ) { stringstream buf; if ( !getStreamId( ).empty( ) ) buf << " ID: " << getStreamId( ) << endl; if ( !getKind().empty() ) buf << " Kind: " << getKind( ) << endl; if ( !getMimeType( ).empty() ) buf << " MimeType: " << getMimeType( ) << endl; if ( !getUrl().empty( ) ) buf << " URL: " << getUrl( ) << endl; if ( !getTitle().empty( ) ) buf << " Title: " << getTitle( ) << endl; if ( getLength( ) >= 0 ) buf << " Length: " << getLength( ) << endl; if ( getWidth( ) >= 0 ) buf << " Width: " << getWidth( ) << endl; if ( getHeight( ) >= 0 ) buf << " Height: " << getHeight( ) << endl; if ( !getRenditionDocumentId().empty( ) ) buf << " Rendition Document ID: " << getRenditionDocumentId( ) << endl; return buf.str( ); } // LCOV_EXCL_STOP } libcmis-0.5.2/src/libcmis/object-type.cxx0000664000175000017500000003074013407414352015254 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include #include using namespace std; namespace libcmis { ObjectType::ObjectType( ) : m_refreshTimestamp( 0 ), m_id( ), m_localName( ), m_localNamespace( ), m_displayName( ), m_queryName( ), m_description( ), m_parentTypeId( ), m_baseTypeId( ), m_creatable( false ), m_fileable( false ), m_queryable( false ), m_fulltextIndexed( false ), m_includedInSupertypeQuery( false ), m_controllablePolicy( false ), m_controllableAcl( false ), m_versionable( false ), m_contentStreamAllowed( libcmis::ObjectType::Allowed ), m_propertiesTypes( ) { } ObjectType::ObjectType( xmlNodePtr node ) : m_refreshTimestamp( 0 ), m_id( ), m_localName( ), m_localNamespace( ), m_displayName( ), m_queryName( ), m_description( ), m_parentTypeId( ), m_baseTypeId( ), m_creatable( false ), m_fileable( false ), m_queryable( false ), m_fulltextIndexed( false ), m_includedInSupertypeQuery( false ), m_controllablePolicy( false ), m_controllableAcl( false ), m_versionable( false ), m_contentStreamAllowed( libcmis::ObjectType::Allowed ), m_propertiesTypes( ) { initializeFromNode( node ); } ObjectType::ObjectType( const ObjectType& copy ) : m_refreshTimestamp( copy.m_refreshTimestamp ), m_id( copy.m_id ), m_localName( copy.m_localName ), m_localNamespace( copy.m_localNamespace ), m_displayName( copy.m_displayName ), m_queryName( copy.m_queryName ), m_description( copy.m_description ), m_parentTypeId( copy.m_parentTypeId ), m_baseTypeId( copy.m_baseTypeId ), m_creatable( copy.m_creatable ), m_fileable( copy.m_fileable ), m_queryable( copy.m_queryable ), m_fulltextIndexed( copy.m_fulltextIndexed ), m_includedInSupertypeQuery( copy.m_includedInSupertypeQuery ), m_controllablePolicy( copy.m_controllablePolicy ), m_controllableAcl( copy.m_controllableAcl ), m_versionable( copy.m_versionable ), m_contentStreamAllowed( copy.m_contentStreamAllowed ), m_propertiesTypes( copy.m_propertiesTypes ) { } ObjectType& ObjectType::operator=( const ObjectType& copy ) { if ( this != © ) { m_refreshTimestamp = copy.m_refreshTimestamp; m_id = copy.m_id; m_localName = copy.m_localName; m_localNamespace = copy.m_localNamespace; m_displayName = copy.m_displayName; m_queryName = copy.m_queryName; m_description = copy.m_description; m_parentTypeId = copy.m_parentTypeId; m_baseTypeId = copy.m_baseTypeId; m_creatable = copy.m_creatable; m_fileable = copy.m_fileable; m_queryable = copy.m_queryable; m_fulltextIndexed = copy.m_fulltextIndexed; m_includedInSupertypeQuery = copy.m_includedInSupertypeQuery; m_controllablePolicy = copy.m_controllablePolicy; m_controllableAcl = copy.m_controllableAcl; m_versionable = copy.m_versionable; m_contentStreamAllowed = copy.m_contentStreamAllowed; m_propertiesTypes = copy.m_propertiesTypes; } return *this; } time_t ObjectType::getRefreshTimestamp( ) const { return m_refreshTimestamp; } string ObjectType::getId( ) const { return m_id; } string ObjectType::getLocalName( ) const { return m_localName; } string ObjectType::getLocalNamespace( ) const { return m_localNamespace; } string ObjectType::getDisplayName( ) const { return m_displayName; } string ObjectType::getQueryName( ) const { return m_queryName; } string ObjectType::getDescription( ) const { return m_description; } string ObjectType::getParentTypeId( ) const { return m_parentTypeId; } string ObjectType::getBaseTypeId( ) const { return m_baseTypeId; } bool ObjectType::isCreatable( ) const { return m_creatable; } bool ObjectType::isFileable( ) const { return m_fileable; } bool ObjectType::isQueryable( ) const { return m_queryable; } bool ObjectType::isFulltextIndexed( ) const { return m_fulltextIndexed; } bool ObjectType::isIncludedInSupertypeQuery( ) const { return m_includedInSupertypeQuery; } bool ObjectType::isControllablePolicy( ) const { return m_controllablePolicy; } bool ObjectType::isControllableACL( ) const { return m_controllableAcl; } bool ObjectType::isVersionable( ) const { return m_versionable; } ObjectType::ContentStreamAllowed ObjectType::getContentStreamAllowed( ) const { return m_contentStreamAllowed; } map< string, PropertyTypePtr >& ObjectType::getPropertiesTypes( ) { return m_propertiesTypes; } void ObjectType::initializeFromNode( xmlNodePtr typeNode ) { if ( typeNode != NULL ) { for ( xmlNodePtr child = typeNode->children; child; child = child->next ) { xmlChar* content = xmlNodeGetContent( child ); if ( content != NULL ) { string value( ( const char * ) content, xmlStrlen( content ) ); if ( xmlStrEqual( child->name, BAD_CAST( "id" ) ) ) m_id = value; else if ( xmlStrEqual( child->name, BAD_CAST( "localName" ) ) ) m_localName = value; else if ( xmlStrEqual( child->name, BAD_CAST( "localNamespace" ) ) ) m_localNamespace = value; else if ( xmlStrEqual( child->name, BAD_CAST( "displayName" ) ) ) m_displayName = value; else if ( xmlStrEqual( child->name, BAD_CAST( "queryName" ) ) ) m_queryName = value; else if ( xmlStrEqual( child->name, BAD_CAST( "description" ) ) ) m_description = value; else if ( xmlStrEqual( child->name, BAD_CAST( "baseId" ) ) ) m_baseTypeId = value; else if ( xmlStrEqual( child->name, BAD_CAST( "parentId" ) ) ) m_parentTypeId = value; else if ( xmlStrEqual( child->name, BAD_CAST( "creatable" ) ) ) m_creatable = libcmis::parseBool( value ); else if ( xmlStrEqual( child->name, BAD_CAST( "fileable" ) ) ) m_fileable = libcmis::parseBool( value ); else if ( xmlStrEqual( child->name, BAD_CAST( "queryable" ) ) ) m_queryable = libcmis::parseBool( value ); else if ( xmlStrEqual( child->name, BAD_CAST( "fulltextIndexed" ) ) ) m_fulltextIndexed = libcmis::parseBool( value ); else if ( xmlStrEqual( child->name, BAD_CAST( "includedInSupertypeQuery" ) ) ) m_includedInSupertypeQuery = libcmis::parseBool( value ); else if ( xmlStrEqual( child->name, BAD_CAST( "controllablePolicy" ) ) ) m_controllablePolicy = libcmis::parseBool( value ); else if ( xmlStrEqual( child->name, BAD_CAST( "controllableACL" ) ) ) m_controllableAcl = libcmis::parseBool( value ); else if ( xmlStrEqual( child->name, BAD_CAST( "versionable" ) ) ) m_versionable = libcmis::parseBool( value ); else if ( xmlStrEqual( child->name, BAD_CAST( "contentStreamAllowed" ) ) ) { libcmis::ObjectType::ContentStreamAllowed streamAllowed = libcmis::ObjectType::Allowed; if ( value == "notallowed" ) streamAllowed = libcmis::ObjectType::NotAllowed; else if ( value == "required" ) streamAllowed = libcmis::ObjectType::Required; m_contentStreamAllowed = streamAllowed; } else { libcmis::PropertyTypePtr type( new libcmis::PropertyType( child ) ); m_propertiesTypes[ type->getId() ] = type; } xmlFree( content ); } } m_refreshTimestamp = time( NULL ); } } void ObjectType::refresh( ) { throw Exception( "ObjectType::refresh() shouldn't be called" ); } ObjectTypePtr ObjectType::getParentType( ) { throw Exception( "ObjectType::getParentType() shouldn't be called" ); } ObjectTypePtr ObjectType::getBaseType( ) { throw Exception( "ObjectType::getBaseType() shouldn't be called" ); } vector< ObjectTypePtr > ObjectType::getChildren( ) { throw Exception( "ObjectType::getChildren() shouldn't be called" ); } // LCOV_EXCL_START string ObjectType::toString( ) { stringstream buf; buf << "Type Description:" << endl << endl; buf << "Id: " << getId( ) << endl; buf << "Display name: " << getDisplayName( ) << endl; buf << "Parent type: " << m_parentTypeId << endl; buf << "Base type: " << m_baseTypeId << endl; buf << "Children types [(id) Name]: " << endl; try { vector< libcmis::ObjectTypePtr > children = getChildren( ); for ( vector< libcmis::ObjectTypePtr >::iterator it = children.begin(); it != children.end(); ++it ) { libcmis::ObjectTypePtr type = *it; buf << " (" << type->getId( ) << ")\t" << type->getDisplayName( ) << endl; } } catch ( const libcmis::Exception& ) { // Ignore it } buf << "Creatable: " << isCreatable( ) << endl; buf << "Fileable: " << isFileable( ) << endl; buf << "Queryable: " << isQueryable( ) << endl; buf << "Full text indexed: " << isFulltextIndexed( ) << endl; buf << "Included in supertype query: " << isIncludedInSupertypeQuery( ) << endl; buf << "Controllable policy: " << isControllablePolicy( ) << endl; buf << "Controllable ACL: " << isControllableACL( ) << endl; buf << "Versionable: " << isVersionable( ) << endl; buf << "Property Definitions [RO/RW (id) Name]: " << endl; map< string, libcmis::PropertyTypePtr > propsTypes = getPropertiesTypes( ); for ( map< string, libcmis::PropertyTypePtr >::iterator it = propsTypes.begin( ); it != propsTypes.end( ); ++it ) { libcmis::PropertyTypePtr propType = it->second; string updatable( "RO" ); if ( propType->isUpdatable( ) ) updatable = string( "RW" ); buf << " " << updatable << "\t (" << propType->getId( ) << ")\t" << propType->getDisplayName( ) << endl; } return buf.str(); } // LCOV_EXCL_STOP } libcmis-0.5.2/src/libcmis/document.cxx0000664000175000017500000000654213407414352014650 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include using namespace std; using libcmis::PropertyPtrMap; namespace libcmis { vector< string > Document::getPaths( ) { vector< string > paths; try { vector< libcmis::FolderPtr > parents = getParents( ); for ( vector< libcmis::FolderPtr >::iterator it = parents.begin( ); it != parents.end(); ++it ) { string path = ( *it )->getPath( ); if ( path.empty() ) continue; if ( path[path.size() - 1] != '/' ) path += "/"; path += getName( ); paths.push_back( path ); } } catch ( const libcmis::Exception& ) { // We may not have the permission to get the parents } return paths; } string Document::getContentType( ) { return getStringProperty( "cmis:contentStreamMimeType" ); } string Document::getContentFilename( ) { return getStringProperty( "cmis:contentStreamFileName" ); } long Document::getContentLength( ) { long contentLength = 0; PropertyPtrMap::const_iterator it = getProperties( ).find( string( "cmis:contentStreamLength" ) ); if ( it != getProperties( ).end( ) && it->second != NULL && !it->second->getLongs( ).empty( ) ) contentLength = it->second->getLongs( ).front( ); return contentLength; } // LCOV_EXCL_START string Document::toString( ) { stringstream buf; buf << "Document Object:" << endl << endl; buf << Object::toString(); try { vector< libcmis::FolderPtr > parents = getParents( ); buf << "Parents ids: "; for ( vector< libcmis::FolderPtr >::iterator it = parents.begin(); it != parents.end(); ++it ) buf << "'" << ( *it )->getId( ) << "' "; buf << endl; } catch ( const libcmis::Exception& ) { } buf << "Content Type: " << getContentType( ) << endl; buf << "Content Length: " << getContentLength( ) << endl; buf << "Content Filename: " << getContentFilename( ) << endl; return buf.str(); } // LCOV_EXCL_STOP } libcmis-0.5.2/src/libcmis/sharepoint-property.cxx0000664000175000017500000000463013407414352017064 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "sharepoint-property.hxx" #include #include "sharepoint-utils.hxx" using namespace std; using namespace libcmis; SharePointProperty::SharePointProperty( ) { } SharePointProperty::~SharePointProperty( ) { } SharePointProperty::SharePointProperty( const string& key, Json json ): Property( ) { PropertyTypePtr propertyType( new PropertyType( ) ); string convertedKey = SharePointUtils::toCmisKey( key ); propertyType->setId( convertedKey ); propertyType->setLocalName( convertedKey ); propertyType->setLocalNamespace( convertedKey ); propertyType->setQueryName( convertedKey ); propertyType->setDisplayName( key ); propertyType->setTypeFromJsonType( json.getStrType( ) ); propertyType->setUpdatable( false ); propertyType->setMultiValued( false ); propertyType->setType( SharePointUtils::getPropertyType( convertedKey ) ); setPropertyType( propertyType ); vector< string > values = SharePointUtils::parseSharePointProperty( key, json ); setValues( values ); } SharePointProperty::SharePointProperty( const SharePointProperty& copy ) : libcmis::Property( copy ) { } SharePointProperty& SharePointProperty::operator=( const SharePointProperty& copy ) { if ( this != © ) { libcmis::Property::operator=( copy ); } return *this; } libcmis-0.5.2/src/libcmis/gdrive-document.cxx0000664000175000017500000002102213407414352016114 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "gdrive-document.hxx" #include #include "gdrive-folder.hxx" #include "gdrive-session.hxx" #include "json-utils.hxx" #include "gdrive-utils.hxx" using namespace std; using namespace libcmis; GDriveDocument::GDriveDocument( GDriveSession* session ) : libcmis::Object( session), libcmis::Document( session ), GDriveObject( session ), m_isGoogleDoc( false ) { } GDriveDocument::GDriveDocument( GDriveSession* session, Json json, string id, string name ) : libcmis::Object( session), libcmis::Document( session ), GDriveObject( session, json, id, name ), m_isGoogleDoc( false ) { m_isGoogleDoc = getContentType( ).find( "google" ) != string::npos; getRenditions( ); } GDriveDocument::~GDriveDocument( ) { } string GDriveDocument::getDownloadUrl( string streamId ) { string streamUrl; vector< RenditionPtr > renditions = getRenditions( ); if ( renditions.empty( ) ) return streamUrl; if ( !streamId.empty( ) ) { // Find the rendition associated with the streamId for ( vector< RenditionPtr >::iterator it = renditions.begin( ) ; it != renditions.end(); ++it ) { if ( (*it)->getStreamId( ) == streamId ) { streamUrl = (*it)->getUrl( ); break; } } } else { // Automatically find the rendition // Prefer ODF format for ( vector< RenditionPtr >::iterator it = renditions.begin( ) ; it != renditions.end(); ++it ) if ( (*it)->getMimeType( ).find( "opendocument") != string::npos ) return (*it)->getUrl( ); // Then MS format for ( vector< RenditionPtr >::iterator it = renditions.begin( ) ; it != renditions.end(); ++it ) if ( (*it)->getMimeType( ).find( "officedocument") != string::npos ) return (*it)->getUrl( ); // If not found, take the first one streamUrl = renditions.front( )->getUrl( ); } return streamUrl; } vector< libcmis::FolderPtr > GDriveDocument::getParents( ) { vector< libcmis::FolderPtr > parents; vector< string > parentsId = getMultiStringProperty( "cmis:parentId" ); // Create folder objects from parent IDs for ( vector< string >::iterator it = parentsId.begin( ); it != parentsId.end( ); ++it) { string parentId = ( *it ); libcmis::ObjectPtr obj = getSession( )->getObject( parentId ); libcmis::FolderPtr parent = boost::dynamic_pointer_cast< libcmis::Folder >( obj ); parents.push_back( parent ); } return parents; } boost::shared_ptr< istream > GDriveDocument::getContentStream( string streamId ) { boost::shared_ptr< istream > stream; string streamUrl = getDownloadUrl( streamId ); if ( streamUrl.empty( ) ) throw libcmis::Exception( "can not found stream url" ); try { stream = getSession( )->httpGetRequest( streamUrl )->getStream( ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } return stream; } void GDriveDocument::uploadStream( boost::shared_ptr< ostream > os, string contentType ) { if ( !os.get( ) ) throw libcmis::Exception( "Missing stream" ); if ( !isImmutable( ) ) throw libcmis::Exception( string ( "Document " + getId( )+ " is not editable" ) ); string putUrl = getUploadUrl( ) + getId( ); putUrl += "?uploadType=media"; // If it's a Google document, convert it if ( isGoogleDoc( ) ) putUrl += "&convert=true"; // Upload stream boost::shared_ptr< istream> is ( new istream ( os->rdbuf( ) ) ); vector headers; headers.push_back( string( "Content-Type: " ) + contentType ); try { getSession()->httpPutRequest( putUrl, *is, headers ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } long httpStatus = getSession( )->getHttpStatus( ); if ( httpStatus < 200 || httpStatus >= 300 ) throw libcmis::Exception( "Document content wasn't set for" "some reason" ); refresh( ); } void GDriveDocument::setContentStream( boost::shared_ptr< ostream > os, string contentType, string fileName, bool /*overwrite*/ ) { if ( !os.get( ) ) throw libcmis::Exception( "Missing stream" ); if ( !isImmutable( ) ) throw libcmis::Exception( string ( "Document " + getId( )+ " is not editable" ) ); string metaUrl = getUrl( ); // If it's a Google document, convert it if ( isGoogleDoc( ) ) metaUrl += "?convert=true"; // Update file name meta information if ( !fileName.empty( ) && fileName != getContentFilename( ) ) { Json metaJson; Json fileJson( fileName.c_str( ) ); metaJson.add("title", fileJson ); std::istringstream is( metaJson.toString( ) ); vector headers; headers.push_back( "Content-Type: application/json" ); try { getSession()->httpPutRequest( metaUrl, is, headers ); } catch ( const CurlException& e ) { throw e.getCmisException( ); } } // Upload stream uploadStream( os, contentType ); } libcmis::DocumentPtr GDriveDocument::checkOut( ) { // GDrive doesn't have CheckOut, so just return the same document here libcmis::ObjectPtr obj = getSession( )->getObject( getId( ) ); libcmis::DocumentPtr checkout = boost::dynamic_pointer_cast< libcmis::Document > ( obj ); return checkout; } void GDriveDocument::cancelCheckout( ) { // Don't do anything since we don't have CheckOut } libcmis::DocumentPtr GDriveDocument::checkIn( bool /*isMajor*/, std::string /*comment*/, const PropertyPtrMap& properties, boost::shared_ptr< std::ostream > stream, std::string contentType, std::string fileName ) { // GDrive doesn't have CheckIn, so just upload the properties, // the content stream and fetch the new document resource. updateProperties( properties ); setContentStream( stream, contentType, fileName ); libcmis::ObjectPtr obj = getSession( )->getObject( getId( ) ); libcmis::DocumentPtr checkin = boost::dynamic_pointer_cast< libcmis::Document > ( obj ); return checkin; } vector< libcmis::DocumentPtr > GDriveDocument::getAllVersions( ) { vector< libcmis::DocumentPtr > revisions; string versionUrl = getUrl( ) + "/revisions"; // Run the http request to get the properties definition string res; try { res = getSession()->httpGetRequest( versionUrl )->getStream()->str(); } catch ( const CurlException& e ) { throw e.getCmisException( ); } Json jsonRes = Json::parse( res ); Json::JsonVector objs = jsonRes["items"].getList( ); string parentId = getStringProperty( "cmis:parentId" ); // Create document objects from Json objects for(unsigned int i = 0; i < objs.size(); i++) { objs[i].add( "parents", GdriveUtils::createJsonFromParentId( parentId ) ); libcmis::DocumentPtr revision( new GDriveDocument( getSession(), objs[i], getId( ), getName( ) ) ); revisions.push_back( revision ); } return revisions; } libcmis-0.5.2/src/libcmis/ws-repositoryservice.cxx0000664000175000017500000000764413407414352017265 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "ws-repositoryservice.hxx" #include "ws-requests.hxx" #include "ws-session.hxx" using namespace std; RepositoryService::RepositoryService( ) : m_session( NULL ), m_url( "" ) { } RepositoryService::RepositoryService( WSSession* session ) : m_session( session ), m_url( session->getServiceUrl( "RepositoryService" ) ) { } RepositoryService::RepositoryService( const RepositoryService& copy ) : m_session( copy.m_session ), m_url( copy.m_url ) { } RepositoryService::~RepositoryService( ) { } RepositoryService& RepositoryService::operator=( const RepositoryService& copy ) { if ( this != © ) { m_session = copy.m_session; m_url = copy.m_url; } return *this; } map< string, string > RepositoryService::getRepositories( ) { map< string, string > repositories; GetRepositories request; vector< SoapResponsePtr > responses = m_session->soapRequest( m_url, request ); if ( responses.size() == 1 ) { GetRepositoriesResponse* response = dynamic_cast< GetRepositoriesResponse* >( responses.front( ).get( ) ); if ( response != NULL ) { repositories = response->getRepositories(); } } return repositories; } libcmis::RepositoryPtr RepositoryService::getRepositoryInfo( string id ) { libcmis::RepositoryPtr repository; GetRepositoryInfo request( id ); vector< SoapResponsePtr > responses = m_session->soapRequest( m_url, request ); if ( responses.size( ) == 1 ) { SoapResponse* resp = responses.front( ).get( ); GetRepositoryInfoResponse* response = dynamic_cast< GetRepositoryInfoResponse* >( resp ); if ( response != NULL ) repository = response->getRepository( ); } return repository; } libcmis::ObjectTypePtr RepositoryService::getTypeDefinition( string repoId, string typeId ) { libcmis::ObjectTypePtr type; GetTypeDefinition request( repoId, typeId ); vector< SoapResponsePtr > responses = m_session->soapRequest( m_url, request ); if ( responses.size( ) == 1 ) { SoapResponse* resp = responses.front( ).get( ); GetTypeDefinitionResponse* response = dynamic_cast< GetTypeDefinitionResponse* >( resp ); if ( response != NULL ) type = response->getType( ); } return type; } vector< libcmis::ObjectTypePtr > RepositoryService::getTypeChildren( string repoId, string typeId ) { vector< libcmis::ObjectTypePtr > children; GetTypeChildren request( repoId, typeId ); vector< SoapResponsePtr > responses = m_session->soapRequest( m_url, request ); if ( responses.size( ) == 1 ) { SoapResponse* resp = responses.front( ).get( ); GetTypeChildrenResponse* response = dynamic_cast< GetTypeChildrenResponse* >( resp ); if ( response != NULL ) children = response->getChildren( ); } return children; } libcmis-0.5.2/src/libcmis/atom-workspace.cxx0000664000175000017500000001654013407414352015765 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 Cédric Bosdonnat * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "atom-workspace.hxx" #include using namespace std; AtomRepository::AtomRepository( xmlNodePtr wsNode ): Repository( ), m_collections( ), m_uriTemplates( ) { if ( wsNode != NULL ) { xmlDocPtr doc = libcmis::wrapInDoc( wsNode ); xmlXPathContextPtr xpathCtx = xmlXPathNewContext( doc ); libcmis::registerNamespaces( xpathCtx ); if ( NULL != xpathCtx ) { // Get the collections xmlXPathObjectPtr xpathObj = xmlXPathEvalExpression( BAD_CAST( "//app:collection" ), xpathCtx ); if ( NULL != xpathObj ) readCollections( xpathObj->nodesetval ); xmlXPathFreeObject( xpathObj ); // Get the URI templates xpathObj = xmlXPathEvalExpression( BAD_CAST( "//cmisra:uritemplate" ), xpathCtx ); if ( NULL != xpathObj ) readUriTemplates( xpathObj->nodesetval ); xmlXPathFreeObject( xpathObj ); // Get the repository infos xpathObj = xmlXPathEvalExpression( BAD_CAST( "//cmisra:repositoryInfo" ), xpathCtx ); if ( NULL != xpathObj ) initializeFromNode( xpathObj->nodesetval->nodeTab[0] ); xmlXPathFreeObject( xpathObj ); } xmlXPathFreeContext( xpathCtx ); xmlFreeDoc( doc ); } } AtomRepository::AtomRepository( const AtomRepository& rCopy ) : Repository( rCopy ), m_collections( rCopy.m_collections ), m_uriTemplates( rCopy.m_uriTemplates ) { } AtomRepository::~AtomRepository( ) { m_collections.clear( ); m_uriTemplates.clear( ); } AtomRepository& AtomRepository::operator= ( const AtomRepository& rCopy ) { if ( this != &rCopy ) { m_collections = rCopy.m_collections; m_uriTemplates = rCopy.m_uriTemplates; } return *this; } string AtomRepository::getCollectionUrl( Collection::Type type ) { return m_collections[ type ]; } string AtomRepository::getUriTemplate( UriTemplate::Type type ) { return m_uriTemplates[ type ]; } void AtomRepository::readCollections( xmlNodeSetPtr nodeSet ) { int size = 0; if ( nodeSet ) size = nodeSet->nodeNr; for ( int i = 0; i < size; i++ ) { xmlNodePtr node = nodeSet->nodeTab[i]; // Look for the href property xmlChar* href = xmlGetProp( node, BAD_CAST( "href" ) ); if ( href ) { string collectionRef( ( char* )href ); xmlFree( href ); // Look for the cmisra:collectionType child for ( xmlNodePtr child = node->children; child; child = child->next ) { // SharePoint CMIS implementation doesn't follow the spec: // the cmisra namespace is omitted bool isCollectionType = xmlStrEqual( child->name, BAD_CAST( "collectionType" ) ); if ( isCollectionType ) { xmlChar* content = xmlNodeGetContent( child ); Collection::Type type = Collection::Root; bool typeDefined = false; if ( xmlStrEqual( content, BAD_CAST( "root" ) ) ) { type = Collection::Root; typeDefined = true; } else if ( xmlStrEqual( content, BAD_CAST( "types" ) ) ) { type = Collection::Types; typeDefined = true; } else if ( xmlStrEqual( content, BAD_CAST( "query" ) ) ) { type = Collection::Query; typeDefined = true; } else if ( xmlStrEqual( content, BAD_CAST( "checkedout" ) ) ) { type = Collection::CheckedOut; typeDefined = true; } else if ( xmlStrEqual( content, BAD_CAST( "unfiled" ) ) ) { type = Collection::Unfiled; typeDefined = true; } if ( typeDefined ) m_collections[ type ] = collectionRef; xmlFree( content ); } } } } } void AtomRepository::readUriTemplates( xmlNodeSetPtr nodeSet ) { int size = 0; if ( nodeSet ) size = nodeSet->nodeNr; for ( int i = 0; i < size; i++ ) { xmlNodePtr node = nodeSet->nodeTab[i]; string templateUri; UriTemplate::Type type = UriTemplate::ObjectById; bool typeDefined = false; // Look for the cmisra:template and cmisra:type children for ( xmlNodePtr child = node->children; child; child = child->next ) { bool isTemplate = xmlStrEqual( child->name, BAD_CAST( "template" ) ); bool isType = xmlStrEqual( child->name, BAD_CAST( "type" ) ); if ( isTemplate ) { xmlChar* content = xmlNodeGetContent( child ); if ( content != NULL ) templateUri = string( ( char * )content ); xmlFree( content ); } else if ( isType ) { xmlChar* content = xmlNodeGetContent( child ); if ( xmlStrEqual( content, BAD_CAST( "objectbyid" ) ) ) { type = UriTemplate::ObjectById; typeDefined = true; } else if ( xmlStrEqual( content, BAD_CAST( "objectbypath" ) ) ) { type = UriTemplate::ObjectByPath; typeDefined = true; } else if ( xmlStrEqual( content, BAD_CAST( "query" ) ) ) { type = UriTemplate::Query; typeDefined = true; } else if ( xmlStrEqual( content, BAD_CAST( "typebyid" ) ) ) { type = UriTemplate::TypeById; typeDefined = true; } xmlFree( content ); } } if ( !templateUri.empty() && typeDefined ) m_uriTemplates[ type ] = templateUri; } } libcmis-0.5.2/src/libcmis/base-session.hxx0000664000175000017500000000631513407414352015430 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _BASE_SESSION_HXX_ #define _BASE_SESSION_HXX_ #include #include #include #include #include #include #include #include #include #include #include #include #include "http-session.hxx" class OAuth2Handler; class BaseSession : public libcmis::Session, public HttpSession { protected: std::string m_bindingUrl; std::string m_repositoryId; std::vector< libcmis::RepositoryPtr > m_repositories; public: BaseSession( std::string sBindingUrl, std::string repository, std::string username, std::string password, bool noSslCheck = false, libcmis::OAuth2DataPtr oauth2 = libcmis::OAuth2DataPtr(), bool verbose = false ); /** This constructor copies an existing http session. This has been mostly designed for SessionFactory to save a few HTTP requests when guessing the binding to use. */ BaseSession( std::string sBindingUrl, std::string repository, const HttpSession& httpSession ); BaseSession( const BaseSession& copy ); ~BaseSession( ); BaseSession& operator=( const BaseSession& copy ); std::string& getRepositoryId( ) { return m_repositoryId; } // Utility methods std::string getRootId( ) { return getRepository()->getRootId( ); } std::string createUrl( const std::string& pattern, std::map< std::string, std::string > variables ); std::string getBindingUrl( ) { return m_bindingUrl; } // HttpSession overridden methods virtual void setOAuth2Data( libcmis::OAuth2DataPtr oauth2 ); // Session methods virtual void setNoSSLCertificateCheck( bool noCheck ); virtual std::vector< libcmis::RepositoryPtr > getRepositories( ); virtual libcmis::FolderPtr getRootFolder(); virtual libcmis::FolderPtr getFolder( std::string id ); protected: BaseSession( ); }; #endif libcmis-0.5.2/src/libcmis-c/0000775000175000017500000000000013411152400012563 500000000000000libcmis-0.5.2/src/libcmis-c/Makefile.in0000664000175000017500000013276213407705041014575 00000000000000# Makefile.in generated by automake 1.16.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2018 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ @ENABLE_VISIBILITY_TRUE@am__append_1 = -fvisibility=hidden @ENABLE_VISIBILITY_TRUE@am__append_2 = -DLIBCMIS_C_VISIBILITY subdir = src/libcmis-c ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \ $(top_srcdir)/m4/ax_cxx_compile_stdcxx_11.m4 \ $(top_srcdir)/m4/ax_gcc_func_attribute.m4 \ $(top_srcdir)/m4/boost.m4 $(top_srcdir)/m4/libtool.m4 \ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; am__install_max = 40 am__nobase_strip_setup = \ srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` am__nobase_strip = \ for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" am__nobase_list = $(am__nobase_strip_setup); \ for p in $$list; do echo "$$p $$p"; done | \ sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ if (++n[$$2] == $(am__install_max)) \ { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ END { for (dir in files) print dir, files[dir] }' am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' am__uninstall_files_from_dir = { \ test -z "$$files" \ || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ $(am__cd) "$$dir" && rm -f $$files; }; \ } am__installdirs = "$(DESTDIR)$(libdir)" LTLIBRARIES = $(lib_LTLIBRARIES) am__DEPENDENCIES_1 = libcmis_c_@LIBCMIS_API_VERSION@_la_DEPENDENCIES = \ ../libcmis/libcmis-@LIBCMIS_API_VERSION@.la \ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) am_libcmis_c_@LIBCMIS_API_VERSION@_la_OBJECTS = \ libcmis_c_@LIBCMIS_API_VERSION@_la-allowable-actions.lo \ libcmis_c_@LIBCMIS_API_VERSION@_la-document.lo \ libcmis_c_@LIBCMIS_API_VERSION@_la-error.lo \ libcmis_c_@LIBCMIS_API_VERSION@_la-folder.lo \ libcmis_c_@LIBCMIS_API_VERSION@_la-oauth2-data.lo \ libcmis_c_@LIBCMIS_API_VERSION@_la-object-type.lo \ libcmis_c_@LIBCMIS_API_VERSION@_la-object.lo \ libcmis_c_@LIBCMIS_API_VERSION@_la-property-type.lo \ libcmis_c_@LIBCMIS_API_VERSION@_la-property.lo \ libcmis_c_@LIBCMIS_API_VERSION@_la-rendition.lo \ libcmis_c_@LIBCMIS_API_VERSION@_la-repository.lo \ libcmis_c_@LIBCMIS_API_VERSION@_la-session-factory.lo \ libcmis_c_@LIBCMIS_API_VERSION@_la-session.lo \ libcmis_c_@LIBCMIS_API_VERSION@_la-vectors.lo libcmis_c_@LIBCMIS_API_VERSION@_la_OBJECTS = \ $(am_libcmis_c_@LIBCMIS_API_VERSION@_la_OBJECTS) AM_V_lt = $(am__v_lt_@AM_V@) am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) am__v_lt_0 = --silent am__v_lt_1 = libcmis_c_@LIBCMIS_API_VERSION@_la_LINK = $(LIBTOOL) $(AM_V_lt) \ --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link \ $(CXXLD) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) \ $(CXXFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_LDFLAGS) \ $(LDFLAGS) -o $@ AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ depcomp = $(SHELL) $(top_srcdir)/depcomp am__maybe_remake_depfiles = depfiles am__depfiles_remade = ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-allowable-actions.Plo \ ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-document.Plo \ ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-error.Plo \ ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-folder.Plo \ ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-oauth2-data.Plo \ ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-object-type.Plo \ ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-object.Plo \ ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-property-type.Plo \ ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-property.Plo \ ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-rendition.Plo \ ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-repository.Plo \ ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-session-factory.Plo \ ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-session.Plo \ ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-vectors.Plo am__mv = mv -f CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ $(AM_CXXFLAGS) $(CXXFLAGS) AM_V_CXX = $(am__v_CXX_@AM_V@) am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@) am__v_CXX_0 = @echo " CXX " $@; am__v_CXX_1 = CXXLD = $(CXX) CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \ $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ AM_V_CXXLD = $(am__v_CXXLD_@AM_V@) am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@) am__v_CXXLD_0 = @echo " CXXLD " $@; am__v_CXXLD_1 = COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ $(AM_CFLAGS) $(CFLAGS) AM_V_CC = $(am__v_CC_@AM_V@) am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) am__v_CC_0 = @echo " CC " $@; am__v_CC_1 = CCLD = $(CC) LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(AM_LDFLAGS) $(LDFLAGS) -o $@ AM_V_CCLD = $(am__v_CCLD_@AM_V@) am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) am__v_CCLD_0 = @echo " CCLD " $@; am__v_CCLD_1 = SOURCES = $(libcmis_c_@LIBCMIS_API_VERSION@_la_SOURCES) DIST_SOURCES = $(libcmis_c_@LIBCMIS_API_VERSION@_la_SOURCES) am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ BOOST_CPPFLAGS = @BOOST_CPPFLAGS@ BOOST_DATE_TIME_LDFLAGS = @BOOST_DATE_TIME_LDFLAGS@ BOOST_DATE_TIME_LDPATH = @BOOST_DATE_TIME_LDPATH@ BOOST_DATE_TIME_LIBS = @BOOST_DATE_TIME_LIBS@ BOOST_LDPATH = @BOOST_LDPATH@ BOOST_PROGRAM_OPTIONS_LDFLAGS = @BOOST_PROGRAM_OPTIONS_LDFLAGS@ BOOST_PROGRAM_OPTIONS_LDPATH = @BOOST_PROGRAM_OPTIONS_LDPATH@ BOOST_PROGRAM_OPTIONS_LIBS = @BOOST_PROGRAM_OPTIONS_LIBS@ BOOST_ROOT = @BOOST_ROOT@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPCHECK = @CPPCHECK@ CPPCHECK_PARALLELISM = @CPPCHECK_PARALLELISM@ CPPFLAGS = @CPPFLAGS@ CPPUNIT_CFLAGS = @CPPUNIT_CFLAGS@ CPPUNIT_LIBS = @CPPUNIT_LIBS@ CURL_CFLAGS = @CURL_CFLAGS@ CURL_LIBS = @CURL_LIBS@ CXX = @CXX@ CXXCPP = @CXXCPP@ CXXDEPMODE = @CXXDEPMODE@ CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DISTCHECK_CONFIGURE_FLAGS = @DISTCHECK_CONFIGURE_FLAGS@ DLLTOOL = @DLLTOOL@ DOCBOOK2MAN = @DOCBOOK2MAN@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ GENHTML = @GENHTML@ GREP = @GREP@ HAVE_CXX11 = @HAVE_CXX11@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LCOV = @LCOV@ LD = @LD@ LDFLAGS = @LDFLAGS@ LIBCMIS_API_VERSION = @LIBCMIS_API_VERSION@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ NPROC = @NPROC@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SRCDIR = @SRCDIR@ STRIP = @STRIP@ VERSION = @VERSION@ XML2_CFLAGS = @XML2_CFLAGS@ XML2_LIBS = @XML2_LIBS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS = -I$(top_srcdir)/inc \ -I$(top_srcdir)/inc/libcmis-c $(XML2_CFLAGS) $(BOOST_CPPFLAGS) \ $(am__append_1) libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS = -DLIBCMIS_C_BUILD \ $(am__append_2) lib_LTLIBRARIES = libcmis-c-@LIBCMIS_API_VERSION@.la libcmis_c_@LIBCMIS_API_VERSION@_la_SOURCES = \ allowable-actions.cxx \ document.cxx \ error.cxx \ folder.cxx \ internals.hxx \ oauth2-data.cxx \ object-type.cxx \ object.cxx \ property-type.cxx \ property.cxx \ rendition.cxx \ repository.cxx \ session-factory.cxx \ session.cxx \ vectors.cxx libcmis_c_@LIBCMIS_API_VERSION@_la_LDFLAGS = -export-dynamic -no-undefined -version-info 5:0:0 libcmis_c_@LIBCMIS_API_VERSION@_la_LIBADD = \ ../libcmis/libcmis-@LIBCMIS_API_VERSION@.la \ $(XML2_LIBS) \ $(CURL_LIBS) \ $(BOOST_SMART_PTR_LIBS) \ $(BOOST_DATE_TIME_LIBS) all: all-am .SUFFIXES: .SUFFIXES: .cxx .lo .o .obj $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign src/libcmis-c/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign src/libcmis-c/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): install-libLTLIBRARIES: $(lib_LTLIBRARIES) @$(NORMAL_INSTALL) @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ list2=; for p in $$list; do \ if test -f $$p; then \ list2="$$list2 $$p"; \ else :; fi; \ done; \ test -z "$$list2" || { \ echo " $(MKDIR_P) '$(DESTDIR)$(libdir)'"; \ $(MKDIR_P) "$(DESTDIR)$(libdir)" || exit 1; \ echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(libdir)'"; \ $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(libdir)"; \ } uninstall-libLTLIBRARIES: @$(NORMAL_UNINSTALL) @list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \ for p in $$list; do \ $(am__strip_dir) \ echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$f'"; \ $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$f"; \ done clean-libLTLIBRARIES: -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES) @list='$(lib_LTLIBRARIES)'; \ locs=`for p in $$list; do echo $$p; done | \ sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ sort -u`; \ test -z "$$locs" || { \ echo rm -f $${locs}; \ rm -f $${locs}; \ } libcmis-c-@LIBCMIS_API_VERSION@.la: $(libcmis_c_@LIBCMIS_API_VERSION@_la_OBJECTS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_DEPENDENCIES) $(EXTRA_libcmis_c_@LIBCMIS_API_VERSION@_la_DEPENDENCIES) $(AM_V_CXXLD)$(libcmis_c_@LIBCMIS_API_VERSION@_la_LINK) -rpath $(libdir) $(libcmis_c_@LIBCMIS_API_VERSION@_la_OBJECTS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_LIBADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-allowable-actions.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-document.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-error.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-folder.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-oauth2-data.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-object-type.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-object.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-property-type.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-property.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-rendition.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-repository.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-session-factory.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-session.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-vectors.Plo@am__quote@ # am--include-marker $(am__depfiles_remade): @$(MKDIR_P) $(@D) @echo '# dummy' >$@-t && $(am__mv) $@-t $@ am--depfiles: $(am__depfiles_remade) .cxx.o: @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $< .cxx.obj: @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .cxx.lo: @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LTCXXCOMPILE) -c -o $@ $< libcmis_c_@LIBCMIS_API_VERSION@_la-allowable-actions.lo: allowable-actions.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -MT libcmis_c_@LIBCMIS_API_VERSION@_la-allowable-actions.lo -MD -MP -MF $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-allowable-actions.Tpo -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-allowable-actions.lo `test -f 'allowable-actions.cxx' || echo '$(srcdir)/'`allowable-actions.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-allowable-actions.Tpo $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-allowable-actions.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='allowable-actions.cxx' object='libcmis_c_@LIBCMIS_API_VERSION@_la-allowable-actions.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-allowable-actions.lo `test -f 'allowable-actions.cxx' || echo '$(srcdir)/'`allowable-actions.cxx libcmis_c_@LIBCMIS_API_VERSION@_la-document.lo: document.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -MT libcmis_c_@LIBCMIS_API_VERSION@_la-document.lo -MD -MP -MF $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-document.Tpo -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-document.lo `test -f 'document.cxx' || echo '$(srcdir)/'`document.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-document.Tpo $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-document.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='document.cxx' object='libcmis_c_@LIBCMIS_API_VERSION@_la-document.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-document.lo `test -f 'document.cxx' || echo '$(srcdir)/'`document.cxx libcmis_c_@LIBCMIS_API_VERSION@_la-error.lo: error.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -MT libcmis_c_@LIBCMIS_API_VERSION@_la-error.lo -MD -MP -MF $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-error.Tpo -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-error.lo `test -f 'error.cxx' || echo '$(srcdir)/'`error.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-error.Tpo $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-error.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='error.cxx' object='libcmis_c_@LIBCMIS_API_VERSION@_la-error.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-error.lo `test -f 'error.cxx' || echo '$(srcdir)/'`error.cxx libcmis_c_@LIBCMIS_API_VERSION@_la-folder.lo: folder.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -MT libcmis_c_@LIBCMIS_API_VERSION@_la-folder.lo -MD -MP -MF $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-folder.Tpo -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-folder.lo `test -f 'folder.cxx' || echo '$(srcdir)/'`folder.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-folder.Tpo $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-folder.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='folder.cxx' object='libcmis_c_@LIBCMIS_API_VERSION@_la-folder.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-folder.lo `test -f 'folder.cxx' || echo '$(srcdir)/'`folder.cxx libcmis_c_@LIBCMIS_API_VERSION@_la-oauth2-data.lo: oauth2-data.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -MT libcmis_c_@LIBCMIS_API_VERSION@_la-oauth2-data.lo -MD -MP -MF $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-oauth2-data.Tpo -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-oauth2-data.lo `test -f 'oauth2-data.cxx' || echo '$(srcdir)/'`oauth2-data.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-oauth2-data.Tpo $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-oauth2-data.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='oauth2-data.cxx' object='libcmis_c_@LIBCMIS_API_VERSION@_la-oauth2-data.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-oauth2-data.lo `test -f 'oauth2-data.cxx' || echo '$(srcdir)/'`oauth2-data.cxx libcmis_c_@LIBCMIS_API_VERSION@_la-object-type.lo: object-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -MT libcmis_c_@LIBCMIS_API_VERSION@_la-object-type.lo -MD -MP -MF $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-object-type.Tpo -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-object-type.lo `test -f 'object-type.cxx' || echo '$(srcdir)/'`object-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-object-type.Tpo $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-object-type.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='object-type.cxx' object='libcmis_c_@LIBCMIS_API_VERSION@_la-object-type.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-object-type.lo `test -f 'object-type.cxx' || echo '$(srcdir)/'`object-type.cxx libcmis_c_@LIBCMIS_API_VERSION@_la-object.lo: object.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -MT libcmis_c_@LIBCMIS_API_VERSION@_la-object.lo -MD -MP -MF $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-object.Tpo -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-object.lo `test -f 'object.cxx' || echo '$(srcdir)/'`object.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-object.Tpo $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-object.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='object.cxx' object='libcmis_c_@LIBCMIS_API_VERSION@_la-object.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-object.lo `test -f 'object.cxx' || echo '$(srcdir)/'`object.cxx libcmis_c_@LIBCMIS_API_VERSION@_la-property-type.lo: property-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -MT libcmis_c_@LIBCMIS_API_VERSION@_la-property-type.lo -MD -MP -MF $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-property-type.Tpo -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-property-type.lo `test -f 'property-type.cxx' || echo '$(srcdir)/'`property-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-property-type.Tpo $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-property-type.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='property-type.cxx' object='libcmis_c_@LIBCMIS_API_VERSION@_la-property-type.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-property-type.lo `test -f 'property-type.cxx' || echo '$(srcdir)/'`property-type.cxx libcmis_c_@LIBCMIS_API_VERSION@_la-property.lo: property.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -MT libcmis_c_@LIBCMIS_API_VERSION@_la-property.lo -MD -MP -MF $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-property.Tpo -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-property.lo `test -f 'property.cxx' || echo '$(srcdir)/'`property.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-property.Tpo $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-property.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='property.cxx' object='libcmis_c_@LIBCMIS_API_VERSION@_la-property.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-property.lo `test -f 'property.cxx' || echo '$(srcdir)/'`property.cxx libcmis_c_@LIBCMIS_API_VERSION@_la-rendition.lo: rendition.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -MT libcmis_c_@LIBCMIS_API_VERSION@_la-rendition.lo -MD -MP -MF $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-rendition.Tpo -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-rendition.lo `test -f 'rendition.cxx' || echo '$(srcdir)/'`rendition.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-rendition.Tpo $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-rendition.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='rendition.cxx' object='libcmis_c_@LIBCMIS_API_VERSION@_la-rendition.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-rendition.lo `test -f 'rendition.cxx' || echo '$(srcdir)/'`rendition.cxx libcmis_c_@LIBCMIS_API_VERSION@_la-repository.lo: repository.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -MT libcmis_c_@LIBCMIS_API_VERSION@_la-repository.lo -MD -MP -MF $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-repository.Tpo -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-repository.lo `test -f 'repository.cxx' || echo '$(srcdir)/'`repository.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-repository.Tpo $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-repository.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='repository.cxx' object='libcmis_c_@LIBCMIS_API_VERSION@_la-repository.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-repository.lo `test -f 'repository.cxx' || echo '$(srcdir)/'`repository.cxx libcmis_c_@LIBCMIS_API_VERSION@_la-session-factory.lo: session-factory.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -MT libcmis_c_@LIBCMIS_API_VERSION@_la-session-factory.lo -MD -MP -MF $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-session-factory.Tpo -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-session-factory.lo `test -f 'session-factory.cxx' || echo '$(srcdir)/'`session-factory.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-session-factory.Tpo $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-session-factory.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='session-factory.cxx' object='libcmis_c_@LIBCMIS_API_VERSION@_la-session-factory.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-session-factory.lo `test -f 'session-factory.cxx' || echo '$(srcdir)/'`session-factory.cxx libcmis_c_@LIBCMIS_API_VERSION@_la-session.lo: session.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -MT libcmis_c_@LIBCMIS_API_VERSION@_la-session.lo -MD -MP -MF $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-session.Tpo -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-session.lo `test -f 'session.cxx' || echo '$(srcdir)/'`session.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-session.Tpo $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-session.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='session.cxx' object='libcmis_c_@LIBCMIS_API_VERSION@_la-session.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-session.lo `test -f 'session.cxx' || echo '$(srcdir)/'`session.cxx libcmis_c_@LIBCMIS_API_VERSION@_la-vectors.lo: vectors.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -MT libcmis_c_@LIBCMIS_API_VERSION@_la-vectors.lo -MD -MP -MF $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-vectors.Tpo -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-vectors.lo `test -f 'vectors.cxx' || echo '$(srcdir)/'`vectors.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-vectors.Tpo $(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-vectors.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='vectors.cxx' object='libcmis_c_@LIBCMIS_API_VERSION@_la-vectors.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS) $(CPPFLAGS) $(libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS) $(CXXFLAGS) -c -o libcmis_c_@LIBCMIS_API_VERSION@_la-vectors.lo `test -f 'vectors.cxx' || echo '$(srcdir)/'`vectors.cxx mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs tags TAGS: ctags CTAGS: cscope cscopelist: distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(LTLIBRARIES) installdirs: for dir in "$(DESTDIR)$(libdir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \ mostlyclean-am distclean: distclean-am -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-allowable-actions.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-document.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-error.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-folder.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-oauth2-data.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-object-type.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-object.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-property-type.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-property.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-rendition.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-repository.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-session-factory.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-session.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-vectors.Plo -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic dvi: dvi-am dvi-am: html: html-am html-am: info: info-am info-am: install-data-am: install-dvi: install-dvi-am install-dvi-am: install-exec-am: install-libLTLIBRARIES install-html: install-html-am install-html-am: install-info: install-info-am install-info-am: install-man: install-pdf: install-pdf-am install-pdf-am: install-ps: install-ps-am install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-allowable-actions.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-document.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-error.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-folder.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-oauth2-data.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-object-type.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-object.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-property-type.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-property.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-rendition.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-repository.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-session-factory.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-session.Plo -rm -f ./$(DEPDIR)/libcmis_c_@LIBCMIS_API_VERSION@_la-vectors.Plo -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-libLTLIBRARIES .MAKE: install-am install-strip .PHONY: all all-am am--depfiles check check-am clean clean-generic \ clean-libLTLIBRARIES clean-libtool cscopelist-am ctags-am \ distclean distclean-compile distclean-generic \ distclean-libtool distdir dvi dvi-am html html-am info info-am \ install install-am install-data install-data-am install-dvi \ install-dvi-am install-exec install-exec-am install-html \ install-html-am install-info install-info-am \ install-libLTLIBRARIES install-man install-pdf install-pdf-am \ install-ps install-ps-am install-strip installcheck \ installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ tags-am uninstall uninstall-am uninstall-libLTLIBRARIES .PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: libcmis-0.5.2/src/libcmis-c/property-type.cxx0000664000175000017500000001253213407414352016111 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include "internals.hxx" void libcmis_vector_property_type_free( libcmis_vector_property_type* vector ) { delete vector; } size_t libcmis_vector_property_type_size( libcmis_vector_property_type* vector ) { size_t size = 0; if ( vector != NULL ) size = vector->handle.size( ); return size; } libcmis_PropertyTypePtr libcmis_vector_property_type_get( libcmis_vector_property_type* vector, size_t i ) { libcmis_PropertyTypePtr item = NULL; if ( vector != NULL && i < vector->handle.size( ) ) { libcmis::PropertyTypePtr type = vector->handle[i]; item = new ( std::nothrow ) libcmis_property_type( ); if ( item ) item->handle = type; } return item; } void libcmis_property_type_free( libcmis_PropertyTypePtr type ) { delete type; } char* libcmis_property_type_getId( libcmis_PropertyTypePtr type ) { if ( type != NULL && type->handle.get( ) != NULL ) return strdup( type->handle->getId( ).c_str( ) ); else return NULL; } char* libcmis_property_type_getLocalName( libcmis_PropertyTypePtr type ) { if ( type != NULL && type->handle.get( ) != NULL ) return strdup( type->handle->getLocalName( ).c_str( ) ); else return NULL; } char* libcmis_property_type_getLocalNamespace( libcmis_PropertyTypePtr type ) { if ( type != NULL && type->handle.get( ) != NULL ) return strdup( type->handle->getLocalNamespace( ).c_str( ) ); else return NULL; } char* libcmis_property_type_getDisplayName( libcmis_PropertyTypePtr type ) { if ( type != NULL && type->handle.get( ) != NULL ) return strdup( type->handle->getDisplayName( ).c_str( ) ); else return NULL; } char* libcmis_property_type_getQueryName( libcmis_PropertyTypePtr type ) { if ( type != NULL && type->handle.get( ) != NULL ) return strdup( type->handle->getQueryName( ).c_str( ) ); else return NULL; } libcmis_property_type_Type libcmis_property_type_getType( libcmis_PropertyTypePtr type ) { if ( type != NULL && type->handle.get( ) != NULL ) return libcmis_property_type_Type( type->handle->getType( ) ); else return libcmis_String; } char* libcmis_property_type_getXmlType( libcmis_PropertyTypePtr type ) { if ( type != NULL && type->handle.get( ) != NULL ) return strdup( type->handle->getXmlType( ).c_str( ) ); else return NULL; } bool libcmis_property_type_isMultiValued( libcmis_PropertyTypePtr type ) { bool value = false; if ( type != NULL && type->handle.get( ) != NULL ) value = type->handle->isMultiValued( ); return value; } bool libcmis_property_type_isUpdatable( libcmis_PropertyTypePtr type ) { bool value = false; if ( type != NULL && type->handle.get( ) != NULL ) value = type->handle->isUpdatable( ); return value; } bool libcmis_property_type_isInherited( libcmis_PropertyTypePtr type ) { bool value = false; if ( type != NULL && type->handle.get( ) != NULL ) value = type->handle->isInherited( ); return value; } bool libcmis_property_type_isRequired( libcmis_PropertyTypePtr type ) { bool value = false; if ( type != NULL && type->handle.get( ) != NULL ) value = type->handle->isRequired( ); return value; } bool libcmis_property_type_isQueryable( libcmis_PropertyTypePtr type ) { bool value = false; if ( type != NULL && type->handle.get( ) != NULL ) value = type->handle->isQueryable( ); return value; } bool libcmis_property_type_isOrderable( libcmis_PropertyTypePtr type ) { bool value = false; if ( type != NULL && type->handle.get( ) != NULL ) value = type->handle->isOrderable( ); return value; } bool libcmis_property_type_isOpenChoice( libcmis_PropertyTypePtr type ) { bool value = false; if ( type != NULL && type->handle.get( ) != NULL ) value = type->handle->isOpenChoice( ); return value; } void libcmis_property_type_update( libcmis_PropertyTypePtr propDef, libcmis_vector_object_type_Ptr types ) { if ( propDef != NULL && propDef->handle.get( ) != NULL && types != NULL ) { std::vector< libcmis::ObjectTypePtr > typesHandle = types->handle; propDef->handle->update( typesHandle ); } } libcmis-0.5.2/src/libcmis-c/folder.cxx0000664000175000017500000002576613407414352014536 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include "internals.hxx" using namespace std; using libcmis::PropertyPtrMap; using libcmis::FolderPtr; using boost::dynamic_pointer_cast; void libcmis_vector_folder_free( libcmis_vector_folder_Ptr vector ) { delete vector; } size_t libcmis_vector_folder_size( libcmis_vector_folder_Ptr vector ) { size_t size = 0; if ( vector != NULL ) size = vector->handle.size( ); return size; } libcmis_FolderPtr libcmis_vector_folder_get( libcmis_vector_folder_Ptr vector, size_t i ) { libcmis_FolderPtr item = NULL; if ( vector != NULL && i < vector->handle.size( ) ) { libcmis::FolderPtr handle = vector->handle[i]; item = new ( nothrow ) libcmis_folder( ); if ( item ) item->handle = handle; } return item; } bool libcmis_is_folder( libcmis_ObjectPtr object ) { bool isFolder = false; if ( object != NULL && object->handle.get( ) != NULL ) { libcmis::FolderPtr folder = boost::dynamic_pointer_cast< libcmis::Folder >( object->handle ); isFolder = folder.get( ) != NULL; } return isFolder; } libcmis_FolderPtr libcmis_folder_cast( libcmis_ObjectPtr object ) { libcmis_FolderPtr folder = NULL; if ( object != NULL && object->handle.get( ) != NULL ) { libcmis::FolderPtr handle = boost::dynamic_pointer_cast< libcmis::Folder >( object->handle ); if ( handle.get( ) != NULL ) { folder = new ( nothrow ) libcmis_folder( ); if ( folder ) folder->handle = handle; } } return folder; } void libcmis_folder_free( libcmis_FolderPtr folder ) { delete folder; } libcmis_FolderPtr libcmis_folder_getParent( libcmis_FolderPtr folder, libcmis_ErrorPtr error ) { libcmis_FolderPtr parent = NULL; if ( folder != NULL && folder->handle.get( ) != NULL ) { try { FolderPtr folderHandle = dynamic_pointer_cast< libcmis::Folder >( folder->handle ); if ( folder ) { libcmis::FolderPtr handle = folderHandle->getFolderParent( ); if ( handle.get( ) != NULL ) { parent = new libcmis_folder( ); parent->handle = handle; } } } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } } return parent; } libcmis_vector_object_Ptr libcmis_folder_getChildren( libcmis_FolderPtr folder, libcmis_ErrorPtr error ) { libcmis_vector_object_Ptr result = NULL; if ( folder != NULL && folder->handle.get( ) != NULL ) { try { libcmis::FolderPtr folderHandle = dynamic_pointer_cast< libcmis::Folder >( folder->handle ); if ( folder ) { std::vector< libcmis::ObjectPtr > handles = folderHandle->getChildren( ); result = new libcmis_vector_object( ); result->handle = handles; } } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } } return result; } char* libcmis_folder_getPath( libcmis_FolderPtr folder ) { char* path = NULL; if ( folder != NULL && folder->handle.get( ) != NULL ) { libcmis::FolderPtr folderHandle = dynamic_pointer_cast< libcmis::Folder >( folder->handle ); if ( folder ) path = strdup( folderHandle->getPath( ).c_str( ) ); } return path; } bool libcmis_folder_isRootFolder( libcmis_FolderPtr folder ) { bool isRoot = false; if ( folder != NULL && folder->handle.get( ) != NULL ) { libcmis::FolderPtr folderHandle = dynamic_pointer_cast< libcmis::Folder >( folder->handle ); if ( folder ) isRoot = folderHandle->isRootFolder( ); } return isRoot; } libcmis_FolderPtr libcmis_folder_createFolder( libcmis_FolderPtr folder, libcmis_vector_property_Ptr properties, libcmis_ErrorPtr error ) { libcmis_FolderPtr result = NULL; if ( folder != NULL && folder->handle.get( ) != NULL ) { libcmis::FolderPtr folderHandle = dynamic_pointer_cast< libcmis::Folder >( folder->handle ); if ( folder ) { try { PropertyPtrMap mappedProperties; if ( properties != NULL ) { size_t size = properties->handle.size( ); for ( size_t i = 0; i < size; ++i ) { libcmis::PropertyPtr property = properties->handle[i]; if ( property.get( ) != NULL ) { string id = property->getPropertyType( )->getId( ); mappedProperties.insert( pair< string, libcmis::PropertyPtr >( id, property ) ); } } } libcmis::FolderPtr handle = folderHandle->createFolder( mappedProperties ); result = new libcmis_folder( ); result->handle = handle; } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } } } return result; } libcmis_DocumentPtr libcmis_folder_createDocument( libcmis_FolderPtr folder, libcmis_vector_property_Ptr properties, libcmis_readFn readFn, void* userData, const char* contentType, const char* filename, libcmis_ErrorPtr error ) { libcmis_DocumentPtr created = NULL; if ( folder != NULL && folder->handle.get( ) != NULL ) { libcmis::FolderPtr folderHandle = dynamic_pointer_cast< libcmis::Folder >( folder->handle ); if ( folder ) { try { // Create the ostream boost::shared_ptr< std::ostream > stream( new stringstream( ) ); size_t bufSize = 2048; char* buf = new char[ bufSize ]; size_t read = 0; do { read = readFn( ( void * )buf, size_t( 1 ), bufSize, userData ); stream->write( buf, read ); } while ( read == bufSize ); delete[] buf; // Create the property map PropertyPtrMap propertiesMap; if ( properties != NULL ) { for ( vector< libcmis::PropertyPtr >::iterator it = properties->handle.begin( ); it != properties->handle.end( ); ++it ) { string id = ( *it )->getPropertyType( )->getId( ); propertiesMap.insert( pair< string, libcmis::PropertyPtr >( id, *it ) ); } } libcmis::DocumentPtr handle = folderHandle->createDocument( propertiesMap, stream, contentType, filename ); created = new libcmis_document( ); created->handle = handle; } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } catch ( const exception& e ) { if ( error != NULL ) error->message = strdup( e.what() ); } } } return created; } libcmis_vector_string_Ptr libcmis_folder_removeTree( libcmis_FolderPtr folder, bool allVersion, libcmis_folder_UnfileObjects unfile, bool continueOnError, libcmis_ErrorPtr error ) { libcmis_vector_string_Ptr failed = NULL; try { failed = new libcmis_vector_string( ); if ( folder != NULL && folder->handle.get( ) != NULL ) { libcmis::FolderPtr folderHandle = dynamic_pointer_cast< libcmis::Folder >( folder->handle ); if ( folder ) { vector< string > handle = folderHandle->removeTree( allVersion, libcmis::UnfileObjects::Type( unfile ), continueOnError ); failed->handle = handle; } } } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } return failed; } libcmis-0.5.2/src/libcmis-c/allowable-actions.cxx0000664000175000017500000000356613407414352016655 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include "internals.hxx" void libcmis_allowable_actions_free( libcmis_AllowableActionsPtr allowable ) { delete allowable; } bool libcmis_allowable_actions_isAllowed( libcmis_AllowableActionsPtr allowable, libcmis_allowable_actions_Type action ) { bool result = false; if ( allowable != NULL && allowable->handle.get( ) != NULL ) result = allowable->handle->isAllowed( libcmis::ObjectAction::Type( action ) ); return result; } bool libcmis_allowable_actions_isDefined( libcmis_AllowableActionsPtr allowable, libcmis_allowable_actions_Type action ) { bool result = false; if ( allowable != NULL && allowable->handle.get( ) != NULL ) result = allowable->handle->isDefined( libcmis::ObjectAction::Type( action ) ); return result; } libcmis-0.5.2/src/libcmis-c/property.cxx0000664000175000017500000001321313407414352015127 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include "internals.hxx" using namespace std; libcmis_vector_property_Ptr libcmis_vector_property_create( ) { return new ( nothrow ) libcmis_vector_property( ); } void libcmis_vector_property_free( libcmis_vector_property_Ptr vector ) { delete vector; } size_t libcmis_vector_property_size( libcmis_vector_property_Ptr vector ) { size_t size = 0; if ( vector != NULL ) size = vector->handle.size( ); return size; } libcmis_PropertyPtr libcmis_vector_property_get( libcmis_vector_property_Ptr vector, size_t i ) { libcmis_PropertyPtr item = NULL; if ( vector != NULL && i < vector->handle.size( ) ) { libcmis::PropertyPtr type = vector->handle[i]; item = new ( nothrow ) libcmis_property( ); if ( item ) item->handle = type; } return item; } void libcmis_vector_property_append( libcmis_vector_property_Ptr vector, libcmis_PropertyPtr item ) { if ( vector != NULL && item != NULL && item->handle.get( ) != NULL ) { vector->handle.push_back( item->handle ); } } libcmis_PropertyPtr libcmis_property_create( libcmis_PropertyTypePtr type, const char** strValues, size_t size ) { libcmis_PropertyPtr property = NULL; if ( type != NULL && type->handle.get( ) != NULL ) { property = new ( nothrow ) libcmis_property( ); if ( property ) { vector< string > values; for ( size_t i = 0; i < size; ++i ) values.push_back( string( strValues[i] ) ); libcmis::PropertyPtr prop( new ( nothrow ) libcmis::Property( type->handle, values ) ); property->handle = prop; } } return property; } void libcmis_property_free( libcmis_PropertyPtr property ) { delete property; } libcmis_PropertyTypePtr libcmis_property_getPropertyType( libcmis_PropertyPtr property ) { libcmis_PropertyTypePtr type = NULL; if ( property != NULL && property->handle.get( ) != NULL ) { libcmis::PropertyTypePtr handle = property->handle->getPropertyType( ); type = new ( nothrow ) libcmis_property_type( ); if ( type ) type->handle = handle; } return type; } libcmis_vector_time_Ptr libcmis_property_getDateTimes( libcmis_PropertyPtr property ) { libcmis_vector_time_Ptr times = NULL; if ( property != NULL && property->handle.get( ) != NULL ) { vector< boost::posix_time::ptime > handles = property->handle->getDateTimes( ); times = new ( nothrow ) libcmis_vector_time( ); if ( times ) times->handle = handles; } return times; } libcmis_vector_bool_Ptr libcmis_property_getBools( libcmis_PropertyPtr property ) { libcmis_vector_bool_Ptr values = NULL; if ( property != NULL && property->handle.get( ) != NULL ) { vector< bool > handles = property->handle->getBools( ); values = new ( nothrow ) libcmis_vector_bool( ); if ( values ) values->handle = handles; } return values; } libcmis_vector_string_Ptr libcmis_property_getStrings( libcmis_PropertyPtr property ) { libcmis_vector_string_Ptr values = NULL; if ( property != NULL && property->handle.get( ) != NULL ) { vector< string > handles = property->handle->getStrings( ); values = new ( nothrow ) libcmis_vector_string( ); if ( values ) values->handle = handles; } return values; } libcmis_vector_long_Ptr libcmis_property_getLongs( libcmis_PropertyPtr property ) { libcmis_vector_long_Ptr values = NULL; if ( property != NULL && property->handle.get( ) != NULL ) { vector< long > handles = property->handle->getLongs( ); values = new ( nothrow ) libcmis_vector_long( ); if ( values ) values->handle = handles; } return values; } libcmis_vector_double_Ptr libcmis_property_getDoubles( libcmis_PropertyPtr property ) { libcmis_vector_double_Ptr values = NULL; if ( property != NULL && property->handle.get( ) != NULL ) { vector< double > handles = property->handle->getDoubles( ); values = new ( nothrow ) libcmis_vector_double( ); if ( values ) values->handle = handles; } return values; } void libcmis_property_setValues( libcmis_PropertyPtr property, const char** strValues, size_t size ) { if ( property != NULL && property->handle.get() != NULL ) { vector< string > values; for ( size_t i = 0; i < size; ++i ) values.push_back( string( strValues[i] ) ); property->handle->setValues( values ); } } libcmis-0.5.2/src/libcmis-c/oauth2-data.cxx0000664000175000017500000000607413407414352015363 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include "internals.hxx" using namespace std; libcmis_OAuth2DataPtr libcmis_oauth2data_create( char* authUrl, char* tokenUrl, char* scope, char* redirectUri, char* clientId, char* clientSecret ) { libcmis_OAuth2DataPtr data = new( nothrow ) libcmis_oauth2data( ); if ( NULL != data ) data->handle.reset( new libcmis::OAuth2Data( authUrl, tokenUrl, scope, redirectUri, clientId, clientSecret ) ); return data; } void libcmis_oauth2data_free( libcmis_OAuth2DataPtr oauth2 ) { delete oauth2; } bool libcmis_oauth2data_isComplete( libcmis_OAuth2DataPtr oauth2 ) { bool result = false; if ( oauth2 != NULL && oauth2->handle != NULL ) result = oauth2->handle->isComplete(); return result; } const char* libcmis_oauth2data_getAuthUrl( libcmis_OAuth2DataPtr oauth2 ) { if ( oauth2 != NULL && oauth2->handle != NULL ) return oauth2->handle->getAuthUrl().c_str(); return NULL; } const char* libcmis_oauth2data_getTokenUrl( libcmis_OAuth2DataPtr oauth2 ) { if ( oauth2 != NULL && oauth2->handle != NULL ) return oauth2->handle->getTokenUrl().c_str(); return NULL; } const char* libcmis_oauth2data_getClientId( libcmis_OAuth2DataPtr oauth2 ) { if ( oauth2 != NULL && oauth2->handle != NULL ) return oauth2->handle->getClientId().c_str(); return NULL; } const char* libcmis_oauth2data_getClientSecret( libcmis_OAuth2DataPtr oauth2 ) { if ( oauth2 != NULL && oauth2->handle != NULL ) return oauth2->handle->getClientSecret().c_str(); return NULL; } const char* libcmis_oauth2data_getScope( libcmis_OAuth2DataPtr oauth2 ) { if ( oauth2 != NULL && oauth2->handle != NULL ) return oauth2->handle->getScope().c_str(); return NULL; } const char* libcmis_oauth2data_getRedirectUri( libcmis_OAuth2DataPtr oauth2 ) { if ( oauth2 != NULL && oauth2->handle != NULL ) return oauth2->handle->getRedirectUri().c_str(); return NULL; } libcmis-0.5.2/src/libcmis-c/session.cxx0000664000175000017500000002021713407414352014730 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include #include "internals.hxx" using namespace std; void libcmis_session_free( libcmis_SessionPtr session ) { if ( session != NULL ) { delete session->handle; delete session; } } libcmis_RepositoryPtr libcmis_session_getRepository( libcmis_SessionPtr session, libcmis_ErrorPtr error ) { libcmis_RepositoryPtr repository = NULL; if ( session != NULL && session->handle != NULL ) { try { libcmis::RepositoryPtr handle = session->handle->getRepository( ); if ( handle ) { repository = new ( nothrow ) libcmis_repository( ); if ( repository ) repository->handle = handle; } } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } } return repository; } libcmis_vector_Repository_Ptr libcmis_session_getRepositories( libcmis_SessionPtr session ) { libcmis_vector_Repository_Ptr result = NULL; if ( session != NULL && session->handle != NULL ) { vector< libcmis::RepositoryPtr > handles = session->handle->getRepositories(); result = new ( nothrow ) libcmis_vector_repository( ); if ( result ) result->handle = handles; } return result; } bool libcmis_session_setRepository( libcmis_SessionPtr session, const char* id ) { bool success = false; if ( session && session->handle && id ) { success = session->handle->setRepository( id ); } return success; } libcmis_FolderPtr libcmis_session_getRootFolder( libcmis_SessionPtr session, libcmis_ErrorPtr error ) { libcmis_FolderPtr folder = NULL; if ( session != NULL && session->handle != NULL ) { try { libcmis::FolderPtr handle = session->handle->getRootFolder( ); folder = new libcmis_folder( ); folder->handle = handle; } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } } return folder; } libcmis_ObjectPtr libcmis_session_getObject( libcmis_SessionPtr session, const char* id, libcmis_ErrorPtr error ) { libcmis_ObjectPtr object = NULL; if ( session != NULL && session->handle != NULL ) { try { libcmis::ObjectPtr handle = session->handle->getObject( string( id ) ); object = new libcmis_object( ); object->handle = handle; } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } } return object; } libcmis_ObjectPtr libcmis_session_getObjectByPath( libcmis_SessionPtr session, const char* path, libcmis_ErrorPtr error ) { libcmis_ObjectPtr object = NULL; if ( session != NULL && session->handle != NULL ) { try { libcmis::ObjectPtr handle = session->handle->getObjectByPath( string( path ) ); object = new libcmis_object( ); object->handle = handle; } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } } return object; } libcmis_FolderPtr libcmis_session_getFolder( libcmis_SessionPtr session, const char* id, libcmis_ErrorPtr error ) { libcmis_FolderPtr folder = NULL; if ( session != NULL && session->handle != NULL ) { try { libcmis::FolderPtr handle = session->handle->getFolder( string( id ) ); folder = new libcmis_folder( ); folder->handle = handle; } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } } return folder; } libcmis_ObjectTypePtr libcmis_session_getType( libcmis_SessionPtr session, const char* id, libcmis_ErrorPtr error ) { libcmis_ObjectTypePtr type = NULL; if ( session != NULL && session->handle != NULL ) { try { libcmis::ObjectTypePtr handle = session->handle->getType( string( id ) ); type = new libcmis_object_type( ); type->handle = handle; } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } } return type; } libcmis_vector_object_type_Ptr libcmis_session_getBaseTypes( libcmis_SessionPtr session, libcmis_ErrorPtr error ) { libcmis_vector_object_type_Ptr types = NULL; if ( session != NULL && session->handle != NULL ) { try { vector< libcmis::ObjectTypePtr > handles = session->handle->getBaseTypes( ); types = new libcmis_vector_object_type( ); types->handle = handles; } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } } return types; } libcmis-0.5.2/src/libcmis-c/session-factory.cxx0000664000175000017500000001605213407414352016377 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include #include #include #include #include #include #include "internals.hxx" using namespace std; namespace { size_t const CRED_MAX_LEN = 1024; class WrapperAuthProvider : public libcmis::AuthProvider { private: libcmis_authenticationCallback m_callback; public: WrapperAuthProvider( libcmis_authenticationCallback callback ) : m_callback( callback ) { } virtual ~WrapperAuthProvider( ) { }; virtual bool authenticationQuery( string& username, string& password ); }; bool WrapperAuthProvider::authenticationQuery( string& username, string& password ) { /* NOTE: As I understand this, the callback is responsible for * filling the correct username and password (possibly using * the passed values as defaults in some dialog or so). But then * there is no guarantee that the new username/password will * not be longer than the present one, in which case it will * not fit into the available space! For now, use a buffer size * big enough for practical purposes. * * It might be a better idea to change the callback's signature * to bool ( * )( char** username, char** password ) * and make it the callee's responsibility to reallocate the * strings if it needs to. */ char user[CRED_MAX_LEN]; strncpy(user, username.c_str( ), sizeof( user ) ); user[CRED_MAX_LEN - 1] = '\0'; char pass[CRED_MAX_LEN]; strncpy(pass, password.c_str( ), sizeof( pass ) ); pass[CRED_MAX_LEN - 1] = '\0'; bool result = m_callback( user, pass ); // Update the username and password with the input username = user; password = pass; return result; } class WrapperCertHandler : public libcmis::CertValidationHandler { private: libcmis_certValidationCallback m_callback; public: WrapperCertHandler( libcmis_certValidationCallback callback ) : m_callback( callback ) { } virtual ~WrapperCertHandler( ) { }; virtual bool validateCertificate( vector< string > certificatesChain ); }; bool WrapperCertHandler::validateCertificate( vector< string > certificatesChain ) { libcmis_vector_string_Ptr chain = new ( nothrow ) libcmis_vector_string( ); if ( chain ) chain->handle = certificatesChain; bool result = m_callback( chain ); libcmis_vector_string_free( chain ); return result; } } std::string createString( char* str ) { if ( str ) return string( str ); else return string( ); } void libcmis_setAuthenticationCallback( libcmis_authenticationCallback callback ) { libcmis::AuthProviderPtr provider( new ( nothrow ) WrapperAuthProvider( callback ) ); if ( provider ) libcmis::SessionFactory::setAuthenticationProvider( provider ); } void libcmis_setCertValidationCallback( libcmis_certValidationCallback callback ) { libcmis::CertValidationHandlerPtr handler( new ( nothrow )WrapperCertHandler( callback ) ); if ( handler ) libcmis::SessionFactory::setCertificateValidationHandler( handler ); } void libcmis_setOAuth2AuthCodeProvider( libcmis_oauth2AuthCodeProvider callback ) { libcmis::SessionFactory::setOAuth2AuthCodeProvider( callback ); } libcmis_oauth2AuthCodeProvider libcmis_getOAuth2AuthCodeProvider( ) { return libcmis::SessionFactory::getOAuth2AuthCodeProvider( ); } void libcmis_setProxySettings( char* proxy, char* noProxy, char* proxyUser, char* proxyPass ) { libcmis::SessionFactory::setProxySettings( string( proxy ), string( noProxy ), string( proxyUser ), string( proxyPass ) ); } const char* libcmis_getProxy( ) { return libcmis::SessionFactory::getProxy( ).c_str(); } const char* libcmis_getNoProxy( ) { return libcmis::SessionFactory::getNoProxy( ).c_str(); } const char* libcmis_getProxyUser( ) { return libcmis::SessionFactory::getProxyUser( ).c_str(); } const char* libcmis_getProxyPass( ) { return libcmis::SessionFactory::getProxyPass( ).c_str(); } libcmis_SessionPtr libcmis_createSession( char* bindingUrl, char* repositoryId, char* username, char* password, bool noSslCheck, libcmis_OAuth2DataPtr oauth2, bool verbose, libcmis_ErrorPtr error ) { libcmis_SessionPtr session = NULL; try { libcmis::OAuth2DataPtr oauth2Handle; if ( oauth2 != NULL ) oauth2Handle = oauth2->handle; libcmis::Session* handle = libcmis::SessionFactory::createSession( createString( bindingUrl ), createString( username ), createString( password ), createString( repositoryId ), noSslCheck, oauth2Handle, verbose ); session = new libcmis_session( ); session->handle = handle; } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } return session; } libcmis_vector_Repository_Ptr libcmis_getRepositories( char* bindingUrl, char* username, char* password, bool verbose, libcmis_ErrorPtr error ) { libcmis_SessionPtr session = libcmis_createSession( bindingUrl, NULL, username, password, false, NULL, verbose, error ); libcmis_vector_Repository_Ptr repositories = libcmis_session_getRepositories( session ); libcmis_session_free( session ); return repositories; } libcmis-0.5.2/src/libcmis-c/vectors.cxx0000664000175000017500000000702113407414352014730 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include "internals.hxx" void libcmis_vector_bool_free( libcmis_vector_bool_Ptr vector ) { delete vector; } size_t libcmis_vector_bool_size( libcmis_vector_bool_Ptr vector ) { size_t size = 0; if ( vector != NULL ) size = vector->handle.size( ); return size; } bool libcmis_vector_bool_get( libcmis_vector_bool_Ptr vector, size_t i ) { bool item = false; if ( vector != NULL && i < vector->handle.size( ) ) item = vector->handle[i]; return item; } void libcmis_vector_string_free( libcmis_vector_string_Ptr vector ) { delete vector; } size_t libcmis_vector_string_size( libcmis_vector_string_Ptr vector ) { size_t size = 0; if ( vector != NULL ) size = vector->handle.size( ); return size; } const char* libcmis_vector_string_get( libcmis_vector_string_Ptr vector, size_t i ) { const char* item = NULL; if ( vector != NULL && i < vector->handle.size( ) ) item = vector->handle[i].c_str( ); return item; } void libcmis_vector_long_free( libcmis_vector_long_Ptr vector ) { delete vector; } size_t libcmis_vector_long_size( libcmis_vector_long_Ptr vector ) { size_t size = 0; if ( vector != NULL ) size = vector->handle.size( ); return size; } long libcmis_vector_long_get( libcmis_vector_long_Ptr vector, size_t i ) { long item = 0; if ( vector != NULL && i < vector->handle.size( ) ) item = vector->handle[i]; return item; } void libcmis_vector_double_free( libcmis_vector_double_Ptr vector ) { delete vector; } size_t libcmis_vector_double_size( libcmis_vector_double_Ptr vector ) { size_t size = 0; if ( vector != NULL ) size = vector->handle.size( ); return size; } double libcmis_vector_double_get( libcmis_vector_double_Ptr vector, size_t i ) { double item = 0.0; if ( vector != NULL && i < vector->handle.size( ) ) item = vector->handle[i]; return item; } void libcmis_vector_time_free( libcmis_vector_time_Ptr vector ) { delete vector; } size_t libcmis_vector_time_size( libcmis_vector_time_Ptr vector ) { size_t size = 0; if ( vector != NULL ) size = vector->handle.size( ); return size; } time_t libcmis_vector_time_get( libcmis_vector_time_Ptr vector, size_t i ) { time_t item = 0; if ( vector != NULL && i < vector->handle.size( ) ) { tm time = boost::posix_time::to_tm( vector->handle[i] ); item = mktime( &time ); } return item; } libcmis-0.5.2/src/libcmis-c/repository.cxx0000664000175000017500000001346713407414352015475 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include "internals.hxx" using std::nothrow; void libcmis_vector_repository_free( libcmis_vector_Repository_Ptr vector ) { delete vector; } size_t libcmis_vector_repository_size( libcmis_vector_Repository_Ptr vector ) { size_t size = 0; if ( vector != NULL ) size = vector->handle.size( ); return size; } libcmis_RepositoryPtr libcmis_vector_repository_get( libcmis_vector_Repository_Ptr vector, size_t i ) { libcmis_RepositoryPtr item = NULL; if ( vector != NULL && i < vector->handle.size( ) ) { libcmis::RepositoryPtr type = vector->handle[i]; item = new ( nothrow ) libcmis_repository( ); if ( item ) item->handle = type; } return item; } libcmis_RepositoryPtr libcmis_repository_create( xmlNodePtr node ) { libcmis_RepositoryPtr repository = new ( nothrow ) libcmis_repository( ); if ( repository ) { libcmis::RepositoryPtr handle( new ( nothrow ) libcmis::Repository( node ) ); repository->handle = handle; } return repository; } void libcmis_repository_free( libcmis_RepositoryPtr repository ) { delete repository; } char* libcmis_repository_getId( libcmis_RepositoryPtr repository ) { if ( repository != NULL && repository->handle != NULL ) return strdup( repository->handle->getId( ).c_str( ) ); else return NULL; } char* libcmis_repository_getName( libcmis_RepositoryPtr repository ) { if ( repository != NULL && repository->handle != NULL ) return strdup( repository->handle->getName( ).c_str( ) ); else return NULL; } char* libcmis_repository_getDescription( libcmis_RepositoryPtr repository ) { if ( repository != NULL && repository->handle != NULL ) return strdup( repository->handle->getDescription( ).c_str( ) ); else return NULL; } char* libcmis_repository_getVendorName( libcmis_RepositoryPtr repository ) { if ( repository != NULL && repository->handle != NULL ) return strdup( repository->handle->getVendorName( ).c_str( ) ); else return NULL; } char* libcmis_repository_getProductName( libcmis_RepositoryPtr repository ) { if ( repository != NULL && repository->handle != NULL ) return strdup( repository->handle->getProductName( ).c_str( ) ); else return NULL; } char* libcmis_repository_getProductVersion( libcmis_RepositoryPtr repository ) { if ( repository != NULL && repository->handle != NULL ) return strdup( repository->handle->getProductVersion( ).c_str( ) ); else return NULL; } char* libcmis_repository_getRootId( libcmis_RepositoryPtr repository ) { if ( repository != NULL && repository->handle != NULL ) return strdup( repository->handle->getRootId( ).c_str( ) ); else return NULL; } char* libcmis_repository_getCmisVersionSupported( libcmis_RepositoryPtr repository ) { if ( repository != NULL && repository->handle != NULL ) return strdup( repository->handle->getCmisVersionSupported( ).c_str( ) ); else return NULL; } char* libcmis_repository_getThinClientUri( libcmis_RepositoryPtr repository ) { if ( repository != NULL && repository->handle != NULL && repository->handle->getThinClientUri( ).get( ) != NULL ) return strdup( repository->handle->getThinClientUri( )->c_str( ) ); else return NULL; } char* libcmis_repository_getPrincipalAnonymous( libcmis_RepositoryPtr repository ) { if ( repository != NULL && repository->handle != NULL && repository->handle->getPrincipalAnonymous( ).get( ) != NULL ) return strdup( repository->handle->getPrincipalAnonymous( )->c_str( ) ); else return NULL; } char* libcmis_repository_getPrincipalAnyone( libcmis_RepositoryPtr repository ) { if ( repository != NULL && repository->handle != NULL && repository->handle->getPrincipalAnyone( ).get( ) != NULL ) return strdup( repository->handle->getPrincipalAnyone( )->c_str( ) ); else return NULL; } char* libcmis_repository_getCapability( libcmis_RepositoryPtr repository, libcmis_repository_capability_Type capability ) { if ( repository != NULL && repository->handle != NULL ) { std::string value = repository->handle->getCapability( ( libcmis::Repository::Capability ) capability ); return strdup( value.c_str( ) ); } else return NULL; } bool libcmis_repository_getCapabilityAsBool( libcmis_RepositoryPtr repository, libcmis_repository_capability_Type capability ) { if ( repository != NULL && repository->handle != NULL ) { return repository->handle->getCapabilityAsBool( ( libcmis::Repository::Capability ) capability ); } else return false; } libcmis-0.5.2/src/libcmis-c/object.cxx0000664000175000017500000003402513407414352014515 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include #include "internals.hxx" using namespace std; using libcmis::PropertyPtrMap; using boost::dynamic_pointer_cast; namespace { string lcl_stdString( const char* str ) { string result; if ( str ) result = string( str ); return result; } PropertyPtrMap lcl_createPropertiesMap( libcmis_vector_property_Ptr properties ) { PropertyPtrMap propertiesMap; if ( properties ) { for ( vector< libcmis::PropertyPtr >::iterator it = properties->handle.begin( ); it != properties->handle.end( ); ++it ) { libcmis::PropertyPtr propHandle = *it; propertiesMap[ propHandle->getPropertyType()->getId( ) ] = propHandle; } } return propertiesMap; } } void libcmis_vector_object_free( libcmis_vector_object_Ptr vector ) { delete vector; } size_t libcmis_vector_object_size( libcmis_vector_object_Ptr vector ) { size_t size = 0; if ( vector != NULL ) size = vector->handle.size( ); return size; } libcmis_ObjectPtr libcmis_vector_object_get( libcmis_vector_object_Ptr vector, size_t i ) { libcmis_ObjectPtr item = NULL; if ( vector != NULL && i < vector->handle.size( ) ) { libcmis::ObjectPtr type = vector->handle[i]; item = new ( nothrow ) libcmis_object( ); if ( item ) item->handle = type; } return item; } void libcmis_object_free( libcmis_ObjectPtr object ) { delete object; } char* libcmis_object_getId( libcmis_ObjectPtr object ) { if ( object != NULL && object->handle != NULL ) return strdup( object->handle->getId( ).c_str( ) ); else return NULL; } char* libcmis_object_getName( libcmis_ObjectPtr object ) { if ( object != NULL && object->handle != NULL ) return strdup( object->handle->getName( ).c_str( ) ); else return NULL; } libcmis_vector_string_Ptr libcmis_object_getPaths( libcmis_ObjectPtr object ) { libcmis_vector_string_Ptr c_paths = NULL; if ( object != NULL && object->handle != NULL ) { std::vector< std::string > paths = object->handle->getPaths( ); c_paths = new ( nothrow ) libcmis_vector_string( ); if ( c_paths ) c_paths->handle = paths; } return c_paths; } char* libcmis_object_getBaseType( libcmis_ObjectPtr object ) { if ( object != NULL && object->handle != NULL ) return strdup( object->handle->getBaseType( ).c_str( ) ); else return NULL; } char* libcmis_object_getType( libcmis_ObjectPtr object ) { if ( object != NULL && object->handle != NULL ) return strdup( object->handle->getType( ).c_str( ) ); else return NULL; } char* libcmis_object_getCreatedBy( libcmis_ObjectPtr object ) { if ( object != NULL && object->handle != NULL ) return strdup( object->handle->getCreatedBy( ).c_str( ) ); else return NULL; } time_t libcmis_object_getCreationDate( libcmis_ObjectPtr object ) { if ( object != NULL && object->handle != NULL ) { tm time = boost::posix_time::to_tm( object->handle->getCreationDate( ) ); return mktime( &time ); } else return 0; } char* libcmis_object_getLastModifiedBy( libcmis_ObjectPtr object ) { if ( object != NULL && object->handle != NULL ) return strdup( object->handle->getLastModifiedBy( ).c_str( ) ); else return NULL; } time_t libcmis_object_getLastModificationDate( libcmis_ObjectPtr object ) { if ( object != NULL && object->handle != NULL ) { tm time = boost::posix_time::to_tm( object->handle->getLastModificationDate( ) ); return mktime( &time ); } else return 0; } char* libcmis_object_getChangeToken( libcmis_ObjectPtr object ) { if ( object != NULL && object->handle != NULL ) return strdup( object->handle->getChangeToken( ).c_str( ) ); else return NULL; } char* libcmis_object_getThumbnailUrl( libcmis_ObjectPtr object ) { if ( object != NULL && object->handle != NULL ) return strdup( object->handle->getThumbnailUrl( ).c_str( ) ); else return NULL; } libcmis_vector_rendition_Ptr libcmis_object_getRenditions( libcmis_ObjectPtr object, libcmis_ErrorPtr error ) { libcmis_vector_rendition_Ptr result = NULL; if ( object != NULL && object->handle.get( ) != NULL ) { try { std::vector< libcmis::RenditionPtr > handles = object->handle->getRenditions( ); result = new libcmis_vector_rendition( ); result->handle = handles; } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } } return result; } bool libcmis_object_isImmutable( libcmis_ObjectPtr object ) { if ( object != NULL && object->handle != NULL ) return object->handle->isImmutable( ); else return true; } libcmis_vector_string_Ptr libcmis_object_getSecondaryTypes( libcmis_ObjectPtr object ) { libcmis_vector_string_Ptr c_types = NULL; if ( object != NULL && object->handle != NULL ) { vector< string > types = object->handle->getSecondaryTypes( ); c_types = new ( nothrow ) libcmis_vector_string( ); if ( c_types ) c_types->handle = types; } return c_types; } libcmis_ObjectPtr libcmis_object_addSecondaryType( libcmis_ObjectPtr object, const char* id, libcmis_vector_property_Ptr properties, libcmis_ErrorPtr error ) { libcmis_ObjectPtr updated = NULL; if ( object != NULL && object->handle != NULL && properties != NULL ) { try { PropertyPtrMap propertiesMap = lcl_createPropertiesMap( properties ); libcmis::ObjectPtr result = object->handle->addSecondaryType( lcl_stdString( id ), propertiesMap ); updated = new libcmis_object( ); updated->handle = result; } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } } return updated; } libcmis_ObjectPtr libcmis_object_removeSecondaryType( libcmis_ObjectPtr object, const char* id, libcmis_ErrorPtr error ) { libcmis_ObjectPtr updated = NULL; if ( object != NULL && object->handle != NULL ) { try { libcmis::ObjectPtr result = object->handle->removeSecondaryType( lcl_stdString( id ) ); updated = new libcmis_object( ); updated->handle = result; } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } } return updated; } libcmis_vector_property_Ptr libcmis_object_getProperties( libcmis_ObjectPtr object ) { libcmis_vector_property_Ptr properties = NULL; if ( object != NULL && object->handle.get( ) != NULL ) { PropertyPtrMap& handles = object->handle->getProperties( ); properties = new ( nothrow ) libcmis_vector_property( ); if ( properties ) { int i = 0; for ( PropertyPtrMap::iterator it = handles.begin( ); it != handles.end( ); ++it, ++i ) { properties->handle.push_back( it->second ); } } } return properties; } libcmis_PropertyPtr libcmis_object_getProperty( libcmis_ObjectPtr object, const char* name ) { libcmis_PropertyPtr property = NULL; if ( object != NULL && object->handle.get( ) != NULL ) { PropertyPtrMap& handles = object->handle->getProperties( ); PropertyPtrMap::iterator it = handles.find( lcl_stdString( name ) ); if ( it != handles.end( ) ) { property = new ( nothrow ) libcmis_property( ); if ( property ) property->handle = it->second; } } return property; } libcmis_ObjectPtr libcmis_object_updateProperties( libcmis_ObjectPtr object, libcmis_vector_property_Ptr properties, libcmis_ErrorPtr error ) { libcmis_ObjectPtr result = NULL; if ( object != NULL && object->handle != NULL && properties != NULL ) { try { // Build the map of changed properties PropertyPtrMap propertiesMap = lcl_createPropertiesMap( properties ); libcmis::ObjectPtr handle = object->handle->updateProperties( propertiesMap ); result = new libcmis_object( ); result->handle = handle; } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } } return result; } libcmis_ObjectTypePtr libcmis_object_getTypeDescription( libcmis_ObjectPtr object ) { libcmis_ObjectTypePtr result = NULL; if ( object != NULL && object->handle.get( ) != NULL ) { result = new ( nothrow ) libcmis_object_type( ); if ( result ) result->handle = object->handle->getTypeDescription( ); } return result; } libcmis_AllowableActionsPtr libcmis_object_getAllowableActions( libcmis_ObjectPtr object ) { libcmis_AllowableActionsPtr result = NULL; if ( object != NULL && object->handle.get( ) != NULL ) { result = new ( nothrow ) libcmis_allowable_actions( ); if ( result ) result->handle = object->handle->getAllowableActions( ); } return result; } void libcmis_object_refresh( libcmis_ObjectPtr object, libcmis_ErrorPtr error ) { if ( object != NULL && object->handle != NULL ) { try { object->handle->refresh( ); } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } } } time_t libcmis_object_getRefreshTimestamp( libcmis_ObjectPtr object ) { if ( object != NULL && object->handle != NULL ) return object->handle->getRefreshTimestamp( ); else return 0; } void libcmis_object_remove( libcmis_ObjectPtr object, bool allVersions, libcmis_ErrorPtr error ) { if ( object != NULL && object->handle != NULL ) { try { object->handle->remove( allVersions ); } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } } } void libcmis_object_move( libcmis_ObjectPtr object, libcmis_FolderPtr source, libcmis_FolderPtr dest, libcmis_ErrorPtr error ) { if ( object != NULL && object->handle != NULL ) { try { libcmis::FolderPtr sourceHandle; if ( source != NULL ) sourceHandle = dynamic_pointer_cast< libcmis::Folder >( source->handle ); libcmis::FolderPtr destHandle; if ( dest != NULL ) destHandle = dynamic_pointer_cast< libcmis::Folder >( dest->handle ); object->handle->move( sourceHandle, destHandle ); } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } } } char* libcmis_object_toString( libcmis_ObjectPtr object ) { if ( object != NULL && object->handle != NULL ) return strdup( object->handle->toString( ).c_str( ) ); else return NULL; } libcmis-0.5.2/src/libcmis-c/Makefile.am0000664000175000017500000000175613407475721014573 00000000000000 libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/inc/libcmis-c \ $(XML2_CFLAGS) \ $(BOOST_CPPFLAGS) libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS = -DLIBCMIS_C_BUILD if ENABLE_VISIBILITY libcmis_c_@LIBCMIS_API_VERSION@_la_CXXFLAGS += -fvisibility=hidden libcmis_c_@LIBCMIS_API_VERSION@_la_CPPFLAGS += -DLIBCMIS_C_VISIBILITY endif lib_LTLIBRARIES = libcmis-c-@LIBCMIS_API_VERSION@.la libcmis_c_@LIBCMIS_API_VERSION@_la_SOURCES = \ allowable-actions.cxx \ document.cxx \ error.cxx \ folder.cxx \ internals.hxx \ oauth2-data.cxx \ object-type.cxx \ object.cxx \ property-type.cxx \ property.cxx \ rendition.cxx \ repository.cxx \ session-factory.cxx \ session.cxx \ vectors.cxx libcmis_c_@LIBCMIS_API_VERSION@_la_LDFLAGS = -export-dynamic -no-undefined -version-info 5:0:0 libcmis_c_@LIBCMIS_API_VERSION@_la_LIBADD = \ ../libcmis/libcmis-@LIBCMIS_API_VERSION@.la \ $(XML2_LIBS) \ $(CURL_LIBS) \ $(BOOST_SMART_PTR_LIBS) \ $(BOOST_DATE_TIME_LIBS) libcmis-0.5.2/src/libcmis-c/internals.hxx0000664000175000017500000001161213407173247015255 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_INTERNALS_H_ #define _LIBCMIS_INTERNALS_H_ #include #include #include #include #include #include #include #include #include #include std::string createString( char* str ); struct libcmis_error { char* message; char* type; bool badAlloc; libcmis_error( ) : message( NULL ), type( NULL ), badAlloc( false ) { } }; struct libcmis_session { libcmis::Session* handle; libcmis::AuthProviderPtr provider; // Constructors libcmis_session( ) : handle( NULL ), provider( ) { } libcmis_session( const libcmis_session& copy ) : handle( copy.handle ), provider( copy.provider ) { } libcmis_session& operator=( const libcmis_session& copy ) { if ( this != © ) { handle = copy.handle; provider = copy.provider; } return *this; } }; struct libcmis_repository { libcmis::RepositoryPtr handle; libcmis_repository( ) : handle( ) { } }; struct libcmis_object { libcmis::ObjectPtr handle; libcmis_object( ) : handle( ) { } virtual ~libcmis_object( ) { } }; struct libcmis_object_type { libcmis::ObjectTypePtr handle; libcmis_object_type( ) : handle( ) { } }; struct libcmis_allowable_actions { libcmis::AllowableActionsPtr handle; libcmis_allowable_actions( ) : handle ( ) { } }; struct libcmis_property_type { libcmis::PropertyTypePtr handle; libcmis_property_type( ) : handle( ) { } }; struct libcmis_property { libcmis::PropertyPtr handle; libcmis_property( ) : handle( ) { } }; struct libcmis_folder : public libcmis_object { libcmis_folder( ) : libcmis_object( ) { } }; struct libcmis_document : public libcmis_object { libcmis_document( ) : libcmis_object( ) { } }; struct libcmis_oauth2data { libcmis::OAuth2DataPtr handle; libcmis_oauth2data( ) : handle( ) { } }; struct libcmis_rendition { libcmis::RenditionPtr handle; libcmis_rendition( ) : handle( ) { } }; struct libcmis_vector_bool { std::vector< bool > handle; libcmis_vector_bool( ) : handle( ) { } }; struct libcmis_vector_string { std::vector< std::string > handle; libcmis_vector_string( ) : handle( ) { } }; struct libcmis_vector_long { std::vector< long > handle; libcmis_vector_long( ) : handle( ) { } }; struct libcmis_vector_double { std::vector< double > handle; libcmis_vector_double( ) : handle( ) { } }; struct libcmis_vector_time { std::vector< boost::posix_time::ptime > handle; libcmis_vector_time( ) : handle( ) { } }; struct libcmis_vector_object_type { std::vector< libcmis::ObjectTypePtr > handle; libcmis_vector_object_type( ) : handle( ) { } }; struct libcmis_vector_property_type { std::vector< libcmis::PropertyTypePtr > handle; libcmis_vector_property_type( ) : handle( ) { } }; struct libcmis_vector_property { std::vector< libcmis::PropertyPtr > handle; libcmis_vector_property( ) : handle( ) { } }; struct libcmis_vector_object { std::vector< libcmis::ObjectPtr > handle; libcmis_vector_object( ) : handle( ) { } }; struct libcmis_vector_folder { std::vector< libcmis::FolderPtr > handle; libcmis_vector_folder( ) : handle( ) { } }; struct libcmis_vector_document { std::vector< libcmis::DocumentPtr > handle; libcmis_vector_document( ) : handle( ) { } }; struct libcmis_vector_repository { std::vector< libcmis::RepositoryPtr > handle; libcmis_vector_repository( ) : handle( ) { } }; struct libcmis_vector_rendition { std::vector< libcmis::RenditionPtr > handle; libcmis_vector_rendition( ) : handle( ) { } }; #endif libcmis-0.5.2/src/libcmis-c/error.cxx0000664000175000017500000000355713407414352014406 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include #include #include "internals.hxx" using namespace std; libcmis_ErrorPtr libcmis_error_create( ) { libcmis_ErrorPtr error = new( nothrow ) libcmis_error( ); return error; } void libcmis_error_free( libcmis_ErrorPtr error ) { if ( error != NULL ) { free( error->message ); free( error->type ); delete error; } } const char* libcmis_error_getMessage( libcmis_ErrorPtr error ) { if ( error != NULL ) { if ( error->badAlloc ) return "Failed to allocate memory"; else return error->message; } else return ""; } const char* libcmis_error_getType( libcmis_ErrorPtr error ) { if ( error != NULL ) return error->type; else return NULL; } libcmis-0.5.2/src/libcmis-c/rendition.cxx0000664000175000017500000000641013407414352015237 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include "internals.hxx" using namespace std; void libcmis_rendition_free( libcmis_RenditionPtr rendition ) { delete rendition; } bool libcmis_rendition_isThumbnail( libcmis_RenditionPtr rendition ) { bool result = false; if ( rendition != NULL && rendition->handle != NULL ) result = rendition->handle->isThumbnail(); return result; } const char* libcmis_rendition_getStreamId( libcmis_RenditionPtr rendition ) { if ( rendition != NULL && rendition->handle != NULL ) return rendition->handle->getStreamId().c_str(); return NULL; } const char* libcmis_rendition_getMimeType( libcmis_RenditionPtr rendition ) { if ( rendition != NULL && rendition->handle != NULL ) return rendition->handle->getMimeType().c_str(); return NULL; } const char* libcmis_rendition_getKind( libcmis_RenditionPtr rendition ) { if ( rendition != NULL && rendition->handle != NULL ) return rendition->handle->getKind().c_str(); return NULL; } const char* libcmis_rendition_getUrl( libcmis_RenditionPtr rendition ) { if ( rendition != NULL && rendition->handle != NULL ) return rendition->handle->getUrl().c_str(); return NULL; } const char* libcmis_rendition_getTitle( libcmis_RenditionPtr rendition ) { if ( rendition != NULL && rendition->handle != NULL ) return rendition->handle->getTitle().c_str(); return NULL; } long libcmis_rendition_getLength( libcmis_RenditionPtr rendition ) { if ( rendition != NULL && rendition->handle != NULL ) return rendition->handle->getLength(); return -1; } long libcmis_rendition_getWidth( libcmis_RenditionPtr rendition ) { if ( rendition != NULL && rendition->handle != NULL ) return rendition->handle->getWidth(); return -1; } long libcmis_rendition_getHeight( libcmis_RenditionPtr rendition ) { if ( rendition != NULL && rendition->handle != NULL ) return rendition->handle->getHeight(); return -1; } const char* libcmis_rendition_getRenditionDocumentId( libcmis_RenditionPtr rendition ) { if ( rendition != NULL && rendition->handle != NULL ) return rendition->handle->getRenditionDocumentId().c_str(); return NULL; } libcmis-0.5.2/src/libcmis-c/object-type.cxx0000664000175000017500000002433313407414352015475 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include "internals.hxx" using namespace std; void libcmis_vector_object_type_free( libcmis_vector_object_type_Ptr vector ) { delete vector; } size_t libcmis_vector_object_type_size( libcmis_vector_object_type_Ptr vector ) { size_t size = 0; if ( vector != NULL ) size = vector->handle.size( ); return size; } libcmis_ObjectTypePtr libcmis_vector_object_type_get( libcmis_vector_object_type_Ptr vector, size_t i ) { libcmis_ObjectTypePtr item = NULL; if ( vector != NULL && i < vector->handle.size( ) ) { libcmis::ObjectTypePtr type = vector->handle[i]; item = new ( nothrow ) libcmis_object_type( ); if ( item ) item->handle = type; } return item; } void libcmis_object_type_free( libcmis_ObjectTypePtr type ) { delete type; } char* libcmis_object_type_getId( libcmis_ObjectTypePtr type ) { if ( type != NULL && type->handle.get( ) != NULL ) return strdup( type->handle->getId( ).c_str( ) ); else return NULL; } char* libcmis_object_type_getLocalName( libcmis_ObjectTypePtr type ) { if ( type != NULL && type->handle.get( ) != NULL ) return strdup( type->handle->getLocalName( ).c_str( ) ); else return NULL; } char* libcmis_object_type_getLocalNamespace( libcmis_ObjectTypePtr type ) { if ( type != NULL && type->handle.get( ) != NULL ) return strdup( type->handle->getLocalNamespace( ).c_str( ) ); else return NULL; } char* libcmis_object_type_getQueryName( libcmis_ObjectTypePtr type ) { if ( type != NULL && type->handle.get( ) != NULL ) return strdup( type->handle->getQueryName( ).c_str( ) ); else return NULL; } char* libcmis_object_type_getDisplayName( libcmis_ObjectTypePtr type ) { if ( type != NULL && type->handle.get( ) != NULL ) return strdup( type->handle->getDisplayName( ).c_str( ) ); else return NULL; } char* libcmis_object_type_getDescription( libcmis_ObjectTypePtr type ) { if ( type != NULL && type->handle.get( ) != NULL ) return strdup( type->handle->getDescription( ).c_str( ) ); else return NULL; } libcmis_ObjectTypePtr libcmis_object_type_getParentType( libcmis_ObjectTypePtr type, libcmis_ErrorPtr error ) { libcmis_ObjectTypePtr result = NULL; if ( type != NULL && type->handle.get( ) != NULL ) { try { libcmis::ObjectTypePtr handle = type->handle->getParentType( ); if ( handle.get ( ) ) { result = new libcmis_object_type( ); result->handle = handle; } } catch( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } } return result; } libcmis_ObjectTypePtr libcmis_object_type_getBaseType( libcmis_ObjectTypePtr type, libcmis_ErrorPtr error ) { libcmis_ObjectTypePtr result = NULL; if ( type != NULL && type->handle.get( ) != NULL ) { try { libcmis::ObjectTypePtr handle = type->handle->getBaseType( ); result = new libcmis_object_type( ); result->handle = handle; } catch( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } } return result; } char* libcmis_object_type_getParentTypeId( libcmis_ObjectTypePtr type ) { char* result = NULL; if ( type != NULL && type->handle.get( ) != NULL ) { result = strdup( type->handle->getParentTypeId( ).c_str() ); } return result; } char* libcmis_object_type_getBaseTypeId( libcmis_ObjectTypePtr type ) { char* result = NULL; if ( type != NULL && type->handle.get( ) != NULL ) { result = strdup( type->handle->getBaseTypeId( ).c_str() ); } return result; } libcmis_vector_object_type_Ptr libcmis_object_type_getChildren( libcmis_ObjectTypePtr type, libcmis_ErrorPtr error ) { libcmis_vector_object_type_Ptr children = NULL; if ( type != NULL && type->handle.get( ) != NULL ) { try { std::vector< libcmis::ObjectTypePtr > types = type->handle->getChildren( ); children = new libcmis_vector_object_type( ); children->handle = types; } catch( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } } return children; } bool libcmis_object_type_isCreatable( libcmis_ObjectTypePtr type ) { bool value = false; if ( type != NULL && type->handle.get( ) != NULL ) value = type->handle->isCreatable( ); return value; } bool libcmis_object_type_isFileable( libcmis_ObjectTypePtr type ) { bool value = false; if ( type != NULL && type->handle.get( ) != NULL ) value = type->handle->isFileable( ); return value; } bool libcmis_object_type_isQueryable( libcmis_ObjectTypePtr type ) { bool value = false; if ( type != NULL && type->handle.get( ) != NULL ) value = type->handle->isQueryable( ); return value; } bool libcmis_object_type_isFulltextIndexed( libcmis_ObjectTypePtr type ) { bool value = false; if ( type != NULL && type->handle.get( ) != NULL ) value = type->handle->isFulltextIndexed( ); return value; } bool libcmis_object_type_isIncludedInSupertypeQuery( libcmis_ObjectTypePtr type ) { bool value = false; if ( type != NULL && type->handle.get( ) != NULL ) value = type->handle->isIncludedInSupertypeQuery( ); return value; } bool libcmis_object_type_isControllablePolicy( libcmis_ObjectTypePtr type ) { bool value = false; if ( type != NULL && type->handle.get( ) != NULL ) value = type->handle->isControllablePolicy( ); return value; } bool libcmis_object_type_isControllableACL( libcmis_ObjectTypePtr type ) { bool value = false; if ( type != NULL && type->handle.get( ) != NULL ) value = type->handle->isControllableACL( ); return value; } bool libcmis_object_type_isVersionable( libcmis_ObjectTypePtr type ) { bool value = false; if ( type != NULL && type->handle.get( ) != NULL ) value = type->handle->isVersionable( ); return value; } libcmis_object_type_ContentStreamAllowed libcmis_object_type_getContentStreamAllowed( libcmis_ObjectTypePtr type ) { libcmis_object_type_ContentStreamAllowed result = libcmis_NotAllowed; if ( type != NULL && type->handle.get( ) != NULL ) { libcmis::ObjectType::ContentStreamAllowed value = type->handle->getContentStreamAllowed( ); result = libcmis_object_type_ContentStreamAllowed( value ); } return result; } libcmis_vector_property_type_Ptr libcmis_object_type_getPropertiesTypes( libcmis_ObjectTypePtr type ) { libcmis_vector_property_type_Ptr propertyTypes = NULL; if ( type != NULL && type->handle != NULL ) { map< string, libcmis::PropertyTypePtr >& handles = type->handle->getPropertiesTypes( ); propertyTypes = new ( nothrow ) libcmis_vector_property_type( ); if ( propertyTypes ) { int i = 0; for ( map< string, libcmis::PropertyTypePtr >::iterator it = handles.begin( ); it != handles.end( ); ++it, ++i ) { propertyTypes->handle.push_back( it->second ); } } } return propertyTypes; } libcmis_PropertyTypePtr libcmis_object_type_getPropertyType( libcmis_ObjectTypePtr type, const char* id ) { libcmis_PropertyTypePtr propertyType = NULL; if ( type != NULL && type->handle != NULL ) { map< string, libcmis::PropertyTypePtr >& handles = type->handle->getPropertiesTypes( ); map< string, libcmis::PropertyTypePtr >::iterator it = handles.find( string( id ) ); if ( it != handles.end( ) ) { propertyType = new ( nothrow ) libcmis_property_type( ); if ( propertyType ) propertyType->handle = it->second; } } return propertyType; } char* libcmis_object_type_toString( libcmis_ObjectTypePtr type ) { if ( type != NULL && type->handle.get( ) != NULL ) return strdup( type->handle->toString( ).c_str( ) ); else return NULL; } libcmis-0.5.2/src/libcmis-c/document.cxx0000664000175000017500000003146113407414352015066 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include "internals.hxx" using namespace std; using libcmis::DocumentPtr; using libcmis::FolderPtr; using libcmis::PropertyPtrMap; using boost::dynamic_pointer_cast; void libcmis_vector_document_free( libcmis_vector_document_Ptr vector ) { delete vector; } size_t libcmis_vector_document_size( libcmis_vector_document_Ptr vector ) { size_t size = 0; if ( vector != NULL ) size = vector->handle.size( ); return size; } libcmis_DocumentPtr libcmis_vector_document_get( libcmis_vector_document_Ptr vector, size_t i ) { libcmis_DocumentPtr item = NULL; if ( vector != NULL && i < vector->handle.size( ) ) { libcmis::DocumentPtr handle = vector->handle[i]; item = new( nothrow ) libcmis_document( ); item->handle = handle; } return item; } bool libcmis_is_document( libcmis_ObjectPtr object ) { bool isDocument = false; if ( object != NULL && object->handle.get( ) != NULL ) { DocumentPtr document = dynamic_pointer_cast< libcmis::Document >( object->handle ); isDocument = document.get( ) != NULL; } return isDocument; } libcmis_DocumentPtr libcmis_document_cast( libcmis_ObjectPtr object ) { libcmis_DocumentPtr document = NULL; if ( object != NULL && object->handle.get( ) != NULL && libcmis_is_document( object ) ) { document = new ( nothrow ) libcmis_document( ); document->handle = object->handle; } return document; } void libcmis_document_free( libcmis_DocumentPtr document ) { delete document; } libcmis_vector_folder_Ptr libcmis_document_getParents( libcmis_DocumentPtr document, libcmis_ErrorPtr error ) { libcmis_vector_folder_Ptr parents = NULL; if ( document != NULL && document->handle.get( ) != NULL ) { try { DocumentPtr doc = dynamic_pointer_cast< libcmis::Document >( document->handle ); if ( doc ) { vector< libcmis::FolderPtr > handles = doc->getParents( ); parents = new libcmis_vector_folder( ); parents->handle = handles; } } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } } return parents; } void libcmis_document_getContentStream( libcmis_DocumentPtr document, libcmis_writeFn writeFn, void* userData, libcmis_ErrorPtr error ) { if ( document != NULL && document->handle.get( ) != NULL ) { try { DocumentPtr doc = dynamic_pointer_cast< libcmis::Document >( document->handle ); if ( doc ) { boost::shared_ptr< istream > stream = doc->getContentStream( ); stream->seekg( 0 ); int bufSize = 2048; char* buf = new char[ bufSize ]; while ( !stream->eof( ) ) { stream->read( buf, bufSize ); size_t read = stream->gcount( ); writeFn( ( const void * )buf, size_t( 1 ), read, userData ); } delete[] buf; } } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } catch ( const exception& e ) { if ( error != NULL ) error->message = strdup( e.what() ); } catch ( ... ) { } } } void libcmis_document_setContentStream( libcmis_DocumentPtr document, libcmis_readFn readFn, void* userData, const char* contentType, const char* fileName, bool overwrite, libcmis_ErrorPtr error ) { if ( document != NULL && document->handle.get( ) != NULL ) { try { boost::shared_ptr< std::ostream > stream( new stringstream( ) ); size_t bufSize = 2048; char* buf = new char[ bufSize ]; size_t read = 0; do { read = readFn( ( void * )buf, size_t( 1 ), bufSize, userData ); stream->write( buf, read ); } while ( read == bufSize ); delete[] buf; DocumentPtr doc = dynamic_pointer_cast< libcmis::Document >( document->handle ); if ( doc ) doc->setContentStream( stream, contentType, fileName, overwrite ); } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } catch ( const exception& e ) { if ( error != NULL ) error->message = strdup( e.what() ); } } } char* libcmis_document_getContentType( libcmis_DocumentPtr document ) { char* value = NULL; if ( document != NULL && document->handle.get( ) != NULL ) { DocumentPtr doc = dynamic_pointer_cast< libcmis::Document >( document->handle ); if ( doc ) value = strdup( doc->getContentType( ).c_str( ) ); } return value; } char* libcmis_document_getContentFilename( libcmis_DocumentPtr document ) { char* value = NULL; if ( document != NULL && document->handle.get( ) != NULL ) { DocumentPtr doc = dynamic_pointer_cast< libcmis::Document >( document->handle ); if ( doc ) value = strdup( doc->getContentFilename( ).c_str( ) ); } return value; } long libcmis_document_getContentLength( libcmis_DocumentPtr document ) { long value = 0; if ( document != NULL && document->handle.get( ) != NULL ) { DocumentPtr doc = dynamic_pointer_cast< libcmis::Document >( document->handle ); if ( doc ) value = doc->getContentLength( ); } return value; } libcmis_DocumentPtr libcmis_document_checkOut( libcmis_DocumentPtr document, libcmis_ErrorPtr error ) { libcmis_DocumentPtr pwc = NULL; if ( document != NULL && document->handle.get( ) != NULL ) { try { DocumentPtr doc = dynamic_pointer_cast< libcmis::Document >( document->handle ); if ( doc ) { libcmis::DocumentPtr handle = doc->checkOut( ); pwc= new libcmis_document( ); pwc->handle = handle; } } catch ( const bad_alloc& e ) { if ( error != NULL ) error->badAlloc = true; } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } } return pwc; } void libcmis_document_cancelCheckout( libcmis_DocumentPtr document, libcmis_ErrorPtr error ) { if ( document != NULL && document->handle.get( ) != NULL ) { try { DocumentPtr doc = dynamic_pointer_cast< libcmis::Document >( document->handle ); if ( doc ) doc->cancelCheckout( ); } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } } } libcmis_DocumentPtr libcmis_document_checkIn( libcmis_DocumentPtr document, bool isMajor, const char* comment, libcmis_vector_property_Ptr properties, libcmis_readFn readFn, void* userData, const char* contentType, const char* filename, libcmis_ErrorPtr error ) { libcmis_DocumentPtr newVersion = NULL; if ( document != NULL && document->handle.get( ) != NULL ) { try { DocumentPtr doc = dynamic_pointer_cast< libcmis::Document >( document->handle ); if ( doc ) { // Create the ostream boost::shared_ptr< std::ostream > stream( new stringstream( ) ); size_t bufSize = 2048; char * buf = new char[ bufSize ]; size_t read = 0; do { read = readFn( ( void * )buf, size_t( 1 ), bufSize, userData ); stream->write( buf, read ); } while ( read == bufSize ); delete[] buf; // Create the property map PropertyPtrMap propertiesMap; if ( properties != NULL ) { for ( vector< libcmis::PropertyPtr >::iterator it = properties->handle.begin( ); it != properties->handle.end( ); ++it ) { string id = ( *it )->getPropertyType( )->getId( ); propertiesMap.insert( pair< string, libcmis::PropertyPtr >( id, *it ) ); } } libcmis::DocumentPtr handle = doc->checkIn( isMajor, comment, propertiesMap, stream, contentType, filename ); newVersion = new libcmis_document( ); newVersion->handle = handle; } } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } catch ( const exception& e ) { if ( error != NULL ) error->message = strdup( e.what() ); } } return newVersion; } libcmis_vector_document_Ptr libcmis_document_getAllVersions( libcmis_DocumentPtr document, libcmis_ErrorPtr error ) { libcmis_vector_document_Ptr result = NULL; if ( document != NULL && document->handle.get( ) != NULL ) { try { DocumentPtr doc = dynamic_pointer_cast< libcmis::Document >( document->handle ); if ( doc ) { std::vector< libcmis::DocumentPtr > handles = doc->getAllVersions( ); result = new libcmis_vector_document( ); result->handle = handles; } } catch ( const libcmis::Exception& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->type = strdup( e.getType().c_str() ); } } catch ( const bad_alloc& e ) { if ( error != NULL ) { error->message = strdup( e.what() ); error->badAlloc = true; } } } return result; } libcmis-0.5.2/src/Makefile.am0000664000175000017500000000056113407414352012713 00000000000000SUBDIRS = libcmis libcmis-c if ENABLE_CLIENT AM_CXXFLAGS = \ -I$(top_srcdir)/inc \ $(XML2_CFLAGS) \ $(BOOST_CPPFLAGS) bin_PROGRAMS = cmis-client cmis_client_SOURCES = cmis-client.cxx cmis_client_LDADD = $(top_builddir)/src/libcmis/libcmis-@LIBCMIS_API_VERSION@.la \ $(XML2_LIBS) \ $(BOOST_PROGRAM_OPTIONS_LIBS) \ $(BOOST_DATE_TIME_LIBS) \ $(JSON_LIBS) endif libcmis-0.5.2/src/cmis-client.cxx0000664000175000017500000013543313411147221013612 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include #include #include #include #include #include #include #include using namespace std; using namespace boost::program_options; using libcmis::PropertyPtrMap; namespace { char* lcl_queryAuthCode( const char* url, const char* /*username*/, const char* /*password*/ ) { string code; cout << "Copy the following link to your browser and take the code: " << endl << endl << url << endl << endl; cout << "Enter the code:" << endl; cin >> code; return strdup( code.c_str() ); } class AuthCodeProvider { private: static string m_authCode; public: static void setAuthCode( string authCode ); static char* getAuthCode( const char* /*url*/, const char* /*username*/, const char* /*password*/ ); }; string AuthCodeProvider::m_authCode = string( ); void AuthCodeProvider::setAuthCode( string authCode ) { m_authCode = authCode; } char* AuthCodeProvider::getAuthCode( const char* /*url*/, const char* /*username*/, const char* /*password*/ ) { return strdup( m_authCode.c_str( ) ); } class CinAuthProvider : public libcmis::AuthProvider { private: string m_user; string m_pass; public: CinAuthProvider( ) : m_user( ), m_pass( ) { } ~CinAuthProvider( ) { } virtual bool authenticationQuery( string& username, string& password ); }; bool CinAuthProvider::authenticationQuery( string& username, string& password ) { bool cancelled = false; bool askUsername = username.empty(); if ( askUsername ) { if ( m_user.empty() ) { cout << "Username (empty to cancel): "; getline( cin, m_user ); } cancelled = m_user.empty(); username = m_user; } if ( !cancelled && ( askUsername || password.empty( ) ) ) { if ( m_pass.empty() ) { cout << "Password (empty to cancel): "; getline( cin, m_pass ); } cancelled = m_pass.empty(); password = m_pass; } return !cancelled; } class CinCertValidationHandler : public libcmis::CertValidationHandler { private: map< string, bool > m_answers; public: CinCertValidationHandler( ) : m_answers( ) { } ~CinCertValidationHandler( ) { } virtual bool validateCertificate( vector< string > certificates ) { if ( certificates.empty( ) ) return false; // Should never happen // Show the first certificate (even base64-encoded) string cert = certificates.front(); map< string, bool >::iterator it = m_answers.find( cert ); if ( it != m_answers.end( ) ) return it->second; cout << "Invalid SSL certificate:" << endl << cert << endl; cout << "'openssl x509 -noout -text' can show you the details of this certificate." << endl << endl; // Ask whether to validate cout << "Do you want to ignore this problem and go on? yes/no [default: no]: "; string answer; getline( cin, answer ); m_answers[cert] = answer == "yes"; return answer == "yes"; } }; } class CommandException : public exception { private: string m_msg; public: CommandException( string msg ) : m_msg( msg ) { } ~CommandException( ) noexcept { } CommandException( const CommandException& copy ) : m_msg( copy.m_msg ) { } CommandException& operator=( const CommandException& copy ) { if ( this != © ) m_msg = copy.m_msg; return *this; } virtual const char* what() const noexcept { return m_msg.c_str(); } }; class CmisClient { private: variables_map& m_vm; public: CmisClient( variables_map& vm ) : m_vm( vm ) { } libcmis::Session* getSession( bool inGetRepositories = false ); void execute( ); void printHelp( ); static options_description getOptionsDescription( ); private: map< int, string > getSessionParams(); map< string, string > getObjectProperties( ); }; map< string, string > CmisClient::getObjectProperties( ) { map< string, string > result; if ( m_vm.count( "object-property" ) > 0 ) { vector< string > params = m_vm["object-property"].as< vector< string > >( ); for ( vector< string >::iterator it = params.begin( ); it != params.end( ); ++it ) { size_t pos = it->find( "=" ); if ( pos != string::npos ) { string name = it->substr( 0, pos ); string value = it->substr( pos + 1 ); result.insert( pair< string, string >( name, value ) ); } } } return result; } libcmis::Session* CmisClient::getSession( bool inGetRepositories ) { if ( m_vm.count( "url" ) == 0 ) throw CommandException( "Missing binding URL" ); // Setup the authentication provider in case we have missing credentials libcmis::AuthProviderPtr provider( new CinAuthProvider( ) ); libcmis::SessionFactory::setAuthenticationProvider( provider ); libcmis::CertValidationHandlerPtr certValidator( new CinCertValidationHandler( ) ); libcmis::SessionFactory::setCertificateValidationHandler( certValidator ); string url = m_vm["url"].as(); // Look for the credentials string username; string password; if ( m_vm.count( "username" ) > 0 ) { username = m_vm["username"].as< string >(); if ( m_vm.count( "password" ) > 0 ) password = m_vm["password"].as< string >(); } // Look for proxy settings string proxyUrl; string proxyUser; string proxyPass; string noproxy; if ( m_vm.count( "proxy" ) > 0 ) { proxyUrl = m_vm["proxy"].as< string >(); if ( m_vm.count( "proxy-user" ) > 0 ) proxyUser = m_vm["proxy-user"].as< string >(); if ( m_vm.count( "proxy-password" ) > 0 ) proxyPass = m_vm["proxy-password"].as< string >(); if ( m_vm.count( "noproxy" ) > 0 ) noproxy = m_vm["noproxy"].as< string >(); libcmis::SessionFactory::setProxySettings( proxyUrl, noproxy, proxyUser, proxyPass ); } bool verbose = m_vm.count( "verbose" ) > 0; libcmis::Session* session = NULL; string repoId; // The repository ID is needed to initiate a session if ( m_vm.count( "repository" ) == 0 && !inGetRepositories ) { // Do we have a single repository on the server? session = getSession( true ); if ( session != NULL ) { vector< libcmis::RepositoryPtr > repos = session->getRepositories(); if ( repos.size() == 1 ) { repoId = repos.front( )->getId( ); session->setRepository( repoId ); } } // We couldn't auto-guess the repository, then throw an error if ( repoId.empty( ) ) { delete session; throw CommandException( "Missing repository ID" ); } } else if ( m_vm.count( "repository" ) > 0 ) { repoId = m_vm["repository"].as< string >(); } if ( session == NULL ) { bool noSslCheck = m_vm.count( "no-ssl-check" ) > 0; // Should we use OAuth2? string oauth2ClientId; string oauth2ClientSecret; string oauth2AuthUrl; string oauth2TokenUrl; string oauth2RedirectUri; string oauth2Scope; if ( m_vm.count( "oauth2-client-id" ) > 0 ) oauth2ClientId = m_vm["oauth2-client-id"].as< string >(); if ( m_vm.count( "oauth2-client-secret" ) > 0 ) oauth2ClientSecret = m_vm["oauth2-client-secret"].as< string >(); if ( m_vm.count( "oauth2-auth-url" ) > 0 ) oauth2AuthUrl = m_vm["oauth2-auth-url"].as< string >(); if ( m_vm.count( "oauth2-token-url" ) > 0 ) oauth2TokenUrl = m_vm["oauth2-token-url"].as< string >(); if ( m_vm.count( "oauth2-redirect-uri" ) > 0 ) oauth2RedirectUri = m_vm["oauth2-redirect-uri"].as< string >(); if ( m_vm.count( "oauth2-scope" ) > 0 ) oauth2Scope = m_vm["oauth2-scope"].as< string >(); if ( m_vm.count( "oauth2-auth-code" ) > 0 ) AuthCodeProvider::setAuthCode( m_vm["oauth2-auth-code"].as< string >() ); libcmis::OAuth2DataPtr oauth2Data( new libcmis::OAuth2Data( oauth2AuthUrl, oauth2TokenUrl, oauth2Scope, oauth2RedirectUri, oauth2ClientId, oauth2ClientSecret) ); if ( oauth2Data->isComplete( ) ) { // Set the fallback AuthCode provider if ( m_vm.count( "oauth2-auth-code" ) > 0 ) { libcmis::SessionFactory::setOAuth2AuthCodeProvider( AuthCodeProvider::getAuthCode ); } else { libcmis::SessionFactory::setOAuth2AuthCodeProvider( lcl_queryAuthCode ); } } else { oauth2Data.reset( ); } session = libcmis::SessionFactory::createSession( url, username, password, repoId, noSslCheck, oauth2Data, verbose ); } return session; } void CmisClient::execute( ) { if ( ( m_vm.count( "help" ) > 0 ) || m_vm.count( "command" ) != 1 ) { printHelp(); return; } if ( m_vm.count( "command" ) == 1 ) { string command = m_vm["command"].as(); if ( "list-repos" == command ) { libcmis::Session* session = getSession( true ); if ( session != NULL ) { vector< libcmis::RepositoryPtr > repos = session->getRepositories(); cout << "Repositories: name (id)" << endl; for ( vector< libcmis::RepositoryPtr >::iterator it = repos.begin(); it != repos.end(); ++it ) cout << "\t" << ( *it )->getName( ) << " (" << ( *it )->getId( ) << ")" << endl; } else { cerr << "Couldn't create a session for some reason" << endl; } } else if ( "show-root" == command ) { unique_ptr session( getSession( ) ); libcmis::FolderPtr root = session->getRootFolder(); if ( root.get() ) { cout << "------------------------------------------------" << endl; cout << root->toString() << endl; } } else if ( "repo-infos" == command ) { unique_ptr session( getSession( ) ); libcmis::RepositoryPtr repo = session->getRepository( ); if ( repo ) { cout << "------------------------------------------------" << endl; cout << repo->toString() << endl; } else throw CommandException( "Please select a repository" ); } else if ( "type-by-id" == command ) { unique_ptr session( getSession( ) ); // Get the ids of the types to fetch if ( m_vm.count( "args" ) == 0 ) throw CommandException( "Please provide the node ids to show as command args" ); vector< string > ids = m_vm["args"].as< vector< string > >( ); for ( vector< string >::iterator it = ids.begin(); it != ids.end(); ++it ) { cout << "------------------------------------------------" << endl; try { libcmis::ObjectTypePtr type = session->getType( *it ); cout << type->toString() << endl; } catch ( const libcmis::Exception& e ) { cout << e.what() << endl; } } } else if ( "show-by-id" == command ) { unique_ptr session( getSession( ) ); // Get the ids of the objects to fetch if ( m_vm.count( "args" ) == 0 ) throw CommandException( "Please provide the node ids to show as command args" ); vector< string > objIds = m_vm["args"].as< vector< string > >( ); for ( vector< string >::iterator it = objIds.begin(); it != objIds.end(); ++it ) { libcmis::ObjectPtr cmisObj = session->getObject( *it ); cout << "------------------------------------------------" << endl; if ( cmisObj.get() ) cout << cmisObj->toString() << endl; else cout << "No such node: " << *it << endl; } } else if ( "show-by-path" == command ) { unique_ptr session( getSession( ) ); // Get the paths of the objects to fetch if ( m_vm.count( "args" ) == 0 ) throw CommandException( "Please provide the node paths to show as command args" ); vector< string > objPaths = m_vm["args"].as< vector< string > >( ); for ( vector< string >::iterator it = objPaths.begin(); it != objPaths.end(); ++it ) { libcmis::ObjectPtr cmisObj = session->getObjectByPath( *it ); cout << "------------------------------------------------" << endl; if ( cmisObj.get() ) cout << cmisObj->toString() << endl; else cout << "No such node: " << *it << endl; } } else if ( "get-content" == command ) { unique_ptr session( getSession( ) ); vector< string > objIds = m_vm["args"].as< vector< string > >( ); if ( objIds.empty( ) ) throw CommandException( "Please provide a content object Id" ); libcmis::ObjectPtr cmisObj = session->getObject( objIds.front() ); libcmis::Document* document = dynamic_cast< libcmis::Document* >( cmisObj.get() ); if ( NULL != document ) { // TODO Handle name clashes string streamId; if ( m_vm.count( "stream-id" ) > 0 ) streamId = m_vm["stream-id"].as(); boost::shared_ptr< istream > in = document->getContentStream( streamId ); ofstream out( document->getContentFilename().c_str() ); out << in->rdbuf(); out.close(); } else throw CommandException( string( "Not a document object id: " ) + objIds.front() ); } else if ( "set-content" == command ) { unique_ptr session( getSession( ) ); vector< string > objIds = m_vm["args"].as< vector< string > >( ); if ( objIds.empty( ) ) throw CommandException( "Please provide a content object Id" ); libcmis::ObjectPtr cmisObj = session->getObject( objIds.front() ); libcmis::Document* document = dynamic_cast< libcmis::Document* >( cmisObj.get() ); if ( NULL != document ) { if ( m_vm.count( "input-file" ) == 0 ) throw CommandException( "Missing --input-file" ); if ( m_vm.count( "input-type" ) == 0 ) throw CommandException( "Missing --input-type" ); string type = m_vm["input-type"].as(); string filename; if ( m_vm.count( "input-name" ) > 0 ) filename = m_vm["input-name"].as(); string file = m_vm["input-file"].as(); ifstream is( file.c_str(), ifstream::in ); boost::shared_ptr< ostream > os ( new ostream ( is.rdbuf( ) ) ); if ( is.fail( ) ) throw CommandException( string( "Unable to open file " ) + file ); document->setContentStream( os, type, filename ); is.close( ); } else throw CommandException( string( "Not a document object id: " ) + objIds.front() ); } else if ( "create-folder" == command ) { unique_ptr session( getSession( ) ); vector< string > args = m_vm["args"].as< vector< string > >( ); if ( args.size() < 2 ) throw CommandException( "Please provide a parent Id and folder name" ); libcmis::FolderPtr parent = session->getFolder( args[0] ); // Get the folder type to create string folderType( "cmis:folder" ); if ( m_vm.count( "object-type" ) != 0 ) folderType = m_vm["object-type"].as( ); libcmis::ObjectTypePtr type = session->getType( folderType ); if ( "cmis:folder" != type->getBaseType( )->getId( ) ) throw CommandException( string( "Not a folder type: " ) + folderType ); PropertyPtrMap properties; map< string, libcmis::PropertyTypePtr >& propertiesTypes = type->getPropertiesTypes( ); // Set the name map< string, libcmis::PropertyTypePtr >::iterator typeIt = propertiesTypes.find( string( "cmis:name" ) ); if ( typeIt == propertiesTypes.end( ) ) throw CommandException( string( "No cmis:name on the object type... weird" ) ); vector< string > nameValues; string newFolderName = args[1]; for ( unsigned int i = 2; i < args.size( ); i++ ) { newFolderName += " " + args[i]; } nameValues.push_back( newFolderName ); libcmis::PropertyPtr nameProperty( new libcmis::Property( typeIt->second, nameValues ) ); properties.insert( pair< string, libcmis::PropertyPtr >( string( "cmis:name" ), nameProperty ) ); // Set the objectTypeId typeIt = propertiesTypes.find( string( "cmis:objectTypeId" ) ); if ( typeIt == propertiesTypes.end( ) ) throw CommandException( string( "No cmis:objectTypeId on the object type... weird" ) ); vector< string > typeIdValues; typeIdValues.push_back( folderType ); libcmis::PropertyPtr typeIdProperty( new libcmis::Property( typeIt->second, typeIdValues ) ); properties.insert( pair< string, libcmis::PropertyPtr >( string( "cmis:objectTypeId" ), typeIdProperty ) ); // Checks for the properties to set if any map< string, string > propsToSet = getObjectProperties( ); for ( map< string, string >::iterator it = propsToSet.begin(); it != propsToSet.end(); ++it ) { // Create the CMIS property if it exists typeIt = propertiesTypes.find( it->first ); if ( typeIt != propertiesTypes.end( ) ) { vector< string > values; values.push_back( it->second ); libcmis::PropertyPtr cmisProperty( new libcmis::Property( typeIt->second, values ) ); properties.insert( pair< string, libcmis::PropertyPtr >( it->first, cmisProperty ) ); } } libcmis::FolderPtr created = parent->createFolder( properties ); cout << "------------------------------------------------" << endl; cout << created->toString() << endl; } else if ( "create-document" == command ) { unique_ptr session( getSession( ) ); vector< string > args = m_vm["args"].as< vector< string > >( ); if ( args.size() < 2 ) throw CommandException( "Please provide a parent Id and document name" ); libcmis::FolderPtr parent = session->getFolder( args[0] ); // Get the document type to create string documentType( "cmis:document" ); if ( m_vm.count( "object-type" ) != 0 ) documentType = m_vm["object-type"].as( ); libcmis::ObjectTypePtr type = session->getType( documentType ); if ( "cmis:document" != type->getBaseType( )->getId( ) ) throw CommandException( string( "Not a document type: " ) + documentType ); PropertyPtrMap properties; map< string, libcmis::PropertyTypePtr >& propertiesTypes = type->getPropertiesTypes( ); // Set the name map< string, libcmis::PropertyTypePtr >::iterator typeIt = propertiesTypes.find( string( "cmis:name" ) ); if ( typeIt == propertiesTypes.end( ) ) throw CommandException( string( "No cmis:name on the object type... weird" ) ); vector< string > nameValues; string newDocumentName = args[1]; for ( unsigned int i = 2; i < args.size( ); i++ ) { newDocumentName += " " + args[i]; } nameValues.push_back( newDocumentName ); libcmis::PropertyPtr nameProperty( new libcmis::Property( typeIt->second, nameValues ) ); properties.insert( pair< string, libcmis::PropertyPtr >( string( "cmis:name" ), nameProperty ) ); // Set the objectTypeId typeIt = propertiesTypes.find( string( "cmis:objectTypeId" ) ); if ( typeIt == propertiesTypes.end( ) ) throw CommandException( string( "No cmis:objectTypeId on the object type... weird" ) ); vector< string > typeIdValues; typeIdValues.push_back( documentType ); libcmis::PropertyPtr typeIdProperty( new libcmis::Property( typeIt->second, typeIdValues ) ); properties.insert( pair< string, libcmis::PropertyPtr >( string( "cmis:objectTypeId" ), typeIdProperty ) ); // Checks for the properties to set if any map< string, string > propsToSet = getObjectProperties( ); for ( map< string, string >::iterator it = propsToSet.begin(); it != propsToSet.end(); ++it ) { // Create the CMIS property if it exists typeIt = propertiesTypes.find( it->first ); if ( typeIt != propertiesTypes.end( ) ) { vector< string > values; values.push_back( it->second ); libcmis::PropertyPtr cmisProperty( new libcmis::Property( typeIt->second, values ) ); properties.insert( pair< string, libcmis::PropertyPtr >( it->first, cmisProperty ) ); } } // Get the content type and stream boost::shared_ptr< ostream > contentStream; string contentType; string filename; bool hasInputFile = m_vm.count( "input-file" ) != 0; bool hasInputType = m_vm.count( "input-type" ) != 0; bool hasInputName = m_vm.count( "input-name" ) != 0; if ( hasInputType && !hasInputFile ) throw CommandException( "Missing --input-file" ); if ( hasInputFile && !hasInputType ) throw CommandException( "Missing --input-type" ); if ( hasInputFile && hasInputType ) { contentType = m_vm["input-type"].as(); string file = m_vm["input-file"].as(); fstream is( file.c_str() ); if ( is.fail( ) ) throw CommandException( string( "Unable to open file " ) + file ); contentStream.reset( new ostringstream( ios_base::out | ios_base::in ) ); *contentStream << is.rdbuf(); } if ( hasInputName ) filename = m_vm[ "input-name" ].as< string >( ); // Actually create the document libcmis::DocumentPtr created = parent->createDocument( properties, contentStream, contentType, filename ); cout << "------------------------------------------------" << endl; cout << created->toString() << endl; } else if ( "update-object" == command ) { unique_ptr session( getSession( ) ); vector< string > args = m_vm["args"].as< vector< string > >( ); if ( args.size() != 1 ) throw CommandException( "Please provide an object id" ); libcmis::ObjectPtr object = session->getObject( args[0] ); libcmis::ObjectTypePtr type = session->getType( object->getType( ) ); map< string, libcmis::PropertyTypePtr >& propertiesTypes = type->getPropertiesTypes( ); PropertyPtrMap properties; // Checks for the properties to set if any map< string, string > propsToSet = getObjectProperties( ); for ( map< string, string >::iterator it = propsToSet.begin(); it != propsToSet.end(); ++it ) { // Create the CMIS property if it exists map< string, libcmis::PropertyTypePtr >::iterator typeIt = propertiesTypes.find( it->first ); if ( typeIt != propertiesTypes.end( ) && typeIt->second->isUpdatable( ) ) { vector< string > values; values.push_back( it->second ); libcmis::PropertyPtr property( new libcmis::Property( typeIt->second, values ) ); properties[ it->first ] = property; } } libcmis::ObjectPtr updated = object->updateProperties( properties ); cout << "------------------------------------------------" << endl; // Output updated instead of object as it may be different depending on the server cout << updated->toString() << endl; } else if ( "move-object" == command ) { unique_ptr session( getSession( ) ); vector< string > args = m_vm["args"].as< vector< string > > ( ); if ( args.size() != 3 ) throw CommandException( "Please provide an object id and source and destination folder ids" ); string& objId = args[0]; string& srcId = args[1]; string& dstId = args[2]; libcmis::ObjectPtr obj = session->getObject( objId ); libcmis::ObjectPtr src = session->getObject( srcId ); libcmis::FolderPtr srcFolder = boost::dynamic_pointer_cast< libcmis::Folder > ( src ); if ( !srcFolder ) throw CommandException( "Source object is not a folder" ); libcmis::ObjectPtr dst = session->getObject( dstId ); libcmis::FolderPtr dstFolder = boost::dynamic_pointer_cast< libcmis::Folder > ( dst ); if ( !dstFolder ) throw CommandException( "Destinaton object is not a folder" ); obj->move( srcFolder, dstFolder ); cout << "------------------------------------------------" << endl; cout << obj->toString( ) << endl; } else if ( "delete" == command ) { unique_ptr session( getSession( ) ); // Get the ids of the objects to fetch if ( m_vm.count( "args" ) == 0 ) throw CommandException( "Please provide the node ids to delete as command args" ); vector< string > objIds = m_vm["args"].as< vector< string > >( ); vector< string > errors; for ( vector< string >::iterator it = objIds.begin(); it != objIds.end(); ++it ) { libcmis::ObjectPtr cmisObj = session->getObject( *it ); libcmis::Folder* folder = dynamic_cast< libcmis::Folder* >( cmisObj.get() ); if ( NULL != folder ) { try { vector< string > failed = folder->removeTree( ); string error; for ( vector< string >::iterator dumpIt = failed.begin( ); dumpIt != failed.end( ); ++dumpIt ) { if ( dumpIt == failed.begin( ) ) error += "Failed to remove children nodes: "; else error += ", "; error = *dumpIt; } if ( !error.empty( ) ) errors.push_back( error ); } catch ( const libcmis::Exception& e ) { string msg = *it + ": " + e.what( ); errors.push_back( msg ); } } else if ( cmisObj.get() ) { try { cmisObj->remove( ); } catch ( const libcmis::Exception& e ) { string msg = *it + ": " + e.what( ); errors.push_back( msg ); } } else { string msg = "No such node: " + *it; errors.push_back( msg ); } } // Show the errors if ( !errors.empty( ) ) { cout << "Errors:" << endl; for ( vector< string >::iterator it = errors.begin( ); it != errors.end( ); ++it ) { cout << "\t" << *it << endl; } } else { cout << "All nodes have been removed" << endl; } } else if ( "checkout" == command ) { unique_ptr session( getSession( ) ); // Get the ids of the objects to fetch if ( m_vm.count( "args" ) == 0 ) throw CommandException( "Please provide the node id to checkout as command args" ); vector< string > objIds = m_vm["args"].as< vector< string > >( ); libcmis::ObjectPtr cmisObj = session->getObject( objIds.front() ); if ( cmisObj.get() ) { libcmis::Document* doc = dynamic_cast< libcmis::Document* >( cmisObj.get() ); if ( NULL != doc ) { libcmis::DocumentPtr pwc = doc->checkOut( ); if ( pwc.get( ) ) { cout << "------------------------------------------------" << endl; cout << pwc->toString() << endl; } else cout << "No Private Working Copy returned?" << endl; } else throw CommandException( string( "Not a document object id: " ) + objIds.front() ); } else cout << "No such node: " << objIds.front() << endl; } else if ( "cancel-checkout" == command ) { unique_ptr session( getSession( ) ); // Get the ids of the objects to fetch if ( m_vm.count( "args" ) == 0 ) throw CommandException( "Please provide the private working copy object id to cancel as command args" ); vector< string > objIds = m_vm["args"].as< vector< string > >( ); libcmis::ObjectPtr cmisObj = session->getObject( objIds.front() ); cout << "------------------------------------------------" << endl; if ( cmisObj.get() ) { libcmis::Document* doc = dynamic_cast< libcmis::Document* >( cmisObj.get() ); if ( NULL != doc ) { doc->cancelCheckout( ); cout << "Checkout cancelled" << endl; } else throw CommandException( string( "Not a document object id: " ) + objIds.front() ); } else cout << "No such node: " << objIds.front() << endl; } else if ( "checkin" == command ) { unique_ptr session( getSession( ) ); // Get the ids of the objects to fetch if ( m_vm.count( "args" ) == 0 ) throw CommandException( "Please provide the node id to checkin as command args" ); vector< string > objIds = m_vm["args"].as< vector< string > >( ); libcmis::ObjectPtr object = session->getObject( objIds.front() ); if ( object.get() ) { // Create the properties map PropertyPtrMap properties; map< string, string > propsToSet = getObjectProperties( ); libcmis::ObjectTypePtr type = session->getType( object->getType( ) ); map< string, libcmis::PropertyTypePtr > propertyTypes = type->getPropertiesTypes( ); for ( map< string, string >::iterator propIt = propsToSet.begin(); propIt != propsToSet.end(); ++propIt ) { string name = propIt->first; map< string, libcmis::PropertyTypePtr >::iterator typeIt = propertyTypes.find( name ); if ( typeIt != propertyTypes.end( ) ) { vector< string > values; values.push_back( propIt->second ); libcmis::PropertyPtr prop( new libcmis::Property( typeIt->second, values ) ); properties.insert( pair< string, libcmis::PropertyPtr >( name, prop ) ); } } // Get the content stream if any string contentType; string filename; boost::shared_ptr< ostream > stream; if ( m_vm.count( "input-file" ) > 0 ) { string file = m_vm["input-file"].as(); ifstream is( file.c_str(), ios_base::in ); stringstream os; os << is.rdbuf( ); if ( is.fail( ) ) throw CommandException( string( "Unable to open file " ) + file ); string content = os.str( ); stream.reset( new stringstream( content ) ); is.close( ); if ( m_vm.count( "input-type" ) > 0 ) { contentType = m_vm["input-type"].as(); } if ( m_vm.count( "input-name" ) > 0 ) { filename = m_vm["input-name"].as(); } } bool major = false; if ( m_vm.count( "major" ) > 0 ) major = "yes"; string comment; if ( m_vm.count( "message" ) > 0 ) comment = m_vm["message"].as< string >( ); libcmis::Document* doc = dynamic_cast< libcmis::Document* >( object.get() ); if ( NULL != doc ) { libcmis::DocumentPtr newDoc = doc->checkIn( major, comment, properties, stream, contentType, filename ); cout << "------------------------------------------------" << endl; cout << newDoc->toString() << endl; } else throw CommandException( string( "Not a document object id: " ) + objIds.front() ); } else cout << "No such node: " << objIds.front() << endl; } else if ( "get-versions" == command ) { unique_ptr session( getSession( ) ); // Get the ids of the objects to fetch if ( m_vm.count( "args" ) == 0 ) throw CommandException( "Please provide the node id to get versions from as command args" ); vector< string > objIds = m_vm["args"].as< vector< string > >( ); libcmis::ObjectPtr object = session->getObject( objIds.front() ); if ( object.get() ) { libcmis::Document* doc = dynamic_cast< libcmis::Document* >( object.get() ); if ( NULL != doc ) { vector< libcmis::DocumentPtr > versions = doc->getAllVersions( ); for ( vector< libcmis::DocumentPtr >::iterator it = versions.begin( ); it != versions.end( ); ++it ) { cout << "------------------------------------------------" << endl; cout << ( *it )->toString() << endl; } } else throw CommandException( string( "Not a document object id: " ) + objIds.front() ); } else cout << "No such node: " << objIds.front() << endl; } else if ( "help" == command ) { printHelp(); } else { cerr << "------------------------------------------------" << endl; cerr << "ERROR: Unknown command: " << command << endl; cerr << "------------------------------------------------" << endl; printHelp( ); } // TODO Add some more useful commands here } } options_description CmisClient::getOptionsDescription( ) { options_description desc( "Allowed options" ); desc.add_options( ) ( "help", "Produce help message and exists" ) ( "verbose,v", "Show loads of useful messages for debugging" ) ( "url", value< string >(), "URL of the binding of the server" ) ( "repository,r", value< string >(), "Name of the repository to use" ) ( "username,u", value< string >(), "Username used to authenticate to the repository" ) ( "password,p", value< string >(), "Password used to authenticate to the repository" ) ( "no-ssl-check", "Disable the verification of SSL certificates. This may come handy" "for self-signed certificates for example, though it lowers the security" ) ( "proxy", value< string >(), "HTTP proxy url to override the system settings" ) ( "noproxy", value< string >(), "Coma separated list if host and domain names not going" "through the proxy" ) ( "proxy-username", value< string >(), "Username to authenticate on the proxy" ) ( "proxy-password", value< string >(), "Password to authenticate on the proxy" ) ( "oauth2-client-id", value< string >(), "OAuth2 application client_id" ) ( "oauth2-client-secret", value< string >(), "OAuth2 application client_secret" ) ( "oauth2-auth-url", value< string >(), "URL to authenticate in the OAuth2 flow" ) ( "oauth2-token-url", value< string >(), "URL to convert code to tokens in the OAuth2 flow" ) ( "oauth2-redirect-uri", value< string >(), "redirect URI indicating that the authentication is finished in OAuth2 flow" ) ( "oauth2-scope", value< string >(), "The authentication scope in OAuth2" ) ( "oauth2-auth-code", value< string >(), "The authentication code required to get the access token" ) ; options_description setcontentOpts( "modification operations options" ); setcontentOpts.add_options( ) ( "input-file", value< string >(), "File to push to the repository" ) ( "input-type", value< string >(), "Mime type of the file to push to the repository" ) ( "input-name", value< string >(), "Name of the file to push to the repository" "(may be different from the local name)" ) ( "object-type", value< string >(), "CMIS type of the object to create" ) ( "object-property", value< vector< string > >(), "under the form prop-id=prop-value, defines a property" "to be set on the object" ) ( "message,m", value< string >(), "Check in message" ) ( "major", "The version to create during the check in will be a major version." ) ( "stream-id", value< string >(), "streamId of the rendition to get content." ) ; desc.add( setcontentOpts ); return desc; } void CmisClient::printHelp( ) { cerr << "cmis-client [options] [command] arguments" << endl; cerr << endl << "Commands" << endl; cerr << " list-repos\n" " Lists the repositories available on the server" << endl; cerr << " repo-infos\n" " Show the informations and capabilities of the selected repository" << endl; cerr << " show-root\n" " Dump the root node of the repository." << endl; cerr << " type-by-id [... ]\n" " Dumps the type informations for all the ids." << endl; cerr << " show-by-id [... ]\n" " Dumps the objects informations for all the ids." << endl; cerr << " show-by-path [... ]\n" " Dumps the objects informations for all the paths." << endl; cerr << " get-content \n" " Saves the stream of the content object in the\n" " current folder. Any existing file is overwritten.\n" " streamId can be used to get the desired rendition with --stream-id"<< endl; cerr << " set-content \n" " Replaces the stream of the content object by the\n" " file selected with --input-file." << endl; cerr << " create-folder \n" " Creates a new folder inside the folder named ." << endl; cerr << " create-document \n" " Creates a new document inside the folder \n" " named .\n" " Note that --input-file and --input-type may be requested if\n" " the server requires a content stream." << endl; cerr << " update-object \n" " Update the object matching id with the properties\n" " defined with --object-property." << endl; cerr << " move-object \n" " Move the object matching id from the\n" " folder to the folder ." << endl; cerr << " delete [... ]\n" " Delete the objects corresponding to the ids. If the node\n" " is a folder, its content will be removed as well." << endl; cerr << " checkout \n" " Check out the document corresponding to the id and shows the\n" " Private Working Copy document infos." << endl; cerr << " cancel-checkout \n" " Cancel the Private Working Copy corresponding to the id" << endl; cerr << " checkin \n" " Check in the Private Working copy corresponding to the id.\n" " Use the --message and --major parameters to give more\n" " details about the new version.\n" " The modification options may be needed to set the new\n" " version properties and content stream if the repository\n" " doesn't allow to change the private working copies." << endl; cerr << " get-versions \n" " Show all the versions of a document." << endl; cerr << " help\n" " Prints this help message and exits (like --help option)." << endl; cerr << endl << getOptionsDescription() << endl; } int main ( int argc, char* argv[] ) { options_description hidden( "Hidden options" ); hidden.add_options( ) ( "command", value< string >(), "Command" ) ( "args", value< vector< string > >(), "Arguments for the command" ) ; options_description allOptions = CmisClient::getOptionsDescription( ); allOptions.add( hidden ); positional_options_description pd; pd.add( "command", 1 ); pd.add( "args", -1 ); variables_map vm; store( command_line_parser( argc, argv ).options( allOptions ).positional( pd ).run( ), vm ); notify( vm ); CmisClient client( vm ); try { client.execute( ); } catch ( const CommandException& e ) { cerr << "------------------------------------------------" << endl; cerr << "ERROR: " << e.what() << endl; cerr << "------------------------------------------------" << endl; client.printHelp(); return 1; } catch ( const libcmis::Exception& e ) { cerr << "------------------------------------------------" << endl; cerr << "ERROR: " << e.what() << endl; cerr << "------------------------------------------------" << endl; return 1; } catch ( const exception& e ) { cerr << "------------------------------------------------" << endl; cerr << "ERROR: " << e.what() << endl; cerr << "------------------------------------------------" << endl; return 1; } return 0; } libcmis-0.5.2/test-driver0000755000175000017500000001104213407230143012252 00000000000000#! /bin/sh # test-driver - basic testsuite driver script. scriptversion=2018-03-07.03; # UTC # Copyright (C) 2011-2018 Free Software Foundation, Inc. # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # This file is maintained in Automake, please report # bugs to or send patches to # . # Make unconditional expansion of undefined variables an error. This # helps a lot in preventing typo-related bugs. set -u usage_error () { echo "$0: $*" >&2 print_usage >&2 exit 2 } print_usage () { cat <$log_file 2>&1 estatus=$? if test $enable_hard_errors = no && test $estatus -eq 99; then tweaked_estatus=1 else tweaked_estatus=$estatus fi case $tweaked_estatus:$expect_failure in 0:yes) col=$red res=XPASS recheck=yes gcopy=yes;; 0:*) col=$grn res=PASS recheck=no gcopy=no;; 77:*) col=$blu res=SKIP recheck=no gcopy=yes;; 99:*) col=$mgn res=ERROR recheck=yes gcopy=yes;; *:yes) col=$lgn res=XFAIL recheck=no gcopy=yes;; *:*) col=$red res=FAIL recheck=yes gcopy=yes;; esac # Report the test outcome and exit status in the logs, so that one can # know whether the test passed or failed simply by looking at the '.log' # file, without the need of also peaking into the corresponding '.trs' # file (automake bug#11814). echo "$res $test_name (exit status: $estatus)" >>$log_file # Report outcome to console. echo "${col}${res}${std}: $test_name" # Register the test result, and other relevant metadata. echo ":test-result: $res" > $trs_file echo ":global-test-result: $res" >> $trs_file echo ":recheck: $recheck" >> $trs_file echo ":copy-in-global-log: $gcopy" >> $trs_file # Local Variables: # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" # time-stamp-end: "; # UTC" # End: libcmis-0.5.2/configure.ac0000664000175000017500000001372213407704530012361 00000000000000# -*- Autoconf -*- # Process this file with autoconf to produce a configure script. m4_define([libcmis_major_version], [0]) m4_define([libcmis_minor_version], [5]) m4_define([libcmis_micro_version], [2]) m4_define([libcmis_api_version], [libcmis_major_version.libcmis_minor_version]) m4_define([libcmis_version],[libcmis_api_version.libcmis_micro_version]) AC_PREREQ([2.63]) AC_INIT([libcmis], [libcmis_version]) AM_INIT_AUTOMAKE([1.10 foreign dist-xz]) m4_ifdef([AM_SILENT_RULES],[AM_SILENT_RULES([yes])]) # Checks for programs. AC_PROG_CC AC_PROG_CPP AC_PROG_CXX AC_PROG_INSTALL AC_PROG_LN_S AC_PROG_MAKE_SET AC_PROG_LIBTOOL LT_INIT([win32-dll disable-static pic-only]) AC_CANONICAL_HOST AX_CXX_COMPILE_STDCXX_11 # Check the options AC_ARG_ENABLE(client, AC_HELP_STRING([--disable-client],[Compile only the library, not the client tool]), enable_client=$enableval, enable_client=yes) AM_CONDITIONAL(ENABLE_CLIENT, test "x$enable_client" != "xno") AC_ARG_ENABLE([tests], [AS_HELP_STRING([--disable-tests], [Do not build the unit tests])], [enable_tests="$enableval"], [enable_tests=yes] ) AM_CONDITIONAL(ENABLE_TESTS, test "x$enable_tests" != "xno") AC_ARG_ENABLE([coverage], [AS_HELP_STRING([--enable-coverage], [Extract test coverage data])], [enable_coverage="$enableval"], [enable_coverage=no] ) AM_CONDITIONAL(ENABLE_COVERAGE, test "x$enable_coverage" != "xno") AS_IF([test "x$enable_coverage" != "xno"], [ enable_tests=yes # Make sure we have gcc if test "x$GCC" != "xyes"; then AC_MSG_ERROR([GCC is required for --enable-coverage]) fi AC_CHECK_PROG(LCOV, lcov, lcov) AC_CHECK_PROG(GENHTML, genhtml, genhtml) AS_IF([test "x$ac_cv_prog_LCOV" = "x"], [ AC_MSG_ERROR([lcov is required for --enable-coverage]) ]) AS_IF([test "x$ac_cv_prog_GENHTML" = "x"], [ AC_MSG_ERROR([genhtml is required for --enable-coverage]) ]) CFLAGS="-g -O0 --coverage" CXXFLAGS="-g -O0 --coverage" LDFLAGS+="--coverage" ]) LIBCMIS_API_VERSION=libcmis_api_version AC_SUBST(LIBCMIS_API_VERSION) AC_CONFIG_MACRO_DIR([m4]) for top_builddir in . .. ../.. $ac_auxdir $ac_auxdir/..; do test -f $top_builddir/configure && break done SRCDIR=$srcdir AC_SUBST(SRCDIR) AC_LANG([C++]) # ========================== # Platform check for windows # ========================== AC_MSG_CHECKING([for native Win32]) AS_CASE([$host], [*-*-mingw*], [native_win32=yes], [native_win32=no]) AC_MSG_RESULT([$native_win32]) AM_CONDITIONAL(OS_WIN32, [test "x$native_win32" = "xyes"]) # ==================== # Check for visibility # ==================== AC_MSG_CHECKING([for -fvisibility=hidden compiler flag]) saved_CPPFLAGS="$CPPFLAGS" CPPFLAGS="$CPPFLAGS -fvisibility=hidden" AC_TRY_COMPILE([], [], [have_visibility=yes], [have_visibility=no]) AC_MSG_RESULT([$have_visibility]) CPPFLAGS="$saved_CPPFLAGS" AX_GCC_FUNC_ATTRIBUTE([visibility]) AM_CONDITIONAL([ENABLE_VISIBILITY], [ test "x$have_visibility" = "xyes" && test "x$ax_cv_have_func_attribute_visibility" = "xyes"]) # ============= # Documentation # ============= AC_ARG_WITH(man, [AS_HELP_STRING([--without-man], [Do not build manpage])], [with_man="$withval"], [with_man=yes] ) AS_IF([test "x$with_man" != "xno"], [ build_man=yes AS_IF([test -z "$DOCBOOK2MAN"], [ AC_PATH_PROGS([DOCBOOK2MAN], [docbook2x-man docbook-to-man docbook2man.pl]) AS_IF([test -z "$DOCBOOK2MAN"], [ AC_MSG_ERROR([docbook-to-man is missing. Install docbook2X package.]) ]) ]) ], [build_man=no]) AC_SUBST(DOCBOOK2MAN) AM_CONDITIONAL([ENABLE_MAN], [test "x$build_man" != "xno"]) # ======== # Cppcheck # ======== AC_PATH_PROG(CPPCHECK,[cppcheck],[]) AS_IF([test "x$ac_cv_path_CPPCHECK" != "x"], [enable_cppcheck=yes], [enable_cppcheck=no]) AC_SUBST(CPPCHECK) AC_PATH_PROG([NPROC], [nproc], []) AS_IF([test "x$NPROC" != "x"], [CPPCHECK_PARALLELISM=`$NPROC`], [CPPCHECK_PARALLELISM=1]) AC_SUBST([CPPCHECK_PARALLELISM]) AC_ARG_ENABLE([werror], [AS_HELP_STRING([--disable-werror], [Treat all warnings as errors, usefull for development])], [enable_werror="$enableval"], [enable_werror=yes] ) AS_IF([test x"$enable_werror" != "xno"], [ CFLAGS="$CFLAGS -Werror" CXXFLAGS="$CXXFLAGS -Werror" ]) AS_IF([test x"$GCC" = xyes], [ # Be tough with warnings and produce less careless code CFLAGS="$CFLAGS -Wall -pedantic -Wshadow -Wendif-labels -Wextra" CXXFLAGS="$CXXFLAGS -Wall -pedantic -Weffc++ -Wshadow -Wendif-labels -Wextra -Wsign-promo -Woverloaded-virtual -Wnon-virtual-dtor -Wsign-promo" ]) # Check for curl PKG_CHECK_MODULES(CURL, [libcurl]) AC_SUBST(CURL_CFLAGS) AC_SUBST(CURL_LIBS) # Check for lixml2 PKG_CHECK_MODULES(XML2, [libxml-2.0]) AC_SUBST(XML2_CFLAGS) AC_SUBST(XML2_LIBS) # Check for cppunit AS_IF([test "x$enable_tests" != "xno"], [ PKG_CHECK_MODULES(CPPUNIT, cppunit >= 1.12 ) AC_SUBST(CPPUNIT_CFLAGS) AC_SUBST(CPPUNIT_LIBS) ]) # Check for boost m4_pattern_allow([^BOOST_]) BOOST_REQUIRE([1.36]) BOOST_DATE_TIME BOOST_SMART_PTR BOOST_STRING_ALGO BOOST_UUID AS_IF([test "x$enable_client" != "xno"], [ BOOST_PROGRAM_OPTIONS ]) AC_SUBST(BOOST_CPPFLAGS) # Checks for header files. AC_CHECK_HEADERS([stdlib.h unistd.h]) # Checks for typedefs, structures, and compiler characteristics. AC_HEADER_STDBOOL AC_C_INLINE AC_TYPE_MODE_T AC_TYPE_SIZE_T # Checks for library functions. AC_CONFIG_FILES([ Makefile doc/cmis-client.xml inc/Makefile inc/libcmis-c/Makefile inc/libcmis/Makefile libcmis-c-$LIBCMIS_API_VERSION.pc:libcmis-c.pc.in libcmis-$LIBCMIS_API_VERSION.pc:libcmis.pc.in qa/Makefile qa/libcmis-c/Makefile qa/libcmis/Makefile qa/mockup/Makefile src/Makefile src/libcmis-c/Makefile src/libcmis/Makefile ]) AC_OUTPUT AC_MSG_NOTICE([ libcmis $VERSION: Prefix: ${prefix} Compiler: ${CXX} Compiler flags: ${CXXFLAGS} client: ${enable_client} werror: ${enable_werror} tests: ${enable_tests} test coverage: ${enable_coverage} mans: ${build_man} ]) libcmis-0.5.2/aclocal.m40000664000175000017500000015542113407705035011737 00000000000000# generated automatically by aclocal 1.16.1 -*- Autoconf -*- # Copyright (C) 1996-2018 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])]) m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],, [m4_warning([this file was generated for autoconf 2.69. You have another version of autoconf. It may work, but is not guaranteed to. If you have problems, you may need to regenerate the build system entirely. To do so, use the procedure documented by the package, typically 'autoreconf'.])]) # =========================================================================== # https://www.gnu.org/software/autoconf-archive/ax_require_defined.html # =========================================================================== # # SYNOPSIS # # AX_REQUIRE_DEFINED(MACRO) # # DESCRIPTION # # AX_REQUIRE_DEFINED is a simple helper for making sure other macros have # been defined and thus are available for use. This avoids random issues # where a macro isn't expanded. Instead the configure script emits a # non-fatal: # # ./configure: line 1673: AX_CFLAGS_WARN_ALL: command not found # # It's like AC_REQUIRE except it doesn't expand the required macro. # # Here's an example: # # AX_REQUIRE_DEFINED([AX_CHECK_LINK_FLAG]) # # LICENSE # # Copyright (c) 2014 Mike Frysinger # # Copying and distribution of this file, with or without modification, are # permitted in any medium without royalty provided the copyright notice # and this notice are preserved. This file is offered as-is, without any # warranty. #serial 2 AC_DEFUN([AX_REQUIRE_DEFINED], [dnl m4_ifndef([$1], [m4_fatal([macro ]$1[ is not defined; is a m4 file missing?])]) ])dnl AX_REQUIRE_DEFINED # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- # serial 11 (pkg-config-0.29.1) dnl Copyright © 2004 Scott James Remnant . dnl Copyright © 2012-2015 Dan Nicholson dnl dnl This program is free software; you can redistribute it and/or modify dnl it under the terms of the GNU General Public License as published by dnl the Free Software Foundation; either version 2 of the License, or dnl (at your option) any later version. dnl dnl This program is distributed in the hope that it will be useful, but dnl WITHOUT ANY WARRANTY; without even the implied warranty of dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU dnl General Public License for more details. dnl dnl You should have received a copy of the GNU General Public License dnl along with this program; if not, write to the Free Software dnl Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA dnl 02111-1307, USA. dnl dnl As a special exception to the GNU General Public License, if you dnl distribute this file as part of a program that contains a dnl configuration script generated by Autoconf, you may include it under dnl the same distribution terms that you use for the rest of that dnl program. dnl PKG_PREREQ(MIN-VERSION) dnl ----------------------- dnl Since: 0.29 dnl dnl Verify that the version of the pkg-config macros are at least dnl MIN-VERSION. Unlike PKG_PROG_PKG_CONFIG, which checks the user's dnl installed version of pkg-config, this checks the developer's version dnl of pkg.m4 when generating configure. dnl dnl To ensure that this macro is defined, also add: dnl m4_ifndef([PKG_PREREQ], dnl [m4_fatal([must install pkg-config 0.29 or later before running autoconf/autogen])]) dnl dnl See the "Since" comment for each macro you use to see what version dnl of the macros you require. m4_defun([PKG_PREREQ], [m4_define([PKG_MACROS_VERSION], [0.29.1]) m4_if(m4_version_compare(PKG_MACROS_VERSION, [$1]), -1, [m4_fatal([pkg.m4 version $1 or higher is required but ]PKG_MACROS_VERSION[ found])]) ])dnl PKG_PREREQ dnl PKG_PROG_PKG_CONFIG([MIN-VERSION]) dnl ---------------------------------- dnl Since: 0.16 dnl dnl Search for the pkg-config tool and set the PKG_CONFIG variable to dnl first found in the path. Checks that the version of pkg-config found dnl is at least MIN-VERSION. If MIN-VERSION is not specified, 0.9.0 is dnl used since that's the first version where most current features of dnl pkg-config existed. AC_DEFUN([PKG_PROG_PKG_CONFIG], [m4_pattern_forbid([^_?PKG_[A-Z_]+$]) m4_pattern_allow([^PKG_CONFIG(_(PATH|LIBDIR|SYSROOT_DIR|ALLOW_SYSTEM_(CFLAGS|LIBS)))?$]) m4_pattern_allow([^PKG_CONFIG_(DISABLE_UNINSTALLED|TOP_BUILD_DIR|DEBUG_SPEW)$]) AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility]) AC_ARG_VAR([PKG_CONFIG_PATH], [directories to add to pkg-config's search path]) AC_ARG_VAR([PKG_CONFIG_LIBDIR], [path overriding pkg-config's built-in search path]) if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) fi if test -n "$PKG_CONFIG"; then _pkg_min_version=m4_default([$1], [0.9.0]) AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version]) if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) PKG_CONFIG="" fi fi[]dnl ])dnl PKG_PROG_PKG_CONFIG dnl PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) dnl ------------------------------------------------------------------- dnl Since: 0.18 dnl dnl Check to see whether a particular set of modules exists. Similar to dnl PKG_CHECK_MODULES(), but does not set variables or print errors. dnl dnl Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG]) dnl only at the first occurence in configure.ac, so if the first place dnl it's called might be skipped (such as if it is within an "if", you dnl have to call PKG_CHECK_EXISTS manually AC_DEFUN([PKG_CHECK_EXISTS], [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl if test -n "$PKG_CONFIG" && \ AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then m4_default([$2], [:]) m4_ifvaln([$3], [else $3])dnl fi]) dnl _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) dnl --------------------------------------------- dnl Internal wrapper calling pkg-config via PKG_CONFIG and setting dnl pkg_failed based on the result. m4_define([_PKG_CONFIG], [if test -n "$$1"; then pkg_cv_[]$1="$$1" elif test -n "$PKG_CONFIG"; then PKG_CHECK_EXISTS([$3], [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes ], [pkg_failed=yes]) else pkg_failed=untried fi[]dnl ])dnl _PKG_CONFIG dnl _PKG_SHORT_ERRORS_SUPPORTED dnl --------------------------- dnl Internal check to see if pkg-config supports short errors. AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED], [AC_REQUIRE([PKG_PROG_PKG_CONFIG]) if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi[]dnl ])dnl _PKG_SHORT_ERRORS_SUPPORTED dnl PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], dnl [ACTION-IF-NOT-FOUND]) dnl -------------------------------------------------------------- dnl Since: 0.4.0 dnl dnl Note that if there is a possibility the first call to dnl PKG_CHECK_MODULES might not happen, you should be sure to include an dnl explicit call to PKG_PROG_PKG_CONFIG in your configure.ac AC_DEFUN([PKG_CHECK_MODULES], [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl pkg_failed=no AC_MSG_CHECKING([for $1]) _PKG_CONFIG([$1][_CFLAGS], [cflags], [$2]) _PKG_CONFIG([$1][_LIBS], [libs], [$2]) m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS and $1[]_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details.]) if test $pkg_failed = yes; then AC_MSG_RESULT([no]) _PKG_SHORT_ERRORS_SUPPORTED if test $_pkg_short_errors_supported = yes; then $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1` else $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD m4_default([$4], [AC_MSG_ERROR( [Package requirements ($2) were not met: $$1_PKG_ERRORS Consider adjusting the PKG_CONFIG_PATH environment variable if you installed software in a non-standard prefix. _PKG_TEXT])[]dnl ]) elif test $pkg_failed = untried; then AC_MSG_RESULT([no]) m4_default([$4], [AC_MSG_FAILURE( [The pkg-config script could not be found or is too old. Make sure it is in your PATH or set the PKG_CONFIG environment variable to the full path to pkg-config. _PKG_TEXT To get pkg-config, see .])[]dnl ]) else $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS $1[]_LIBS=$pkg_cv_[]$1[]_LIBS AC_MSG_RESULT([yes]) $3 fi[]dnl ])dnl PKG_CHECK_MODULES dnl PKG_CHECK_MODULES_STATIC(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], dnl [ACTION-IF-NOT-FOUND]) dnl --------------------------------------------------------------------- dnl Since: 0.29 dnl dnl Checks for existence of MODULES and gathers its build flags with dnl static libraries enabled. Sets VARIABLE-PREFIX_CFLAGS from --cflags dnl and VARIABLE-PREFIX_LIBS from --libs. dnl dnl Note that if there is a possibility the first call to dnl PKG_CHECK_MODULES_STATIC might not happen, you should be sure to dnl include an explicit call to PKG_PROG_PKG_CONFIG in your dnl configure.ac. AC_DEFUN([PKG_CHECK_MODULES_STATIC], [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl _save_PKG_CONFIG=$PKG_CONFIG PKG_CONFIG="$PKG_CONFIG --static" PKG_CHECK_MODULES($@) PKG_CONFIG=$_save_PKG_CONFIG[]dnl ])dnl PKG_CHECK_MODULES_STATIC dnl PKG_INSTALLDIR([DIRECTORY]) dnl ------------------------- dnl Since: 0.27 dnl dnl Substitutes the variable pkgconfigdir as the location where a module dnl should install pkg-config .pc files. By default the directory is dnl $libdir/pkgconfig, but the default can be changed by passing dnl DIRECTORY. The user can override through the --with-pkgconfigdir dnl parameter. AC_DEFUN([PKG_INSTALLDIR], [m4_pushdef([pkg_default], [m4_default([$1], ['${libdir}/pkgconfig'])]) m4_pushdef([pkg_description], [pkg-config installation directory @<:@]pkg_default[@:>@]) AC_ARG_WITH([pkgconfigdir], [AS_HELP_STRING([--with-pkgconfigdir], pkg_description)],, [with_pkgconfigdir=]pkg_default) AC_SUBST([pkgconfigdir], [$with_pkgconfigdir]) m4_popdef([pkg_default]) m4_popdef([pkg_description]) ])dnl PKG_INSTALLDIR dnl PKG_NOARCH_INSTALLDIR([DIRECTORY]) dnl -------------------------------- dnl Since: 0.27 dnl dnl Substitutes the variable noarch_pkgconfigdir as the location where a dnl module should install arch-independent pkg-config .pc files. By dnl default the directory is $datadir/pkgconfig, but the default can be dnl changed by passing DIRECTORY. The user can override through the dnl --with-noarch-pkgconfigdir parameter. AC_DEFUN([PKG_NOARCH_INSTALLDIR], [m4_pushdef([pkg_default], [m4_default([$1], ['${datadir}/pkgconfig'])]) m4_pushdef([pkg_description], [pkg-config arch-independent installation directory @<:@]pkg_default[@:>@]) AC_ARG_WITH([noarch-pkgconfigdir], [AS_HELP_STRING([--with-noarch-pkgconfigdir], pkg_description)],, [with_noarch_pkgconfigdir=]pkg_default) AC_SUBST([noarch_pkgconfigdir], [$with_noarch_pkgconfigdir]) m4_popdef([pkg_default]) m4_popdef([pkg_description]) ])dnl PKG_NOARCH_INSTALLDIR dnl PKG_CHECK_VAR(VARIABLE, MODULE, CONFIG-VARIABLE, dnl [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) dnl ------------------------------------------- dnl Since: 0.28 dnl dnl Retrieves the value of the pkg-config variable for the given module. AC_DEFUN([PKG_CHECK_VAR], [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl AC_ARG_VAR([$1], [value of $3 for $2, overriding pkg-config])dnl _PKG_CONFIG([$1], [variable="][$3]["], [$2]) AS_VAR_COPY([$1], [pkg_cv_][$1]) AS_VAR_IF([$1], [""], [$5], [$4])dnl ])dnl PKG_CHECK_VAR dnl PKG_WITH_MODULES(VARIABLE-PREFIX, MODULES, dnl [ACTION-IF-FOUND],[ACTION-IF-NOT-FOUND], dnl [DESCRIPTION], [DEFAULT]) dnl ------------------------------------------ dnl dnl Prepare a "--with-" configure option using the lowercase dnl [VARIABLE-PREFIX] name, merging the behaviour of AC_ARG_WITH and dnl PKG_CHECK_MODULES in a single macro. AC_DEFUN([PKG_WITH_MODULES], [ m4_pushdef([with_arg], m4_tolower([$1])) m4_pushdef([description], [m4_default([$5], [build with ]with_arg[ support])]) m4_pushdef([def_arg], [m4_default([$6], [auto])]) m4_pushdef([def_action_if_found], [AS_TR_SH([with_]with_arg)=yes]) m4_pushdef([def_action_if_not_found], [AS_TR_SH([with_]with_arg)=no]) m4_case(def_arg, [yes],[m4_pushdef([with_without], [--without-]with_arg)], [m4_pushdef([with_without],[--with-]with_arg)]) AC_ARG_WITH(with_arg, AS_HELP_STRING(with_without, description[ @<:@default=]def_arg[@:>@]),, [AS_TR_SH([with_]with_arg)=def_arg]) AS_CASE([$AS_TR_SH([with_]with_arg)], [yes],[PKG_CHECK_MODULES([$1],[$2],$3,$4)], [auto],[PKG_CHECK_MODULES([$1],[$2], [m4_n([def_action_if_found]) $3], [m4_n([def_action_if_not_found]) $4])]) m4_popdef([with_arg]) m4_popdef([description]) m4_popdef([def_arg]) ])dnl PKG_WITH_MODULES dnl PKG_HAVE_WITH_MODULES(VARIABLE-PREFIX, MODULES, dnl [DESCRIPTION], [DEFAULT]) dnl ----------------------------------------------- dnl dnl Convenience macro to trigger AM_CONDITIONAL after PKG_WITH_MODULES dnl check._[VARIABLE-PREFIX] is exported as make variable. AC_DEFUN([PKG_HAVE_WITH_MODULES], [ PKG_WITH_MODULES([$1],[$2],,,[$3],[$4]) AM_CONDITIONAL([HAVE_][$1], [test "$AS_TR_SH([with_]m4_tolower([$1]))" = "yes"]) ])dnl PKG_HAVE_WITH_MODULES dnl PKG_HAVE_DEFINE_WITH_MODULES(VARIABLE-PREFIX, MODULES, dnl [DESCRIPTION], [DEFAULT]) dnl ------------------------------------------------------ dnl dnl Convenience macro to run AM_CONDITIONAL and AC_DEFINE after dnl PKG_WITH_MODULES check. HAVE_[VARIABLE-PREFIX] is exported as make dnl and preprocessor variable. AC_DEFUN([PKG_HAVE_DEFINE_WITH_MODULES], [ PKG_HAVE_WITH_MODULES([$1],[$2],[$3],[$4]) AS_IF([test "$AS_TR_SH([with_]m4_tolower([$1]))" = "yes"], [AC_DEFINE([HAVE_][$1], 1, [Enable ]m4_tolower([$1])[ support])]) ])dnl PKG_HAVE_DEFINE_WITH_MODULES # Copyright (C) 2002-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_AUTOMAKE_VERSION(VERSION) # ---------------------------- # Automake X.Y traces this macro to ensure aclocal.m4 has been # generated from the m4 files accompanying Automake X.Y. # (This private macro should not be called outside this file.) AC_DEFUN([AM_AUTOMAKE_VERSION], [am__api_version='1.16' dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to dnl require some minimum version. Point them to the right macro. m4_if([$1], [1.16.1], [], [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl ]) # _AM_AUTOCONF_VERSION(VERSION) # ----------------------------- # aclocal traces this macro to find the Autoconf version. # This is a private macro too. Using m4_define simplifies # the logic in aclocal, which can simply ignore this definition. m4_define([_AM_AUTOCONF_VERSION], []) # AM_SET_CURRENT_AUTOMAKE_VERSION # ------------------------------- # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. # This function is AC_REQUIREd by AM_INIT_AUTOMAKE. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], [AM_AUTOMAKE_VERSION([1.16.1])dnl m4_ifndef([AC_AUTOCONF_VERSION], [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) # AM_AUX_DIR_EXPAND -*- Autoconf -*- # Copyright (C) 2001-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets # $ac_aux_dir to '$srcdir/foo'. In other projects, it is set to # '$srcdir', '$srcdir/..', or '$srcdir/../..'. # # Of course, Automake must honor this variable whenever it calls a # tool from the auxiliary directory. The problem is that $srcdir (and # therefore $ac_aux_dir as well) can be either absolute or relative, # depending on how configure is run. This is pretty annoying, since # it makes $ac_aux_dir quite unusable in subdirectories: in the top # source directory, any form will work fine, but in subdirectories a # relative path needs to be adjusted first. # # $ac_aux_dir/missing # fails when called from a subdirectory if $ac_aux_dir is relative # $top_srcdir/$ac_aux_dir/missing # fails if $ac_aux_dir is absolute, # fails when called from a subdirectory in a VPATH build with # a relative $ac_aux_dir # # The reason of the latter failure is that $top_srcdir and $ac_aux_dir # are both prefixed by $srcdir. In an in-source build this is usually # harmless because $srcdir is '.', but things will broke when you # start a VPATH build or use an absolute $srcdir. # # So we could use something similar to $top_srcdir/$ac_aux_dir/missing, # iff we strip the leading $srcdir from $ac_aux_dir. That would be: # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` # and then we would define $MISSING as # MISSING="\${SHELL} $am_aux_dir/missing" # This will work as long as MISSING is not called from configure, because # unfortunately $(top_srcdir) has no meaning in configure. # However there are other variables, like CC, which are often used in # configure, and could therefore not use this "fixed" $ac_aux_dir. # # Another solution, used here, is to always expand $ac_aux_dir to an # absolute PATH. The drawback is that using absolute paths prevent a # configured tree to be moved without reconfiguration. AC_DEFUN([AM_AUX_DIR_EXPAND], [AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl # Expand $ac_aux_dir to an absolute path. am_aux_dir=`cd "$ac_aux_dir" && pwd` ]) # AM_CONDITIONAL -*- Autoconf -*- # Copyright (C) 1997-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_CONDITIONAL(NAME, SHELL-CONDITION) # ------------------------------------- # Define a conditional. AC_DEFUN([AM_CONDITIONAL], [AC_PREREQ([2.52])dnl m4_if([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl AC_SUBST([$1_TRUE])dnl AC_SUBST([$1_FALSE])dnl _AM_SUBST_NOTMAKE([$1_TRUE])dnl _AM_SUBST_NOTMAKE([$1_FALSE])dnl m4_define([_AM_COND_VALUE_$1], [$2])dnl if $2; then $1_TRUE= $1_FALSE='#' else $1_TRUE='#' $1_FALSE= fi AC_CONFIG_COMMANDS_PRE( [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then AC_MSG_ERROR([[conditional "$1" was never defined. Usually this means the macro was only invoked conditionally.]]) fi])]) # Copyright (C) 1999-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # There are a few dirty hacks below to avoid letting 'AC_PROG_CC' be # written in clear, in which case automake, when reading aclocal.m4, # will think it sees a *use*, and therefore will trigger all it's # C support machinery. Also note that it means that autoscan, seeing # CC etc. in the Makefile, will ask for an AC_PROG_CC use... # _AM_DEPENDENCIES(NAME) # ---------------------- # See how the compiler implements dependency checking. # NAME is "CC", "CXX", "OBJC", "OBJCXX", "UPC", or "GJC". # We try a few techniques and use that to set a single cache variable. # # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular # dependency, and given that the user is not expected to run this macro, # just rely on AC_PROG_CC. AC_DEFUN([_AM_DEPENDENCIES], [AC_REQUIRE([AM_SET_DEPDIR])dnl AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl AC_REQUIRE([AM_MAKE_INCLUDE])dnl AC_REQUIRE([AM_DEP_TRACK])dnl m4_if([$1], [CC], [depcc="$CC" am_compiler_list=], [$1], [CXX], [depcc="$CXX" am_compiler_list=], [$1], [OBJC], [depcc="$OBJC" am_compiler_list='gcc3 gcc'], [$1], [OBJCXX], [depcc="$OBJCXX" am_compiler_list='gcc3 gcc'], [$1], [UPC], [depcc="$UPC" am_compiler_list=], [$1], [GCJ], [depcc="$GCJ" am_compiler_list='gcc3 gcc'], [depcc="$$1" am_compiler_list=]) AC_CACHE_CHECK([dependency style of $depcc], [am_cv_$1_dependencies_compiler_type], [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named 'D' -- because '-MD' means "put the output # in D". rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_$1_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` fi am__universal=false m4_case([$1], [CC], [case " $depcc " in #( *\ -arch\ *\ -arch\ *) am__universal=true ;; esac], [CXX], [case " $depcc " in #( *\ -arch\ *\ -arch\ *) am__universal=true ;; esac]) for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with # Solaris 10 /bin/sh. echo '/* dummy */' > sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf # We check with '-c' and '-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle '-M -o', and we need to detect this. Also, some Intel # versions had trouble with output in subdirs. am__obj=sub/conftest.${OBJEXT-o} am__minus_obj="-o $am__obj" case $depmode in gcc) # This depmode causes a compiler race in universal mode. test "$am__universal" = false || continue ;; nosideeffect) # After this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested. if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; msvc7 | msvc7msys | msvisualcpp | msvcmsys) # This compiler won't grok '-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. am__obj=conftest.${OBJEXT-o} am__minus_obj= ;; none) break ;; esac if depmode=$depmode \ source=sub/conftest.c object=$am__obj \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep $am__obj sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_$1_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_$1_dependencies_compiler_type=none fi ]) AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) AM_CONDITIONAL([am__fastdep$1], [ test "x$enable_dependency_tracking" != xno \ && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) ]) # AM_SET_DEPDIR # ------------- # Choose a directory name for dependency files. # This macro is AC_REQUIREd in _AM_DEPENDENCIES. AC_DEFUN([AM_SET_DEPDIR], [AC_REQUIRE([AM_SET_LEADING_DOT])dnl AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl ]) # AM_DEP_TRACK # ------------ AC_DEFUN([AM_DEP_TRACK], [AC_ARG_ENABLE([dependency-tracking], [dnl AS_HELP_STRING( [--enable-dependency-tracking], [do not reject slow dependency extractors]) AS_HELP_STRING( [--disable-dependency-tracking], [speeds up one-time build])]) if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' am__nodep='_no' fi AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) AC_SUBST([AMDEPBACKSLASH])dnl _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl AC_SUBST([am__nodep])dnl _AM_SUBST_NOTMAKE([am__nodep])dnl ]) # Generate code to set up dependency tracking. -*- Autoconf -*- # Copyright (C) 1999-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # _AM_OUTPUT_DEPENDENCY_COMMANDS # ------------------------------ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], [{ # Older Autoconf quotes --file arguments for eval, but not when files # are listed without --file. Let's play safe and only enable the eval # if we detect the quoting. # TODO: see whether this extra hack can be removed once we start # requiring Autoconf 2.70 or later. AS_CASE([$CONFIG_FILES], [*\'*], [eval set x "$CONFIG_FILES"], [*], [set x $CONFIG_FILES]) shift # Used to flag and report bootstrapping failures. am_rc=0 for am_mf do # Strip MF so we end up with the name of the file. am_mf=`AS_ECHO(["$am_mf"]) | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile which includes # dependency-tracking related rules and includes. # Grep'ing the whole file directly is not great: AIX grep has a line # limit of 2048, but all sed's we know have understand at least 4000. sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \ || continue am_dirpart=`AS_DIRNAME(["$am_mf"])` am_filepart=`AS_BASENAME(["$am_mf"])` AM_RUN_LOG([cd "$am_dirpart" \ && sed -e '/# am--include-marker/d' "$am_filepart" \ | $MAKE -f - am--depfiles]) || am_rc=$? done if test $am_rc -ne 0; then AC_MSG_FAILURE([Something went wrong bootstrapping makefile fragments for automatic dependency tracking. Try re-running configure with the '--disable-dependency-tracking' option to at least be able to build the package (albeit without support for automatic dependency tracking).]) fi AS_UNSET([am_dirpart]) AS_UNSET([am_filepart]) AS_UNSET([am_mf]) AS_UNSET([am_rc]) rm -f conftest-deps.mk } ])# _AM_OUTPUT_DEPENDENCY_COMMANDS # AM_OUTPUT_DEPENDENCY_COMMANDS # ----------------------------- # This macro should only be invoked once -- use via AC_REQUIRE. # # This code is only required when automatic dependency tracking is enabled. # This creates each '.Po' and '.Plo' makefile fragment that we'll need in # order to bootstrap the dependency handling code. AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], [AC_CONFIG_COMMANDS([depfiles], [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], [AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}"])]) # Do all the work for Automake. -*- Autoconf -*- # Copyright (C) 1996-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This macro actually does too much. Some checks are only needed if # your package does certain things. But this isn't really a big deal. dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O. m4_define([AC_PROG_CC], m4_defn([AC_PROG_CC]) [_AM_PROG_CC_C_O ]) # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) # AM_INIT_AUTOMAKE([OPTIONS]) # ----------------------------------------------- # The call with PACKAGE and VERSION arguments is the old style # call (pre autoconf-2.50), which is being phased out. PACKAGE # and VERSION should now be passed to AC_INIT and removed from # the call to AM_INIT_AUTOMAKE. # We support both call styles for the transition. After # the next Automake release, Autoconf can make the AC_INIT # arguments mandatory, and then we can depend on a new Autoconf # release and drop the old call support. AC_DEFUN([AM_INIT_AUTOMAKE], [AC_PREREQ([2.65])dnl dnl Autoconf wants to disallow AM_ names. We explicitly allow dnl the ones we care about. m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl AC_REQUIRE([AC_PROG_INSTALL])dnl if test "`cd $srcdir && pwd`" != "`pwd`"; then # Use -I$(srcdir) only when $(srcdir) != ., so that make's output # is not polluted with repeated "-I." AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl # test to see if srcdir already configured if test -f $srcdir/config.status; then AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) fi fi # test whether we have cygpath if test -z "$CYGPATH_W"; then if (cygpath --version) >/dev/null 2>/dev/null; then CYGPATH_W='cygpath -w' else CYGPATH_W=echo fi fi AC_SUBST([CYGPATH_W]) # Define the identity of the package. dnl Distinguish between old-style and new-style calls. m4_ifval([$2], [AC_DIAGNOSE([obsolete], [$0: two- and three-arguments forms are deprecated.]) m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl AC_SUBST([PACKAGE], [$1])dnl AC_SUBST([VERSION], [$2])], [_AM_SET_OPTIONS([$1])dnl dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. m4_if( m4_ifdef([AC_PACKAGE_NAME], [ok]):m4_ifdef([AC_PACKAGE_VERSION], [ok]), [ok:ok],, [m4_fatal([AC_INIT should be called with package and version arguments])])dnl AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl _AM_IF_OPTION([no-define],, [AC_DEFINE_UNQUOTED([PACKAGE], ["$PACKAGE"], [Name of package]) AC_DEFINE_UNQUOTED([VERSION], ["$VERSION"], [Version number of package])])dnl # Some tools Automake needs. AC_REQUIRE([AM_SANITY_CHECK])dnl AC_REQUIRE([AC_ARG_PROGRAM])dnl AM_MISSING_PROG([ACLOCAL], [aclocal-${am__api_version}]) AM_MISSING_PROG([AUTOCONF], [autoconf]) AM_MISSING_PROG([AUTOMAKE], [automake-${am__api_version}]) AM_MISSING_PROG([AUTOHEADER], [autoheader]) AM_MISSING_PROG([MAKEINFO], [makeinfo]) AC_REQUIRE([AM_PROG_INSTALL_SH])dnl AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl AC_REQUIRE([AC_PROG_MKDIR_P])dnl # For better backward compatibility. To be removed once Automake 1.9.x # dies out for good. For more background, see: # # AC_SUBST([mkdir_p], ['$(MKDIR_P)']) # We need awk for the "check" target (and possibly the TAP driver). The # system "awk" is bad on some platforms. AC_REQUIRE([AC_PROG_AWK])dnl AC_REQUIRE([AC_PROG_MAKE_SET])dnl AC_REQUIRE([AM_SET_LEADING_DOT])dnl _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], [_AM_PROG_TAR([v7])])]) _AM_IF_OPTION([no-dependencies],, [AC_PROVIDE_IFELSE([AC_PROG_CC], [_AM_DEPENDENCIES([CC])], [m4_define([AC_PROG_CC], m4_defn([AC_PROG_CC])[_AM_DEPENDENCIES([CC])])])dnl AC_PROVIDE_IFELSE([AC_PROG_CXX], [_AM_DEPENDENCIES([CXX])], [m4_define([AC_PROG_CXX], m4_defn([AC_PROG_CXX])[_AM_DEPENDENCIES([CXX])])])dnl AC_PROVIDE_IFELSE([AC_PROG_OBJC], [_AM_DEPENDENCIES([OBJC])], [m4_define([AC_PROG_OBJC], m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl AC_PROVIDE_IFELSE([AC_PROG_OBJCXX], [_AM_DEPENDENCIES([OBJCXX])], [m4_define([AC_PROG_OBJCXX], m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl ]) AC_REQUIRE([AM_SILENT_RULES])dnl dnl The testsuite driver may need to know about EXEEXT, so add the dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below. AC_CONFIG_COMMANDS_PRE(dnl [m4_provide_if([_AM_COMPILER_EXEEXT], [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl # POSIX will say in a future version that running "rm -f" with no argument # is OK; and we want to be able to make that assumption in our Makefile # recipes. So use an aggressive probe to check that the usage we want is # actually supported "in the wild" to an acceptable degree. # See automake bug#10828. # To make any issue more visible, cause the running configure to be aborted # by default if the 'rm' program in use doesn't match our expectations; the # user can still override this though. if rm -f && rm -fr && rm -rf; then : OK; else cat >&2 <<'END' Oops! Your 'rm' program seems unable to run without file operands specified on the command line, even when the '-f' option is present. This is contrary to the behaviour of most rm programs out there, and not conforming with the upcoming POSIX standard: Please tell bug-automake@gnu.org about your system, including the value of your $PATH and any error possibly output before this message. This can help us improve future automake versions. END if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then echo 'Configuration will proceed anyway, since you have set the' >&2 echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 echo >&2 else cat >&2 <<'END' Aborting the configuration process, to ensure you take notice of the issue. You can download and install GNU coreutils to get an 'rm' implementation that behaves properly: . If you want to complete the configuration process using your problematic 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM to "yes", and re-run configure. END AC_MSG_ERROR([Your 'rm' program is bad, sorry.]) fi fi dnl The trailing newline in this macro's definition is deliberate, for dnl backward compatibility and to allow trailing 'dnl'-style comments dnl after the AM_INIT_AUTOMAKE invocation. See automake bug#16841. ]) dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further dnl mangled by Autoconf and run in a shell conditional statement. m4_define([_AC_COMPILER_EXEEXT], m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) # When config.status generates a header, we must update the stamp-h file. # This file resides in the same directory as the config header # that is generated. The stamp files are numbered to have different names. # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the # loop where config.status creates the headers, so we can generate # our stamp files there. AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], [# Compute $1's index in $config_headers. _am_arg=$1 _am_stamp_count=1 for _am_header in $config_headers :; do case $_am_header in $_am_arg | $_am_arg:* ) break ;; * ) _am_stamp_count=`expr $_am_stamp_count + 1` ;; esac done echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) # Copyright (C) 2001-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_PROG_INSTALL_SH # ------------------ # Define $install_sh. AC_DEFUN([AM_PROG_INSTALL_SH], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl if test x"${install_sh+set}" != xset; then case $am_aux_dir in *\ * | *\ *) install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; *) install_sh="\${SHELL} $am_aux_dir/install-sh" esac fi AC_SUBST([install_sh])]) # Copyright (C) 2003-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # Check whether the underlying file-system supports filenames # with a leading dot. For instance MS-DOS doesn't. AC_DEFUN([AM_SET_LEADING_DOT], [rm -rf .tst 2>/dev/null mkdir .tst 2>/dev/null if test -d .tst; then am__leading_dot=. else am__leading_dot=_ fi rmdir .tst 2>/dev/null AC_SUBST([am__leading_dot])]) # Check to see how 'make' treats includes. -*- Autoconf -*- # Copyright (C) 2001-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_MAKE_INCLUDE() # ----------------- # Check whether make has an 'include' directive that can support all # the idioms we need for our automatic dependency tracking code. AC_DEFUN([AM_MAKE_INCLUDE], [AC_MSG_CHECKING([whether ${MAKE-make} supports the include directive]) cat > confinc.mk << 'END' am__doit: @echo this is the am__doit target >confinc.out .PHONY: am__doit END am__include="#" am__quote= # BSD make does it like this. echo '.include "confinc.mk" # ignored' > confmf.BSD # Other make implementations (GNU, Solaris 10, AIX) do it like this. echo 'include confinc.mk # ignored' > confmf.GNU _am_result=no for s in GNU BSD; do AM_RUN_LOG([${MAKE-make} -f confmf.$s && cat confinc.out]) AS_CASE([$?:`cat confinc.out 2>/dev/null`], ['0:this is the am__doit target'], [AS_CASE([$s], [BSD], [am__include='.include' am__quote='"'], [am__include='include' am__quote=''])]) if test "$am__include" != "#"; then _am_result="yes ($s style)" break fi done rm -f confinc.* confmf.* AC_MSG_RESULT([${_am_result}]) AC_SUBST([am__include])]) AC_SUBST([am__quote])]) # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- # Copyright (C) 1997-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_MISSING_PROG(NAME, PROGRAM) # ------------------------------ AC_DEFUN([AM_MISSING_PROG], [AC_REQUIRE([AM_MISSING_HAS_RUN]) $1=${$1-"${am_missing_run}$2"} AC_SUBST($1)]) # AM_MISSING_HAS_RUN # ------------------ # Define MISSING if not defined so far and test if it is modern enough. # If it is, set am_missing_run to use it, otherwise, to nothing. AC_DEFUN([AM_MISSING_HAS_RUN], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl AC_REQUIRE_AUX_FILE([missing])dnl if test x"${MISSING+set}" != xset; then case $am_aux_dir in *\ * | *\ *) MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; *) MISSING="\${SHELL} $am_aux_dir/missing" ;; esac fi # Use eval to expand $SHELL if eval "$MISSING --is-lightweight"; then am_missing_run="$MISSING " else am_missing_run= AC_MSG_WARN(['missing' script is too old or missing]) fi ]) # Helper functions for option handling. -*- Autoconf -*- # Copyright (C) 2001-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # _AM_MANGLE_OPTION(NAME) # ----------------------- AC_DEFUN([_AM_MANGLE_OPTION], [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) # _AM_SET_OPTION(NAME) # -------------------- # Set option NAME. Presently that only means defining a flag for this option. AC_DEFUN([_AM_SET_OPTION], [m4_define(_AM_MANGLE_OPTION([$1]), [1])]) # _AM_SET_OPTIONS(OPTIONS) # ------------------------ # OPTIONS is a space-separated list of Automake options. AC_DEFUN([_AM_SET_OPTIONS], [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) # ------------------------------------------- # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. AC_DEFUN([_AM_IF_OPTION], [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) # Copyright (C) 1999-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # _AM_PROG_CC_C_O # --------------- # Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC # to automatically call this. AC_DEFUN([_AM_PROG_CC_C_O], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl AC_REQUIRE_AUX_FILE([compile])dnl AC_LANG_PUSH([C])dnl AC_CACHE_CHECK( [whether $CC understands -c and -o together], [am_cv_prog_cc_c_o], [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])]) # Make sure it works both with $CC and with simple cc. # Following AC_PROG_CC_C_O, we do the test twice because some # compilers refuse to overwrite an existing .o file with -o, # though they will create one. am_cv_prog_cc_c_o=yes for am_i in 1 2; do if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \ && test -f conftest2.$ac_objext; then : OK else am_cv_prog_cc_c_o=no break fi done rm -f core conftest* unset am_i]) if test "$am_cv_prog_cc_c_o" != yes; then # Losing compiler, so override with the script. # FIXME: It is wrong to rewrite CC. # But if we don't then we get into trouble of one sort or another. # A longer-term fix would be to have automake use am__CC in this case, # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" CC="$am_aux_dir/compile $CC" fi AC_LANG_POP([C])]) # For backward compatibility. AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])]) # Copyright (C) 2001-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_RUN_LOG(COMMAND) # ------------------- # Run COMMAND, save the exit status in ac_status, and log it. # (This has been adapted from Autoconf's _AC_RUN_LOG macro.) AC_DEFUN([AM_RUN_LOG], [{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD (exit $ac_status); }]) # Check to make sure that the build environment is sane. -*- Autoconf -*- # Copyright (C) 1996-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_SANITY_CHECK # --------------- AC_DEFUN([AM_SANITY_CHECK], [AC_MSG_CHECKING([whether build environment is sane]) # Reject unsafe characters in $srcdir or the absolute working directory # name. Accept space and tab only in the latter. am_lf=' ' case `pwd` in *[[\\\"\#\$\&\'\`$am_lf]]*) AC_MSG_ERROR([unsafe absolute working directory name]);; esac case $srcdir in *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) AC_MSG_ERROR([unsafe srcdir value: '$srcdir']);; esac # Do 'set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( am_has_slept=no for am_try in 1 2; do echo "timestamp, slept: $am_has_slept" > conftest.file set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` if test "$[*]" = "X"; then # -L didn't work. set X `ls -t "$srcdir/configure" conftest.file` fi if test "$[*]" != "X $srcdir/configure conftest.file" \ && test "$[*]" != "X conftest.file $srcdir/configure"; then # If neither matched, then we have a broken ls. This can happen # if, for instance, CONFIG_SHELL is bash and it inherits a # broken ls alias from the environment. This has actually # happened. Such a system could not be considered "sane". AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken alias in your environment]) fi if test "$[2]" = conftest.file || test $am_try -eq 2; then break fi # Just in case. sleep 1 am_has_slept=yes done test "$[2]" = conftest.file ) then # Ok. : else AC_MSG_ERROR([newly created file is older than distributed files! Check your system clock]) fi AC_MSG_RESULT([yes]) # If we didn't sleep, we still need to ensure time stamps of config.status and # generated files are strictly newer. am_sleep_pid= if grep 'slept: no' conftest.file >/dev/null 2>&1; then ( sleep 1 ) & am_sleep_pid=$! fi AC_CONFIG_COMMANDS_PRE( [AC_MSG_CHECKING([that generated files are newer than configure]) if test -n "$am_sleep_pid"; then # Hide warnings about reused PIDs. wait $am_sleep_pid 2>/dev/null fi AC_MSG_RESULT([done])]) rm -f conftest.file ]) # Copyright (C) 2009-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_SILENT_RULES([DEFAULT]) # -------------------------- # Enable less verbose build rules; with the default set to DEFAULT # ("yes" being less verbose, "no" or empty being verbose). AC_DEFUN([AM_SILENT_RULES], [AC_ARG_ENABLE([silent-rules], [dnl AS_HELP_STRING( [--enable-silent-rules], [less verbose build output (undo: "make V=1")]) AS_HELP_STRING( [--disable-silent-rules], [verbose build output (undo: "make V=0")])dnl ]) case $enable_silent_rules in @%:@ ((( yes) AM_DEFAULT_VERBOSITY=0;; no) AM_DEFAULT_VERBOSITY=1;; *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; esac dnl dnl A few 'make' implementations (e.g., NonStop OS and NextStep) dnl do not support nested variable expansions. dnl See automake bug#9928 and bug#10237. am_make=${MAKE-make} AC_CACHE_CHECK([whether $am_make supports nested variables], [am_cv_make_support_nested_variables], [if AS_ECHO([['TRUE=$(BAR$(V)) BAR0=false BAR1=true V=1 am__doit: @$(TRUE) .PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then am_cv_make_support_nested_variables=yes else am_cv_make_support_nested_variables=no fi]) if test $am_cv_make_support_nested_variables = yes; then dnl Using '$V' instead of '$(V)' breaks IRIX make. AM_V='$(V)' AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' else AM_V=$AM_DEFAULT_VERBOSITY AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY fi AC_SUBST([AM_V])dnl AM_SUBST_NOTMAKE([AM_V])dnl AC_SUBST([AM_DEFAULT_V])dnl AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl AC_SUBST([AM_DEFAULT_VERBOSITY])dnl AM_BACKSLASH='\' AC_SUBST([AM_BACKSLASH])dnl _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl ]) # Copyright (C) 2001-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_PROG_INSTALL_STRIP # --------------------- # One issue with vendor 'install' (even GNU) is that you can't # specify the program used to strip binaries. This is especially # annoying in cross-compiling environments, where the build's strip # is unlikely to handle the host's binaries. # Fortunately install-sh will honor a STRIPPROG variable, so we # always use install-sh in "make install-strip", and initialize # STRIPPROG with the value of the STRIP variable (set by the user). AC_DEFUN([AM_PROG_INSTALL_STRIP], [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl # Installed binaries are usually stripped using 'strip' when the user # run "make install-strip". However 'strip' might not be the right # tool to use in cross-compilation environments, therefore Automake # will honor the 'STRIP' environment variable to overrule this program. dnl Don't test for $cross_compiling = yes, because it might be 'maybe'. if test "$cross_compiling" != no; then AC_CHECK_TOOL([STRIP], [strip], :) fi INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" AC_SUBST([INSTALL_STRIP_PROGRAM])]) # Copyright (C) 2006-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # _AM_SUBST_NOTMAKE(VARIABLE) # --------------------------- # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. # This macro is traced by Automake. AC_DEFUN([_AM_SUBST_NOTMAKE]) # AM_SUBST_NOTMAKE(VARIABLE) # -------------------------- # Public sister of _AM_SUBST_NOTMAKE. AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) # Check how to create a tarball. -*- Autoconf -*- # Copyright (C) 2004-2018 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # _AM_PROG_TAR(FORMAT) # -------------------- # Check how to create a tarball in format FORMAT. # FORMAT should be one of 'v7', 'ustar', or 'pax'. # # Substitute a variable $(am__tar) that is a command # writing to stdout a FORMAT-tarball containing the directory # $tardir. # tardir=directory && $(am__tar) > result.tar # # Substitute a variable $(am__untar) that extract such # a tarball read from stdin. # $(am__untar) < result.tar # AC_DEFUN([_AM_PROG_TAR], [# Always define AMTAR for backward compatibility. Yes, it's still used # in the wild :-( We should find a proper way to deprecate it ... AC_SUBST([AMTAR], ['$${TAR-tar}']) # We'll loop over all known methods to create a tar archive until one works. _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' m4_if([$1], [v7], [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'], [m4_case([$1], [ustar], [# The POSIX 1988 'ustar' format is defined with fixed-size fields. # There is notably a 21 bits limit for the UID and the GID. In fact, # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343 # and bug#13588). am_max_uid=2097151 # 2^21 - 1 am_max_gid=$am_max_uid # The $UID and $GID variables are not portable, so we need to resort # to the POSIX-mandated id(1) utility. Errors in the 'id' calls # below are definitely unexpected, so allow the users to see them # (that is, avoid stderr redirection). am_uid=`id -u || echo unknown` am_gid=`id -g || echo unknown` AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format]) if test $am_uid -le $am_max_uid; then AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) _am_tools=none fi AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format]) if test $am_gid -le $am_max_gid; then AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) _am_tools=none fi], [pax], [], [m4_fatal([Unknown tar format])]) AC_MSG_CHECKING([how to create a $1 tar archive]) # Go ahead even if we have the value already cached. We do so because we # need to set the values for the 'am__tar' and 'am__untar' variables. _am_tools=${am_cv_prog_tar_$1-$_am_tools} for _am_tool in $_am_tools; do case $_am_tool in gnutar) for _am_tar in tar gnutar gtar; do AM_RUN_LOG([$_am_tar --version]) && break done am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' am__untar="$_am_tar -xf -" ;; plaintar) # Must skip GNU tar: if it does not support --format= it doesn't create # ustar tarball either. (tar --version) >/dev/null 2>&1 && continue am__tar='tar chf - "$$tardir"' am__tar_='tar chf - "$tardir"' am__untar='tar xf -' ;; pax) am__tar='pax -L -x $1 -w "$$tardir"' am__tar_='pax -L -x $1 -w "$tardir"' am__untar='pax -r' ;; cpio) am__tar='find "$$tardir" -print | cpio -o -H $1 -L' am__tar_='find "$tardir" -print | cpio -o -H $1 -L' am__untar='cpio -i -H $1 -d' ;; none) am__tar=false am__tar_=false am__untar=false ;; esac # If the value was cached, stop now. We just wanted to have am__tar # and am__untar set. test -n "${am_cv_prog_tar_$1}" && break # tar/untar a dummy directory, and stop if the command works. rm -rf conftest.dir mkdir conftest.dir echo GrepMe > conftest.dir/file AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) rm -rf conftest.dir if test -s conftest.tar; then AM_RUN_LOG([$am__untar /dev/null 2>&1 && break fi done rm -rf conftest.dir AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) AC_MSG_RESULT([$am_cv_prog_tar_$1])]) AC_SUBST([am__tar]) AC_SUBST([am__untar]) ]) # _AM_PROG_TAR m4_include([m4/ax_cxx_compile_stdcxx.m4]) m4_include([m4/ax_cxx_compile_stdcxx_11.m4]) m4_include([m4/ax_gcc_func_attribute.m4]) m4_include([m4/boost.m4]) m4_include([m4/libtool.m4]) m4_include([m4/ltoptions.m4]) m4_include([m4/ltsugar.m4]) m4_include([m4/ltversion.m4]) m4_include([m4/lt~obsolete.m4]) libcmis-0.5.2/libcmis-c.pc.in0000664000175000017500000000052713407661560012672 00000000000000prefix=@prefix@ exec_prefix=@exec_prefix@ libdir=@libdir@ includedir=@includedir@ Name: libcmis Description: CMIS protocol C client library Version: @VERSION@ Requires: libcmis-@LIBCMIS_API_VERSION@ libxml-2.0 Requires.private: libcurl Libs: -L${libdir} -lcmis-c-@LIBCMIS_API_VERSION@ Cflags: -I${includedir}/libcmis-c-@LIBCMIS_API_VERSION@ libcmis-0.5.2/config.guess0000755000175000017500000012620613407230143012405 00000000000000#! /bin/sh # Attempt to guess a canonical system name. # Copyright 1992-2018 Free Software Foundation, Inc. timestamp='2018-03-08' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, see . # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that # program. This Exception is an additional permission under section 7 # of the GNU General Public License, version 3 ("GPLv3"). # # Originally written by Per Bothner; maintained since 2000 by Ben Elliston. # # You can get the latest version of this script from: # https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess # # Please send patches to . me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] Output the configuration name of the system \`$me' is run on. Options: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit Report bugs and patches to ." version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. Copyright 1992-2018 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" Try \`$me --help' for more information." # Parse command line while test $# -gt 0 ; do case $1 in --time-stamp | --time* | -t ) echo "$timestamp" ; exit ;; --version | -v ) echo "$version" ; exit ;; --help | --h* | -h ) echo "$usage"; exit ;; -- ) # Stop option processing shift; break ;; - ) # Use stdin as input. break ;; -* ) echo "$me: invalid option $1$help" >&2 exit 1 ;; * ) break ;; esac done if test $# != 0; then echo "$me: too many arguments$help" >&2 exit 1 fi trap 'exit 1' 1 2 15 # CC_FOR_BUILD -- compiler used by this script. Note that the use of a # compiler to aid in system detection is discouraged as it requires # temporary files to be created and, as you can see below, it is a # headache to deal with in a portable fashion. # Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still # use `HOST_CC' if defined, but it is deprecated. # Portable tmp directory creation inspired by the Autoconf team. set_cc_for_build=' trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; : ${TMPDIR=/tmp} ; { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; dummy=$tmp/dummy ; tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; case $CC_FOR_BUILD,$HOST_CC,$CC in ,,) echo "int x;" > "$dummy.c" ; for c in cc gcc c89 c99 ; do if ($c -c -o "$dummy.o" "$dummy.c") >/dev/null 2>&1 ; then CC_FOR_BUILD="$c"; break ; fi ; done ; if test x"$CC_FOR_BUILD" = x ; then CC_FOR_BUILD=no_compiler_found ; fi ;; ,,*) CC_FOR_BUILD=$CC ;; ,*,*) CC_FOR_BUILD=$HOST_CC ;; esac ; set_cc_for_build= ;' # This is needed to find uname on a Pyramid OSx when run in the BSD universe. # (ghazi@noc.rutgers.edu 1994-08-24) if (test -f /.attbin/uname) >/dev/null 2>&1 ; then PATH=$PATH:/.attbin ; export PATH fi UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown case "$UNAME_SYSTEM" in Linux|GNU|GNU/*) # If the system lacks a compiler, then just pick glibc. # We could probably try harder. LIBC=gnu eval "$set_cc_for_build" cat <<-EOF > "$dummy.c" #include #if defined(__UCLIBC__) LIBC=uclibc #elif defined(__dietlibc__) LIBC=dietlibc #else LIBC=gnu #endif EOF eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^LIBC' | sed 's, ,,g'`" # If ldd exists, use it to detect musl libc. if command -v ldd >/dev/null && \ ldd --version 2>&1 | grep -q ^musl then LIBC=musl fi ;; esac # Note: order is significant - the case branches are not exclusive. case "$UNAME_MACHINE:$UNAME_SYSTEM:$UNAME_RELEASE:$UNAME_VERSION" in *:NetBSD:*:*) # NetBSD (nbsd) targets should (where applicable) match one or # more of the tuples: *-*-netbsdelf*, *-*-netbsdaout*, # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently # switched to ELF, *-*-netbsd* would select the old # object file format. This provides both forward # compatibility and a consistent mechanism for selecting the # object file format. # # Note: NetBSD doesn't particularly care about the vendor # portion of the name. We always set it to "unknown". sysctl="sysctl -n hw.machine_arch" UNAME_MACHINE_ARCH=`(uname -p 2>/dev/null || \ "/sbin/$sysctl" 2>/dev/null || \ "/usr/sbin/$sysctl" 2>/dev/null || \ echo unknown)` case "$UNAME_MACHINE_ARCH" in armeb) machine=armeb-unknown ;; arm*) machine=arm-unknown ;; sh3el) machine=shl-unknown ;; sh3eb) machine=sh-unknown ;; sh5el) machine=sh5le-unknown ;; earmv*) arch=`echo "$UNAME_MACHINE_ARCH" | sed -e 's,^e\(armv[0-9]\).*$,\1,'` endian=`echo "$UNAME_MACHINE_ARCH" | sed -ne 's,^.*\(eb\)$,\1,p'` machine="${arch}${endian}"-unknown ;; *) machine="$UNAME_MACHINE_ARCH"-unknown ;; esac # The Operating System including object format, if it has switched # to ELF recently (or will in the future) and ABI. case "$UNAME_MACHINE_ARCH" in earm*) os=netbsdelf ;; arm*|i386|m68k|ns32k|sh3*|sparc|vax) eval "$set_cc_for_build" if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ELF__ then # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). # Return netbsd for either. FIX? os=netbsd else os=netbsdelf fi ;; *) os=netbsd ;; esac # Determine ABI tags. case "$UNAME_MACHINE_ARCH" in earm*) expr='s/^earmv[0-9]/-eabi/;s/eb$//' abi=`echo "$UNAME_MACHINE_ARCH" | sed -e "$expr"` ;; esac # The OS release # Debian GNU/NetBSD machines have a different userland, and # thus, need a distinct triplet. However, they do not need # kernel version information, so it can be replaced with a # suitable tag, in the style of linux-gnu. case "$UNAME_VERSION" in Debian*) release='-gnu' ;; *) release=`echo "$UNAME_RELEASE" | sed -e 's/[-_].*//' | cut -d. -f1,2` ;; esac # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: # contains redundant information, the shorter form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. echo "$machine-${os}${release}${abi}" exit ;; *:Bitrig:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/Bitrig.//'` echo "$UNAME_MACHINE_ARCH"-unknown-bitrig"$UNAME_RELEASE" exit ;; *:OpenBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` echo "$UNAME_MACHINE_ARCH"-unknown-openbsd"$UNAME_RELEASE" exit ;; *:LibertyBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/^.*BSD\.//'` echo "$UNAME_MACHINE_ARCH"-unknown-libertybsd"$UNAME_RELEASE" exit ;; *:MidnightBSD:*:*) echo "$UNAME_MACHINE"-unknown-midnightbsd"$UNAME_RELEASE" exit ;; *:ekkoBSD:*:*) echo "$UNAME_MACHINE"-unknown-ekkobsd"$UNAME_RELEASE" exit ;; *:SolidBSD:*:*) echo "$UNAME_MACHINE"-unknown-solidbsd"$UNAME_RELEASE" exit ;; macppc:MirBSD:*:*) echo powerpc-unknown-mirbsd"$UNAME_RELEASE" exit ;; *:MirBSD:*:*) echo "$UNAME_MACHINE"-unknown-mirbsd"$UNAME_RELEASE" exit ;; *:Sortix:*:*) echo "$UNAME_MACHINE"-unknown-sortix exit ;; *:Redox:*:*) echo "$UNAME_MACHINE"-unknown-redox exit ;; mips:OSF1:*.*) echo mips-dec-osf1 exit ;; alpha:OSF1:*:*) case $UNAME_RELEASE in *4.0) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` ;; *5.*) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` ;; esac # According to Compaq, /usr/sbin/psrinfo has been available on # OSF/1 and Tru64 systems produced since 1995. I hope that # covers most systems running today. This code pipes the CPU # types through head -n 1, so we only detect the type of CPU 0. ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` case "$ALPHA_CPU_TYPE" in "EV4 (21064)") UNAME_MACHINE=alpha ;; "EV4.5 (21064)") UNAME_MACHINE=alpha ;; "LCA4 (21066/21068)") UNAME_MACHINE=alpha ;; "EV5 (21164)") UNAME_MACHINE=alphaev5 ;; "EV5.6 (21164A)") UNAME_MACHINE=alphaev56 ;; "EV5.6 (21164PC)") UNAME_MACHINE=alphapca56 ;; "EV5.7 (21164PC)") UNAME_MACHINE=alphapca57 ;; "EV6 (21264)") UNAME_MACHINE=alphaev6 ;; "EV6.7 (21264A)") UNAME_MACHINE=alphaev67 ;; "EV6.8CB (21264C)") UNAME_MACHINE=alphaev68 ;; "EV6.8AL (21264B)") UNAME_MACHINE=alphaev68 ;; "EV6.8CX (21264D)") UNAME_MACHINE=alphaev68 ;; "EV6.9A (21264/EV69A)") UNAME_MACHINE=alphaev69 ;; "EV7 (21364)") UNAME_MACHINE=alphaev7 ;; "EV7.9 (21364A)") UNAME_MACHINE=alphaev79 ;; esac # A Pn.n version is a patched version. # A Vn.n version is a released version. # A Tn.n version is a released field test version. # A Xn.n version is an unreleased experimental baselevel. # 1.2 uses "1.2" for uname -r. echo "$UNAME_MACHINE"-dec-osf"`echo "$UNAME_RELEASE" | sed -e 's/^[PVTX]//' | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz`" # Reset EXIT trap before exiting to avoid spurious non-zero exit code. exitcode=$? trap '' 0 exit $exitcode ;; Amiga*:UNIX_System_V:4.0:*) echo m68k-unknown-sysv4 exit ;; *:[Aa]miga[Oo][Ss]:*:*) echo "$UNAME_MACHINE"-unknown-amigaos exit ;; *:[Mm]orph[Oo][Ss]:*:*) echo "$UNAME_MACHINE"-unknown-morphos exit ;; *:OS/390:*:*) echo i370-ibm-openedition exit ;; *:z/VM:*:*) echo s390-ibm-zvmoe exit ;; *:OS400:*:*) echo powerpc-ibm-os400 exit ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) echo arm-acorn-riscix"$UNAME_RELEASE" exit ;; arm*:riscos:*:*|arm*:RISCOS:*:*) echo arm-unknown-riscos exit ;; SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) echo hppa1.1-hitachi-hiuxmpp exit ;; Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. if test "`(/bin/universe) 2>/dev/null`" = att ; then echo pyramid-pyramid-sysv3 else echo pyramid-pyramid-bsd fi exit ;; NILE*:*:*:dcosx) echo pyramid-pyramid-svr4 exit ;; DRS?6000:unix:4.0:6*) echo sparc-icl-nx6 exit ;; DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) case `/usr/bin/uname -p` in sparc) echo sparc-icl-nx7; exit ;; esac ;; s390x:SunOS:*:*) echo "$UNAME_MACHINE"-ibm-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`" exit ;; sun4H:SunOS:5.*:*) echo sparc-hal-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" exit ;; sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) echo sparc-sun-solaris2"`echo "$UNAME_RELEASE" | sed -e 's/[^.]*//'`" exit ;; i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) echo i386-pc-auroraux"$UNAME_RELEASE" exit ;; i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) eval "$set_cc_for_build" SUN_ARCH=i386 # If there is a compiler, see if it is configured for 64-bit objects. # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. # This test works for both compilers. if [ "$CC_FOR_BUILD" != no_compiler_found ]; then if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ grep IS_64BIT_ARCH >/dev/null then SUN_ARCH=x86_64 fi fi echo "$SUN_ARCH"-pc-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" exit ;; sun4*:SunOS:6*:*) # According to config.sub, this is the proper way to canonicalize # SunOS6. Hard to guess exactly what SunOS6 will be like, but # it's likely to be more like Solaris than SunOS4. echo sparc-sun-solaris3"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" exit ;; sun4*:SunOS:*:*) case "`/usr/bin/arch -k`" in Series*|S4*) UNAME_RELEASE=`uname -v` ;; esac # Japanese Language versions have a version number like `4.1.3-JL'. echo sparc-sun-sunos"`echo "$UNAME_RELEASE"|sed -e 's/-/_/'`" exit ;; sun3*:SunOS:*:*) echo m68k-sun-sunos"$UNAME_RELEASE" exit ;; sun*:*:4.2BSD:*) UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` test "x$UNAME_RELEASE" = x && UNAME_RELEASE=3 case "`/bin/arch`" in sun3) echo m68k-sun-sunos"$UNAME_RELEASE" ;; sun4) echo sparc-sun-sunos"$UNAME_RELEASE" ;; esac exit ;; aushp:SunOS:*:*) echo sparc-auspex-sunos"$UNAME_RELEASE" exit ;; # The situation for MiNT is a little confusing. The machine name # can be virtually everything (everything which is not # "atarist" or "atariste" at least should have a processor # > m68000). The system name ranges from "MiNT" over "FreeMiNT" # to the lowercase version "mint" (or "freemint"). Finally # the system name "TOS" denotes a system which is actually not # MiNT. But MiNT is downward compatible to TOS, so this should # be no problem. atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) echo m68k-atari-mint"$UNAME_RELEASE" exit ;; atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) echo m68k-atari-mint"$UNAME_RELEASE" exit ;; *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) echo m68k-atari-mint"$UNAME_RELEASE" exit ;; milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) echo m68k-milan-mint"$UNAME_RELEASE" exit ;; hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) echo m68k-hades-mint"$UNAME_RELEASE" exit ;; *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) echo m68k-unknown-mint"$UNAME_RELEASE" exit ;; m68k:machten:*:*) echo m68k-apple-machten"$UNAME_RELEASE" exit ;; powerpc:machten:*:*) echo powerpc-apple-machten"$UNAME_RELEASE" exit ;; RISC*:Mach:*:*) echo mips-dec-mach_bsd4.3 exit ;; RISC*:ULTRIX:*:*) echo mips-dec-ultrix"$UNAME_RELEASE" exit ;; VAX*:ULTRIX*:*:*) echo vax-dec-ultrix"$UNAME_RELEASE" exit ;; 2020:CLIX:*:* | 2430:CLIX:*:*) echo clipper-intergraph-clix"$UNAME_RELEASE" exit ;; mips:*:*:UMIPS | mips:*:*:RISCos) eval "$set_cc_for_build" sed 's/^ //' << EOF > "$dummy.c" #ifdef __cplusplus #include /* for printf() prototype */ int main (int argc, char *argv[]) { #else int main (argc, argv) int argc; char *argv[]; { #endif #if defined (host_mips) && defined (MIPSEB) #if defined (SYSTYPE_SYSV) printf ("mips-mips-riscos%ssysv\\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_SVR4) printf ("mips-mips-riscos%ssvr4\\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) printf ("mips-mips-riscos%sbsd\\n", argv[1]); exit (0); #endif #endif exit (-1); } EOF $CC_FOR_BUILD -o "$dummy" "$dummy.c" && dummyarg=`echo "$UNAME_RELEASE" | sed -n 's/\([0-9]*\).*/\1/p'` && SYSTEM_NAME=`"$dummy" "$dummyarg"` && { echo "$SYSTEM_NAME"; exit; } echo mips-mips-riscos"$UNAME_RELEASE" exit ;; Motorola:PowerMAX_OS:*:*) echo powerpc-motorola-powermax exit ;; Motorola:*:4.3:PL8-*) echo powerpc-harris-powermax exit ;; Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) echo powerpc-harris-powermax exit ;; Night_Hawk:Power_UNIX:*:*) echo powerpc-harris-powerunix exit ;; m88k:CX/UX:7*:*) echo m88k-harris-cxux7 exit ;; m88k:*:4*:R4*) echo m88k-motorola-sysv4 exit ;; m88k:*:3*:R3*) echo m88k-motorola-sysv3 exit ;; AViiON:dgux:*:*) # DG/UX returns AViiON for all architectures UNAME_PROCESSOR=`/usr/bin/uname -p` if [ "$UNAME_PROCESSOR" = mc88100 ] || [ "$UNAME_PROCESSOR" = mc88110 ] then if [ "$TARGET_BINARY_INTERFACE"x = m88kdguxelfx ] || \ [ "$TARGET_BINARY_INTERFACE"x = x ] then echo m88k-dg-dgux"$UNAME_RELEASE" else echo m88k-dg-dguxbcs"$UNAME_RELEASE" fi else echo i586-dg-dgux"$UNAME_RELEASE" fi exit ;; M88*:DolphinOS:*:*) # DolphinOS (SVR3) echo m88k-dolphin-sysv3 exit ;; M88*:*:R3*:*) # Delta 88k system running SVR3 echo m88k-motorola-sysv3 exit ;; XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) echo m88k-tektronix-sysv3 exit ;; Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) echo m68k-tektronix-bsd exit ;; *:IRIX*:*:*) echo mips-sgi-irix"`echo "$UNAME_RELEASE"|sed -e 's/-/_/g'`" exit ;; ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id exit ;; # Note that: echo "'`uname -s`'" gives 'AIX ' i*86:AIX:*:*) echo i386-ibm-aix exit ;; ia64:AIX:*:*) if [ -x /usr/bin/oslevel ] ; then IBM_REV=`/usr/bin/oslevel` else IBM_REV="$UNAME_VERSION.$UNAME_RELEASE" fi echo "$UNAME_MACHINE"-ibm-aix"$IBM_REV" exit ;; *:AIX:2:3) if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then eval "$set_cc_for_build" sed 's/^ //' << EOF > "$dummy.c" #include main() { if (!__power_pc()) exit(1); puts("powerpc-ibm-aix3.2.5"); exit(0); } EOF if $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` then echo "$SYSTEM_NAME" else echo rs6000-ibm-aix3.2.5 fi elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then echo rs6000-ibm-aix3.2.4 else echo rs6000-ibm-aix3.2 fi exit ;; *:AIX:*:[4567]) IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` if /usr/sbin/lsattr -El "$IBM_CPU_ID" | grep ' POWER' >/dev/null 2>&1; then IBM_ARCH=rs6000 else IBM_ARCH=powerpc fi if [ -x /usr/bin/lslpp ] ; then IBM_REV=`/usr/bin/lslpp -Lqc bos.rte.libc | awk -F: '{ print $3 }' | sed s/[0-9]*$/0/` else IBM_REV="$UNAME_VERSION.$UNAME_RELEASE" fi echo "$IBM_ARCH"-ibm-aix"$IBM_REV" exit ;; *:AIX:*:*) echo rs6000-ibm-aix exit ;; ibmrt:4.4BSD:*|romp-ibm:4.4BSD:*) echo romp-ibm-bsd4.4 exit ;; ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and echo romp-ibm-bsd"$UNAME_RELEASE" # 4.3 with uname added to exit ;; # report: romp-ibm BSD 4.3 *:BOSX:*:*) echo rs6000-bull-bosx exit ;; DPX/2?00:B.O.S.:*:*) echo m68k-bull-sysv3 exit ;; 9000/[34]??:4.3bsd:1.*:*) echo m68k-hp-bsd exit ;; hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) echo m68k-hp-bsd4.4 exit ;; 9000/[34678]??:HP-UX:*:*) HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'` case "$UNAME_MACHINE" in 9000/31?) HP_ARCH=m68000 ;; 9000/[34]??) HP_ARCH=m68k ;; 9000/[678][0-9][0-9]) if [ -x /usr/bin/getconf ]; then sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` case "$sc_cpu_version" in 523) HP_ARCH=hppa1.0 ;; # CPU_PA_RISC1_0 528) HP_ARCH=hppa1.1 ;; # CPU_PA_RISC1_1 532) # CPU_PA_RISC2_0 case "$sc_kernel_bits" in 32) HP_ARCH=hppa2.0n ;; 64) HP_ARCH=hppa2.0w ;; '') HP_ARCH=hppa2.0 ;; # HP-UX 10.20 esac ;; esac fi if [ "$HP_ARCH" = "" ]; then eval "$set_cc_for_build" sed 's/^ //' << EOF > "$dummy.c" #define _HPUX_SOURCE #include #include int main () { #if defined(_SC_KERNEL_BITS) long bits = sysconf(_SC_KERNEL_BITS); #endif long cpu = sysconf (_SC_CPU_VERSION); switch (cpu) { case CPU_PA_RISC1_0: puts ("hppa1.0"); break; case CPU_PA_RISC1_1: puts ("hppa1.1"); break; case CPU_PA_RISC2_0: #if defined(_SC_KERNEL_BITS) switch (bits) { case 64: puts ("hppa2.0w"); break; case 32: puts ("hppa2.0n"); break; default: puts ("hppa2.0"); break; } break; #else /* !defined(_SC_KERNEL_BITS) */ puts ("hppa2.0"); break; #endif default: puts ("hppa1.0"); break; } exit (0); } EOF (CCOPTS="" $CC_FOR_BUILD -o "$dummy" "$dummy.c" 2>/dev/null) && HP_ARCH=`"$dummy"` test -z "$HP_ARCH" && HP_ARCH=hppa fi ;; esac if [ "$HP_ARCH" = hppa2.0w ] then eval "$set_cc_for_build" # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler # generating 64-bit code. GNU and HP use different nomenclature: # # $ CC_FOR_BUILD=cc ./config.guess # => hppa2.0w-hp-hpux11.23 # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess # => hppa64-hp-hpux11.23 if echo __LP64__ | (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | grep -q __LP64__ then HP_ARCH=hppa2.0w else HP_ARCH=hppa64 fi fi echo "$HP_ARCH"-hp-hpux"$HPUX_REV" exit ;; ia64:HP-UX:*:*) HPUX_REV=`echo "$UNAME_RELEASE"|sed -e 's/[^.]*.[0B]*//'` echo ia64-hp-hpux"$HPUX_REV" exit ;; 3050*:HI-UX:*:*) eval "$set_cc_for_build" sed 's/^ //' << EOF > "$dummy.c" #include int main () { long cpu = sysconf (_SC_CPU_VERSION); /* The order matters, because CPU_IS_HP_MC68K erroneously returns true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct results, however. */ if (CPU_IS_PA_RISC (cpu)) { switch (cpu) { case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break; case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break; case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break; default: puts ("hppa-hitachi-hiuxwe2"); break; } } else if (CPU_IS_HP_MC68K (cpu)) puts ("m68k-hitachi-hiuxwe2"); else puts ("unknown-hitachi-hiuxwe2"); exit (0); } EOF $CC_FOR_BUILD -o "$dummy" "$dummy.c" && SYSTEM_NAME=`"$dummy"` && { echo "$SYSTEM_NAME"; exit; } echo unknown-hitachi-hiuxwe2 exit ;; 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:*) echo hppa1.1-hp-bsd exit ;; 9000/8??:4.3bsd:*:*) echo hppa1.0-hp-bsd exit ;; *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) echo hppa1.0-hp-mpeix exit ;; hp7??:OSF1:*:* | hp8?[79]:OSF1:*:*) echo hppa1.1-hp-osf exit ;; hp8??:OSF1:*:*) echo hppa1.0-hp-osf exit ;; i*86:OSF1:*:*) if [ -x /usr/sbin/sysversion ] ; then echo "$UNAME_MACHINE"-unknown-osf1mk else echo "$UNAME_MACHINE"-unknown-osf1 fi exit ;; parisc*:Lites*:*:*) echo hppa1.1-hp-lites exit ;; C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) echo c1-convex-bsd exit ;; C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) if getsysinfo -f scalar_acc then echo c32-convex-bsd else echo c2-convex-bsd fi exit ;; C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) echo c34-convex-bsd exit ;; C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) echo c38-convex-bsd exit ;; C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) echo c4-convex-bsd exit ;; CRAY*Y-MP:*:*:*) echo ymp-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*[A-Z]90:*:*:*) echo "$UNAME_MACHINE"-cray-unicos"$UNAME_RELEASE" \ | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ -e 's/\.[^.]*$/.X/' exit ;; CRAY*TS:*:*:*) echo t90-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*T3E:*:*:*) echo alphaev5-cray-unicosmk"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*SV1:*:*:*) echo sv1-cray-unicos"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' exit ;; *:UNICOS/mp:*:*) echo craynv-cray-unicosmp"$UNAME_RELEASE" | sed -e 's/\.[^.]*$/.X/' exit ;; F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) FUJITSU_PROC=`uname -m | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz` FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'` FUJITSU_REL=`echo "$UNAME_RELEASE" | sed -e 's/ /_/'` echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit ;; 5000:UNIX_System_V:4.*:*) FUJITSU_SYS=`uname -p | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/\///'` FUJITSU_REL=`echo "$UNAME_RELEASE" | tr ABCDEFGHIJKLMNOPQRSTUVWXYZ abcdefghijklmnopqrstuvwxyz | sed -e 's/ /_/'` echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit ;; i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) echo "$UNAME_MACHINE"-pc-bsdi"$UNAME_RELEASE" exit ;; sparc*:BSD/OS:*:*) echo sparc-unknown-bsdi"$UNAME_RELEASE" exit ;; *:BSD/OS:*:*) echo "$UNAME_MACHINE"-unknown-bsdi"$UNAME_RELEASE" exit ;; *:FreeBSD:*:*) UNAME_PROCESSOR=`/usr/bin/uname -p` case "$UNAME_PROCESSOR" in amd64) UNAME_PROCESSOR=x86_64 ;; i386) UNAME_PROCESSOR=i586 ;; esac echo "$UNAME_PROCESSOR"-unknown-freebsd"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`" exit ;; i*:CYGWIN*:*) echo "$UNAME_MACHINE"-pc-cygwin exit ;; *:MINGW64*:*) echo "$UNAME_MACHINE"-pc-mingw64 exit ;; *:MINGW*:*) echo "$UNAME_MACHINE"-pc-mingw32 exit ;; *:MSYS*:*) echo "$UNAME_MACHINE"-pc-msys exit ;; i*:PW*:*) echo "$UNAME_MACHINE"-pc-pw32 exit ;; *:Interix*:*) case "$UNAME_MACHINE" in x86) echo i586-pc-interix"$UNAME_RELEASE" exit ;; authenticamd | genuineintel | EM64T) echo x86_64-unknown-interix"$UNAME_RELEASE" exit ;; IA64) echo ia64-unknown-interix"$UNAME_RELEASE" exit ;; esac ;; i*:UWIN*:*) echo "$UNAME_MACHINE"-pc-uwin exit ;; amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) echo x86_64-unknown-cygwin exit ;; prep*:SunOS:5.*:*) echo powerpcle-unknown-solaris2"`echo "$UNAME_RELEASE"|sed -e 's/[^.]*//'`" exit ;; *:GNU:*:*) # the GNU system echo "`echo "$UNAME_MACHINE"|sed -e 's,[-/].*$,,'`-unknown-$LIBC`echo "$UNAME_RELEASE"|sed -e 's,/.*$,,'`" exit ;; *:GNU/*:*:*) # other systems with GNU libc and userland echo "$UNAME_MACHINE-unknown-`echo "$UNAME_SYSTEM" | sed 's,^[^/]*/,,' | tr "[:upper:]" "[:lower:]"``echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`-$LIBC" exit ;; i*86:Minix:*:*) echo "$UNAME_MACHINE"-pc-minix exit ;; aarch64:Linux:*:*) echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; aarch64_be:Linux:*:*) UNAME_MACHINE=aarch64_be echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; alpha:Linux:*:*) case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in EV5) UNAME_MACHINE=alphaev5 ;; EV56) UNAME_MACHINE=alphaev56 ;; PCA56) UNAME_MACHINE=alphapca56 ;; PCA57) UNAME_MACHINE=alphapca56 ;; EV6) UNAME_MACHINE=alphaev6 ;; EV67) UNAME_MACHINE=alphaev67 ;; EV68*) UNAME_MACHINE=alphaev68 ;; esac objdump --private-headers /bin/sh | grep -q ld.so.1 if test "$?" = 0 ; then LIBC=gnulibc1 ; fi echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; arc:Linux:*:* | arceb:Linux:*:*) echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; arm*:Linux:*:*) eval "$set_cc_for_build" if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_EABI__ then echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" else if echo __ARM_PCS_VFP | $CC_FOR_BUILD -E - 2>/dev/null \ | grep -q __ARM_PCS_VFP then echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"eabi else echo "$UNAME_MACHINE"-unknown-linux-"$LIBC"eabihf fi fi exit ;; avr32*:Linux:*:*) echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; cris:Linux:*:*) echo "$UNAME_MACHINE"-axis-linux-"$LIBC" exit ;; crisv32:Linux:*:*) echo "$UNAME_MACHINE"-axis-linux-"$LIBC" exit ;; e2k:Linux:*:*) echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; frv:Linux:*:*) echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; hexagon:Linux:*:*) echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; i*86:Linux:*:*) echo "$UNAME_MACHINE"-pc-linux-"$LIBC" exit ;; ia64:Linux:*:*) echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; k1om:Linux:*:*) echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; m32r*:Linux:*:*) echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; m68*:Linux:*:*) echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; mips:Linux:*:* | mips64:Linux:*:*) eval "$set_cc_for_build" sed 's/^ //' << EOF > "$dummy.c" #undef CPU #undef ${UNAME_MACHINE} #undef ${UNAME_MACHINE}el #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) CPU=${UNAME_MACHINE}el #else #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) CPU=${UNAME_MACHINE} #else CPU= #endif #endif EOF eval "`$CC_FOR_BUILD -E "$dummy.c" 2>/dev/null | grep '^CPU'`" test "x$CPU" != x && { echo "$CPU-unknown-linux-$LIBC"; exit; } ;; mips64el:Linux:*:*) echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; openrisc*:Linux:*:*) echo or1k-unknown-linux-"$LIBC" exit ;; or32:Linux:*:* | or1k*:Linux:*:*) echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; padre:Linux:*:*) echo sparc-unknown-linux-"$LIBC" exit ;; parisc64:Linux:*:* | hppa64:Linux:*:*) echo hppa64-unknown-linux-"$LIBC" exit ;; parisc:Linux:*:* | hppa:Linux:*:*) # Look for CPU level case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in PA7*) echo hppa1.1-unknown-linux-"$LIBC" ;; PA8*) echo hppa2.0-unknown-linux-"$LIBC" ;; *) echo hppa-unknown-linux-"$LIBC" ;; esac exit ;; ppc64:Linux:*:*) echo powerpc64-unknown-linux-"$LIBC" exit ;; ppc:Linux:*:*) echo powerpc-unknown-linux-"$LIBC" exit ;; ppc64le:Linux:*:*) echo powerpc64le-unknown-linux-"$LIBC" exit ;; ppcle:Linux:*:*) echo powerpcle-unknown-linux-"$LIBC" exit ;; riscv32:Linux:*:* | riscv64:Linux:*:*) echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; s390:Linux:*:* | s390x:Linux:*:*) echo "$UNAME_MACHINE"-ibm-linux-"$LIBC" exit ;; sh64*:Linux:*:*) echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; sh*:Linux:*:*) echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; sparc:Linux:*:* | sparc64:Linux:*:*) echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; tile*:Linux:*:*) echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; vax:Linux:*:*) echo "$UNAME_MACHINE"-dec-linux-"$LIBC" exit ;; x86_64:Linux:*:*) echo "$UNAME_MACHINE"-pc-linux-"$LIBC" exit ;; xtensa*:Linux:*:*) echo "$UNAME_MACHINE"-unknown-linux-"$LIBC" exit ;; i*86:DYNIX/ptx:4*:*) # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. # earlier versions are messed up and put the nodename in both # sysname and nodename. echo i386-sequent-sysv4 exit ;; i*86:UNIX_SV:4.2MP:2.*) # Unixware is an offshoot of SVR4, but it has its own version # number series starting with 2... # I am not positive that other SVR4 systems won't match this, # I just have to hope. -- rms. # Use sysv4.2uw... so that sysv4* matches it. echo "$UNAME_MACHINE"-pc-sysv4.2uw"$UNAME_VERSION" exit ;; i*86:OS/2:*:*) # If we were able to find `uname', then EMX Unix compatibility # is probably installed. echo "$UNAME_MACHINE"-pc-os2-emx exit ;; i*86:XTS-300:*:STOP) echo "$UNAME_MACHINE"-unknown-stop exit ;; i*86:atheos:*:*) echo "$UNAME_MACHINE"-unknown-atheos exit ;; i*86:syllable:*:*) echo "$UNAME_MACHINE"-pc-syllable exit ;; i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) echo i386-unknown-lynxos"$UNAME_RELEASE" exit ;; i*86:*DOS:*:*) echo "$UNAME_MACHINE"-pc-msdosdjgpp exit ;; i*86:*:4.*:*) UNAME_REL=`echo "$UNAME_RELEASE" | sed 's/\/MP$//'` if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then echo "$UNAME_MACHINE"-univel-sysv"$UNAME_REL" else echo "$UNAME_MACHINE"-pc-sysv"$UNAME_REL" fi exit ;; i*86:*:5:[678]*) # UnixWare 7.x, OpenUNIX and OpenServer 6. case `/bin/uname -X | grep "^Machine"` in *486*) UNAME_MACHINE=i486 ;; *Pentium) UNAME_MACHINE=i586 ;; *Pent*|*Celeron) UNAME_MACHINE=i686 ;; esac echo "$UNAME_MACHINE-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}{$UNAME_VERSION}" exit ;; i*86:*:3.2:*) if test -f /usr/options/cb.name; then UNAME_REL=`sed -n 's/.*Version //p' /dev/null >/dev/null ; then UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \ && UNAME_MACHINE=i586 (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \ && UNAME_MACHINE=i686 (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ && UNAME_MACHINE=i686 echo "$UNAME_MACHINE"-pc-sco"$UNAME_REL" else echo "$UNAME_MACHINE"-pc-sysv32 fi exit ;; pc:*:*:*) # Left here for compatibility: # uname -m prints for DJGPP always 'pc', but it prints nothing about # the processor, so we play safe by assuming i586. # Note: whatever this is, it MUST be the same as what config.sub # prints for the "djgpp" host, or else GDB configure will decide that # this is a cross-build. echo i586-pc-msdosdjgpp exit ;; Intel:Mach:3*:*) echo i386-pc-mach3 exit ;; paragon:*:*:*) echo i860-intel-osf1 exit ;; i860:*:4.*:*) # i860-SVR4 if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then echo i860-stardent-sysv"$UNAME_RELEASE" # Stardent Vistra i860-SVR4 else # Add other i860-SVR4 vendors below as they are discovered. echo i860-unknown-sysv"$UNAME_RELEASE" # Unknown i860-SVR4 fi exit ;; mini*:CTIX:SYS*5:*) # "miniframe" echo m68010-convergent-sysv exit ;; mc68k:UNIX:SYSTEM5:3.51m) echo m68k-convergent-sysv exit ;; M680?0:D-NIX:5.3:*) echo m68k-diab-dnix exit ;; M68*:*:R3V[5678]*:*) test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;; 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0) OS_REL='' test -r /etc/.relid \ && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4.3"$OS_REL"; exit; } /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;; 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4; exit; } ;; NCR*:*:4.2:* | MPRAS*:*:4.2:*) OS_REL='.3' test -r /etc/.relid \ && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4.3"$OS_REL"; exit; } /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ && { echo i586-ncr-sysv4.3"$OS_REL"; exit; } ;; m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) echo m68k-unknown-lynxos"$UNAME_RELEASE" exit ;; mc68030:UNIX_System_V:4.*:*) echo m68k-atari-sysv4 exit ;; TSUNAMI:LynxOS:2.*:*) echo sparc-unknown-lynxos"$UNAME_RELEASE" exit ;; rs6000:LynxOS:2.*:*) echo rs6000-unknown-lynxos"$UNAME_RELEASE" exit ;; PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) echo powerpc-unknown-lynxos"$UNAME_RELEASE" exit ;; SM[BE]S:UNIX_SV:*:*) echo mips-dde-sysv"$UNAME_RELEASE" exit ;; RM*:ReliantUNIX-*:*:*) echo mips-sni-sysv4 exit ;; RM*:SINIX-*:*:*) echo mips-sni-sysv4 exit ;; *:SINIX-*:*:*) if uname -p 2>/dev/null >/dev/null ; then UNAME_MACHINE=`(uname -p) 2>/dev/null` echo "$UNAME_MACHINE"-sni-sysv4 else echo ns32k-sni-sysv fi exit ;; PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort # says echo i586-unisys-sysv4 exit ;; *:UNIX_System_V:4*:FTX*) # From Gerald Hewes . # How about differentiating between stratus architectures? -djm echo hppa1.1-stratus-sysv4 exit ;; *:*:*:FTX*) # From seanf@swdc.stratus.com. echo i860-stratus-sysv4 exit ;; i*86:VOS:*:*) # From Paul.Green@stratus.com. echo "$UNAME_MACHINE"-stratus-vos exit ;; *:VOS:*:*) # From Paul.Green@stratus.com. echo hppa1.1-stratus-vos exit ;; mc68*:A/UX:*:*) echo m68k-apple-aux"$UNAME_RELEASE" exit ;; news*:NEWS-OS:6*:*) echo mips-sony-newsos6 exit ;; R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) if [ -d /usr/nec ]; then echo mips-nec-sysv"$UNAME_RELEASE" else echo mips-unknown-sysv"$UNAME_RELEASE" fi exit ;; BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. echo powerpc-be-beos exit ;; BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. echo powerpc-apple-beos exit ;; BePC:BeOS:*:*) # BeOS running on Intel PC compatible. echo i586-pc-beos exit ;; BePC:Haiku:*:*) # Haiku running on Intel PC compatible. echo i586-pc-haiku exit ;; x86_64:Haiku:*:*) echo x86_64-unknown-haiku exit ;; SX-4:SUPER-UX:*:*) echo sx4-nec-superux"$UNAME_RELEASE" exit ;; SX-5:SUPER-UX:*:*) echo sx5-nec-superux"$UNAME_RELEASE" exit ;; SX-6:SUPER-UX:*:*) echo sx6-nec-superux"$UNAME_RELEASE" exit ;; SX-7:SUPER-UX:*:*) echo sx7-nec-superux"$UNAME_RELEASE" exit ;; SX-8:SUPER-UX:*:*) echo sx8-nec-superux"$UNAME_RELEASE" exit ;; SX-8R:SUPER-UX:*:*) echo sx8r-nec-superux"$UNAME_RELEASE" exit ;; SX-ACE:SUPER-UX:*:*) echo sxace-nec-superux"$UNAME_RELEASE" exit ;; Power*:Rhapsody:*:*) echo powerpc-apple-rhapsody"$UNAME_RELEASE" exit ;; *:Rhapsody:*:*) echo "$UNAME_MACHINE"-apple-rhapsody"$UNAME_RELEASE" exit ;; *:Darwin:*:*) UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown eval "$set_cc_for_build" if test "$UNAME_PROCESSOR" = unknown ; then UNAME_PROCESSOR=powerpc fi if test "`echo "$UNAME_RELEASE" | sed -e 's/\..*//'`" -le 10 ; then if [ "$CC_FOR_BUILD" != no_compiler_found ]; then if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ grep IS_64BIT_ARCH >/dev/null then case $UNAME_PROCESSOR in i386) UNAME_PROCESSOR=x86_64 ;; powerpc) UNAME_PROCESSOR=powerpc64 ;; esac fi # On 10.4-10.6 one might compile for PowerPC via gcc -arch ppc if (echo '#ifdef __POWERPC__'; echo IS_PPC; echo '#endif') | \ (CCOPTS="" $CC_FOR_BUILD -E - 2>/dev/null) | \ grep IS_PPC >/dev/null then UNAME_PROCESSOR=powerpc fi fi elif test "$UNAME_PROCESSOR" = i386 ; then # Avoid executing cc on OS X 10.9, as it ships with a stub # that puts up a graphical alert prompting to install # developer tools. Any system running Mac OS X 10.7 or # later (Darwin 11 and later) is required to have a 64-bit # processor. This is not true of the ARM version of Darwin # that Apple uses in portable devices. UNAME_PROCESSOR=x86_64 fi echo "$UNAME_PROCESSOR"-apple-darwin"$UNAME_RELEASE" exit ;; *:procnto*:*:* | *:QNX:[0123456789]*:*) UNAME_PROCESSOR=`uname -p` if test "$UNAME_PROCESSOR" = x86; then UNAME_PROCESSOR=i386 UNAME_MACHINE=pc fi echo "$UNAME_PROCESSOR"-"$UNAME_MACHINE"-nto-qnx"$UNAME_RELEASE" exit ;; *:QNX:*:4*) echo i386-pc-qnx exit ;; NEO-*:NONSTOP_KERNEL:*:*) echo neo-tandem-nsk"$UNAME_RELEASE" exit ;; NSE-*:NONSTOP_KERNEL:*:*) echo nse-tandem-nsk"$UNAME_RELEASE" exit ;; NSR-*:NONSTOP_KERNEL:*:*) echo nsr-tandem-nsk"$UNAME_RELEASE" exit ;; NSV-*:NONSTOP_KERNEL:*:*) echo nsv-tandem-nsk"$UNAME_RELEASE" exit ;; NSX-*:NONSTOP_KERNEL:*:*) echo nsx-tandem-nsk"$UNAME_RELEASE" exit ;; *:NonStop-UX:*:*) echo mips-compaq-nonstopux exit ;; BS2000:POSIX*:*:*) echo bs2000-siemens-sysv exit ;; DS/*:UNIX_System_V:*:*) echo "$UNAME_MACHINE"-"$UNAME_SYSTEM"-"$UNAME_RELEASE" exit ;; *:Plan9:*:*) # "uname -m" is not consistent, so use $cputype instead. 386 # is converted to i386 for consistency with other x86 # operating systems. if test "$cputype" = 386; then UNAME_MACHINE=i386 else UNAME_MACHINE="$cputype" fi echo "$UNAME_MACHINE"-unknown-plan9 exit ;; *:TOPS-10:*:*) echo pdp10-unknown-tops10 exit ;; *:TENEX:*:*) echo pdp10-unknown-tenex exit ;; KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) echo pdp10-dec-tops20 exit ;; XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) echo pdp10-xkl-tops20 exit ;; *:TOPS-20:*:*) echo pdp10-unknown-tops20 exit ;; *:ITS:*:*) echo pdp10-unknown-its exit ;; SEI:*:*:SEIUX) echo mips-sei-seiux"$UNAME_RELEASE" exit ;; *:DragonFly:*:*) echo "$UNAME_MACHINE"-unknown-dragonfly"`echo "$UNAME_RELEASE"|sed -e 's/[-(].*//'`" exit ;; *:*VMS:*:*) UNAME_MACHINE=`(uname -p) 2>/dev/null` case "$UNAME_MACHINE" in A*) echo alpha-dec-vms ; exit ;; I*) echo ia64-dec-vms ; exit ;; V*) echo vax-dec-vms ; exit ;; esac ;; *:XENIX:*:SysV) echo i386-pc-xenix exit ;; i*86:skyos:*:*) echo "$UNAME_MACHINE"-pc-skyos"`echo "$UNAME_RELEASE" | sed -e 's/ .*$//'`" exit ;; i*86:rdos:*:*) echo "$UNAME_MACHINE"-pc-rdos exit ;; i*86:AROS:*:*) echo "$UNAME_MACHINE"-pc-aros exit ;; x86_64:VMkernel:*:*) echo "$UNAME_MACHINE"-unknown-esx exit ;; amd64:Isilon\ OneFS:*:*) echo x86_64-unknown-onefs exit ;; esac echo "$0: unable to guess system type" >&2 case "$UNAME_MACHINE:$UNAME_SYSTEM" in mips:Linux | mips64:Linux) # If we got here on MIPS GNU/Linux, output extra information. cat >&2 <&2 </dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null` /bin/uname -X = `(/bin/uname -X) 2>/dev/null` hostinfo = `(hostinfo) 2>/dev/null` /bin/universe = `(/bin/universe) 2>/dev/null` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null` /bin/arch = `(/bin/arch) 2>/dev/null` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` UNAME_MACHINE = "$UNAME_MACHINE" UNAME_RELEASE = "$UNAME_RELEASE" UNAME_SYSTEM = "$UNAME_SYSTEM" UNAME_VERSION = "$UNAME_VERSION" EOF exit 1 # Local variables: # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" # End: libcmis-0.5.2/NEWS0000664000175000017500000000577713411147241010600 000000000000000.1.0 * Generic * Anonymous connection * AtomPub binding * Get the content hierarchy using the down relations * Get the content of a document * Query nodes by ID 0.2.0 * Generic * Support for authentication in the API * Callback for providing interactive authentication * Added API to create documents and folders * Added API to delete documents and folders * AtomPub binding * Handle all the authentication methods that can be handled by libcurl like Basic, NTLM... * Decode base64 encoded content sent by SharePoint * Set the content of a document * Query nodes by path * Get the allowable actions for a node * Object properties can be updated * Query object types * Creation of folders and documents * Deletion of folders and documents 0.2.1 * Fixed documentation distribution 0.2.2 * Fixed soname for the library * Allow building against libcurl 7.13.1 0.2.3 * Fixed SharePoint support * Conditional build of man page 0.3.0 * Added Document::checkOut(), Document::cancelCheckout() and Document::checkIn() * Added Object::move( ) -- Grau Data * Fixes for xcmis and cloudoku.com -- Grau Data * Added Document::getAllVersions( ) * WebService binding implementation * Session factory automatically detects which binding to use * C wrapper API * Unit tests are now split between quick ones and the ones needing a CMIS server 0.4.0 * Support for Google Drive protocol as a binding * Support for Alfresco in the cloud * Added OAuth2 authentication support * Added API to configure HTTP proxy * Handle invalid SSL certificate problems * Added API for renditions * Moved the CMIS Atom binding unit tests to use libcurl mockup * Added repository capabilities support (still missing capabilityCreatablePropertyTypes and capabilityNewTypeSettableAttributes) 0.5.0 * Completely removed the dependency on InMemory server for unit tests * Minimized the number of HTTP requests sent by SessionFactory::createSession * Added Session::getBaseTypes() 0.5.1 * Fixed a crash when server response did not contain cmis:baseTypeId property (tdf#90351) * Removed the requirement for non-empty password when using HTTP authentication credentials * Fixed build with boost 1.60 and gcc 5 * Fixed a few problems found by Coverity * Fixed a busload of memory leaks 0.5.2 * Fixed Google Drive login, broken by Google's new 2-page login sequence * Added support for Google Drive two-factor authentication * Fixed access to SharePoint root folder (tdf#101385) * Limited the maximal number of redirections to 20 (rhbz#1410197) * Switched library implementation to C++11 (the API remains C++98-compatible) * Fixed build with boost >= 1.68.0 (#19) * Fixed encoding of OAuth2 credentials * Dropped cppcheck run from "make check". A new "make cppcheck" target was created for it * Added proper API symbol exporting * Speeded up building of tests a bit * Fixed a few issues found by coverity and cppcheck libcmis-0.5.2/install-sh0000755000175000017500000003601013407230143012062 00000000000000#!/bin/sh # install - install a program, script, or datafile scriptversion=2018-03-11.20; # UTC # This originates from X11R5 (mit/util/scripts/install.sh), which was # later released in X11R6 (xc/config/util/install.sh) with the # following copyright and license. # # Copyright (C) 1994 X Consortium # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to # deal in the Software without restriction, including without limitation the # rights to use, copy, modify, merge, publish, distribute, sublicense, and/or # sell copies of the Software, and to permit persons to whom the Software is # furnished to do so, subject to the following conditions: # # The above copyright notice and this permission notice shall be included in # all copies or substantial portions of the Software. # # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN # AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC- # TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. # # Except as contained in this notice, the name of the X Consortium shall not # be used in advertising or otherwise to promote the sale, use or other deal- # ings in this Software without prior written authorization from the X Consor- # tium. # # # FSF changes to this file are in the public domain. # # Calling this script install-sh is preferred over install.sh, to prevent # 'make' implicit rules from creating a file called install from it # when there is no Makefile. # # This script is compatible with the BSD install script, but was written # from scratch. tab=' ' nl=' ' IFS=" $tab$nl" # Set DOITPROG to "echo" to test this script. doit=${DOITPROG-} doit_exec=${doit:-exec} # Put in absolute file names if you don't have them in your path; # or use environment vars. chgrpprog=${CHGRPPROG-chgrp} chmodprog=${CHMODPROG-chmod} chownprog=${CHOWNPROG-chown} cmpprog=${CMPPROG-cmp} cpprog=${CPPROG-cp} mkdirprog=${MKDIRPROG-mkdir} mvprog=${MVPROG-mv} rmprog=${RMPROG-rm} stripprog=${STRIPPROG-strip} posix_mkdir= # Desired mode of installed file. mode=0755 chgrpcmd= chmodcmd=$chmodprog chowncmd= mvcmd=$mvprog rmcmd="$rmprog -f" stripcmd= src= dst= dir_arg= dst_arg= copy_on_change=false is_target_a_directory=possibly usage="\ Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE or: $0 [OPTION]... SRCFILES... DIRECTORY or: $0 [OPTION]... -t DIRECTORY SRCFILES... or: $0 [OPTION]... -d DIRECTORIES... In the 1st form, copy SRCFILE to DSTFILE. In the 2nd and 3rd, copy all SRCFILES to DIRECTORY. In the 4th, create DIRECTORIES. Options: --help display this help and exit. --version display version info and exit. -c (ignored) -C install only if different (preserve the last data modification time) -d create directories instead of installing files. -g GROUP $chgrpprog installed files to GROUP. -m MODE $chmodprog installed files to MODE. -o USER $chownprog installed files to USER. -s $stripprog installed files. -t DIRECTORY install into DIRECTORY. -T report an error if DSTFILE is a directory. Environment variables override the default commands: CHGRPPROG CHMODPROG CHOWNPROG CMPPROG CPPROG MKDIRPROG MVPROG RMPROG STRIPPROG " while test $# -ne 0; do case $1 in -c) ;; -C) copy_on_change=true;; -d) dir_arg=true;; -g) chgrpcmd="$chgrpprog $2" shift;; --help) echo "$usage"; exit $?;; -m) mode=$2 case $mode in *' '* | *"$tab"* | *"$nl"* | *'*'* | *'?'* | *'['*) echo "$0: invalid mode: $mode" >&2 exit 1;; esac shift;; -o) chowncmd="$chownprog $2" shift;; -s) stripcmd=$stripprog;; -t) is_target_a_directory=always dst_arg=$2 # Protect names problematic for 'test' and other utilities. case $dst_arg in -* | [=\(\)!]) dst_arg=./$dst_arg;; esac shift;; -T) is_target_a_directory=never;; --version) echo "$0 $scriptversion"; exit $?;; --) shift break;; -*) echo "$0: invalid option: $1" >&2 exit 1;; *) break;; esac shift done # We allow the use of options -d and -T together, by making -d # take the precedence; this is for compatibility with GNU install. if test -n "$dir_arg"; then if test -n "$dst_arg"; then echo "$0: target directory not allowed when installing a directory." >&2 exit 1 fi fi if test $# -ne 0 && test -z "$dir_arg$dst_arg"; then # When -d is used, all remaining arguments are directories to create. # When -t is used, the destination is already specified. # Otherwise, the last argument is the destination. Remove it from $@. for arg do if test -n "$dst_arg"; then # $@ is not empty: it contains at least $arg. set fnord "$@" "$dst_arg" shift # fnord fi shift # arg dst_arg=$arg # Protect names problematic for 'test' and other utilities. case $dst_arg in -* | [=\(\)!]) dst_arg=./$dst_arg;; esac done fi if test $# -eq 0; then if test -z "$dir_arg"; then echo "$0: no input file specified." >&2 exit 1 fi # It's OK to call 'install-sh -d' without argument. # This can happen when creating conditional directories. exit 0 fi if test -z "$dir_arg"; then if test $# -gt 1 || test "$is_target_a_directory" = always; then if test ! -d "$dst_arg"; then echo "$0: $dst_arg: Is not a directory." >&2 exit 1 fi fi fi if test -z "$dir_arg"; then do_exit='(exit $ret); exit $ret' trap "ret=129; $do_exit" 1 trap "ret=130; $do_exit" 2 trap "ret=141; $do_exit" 13 trap "ret=143; $do_exit" 15 # Set umask so as not to create temps with too-generous modes. # However, 'strip' requires both read and write access to temps. case $mode in # Optimize common cases. *644) cp_umask=133;; *755) cp_umask=22;; *[0-7]) if test -z "$stripcmd"; then u_plus_rw= else u_plus_rw='% 200' fi cp_umask=`expr '(' 777 - $mode % 1000 ')' $u_plus_rw`;; *) if test -z "$stripcmd"; then u_plus_rw= else u_plus_rw=,u+rw fi cp_umask=$mode$u_plus_rw;; esac fi for src do # Protect names problematic for 'test' and other utilities. case $src in -* | [=\(\)!]) src=./$src;; esac if test -n "$dir_arg"; then dst=$src dstdir=$dst test -d "$dstdir" dstdir_status=$? else # Waiting for this to be detected by the "$cpprog $src $dsttmp" command # might cause directories to be created, which would be especially bad # if $src (and thus $dsttmp) contains '*'. if test ! -f "$src" && test ! -d "$src"; then echo "$0: $src does not exist." >&2 exit 1 fi if test -z "$dst_arg"; then echo "$0: no destination specified." >&2 exit 1 fi dst=$dst_arg # If destination is a directory, append the input filename. if test -d "$dst"; then if test "$is_target_a_directory" = never; then echo "$0: $dst_arg: Is a directory" >&2 exit 1 fi dstdir=$dst dstbase=`basename "$src"` case $dst in */) dst=$dst$dstbase;; *) dst=$dst/$dstbase;; esac dstdir_status=0 else dstdir=`dirname "$dst"` test -d "$dstdir" dstdir_status=$? fi fi case $dstdir in */) dstdirslash=$dstdir;; *) dstdirslash=$dstdir/;; esac obsolete_mkdir_used=false if test $dstdir_status != 0; then case $posix_mkdir in '') # Create intermediate dirs using mode 755 as modified by the umask. # This is like FreeBSD 'install' as of 1997-10-28. umask=`umask` case $stripcmd.$umask in # Optimize common cases. *[2367][2367]) mkdir_umask=$umask;; .*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;; *[0-7]) mkdir_umask=`expr $umask + 22 \ - $umask % 100 % 40 + $umask % 20 \ - $umask % 10 % 4 + $umask % 2 `;; *) mkdir_umask=$umask,go-w;; esac # With -d, create the new directory with the user-specified mode. # Otherwise, rely on $mkdir_umask. if test -n "$dir_arg"; then mkdir_mode=-m$mode else mkdir_mode= fi posix_mkdir=false case $umask in *[123567][0-7][0-7]) # POSIX mkdir -p sets u+wx bits regardless of umask, which # is incompatible with FreeBSD 'install' when (umask & 300) != 0. ;; *) # Note that $RANDOM variable is not portable (e.g. dash); Use it # here however when possible just to lower collision chance. tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$ trap 'ret=$?; rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" 2>/dev/null; exit $ret' 0 # Because "mkdir -p" follows existing symlinks and we likely work # directly in world-writeable /tmp, make sure that the '$tmpdir' # directory is successfully created first before we actually test # 'mkdir -p' feature. if (umask $mkdir_umask && $mkdirprog $mkdir_mode "$tmpdir" && exec $mkdirprog $mkdir_mode -p -- "$tmpdir/a/b") >/dev/null 2>&1 then if test -z "$dir_arg" || { # Check for POSIX incompatibilities with -m. # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or # other-writable bit of parent directory when it shouldn't. # FreeBSD 6.1 mkdir -m -p sets mode of existing directory. test_tmpdir="$tmpdir/a" ls_ld_tmpdir=`ls -ld "$test_tmpdir"` case $ls_ld_tmpdir in d????-?r-*) different_mode=700;; d????-?--*) different_mode=755;; *) false;; esac && $mkdirprog -m$different_mode -p -- "$test_tmpdir" && { ls_ld_tmpdir_1=`ls -ld "$test_tmpdir"` test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1" } } then posix_mkdir=: fi rmdir "$tmpdir/a/b" "$tmpdir/a" "$tmpdir" else # Remove any dirs left behind by ancient mkdir implementations. rmdir ./$mkdir_mode ./-p ./-- "$tmpdir" 2>/dev/null fi trap '' 0;; esac;; esac if $posix_mkdir && ( umask $mkdir_umask && $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir" ) then : else # The umask is ridiculous, or mkdir does not conform to POSIX, # or it failed possibly due to a race condition. Create the # directory the slow way, step by step, checking for races as we go. case $dstdir in /*) prefix='/';; [-=\(\)!]*) prefix='./';; *) prefix='';; esac oIFS=$IFS IFS=/ set -f set fnord $dstdir shift set +f IFS=$oIFS prefixes= for d do test X"$d" = X && continue prefix=$prefix$d if test -d "$prefix"; then prefixes= else if $posix_mkdir; then (umask=$mkdir_umask && $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break # Don't fail if two instances are running concurrently. test -d "$prefix" || exit 1 else case $prefix in *\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;; *) qprefix=$prefix;; esac prefixes="$prefixes '$qprefix'" fi fi prefix=$prefix/ done if test -n "$prefixes"; then # Don't fail if two instances are running concurrently. (umask $mkdir_umask && eval "\$doit_exec \$mkdirprog $prefixes") || test -d "$dstdir" || exit 1 obsolete_mkdir_used=true fi fi fi if test -n "$dir_arg"; then { test -z "$chowncmd" || $doit $chowncmd "$dst"; } && { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } && { test "$obsolete_mkdir_used$chowncmd$chgrpcmd" = false || test -z "$chmodcmd" || $doit $chmodcmd $mode "$dst"; } || exit 1 else # Make a couple of temp file names in the proper directory. dsttmp=${dstdirslash}_inst.$$_ rmtmp=${dstdirslash}_rm.$$_ # Trap to clean up those temp files at exit. trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 # Copy the file name to the temp name. (umask $cp_umask && $doit_exec $cpprog "$src" "$dsttmp") && # and set any options; do chmod last to preserve setuid bits. # # If any of these fail, we abort the whole thing. If we want to # ignore errors from any of these, just make sure not to ignore # errors from the above "$doit $cpprog $src $dsttmp" command. # { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } && { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } && { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } && { test -z "$chmodcmd" || $doit $chmodcmd $mode "$dsttmp"; } && # If -C, don't bother to copy if it wouldn't change the file. if $copy_on_change && old=`LC_ALL=C ls -dlL "$dst" 2>/dev/null` && new=`LC_ALL=C ls -dlL "$dsttmp" 2>/dev/null` && set -f && set X $old && old=:$2:$4:$5:$6 && set X $new && new=:$2:$4:$5:$6 && set +f && test "$old" = "$new" && $cmpprog "$dst" "$dsttmp" >/dev/null 2>&1 then rm -f "$dsttmp" else # Rename the file to the real destination. $doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null || # The rename failed, perhaps because mv can't rename something else # to itself, or perhaps because mv is so ancient that it does not # support -f. { # Now remove or move aside any old file at destination location. # We try this two ways since rm can't unlink itself on some # systems and the destination file might be busy for other # reasons. In this case, the final cleanup might fail but the new # file should still install successfully. { test ! -f "$dst" || $doit $rmcmd -f "$dst" 2>/dev/null || { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null && { $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; } } || { echo "$0: cannot unlink or rename $dst" >&2 (exit 1); exit 1 } } && # Now rename the file to the real destination. $doit $mvcmd "$dsttmp" "$dst" } fi || exit 1 trap '' 0 fi done # Local variables: # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" # time-stamp-end: "; # UTC" # End: libcmis-0.5.2/config.sub0000755000175000017500000010707013407230143012046 00000000000000#! /bin/sh # Configuration validation subroutine script. # Copyright 1992-2018 Free Software Foundation, Inc. timestamp='2018-05-05' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, see . # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that # program. This Exception is an additional permission under section 7 # of the GNU General Public License, version 3 ("GPLv3"). # Please send patches to . # # Configuration subroutine to validate and canonicalize a configuration type. # Supply the specified configuration type as an argument. # If it is invalid, we print an error message on stderr and exit with code 1. # Otherwise, we print the canonical config type on stdout and succeed. # You can get the latest version of this script from: # https://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub # This file is supposed to be the same for all GNU packages # and recognize all the CPU types, system types and aliases # that are meaningful with *any* GNU software. # Each package is responsible for reporting which valid configurations # it does not support. The user should be able to distinguish # a failure to support a valid configuration from a meaningless # configuration. # The goal of this file is to map all the various variations of a given # machine specification into a single specification in the form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM # or in some cases, the newer four-part form: # CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM # It is wrong to echo any other type of specification. me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] CPU-MFR-OPSYS or ALIAS Canonicalize a configuration name. Options: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit Report bugs and patches to ." version="\ GNU config.sub ($timestamp) Copyright 1992-2018 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" Try \`$me --help' for more information." # Parse command line while test $# -gt 0 ; do case $1 in --time-stamp | --time* | -t ) echo "$timestamp" ; exit ;; --version | -v ) echo "$version" ; exit ;; --help | --h* | -h ) echo "$usage"; exit ;; -- ) # Stop option processing shift; break ;; - ) # Use stdin as input. break ;; -* ) echo "$me: invalid option $1$help" exit 1 ;; *local*) # First pass through any local machine types. echo "$1" exit ;; * ) break ;; esac done case $# in 0) echo "$me: missing argument$help" >&2 exit 1;; 1) ;; *) echo "$me: too many arguments$help" >&2 exit 1;; esac # Spilt fields of configuration type IFS="-" read -r field1 field2 field3 field4 <&2 exit 1 ;; # Recognize the basic CPU types with company name. 580-* \ | a29k-* \ | aarch64-* | aarch64_be-* \ | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ | alphapca5[67]-* | alpha64pca5[67]-* | arc-* | arceb-* \ | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ | avr-* | avr32-* \ | ba-* \ | be32-* | be64-* \ | bfin-* | bs2000-* \ | c[123]* | c30-* | [cjt]90-* | c4x-* \ | c8051-* | clipper-* | craynv-* | csky-* | cydra-* \ | d10v-* | d30v-* | dlx-* \ | e2k-* | elxsi-* \ | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \ | h8300-* | h8500-* \ | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ | hexagon-* \ | i*86-* | i860-* | i960-* | ia16-* | ia64-* \ | ip2k-* | iq2000-* \ | k1om-* \ | le32-* | le64-* \ | lm32-* \ | m32c-* | m32r-* | m32rle-* \ | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ | m88110-* | m88k-* | maxq-* | mcore-* | metag-* \ | microblaze-* | microblazeel-* \ | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ | mips16-* \ | mips64-* | mips64el-* \ | mips64octeon-* | mips64octeonel-* \ | mips64orion-* | mips64orionel-* \ | mips64r5900-* | mips64r5900el-* \ | mips64vr-* | mips64vrel-* \ | mips64vr4100-* | mips64vr4100el-* \ | mips64vr4300-* | mips64vr4300el-* \ | mips64vr5000-* | mips64vr5000el-* \ | mips64vr5900-* | mips64vr5900el-* \ | mipsisa32-* | mipsisa32el-* \ | mipsisa32r2-* | mipsisa32r2el-* \ | mipsisa32r6-* | mipsisa32r6el-* \ | mipsisa64-* | mipsisa64el-* \ | mipsisa64r2-* | mipsisa64r2el-* \ | mipsisa64r6-* | mipsisa64r6el-* \ | mipsisa64sb1-* | mipsisa64sb1el-* \ | mipsisa64sr71k-* | mipsisa64sr71kel-* \ | mipsr5900-* | mipsr5900el-* \ | mipstx39-* | mipstx39el-* \ | mmix-* \ | mt-* \ | msp430-* \ | nds32-* | nds32le-* | nds32be-* \ | nfp-* \ | nios-* | nios2-* | nios2eb-* | nios2el-* \ | none-* | np1-* | ns16k-* | ns32k-* \ | open8-* \ | or1k*-* \ | orion-* \ | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* \ | pru-* \ | pyramid-* \ | riscv32-* | riscv64-* \ | rl78-* | romp-* | rs6000-* | rx-* \ | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ | sparclite-* \ | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | sv1-* | sx*-* \ | tahoe-* \ | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ | tile*-* \ | tron-* \ | ubicom32-* \ | v850-* | v850e-* | v850e1-* | v850es-* | v850e2-* | v850e2v3-* \ | vax-* \ | visium-* \ | wasm32-* \ | we32k-* \ | x86-* | x86_64-* | xc16x-* | xps100-* \ | xstormy16-* | xtensa*-* \ | ymp-* \ | z8k-* | z80-*) ;; # Recognize the basic CPU types without company name, with glob match. xtensa*) basic_machine=$basic_machine-unknown ;; # Recognize the various machine names and aliases which stand # for a CPU type and a company and sometimes even an OS. 386bsd) basic_machine=i386-pc os=-bsd ;; 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) basic_machine=m68000-att ;; 3b*) basic_machine=we32k-att ;; a29khif) basic_machine=a29k-amd os=-udi ;; abacus) basic_machine=abacus-unknown ;; adobe68k) basic_machine=m68010-adobe os=-scout ;; alliant | fx80) basic_machine=fx80-alliant ;; altos | altos3068) basic_machine=m68k-altos ;; am29k) basic_machine=a29k-none os=-bsd ;; amd64) basic_machine=x86_64-pc ;; amd64-*) basic_machine=x86_64-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; amdahl) basic_machine=580-amdahl os=-sysv ;; amiga | amiga-*) basic_machine=m68k-unknown ;; amigaos | amigados) basic_machine=m68k-unknown os=-amigaos ;; amigaunix | amix) basic_machine=m68k-unknown os=-sysv4 ;; apollo68) basic_machine=m68k-apollo os=-sysv ;; apollo68bsd) basic_machine=m68k-apollo os=-bsd ;; aros) basic_machine=i386-pc os=-aros ;; asmjs) basic_machine=asmjs-unknown ;; aux) basic_machine=m68k-apple os=-aux ;; balance) basic_machine=ns32k-sequent os=-dynix ;; blackfin) basic_machine=bfin-unknown os=-linux ;; blackfin-*) basic_machine=bfin-`echo "$basic_machine" | sed 's/^[^-]*-//'` os=-linux ;; bluegene*) basic_machine=powerpc-ibm os=-cnk ;; c54x-*) basic_machine=tic54x-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; c55x-*) basic_machine=tic55x-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; c6x-*) basic_machine=tic6x-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; c90) basic_machine=c90-cray os=-unicos ;; cegcc) basic_machine=arm-unknown os=-cegcc ;; convex-c1) basic_machine=c1-convex os=-bsd ;; convex-c2) basic_machine=c2-convex os=-bsd ;; convex-c32) basic_machine=c32-convex os=-bsd ;; convex-c34) basic_machine=c34-convex os=-bsd ;; convex-c38) basic_machine=c38-convex os=-bsd ;; cray | j90) basic_machine=j90-cray os=-unicos ;; craynv) basic_machine=craynv-cray os=-unicosmp ;; cr16 | cr16-*) basic_machine=cr16-unknown os=-elf ;; crds | unos) basic_machine=m68k-crds ;; crisv32 | crisv32-* | etraxfs*) basic_machine=crisv32-axis ;; cris | cris-* | etrax*) basic_machine=cris-axis ;; crx) basic_machine=crx-unknown os=-elf ;; da30 | da30-*) basic_machine=m68k-da30 ;; decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn) basic_machine=mips-dec ;; decsystem10* | dec10*) basic_machine=pdp10-dec os=-tops10 ;; decsystem20* | dec20*) basic_machine=pdp10-dec os=-tops20 ;; delta | 3300 | motorola-3300 | motorola-delta \ | 3300-motorola | delta-motorola) basic_machine=m68k-motorola ;; delta88) basic_machine=m88k-motorola os=-sysv3 ;; dicos) basic_machine=i686-pc os=-dicos ;; djgpp) basic_machine=i586-pc os=-msdosdjgpp ;; dpx20 | dpx20-*) basic_machine=rs6000-bull os=-bosx ;; dpx2*) basic_machine=m68k-bull os=-sysv3 ;; e500v[12]) basic_machine=powerpc-unknown os=$os"spe" ;; e500v[12]-*) basic_machine=powerpc-`echo "$basic_machine" | sed 's/^[^-]*-//'` os=$os"spe" ;; ebmon29k) basic_machine=a29k-amd os=-ebmon ;; elxsi) basic_machine=elxsi-elxsi os=-bsd ;; encore | umax | mmax) basic_machine=ns32k-encore ;; es1800 | OSE68k | ose68k | ose | OSE) basic_machine=m68k-ericsson os=-ose ;; fx2800) basic_machine=i860-alliant ;; genix) basic_machine=ns32k-ns ;; gmicro) basic_machine=tron-gmicro os=-sysv ;; go32) basic_machine=i386-pc os=-go32 ;; h3050r* | hiux*) basic_machine=hppa1.1-hitachi os=-hiuxwe2 ;; h8300hms) basic_machine=h8300-hitachi os=-hms ;; h8300xray) basic_machine=h8300-hitachi os=-xray ;; h8500hms) basic_machine=h8500-hitachi os=-hms ;; harris) basic_machine=m88k-harris os=-sysv3 ;; hp300-*) basic_machine=m68k-hp ;; hp300bsd) basic_machine=m68k-hp os=-bsd ;; hp300hpux) basic_machine=m68k-hp os=-hpux ;; hp3k9[0-9][0-9] | hp9[0-9][0-9]) basic_machine=hppa1.0-hp ;; hp9k2[0-9][0-9] | hp9k31[0-9]) basic_machine=m68000-hp ;; hp9k3[2-9][0-9]) basic_machine=m68k-hp ;; hp9k6[0-9][0-9] | hp6[0-9][0-9]) basic_machine=hppa1.0-hp ;; hp9k7[0-79][0-9] | hp7[0-79][0-9]) basic_machine=hppa1.1-hp ;; hp9k78[0-9] | hp78[0-9]) # FIXME: really hppa2.0-hp basic_machine=hppa1.1-hp ;; hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) # FIXME: really hppa2.0-hp basic_machine=hppa1.1-hp ;; hp9k8[0-9][13679] | hp8[0-9][13679]) basic_machine=hppa1.1-hp ;; hp9k8[0-9][0-9] | hp8[0-9][0-9]) basic_machine=hppa1.0-hp ;; hppaosf) basic_machine=hppa1.1-hp os=-osf ;; hppro) basic_machine=hppa1.1-hp os=-proelf ;; i370-ibm* | ibm*) basic_machine=i370-ibm ;; i*86v32) basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'` os=-sysv32 ;; i*86v4*) basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'` os=-sysv4 ;; i*86v) basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'` os=-sysv ;; i*86sol2) basic_machine=`echo "$1" | sed -e 's/86.*/86-pc/'` os=-solaris2 ;; i386mach) basic_machine=i386-mach os=-mach ;; vsta) basic_machine=i386-unknown os=-vsta ;; iris | iris4d) basic_machine=mips-sgi case $os in -irix*) ;; *) os=-irix4 ;; esac ;; isi68 | isi) basic_machine=m68k-isi os=-sysv ;; leon-*|leon[3-9]-*) basic_machine=sparc-`echo "$basic_machine" | sed 's/-.*//'` ;; m68knommu) basic_machine=m68k-unknown os=-linux ;; m68knommu-*) basic_machine=m68k-`echo "$basic_machine" | sed 's/^[^-]*-//'` os=-linux ;; magnum | m3230) basic_machine=mips-mips os=-sysv ;; merlin) basic_machine=ns32k-utek os=-sysv ;; microblaze*) basic_machine=microblaze-xilinx ;; mingw64) basic_machine=x86_64-pc os=-mingw64 ;; mingw32) basic_machine=i686-pc os=-mingw32 ;; mingw32ce) basic_machine=arm-unknown os=-mingw32ce ;; miniframe) basic_machine=m68000-convergent ;; *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*) basic_machine=m68k-atari os=-mint ;; mips3*-*) basic_machine=`echo "$basic_machine" | sed -e 's/mips3/mips64/'` ;; mips3*) basic_machine=`echo "$basic_machine" | sed -e 's/mips3/mips64/'`-unknown ;; monitor) basic_machine=m68k-rom68k os=-coff ;; morphos) basic_machine=powerpc-unknown os=-morphos ;; moxiebox) basic_machine=moxie-unknown os=-moxiebox ;; msdos) basic_machine=i386-pc os=-msdos ;; ms1-*) basic_machine=`echo "$basic_machine" | sed -e 's/ms1-/mt-/'` ;; msys) basic_machine=i686-pc os=-msys ;; mvs) basic_machine=i370-ibm os=-mvs ;; nacl) basic_machine=le32-unknown os=-nacl ;; ncr3000) basic_machine=i486-ncr os=-sysv4 ;; netbsd386) basic_machine=i386-unknown os=-netbsd ;; netwinder) basic_machine=armv4l-rebel os=-linux ;; news | news700 | news800 | news900) basic_machine=m68k-sony os=-newsos ;; news1000) basic_machine=m68030-sony os=-newsos ;; news-3600 | risc-news) basic_machine=mips-sony os=-newsos ;; necv70) basic_machine=v70-nec os=-sysv ;; next | m*-next) basic_machine=m68k-next case $os in -nextstep* ) ;; -ns2*) os=-nextstep2 ;; *) os=-nextstep3 ;; esac ;; nh3000) basic_machine=m68k-harris os=-cxux ;; nh[45]000) basic_machine=m88k-harris os=-cxux ;; nindy960) basic_machine=i960-intel os=-nindy ;; mon960) basic_machine=i960-intel os=-mon960 ;; nonstopux) basic_machine=mips-compaq os=-nonstopux ;; np1) basic_machine=np1-gould ;; neo-tandem) basic_machine=neo-tandem ;; nse-tandem) basic_machine=nse-tandem ;; nsr-tandem) basic_machine=nsr-tandem ;; nsv-tandem) basic_machine=nsv-tandem ;; nsx-tandem) basic_machine=nsx-tandem ;; op50n-* | op60c-*) basic_machine=hppa1.1-oki os=-proelf ;; openrisc | openrisc-*) basic_machine=or32-unknown ;; os400) basic_machine=powerpc-ibm os=-os400 ;; OSE68000 | ose68000) basic_machine=m68000-ericsson os=-ose ;; os68k) basic_machine=m68k-none os=-os68k ;; pa-hitachi) basic_machine=hppa1.1-hitachi os=-hiuxwe2 ;; paragon) basic_machine=i860-intel os=-osf ;; parisc) basic_machine=hppa-unknown os=-linux ;; parisc-*) basic_machine=hppa-`echo "$basic_machine" | sed 's/^[^-]*-//'` os=-linux ;; pbd) basic_machine=sparc-tti ;; pbb) basic_machine=m68k-tti ;; pc532 | pc532-*) basic_machine=ns32k-pc532 ;; pc98) basic_machine=i386-pc ;; pc98-*) basic_machine=i386-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; pentium | p5 | k5 | k6 | nexgen | viac3) basic_machine=i586-pc ;; pentiumpro | p6 | 6x86 | athlon | athlon_*) basic_machine=i686-pc ;; pentiumii | pentium2 | pentiumiii | pentium3) basic_machine=i686-pc ;; pentium4) basic_machine=i786-pc ;; pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) basic_machine=i586-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; pentiumpro-* | p6-* | 6x86-* | athlon-*) basic_machine=i686-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) basic_machine=i686-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; pentium4-*) basic_machine=i786-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; pn) basic_machine=pn-gould ;; power) basic_machine=power-ibm ;; ppc | ppcbe) basic_machine=powerpc-unknown ;; ppc-* | ppcbe-*) basic_machine=powerpc-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; ppcle | powerpclittle) basic_machine=powerpcle-unknown ;; ppcle-* | powerpclittle-*) basic_machine=powerpcle-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; ppc64) basic_machine=powerpc64-unknown ;; ppc64-*) basic_machine=powerpc64-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; ppc64le | powerpc64little) basic_machine=powerpc64le-unknown ;; ppc64le-* | powerpc64little-*) basic_machine=powerpc64le-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; ps2) basic_machine=i386-ibm ;; pw32) basic_machine=i586-unknown os=-pw32 ;; rdos | rdos64) basic_machine=x86_64-pc os=-rdos ;; rdos32) basic_machine=i386-pc os=-rdos ;; rom68k) basic_machine=m68k-rom68k os=-coff ;; rm[46]00) basic_machine=mips-siemens ;; rtpc | rtpc-*) basic_machine=romp-ibm ;; s390 | s390-*) basic_machine=s390-ibm ;; s390x | s390x-*) basic_machine=s390x-ibm ;; sa29200) basic_machine=a29k-amd os=-udi ;; sb1) basic_machine=mipsisa64sb1-unknown ;; sb1el) basic_machine=mipsisa64sb1el-unknown ;; sde) basic_machine=mipsisa32-sde os=-elf ;; sei) basic_machine=mips-sei os=-seiux ;; sequent) basic_machine=i386-sequent ;; sh5el) basic_machine=sh5le-unknown ;; simso-wrs) basic_machine=sparclite-wrs os=-vxworks ;; sps7) basic_machine=m68k-bull os=-sysv2 ;; spur) basic_machine=spur-unknown ;; st2000) basic_machine=m68k-tandem ;; stratus) basic_machine=i860-stratus os=-sysv4 ;; strongarm-* | thumb-*) basic_machine=arm-`echo "$basic_machine" | sed 's/^[^-]*-//'` ;; sun2) basic_machine=m68000-sun ;; sun2os3) basic_machine=m68000-sun os=-sunos3 ;; sun2os4) basic_machine=m68000-sun os=-sunos4 ;; sun3os3) basic_machine=m68k-sun os=-sunos3 ;; sun3os4) basic_machine=m68k-sun os=-sunos4 ;; sun4os3) basic_machine=sparc-sun os=-sunos3 ;; sun4os4) basic_machine=sparc-sun os=-sunos4 ;; sun4sol2) basic_machine=sparc-sun os=-solaris2 ;; sun3 | sun3-*) basic_machine=m68k-sun ;; sun4) basic_machine=sparc-sun ;; sun386 | sun386i | roadrunner) basic_machine=i386-sun ;; sv1) basic_machine=sv1-cray os=-unicos ;; symmetry) basic_machine=i386-sequent os=-dynix ;; t3e) basic_machine=alphaev5-cray os=-unicos ;; t90) basic_machine=t90-cray os=-unicos ;; tile*) basic_machine=$basic_machine-unknown os=-linux-gnu ;; tx39) basic_machine=mipstx39-unknown ;; tx39el) basic_machine=mipstx39el-unknown ;; toad1) basic_machine=pdp10-xkl os=-tops20 ;; tower | tower-32) basic_machine=m68k-ncr ;; tpf) basic_machine=s390x-ibm os=-tpf ;; udi29k) basic_machine=a29k-amd os=-udi ;; ultra3) basic_machine=a29k-nyu os=-sym1 ;; v810 | necv810) basic_machine=v810-nec os=-none ;; vaxv) basic_machine=vax-dec os=-sysv ;; vms) basic_machine=vax-dec os=-vms ;; vpp*|vx|vx-*) basic_machine=f301-fujitsu ;; vxworks960) basic_machine=i960-wrs os=-vxworks ;; vxworks68) basic_machine=m68k-wrs os=-vxworks ;; vxworks29k) basic_machine=a29k-wrs os=-vxworks ;; w65*) basic_machine=w65-wdc os=-none ;; w89k-*) basic_machine=hppa1.1-winbond os=-proelf ;; x64) basic_machine=x86_64-pc ;; xbox) basic_machine=i686-pc os=-mingw32 ;; xps | xps100) basic_machine=xps100-honeywell ;; xscale-* | xscalee[bl]-*) basic_machine=`echo "$basic_machine" | sed 's/^xscale/arm/'` ;; ymp) basic_machine=ymp-cray os=-unicos ;; none) basic_machine=none-none os=-none ;; # Here we handle the default manufacturer of certain CPU types. It is in # some cases the only manufacturer, in others, it is the most popular. w89k) basic_machine=hppa1.1-winbond ;; op50n) basic_machine=hppa1.1-oki ;; op60c) basic_machine=hppa1.1-oki ;; romp) basic_machine=romp-ibm ;; mmix) basic_machine=mmix-knuth ;; rs6000) basic_machine=rs6000-ibm ;; vax) basic_machine=vax-dec ;; pdp11) basic_machine=pdp11-dec ;; we32k) basic_machine=we32k-att ;; sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele) basic_machine=sh-unknown ;; cydra) basic_machine=cydra-cydrome ;; orion) basic_machine=orion-highlevel ;; orion105) basic_machine=clipper-highlevel ;; mac | mpw | mac-mpw) basic_machine=m68k-apple ;; pmac | pmac-mpw) basic_machine=powerpc-apple ;; *-unknown) # Make sure to match an already-canonicalized machine name. ;; *) echo Invalid configuration \`"$1"\': machine \`"$basic_machine"\' not recognized 1>&2 exit 1 ;; esac # Here we canonicalize certain aliases for manufacturers. case $basic_machine in *-digital*) basic_machine=`echo "$basic_machine" | sed 's/digital.*/dec/'` ;; *-commodore*) basic_machine=`echo "$basic_machine" | sed 's/commodore.*/cbm/'` ;; *) ;; esac # Decode manufacturer-specific aliases for certain operating systems. if [ x$os != x ] then case $os in # First match some system type aliases that might get confused # with valid system types. # -solaris* is a basic system type, with this one exception. -auroraux) os=-auroraux ;; -solaris1 | -solaris1.*) os=`echo $os | sed -e 's|solaris1|sunos4|'` ;; -solaris) os=-solaris2 ;; -unixware*) os=-sysv4.2uw ;; -gnu/linux*) os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'` ;; # es1800 is here to avoid being matched by es* (a different OS) -es1800*) os=-ose ;; # Now accept the basic system types. # The portable systems comes first. # Each alternative MUST end in a * to match a version number. # -sysv* is not here because it comes later, after sysvr4. -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\ | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \ | -sym* | -kopensolaris* | -plan9* \ | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ | -aos* | -aros* | -cloudabi* | -sortix* \ | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ | -hiux* | -knetbsd* | -mirbsd* | -netbsd* \ | -bitrig* | -openbsd* | -solidbsd* | -libertybsd* \ | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* | -hcos* \ | -chorusos* | -chorusrdb* | -cegcc* | -glidix* \ | -cygwin* | -msys* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ | -midipix* | -mingw32* | -mingw64* | -linux-gnu* | -linux-android* \ | -linux-newlib* | -linux-musl* | -linux-uclibc* \ | -uxpv* | -beos* | -mpeix* | -udk* | -moxiebox* \ | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* \ | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ | -morphos* | -superux* | -rtmk* | -windiss* \ | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es* \ | -onefs* | -tirtos* | -phoenix* | -fuchsia* | -redox* | -bme* \ | -midnightbsd*) # Remember, each alternative MUST END IN *, to match a version number. ;; -qnx*) case $basic_machine in x86-* | i*86-*) ;; *) os=-nto$os ;; esac ;; -nto-qnx*) ;; -nto*) os=`echo $os | sed -e 's|nto|nto-qnx|'` ;; -sim | -xray | -os68k* | -v88r* \ | -windows* | -osx | -abug | -netware* | -os9* \ | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) ;; -mac*) os=`echo "$os" | sed -e 's|mac|macos|'` ;; -linux-dietlibc) os=-linux-dietlibc ;; -linux*) os=`echo $os | sed -e 's|linux|linux-gnu|'` ;; -sunos5*) os=`echo "$os" | sed -e 's|sunos5|solaris2|'` ;; -sunos6*) os=`echo "$os" | sed -e 's|sunos6|solaris3|'` ;; -opened*) os=-openedition ;; -os400*) os=-os400 ;; -wince*) os=-wince ;; -utek*) os=-bsd ;; -dynix*) os=-bsd ;; -acis*) os=-aos ;; -atheos*) os=-atheos ;; -syllable*) os=-syllable ;; -386bsd) os=-bsd ;; -ctix* | -uts*) os=-sysv ;; -nova*) os=-rtmk-nova ;; -ns2) os=-nextstep2 ;; -nsk*) os=-nsk ;; # Preserve the version number of sinix5. -sinix5.*) os=`echo $os | sed -e 's|sinix|sysv|'` ;; -sinix*) os=-sysv4 ;; -tpf*) os=-tpf ;; -triton*) os=-sysv3 ;; -oss*) os=-sysv3 ;; -svr4*) os=-sysv4 ;; -svr3) os=-sysv3 ;; -sysvr4) os=-sysv4 ;; # This must come after -sysvr4. -sysv*) ;; -ose*) os=-ose ;; -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) os=-mint ;; -zvmoe) os=-zvmoe ;; -dicos*) os=-dicos ;; -pikeos*) # Until real need of OS specific support for # particular features comes up, bare metal # configurations are quite functional. case $basic_machine in arm*) os=-eabi ;; *) os=-elf ;; esac ;; -nacl*) ;; -ios) ;; -none) ;; -*-eabi) case $basic_machine in arm*) ;; esac ;; *) # Get rid of the `-' at the beginning of $os. os=`echo $os | sed 's/[^-]*-//'` echo Invalid configuration \`"$1"\': system \`"$os"\' not recognized 1>&2 exit 1 ;; esac else # Here we handle the default operating systems that come with various machines. # The value should be what the vendor currently ships out the door with their # machine or put another way, the most popular os provided with the machine. # Note that if you're going to try to match "-MANUFACTURER" here (say, # "-sun"), then you have to tell the case statement up towards the top # that MANUFACTURER isn't an operating system. Otherwise, code above # will signal an error saying that MANUFACTURER isn't an operating # system, and we'll never get to this point. case $basic_machine in score-*) os=-elf ;; spu-*) os=-elf ;; *-acorn) os=-riscix1.2 ;; arm*-rebel) os=-linux ;; arm*-semi) os=-aout ;; c4x-* | tic4x-*) os=-coff ;; c8051-*) os=-elf ;; hexagon-*) os=-elf ;; tic54x-*) os=-coff ;; tic55x-*) os=-coff ;; tic6x-*) os=-coff ;; # This must come before the *-dec entry. pdp10-*) os=-tops20 ;; pdp11-*) os=-none ;; *-dec | vax-*) os=-ultrix4.2 ;; m68*-apollo) os=-domain ;; i386-sun) os=-sunos4.0.2 ;; m68000-sun) os=-sunos3 ;; m68*-cisco) os=-aout ;; mep-*) os=-elf ;; mips*-cisco) os=-elf ;; mips*-*) os=-elf ;; or32-*) os=-coff ;; *-tti) # must be before sparc entry or we get the wrong os. os=-sysv3 ;; sparc-* | *-sun) os=-sunos4.1.1 ;; pru-*) os=-elf ;; *-be) os=-beos ;; *-ibm) os=-aix ;; *-knuth) os=-mmixware ;; *-wec) os=-proelf ;; *-winbond) os=-proelf ;; *-oki) os=-proelf ;; *-hp) os=-hpux ;; *-hitachi) os=-hiux ;; i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) os=-sysv ;; *-cbm) os=-amigaos ;; *-dg) os=-dgux ;; *-dolphin) os=-sysv3 ;; m68k-ccur) os=-rtu ;; m88k-omron*) os=-luna ;; *-next) os=-nextstep ;; *-sequent) os=-ptx ;; *-crds) os=-unos ;; *-ns) os=-genix ;; i370-*) os=-mvs ;; *-gould) os=-sysv ;; *-highlevel) os=-bsd ;; *-encore) os=-bsd ;; *-sgi) os=-irix ;; *-siemens) os=-sysv4 ;; *-masscomp) os=-rtu ;; f30[01]-fujitsu | f700-fujitsu) os=-uxpv ;; *-rom68k) os=-coff ;; *-*bug) os=-coff ;; *-apple) os=-macos ;; *-atari*) os=-mint ;; *) os=-none ;; esac fi # Here we handle the case where we know the os, and the CPU type, but not the # manufacturer. We pick the logical manufacturer. vendor=unknown case $basic_machine in *-unknown) case $os in -riscix*) vendor=acorn ;; -sunos*) vendor=sun ;; -cnk*|-aix*) vendor=ibm ;; -beos*) vendor=be ;; -hpux*) vendor=hp ;; -mpeix*) vendor=hp ;; -hiux*) vendor=hitachi ;; -unos*) vendor=crds ;; -dgux*) vendor=dg ;; -luna*) vendor=omron ;; -genix*) vendor=ns ;; -mvs* | -opened*) vendor=ibm ;; -os400*) vendor=ibm ;; -ptx*) vendor=sequent ;; -tpf*) vendor=ibm ;; -vxsim* | -vxworks* | -windiss*) vendor=wrs ;; -aux*) vendor=apple ;; -hms*) vendor=hitachi ;; -mpw* | -macos*) vendor=apple ;; -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) vendor=atari ;; -vos*) vendor=stratus ;; esac basic_machine=`echo "$basic_machine" | sed "s/unknown/$vendor/"` ;; esac echo "$basic_machine$os" exit # Local variables: # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" # End: libcmis-0.5.2/AUTHORS0000664000175000017500000000023113407173247011137 00000000000000Cedric Bosdonnat Mihai Varga Cao Cuong Ngo David Tardon libcmis-0.5.2/cppcheck-suppress0000664000175000017500000000014613407411537013456 00000000000000publicAllocationError:qa/libcmis/test-decoder.cxx noExplicitConstructor noExplicitCopyMoveConstructor libcmis-0.5.2/doc/0000775000175000017500000000000013411152374010711 500000000000000libcmis-0.5.2/doc/cmis-client.xml.in0000664000175000017500000005617613407717637014224 00000000000000 2018-12-23 cmis-client 1 @PACKAGE_STRING@ cmis-client command line CMIS client tool. 2012-01-27 cmis-client help cmis-client -v --url url://to/binding list-repos cmis-client -v -u login -p secret --url url://to/binding -r repo-id repo-infos cmis-client -v -u login -p secret --url url://to/binding -r repo-id show-root cmis-client -v -u login -p secret --url url://to/binding -r repo-id get-content id cmis-client -v -u login -p secret --url url://to/binding -r repo-id --input-file path/to/file --input-type mime/type --input-name name.ext set-content id cmis-client -v -u login -p secret --url url://to/binding -r repo-id --object-type some:cmistype --object-property prop-id=prop-value create-folder parent-id name cmis-client -v -u login -p secret --url url://to/binding -r repo-id --input-file path/to/file --input-type mime/type --input-name name.ext --object-type some:cmistype --object-property prop-id=prop-value create-document parent-id name cmis-client -v -u login -p secret --url url://to/binding -r repo-id --object-property prop-id=prop-value update-object object-id cmis-client -v -u login -p secret --url url://to/binding -r repo-id type-by-id show-by-id show-by-path delete arg cmis-client -v -u login -p secret --url url://to/binding -r repo-id checkout cancel-checkout get-versions arg cmis-client -v -u login -p secret --url url://to/binding -r repo-id --input-file path/to/file --input-type mime/type --input-name name.ext --object-property prop-id=prop-value --major --message checkin pwc id 2012-01-27 DESCRIPTION The cmis-client tool sends queries over the net to a CMIS-enabled server to access or modify its content. It is originally demonstrating what libcmis is capable of. OPTIONS GLOBAL OPTIONS -v, --verbose Shows a lot of information to monitor what is happening behind the scene. This helps a lot to debug libcmis. --help Show the help and exit. This is equivalent to use the help command. --url url://to/binding url://to/binding needs to point to the service document of either AtomPub or WebService binding. -r,--repository repo-id Operate on the repo-id CMIS repository. If there is only one repository on the server, this parameter is not needed and that repository will be automatically selected. Use this parameter if there are several repositories on the server. -u,--username login Connect as login to the CMIS server. If not provided connect anonymously. -p,--password secret Use secret to authenticate on the CMIS server. --no-ssl-check Disables the SSL certificate verifications. Lowers the security, but may be handy to work around bad certificates like expired or self-signed ones. --proxy url Use url as the HTTP proxy. Setting this value will override the system proxy settings. --proxy-username login Use login to authenticate on the HTTP proxy. --proxy-password secret Use secret to authenticate on the HTTP proxy. --noproxy list Proxy settings won't apply to hostnames and domain names listed in list. This value is a coma separated list. --oauth2-client-id client_id Application client id to use in the OAuth2 authentication flow. --oauth2-client-secret client_secret Application client secret to use in the OAuth2 authentication flow. --oauth2-auth-url url URL to authenticate the user in the OAuth2 authentication flow. --oauth2-token-url url URL to authenticate the application in the OAuth2 authentication flow. The access and refresh tokens are provided by this URL. --oauth2-redirect-uri uri URI where the OAuth2 authentication flow will redirect after a sucessful authentication. --oauth2-scope scope Requested scope to access in the OAuth2 authentication flow. MODIFICATION OPERATIONS OPTIONS --input-file path/to/file Upload path/to/file as the new content stream of the object. --input-type mime/type Set the mime type of the new content stream of the object to mime/type. --input-name name.ext Set the remote content stream filename of the new content stream of the object to name.ext. --object-type some:cmistype Set the object type of the CMIS object to be created to some:cmistype. This is the equivalent of --object-property cmis:objectTypeId=some:cmistype. --object-property prop-id=prop-value Set a property to be updated or added to the CMIS object. prop-id is the property definition id and prop-value is the value to set on it. --major Create a major version when performing a checkin. -m, --message message Set the checking message. COMMANDS help Show the help and exit. list-repos List the repositories available on the server. repo-infos Displays the informations and capabilities of the selected repository show-root Displays the root node infos and children. get-content id Download the content of the CMIS object corresponding to id in the current directory. set-content id Upload a file as the content stream of the CMIS object corresponding to id. create-folder parent-id name Create a sub folder in folder parent-id named name. The default type of the folder to create is cmis:folder, but this can be changed using --object-type option. create-document parent-id name Create a document in folder parent-id named name. The default type of the document to create is cmis:document, but this can be changed using --object-type option. Note that the --input-file and --input-type may be mandatory, depending on the type of the document to create and its constraints. update-object object-id Replace the writeable properties given with --object-property option on the object matching id object-id. type-by-id arg... Displays the infos and children (if any) of all the CMIS types corresponding to the listed ids. show-by-id arg... Displays the infos and children (if any) of all the CMIS objects corresponding to the listed ids. show-by-path arg... Displays the infos and children (if any) of all the CMIS objects corresponding to the listed paths. delete arg... Deletes the CMIS objects corresponding to the listed ids. If the node is a folder, its content will be removed as well. checkout arg Checkout the document corresponding to the provided id and display the infos of the created private working copy. cancel-checkout arg Cancel the Private Working Copy corresponding to the node id. get-versions arg Display the versions (if any) of all the CMIS object corresponding to the provided id. checkin arg Check in the private working copy corresponding to the provided id and display the infos of the resulting document. Use the --major and --message options to define the version to create and the commit to associate to it. Note that repositories without the ability to update the private working copies will need the --input-file, --input-type and --object-property options. USAGE Displays the root node of repository A1: cmis-client -r A1 --url http://localhost/atom show-root Displays the nodes with id 133 and 116 of repository A1: cmis-client -r A1 --url http://localhost/atom show-by id 133 116 AUTHOR Cédric Bosdonnat Original author REPORTING BUGS Report bugs to <https://github.com/tdf/libcmis/issues>. libcmis-0.5.2/qa/0000775000175000017500000000000013411152401010534 500000000000000libcmis-0.5.2/qa/Makefile.in0000664000175000017500000004621313407705040012537 00000000000000# Makefile.in generated by automake 1.16.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2018 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = qa ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \ $(top_srcdir)/m4/ax_cxx_compile_stdcxx_11.m4 \ $(top_srcdir)/m4/ax_gcc_func_attribute.m4 \ $(top_srcdir)/m4/boost.m4 $(top_srcdir)/m4/libtool.m4 \ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = SOURCES = DIST_SOURCES = RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \ ctags-recursive dvi-recursive html-recursive info-recursive \ install-data-recursive install-dvi-recursive \ install-exec-recursive install-html-recursive \ install-info-recursive install-pdf-recursive \ install-ps-recursive install-recursive installcheck-recursive \ installdirs-recursive pdf-recursive ps-recursive \ tags-recursive uninstall-recursive am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ distclean-recursive maintainer-clean-recursive am__recursive_targets = \ $(RECURSIVE_TARGETS) \ $(RECURSIVE_CLEAN_TARGETS) \ $(am__extra_recursive_targets) AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \ distdir distdir-am am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is # *not* preserved. am__uniquify_input = $(AWK) '\ BEGIN { nonempty = 0; } \ { items[$$0] = 1; nonempty = 1; } \ END { if (nonempty) { for (i in items) print i; }; } \ ' # Make sure the list of sources is unique. This is necessary because, # e.g., the same source file might be shared among _SOURCES variables # for different programs/libraries. am__define_uniq_tagged_files = \ list='$(am__tagged_files)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags DIST_SUBDIRS = $(SUBDIRS) am__DIST_COMMON = $(srcdir)/Makefile.in DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) am__relativize = \ dir0=`pwd`; \ sed_first='s,^\([^/]*\)/.*$$,\1,'; \ sed_rest='s,^[^/]*/*,,'; \ sed_last='s,^.*/\([^/]*\)$$,\1,'; \ sed_butlast='s,/*[^/]*$$,,'; \ while test -n "$$dir1"; do \ first=`echo "$$dir1" | sed -e "$$sed_first"`; \ if test "$$first" != "."; then \ if test "$$first" = ".."; then \ dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ else \ first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ if test "$$first2" = "$$first"; then \ dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ else \ dir2="../$$dir2"; \ fi; \ dir0="$$dir0"/"$$first"; \ fi; \ fi; \ dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ done; \ reldir="$$dir2" ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ BOOST_CPPFLAGS = @BOOST_CPPFLAGS@ BOOST_DATE_TIME_LDFLAGS = @BOOST_DATE_TIME_LDFLAGS@ BOOST_DATE_TIME_LDPATH = @BOOST_DATE_TIME_LDPATH@ BOOST_DATE_TIME_LIBS = @BOOST_DATE_TIME_LIBS@ BOOST_LDPATH = @BOOST_LDPATH@ BOOST_PROGRAM_OPTIONS_LDFLAGS = @BOOST_PROGRAM_OPTIONS_LDFLAGS@ BOOST_PROGRAM_OPTIONS_LDPATH = @BOOST_PROGRAM_OPTIONS_LDPATH@ BOOST_PROGRAM_OPTIONS_LIBS = @BOOST_PROGRAM_OPTIONS_LIBS@ BOOST_ROOT = @BOOST_ROOT@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPCHECK = @CPPCHECK@ CPPCHECK_PARALLELISM = @CPPCHECK_PARALLELISM@ CPPFLAGS = @CPPFLAGS@ CPPUNIT_CFLAGS = @CPPUNIT_CFLAGS@ CPPUNIT_LIBS = @CPPUNIT_LIBS@ CURL_CFLAGS = @CURL_CFLAGS@ CURL_LIBS = @CURL_LIBS@ CXX = @CXX@ CXXCPP = @CXXCPP@ CXXDEPMODE = @CXXDEPMODE@ CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DISTCHECK_CONFIGURE_FLAGS = @DISTCHECK_CONFIGURE_FLAGS@ DLLTOOL = @DLLTOOL@ DOCBOOK2MAN = @DOCBOOK2MAN@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ GENHTML = @GENHTML@ GREP = @GREP@ HAVE_CXX11 = @HAVE_CXX11@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LCOV = @LCOV@ LD = @LD@ LDFLAGS = @LDFLAGS@ LIBCMIS_API_VERSION = @LIBCMIS_API_VERSION@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ NPROC = @NPROC@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SRCDIR = @SRCDIR@ STRIP = @STRIP@ VERSION = @VERSION@ XML2_CFLAGS = @XML2_CFLAGS@ XML2_LIBS = @XML2_LIBS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ SUBDIRS = mockup libcmis libcmis-c all: all-recursive .SUFFIXES: $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign qa/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign qa/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs # This directory's subdirectories are mostly independent; you can cd # into them and run 'make' without going through this Makefile. # To change the values of 'make' variables: instead of editing Makefiles, # (1) if the variable is set in 'config.status', edit 'config.status' # (which will cause the Makefiles to be regenerated when you run 'make'); # (2) otherwise, pass the desired values on the 'make' command line. $(am__recursive_targets): @fail=; \ if $(am__make_keepgoing); then \ failcom='fail=yes'; \ else \ failcom='exit 1'; \ fi; \ dot_seen=no; \ target=`echo $@ | sed s/-recursive//`; \ case "$@" in \ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ *) list='$(SUBDIRS)' ;; \ esac; \ for subdir in $$list; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ dot_seen=yes; \ local_target="$$target-am"; \ else \ local_target="$$target"; \ fi; \ ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ || eval $$failcom; \ done; \ if test "$$dot_seen" = "no"; then \ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ fi; test -z "$$fail" ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique tags: tags-recursive TAGS: tags tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ include_option=--etags-include; \ empty_fix=.; \ else \ include_option=--include; \ empty_fix=; \ fi; \ list='$(SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ test ! -f $$subdir/TAGS || \ set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ fi; \ done; \ $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ if test $$# -gt 0; then \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ "$$@" $$unique; \ else \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$unique; \ fi; \ fi ctags: ctags-recursive CTAGS: ctags ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" cscopelist: cscopelist-recursive cscopelist-am: $(am__tagged_files) list='$(am__tagged_files)'; \ case "$(srcdir)" in \ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ *) sdir=$(subdir)/$(srcdir) ;; \ esac; \ for i in $$list; do \ if test -f "$$i"; then \ echo "$(subdir)/$$i"; \ else \ echo "$$sdir/$$i"; \ fi; \ done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ $(am__make_dryrun) \ || test -d "$(distdir)/$$subdir" \ || $(MKDIR_P) "$(distdir)/$$subdir" \ || exit 1; \ dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ $(am__relativize); \ new_distdir=$$reldir; \ dir1=$$subdir; dir2="$(top_distdir)"; \ $(am__relativize); \ new_top_distdir=$$reldir; \ echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ ($(am__cd) $$subdir && \ $(MAKE) $(AM_MAKEFLAGS) \ top_distdir="$$new_top_distdir" \ distdir="$$new_distdir" \ am__remove_distdir=: \ am__skip_length_check=: \ am__skip_mode_fix=: \ distdir) \ || exit 1; \ fi; \ done check-am: all-am check: check-recursive all-am: Makefile installdirs: installdirs-recursive installdirs-am: install: install-recursive install-exec: install-exec-recursive install-data: install-data-recursive uninstall: uninstall-recursive install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-recursive install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-recursive clean-am: clean-generic clean-libtool mostlyclean-am distclean: distclean-recursive -rm -f Makefile distclean-am: clean-am distclean-generic distclean-tags dvi: dvi-recursive dvi-am: html: html-recursive html-am: info: info-recursive info-am: install-data-am: install-dvi: install-dvi-recursive install-dvi-am: install-exec-am: install-html: install-html-recursive install-html-am: install-info: install-info-recursive install-info-am: install-man: install-pdf: install-pdf-recursive install-pdf-am: install-ps: install-ps-recursive install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-recursive -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-recursive mostlyclean-am: mostlyclean-generic mostlyclean-libtool pdf: pdf-recursive pdf-am: ps: ps-recursive ps-am: uninstall-am: .MAKE: $(am__recursive_targets) install-am install-strip .PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \ check-am clean clean-generic clean-libtool cscopelist-am ctags \ ctags-am distclean distclean-generic distclean-libtool \ distclean-tags distdir dvi dvi-am html html-am info info-am \ install install-am install-data install-data-am install-dvi \ install-dvi-am install-exec install-exec-am install-html \ install-html-am install-info install-info-am install-man \ install-pdf install-pdf-am install-ps install-ps-am \ install-strip installcheck installcheck-am installdirs \ installdirs-am maintainer-clean maintainer-clean-generic \ mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \ ps ps-am tags tags-am uninstall uninstall-am .PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: libcmis-0.5.2/qa/libcmis/0000775000175000017500000000000013411152401012156 500000000000000libcmis-0.5.2/qa/libcmis/test-xmlutils.cxx0000664000175000017500000006017213407451052015477 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include #include #include #include #include #include #if defined __clang__ #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wkeyword-macro" #endif #define private public #if defined __clang__ #pragma clang diagnostic pop #endif #include #include #include #include #include "test-helpers.hxx" using namespace boost; using namespace std; using namespace test; class XmlTest : public CppUnit::TestFixture { public: // Parser tests void parseDateTimeTest( ); void parseBoolTest( ); void parseIntegerTest( ); void parseDoubleTest( ); void parsePropertyStringTest( ); void parsePropertyIntegerTest( ); void parsePropertyDateTimeTest( ); void parsePropertyBoolTest( ); void parseEmptyPropertyTest( ); void parsePropertyNoTypeTest( ); void parseRenditionTest( ); void parseRepositoryCapabilitiesTest( ); // Writer tests void propertyStringAsXmlTest( ); void propertyIntegerAsXmlTest( ); // Other tests void sha1Test( ); void propertyTypeUpdateTest( ); void escapeTest( ); void unescapeTest( ); CPPUNIT_TEST_SUITE( XmlTest ); CPPUNIT_TEST( parseDateTimeTest ); CPPUNIT_TEST( parseBoolTest ); CPPUNIT_TEST( parseIntegerTest ); CPPUNIT_TEST( parseDoubleTest ); CPPUNIT_TEST( parsePropertyStringTest ); CPPUNIT_TEST( parsePropertyIntegerTest ); CPPUNIT_TEST( parsePropertyDateTimeTest ); CPPUNIT_TEST( parsePropertyBoolTest ); CPPUNIT_TEST( parseEmptyPropertyTest ); CPPUNIT_TEST( parsePropertyNoTypeTest ); CPPUNIT_TEST( parseRenditionTest ); CPPUNIT_TEST( parseRepositoryCapabilitiesTest ); CPPUNIT_TEST( propertyStringAsXmlTest ); CPPUNIT_TEST( propertyIntegerAsXmlTest ); CPPUNIT_TEST( sha1Test ); CPPUNIT_TEST( propertyTypeUpdateTest ); CPPUNIT_TEST( escapeTest ); CPPUNIT_TEST( unescapeTest ); CPPUNIT_TEST_SUITE_END( ); }; /** Dummy ObjectType implementation used as a PropertyType factory. */ class ObjectTypeDummy : public libcmis::ObjectType { public: ObjectTypeDummy( ); virtual ~ObjectTypeDummy() { }; }; ObjectTypeDummy::ObjectTypeDummy( ) { // String Property { libcmis::PropertyTypePtr prop ( new libcmis::PropertyType( ) ); prop->setId( string( "STR-ID" ) ); prop->setLocalName( string( "LOCAL" ) ); prop->setDisplayName( string( "DISPLAY" ) ); prop->setQueryName( string( "QUERY" ) ); prop->setTypeFromXml( "string" ); m_propertiesTypes.insert( pair< string, libcmis::PropertyTypePtr >( prop->getId( ), prop ) ); } // Integer Property { libcmis::PropertyTypePtr prop ( new libcmis::PropertyType( ) ); prop->setId( string( "INT-ID" ) ); prop->setLocalName( string( "LOCAL" ) ); prop->setDisplayName( string( "DISPLAY" ) ); prop->setQueryName( string( "QUERY" ) ); prop->setTypeFromXml( "integer" ); m_propertiesTypes.insert( pair< string, libcmis::PropertyTypePtr >( prop->getId( ), prop ) ); } // DateTime Property { libcmis::PropertyTypePtr prop ( new libcmis::PropertyType( ) ); prop->setId( string( "DATE-ID" ) ); prop->setLocalName( string( "LOCAL" ) ); prop->setDisplayName( string( "DISPLAY" ) ); prop->setQueryName( string( "QUERY" ) ); prop->setTypeFromXml( "datetime" ); m_propertiesTypes.insert( pair< string, libcmis::PropertyTypePtr >( prop->getId( ), prop ) ); } // Boolean Property { libcmis::PropertyTypePtr prop ( new libcmis::PropertyType( ) ); prop->setId( string( "BOOL-ID" ) ); prop->setLocalName( string( "LOCAL" ) ); prop->setDisplayName( string( "DISPLAY" ) ); prop->setQueryName( string( "QUERY" ) ); prop->setTypeFromXml( "boolean" ); m_propertiesTypes.insert( pair< string, libcmis::PropertyTypePtr >( prop->getId( ), prop ) ); } } void XmlTest::parseDateTimeTest( ) { tm basis; basis.tm_year = 2011 - 1900; basis.tm_mon = 8; // Months are in 0..11 range basis.tm_mday = 28; basis.tm_hour = 12; basis.tm_min = 44; basis.tm_sec = 28; // Broken strings { posix_time::ptime expected( boost::date_time::not_a_date_time ); posix_time::ptime t = libcmis::parseDateTime( string() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Broken time string case failed #1", expected, t ); char toParse[50]; strftime( toParse, sizeof( toParse ), "%FT", &basis ); t = libcmis::parseDateTime( string( toParse ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Broken time string case failed #2", expected, t ); strftime( toParse, sizeof( toParse ), "T%T", &basis ); t = libcmis::parseDateTime( string( toParse ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Broken time string case failed #3", expected, t ); strftime( toParse, sizeof( toParse ), "%T", &basis ); t = libcmis::parseDateTime( string( toParse ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Broken time string case failed #4", expected, t ); } // No time zone test { char toParse[50]; strftime( toParse, sizeof( toParse ), "%FT%T", &basis ); posix_time::ptime t = libcmis::parseDateTime( string( toParse ) ); gregorian::date expDate( basis.tm_year + 1900, basis.tm_mon + 1, basis.tm_mday ); posix_time::time_duration expTime( basis.tm_hour, basis.tm_min, basis.tm_sec ); posix_time::ptime expected( expDate, expTime ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "No time zone case failed", expected, t ); } // Z time zone test { char toParse[50]; strftime( toParse, sizeof( toParse ), "%FT%TZ", &basis ); posix_time::ptime t = libcmis::parseDateTime( string( toParse ) ); gregorian::date expDate( basis.tm_year + 1900, basis.tm_mon + 1, basis.tm_mday ); posix_time::time_duration expTime( basis.tm_hour, basis.tm_min, basis.tm_sec ); posix_time::ptime expected( expDate, expTime ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Z time zone case failed", expected, t ); } // +XX:XX time zone test { char toParse[50]; strftime( toParse, sizeof( toParse ), "%FT%T+02:00", &basis ); posix_time::ptime t = libcmis::parseDateTime( string( toParse ) ); gregorian::date expDate( basis.tm_year + 1900, basis.tm_mon + 1, basis.tm_mday ); posix_time::time_duration expTime( basis.tm_hour + 2, basis.tm_min, basis.tm_sec ); posix_time::ptime expected( expDate, expTime ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "+XX:XX time zone case failed", expected, t ); } // -XX:XX time zone test { char toParse[50]; strftime( toParse, sizeof( toParse ), "%FT%T-02:00", &basis ); posix_time::ptime t = libcmis::parseDateTime( string( toParse ) ); gregorian::date expDate( basis.tm_year + 1900, basis.tm_mon + 1, basis.tm_mday ); posix_time::time_duration expTime( basis.tm_hour - 2, basis.tm_min, basis.tm_sec ); posix_time::ptime expected( expDate, expTime ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "+XX:XX time zone case failed", expected, t ); } // Error test { posix_time::ptime t = libcmis::parseDateTime( string( "Nothing interesting 9990" ) ); CPPUNIT_ASSERT_MESSAGE( "Error case failed", t.is_not_a_date_time( ) ); } } void XmlTest::parseBoolTest( ) { // 'true' test { bool result = libcmis::parseBool( string( "true" ) ); CPPUNIT_ASSERT_MESSAGE( "'true' can't be parsed properly", result ); } // '1' test { bool result = libcmis::parseBool( string( "1" ) ); CPPUNIT_ASSERT_MESSAGE( "'1' can't be parsed properly", result ); } // 'false' test { bool result = libcmis::parseBool( string( "false" ) ); CPPUNIT_ASSERT_MESSAGE( "'false' can't be parsed properly", !result ); } // '0' test { bool result = libcmis::parseBool( string( "0" ) ); CPPUNIT_ASSERT_MESSAGE( "'0' can't be parsed properly", !result ); } // Error test { try { libcmis::parseBool( string( "boolcheat" ) ); CPPUNIT_FAIL( "Exception should be thrown" ); } catch ( const libcmis::Exception& e ) { CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad exception message", string( "Invalid xsd:boolean input: boolcheat" ), string( e.what() ) ); } } } void XmlTest::parseIntegerTest( ) { // Positive value test { long result = libcmis::parseInteger( string( "123" ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Positive integer can't be parsed properly", 123L, result ); } // Negative value test { long result = libcmis::parseInteger( string( "-123" ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Negative integer can't be parsed properly", -123L, result ); } // Overflow error test { try { libcmis::parseInteger( string( "9999999999999999999" ) ); CPPUNIT_FAIL( "Exception should be thrown" ); } catch ( const libcmis::Exception& e ) { CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad exception message", string( "xsd:integer input can't fit to long: 9999999999999999999" ), string( e.what() ) ); } } // Non integer test { try { libcmis::parseInteger( string( "123bad" ) ); CPPUNIT_FAIL( "Exception should be thrown" ); } catch ( const libcmis::Exception& e ) { CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad exception message", string( "Invalid xsd:integer input: 123bad" ), string( e.what() ) ); } } } void XmlTest::parseDoubleTest( ) { // Positive value test { double result = libcmis::parseDouble( string( "123.456" ) ); CPPUNIT_ASSERT_DOUBLES_EQUAL_MESSAGE( "Positive decimal can't be parsed properly", 123.456, result, 0.000001 ); } // Negative value test { double result = libcmis::parseDouble( string( "-123.456" ) ); CPPUNIT_ASSERT_DOUBLES_EQUAL_MESSAGE( "Negative decimal can't be parsed properly", -123.456, result, 0.000001 ); } // Non integer test { try { libcmis::parseDouble( string( "123.456bad" ) ); CPPUNIT_FAIL( "Exception should be thrown" ); } catch ( const libcmis::Exception& e ) { CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad exception message", string( "Invalid xsd:decimal input: 123.456bad" ), string( e.what() ) ); } } } void XmlTest::parsePropertyStringTest( ) { stringstream buf; buf << "" << "VALUE 1" << "VALUE 2" << ""; libcmis::ObjectTypePtr dummy( new ObjectTypeDummy( ) ); libcmis::PropertyPtr actual = libcmis::parseProperty( getXmlNode( buf.str( ) ), dummy ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong id parsed", string( "STR-ID" ), actual->getPropertyType( )->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of values parsed", vector::size_type( 2 ), actual->getStrings( ).size( ) ); } void XmlTest::parsePropertyIntegerTest( ) { stringstream buf; buf << "" << "12345" << "67890" << ""; libcmis::ObjectTypePtr dummy( new ObjectTypeDummy( ) ); libcmis::PropertyPtr actual = libcmis::parseProperty( getXmlNode( buf.str( ) ), dummy ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong id parsed", string( "INT-ID" ), actual->getPropertyType()->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of values parsed", vector::size_type( 2 ), actual->getLongs( ).size( ) ); } void XmlTest::parsePropertyDateTimeTest( ) { stringstream buf; buf << "" << "2012-01-19T09:06:57.388Z" << "2011-01-19T09:06:57.388Z" << ""; libcmis::ObjectTypePtr dummy( new ObjectTypeDummy( ) ); libcmis::PropertyPtr actual = libcmis::parseProperty( getXmlNode( buf.str( ) ), dummy ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong id parsed", string( "DATE-ID" ), actual->getPropertyType()->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of values parsed", vector::size_type( 2 ), actual->getDateTimes( ).size( ) ); } void XmlTest::parsePropertyBoolTest( ) { stringstream buf; buf << "" << "true" << ""; libcmis::ObjectTypePtr dummy( new ObjectTypeDummy( ) ); libcmis::PropertyPtr actual = libcmis::parseProperty( getXmlNode( buf.str( ) ), dummy ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong id parsed", string( "BOOL-ID" ), actual->getPropertyType()->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of values parsed", vector::size_type( 1 ), actual->getBools( ).size( ) ); } void XmlTest::parseEmptyPropertyTest( ) { stringstream buf; buf << ""; libcmis::ObjectTypePtr dummy( new ObjectTypeDummy( ) ); libcmis::PropertyPtr actual = libcmis::parseProperty( getXmlNode( buf.str( ) ), dummy ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong id parsed", string( "STR-ID" ), actual->getPropertyType()->getId( ) ); CPPUNIT_ASSERT_MESSAGE( "Should have no value", actual->getStrings( ).empty( ) ); } void XmlTest::parsePropertyNoTypeTest( ) { stringstream buf; buf << "" << "2012-01-19T09:06:57.388Z" << "2011-01-19T09:06:57.388Z" << ""; libcmis::ObjectTypePtr noType; libcmis::PropertyPtr actual = libcmis::parseProperty( getXmlNode( buf.str( ) ), noType ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong id parsed", string( "DATE-ID" ), actual->getPropertyType()->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of values parsed", vector::size_type( 2 ), actual->getDateTimes( ).size( ) ); } void XmlTest::parseRenditionTest( ) { stringstream buf; buf << "" << "STREAM-ID" << "MIME" << "123456" << "KIND" << "TITLE" << "123" << "456" << "DOC-ID" << ""; libcmis::RenditionPtr actual( new libcmis::Rendition( getXmlNode( buf.str( ) ) ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong stream id parsed", string( "STREAM-ID" ), actual->getStreamId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong mime type parsed", string( "MIME" ), actual->getMimeType( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong length parsed", long( 123456 ), actual->getLength( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong kind parsed", string( "KIND" ), actual->getKind( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong title parsed", string( "TITLE" ), actual->getTitle( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong height parsed", long( 123 ), actual->getHeight( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong width parsed", long( 456 ), actual->getWidth( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong rendition doc id parsed", string( "DOC-ID" ), actual->getRenditionDocumentId( ) ); } string lcl_findCapability( map< libcmis::Repository::Capability, string > store, libcmis::Repository::Capability capability ) { string result; map< libcmis::Repository::Capability, string >::iterator it = store.find( capability ); if ( it != store.end( ) ) result = it->second; return result; } void XmlTest::parseRepositoryCapabilitiesTest( ) { stringstream buf; buf << "" << "manage" << "false" << "none" << "anytime" << "true" << "true" << "common" << "true" << "false" << "true" << "bothcombined" << "read" << "false" << "false" << "none" << ""; map< libcmis::Repository::Capability, string > capabilities = libcmis::Repository::parseCapabilities( getXmlNode( buf.str( ) ) ); CPPUNIT_ASSERT_EQUAL( string( "manage" ), lcl_findCapability( capabilities, libcmis::Repository::ACL ) ); CPPUNIT_ASSERT_EQUAL( string( "false" ), lcl_findCapability( capabilities, libcmis::Repository::AllVersionsSearchable ) ); CPPUNIT_ASSERT_EQUAL( string( "none" ), lcl_findCapability( capabilities, libcmis::Repository::Changes ) ); CPPUNIT_ASSERT_EQUAL( string( "anytime" ), lcl_findCapability( capabilities, libcmis::Repository::ContentStreamUpdatability ) ); CPPUNIT_ASSERT_EQUAL( string( "true" ), lcl_findCapability( capabilities, libcmis::Repository::GetDescendants ) ); CPPUNIT_ASSERT_EQUAL( string( "true" ), lcl_findCapability( capabilities, libcmis::Repository::GetFolderTree ) ); CPPUNIT_ASSERT_EQUAL( string( "common" ), lcl_findCapability( capabilities, libcmis::Repository::OrderBy ) ); CPPUNIT_ASSERT_EQUAL( string( "true" ), lcl_findCapability( capabilities, libcmis::Repository::Multifiling ) ); CPPUNIT_ASSERT_EQUAL( string( "false" ), lcl_findCapability( capabilities, libcmis::Repository::PWCSearchable ) ); CPPUNIT_ASSERT_EQUAL( string( "true" ), lcl_findCapability( capabilities, libcmis::Repository::PWCUpdatable ) ); CPPUNIT_ASSERT_EQUAL( string( "bothcombined" ), lcl_findCapability( capabilities, libcmis::Repository::Query ) ); CPPUNIT_ASSERT_EQUAL( string( "read" ), lcl_findCapability( capabilities, libcmis::Repository::Renditions ) ); CPPUNIT_ASSERT_EQUAL( string( "false" ), lcl_findCapability( capabilities, libcmis::Repository::Unfiling ) ); CPPUNIT_ASSERT_EQUAL( string( "false" ), lcl_findCapability( capabilities, libcmis::Repository::VersionSpecificFiling ) ); CPPUNIT_ASSERT_EQUAL( string( "none" ), lcl_findCapability( capabilities, libcmis::Repository::Join ) ); } void XmlTest::propertyStringAsXmlTest( ) { vector< string > values; values.push_back( string( "Value 1" ) ); values.push_back( string( "Value 2" ) ); ObjectTypeDummy factory; map< string, libcmis::PropertyTypePtr >::iterator it = factory.getPropertiesTypes( ).find( "STR-ID" ); CPPUNIT_ASSERT_MESSAGE( "Missing property type to setup fixture", it != factory.getPropertiesTypes( ).end() ); libcmis::PropertyPtr property( new libcmis::Property( it->second, values ) ); string actual = writeXml( property ); stringstream expected; expected << "\n" << "" << "Value 1" << "Value 2" << "\n"; CPPUNIT_ASSERT_EQUAL( expected.str( ), actual ); } void XmlTest::propertyIntegerAsXmlTest( ) { vector< string > values; values.push_back( string( "123" ) ); values.push_back( string( "456" ) ); ObjectTypeDummy factory; map< string, libcmis::PropertyTypePtr >::iterator it = factory.getPropertiesTypes( ).find( "INT-ID" ); CPPUNIT_ASSERT_MESSAGE( "Missing property type to setup fixture", it != factory.getPropertiesTypes( ).end() ); libcmis::PropertyPtr property( new libcmis::Property( it->second, values ) ); string actual = writeXml( property ); stringstream expected; expected << "\n" << "" << "123" << "456" << "\n"; CPPUNIT_ASSERT_EQUAL( expected.str( ), actual ); } void XmlTest::sha1Test( ) { { string actual = libcmis::sha1( "Hello" ); CPPUNIT_ASSERT_EQUAL( string( "f7ff9e8b7bb2e09b70935a5d785e0cc5d9d0abf0" ), actual ); } { // check correct width string actual = libcmis::sha1( "35969137" ); CPPUNIT_ASSERT_EQUAL( string( "0d93546909cfeb5c00089202104df3980000ec9f" ), actual ); } } void XmlTest::propertyTypeUpdateTest( ) { libcmis::PropertyType propDef( "datetime", "DATE-ID", "", "", "" ); libcmis::ObjectTypePtr dummy( new ObjectTypeDummy( ) ); vector< libcmis::ObjectTypePtr > typeDefs; typeDefs.push_back( dummy ); propDef.update( typeDefs ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Not updated", string( "LOCAL" ), propDef.getLocalName( ) ); CPPUNIT_ASSERT_MESSAGE( "Property Type still marked temporary", !propDef.m_temporary ); } void XmlTest::escapeTest( ) { string actual = libcmis::escape("something to escape$"); CPPUNIT_ASSERT_EQUAL( string("something%20to%20escape%24"), actual); } void XmlTest::unescapeTest( ) { string actual = libcmis::unescape("something%20to%20escape%24"); CPPUNIT_ASSERT_EQUAL( string("something to escape$"), actual); } CPPUNIT_TEST_SUITE_REGISTRATION( XmlTest ); libcmis-0.5.2/qa/libcmis/Makefile.in0000664000175000017500000022532413407705041014164 00000000000000# Makefile.in generated by automake 1.16.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2018 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ check_PROGRAMS = test-json$(EXEEXT) test-utils$(EXEEXT) \ $(am__EXEEXT_1) @OS_WIN32_FALSE@am__append_1 = \ @OS_WIN32_FALSE@ test-mockup-helpers.cxx \ @OS_WIN32_FALSE@ test-mockup-helpers.hxx TESTS = test-utils$(EXEEXT) test-json$(EXEEXT) $(am__EXEEXT_1) subdir = qa/libcmis ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \ $(top_srcdir)/m4/ax_cxx_compile_stdcxx_11.m4 \ $(top_srcdir)/m4/ax_gcc_func_attribute.m4 \ $(top_srcdir)/m4/boost.m4 $(top_srcdir)/m4/libtool.m4 \ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = @OS_WIN32_FALSE@am__EXEEXT_1 = test-atom$(EXEEXT) \ @OS_WIN32_FALSE@ test-factory$(EXEEXT) test-gdrive$(EXEEXT) \ @OS_WIN32_FALSE@ test-onedrive$(EXEEXT) \ @OS_WIN32_FALSE@ test-sharepoint$(EXEEXT) test-ws$(EXEEXT) ARFLAGS = cru AM_V_AR = $(am__v_AR_@AM_V@) am__v_AR_ = $(am__v_AR_@AM_DEFAULT_V@) am__v_AR_0 = @echo " AR " $@; am__v_AR_1 = libtest_a_AR = $(AR) $(ARFLAGS) libtest_a_LIBADD = am__libtest_a_SOURCES_DIST = test-helpers.cxx test-helpers.hxx \ test-main.cxx test-mockup-helpers.cxx test-mockup-helpers.hxx @OS_WIN32_FALSE@am__objects_1 = \ @OS_WIN32_FALSE@ libtest_a-test-mockup-helpers.$(OBJEXT) am_libtest_a_OBJECTS = libtest_a-test-helpers.$(OBJEXT) \ libtest_a-test-main.$(OBJEXT) $(am__objects_1) libtest_a_OBJECTS = $(am_libtest_a_OBJECTS) am_test_atom_OBJECTS = test_atom-test-atom.$(OBJEXT) test_atom_OBJECTS = $(am_test_atom_OBJECTS) am__DEPENDENCIES_1 = test_atom_DEPENDENCIES = libtest.a \ $(top_builddir)/qa/mockup/libcmis-mockup.la \ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) AM_V_lt = $(am__v_lt_@AM_V@) am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) am__v_lt_0 = --silent am__v_lt_1 = am_test_factory_OBJECTS = test_factory-test-factory.$(OBJEXT) test_factory_OBJECTS = $(am_test_factory_OBJECTS) test_factory_DEPENDENCIES = libtest.a \ $(top_builddir)/qa/mockup/libcmis-mockup.la \ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) am_test_gdrive_OBJECTS = test_gdrive-test-gdrive.$(OBJEXT) test_gdrive_OBJECTS = $(am_test_gdrive_OBJECTS) test_gdrive_DEPENDENCIES = libtest.a \ $(top_builddir)/qa/mockup/libcmis-mockup.la \ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) am_test_json_OBJECTS = test_json-test-jsonutils.$(OBJEXT) test_json_OBJECTS = $(am_test_json_OBJECTS) test_json_DEPENDENCIES = libtest.a \ $(top_builddir)/src/libcmis/libcmis.la $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) am_test_onedrive_OBJECTS = test_onedrive-test-onedrive.$(OBJEXT) test_onedrive_OBJECTS = $(am_test_onedrive_OBJECTS) test_onedrive_DEPENDENCIES = libtest.a \ $(top_builddir)/qa/mockup/libcmis-mockup.la \ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) am_test_sharepoint_OBJECTS = \ test_sharepoint-test-sharepoint.$(OBJEXT) test_sharepoint_OBJECTS = $(am_test_sharepoint_OBJECTS) test_sharepoint_DEPENDENCIES = libtest.a \ $(top_builddir)/qa/mockup/libcmis-mockup.la \ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) am_test_utils_OBJECTS = test_utils-test-commons.$(OBJEXT) \ test_utils-test-decoder.$(OBJEXT) \ test_utils-test-soap.$(OBJEXT) \ test_utils-test-xmlutils.$(OBJEXT) test_utils_OBJECTS = $(am_test_utils_OBJECTS) test_utils_DEPENDENCIES = libtest.a \ $(top_builddir)/src/libcmis/libcmis.la $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) am_test_ws_OBJECTS = test_ws-test-ws.$(OBJEXT) test_ws_OBJECTS = $(am_test_ws_OBJECTS) test_ws_DEPENDENCIES = libtest.a \ $(top_builddir)/qa/mockup/libcmis-mockup.la \ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ depcomp = $(SHELL) $(top_srcdir)/depcomp am__maybe_remake_depfiles = depfiles am__depfiles_remade = ./$(DEPDIR)/libtest_a-test-helpers.Po \ ./$(DEPDIR)/libtest_a-test-main.Po \ ./$(DEPDIR)/libtest_a-test-mockup-helpers.Po \ ./$(DEPDIR)/test_atom-test-atom.Po \ ./$(DEPDIR)/test_factory-test-factory.Po \ ./$(DEPDIR)/test_gdrive-test-gdrive.Po \ ./$(DEPDIR)/test_json-test-jsonutils.Po \ ./$(DEPDIR)/test_onedrive-test-onedrive.Po \ ./$(DEPDIR)/test_sharepoint-test-sharepoint.Po \ ./$(DEPDIR)/test_utils-test-commons.Po \ ./$(DEPDIR)/test_utils-test-decoder.Po \ ./$(DEPDIR)/test_utils-test-soap.Po \ ./$(DEPDIR)/test_utils-test-xmlutils.Po \ ./$(DEPDIR)/test_ws-test-ws.Po am__mv = mv -f CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ $(AM_CXXFLAGS) $(CXXFLAGS) AM_V_CXX = $(am__v_CXX_@AM_V@) am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@) am__v_CXX_0 = @echo " CXX " $@; am__v_CXX_1 = CXXLD = $(CXX) CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \ $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ AM_V_CXXLD = $(am__v_CXXLD_@AM_V@) am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@) am__v_CXXLD_0 = @echo " CXXLD " $@; am__v_CXXLD_1 = COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ $(AM_CFLAGS) $(CFLAGS) AM_V_CC = $(am__v_CC_@AM_V@) am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) am__v_CC_0 = @echo " CC " $@; am__v_CC_1 = CCLD = $(CC) LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(AM_LDFLAGS) $(LDFLAGS) -o $@ AM_V_CCLD = $(am__v_CCLD_@AM_V@) am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) am__v_CCLD_0 = @echo " CCLD " $@; am__v_CCLD_1 = SOURCES = $(libtest_a_SOURCES) $(test_atom_SOURCES) \ $(test_factory_SOURCES) $(test_gdrive_SOURCES) \ $(test_json_SOURCES) $(test_onedrive_SOURCES) \ $(test_sharepoint_SOURCES) $(test_utils_SOURCES) \ $(test_ws_SOURCES) DIST_SOURCES = $(am__libtest_a_SOURCES_DIST) $(test_atom_SOURCES) \ $(test_factory_SOURCES) $(test_gdrive_SOURCES) \ $(test_json_SOURCES) $(test_onedrive_SOURCES) \ $(test_sharepoint_SOURCES) $(test_utils_SOURCES) \ $(test_ws_SOURCES) am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is # *not* preserved. am__uniquify_input = $(AWK) '\ BEGIN { nonempty = 0; } \ { items[$$0] = 1; nonempty = 1; } \ END { if (nonempty) { for (i in items) print i; }; } \ ' # Make sure the list of sources is unique. This is necessary because, # e.g., the same source file might be shared among _SOURCES variables # for different programs/libraries. am__define_uniq_tagged_files = \ list='$(am__tagged_files)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags am__tty_colors_dummy = \ mgn= red= grn= lgn= blu= brg= std=; \ am__color_tests=no am__tty_colors = { \ $(am__tty_colors_dummy); \ if test "X$(AM_COLOR_TESTS)" = Xno; then \ am__color_tests=no; \ elif test "X$(AM_COLOR_TESTS)" = Xalways; then \ am__color_tests=yes; \ elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \ am__color_tests=yes; \ fi; \ if test $$am__color_tests = yes; then \ red=''; \ grn=''; \ lgn=''; \ blu=''; \ mgn=''; \ brg=''; \ std=''; \ fi; \ } am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; am__install_max = 40 am__nobase_strip_setup = \ srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` am__nobase_strip = \ for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" am__nobase_list = $(am__nobase_strip_setup); \ for p in $$list; do echo "$$p $$p"; done | \ sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ if (++n[$$2] == $(am__install_max)) \ { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ END { for (dir in files) print dir, files[dir] }' am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' am__uninstall_files_from_dir = { \ test -z "$$files" \ || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ $(am__cd) "$$dir" && rm -f $$files; }; \ } am__recheck_rx = ^[ ]*:recheck:[ ]* am__global_test_result_rx = ^[ ]*:global-test-result:[ ]* am__copy_in_global_log_rx = ^[ ]*:copy-in-global-log:[ ]* # A command that, given a newline-separated list of test names on the # standard input, print the name of the tests that are to be re-run # upon "make recheck". am__list_recheck_tests = $(AWK) '{ \ recheck = 1; \ while ((rc = (getline line < ($$0 ".trs"))) != 0) \ { \ if (rc < 0) \ { \ if ((getline line2 < ($$0 ".log")) < 0) \ recheck = 0; \ break; \ } \ else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \ { \ recheck = 0; \ break; \ } \ else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \ { \ break; \ } \ }; \ if (recheck) \ print $$0; \ close ($$0 ".trs"); \ close ($$0 ".log"); \ }' # A command that, given a newline-separated list of test names on the # standard input, create the global log from their .trs and .log files. am__create_global_log = $(AWK) ' \ function fatal(msg) \ { \ print "fatal: making $@: " msg | "cat >&2"; \ exit 1; \ } \ function rst_section(header) \ { \ print header; \ len = length(header); \ for (i = 1; i <= len; i = i + 1) \ printf "="; \ printf "\n\n"; \ } \ { \ copy_in_global_log = 1; \ global_test_result = "RUN"; \ while ((rc = (getline line < ($$0 ".trs"))) != 0) \ { \ if (rc < 0) \ fatal("failed to read from " $$0 ".trs"); \ if (line ~ /$(am__global_test_result_rx)/) \ { \ sub("$(am__global_test_result_rx)", "", line); \ sub("[ ]*$$", "", line); \ global_test_result = line; \ } \ else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \ copy_in_global_log = 0; \ }; \ if (copy_in_global_log) \ { \ rst_section(global_test_result ": " $$0); \ while ((rc = (getline line < ($$0 ".log"))) != 0) \ { \ if (rc < 0) \ fatal("failed to read from " $$0 ".log"); \ print line; \ }; \ printf "\n"; \ }; \ close ($$0 ".trs"); \ close ($$0 ".log"); \ }' # Restructured Text title. am__rst_title = { sed 's/.*/ & /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; } # Solaris 10 'make', and several other traditional 'make' implementations, # pass "-e" to $(SHELL), and POSIX 2008 even requires this. Work around it # by disabling -e (using the XSI extension "set +e") if it's set. am__sh_e_setup = case $$- in *e*) set +e;; esac # Default flags passed to test drivers. am__common_driver_flags = \ --color-tests "$$am__color_tests" \ --enable-hard-errors "$$am__enable_hard_errors" \ --expect-failure "$$am__expect_failure" # To be inserted before the command running the test. Creates the # directory for the log if needed. Stores in $dir the directory # containing $f, in $tst the test, in $log the log. Executes the # developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and # passes TESTS_ENVIRONMENT. Set up options for the wrapper that # will run the test scripts (or their associated LOG_COMPILER, if # thy have one). am__check_pre = \ $(am__sh_e_setup); \ $(am__vpath_adj_setup) $(am__vpath_adj) \ $(am__tty_colors); \ srcdir=$(srcdir); export srcdir; \ case "$@" in \ */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;; \ *) am__odir=.;; \ esac; \ test "x$$am__odir" = x"." || test -d "$$am__odir" \ || $(MKDIR_P) "$$am__odir" || exit $$?; \ if test -f "./$$f"; then dir=./; \ elif test -f "$$f"; then dir=; \ else dir="$(srcdir)/"; fi; \ tst=$$dir$$f; log='$@'; \ if test -n '$(DISABLE_HARD_ERRORS)'; then \ am__enable_hard_errors=no; \ else \ am__enable_hard_errors=yes; \ fi; \ case " $(XFAIL_TESTS) " in \ *[\ \ ]$$f[\ \ ]* | *[\ \ ]$$dir$$f[\ \ ]*) \ am__expect_failure=yes;; \ *) \ am__expect_failure=no;; \ esac; \ $(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT) # A shell command to get the names of the tests scripts with any registered # extension removed (i.e., equivalently, the names of the test logs, with # the '.log' extension removed). The result is saved in the shell variable # '$bases'. This honors runtime overriding of TESTS and TEST_LOGS. Sadly, # we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)", # since that might cause problem with VPATH rewrites for suffix-less tests. # See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'. am__set_TESTS_bases = \ bases='$(TEST_LOGS)'; \ bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \ bases=`echo $$bases` RECHECK_LOGS = $(TEST_LOGS) AM_RECURSIVE_TARGETS = check recheck TEST_SUITE_LOG = test-suite.log TEST_EXTENSIONS = @EXEEXT@ .test LOG_DRIVER = $(SHELL) $(top_srcdir)/test-driver LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS) am__set_b = \ case '$@' in \ */*) \ case '$*' in \ */*) b='$*';; \ *) b=`echo '$@' | sed 's/\.log$$//'`; \ esac;; \ *) \ b='$*';; \ esac am__test_logs1 = $(TESTS:=.log) am__test_logs2 = $(am__test_logs1:@EXEEXT@.log=.log) TEST_LOGS = $(am__test_logs2:.test.log=.log) TEST_LOG_DRIVER = $(SHELL) $(top_srcdir)/test-driver TEST_LOG_COMPILE = $(TEST_LOG_COMPILER) $(AM_TEST_LOG_FLAGS) \ $(TEST_LOG_FLAGS) am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp \ $(top_srcdir)/test-driver DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ BOOST_CPPFLAGS = @BOOST_CPPFLAGS@ BOOST_DATE_TIME_LDFLAGS = @BOOST_DATE_TIME_LDFLAGS@ BOOST_DATE_TIME_LDPATH = @BOOST_DATE_TIME_LDPATH@ BOOST_DATE_TIME_LIBS = @BOOST_DATE_TIME_LIBS@ BOOST_LDPATH = @BOOST_LDPATH@ BOOST_PROGRAM_OPTIONS_LDFLAGS = @BOOST_PROGRAM_OPTIONS_LDFLAGS@ BOOST_PROGRAM_OPTIONS_LDPATH = @BOOST_PROGRAM_OPTIONS_LDPATH@ BOOST_PROGRAM_OPTIONS_LIBS = @BOOST_PROGRAM_OPTIONS_LIBS@ BOOST_ROOT = @BOOST_ROOT@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPCHECK = @CPPCHECK@ CPPCHECK_PARALLELISM = @CPPCHECK_PARALLELISM@ CPPFLAGS = @CPPFLAGS@ CPPUNIT_CFLAGS = @CPPUNIT_CFLAGS@ CPPUNIT_LIBS = @CPPUNIT_LIBS@ CURL_CFLAGS = @CURL_CFLAGS@ CURL_LIBS = @CURL_LIBS@ CXX = @CXX@ CXXCPP = @CXXCPP@ CXXDEPMODE = @CXXDEPMODE@ CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DISTCHECK_CONFIGURE_FLAGS = @DISTCHECK_CONFIGURE_FLAGS@ DLLTOOL = @DLLTOOL@ DOCBOOK2MAN = @DOCBOOK2MAN@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ GENHTML = @GENHTML@ GREP = @GREP@ HAVE_CXX11 = @HAVE_CXX11@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LCOV = @LCOV@ LD = @LD@ LDFLAGS = @LDFLAGS@ LIBCMIS_API_VERSION = @LIBCMIS_API_VERSION@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ NPROC = @NPROC@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SRCDIR = @SRCDIR@ STRIP = @STRIP@ VERSION = @VERSION@ XML2_CFLAGS = @XML2_CFLAGS@ XML2_LIBS = @XML2_LIBS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ @OS_WIN32_FALSE@mockup_tests = \ @OS_WIN32_FALSE@ test-atom \ @OS_WIN32_FALSE@ test-factory \ @OS_WIN32_FALSE@ test-gdrive \ @OS_WIN32_FALSE@ test-onedrive \ @OS_WIN32_FALSE@ test-sharepoint \ @OS_WIN32_FALSE@ test-ws check_LIBRARIES = \ libtest.a libtest_a_SOURCES = test-helpers.cxx test-helpers.hxx test-main.cxx \ $(am__append_1) libtest_a_CPPFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ -I$(top_srcdir)/qa/mockup \ $(XML2_CFLAGS) \ $(CURL_CFLAGS) \ $(BOOST_CPPFLAGS) test_utils_SOURCES = \ test-commons.cxx \ test-decoder.cxx \ test-soap.cxx \ test-xmlutils.cxx test_utils_CPPFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ $(XML2_CFLAGS) \ $(CURL_CFLAGS) \ $(BOOST_CPPFLAGS) test_utils_LDADD = \ libtest.a \ $(top_builddir)/src/libcmis/libcmis.la \ $(XML2_LIBS) \ $(CURL_LIBS) \ $(CPPUNIT_LIBS) \ $(BOOST_DATE_TIME_LIBS) test_atom_SOURCES = \ test-atom.cxx test_atom_CPPFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ -I$(top_srcdir)/qa/mockup \ $(XML2_CFLAGS) \ $(BOOST_CPPFLAGS) \ -DDATA_DIR=\"$(top_srcdir)/qa/libcmis/data\" test_atom_LDADD = \ libtest.a \ $(top_builddir)/qa/mockup/libcmis-mockup.la \ $(XML2_LIBS) \ $(CPPUNIT_LIBS) \ $(BOOST_DATE_TIME_LIBS) test_gdrive_SOURCES = \ test-gdrive.cxx test_gdrive_CPPFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ -I$(top_srcdir)/qa/mockup \ $(XML2_CFLAGS) \ $(BOOST_CPPFLAGS) \ -DDATA_DIR=\"$(top_srcdir)/qa/libcmis/data\" test_gdrive_LDADD = \ libtest.a \ $(top_builddir)/qa/mockup/libcmis-mockup.la \ $(XML2_LIBS) \ $(CPPUNIT_LIBS) \ $(BOOST_DATE_TIME_LIBS) test_onedrive_SOURCES = \ test-onedrive.cxx test_onedrive_CPPFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ -I$(top_srcdir)/qa/mockup \ $(XML2_CFLAGS) \ $(BOOST_CPPFLAGS) \ -DDATA_DIR=\"$(top_srcdir)/qa/libcmis/data\" test_onedrive_LDADD = \ libtest.a \ $(top_builddir)/qa/mockup/libcmis-mockup.la \ $(XML2_LIBS) \ $(CPPUNIT_LIBS) \ $(BOOST_DATE_TIME_LIBS) test_sharepoint_SOURCES = \ test-sharepoint.cxx test_sharepoint_CPPFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ -I$(top_srcdir)/qa/mockup \ $(XML2_CFLAGS) \ $(BOOST_CPPFLAGS) \ -DDATA_DIR=\"$(top_srcdir)/qa/libcmis/data\" test_sharepoint_LDADD = \ libtest.a \ $(top_builddir)/qa/mockup/libcmis-mockup.la \ $(XML2_LIBS) \ $(CPPUNIT_LIBS) \ $(BOOST_DATE_TIME_LIBS) test_ws_SOURCES = \ test-ws.cxx test_ws_CPPFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ -I$(top_srcdir)/qa/mockup \ $(XML2_CFLAGS) \ $(BOOST_CPPFLAGS) \ -DDATA_DIR=\"$(top_srcdir)/qa/libcmis/data\" test_ws_LDADD = \ libtest.a \ $(top_builddir)/qa/mockup/libcmis-mockup.la \ $(XML2_LIBS) \ $(CPPUNIT_LIBS) \ $(BOOST_DATE_TIME_LIBS) test_json_SOURCES = \ test-jsonutils.cxx test_json_CPPFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ $(XML2_CFLAGS) \ $(BOOST_CPPFLAGS) \ -DDATA_DIR=\"$(top_srcdir)/qa/libcmis/data\" test_json_LDADD = \ libtest.a \ $(top_builddir)/src/libcmis/libcmis.la \ $(XML2_LIBS) \ $(CPPUNIT_LIBS) \ $(CURL_LIBS) \ $(BOOST_DATE_TIME_LIBS) test_factory_SOURCES = \ test-factory.cxx test_factory_CPPFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ -I$(top_srcdir)/qa/mockup \ $(XML2_CFLAGS) \ $(BOOST_CPPFLAGS) \ -DDATA_DIR=\"$(top_srcdir)/qa/libcmis/data\" test_factory_LDADD = \ libtest.a \ $(top_builddir)/qa/mockup/libcmis-mockup.la \ $(XML2_LIBS) \ $(CPPUNIT_LIBS) \ $(BOOST_DATE_TIME_LIBS) all: all-am .SUFFIXES: .SUFFIXES: .cxx .lo .log .o .obj .test .test$(EXEEXT) .trs $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign qa/libcmis/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign qa/libcmis/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): clean-checkPROGRAMS: @list='$(check_PROGRAMS)'; test -n "$$list" || exit 0; \ echo " rm -f" $$list; \ rm -f $$list || exit $$?; \ test -n "$(EXEEXT)" || exit 0; \ list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list clean-checkLIBRARIES: -test -z "$(check_LIBRARIES)" || rm -f $(check_LIBRARIES) libtest.a: $(libtest_a_OBJECTS) $(libtest_a_DEPENDENCIES) $(EXTRA_libtest_a_DEPENDENCIES) $(AM_V_at)-rm -f libtest.a $(AM_V_AR)$(libtest_a_AR) libtest.a $(libtest_a_OBJECTS) $(libtest_a_LIBADD) $(AM_V_at)$(RANLIB) libtest.a test-atom$(EXEEXT): $(test_atom_OBJECTS) $(test_atom_DEPENDENCIES) $(EXTRA_test_atom_DEPENDENCIES) @rm -f test-atom$(EXEEXT) $(AM_V_CXXLD)$(CXXLINK) $(test_atom_OBJECTS) $(test_atom_LDADD) $(LIBS) test-factory$(EXEEXT): $(test_factory_OBJECTS) $(test_factory_DEPENDENCIES) $(EXTRA_test_factory_DEPENDENCIES) @rm -f test-factory$(EXEEXT) $(AM_V_CXXLD)$(CXXLINK) $(test_factory_OBJECTS) $(test_factory_LDADD) $(LIBS) test-gdrive$(EXEEXT): $(test_gdrive_OBJECTS) $(test_gdrive_DEPENDENCIES) $(EXTRA_test_gdrive_DEPENDENCIES) @rm -f test-gdrive$(EXEEXT) $(AM_V_CXXLD)$(CXXLINK) $(test_gdrive_OBJECTS) $(test_gdrive_LDADD) $(LIBS) test-json$(EXEEXT): $(test_json_OBJECTS) $(test_json_DEPENDENCIES) $(EXTRA_test_json_DEPENDENCIES) @rm -f test-json$(EXEEXT) $(AM_V_CXXLD)$(CXXLINK) $(test_json_OBJECTS) $(test_json_LDADD) $(LIBS) test-onedrive$(EXEEXT): $(test_onedrive_OBJECTS) $(test_onedrive_DEPENDENCIES) $(EXTRA_test_onedrive_DEPENDENCIES) @rm -f test-onedrive$(EXEEXT) $(AM_V_CXXLD)$(CXXLINK) $(test_onedrive_OBJECTS) $(test_onedrive_LDADD) $(LIBS) test-sharepoint$(EXEEXT): $(test_sharepoint_OBJECTS) $(test_sharepoint_DEPENDENCIES) $(EXTRA_test_sharepoint_DEPENDENCIES) @rm -f test-sharepoint$(EXEEXT) $(AM_V_CXXLD)$(CXXLINK) $(test_sharepoint_OBJECTS) $(test_sharepoint_LDADD) $(LIBS) test-utils$(EXEEXT): $(test_utils_OBJECTS) $(test_utils_DEPENDENCIES) $(EXTRA_test_utils_DEPENDENCIES) @rm -f test-utils$(EXEEXT) $(AM_V_CXXLD)$(CXXLINK) $(test_utils_OBJECTS) $(test_utils_LDADD) $(LIBS) test-ws$(EXEEXT): $(test_ws_OBJECTS) $(test_ws_DEPENDENCIES) $(EXTRA_test_ws_DEPENDENCIES) @rm -f test-ws$(EXEEXT) $(AM_V_CXXLD)$(CXXLINK) $(test_ws_OBJECTS) $(test_ws_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libtest_a-test-helpers.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libtest_a-test-main.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libtest_a-test-mockup-helpers.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_atom-test-atom.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_factory-test-factory.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_gdrive-test-gdrive.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_json-test-jsonutils.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_onedrive-test-onedrive.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_sharepoint-test-sharepoint.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_utils-test-commons.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_utils-test-decoder.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_utils-test-soap.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_utils-test-xmlutils.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_ws-test-ws.Po@am__quote@ # am--include-marker $(am__depfiles_remade): @$(MKDIR_P) $(@D) @echo '# dummy' >$@-t && $(am__mv) $@-t $@ am--depfiles: $(am__depfiles_remade) .cxx.o: @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $< .cxx.obj: @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .cxx.lo: @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LTCXXCOMPILE) -c -o $@ $< libtest_a-test-helpers.o: test-helpers.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libtest_a_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libtest_a-test-helpers.o -MD -MP -MF $(DEPDIR)/libtest_a-test-helpers.Tpo -c -o libtest_a-test-helpers.o `test -f 'test-helpers.cxx' || echo '$(srcdir)/'`test-helpers.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libtest_a-test-helpers.Tpo $(DEPDIR)/libtest_a-test-helpers.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-helpers.cxx' object='libtest_a-test-helpers.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libtest_a_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libtest_a-test-helpers.o `test -f 'test-helpers.cxx' || echo '$(srcdir)/'`test-helpers.cxx libtest_a-test-helpers.obj: test-helpers.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libtest_a_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libtest_a-test-helpers.obj -MD -MP -MF $(DEPDIR)/libtest_a-test-helpers.Tpo -c -o libtest_a-test-helpers.obj `if test -f 'test-helpers.cxx'; then $(CYGPATH_W) 'test-helpers.cxx'; else $(CYGPATH_W) '$(srcdir)/test-helpers.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libtest_a-test-helpers.Tpo $(DEPDIR)/libtest_a-test-helpers.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-helpers.cxx' object='libtest_a-test-helpers.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libtest_a_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libtest_a-test-helpers.obj `if test -f 'test-helpers.cxx'; then $(CYGPATH_W) 'test-helpers.cxx'; else $(CYGPATH_W) '$(srcdir)/test-helpers.cxx'; fi` libtest_a-test-main.o: test-main.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libtest_a_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libtest_a-test-main.o -MD -MP -MF $(DEPDIR)/libtest_a-test-main.Tpo -c -o libtest_a-test-main.o `test -f 'test-main.cxx' || echo '$(srcdir)/'`test-main.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libtest_a-test-main.Tpo $(DEPDIR)/libtest_a-test-main.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-main.cxx' object='libtest_a-test-main.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libtest_a_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libtest_a-test-main.o `test -f 'test-main.cxx' || echo '$(srcdir)/'`test-main.cxx libtest_a-test-main.obj: test-main.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libtest_a_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libtest_a-test-main.obj -MD -MP -MF $(DEPDIR)/libtest_a-test-main.Tpo -c -o libtest_a-test-main.obj `if test -f 'test-main.cxx'; then $(CYGPATH_W) 'test-main.cxx'; else $(CYGPATH_W) '$(srcdir)/test-main.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libtest_a-test-main.Tpo $(DEPDIR)/libtest_a-test-main.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-main.cxx' object='libtest_a-test-main.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libtest_a_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libtest_a-test-main.obj `if test -f 'test-main.cxx'; then $(CYGPATH_W) 'test-main.cxx'; else $(CYGPATH_W) '$(srcdir)/test-main.cxx'; fi` libtest_a-test-mockup-helpers.o: test-mockup-helpers.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libtest_a_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libtest_a-test-mockup-helpers.o -MD -MP -MF $(DEPDIR)/libtest_a-test-mockup-helpers.Tpo -c -o libtest_a-test-mockup-helpers.o `test -f 'test-mockup-helpers.cxx' || echo '$(srcdir)/'`test-mockup-helpers.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libtest_a-test-mockup-helpers.Tpo $(DEPDIR)/libtest_a-test-mockup-helpers.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-mockup-helpers.cxx' object='libtest_a-test-mockup-helpers.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libtest_a_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libtest_a-test-mockup-helpers.o `test -f 'test-mockup-helpers.cxx' || echo '$(srcdir)/'`test-mockup-helpers.cxx libtest_a-test-mockup-helpers.obj: test-mockup-helpers.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libtest_a_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT libtest_a-test-mockup-helpers.obj -MD -MP -MF $(DEPDIR)/libtest_a-test-mockup-helpers.Tpo -c -o libtest_a-test-mockup-helpers.obj `if test -f 'test-mockup-helpers.cxx'; then $(CYGPATH_W) 'test-mockup-helpers.cxx'; else $(CYGPATH_W) '$(srcdir)/test-mockup-helpers.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/libtest_a-test-mockup-helpers.Tpo $(DEPDIR)/libtest_a-test-mockup-helpers.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-mockup-helpers.cxx' object='libtest_a-test-mockup-helpers.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(libtest_a_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o libtest_a-test-mockup-helpers.obj `if test -f 'test-mockup-helpers.cxx'; then $(CYGPATH_W) 'test-mockup-helpers.cxx'; else $(CYGPATH_W) '$(srcdir)/test-mockup-helpers.cxx'; fi` test_atom-test-atom.o: test-atom.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_atom_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_atom-test-atom.o -MD -MP -MF $(DEPDIR)/test_atom-test-atom.Tpo -c -o test_atom-test-atom.o `test -f 'test-atom.cxx' || echo '$(srcdir)/'`test-atom.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_atom-test-atom.Tpo $(DEPDIR)/test_atom-test-atom.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-atom.cxx' object='test_atom-test-atom.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_atom_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_atom-test-atom.o `test -f 'test-atom.cxx' || echo '$(srcdir)/'`test-atom.cxx test_atom-test-atom.obj: test-atom.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_atom_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_atom-test-atom.obj -MD -MP -MF $(DEPDIR)/test_atom-test-atom.Tpo -c -o test_atom-test-atom.obj `if test -f 'test-atom.cxx'; then $(CYGPATH_W) 'test-atom.cxx'; else $(CYGPATH_W) '$(srcdir)/test-atom.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_atom-test-atom.Tpo $(DEPDIR)/test_atom-test-atom.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-atom.cxx' object='test_atom-test-atom.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_atom_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_atom-test-atom.obj `if test -f 'test-atom.cxx'; then $(CYGPATH_W) 'test-atom.cxx'; else $(CYGPATH_W) '$(srcdir)/test-atom.cxx'; fi` test_factory-test-factory.o: test-factory.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_factory_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_factory-test-factory.o -MD -MP -MF $(DEPDIR)/test_factory-test-factory.Tpo -c -o test_factory-test-factory.o `test -f 'test-factory.cxx' || echo '$(srcdir)/'`test-factory.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_factory-test-factory.Tpo $(DEPDIR)/test_factory-test-factory.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-factory.cxx' object='test_factory-test-factory.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_factory_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_factory-test-factory.o `test -f 'test-factory.cxx' || echo '$(srcdir)/'`test-factory.cxx test_factory-test-factory.obj: test-factory.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_factory_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_factory-test-factory.obj -MD -MP -MF $(DEPDIR)/test_factory-test-factory.Tpo -c -o test_factory-test-factory.obj `if test -f 'test-factory.cxx'; then $(CYGPATH_W) 'test-factory.cxx'; else $(CYGPATH_W) '$(srcdir)/test-factory.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_factory-test-factory.Tpo $(DEPDIR)/test_factory-test-factory.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-factory.cxx' object='test_factory-test-factory.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_factory_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_factory-test-factory.obj `if test -f 'test-factory.cxx'; then $(CYGPATH_W) 'test-factory.cxx'; else $(CYGPATH_W) '$(srcdir)/test-factory.cxx'; fi` test_gdrive-test-gdrive.o: test-gdrive.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_gdrive_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_gdrive-test-gdrive.o -MD -MP -MF $(DEPDIR)/test_gdrive-test-gdrive.Tpo -c -o test_gdrive-test-gdrive.o `test -f 'test-gdrive.cxx' || echo '$(srcdir)/'`test-gdrive.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_gdrive-test-gdrive.Tpo $(DEPDIR)/test_gdrive-test-gdrive.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-gdrive.cxx' object='test_gdrive-test-gdrive.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_gdrive_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_gdrive-test-gdrive.o `test -f 'test-gdrive.cxx' || echo '$(srcdir)/'`test-gdrive.cxx test_gdrive-test-gdrive.obj: test-gdrive.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_gdrive_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_gdrive-test-gdrive.obj -MD -MP -MF $(DEPDIR)/test_gdrive-test-gdrive.Tpo -c -o test_gdrive-test-gdrive.obj `if test -f 'test-gdrive.cxx'; then $(CYGPATH_W) 'test-gdrive.cxx'; else $(CYGPATH_W) '$(srcdir)/test-gdrive.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_gdrive-test-gdrive.Tpo $(DEPDIR)/test_gdrive-test-gdrive.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-gdrive.cxx' object='test_gdrive-test-gdrive.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_gdrive_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_gdrive-test-gdrive.obj `if test -f 'test-gdrive.cxx'; then $(CYGPATH_W) 'test-gdrive.cxx'; else $(CYGPATH_W) '$(srcdir)/test-gdrive.cxx'; fi` test_json-test-jsonutils.o: test-jsonutils.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_json_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_json-test-jsonutils.o -MD -MP -MF $(DEPDIR)/test_json-test-jsonutils.Tpo -c -o test_json-test-jsonutils.o `test -f 'test-jsonutils.cxx' || echo '$(srcdir)/'`test-jsonutils.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_json-test-jsonutils.Tpo $(DEPDIR)/test_json-test-jsonutils.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-jsonutils.cxx' object='test_json-test-jsonutils.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_json_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_json-test-jsonutils.o `test -f 'test-jsonutils.cxx' || echo '$(srcdir)/'`test-jsonutils.cxx test_json-test-jsonutils.obj: test-jsonutils.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_json_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_json-test-jsonutils.obj -MD -MP -MF $(DEPDIR)/test_json-test-jsonutils.Tpo -c -o test_json-test-jsonutils.obj `if test -f 'test-jsonutils.cxx'; then $(CYGPATH_W) 'test-jsonutils.cxx'; else $(CYGPATH_W) '$(srcdir)/test-jsonutils.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_json-test-jsonutils.Tpo $(DEPDIR)/test_json-test-jsonutils.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-jsonutils.cxx' object='test_json-test-jsonutils.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_json_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_json-test-jsonutils.obj `if test -f 'test-jsonutils.cxx'; then $(CYGPATH_W) 'test-jsonutils.cxx'; else $(CYGPATH_W) '$(srcdir)/test-jsonutils.cxx'; fi` test_onedrive-test-onedrive.o: test-onedrive.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_onedrive_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_onedrive-test-onedrive.o -MD -MP -MF $(DEPDIR)/test_onedrive-test-onedrive.Tpo -c -o test_onedrive-test-onedrive.o `test -f 'test-onedrive.cxx' || echo '$(srcdir)/'`test-onedrive.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_onedrive-test-onedrive.Tpo $(DEPDIR)/test_onedrive-test-onedrive.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-onedrive.cxx' object='test_onedrive-test-onedrive.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_onedrive_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_onedrive-test-onedrive.o `test -f 'test-onedrive.cxx' || echo '$(srcdir)/'`test-onedrive.cxx test_onedrive-test-onedrive.obj: test-onedrive.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_onedrive_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_onedrive-test-onedrive.obj -MD -MP -MF $(DEPDIR)/test_onedrive-test-onedrive.Tpo -c -o test_onedrive-test-onedrive.obj `if test -f 'test-onedrive.cxx'; then $(CYGPATH_W) 'test-onedrive.cxx'; else $(CYGPATH_W) '$(srcdir)/test-onedrive.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_onedrive-test-onedrive.Tpo $(DEPDIR)/test_onedrive-test-onedrive.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-onedrive.cxx' object='test_onedrive-test-onedrive.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_onedrive_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_onedrive-test-onedrive.obj `if test -f 'test-onedrive.cxx'; then $(CYGPATH_W) 'test-onedrive.cxx'; else $(CYGPATH_W) '$(srcdir)/test-onedrive.cxx'; fi` test_sharepoint-test-sharepoint.o: test-sharepoint.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_sharepoint_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_sharepoint-test-sharepoint.o -MD -MP -MF $(DEPDIR)/test_sharepoint-test-sharepoint.Tpo -c -o test_sharepoint-test-sharepoint.o `test -f 'test-sharepoint.cxx' || echo '$(srcdir)/'`test-sharepoint.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_sharepoint-test-sharepoint.Tpo $(DEPDIR)/test_sharepoint-test-sharepoint.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-sharepoint.cxx' object='test_sharepoint-test-sharepoint.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_sharepoint_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_sharepoint-test-sharepoint.o `test -f 'test-sharepoint.cxx' || echo '$(srcdir)/'`test-sharepoint.cxx test_sharepoint-test-sharepoint.obj: test-sharepoint.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_sharepoint_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_sharepoint-test-sharepoint.obj -MD -MP -MF $(DEPDIR)/test_sharepoint-test-sharepoint.Tpo -c -o test_sharepoint-test-sharepoint.obj `if test -f 'test-sharepoint.cxx'; then $(CYGPATH_W) 'test-sharepoint.cxx'; else $(CYGPATH_W) '$(srcdir)/test-sharepoint.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_sharepoint-test-sharepoint.Tpo $(DEPDIR)/test_sharepoint-test-sharepoint.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-sharepoint.cxx' object='test_sharepoint-test-sharepoint.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_sharepoint_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_sharepoint-test-sharepoint.obj `if test -f 'test-sharepoint.cxx'; then $(CYGPATH_W) 'test-sharepoint.cxx'; else $(CYGPATH_W) '$(srcdir)/test-sharepoint.cxx'; fi` test_utils-test-commons.o: test-commons.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_utils_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_utils-test-commons.o -MD -MP -MF $(DEPDIR)/test_utils-test-commons.Tpo -c -o test_utils-test-commons.o `test -f 'test-commons.cxx' || echo '$(srcdir)/'`test-commons.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_utils-test-commons.Tpo $(DEPDIR)/test_utils-test-commons.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-commons.cxx' object='test_utils-test-commons.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_utils_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_utils-test-commons.o `test -f 'test-commons.cxx' || echo '$(srcdir)/'`test-commons.cxx test_utils-test-commons.obj: test-commons.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_utils_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_utils-test-commons.obj -MD -MP -MF $(DEPDIR)/test_utils-test-commons.Tpo -c -o test_utils-test-commons.obj `if test -f 'test-commons.cxx'; then $(CYGPATH_W) 'test-commons.cxx'; else $(CYGPATH_W) '$(srcdir)/test-commons.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_utils-test-commons.Tpo $(DEPDIR)/test_utils-test-commons.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-commons.cxx' object='test_utils-test-commons.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_utils_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_utils-test-commons.obj `if test -f 'test-commons.cxx'; then $(CYGPATH_W) 'test-commons.cxx'; else $(CYGPATH_W) '$(srcdir)/test-commons.cxx'; fi` test_utils-test-decoder.o: test-decoder.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_utils_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_utils-test-decoder.o -MD -MP -MF $(DEPDIR)/test_utils-test-decoder.Tpo -c -o test_utils-test-decoder.o `test -f 'test-decoder.cxx' || echo '$(srcdir)/'`test-decoder.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_utils-test-decoder.Tpo $(DEPDIR)/test_utils-test-decoder.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-decoder.cxx' object='test_utils-test-decoder.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_utils_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_utils-test-decoder.o `test -f 'test-decoder.cxx' || echo '$(srcdir)/'`test-decoder.cxx test_utils-test-decoder.obj: test-decoder.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_utils_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_utils-test-decoder.obj -MD -MP -MF $(DEPDIR)/test_utils-test-decoder.Tpo -c -o test_utils-test-decoder.obj `if test -f 'test-decoder.cxx'; then $(CYGPATH_W) 'test-decoder.cxx'; else $(CYGPATH_W) '$(srcdir)/test-decoder.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_utils-test-decoder.Tpo $(DEPDIR)/test_utils-test-decoder.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-decoder.cxx' object='test_utils-test-decoder.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_utils_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_utils-test-decoder.obj `if test -f 'test-decoder.cxx'; then $(CYGPATH_W) 'test-decoder.cxx'; else $(CYGPATH_W) '$(srcdir)/test-decoder.cxx'; fi` test_utils-test-soap.o: test-soap.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_utils_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_utils-test-soap.o -MD -MP -MF $(DEPDIR)/test_utils-test-soap.Tpo -c -o test_utils-test-soap.o `test -f 'test-soap.cxx' || echo '$(srcdir)/'`test-soap.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_utils-test-soap.Tpo $(DEPDIR)/test_utils-test-soap.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-soap.cxx' object='test_utils-test-soap.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_utils_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_utils-test-soap.o `test -f 'test-soap.cxx' || echo '$(srcdir)/'`test-soap.cxx test_utils-test-soap.obj: test-soap.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_utils_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_utils-test-soap.obj -MD -MP -MF $(DEPDIR)/test_utils-test-soap.Tpo -c -o test_utils-test-soap.obj `if test -f 'test-soap.cxx'; then $(CYGPATH_W) 'test-soap.cxx'; else $(CYGPATH_W) '$(srcdir)/test-soap.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_utils-test-soap.Tpo $(DEPDIR)/test_utils-test-soap.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-soap.cxx' object='test_utils-test-soap.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_utils_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_utils-test-soap.obj `if test -f 'test-soap.cxx'; then $(CYGPATH_W) 'test-soap.cxx'; else $(CYGPATH_W) '$(srcdir)/test-soap.cxx'; fi` test_utils-test-xmlutils.o: test-xmlutils.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_utils_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_utils-test-xmlutils.o -MD -MP -MF $(DEPDIR)/test_utils-test-xmlutils.Tpo -c -o test_utils-test-xmlutils.o `test -f 'test-xmlutils.cxx' || echo '$(srcdir)/'`test-xmlutils.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_utils-test-xmlutils.Tpo $(DEPDIR)/test_utils-test-xmlutils.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-xmlutils.cxx' object='test_utils-test-xmlutils.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_utils_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_utils-test-xmlutils.o `test -f 'test-xmlutils.cxx' || echo '$(srcdir)/'`test-xmlutils.cxx test_utils-test-xmlutils.obj: test-xmlutils.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_utils_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_utils-test-xmlutils.obj -MD -MP -MF $(DEPDIR)/test_utils-test-xmlutils.Tpo -c -o test_utils-test-xmlutils.obj `if test -f 'test-xmlutils.cxx'; then $(CYGPATH_W) 'test-xmlutils.cxx'; else $(CYGPATH_W) '$(srcdir)/test-xmlutils.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_utils-test-xmlutils.Tpo $(DEPDIR)/test_utils-test-xmlutils.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-xmlutils.cxx' object='test_utils-test-xmlutils.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_utils_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_utils-test-xmlutils.obj `if test -f 'test-xmlutils.cxx'; then $(CYGPATH_W) 'test-xmlutils.cxx'; else $(CYGPATH_W) '$(srcdir)/test-xmlutils.cxx'; fi` test_ws-test-ws.o: test-ws.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_ws_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_ws-test-ws.o -MD -MP -MF $(DEPDIR)/test_ws-test-ws.Tpo -c -o test_ws-test-ws.o `test -f 'test-ws.cxx' || echo '$(srcdir)/'`test-ws.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_ws-test-ws.Tpo $(DEPDIR)/test_ws-test-ws.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-ws.cxx' object='test_ws-test-ws.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_ws_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_ws-test-ws.o `test -f 'test-ws.cxx' || echo '$(srcdir)/'`test-ws.cxx test_ws-test-ws.obj: test-ws.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_ws_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_ws-test-ws.obj -MD -MP -MF $(DEPDIR)/test_ws-test-ws.Tpo -c -o test_ws-test-ws.obj `if test -f 'test-ws.cxx'; then $(CYGPATH_W) 'test-ws.cxx'; else $(CYGPATH_W) '$(srcdir)/test-ws.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_ws-test-ws.Tpo $(DEPDIR)/test_ws-test-ws.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-ws.cxx' object='test_ws-test-ws.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(test_ws_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_ws-test-ws.obj `if test -f 'test-ws.cxx'; then $(CYGPATH_W) 'test-ws.cxx'; else $(CYGPATH_W) '$(srcdir)/test-ws.cxx'; fi` mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique tags: tags-am TAGS: tags tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ if test $$# -gt 0; then \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ "$$@" $$unique; \ else \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$unique; \ fi; \ fi ctags: ctags-am CTAGS: ctags ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" cscopelist: cscopelist-am cscopelist-am: $(am__tagged_files) list='$(am__tagged_files)'; \ case "$(srcdir)" in \ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ *) sdir=$(subdir)/$(srcdir) ;; \ esac; \ for i in $$list; do \ if test -f "$$i"; then \ echo "$(subdir)/$$i"; \ else \ echo "$$sdir/$$i"; \ fi; \ done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags # Recover from deleted '.trs' file; this should ensure that # "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create # both 'foo.log' and 'foo.trs'. Break the recipe in two subshells # to avoid problems with "make -n". .log.trs: rm -f $< $@ $(MAKE) $(AM_MAKEFLAGS) $< # Leading 'am--fnord' is there to ensure the list of targets does not # expand to empty, as could happen e.g. with make check TESTS=''. am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck) am--force-recheck: @: $(TEST_SUITE_LOG): $(TEST_LOGS) @$(am__set_TESTS_bases); \ am__f_ok () { test -f "$$1" && test -r "$$1"; }; \ redo_bases=`for i in $$bases; do \ am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \ done`; \ if test -n "$$redo_bases"; then \ redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \ redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \ if $(am__make_dryrun); then :; else \ rm -f $$redo_logs && rm -f $$redo_results || exit 1; \ fi; \ fi; \ if test -n "$$am__remaking_logs"; then \ echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \ "recursion detected" >&2; \ elif test -n "$$redo_logs"; then \ am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \ fi; \ if $(am__make_dryrun); then :; else \ st=0; \ errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \ for i in $$redo_bases; do \ test -f $$i.trs && test -r $$i.trs \ || { echo "$$errmsg $$i.trs" >&2; st=1; }; \ test -f $$i.log && test -r $$i.log \ || { echo "$$errmsg $$i.log" >&2; st=1; }; \ done; \ test $$st -eq 0 || exit 1; \ fi @$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \ ws='[ ]'; \ results=`for b in $$bases; do echo $$b.trs; done`; \ test -n "$$results" || results=/dev/null; \ all=` grep "^$$ws*:test-result:" $$results | wc -l`; \ pass=` grep "^$$ws*:test-result:$$ws*PASS" $$results | wc -l`; \ fail=` grep "^$$ws*:test-result:$$ws*FAIL" $$results | wc -l`; \ skip=` grep "^$$ws*:test-result:$$ws*SKIP" $$results | wc -l`; \ xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \ xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \ error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \ if test `expr $$fail + $$xpass + $$error` -eq 0; then \ success=true; \ else \ success=false; \ fi; \ br='==================='; br=$$br$$br$$br$$br; \ result_count () \ { \ if test x"$$1" = x"--maybe-color"; then \ maybe_colorize=yes; \ elif test x"$$1" = x"--no-color"; then \ maybe_colorize=no; \ else \ echo "$@: invalid 'result_count' usage" >&2; exit 4; \ fi; \ shift; \ desc=$$1 count=$$2; \ if test $$maybe_colorize = yes && test $$count -gt 0; then \ color_start=$$3 color_end=$$std; \ else \ color_start= color_end=; \ fi; \ echo "$${color_start}# $$desc $$count$${color_end}"; \ }; \ create_testsuite_report () \ { \ result_count $$1 "TOTAL:" $$all "$$brg"; \ result_count $$1 "PASS: " $$pass "$$grn"; \ result_count $$1 "SKIP: " $$skip "$$blu"; \ result_count $$1 "XFAIL:" $$xfail "$$lgn"; \ result_count $$1 "FAIL: " $$fail "$$red"; \ result_count $$1 "XPASS:" $$xpass "$$red"; \ result_count $$1 "ERROR:" $$error "$$mgn"; \ }; \ { \ echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" | \ $(am__rst_title); \ create_testsuite_report --no-color; \ echo; \ echo ".. contents:: :depth: 2"; \ echo; \ for b in $$bases; do echo $$b; done \ | $(am__create_global_log); \ } >$(TEST_SUITE_LOG).tmp || exit 1; \ mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG); \ if $$success; then \ col="$$grn"; \ else \ col="$$red"; \ test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG); \ fi; \ echo "$${col}$$br$${std}"; \ echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}"; \ echo "$${col}$$br$${std}"; \ create_testsuite_report --maybe-color; \ echo "$$col$$br$$std"; \ if $$success; then :; else \ echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}"; \ if test -n "$(PACKAGE_BUGREPORT)"; then \ echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}"; \ fi; \ echo "$$col$$br$$std"; \ fi; \ $$success || exit 1 check-TESTS: $(check_PROGRAMS) $(check_LIBRARIES) @list='$(RECHECK_LOGS)'; test -z "$$list" || rm -f $$list @list='$(RECHECK_LOGS:.log=.trs)'; test -z "$$list" || rm -f $$list @test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) @set +e; $(am__set_TESTS_bases); \ log_list=`for i in $$bases; do echo $$i.log; done`; \ trs_list=`for i in $$bases; do echo $$i.trs; done`; \ log_list=`echo $$log_list`; trs_list=`echo $$trs_list`; \ $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) TEST_LOGS="$$log_list"; \ exit $$?; recheck: all $(check_PROGRAMS) $(check_LIBRARIES) @test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) @set +e; $(am__set_TESTS_bases); \ bases=`for i in $$bases; do echo $$i; done \ | $(am__list_recheck_tests)` || exit 1; \ log_list=`for i in $$bases; do echo $$i.log; done`; \ log_list=`echo $$log_list`; \ $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \ am__force_recheck=am--force-recheck \ TEST_LOGS="$$log_list"; \ exit $$? test-utils.log: test-utils$(EXEEXT) @p='test-utils$(EXEEXT)'; \ b='test-utils'; \ $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ --log-file $$b.log --trs-file $$b.trs \ $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ "$$tst" $(AM_TESTS_FD_REDIRECT) test-json.log: test-json$(EXEEXT) @p='test-json$(EXEEXT)'; \ b='test-json'; \ $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ --log-file $$b.log --trs-file $$b.trs \ $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ "$$tst" $(AM_TESTS_FD_REDIRECT) test-atom.log: test-atom$(EXEEXT) @p='test-atom$(EXEEXT)'; \ b='test-atom'; \ $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ --log-file $$b.log --trs-file $$b.trs \ $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ "$$tst" $(AM_TESTS_FD_REDIRECT) test-factory.log: test-factory$(EXEEXT) @p='test-factory$(EXEEXT)'; \ b='test-factory'; \ $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ --log-file $$b.log --trs-file $$b.trs \ $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ "$$tst" $(AM_TESTS_FD_REDIRECT) test-gdrive.log: test-gdrive$(EXEEXT) @p='test-gdrive$(EXEEXT)'; \ b='test-gdrive'; \ $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ --log-file $$b.log --trs-file $$b.trs \ $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ "$$tst" $(AM_TESTS_FD_REDIRECT) test-onedrive.log: test-onedrive$(EXEEXT) @p='test-onedrive$(EXEEXT)'; \ b='test-onedrive'; \ $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ --log-file $$b.log --trs-file $$b.trs \ $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ "$$tst" $(AM_TESTS_FD_REDIRECT) test-sharepoint.log: test-sharepoint$(EXEEXT) @p='test-sharepoint$(EXEEXT)'; \ b='test-sharepoint'; \ $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ --log-file $$b.log --trs-file $$b.trs \ $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ "$$tst" $(AM_TESTS_FD_REDIRECT) test-ws.log: test-ws$(EXEEXT) @p='test-ws$(EXEEXT)'; \ b='test-ws'; \ $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ --log-file $$b.log --trs-file $$b.trs \ $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ "$$tst" $(AM_TESTS_FD_REDIRECT) .test.log: @p='$<'; \ $(am__set_b); \ $(am__check_pre) $(TEST_LOG_DRIVER) --test-name "$$f" \ --log-file $$b.log --trs-file $$b.trs \ $(am__common_driver_flags) $(AM_TEST_LOG_DRIVER_FLAGS) $(TEST_LOG_DRIVER_FLAGS) -- $(TEST_LOG_COMPILE) \ "$$tst" $(AM_TESTS_FD_REDIRECT) @am__EXEEXT_TRUE@.test$(EXEEXT).log: @am__EXEEXT_TRUE@ @p='$<'; \ @am__EXEEXT_TRUE@ $(am__set_b); \ @am__EXEEXT_TRUE@ $(am__check_pre) $(TEST_LOG_DRIVER) --test-name "$$f" \ @am__EXEEXT_TRUE@ --log-file $$b.log --trs-file $$b.trs \ @am__EXEEXT_TRUE@ $(am__common_driver_flags) $(AM_TEST_LOG_DRIVER_FLAGS) $(TEST_LOG_DRIVER_FLAGS) -- $(TEST_LOG_COMPILE) \ @am__EXEEXT_TRUE@ "$$tst" $(AM_TESTS_FD_REDIRECT) distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done check-am: all-am $(MAKE) $(AM_MAKEFLAGS) $(check_PROGRAMS) $(check_LIBRARIES) $(MAKE) $(AM_MAKEFLAGS) check-TESTS check: check-am all-am: Makefile installdirs: install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: -test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS) -test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs) -test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-checkLIBRARIES clean-checkPROGRAMS clean-generic \ clean-libtool mostlyclean-am distclean: distclean-am -rm -f ./$(DEPDIR)/libtest_a-test-helpers.Po -rm -f ./$(DEPDIR)/libtest_a-test-main.Po -rm -f ./$(DEPDIR)/libtest_a-test-mockup-helpers.Po -rm -f ./$(DEPDIR)/test_atom-test-atom.Po -rm -f ./$(DEPDIR)/test_factory-test-factory.Po -rm -f ./$(DEPDIR)/test_gdrive-test-gdrive.Po -rm -f ./$(DEPDIR)/test_json-test-jsonutils.Po -rm -f ./$(DEPDIR)/test_onedrive-test-onedrive.Po -rm -f ./$(DEPDIR)/test_sharepoint-test-sharepoint.Po -rm -f ./$(DEPDIR)/test_utils-test-commons.Po -rm -f ./$(DEPDIR)/test_utils-test-decoder.Po -rm -f ./$(DEPDIR)/test_utils-test-soap.Po -rm -f ./$(DEPDIR)/test_utils-test-xmlutils.Po -rm -f ./$(DEPDIR)/test_ws-test-ws.Po -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-tags dvi: dvi-am dvi-am: html: html-am html-am: info: info-am info-am: install-data-am: install-dvi: install-dvi-am install-dvi-am: install-exec-am: install-html: install-html-am install-html-am: install-info: install-info-am install-info-am: install-man: install-pdf: install-pdf-am install-pdf-am: install-ps: install-ps-am install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am -rm -f ./$(DEPDIR)/libtest_a-test-helpers.Po -rm -f ./$(DEPDIR)/libtest_a-test-main.Po -rm -f ./$(DEPDIR)/libtest_a-test-mockup-helpers.Po -rm -f ./$(DEPDIR)/test_atom-test-atom.Po -rm -f ./$(DEPDIR)/test_factory-test-factory.Po -rm -f ./$(DEPDIR)/test_gdrive-test-gdrive.Po -rm -f ./$(DEPDIR)/test_json-test-jsonutils.Po -rm -f ./$(DEPDIR)/test_onedrive-test-onedrive.Po -rm -f ./$(DEPDIR)/test_sharepoint-test-sharepoint.Po -rm -f ./$(DEPDIR)/test_utils-test-commons.Po -rm -f ./$(DEPDIR)/test_utils-test-decoder.Po -rm -f ./$(DEPDIR)/test_utils-test-soap.Po -rm -f ./$(DEPDIR)/test_utils-test-xmlutils.Po -rm -f ./$(DEPDIR)/test_ws-test-ws.Po -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: .MAKE: check-am install-am install-strip .PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-TESTS \ check-am clean clean-checkLIBRARIES clean-checkPROGRAMS \ clean-generic clean-libtool cscopelist-am ctags ctags-am \ distclean distclean-compile distclean-generic \ distclean-libtool distclean-tags distdir dvi dvi-am html \ html-am info info-am install install-am install-data \ install-data-am install-dvi install-dvi-am install-exec \ install-exec-am install-html install-html-am install-info \ install-info-am install-man install-pdf install-pdf-am \ install-ps install-ps-am install-strip installcheck \ installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ recheck tags tags-am uninstall uninstall-am .PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: libcmis-0.5.2/qa/libcmis/test-helpers.hxx0000664000175000017500000000406113407414352015262 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include #include #include #include #include namespace test { class XmlNodeRef { public: XmlNodeRef( xmlNodePtr node, boost::shared_ptr< xmlDoc > doc ); XmlNodeRef( const XmlNodeRef& other ); XmlNodeRef& operator=( const XmlNodeRef& other ); operator xmlNodePtr( ) const; private: xmlNodePtr m_node; boost::shared_ptr< xmlDoc > m_doc; }; // Test helper functions for parser and writer tests XmlNodeRef getXmlNode( std::string str ); const char* getXmlns( ); std::string writeXml( boost::shared_ptr< libcmis::XmlSerializable > serializable ); std::string getXmlNodeAsString( const std::string& xmlDoc, const std::string& xpath ); libcmis::DocumentPtr createVersionableDocument( libcmis::Session* session, std::string docName ); void loadFromFile( const char* path, std::string& buf ); } libcmis-0.5.2/qa/libcmis/test-ws.cxx0000664000175000017500000022234013407173247014253 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include #include #if defined __clang__ #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wkeyword-macro" #endif #define private public #define protected public #if defined __clang__ #pragma clang diagnostic pop #endif #include #include #include #include #include #define SERVER_URL string( "http://mockup/ws" ) #define SERVER_REPOSITORY string( "mock" ) #define SERVER_USERNAME "tester" #define SERVER_PASSWORD "somepass" using namespace std; using libcmis::PropertyPtrMap; namespace { string lcl_getStreamAsString( boost::shared_ptr< istream > is ) { is->seekg( 0, ios::end ); long size = is->tellg( ); is->seekg( 0, ios::beg ); char* buf = new char[ size ]; is->read( buf, size ); string content( buf, size ); delete[ ] buf; return content; } string lcl_getCmisRequestXml( string url, const char* bodyMatch = NULL ) { const struct HttpRequest* request = curl_mockup_getRequest( url.c_str(), "", "POST", bodyMatch ); char* contentType = curl_mockup_HttpRequest_getHeader( request, "Content-Type" ); RelatedMultipart multipart( request->body, string( contentType ) ); RelatedPartPtr part = multipart.getPart( multipart.getStartId() ); string xml = part->getContent( ); curl_mockup_HttpRequest_free( request ); free( contentType ); string requestStr = test::getXmlNodeAsString( xml, "/soap-env:Envelope/soap-env:Body/child::*" ); // Obfuscate the xop:Include ids string xopSearch = " actual = session.getRepositoryService().getRepositories( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of repositories", size_t( 1 ), actual.size( ) ); // Test the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/RepositoryService" ); string expectedRequest = ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::getRepositoryInfosTest() { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/repository-infos.http" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); string validId = "mock"; libcmis::RepositoryPtr actual = session.getRepositoryService().getRepositoryInfo( validId ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Root folder is wrong", string( "root-folder" ), actual->getRootId( ) ); // Test the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/RepositoryService" ); string expectedRequest = "" "" + validId + "" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::getRepositoryInfosBadTest() { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/repository-infos-bad.http" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); string badId = "bad"; try { session.getRepositoryService().getRepositoryInfo( badId ); } catch( const libcmis::Exception& e ) { // Test the caught exception CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong exception type", string( "invalidArgument" ), e.getType( ) ); // Test the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/RepositoryService" ); string expectedRequest = "" "" + badId + "" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } } void WSTest::getTypeTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-folder.http" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); string id( "cmis:folder" ); libcmis::ObjectTypePtr actual = session.getType( id ); // Check the returned type CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong id", id, actual->getId( ) ); // Check the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/RepositoryService" ); string expectedRequest = "" "mock" "" + id + "" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::getTypeRefreshTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-docLevel2.http" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); string id( "DocumentLevel2" ); libcmis::ObjectTypePtr actual = session.getType( id ); // Check the returned type CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong id", id, actual->getId( ) ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-docLevel1.http" ); // Do the refresh actual->refresh(); // Check the refreshed object CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong id", string( "DocumentLevel1" ), actual->getId( ) ); } void WSTest::objectTypeCopyTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-folder.http" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); string id( "cmis:folder" ); libcmis::ObjectTypePtr expected = session.getType( id ); WSObjectType* type = dynamic_cast< WSObjectType* >( expected.get( ) ); { WSObjectType copy( *type ); CPPUNIT_ASSERT_EQUAL( type->getId( ), copy.getId( ) ); CPPUNIT_ASSERT_EQUAL( type->m_session, copy.m_session ); } { WSObjectType copy; copy = *type; CPPUNIT_ASSERT_EQUAL( type->getId( ), copy.getId( ) ); CPPUNIT_ASSERT_EQUAL( type->m_session, copy.m_session ); } } void WSTest::getUnexistantTypeTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-bad.http" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); string id( "bad_type" ); try { session.getType( id ); } catch ( const libcmis::Exception& e ) { // Check the caught exception CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong error type", string( "objectNotFound" ), e.getType() ); // Check the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/RepositoryService" ); string expectedRequest = "" "mock" "" + id + "" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } } void WSTest::getTypeParentsTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-docLevel2.http", "DocumentLevel2" ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-docLevel1.http", "DocumentLevel1" ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-document.http", "cmis:document" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); string id = "DocumentLevel2"; libcmis::ObjectTypePtr actual = session.getType( id ); // Check the resulting type CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong Parent type Id", string( "DocumentLevel1" ), actual->getParentTypeId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong Base type Id", string( "cmis:document" ), actual->getBaseTypeId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong Parent type", string( "DocumentLevel1" ), actual->getParentType()->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong Base type", string( "cmis:document" ), actual->getBaseType()->getId( ) ); // Check the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/RepositoryService" ); string expectedRequest = "" "mock" "" + id + "" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::getTypeChildrenTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/typechildren-document.http", "cmis:document" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); string id = "cmis:document"; libcmis::ObjectTypePtr actual = session.getType( id ); vector< libcmis::ObjectTypePtr > children = actual->getChildren(); // Check the actual children returned CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of children", size_t( 1 ), children.size( ) ); // Check the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/RepositoryService", "" "mock" "" + id + "" "true" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::getObjectTest( ) { // Setup the mockup curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-folder.http" ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/valid-object.http" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); // Run the tested method string expectedId( "valid-object" ); libcmis::ObjectPtr actual = session.getObject( expectedId ); // Check the returned object CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong Id for fetched object", expectedId, actual->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong type for fetched object", string( "cmis:folder" ), actual->getType() ); // Check the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/ObjectService" ); string expectedRequest = "" "mock" "" + expectedId + "" "true" "*" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::getDocumentTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-docLevel2.http" ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/test-document.http" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); string expectedId( "test-document" ); libcmis::ObjectPtr actual = session.getObject( expectedId ); // Do we have a document? libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( actual ); CPPUNIT_ASSERT_MESSAGE( "Fetched object should be an instance of libcmis::DocumentPtr", NULL != document ); // Check the document properties CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong document ID", expectedId, document->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong document name", string( "Test Document" ), document->getName( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong document type", string( "text/plain" ), document->getContentType( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong base type", string( "cmis:document" ), document->getBaseType( ) ); CPPUNIT_ASSERT_MESSAGE( "CreatedBy is missing", !document->getCreatedBy( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "CreationDate is missing", !document->getCreationDate( ).is_not_a_date_time() ); CPPUNIT_ASSERT_MESSAGE( "LastModifiedBy is missing", !document->getLastModifiedBy( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "LastModificationDate is missing", !document->getLastModificationDate( ).is_not_a_date_time() ); CPPUNIT_ASSERT_MESSAGE( "ChangeToken is missing", !document->getChangeToken( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "Content length is missing", 12345 == document->getContentLength( ) ); // Check the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/ObjectService" ); string expectedRequest = "" "mock" "" + expectedId + "" "true" "*" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::getFolderTest( ) { // Setup the mockup curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-folder.http" ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/valid-object.http" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); // Run the method under test string expectedId( "valid-object" ); libcmis::FolderPtr actual = session.getFolder( expectedId ); // Check the returned folder CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong folder ID", expectedId, actual->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong folder name", string( "Valid Object" ), actual->getName( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong folder path", string( "/Valid Object" ), actual->getPath( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong base type", string( "cmis:folder" ), actual->getBaseType( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Missing folder parent ID", string( "root-folder" ), actual->getParentId() ); CPPUNIT_ASSERT_MESSAGE( "Not a root folder", !actual->isRootFolder() ); CPPUNIT_ASSERT_MESSAGE( "CreatedBy is missing", !actual->getCreatedBy( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "CreationDate is missing", !actual->getCreationDate( ).is_not_a_date_time() ); CPPUNIT_ASSERT_MESSAGE( "LastModifiedBy is missing", !actual->getLastModifiedBy( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "LastModificationDate is missing", !actual->getLastModificationDate( ).is_not_a_date_time() ); CPPUNIT_ASSERT_MESSAGE( "ChangeToken is missing", !actual->getChangeToken( ).empty( ) ); // No need to check the request: we do the same one in another test } void WSTest::getByPathValidTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-folder.http" ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/valid-object.http" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); string path = "/Valid Object"; libcmis::ObjectPtr actual = session.getObjectByPath( path ); // Check the returned object CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong Id for fetched object", string( "valid-object" ), actual->getId( ) ); // Check the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/ObjectService" ); string expectedRequest = "" "mock" "" + path + "" "true" "*" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::getByPathInvalidTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/getbypath-bad.http" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); string path = "/some/invalid/path"; try { session.getObjectByPath( path ); CPPUNIT_FAIL( "Exception should be thrown: invalid Path" ); } catch ( const libcmis::Exception& e ) { // Check the caught exception CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong error type", string( "objectNotFound" ), e.getType() ); // Check the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/ObjectService" ); string expectedRequest = "" "mock" "" + path + "" "true" "*" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } } void WSTest::getDocumentParentsTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-folder.http" ); test::addWsResponse( "http://mockup/ws/services/NavigationService", DATA_DIR "/ws/test-document-parents.http" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); string id = "test-document"; vector< libcmis::FolderPtr > actual = session.getNavigationService(). getObjectParents( session.m_repositoryId, id ); // Check the actual parents CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad number of parents", size_t( 2 ), actual.size() ); // Check the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/NavigationService" ); string expectedRequest = "" "mock" "" + id + "" "true" "*" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::getChildrenTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-folder.http", "cmis:folder" ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-docLevel2.http", "DocumentLevel2" ); test::addWsResponse( "http://mockup/ws/services/NavigationService", DATA_DIR "/ws/root-children.http" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); string id = "root-folder"; vector< libcmis::ObjectPtr > children = session.getNavigationService(). getChildren( session.m_repositoryId, id ); // Check the returned children CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of children", size_t( 5 ), children.size() ); int folderCount = 0; int documentCount = 0; for ( vector< libcmis::ObjectPtr >::iterator it = children.begin( ); it != children.end( ); ++it ) { if ( NULL != boost::dynamic_pointer_cast< libcmis::Folder >( *it ) ) ++folderCount; else if ( NULL != boost::dynamic_pointer_cast< libcmis::Document >( *it ) ) ++documentCount; } CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of folder children", 2, folderCount ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of document children", 3, documentCount ); // Check the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/NavigationService" ); string expectedRequest = "" "mock" "" + id + "" "true" "*" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::getContentStreamTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/test-document.http", "( object ); boost::shared_ptr< istream > is = document->getContentStream( ); // Check the fetched content string actualContent = lcl_getStreamAsString( is ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Content stream doesn't match", string( "Some content stream" ), actualContent ); // Check the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/ObjectService", "" "mock" "" + id + "" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::setContentStreamTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/test-document.http", "( object ); try { string oldChangeToken = object->getChangeToken( ); string expectedContent( "Some content stream to set" ); boost::shared_ptr< ostream > os ( new stringstream ( expectedContent ) ); string filename( "name.txt" ); string contentType( "text/plain" ); document->setContentStream( os, contentType, filename, true ); CPPUNIT_ASSERT_MESSAGE( "Object not refreshed during setContentStream", object->getRefreshTimestamp( ) > 0 ); // We do not check the change token as we are lazy // That would require to write another answer file for the refresh // Check the sent request ostringstream converter; converter << expectedContent.size( ); string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/ObjectService", "" "mock" "" + id + "" "true" "" + oldChangeToken + "" "" "" + converter.str() + "" "" + contentType + "" "" + filename + "" "" "" "" "" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } catch ( const libcmis::Exception& e ) { string msg = "Unexpected exception: "; msg += e.what(); CPPUNIT_FAIL( msg.c_str() ); } } void WSTest::getRenditionsTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/test-document.http", " renditions = actual->getRenditions( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad renditions count", size_t( 2 ), renditions.size( ) ); libcmis::RenditionPtr rendition = renditions[1]; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad rendition mime type", string( "application/pdf" ), rendition->getMimeType( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad rendition stream id", string( "test-document-rendition2" ), rendition->getStreamId() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad rendition length - default case", long( -1 ), rendition->getLength( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad rendition Title", string( "Doc as PDF" ), rendition->getTitle( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad rendition kind", string( "pdf" ), rendition->getKind( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad rendition length - filled case", long( 40385 ), renditions[0]->getLength( ) ); } void WSTest::updatePropertiesTest( ) { curl_mockup_reset( ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-docLevel2.http" ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/test-document.http", "getTypeDescription( ); map< string, libcmis::PropertyTypePtr >::iterator it = objectType->getPropertiesTypes( ).find( propertyName ); vector< string > values; values.push_back( expectedValue ); libcmis::PropertyPtr property( new libcmis::Property( it->second, values ) ); newProperties[ propertyName ] = property; // Change the object response to provide the updated values test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/test-document-updated.http", "updateProperties( newProperties ); // Check the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/ObjectService", "" "mock" "" + id + "" "some-change-token" "" "" "New name" "" "" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); // Check that the properties are updated after the call PropertyPtrMap::iterator propIt = updated->getProperties( ).find( propertyName ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong value after refresh", expectedValue, propIt->second->getStrings().front( ) ); } void WSTest::updatePropertiesEmptyTest( ) { curl_mockup_reset( ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-docLevel2.http" ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/test-document.http", "updateProperties( emptyProperties ); // Check that no HTTP request was sent int count = curl_mockup_getRequestsCount( "http://mockup/ws/services/ObjectService", "", "POST", "getChangeToken(), updated->getChangeToken() ); } void WSTest::createFolderTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-folder.http" ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/root-folder.http", " propTypes = type->getPropertiesTypes( ); // Set the object name string expectedName( "create folder" ); map< string, libcmis::PropertyTypePtr >::iterator it = propTypes.find( string( "cmis:name" ) ); vector< string > nameValues; nameValues.push_back( expectedName ); libcmis::PropertyPtr nameProperty( new libcmis::Property( it->second, nameValues ) ); props.insert( pair< string, libcmis::PropertyPtr >( string( "cmis:name" ), nameProperty ) ); // set the object type it = propTypes.find( string( "cmis:objectTypeId" ) ); vector< string > typeValues; typeValues.push_back( "cmis:folder" ); libcmis::PropertyPtr typeProperty( new libcmis::Property( it->second, typeValues ) ); props.insert( pair< string, libcmis::PropertyPtr >( string( "cmis:objectTypeId" ), typeProperty ) ); // Set the mockup to send the updated folder now that we had the parent test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/created-folder.http", "createFolder( props ); // Check that something came back CPPUNIT_ASSERT_MESSAGE( "Change token shouldn't be empty: object should have been refreshed", !created->getChangeToken( ).empty() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong name", expectedName, created->getName( ) ); // Check that the proper request has been sent string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/ObjectService", "" "mock" "" "" "create folder" "" "" "cmis:folder" "" "" "root-folder" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::createFolderBadTypeTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-folder.http" ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/root-folder.http", " propTypes = type->getPropertiesTypes( ); // Set the object name string expectedName( "create folder" ); map< string, libcmis::PropertyTypePtr >::iterator it = propTypes.find( string( "cmis:name" ) ); vector< string > nameValues; nameValues.push_back( expectedName ); libcmis::PropertyPtr nameProperty( new libcmis::Property( it->second, nameValues ) ); props.insert( pair< string, libcmis::PropertyPtr >( string( "cmis:name" ), nameProperty ) ); // set the object type it = propTypes.find( string( "cmis:objectTypeId" ) ); vector< string > typeValues; typeValues.push_back( "cmis:document" ); libcmis::PropertyPtr typeProperty( new libcmis::Property( it->second, typeValues ) ); props.insert( pair< string, libcmis::PropertyPtr >( string( "cmis:objectTypeId" ), typeProperty ) ); // Actually send the folder creation request try { libcmis::FolderPtr created = parent->createFolder( props ); CPPUNIT_FAIL( "Should not succeed to return a folder" ); } catch ( libcmis::Exception& e ) { // Check the caught exception CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong error type", string( "constraint" ), e.getType() ); // Check that the proper request has been sent string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/ObjectService", "" "mock" "" "" "create folder" "" "" "cmis:document" "" "" "root-folder" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } } void WSTest::createDocumentTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/create-document.http", " propTypes = type->getPropertiesTypes( ); // Set the object name string expectedName( "create document" ); map< string, libcmis::PropertyTypePtr >::iterator it = propTypes.find( string( "cmis:name" ) ); vector< string > nameValues; nameValues.push_back( expectedName ); libcmis::PropertyPtr nameProperty( new libcmis::Property( it->second, nameValues ) ); props.insert( pair< string, libcmis::PropertyPtr >( string( "cmis:name" ), nameProperty ) ); // set the object type it = propTypes.find( string( "cmis:objectTypeId" ) ); vector< string > typeValues; typeValues.push_back( "cmis:document" ); libcmis::PropertyPtr typeProperty( new libcmis::Property( it->second, typeValues ) ); props.insert( pair< string, libcmis::PropertyPtr >( string( "cmis:objectTypeId" ), typeProperty ) ); // Make the mockup able to send the response to update the object test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/created-document.http", " os ( new stringstream( content ) ); string contentType = "text/plain"; string filename( "name.txt" ); libcmis::DocumentPtr created = parent->createDocument( props, os, contentType, filename ); // Check that something came back CPPUNIT_ASSERT_MESSAGE( "Change token shouldn't be empty: object should have been refreshed", !created->getChangeToken( ).empty() ); // Check that the name is ok CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong name set", expectedName, created->getName( ) ); // Check that the sent request is the expected one ostringstream converter; converter << content.size( ); string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/ObjectService", "" "mock" "" "" "create document" "" "" "cmis:document" "" "" "root-folder" "" "" + converter.str( ) + "" "" + contentType + "" "" + filename + "" "" "" "" "" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::deleteDocumentTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/test-document.http", "( object.get() ); // Run the tested method. Here we delete the object with all its versions document->remove( true ); // Check that the proper request has been sent string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/ObjectService", "" "mock" "" + id + "" "true" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::deleteFolderTreeTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/valid-object.http", "( object.get() ); vector failed = folder->removeTree( true, libcmis::UnfileObjects::Delete, false ); // Check that we had the failed ids CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong ids for non-deleted objects", string( "bad-delete" ), failed[0] ); // Test the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/ObjectService", "" "mock" "valid-object" "true" "delete" "false" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::moveTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-folder.http", "cmis:folder" ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-docLevel2.http", "DocumentLevel2" ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/test-document.http", "( object.get() ); string destFolderId = "valid-object"; libcmis::FolderPtr src = document->getParents( ).front( ); // Tell the mockup about the destination folder test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/valid-object.http", "move( src, dest ); // Check the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/ObjectService", "" "mock" "" + id + "" "" + destFolderId + "" "" + src->getId( ) + "" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::addSecondaryTypeTest( ) { curl_mockup_reset( ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/secondary-type.http", "secondary-type" ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-docLevel2-secondary.http", "DocumentLevel2" ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/test-document.http", "::iterator it = objectType->getPropertiesTypes( ).find( propertyName ); vector< string > values; values.push_back( expectedValue ); libcmis::PropertyPtr property( new libcmis::Property( it->second, values ) ); newProperties[ propertyName ] = property; // Change the object response to provide the updated values test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/test-document-add-secondary.http", "addSecondaryType( secondaryType, newProperties ); // Check the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/ObjectService", "" "mock" "" + id + "" "some-change-token" "" "" "" + secondaryType + "" "" "" "" + expectedValue + "" "" "" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); // Check that the properties are updated after the call PropertyPtrMap::iterator propIt = updated->getProperties( ).find( propertyName ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong value after refresh", expectedValue, propIt->second->getStrings().front( ) ); } void WSTest::checkOutTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/test-document.http", "test-document" ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/working-copy.http", "working-copy" ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-docLevel2.http" ); test::addWsResponse( "http://mockup/ws/services/VersioningService", DATA_DIR "/ws/checkout.http" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); string id = "test-document"; libcmis::ObjectPtr object = session.getObject( id ); libcmis::Document* document = dynamic_cast< libcmis::Document* >( object.get() ); libcmis::DocumentPtr pwc = document->checkOut( ); // Check that we have a PWC CPPUNIT_ASSERT_MESSAGE( "Missing returned Private Working Copy", pwc.get( ) != NULL ); PropertyPtrMap::iterator it = pwc->getProperties( ).find( string( "cmis:isVersionSeriesCheckedOut" ) ); vector< bool > values = it->second->getBools( ); CPPUNIT_ASSERT_MESSAGE( "cmis:isVersionSeriesCheckedOut isn't true", values.front( ) ); // Check the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/VersioningService" ); string expectedRequest = "" "mock" "" + id + "" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::cancelCheckOutTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/working-copy.http" ); test::addWsResponse( "http://mockup/ws/services/VersioningService", DATA_DIR "/ws/cancel-checkout.http" ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-docLevel2.http" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); // First get a checked out document string id = "working-copy"; libcmis::ObjectPtr object = session.getObject( id ); libcmis::DocumentPtr pwc = boost::dynamic_pointer_cast< libcmis::Document >( object ); pwc->cancelCheckout( ); // Check the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/VersioningService" ); string expectedRequest = "" "mock" "" + id + "" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::checkInTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-docLevel2.http" ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/working-copy.http", "working-copy" ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/checked-in.http", "test-document" ); test::addWsResponse( "http://mockup/ws/services/VersioningService", DATA_DIR "/ws/checkin.http" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); // First get a checked out document string id = "working-copy"; libcmis::ObjectPtr object = session.getObject( id ); libcmis::DocumentPtr pwc = boost::dynamic_pointer_cast< libcmis::Document >( object ); // Do the checkin bool isMajor = true; string comment( "Some check-in comment" ); PropertyPtrMap properties; string newContent = "Some New content to check in"; boost::shared_ptr< ostream > stream ( new stringstream( newContent ) ); string contentType = "text/plain"; string filename = "filename.txt"; libcmis::DocumentPtr updated = pwc->checkIn( isMajor, comment, properties, stream, contentType, filename ); // Check that we had the new version CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong filename: probably not the new version", filename, updated->getContentFilename() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong commit comment: not the new version", comment, updated->getStringProperty( "cmis:checkinComment" ) ); // Check the sent request ostringstream converter; converter << newContent.size( ); string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/VersioningService" ); string expectedRequest = "" "mock" "" + id + "" "true" "" "" "" + converter.str() + "" "" + contentType + "" "" + filename + "" "" "" "" "" "" + comment + "" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::getAllVersionsTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); test::addWsResponse( "http://mockup/ws/services/RepositoryService", DATA_DIR "/ws/type-docLevel2.http" ); test::addWsResponse( "http://mockup/ws/services/ObjectService", DATA_DIR "/ws/test-document.http" ); test::addWsResponse( "http://mockup/ws/services/VersioningService", DATA_DIR "/ws/get-versions.http" ); WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); // First get a document string id = "test-document"; libcmis::ObjectPtr object = session.getObject( id ); string seriesId = object->getStringProperty( "cmis:versionSeriesId" ); libcmis::DocumentPtr doc = boost::dynamic_pointer_cast< libcmis::Document >( object ); // Get all the versions (method to check) vector< libcmis::DocumentPtr > versions = doc->getAllVersions( ); // Checks CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of versions", size_t( 2 ), versions.size( ) ); // Check the sent request string xmlRequest = lcl_getCmisRequestXml( "http://mockup/ws/services/VersioningService" ); string expectedRequest = "" "mock" "" + seriesId + "" "true" ""; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request sent", expectedRequest, xmlRequest ); } void WSTest::navigationServiceCopyTest() { WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); NavigationService service( &session ); { NavigationService copy( service ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Session not copied", service.m_session, copy.m_session ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "URL not copied", service.m_url, copy.m_url ); } { NavigationService copy; copy = service; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Session not copied", service.m_session, copy.m_session ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "URL not copied", service.m_url, copy.m_url ); } } void WSTest::repositoryServiceCopyTest() { WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); RepositoryService service( &session ); { RepositoryService copy( service ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Session not copied", service.m_session, copy.m_session ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "URL not copied", service.m_url, copy.m_url ); } { RepositoryService copy; copy = service; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Session not copied", service.m_session, copy.m_session ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "URL not copied", service.m_url, copy.m_url ); } } void WSTest::objectServiceCopyTest() { WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); ObjectService service( &session ); { ObjectService copy( service ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Session not copied", service.m_session, copy.m_session ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "URL not copied", service.m_url, copy.m_url ); } { ObjectService copy; copy = service; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Session not copied", service.m_session, copy.m_session ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "URL not copied", service.m_url, copy.m_url ); } } void WSTest::versioningServiceCopyTest() { WSSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD, true ); VersioningService service( &session ); { VersioningService copy( service ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Session not copied", service.m_session, copy.m_session ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "URL not copied", service.m_url, copy.m_url ); } { VersioningService copy; copy = service; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Session not copied", service.m_session, copy.m_session ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "URL not copied", service.m_url, copy.m_url ); } } WSSession WSTest::getTestSession( string username, string password, bool noRepos ) { WSSession session; session.m_username = username; session.m_password = password; string buf; test::loadFromFile( DATA_DIR "/ws/CMISWS-Service.wsdl", buf ); session.parseWsdl( buf ); session.initializeResponseFactory( ); // Manually define the repositories to avoid the HTTP query if ( noRepos ) { libcmis::RepositoryPtr repo = getTestRepository( ); session.m_repositories.push_back( repo ); session.m_repositoryId = repo->getId( ); } return session; } libcmis::RepositoryPtr WSTest::getTestRepository() { libcmis::RepositoryPtr repo( new libcmis::Repository( ) ); repo->m_id = "mock"; repo->m_name = "Mockup"; repo->m_description = "Repository sent by mockup server"; repo->m_vendorName = "libcmis"; repo->m_productName = "Libcmis mockup"; repo->m_productVersion = "some-version"; repo->m_cmisVersionSupported = "1.1"; repo->m_rootId = "root-folder"; map< libcmis::Repository::Capability, string > capabilities; capabilities[libcmis::Repository::ACL] = "manage"; capabilities[libcmis::Repository::AllVersionsSearchable] = "false"; capabilities[libcmis::Repository::Changes] = "none"; capabilities[libcmis::Repository::ContentStreamUpdatability] = "anytime"; capabilities[libcmis::Repository::GetDescendants] = "true"; capabilities[libcmis::Repository::GetFolderTree] = "true"; capabilities[libcmis::Repository::Multifiling] = "true"; capabilities[libcmis::Repository::PWCSearchable] = "false"; capabilities[libcmis::Repository::PWCUpdatable] = "true"; capabilities[libcmis::Repository::Query] = "bothcombined"; capabilities[libcmis::Repository::Renditions] = "read"; capabilities[libcmis::Repository::Unfiling] = "true"; capabilities[libcmis::Repository::VersionSpecificFiling] = "false"; capabilities[libcmis::Repository::Join] = "none"; repo->m_capabilities = capabilities; return repo; } libcmis-0.5.2/qa/libcmis/test-soap.cxx0000664000175000017500000005151113407414352014557 00000000000000/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include #include #include #include #if defined __clang__ #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wkeyword-macro" #endif #define private public #if defined __clang__ #pragma clang diagnostic pop #endif #include "ws-relatedmultipart.hxx" #include "ws-requests.hxx" #include "ws-soap.hxx" #include "test-helpers.hxx" using namespace std; class SoapTest : public CppUnit::TestFixture { private: map< string, SoapResponseCreator > getTestMapping( ); map< string, string > getTestNamespaces( ); map< string, SoapFaultDetailCreator > getTestDetailMapping( ); public: // Copy tests void soapResponseFactoryCopyTest(); // Soap Responses tests void createResponseTest( ); void parseFaultDetailEmptyTest( ); void parseFaultDetailUnknownTest( ); void parseFaultDetailValidTest( ); void createFaultDefaultTest( ); void parseResponseTest( ); void parseResponseXmlTest( ); void parseResponseFaultTest( ); // RelatedMultipart tests void serializeMultipartSimpleTest( ); void serializeMultipartComplexTest( ); void parseMultipartTest( ); void getStreamFromNodeXopTest( ); void getStreamFromNodeBase64Test( ); // CMISM utilities tests void writeCmismStreamTest( ); CPPUNIT_TEST_SUITE( SoapTest ); CPPUNIT_TEST( soapResponseFactoryCopyTest ); CPPUNIT_TEST( createResponseTest ); CPPUNIT_TEST( parseFaultDetailEmptyTest ); CPPUNIT_TEST( parseFaultDetailUnknownTest ); CPPUNIT_TEST( parseFaultDetailValidTest ); CPPUNIT_TEST( parseResponseTest ); CPPUNIT_TEST( parseResponseXmlTest ); CPPUNIT_TEST( parseResponseFaultTest ); CPPUNIT_TEST( serializeMultipartSimpleTest ); CPPUNIT_TEST( serializeMultipartComplexTest ); CPPUNIT_TEST( parseMultipartTest ); CPPUNIT_TEST( getStreamFromNodeXopTest ); CPPUNIT_TEST( getStreamFromNodeBase64Test ); CPPUNIT_TEST( writeCmismStreamTest ); CPPUNIT_TEST_SUITE_END( ); }; CPPUNIT_TEST_SUITE_REGISTRATION( SoapTest ); /** Dummy response class to use for testing */ class TestResponse : public SoapResponse { private: TestResponse( ) { }; public: static SoapResponsePtr create( xmlNodePtr, RelatedMultipart&, SoapSession* ) { SoapResponsePtr resp ( new TestResponse( ) ); return resp; } }; class TestFaultDetail : public SoapFaultDetail { private: TestFaultDetail( ) : SoapFaultDetail( ) { }; public: ~TestFaultDetail( ) noexcept { }; static SoapFaultDetailPtr create( xmlNodePtr ) { return SoapFaultDetailPtr( new TestFaultDetail( ) ); } }; map< string, SoapResponseCreator > SoapTest::getTestMapping( ) { map< string, SoapResponseCreator > mapping; mapping[ "{test-ns-url}testResponse" ] = &TestResponse::create; return mapping; } map< string, SoapFaultDetailCreator > SoapTest::getTestDetailMapping( ) { map< string, SoapFaultDetailCreator > mapping; mapping[ "{test-ns-url}testFault" ] = &TestFaultDetail::create; return mapping; } map< string, string > SoapTest::getTestNamespaces( ) { map< string, string > namespaces; namespaces[ "test" ] = "test-ns-url"; return namespaces; } void SoapTest::soapResponseFactoryCopyTest( ) { SoapResponseFactory factory; factory.setMapping( getTestMapping() ); factory.setNamespaces( getTestNamespaces( ) ); factory.setDetailMapping( getTestDetailMapping( ) ); { SoapResponseFactory copy; copy = factory; CPPUNIT_ASSERT_EQUAL( factory.m_mapping.size(), copy.m_mapping.size() ); CPPUNIT_ASSERT_EQUAL( factory.m_namespaces.size(), copy.m_namespaces.size() ); CPPUNIT_ASSERT_EQUAL( factory.m_detailMapping.size(), copy.m_detailMapping.size() ); CPPUNIT_ASSERT_EQUAL( factory.m_session, copy.m_session ); } { SoapResponseFactory copy( factory ); CPPUNIT_ASSERT_EQUAL( factory.m_mapping.size(), copy.m_mapping.size() ); CPPUNIT_ASSERT_EQUAL( factory.m_namespaces.size(), copy.m_namespaces.size() ); CPPUNIT_ASSERT_EQUAL( factory.m_detailMapping.size(), copy.m_detailMapping.size() ); CPPUNIT_ASSERT_EQUAL( factory.m_session, copy.m_session ); } } void SoapTest::createResponseTest( ) { SoapResponseFactory factory; factory.setMapping( getTestMapping() ); factory.setNamespaces( getTestNamespaces( ) ); factory.setDetailMapping( getTestDetailMapping( ) ); string xml = ""; RelatedMultipart multipart; // Multipart won't be used in that test SoapResponsePtr actual = factory.createResponse( test::getXmlNode( xml ), multipart ); CPPUNIT_ASSERT_MESSAGE( "Wrong response created", dynamic_cast< TestResponse* >( actual.get( ) ) != NULL ); } void SoapTest::parseFaultDetailEmptyTest( ) { SoapResponseFactory factory; factory.setMapping( getTestMapping() ); factory.setNamespaces( getTestNamespaces( ) ); factory.setDetailMapping( getTestDetailMapping( ) ); string xml = ""; vector< SoapFaultDetailPtr > actual = factory.parseFaultDetail( test::getXmlNode( xml ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Shouldn't have any detail", size_t( 0 ), actual.size() ); } void SoapTest::parseFaultDetailUnknownTest( ) { SoapResponseFactory factory; factory.setMapping( getTestMapping() ); factory.setNamespaces( getTestNamespaces( ) ); factory.setDetailMapping( getTestDetailMapping( ) ); string xml = ""; vector< SoapFaultDetailPtr > actual = factory.parseFaultDetail( test::getXmlNode( xml ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Shouldn't have ignored unknonw details", size_t( 0 ), actual.size() ); } void SoapTest::parseFaultDetailValidTest( ) { SoapResponseFactory factory; factory.setMapping( getTestMapping() ); factory.setNamespaces( getTestNamespaces( ) ); factory.setDetailMapping( getTestDetailMapping( ) ); string xml = ""; vector< SoapFaultDetailPtr > actual = factory.parseFaultDetail( test::getXmlNode( xml ) ); CPPUNIT_ASSERT_MESSAGE( "Wrong fault detail created", dynamic_cast< TestFaultDetail* >( actual.front( ).get( ) ) != NULL ); } void SoapTest::parseResponseTest( ) { SoapResponseFactory factory; factory.setMapping( getTestMapping() ); factory.setNamespaces( getTestNamespaces( ) ); factory.setDetailMapping( getTestDetailMapping( ) ); string xml = "" "" "" ""; string name( "name" ); string type( "application/xop+xml" ); RelatedPartPtr requestPart( new RelatedPart( name, type, xml ) ); RelatedMultipart multipart; string cid = multipart.addPart( requestPart ); string startInfo( "text/xml" ); multipart.setStart( cid, startInfo ); vector< SoapResponsePtr > actual = factory.parseResponse( multipart ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of responses", size_t( 2 ), actual.size( ) ); } void SoapTest::parseResponseXmlTest( ) { SoapResponseFactory factory; factory.setMapping( getTestMapping() ); factory.setNamespaces( getTestNamespaces( ) ); factory.setDetailMapping( getTestDetailMapping( ) ); string xml = "" "" "" ""; vector< SoapResponsePtr > actual = factory.parseResponse( xml ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of responses", size_t( 2 ), actual.size( ) ); } void SoapTest::parseResponseFaultTest( ) { SoapResponseFactory factory; factory.setMapping( getTestMapping() ); factory.setNamespaces( getTestNamespaces( ) ); factory.setDetailMapping( getTestDetailMapping( ) ); string xml = "" " " " S:Client" " Some Error Message" " " " " ""; string name( "name" ); string type( "application/xop+xml" ); RelatedPartPtr requestPart( new RelatedPart( name, type, xml ) ); RelatedMultipart multipart; string cid = multipart.addPart( requestPart ); string startInfo( "text/xml" ); multipart.setStart( cid, startInfo ); try { factory.parseResponse( multipart ); CPPUNIT_FAIL( "Should have thrown the SoapFault" ); } catch ( const SoapFault& e ) { CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong detail string", string( "Some Error Message" ), e.getFaultstring() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong detail string", string( "Client" ), e.getFaultcode() ); CPPUNIT_ASSERT_MESSAGE( "Wrong fault detail created", dynamic_cast< TestFaultDetail* >( e.getDetail( ).front( ).get( ) ) != NULL ); } } void SoapTest::serializeMultipartSimpleTest( ) { string partName = "data"; string partType = "text/plain"; string partContent = "Some content"; string startInfo = "some info"; RelatedMultipart multipart; RelatedPartPtr part( new RelatedPart( partName, partType, partContent ) ); string cid = multipart.addPart( part ); multipart.setStart( cid, startInfo ); boost::shared_ptr< istringstream > actual = multipart.toStream( ); string boundary = multipart.getBoundary( ); string expected = "\r\n--" + boundary + "\r\n" + "Content-Id: <" + cid + ">\r\n" + "Content-Type: " + partType + "\r\n" + "Content-Transfer-Encoding: binary\r\n" + "\r\n" + partContent + "\r\n--" + boundary + "--\r\n"; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong body", expected, actual->str() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong content type", "multipart/related;start=\"" + cid + "\";type=\"" + partType + "\";boundary=\"" + boundary + "\";start-info=\"" + startInfo + "\"", multipart.getContentType() ); } void SoapTest::serializeMultipartComplexTest( ) { string rootName = "root"; string rootType = "text/plain"; string rootContent = "Some content"; string part2Name = "part2"; string part2Type = "application/octet-stream"; string part2Content = "Some content 2"; string startInfo = "some info"; RelatedMultipart multipart; RelatedPartPtr rootPart( new RelatedPart( rootName, rootType, rootContent ) ); string rootCid = multipart.addPart( rootPart ); RelatedPartPtr part2( new RelatedPart( part2Name, part2Type, part2Content ) ); string part2Cid = multipart.addPart( part2 ); multipart.setStart( rootCid, startInfo ); boost::shared_ptr< istringstream > actual = multipart.toStream( ); string boundary = multipart.getBoundary( ); string expected = "\r\n--" + boundary + "\r\n" + "Content-Id: <" + rootCid + ">\r\n" + "Content-Type: " + rootType + "\r\n" + "Content-Transfer-Encoding: binary\r\n" + "\r\n" + rootContent + "\r\n--" + boundary + "\r\n" + "Content-Id: <" + part2Cid + ">\r\n" + "Content-Type: " + part2Type + "\r\n" + "Content-Transfer-Encoding: binary\r\n" + "\r\n" + part2Content + "\r\n--" + boundary + "--\r\n"; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong body", expected, actual->str() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong content type", "multipart/related;start=\"" + rootCid + "\";type=\"" + rootType + "\";boundary=\"" + boundary + "\";start-info=\"" + startInfo + "\"", multipart.getContentType() ); } void SoapTest::parseMultipartTest( ) { string rootCid = "root-cid"; string rootType = "text/plain"; string rootContent = "Some content"; string part2Cid = "part2-cid"; string part2Type = "application/octet-stream"; string part2Content = "Some content 2\r\nwith windows-style line endings\r\n"; string startInfo = "some info"; string boundary = "------------ABCDEF-Boundary"; string body = "\r\n--" + boundary + "\r\n" + "Content-Id: <" + rootCid + ">\r\n" + "Content-Type: " + rootType + "\r\n" + "Content-Transfer-Encoding: binary\r\n" + "\r\n" + rootContent + "\r\n--" + boundary + "\r\n" + // Voluntarily make a case-sensitivity error to test the SharePoint case "Content-ID: <" + part2Cid + ">\r\n" + "Content-Type: " + part2Type + "\r\n" + "Content-Transfer-Encoding: binary\r\n" + "\r\n" + part2Content + "\r\n--" + boundary + "--\r\n"; // Added a space before one of the items as it may happen string contentType = "multipart/related; start=\"" + rootCid + "\";type=\"" + rootType + "\";" + "boundary=\"" + boundary + "\";start-info=\"" + startInfo + "\""; RelatedMultipart multipart( body, contentType ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong start Content id", rootCid, multipart.getStartId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong start info", startInfo, multipart.getStartInfo( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong boundary", boundary, multipart.getBoundary( ) ); vector< string > cids = multipart.getIds( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of parts parsed", size_t( 2 ), cids.size( ) ); RelatedPartPtr actualRoot = multipart.getPart( rootCid ); CPPUNIT_ASSERT_MESSAGE( "No part corresponding to root cid", actualRoot.get( ) != NULL ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong root part content type", rootType, actualRoot->getContentType( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong root part content", rootContent, actualRoot->getContent( ) ); RelatedPartPtr actualPart2 = multipart.getPart( part2Cid ); CPPUNIT_ASSERT_MESSAGE( "No part corresponding to part2 cid", actualPart2.get( ) != NULL ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong part2 part content type", part2Type, actualPart2->getContentType( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong part2 part content", part2Content, actualPart2->getContent( ) ); } void SoapTest::getStreamFromNodeXopTest( ) { // Create the test multipart string dataCid = "http://data-cid"; string dataCidEncoded = "http%3A%2F%2Fdata-cid"; string dataContent = "Some transfered content"; string boundary = "------------ABCDEF-Boundary"; string body = "\r\n--" + boundary + "\r\n" + "Content-Id: \r\n" + "Content-Type: text/plain\r\n" + "Content-Transfer-Encoding: binary\r\n" + "\r\n" + "Who cares? we assume, this has been properly extracted in this test" + "\r\n--" + boundary + "\r\n" + "Content-Id: " + dataCid + "\r\n" + "Content-Type: text/plain\r\n" + "Content-Transfer-Encoding: binary\r\n" + "\r\n" + dataContent + "\r\n--" + boundary + "--\r\n"; string contentType = string( "multipart/related;start=\"root-cid\";type=\"text/plain\";" ) + "boundary=\"" + boundary + "\";start-info=\"info\""; RelatedMultipart multipart( body, contentType ); // Create test node stringstream buf; buf << "" << " " << ""; test::XmlNodeRef node = test::getXmlNode( buf.str( ) ); // Run the tested method boost::shared_ptr< istream > stream = getStreamFromNode( node, multipart ); // Checks stringstream out; out << stream->rdbuf( ); CPPUNIT_ASSERT_EQUAL( dataContent, out.str( ) ); } void SoapTest::getStreamFromNodeBase64Test( ) { // Create the test multipart string boundary = "------------ABCDEF-Boundary"; string body = "\r\n--" + boundary + "\r\n" + "Content-Id: \r\n" + "Content-Type: text/plain\r\n" + "Content-Transfer-Encoding: binary\r\n" + "\r\n" + "Who cares? we assume, this has been properly extracted in this test" + "\r\n--" + boundary + "--\r\n"; string contentType = string( "multipart/related;start=\"root-cid\";type=\"text/plain\";" ) + "boundary=\"" + boundary + "\";start-info=\"info\""; RelatedMultipart multipart( body, contentType ); // Create test node string dataContent = "U29tZSB0cmFuc2ZlcmVkIGNvbnRlbnQ="; string expectedContent = "Some transfered content"; stringstream buf; buf << "" << dataContent << ""; test::XmlNodeRef node = test::getXmlNode( buf.str( ) ); // Run the tested method boost::shared_ptr< istream > stream = getStreamFromNode( node, multipart ); // Checks stringstream out; out << stream->rdbuf( ); CPPUNIT_ASSERT_EQUAL( expectedContent, out.str( ) ); } void SoapTest::writeCmismStreamTest( ) { // Initialize the writer xmlBufferPtr buf = xmlBufferCreate( ); xmlTextWriterPtr writer = xmlNewTextWriterMemory( buf, 0 ); xmlTextWriterStartDocument( writer, NULL, NULL, NULL ); // Test writeCmismStream RelatedMultipart multipart; string contentType( "text/plain" ); string content( "Expected content" ); string filename( "name.txt" ); boost::shared_ptr< ostream > os( new stringstream( content ) ); writeCmismStream( writer, multipart, os, contentType, filename ); // Close the writer and check the results xmlTextWriterEndDocument( writer ); string str( ( const char * )xmlBufferContent( buf ) ); vector< string > ids = multipart.getIds( ); CPPUNIT_ASSERT_EQUAL( size_t( 1 ), ids.size( ) ); string partId = ids.front( ); RelatedPartPtr part = multipart.getPart( partId ); CPPUNIT_ASSERT_MESSAGE( "Missing stream related part", part.get( ) != NULL ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Content not properly attached", content, part->getContent( ) ); stringstream expectedXml; expectedXml << "\n" << "" << content.size( ) << "" << "" << contentType << "" << "" << filename << "" << "" << "" << "\n"; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Envelope part isn't correct", expectedXml.str( ), str ); // Free it all xmlFreeTextWriter( writer ); xmlBufferFree( buf ); } libcmis-0.5.2/qa/libcmis/data/0000775000175000017500000000000013407173247013107 500000000000000libcmis-0.5.2/qa/libcmis/data/sharepoint/0000775000175000017500000000000013407173247015263 500000000000000libcmis-0.5.2/qa/libcmis/data/sharepoint/author.json0000664000175000017500000000120313407173247017374 00000000000000{ "d":{ "Email":"", "Groups":{ "__deferred":{ "uri":"http://mock/_api/Web/GetUserById(1)/Groups" } }, "Id":1, "IsHiddenInUI":false, "IsSiteAdmin":true, "LoginName":"i:0#.w|sp-cmis\\aUserId", "PrincipalType":1, "Title":"aUserId", "UserId":{ "NameId":"s-1-5-21-1673017749-4204619129-3521412262-500", "NameIdIssuer":"urn:office:idp:activedirectory", "__metadata":{ "type":"SP.UserIdInfo" } }, "__metadata":{ "id":"http://mock/_api/Web/GetUserById(1)", "type":"SP.User", "uri":"http://mock/_api/Web/GetUserById(1)" } } } libcmis-0.5.2/qa/libcmis/data/sharepoint/folder-properties.json0000664000175000017500000000264313407173247021550 00000000000000{ "d": { "__metadata": { "id": "http://base/_api/web/aFolderId/properties", "type": "SP.PropertyValues", "uri": "http://base/_api/web/aFolderId/properties" }, "vti_x005f_candeleteversion": "true", "vti_x005f_dirlateststamp": "2014-07-28T16:10:28", "vti_x005f_docstoretype": 1, "vti_x005f_etag": "\"{61A348A0-D6D6-4B67-91E9-FFC87CCDE1BF},0\"", "vti_x005f_folderitemcount": 3, "vti_x005f_foldersubfolderitemcount": 0, "vti_x005f_hassubdirs": "true", "vti_x005f_isbrowsable": "true", "vti_x005f_isexecutable": "false", "vti_x005f_isscriptable": "false", "vti_x005f_level": 1, "vti_x005f_listbasetype": 1, "vti_x005f_listenableminorversions": "true", "vti_x005f_listenablemoderation": "false", "vti_x005f_listenableversioning": "true", "vti_x005f_listname": "{D0014F89-052C-4F0A-A65D-A61DFC837093}", "vti_x005f_listrequirecheckout": "false", "vti_x005f_listservertemplate": 101, "vti_x005f_listtitle": "Documents", "vti_x005f_metainfoversion": 1, "vti_x005f_nexttolasttimemodified": "2014-07-08T09:29:29", "vti_x005f_parentid": "{F3A8C5D9-525D-4BEB-A9DF-4CA122A5D074}", "vti_x005f_replid": "rid:{61A348A0-D6D6-4B67-91E9-FFC87CCDE1BF}", "vti_x005f_rtag": "rt:61A348A0-D6D6-4B67-91E9-FFC87CCDE1BF@00000000000", "vti_x005f_timecreated": "2014-07-02T14:19:02", "vti_x005f_timelastmodified": "2014-07-14T09:15:56" } } libcmis-0.5.2/qa/libcmis/data/sharepoint/xdigest.json0000664000175000017500000000111213407173247017540 00000000000000{ "d":{ "GetContextWebInformation":{ "FormDigestTimeoutSeconds":1800, "FormDigestValue":"0xEBC52E4F66DE48475242A8F8291E9C6CAE1C71525B2EFFC8100F87746F4A5780E5EFCA2ABF063C8B3B08B987EBF56BF7ADE4A94714934D2C3928E060FBA4009A,14 Jul 2014 08:31:38 -0000", "LibraryVersion":"15.0.4420.1017", "SiteFullUrl":"http://base/_api", "SupportedSchemaVersions":{ "results":[ "14.0.0.0", "15.0.0.0" ] }, "WebFullUrl":"http://base/_api", "__metadata":{ "type":"SP.ContextWebInformation" } } } } libcmis-0.5.2/qa/libcmis/data/sharepoint/file-v1.json0000664000175000017500000000256013407173247017344 00000000000000{ "d":{ "Author":{ "__deferred":{ "uri":"http://base/_api/Web/aFileId/Author" } }, "CheckInComment":"aCheckinComment", "CheckOutType":2, "CheckedOutByUser":{ "__deferred":{ "uri":"http://base/_api/Web/aFileId/CheckedOutByUser" } }, "ContentTag":"{AD7FC895-3E19-4553-AD77-9ADFC2A3B69A},1,2", "CustomizedPageStatus":0, "ETag":"\"{AD7FC895-3E19-4553-AD77-9ADFC2A3B69A},1\"", "Exists":true, "Length":"18045", "Level":1, "ListItemAllFields":{ "__deferred":{ "uri":"http://base/_api/Web/aFileId/ListItemAllFields" } }, "LockedByUser":{ "__deferred":{ "uri":"http://base/_api/Web/aFileId/LockedByUser" } }, "MajorVersion":2, "MinorVersion":0, "ModifiedBy":{ "__deferred":{ "uri":"http://base/_api/Web/aFileId/ModifiedBy" } }, "Name":"SharePointFile", "ServerRelativeUrl":"/Shared Documents/file.txt", "TimeCreated":"2014-07-08T09:29:29Z", "TimeLastModified":"2014-07-08T09:29:29Z", "Title":"", "UIVersion":512, "UIVersionLabel":"1.0", "Versions":{ "__deferred":{ "uri":"http://base/_api/Web/aFileId/Versions" } }, "__metadata":{ "id":"http://base/_api/Web/aFileId-v1", "type":"SP.File", "uri":"http://base/_api/Web/aFileId-v1" } } } libcmis-0.5.2/qa/libcmis/data/sharepoint/children-folders.json0000664000175000017500000000202013407173247021314 00000000000000{ "d": { "results":[ { "Files": { "__deferred": { "uri": "http://base/_api/Web/aFolderId/Files" } }, "Folders": { "__deferred": { "uri": "http://base/_api/Web/aFolderId/Folders" } }, "ItemCount": 3, "ListItemAllFields": { "__deferred": { "uri": "http://base/_api/Web/aFolderId/ListItemAllFields" } }, "Name": "SharePoint Folder", "ParentFolder": { "__deferred": { "uri": "http://base/_api/Web/aFolderId/ParentFolder" } }, "Properties": { "__deferred": { "uri": "http://base/_api/Web/aFolderId/Properties" } }, "ServerRelativeUrl": "/Shared Documents", "WelcomePage": "", "__metadata": { "id": "http://base/_api/Web/aFolderId", "type": "SP.Folder", "uri": "http://base/_api/Web/aFolderId" } } ] } } libcmis-0.5.2/qa/libcmis/data/sharepoint/auth-resp.json0000664000175000017500000001164413407173247020014 00000000000000{ "d":{ "AllProperties":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/AllProperties" } }, "AllowRssFeeds":true, "AppInstanceId":"00000000-0000-0000-0000-000000000000", "AssociatedMemberGroup":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/AssociatedMemberGroup" } }, "AssociatedOwnerGroup":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/AssociatedOwnerGroup" } }, "AssociatedVisitorGroup":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/AssociatedVisitorGroup" } }, "AvailableContentTypes":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/AvailableContentTypes" } }, "AvailableFields":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/AvailableFields" } }, "Configuration":0, "ContentTypes":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/ContentTypes" } }, "Created":"2014-07-02T13:55:23", "CurrentUser":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/CurrentUser" } }, "CustomMasterUrl":"/_catalogs/masterpage/seattle.master", "Description":"", "DocumentLibraryCalloutOfficeWebAppPreviewersDisabled":false, "EnableMinimalDownload":false, "EventReceivers":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/EventReceivers" } }, "Features":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/Features" } }, "Fields":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/Fields" } }, "FirstUniqueAncestorSecurableObject":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/FirstUniqueAncestorSecurableObject" } }, "Folders":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/Folders" } }, "Id":"98a58f26-7ed4-436c-917b-05fa37e06ab2", "Language":1033, "LastItemModifiedDate":"2014-07-03T10:51:32Z", "ListTemplates":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/ListTemplates" } }, "Lists":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/Lists" } }, "MasterUrl":"/_catalogs/masterpage/seattle.master", "Navigation":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/Navigation" } }, "ParentWeb":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/ParentWeb" } }, "PushNotificationSubscribers":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/PushNotificationSubscribers" } }, "QuickLaunchEnabled":true, "RecycleBin":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/RecycleBin" } }, "RecycleBinEnabled":true, "RegionalSettings":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/RegionalSettings" } }, "RoleAssignments":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/RoleAssignments" } }, "RoleDefinitions":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/RoleDefinitions" } }, "RootFolder":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/RootFolder" } }, "ServerRelativeUrl":"/", "SiteGroups":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/SiteGroups" } }, "SiteUserInfoList":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/SiteUserInfoList" } }, "SiteUsers":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/SiteUsers" } }, "SyndicationEnabled":true, "ThemeInfo":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/ThemeInfo" } }, "Title":"Home", "TreeViewEnabled":false, "UIVersion":15, "UIVersionConfigurationEnabled":false, "Url":"http://sp-cmis.cloudapp.net", "UserCustomActions":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/UserCustomActions" } }, "WebInfos":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/WebInfos" } }, "WebTemplate":"STS", "Webs":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/Webs" } }, "WorkflowAssociations":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/WorkflowAssociations" } }, "WorkflowTemplates":{ "__deferred":{ "uri":"http://sp-cmis.cloudapp.net/_api/Web/WorkflowTemplates" } }, "__metadata":{ "id":"http://sp-cmis.cloudapp.net/_api/Web", "type":"SP.Web", "uri":"http://sp-cmis.cloudapp.net/_api/Web" } } }libcmis-0.5.2/qa/libcmis/data/sharepoint/file.json0000664000175000017500000000255213407173247017021 00000000000000{ "d":{ "Author":{ "__deferred":{ "uri":"http://base/_api/Web/aFileId/Author" } }, "CheckInComment":"aCheckinComment", "CheckOutType":2, "CheckedOutByUser":{ "__deferred":{ "uri":"http://base/_api/Web/aFileId/CheckedOutByUser" } }, "ContentTag":"{AD7FC895-3E19-4553-AD77-9ADFC2A3B69A},1,2", "CustomizedPageStatus":0, "ETag":"\"{AD7FC895-3E19-4553-AD77-9ADFC2A3B69A},1\"", "Exists":true, "Length":"18045", "Level":1, "ListItemAllFields":{ "__deferred":{ "uri":"http://base/_api/Web/aFileId/ListItemAllFields" } }, "LockedByUser":{ "__deferred":{ "uri":"http://base/_api/Web/aFileId/LockedByUser" } }, "MajorVersion":2, "MinorVersion":0, "ModifiedBy":{ "__deferred":{ "uri":"http://base/_api/Web/aFileId/ModifiedBy" } }, "Name":"SharePointFile", "ServerRelativeUrl":"/Shared Documents/file.txt", "TimeCreated":"2014-07-08T09:29:29Z", "TimeLastModified":"2014-07-08T09:29:29Z", "Title":"", "UIVersion":512, "UIVersionLabel":"1.0", "Versions":{ "__deferred":{ "uri":"http://base/_api/Web/aFileId/Versions" } }, "__metadata":{ "id":"http://base/_api/Web/aFileId", "type":"SP.File", "uri":"http://base/_api/Web/aFileId" } } } libcmis-0.5.2/qa/libcmis/data/sharepoint/versions.json0000664000175000017500000000274613407173247017757 00000000000000{ "d": { "results": [ { "CheckInComment": "checkin Comment", "Created": "2014-07-25T12:07:57Z", "CreatedBy": { "__deferred": { "uri": "http://sp-cmis.cloudapp.net/_api/SP.FileVersionc617ba22-0ea6-4d05-a9ac-6135d8cede1a/CreatedBy" } }, "ID": 1, "IsCurrentVersion": true, "Size": 14027, "Url": "_vti_history/512/Shared Documents/File Name", "VersionLabel": "1.0", "__metadata": { "id": "http://sp-cmis.cloudapp.net/_api/SP.FileVersionc617ba22-0ea6-4d05-a9ac-6135d8cede1a", "type": "SP.FileVersion", "uri": "http://sp-cmis.cloudapp.net/_api/SP.FileVersionc617ba22-0ea6-4d05-a9ac-6135d8cede1a" } }, { "CheckInComment": "checkin Comment", "Created": "2014-07-25T12:13:47Z", "CreatedBy": { "__deferred": { "uri": "http://sp-cmis.cloudapp.net/_api/SP.FileVersion5e4560d1-2047-4d3d-9f14-5be91aaf1f6c/CreatedBy" } }, "ID": 2, "IsCurrentVersion": false, "Size": 14120, "Url": "_vti_history/513/Shared Documents/File Name", "VersionLabel": "1.1", "__metadata": { "id": "http://sp-cmis.cloudapp.net/_api/SP.FileVersion5e4560d1-2047-4d3d-9f14-5be91aaf1f6c", "type": "SP.FileVersion", "uri": "http://sp-cmis.cloudapp.net/_api/SP.FileVersion5e4560d1-2047-4d3d-9f14-5be91aaf1f6c" } } ] } } libcmis-0.5.2/qa/libcmis/data/sharepoint/new-xdigest.json0000664000175000017500000000067513407173247020344 00000000000000{ "d":{ "GetContextWebInformation":{ "FormDigestTimeoutSeconds":1800, "FormDigestValue":"new-xdigest-code", "LibraryVersion":"15.0.4420.1017", "SiteFullUrl":"http://base/_api", "SupportedSchemaVersions":{ "results":[ "14.0.0.0", "15.0.0.0" ] }, "WebFullUrl":"http://base/_api", "__metadata":{ "type":"SP.ContextWebInformation" } } } } libcmis-0.5.2/qa/libcmis/data/sharepoint/folder.json0000664000175000017500000000154113407173247017352 00000000000000{ "d": { "Files": { "__deferred": { "uri": "http://base/_api/Web/aFolderId/Files" } }, "Folders": { "__deferred": { "uri": "http://base/_api/Web/aFolderId/Folders" } }, "ItemCount": 3, "ListItemAllFields": { "__deferred": { "uri": "http://base/_api/Web/aFolderId/ListItemAllFields" } }, "Name": "SharePointFolder", "ParentFolder": { "__deferred": { "uri": "http://base/_api/Web/aFolderId/ParentFolder" } }, "Properties": { "__deferred": { "uri": "http://base/_api/Web/aFolderId/Properties" } }, "ServerRelativeUrl": "/SharePointFolder", "WelcomePage": "", "__metadata": { "id": "http://base/_api/Web/aFolderId", "type": "SP.Folder", "uri": "http://base/_api/Web/aFolderId" } } } libcmis-0.5.2/qa/libcmis/data/sharepoint/root-folder.json0000664000175000017500000000155113407173247020334 00000000000000{ "d":{ "Files":{ "__deferred":{ "uri":"http://base/_api/Web/rootFolderId/Files" } }, "Folders":{ "__deferred":{ "uri":"http://base/_api/Web/rootFolderId/Folders" } }, "ItemCount":0, "ListItemAllFields":{ "__deferred":{ "uri":"http://base/_api/Web/rootFolderId/ListItemAllFields" } }, "Name":"", "ParentFolder":{ "__deferred":{ "uri":"http://base/_api/Web/rootFolderId/ParentFolder" } }, "Properties":{ "__deferred":{ "uri":"http://base/_api/Web/rootFolderId/Properties" } }, "ServerRelativeUrl":"/", "WelcomePage":"SitePages/Home.aspx", "__metadata":{ "id":"http://base/_api/Web/rootFolderId", "type":"SP.Folder", "uri":"http://base/_api/Web/rootFolderId" } } } libcmis-0.5.2/qa/libcmis/data/sharepoint/auth-xml-resp.xml0000664000175000017500000001751613407173247020445 00000000000000 http://mock/_api/Web <updated>2014-07-10T07:24:26Z</updated> <author> <name /> </author> <content type="application/xml"> <m:properties> <d:AllowRssFeeds m:type="Edm.Boolean">true</d:AllowRssFeeds> <d:AppInstanceId m:type="Edm.Guid">00000000-0000-0000-0000-000000000000</d:AppInstanceId> <d:Configuration m:type="Edm.Int16">0</d:Configuration> <d:Created m:type="Edm.DateTime">2014-07-02T13:55:23</d:Created> <d:CustomMasterUrl>/_catalogs/masterpage/seattle.master</d:CustomMasterUrl> <d:Description /> <d:DocumentLibraryCalloutOfficeWebAppPreviewersDisabled m:type="Edm.Boolean">false</d:DocumentLibraryCalloutOfficeWebAppPreviewersDisabled> <d:EnableMinimalDownload m:type="Edm.Boolean">false</d:EnableMinimalDownload> <d:Id m:type="Edm.Guid">98a58f26-7ed4-436c-917b-05fa37e06ab2</d:Id> <d:Language m:type="Edm.Int32">1033</d:Language> <d:LastItemModifiedDate m:type="Edm.DateTime">2014-07-08T09:29:30Z</d:LastItemModifiedDate> <d:MasterUrl>/_catalogs/masterpage/seattle.master</d:MasterUrl> <d:QuickLaunchEnabled m:type="Edm.Boolean">true</d:QuickLaunchEnabled> <d:RecycleBinEnabled m:type="Edm.Boolean">true</d:RecycleBinEnabled> <d:ServerRelativeUrl>/</d:ServerRelativeUrl> <d:SyndicationEnabled m:type="Edm.Boolean">true</d:SyndicationEnabled> <d:Title>Home</d:Title> <d:TreeViewEnabled m:type="Edm.Boolean">false</d:TreeViewEnabled> <d:UIVersion m:type="Edm.Int32">15</d:UIVersion> <d:UIVersionConfigurationEnabled m:type="Edm.Boolean">false</d:UIVersionConfigurationEnabled> <d:Url>http://mock</d:Url> <d:WebTemplate>STS</d:WebTemplate> </m:properties> </content> </entry> ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/sharepoint/children-files.json����������������������������������������0000664�0001750�0001750�00000003146�13407173247�020772� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "d":{ "results":[ { "Author":{ "__deferred":{ "uri":"http://base/_api/Web/aFileId/Author" } }, "CheckInComment":"aCheckinComment", "CheckOutType":2, "CheckedOutByUser":{ "__deferred":{ "uri":"http://base/_api/Web/aFileId/CheckedOutByUser" } }, "ContentTag":"{AD7FC895-3E19-4553-AD77-9ADFC2A3B69A},1,2", "CustomizedPageStatus":0, "ETag":"\"{AD7FC895-3E19-4553-AD77-9ADFC2A3B69A},1\"", "Exists":true, "Length":"18045", "Level":1, "ListItemAllFields":{ "__deferred":{ "uri":"http://base/_api/Web/aFileId/ListItemAllFields" } }, "LockedByUser":{ "__deferred":{ "uri":"http://base/_api/Web/aFileId/LockedByUser" } }, "MajorVersion":2, "MinorVersion":0, "ModifiedBy":{ "__deferred":{ "uri":"http://base/_api/Web/aFileId/ModifiedBy" } }, "Name":"SharePoint File", "ServerRelative_api/Web":"/Shared Documents/file.txt", "TimeCreated":"2014-07-08T09:29:29Z", "TimeLastModified":"2014-07-08T09:29:29Z", "Title":"", "UIVersion":512, "UIVersionLabel":"1.0", "Versions":{ "__deferred":{ "uri":"http://base/_api/Web/aFileId/Versions" } }, "__metadata":{ "id":"http://base/_api/Web/aFileId", "type":"SP.File", "uri":"http://base/_api/Web/aFileId" } } ] } } ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/�����������������������������������������������������������������0000775�0001750�0001750�00000000000�13407173247�014047� 5����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/allowable-actions.xml��������������������������������������������0000664�0001750�0001750�00000003475�13407173247�020122� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <ns2:allowableActions xmlns="http://docs.oasis-open.org/ns/cmis/messaging/200908/" xmlns:ns2="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:ns3="http://docs.oasis-open.org/ns/cmis/restatom/200908/"> <ns2:canDeleteObject>true</ns2:canDeleteObject> <ns2:canUpdateProperties>true</ns2:canUpdateProperties> <ns2:canGetFolderTree>true</ns2:canGetFolderTree> <ns2:canGetProperties>true</ns2:canGetProperties> <ns2:canGetObjectRelationships>false</ns2:canGetObjectRelationships> <ns2:canGetObjectParents>true</ns2:canGetObjectParents> <ns2:canGetFolderParent>true</ns2:canGetFolderParent> <ns2:canGetDescendants>true</ns2:canGetDescendants> <ns2:canMoveObject>true</ns2:canMoveObject> <ns2:canDeleteContentStream>false</ns2:canDeleteContentStream> <ns2:canCheckOut>false</ns2:canCheckOut> <ns2:canCancelCheckOut>false</ns2:canCancelCheckOut> <ns2:canCheckIn>false</ns2:canCheckIn> <ns2:canSetContentStream>false</ns2:canSetContentStream> <ns2:canGetAllVersions>false</ns2:canGetAllVersions> <ns2:canAddObjectToFolder>false</ns2:canAddObjectToFolder> <ns2:canRemoveObjectFromFolder>false</ns2:canRemoveObjectFromFolder> <ns2:canGetContentStream>false</ns2:canGetContentStream> <ns2:canApplyPolicy>false</ns2:canApplyPolicy> <ns2:canGetAppliedPolicies>false</ns2:canGetAppliedPolicies> <ns2:canRemovePolicy>false</ns2:canRemovePolicy> <ns2:canGetChildren>true</ns2:canGetChildren> <ns2:canCreateDocument>true</ns2:canCreateDocument> <ns2:canCreateFolder>true</ns2:canCreateFolder> <ns2:canCreateRelationship>false</ns2:canCreateRelationship> <ns2:canDeleteTree>true</ns2:canDeleteTree> <ns2:canGetRenditions>false</ns2:canGetRenditions> <ns2:canGetACL>false</ns2:canGetACL> <ns2:canApplyACL>false</ns2:canApplyACL> </ns2:allowableActions> ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/create-folder-bad-type.xml���������������������������������������0000664�0001750�0001750�00000011011�13407173247�020722� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:entry xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>Admin</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:published>2012-11-29T16:14:47Z</atom:published> <atom:title>create folder</atom:title> <app:edited>2012-11-29T16:14:47Z</app:edited> <atom:updated>2012-11-29T16:14:47Z</atom:updated> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyId queryName="cmis:allowedChildObjectTypeIds" displayName="Allowed Child Types" localName="cmis:allowedChildObjectTypeIds" propertyDefinitionId="cmis:allowedChildObjectTypeIds"> <cmis:value>*</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:path" displayName="Path" localName="cmis:path" propertyDefinitionId="cmis:path"> <cmis:value>/create folder</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>create folder</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>create-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2012-11-29T16:14:47.019Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1354205687020</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyId queryName="cmis:parentId" displayName="Parent Id" localName="cmis:parentId" propertyDefinitionId="cmis:parentId"> <cmis:value>root-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2012-11-29T16:14:47.020Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmisra:object> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/id?id=create-folder" type="application/atom+xml;type=entry" cmisra:id="create-folder"/> <atom:link rel="enclosure" href="http://mockup/mock/id?id=create-folder" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/id?id=create-folder" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=cmis%3Adocument" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=create-folder" type="application/cmisallowableactions+xml"/> <atom:link rel="up" href="http://mockup/mock/parents?id=create-folder" type="application/atom+xml;type=feed"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/foldertree" href="http://mockup/mock/foldertree?id=create-folder" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=create-folder" type="application/cmisacl+xml"/> </atom:entry> �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/valid-object-noactions.xml���������������������������������������0000664�0001750�0001750�00000012002�13407173247�021042� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:entry xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>Admin</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:published>2012-11-29T16:14:47Z</atom:published> <atom:title>Valid Object</atom:title> <app:edited>2012-11-29T16:14:47Z</app:edited> <atom:updated>2012-11-29T16:14:47Z</atom:updated> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyId queryName="cmis:allowedChildObjectTypeIds" displayName="Allowed Child Types" localName="cmis:allowedChildObjectTypeIds" propertyDefinitionId="cmis:allowedChildObjectTypeIds"> <cmis:value>*</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:path" displayName="Path" localName="cmis:path" propertyDefinitionId="cmis:path"> <cmis:value>/Valid Object</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Valid Object</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>valid-object</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2012-11-29T16:14:47.019Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1354205687020</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyId queryName="cmis:parentId" displayName="Parent Id" localName="cmis:parentId" propertyDefinitionId="cmis:parentId"> <cmis:value>root-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2012-11-29T16:14:47.020Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> <exampleExtension:exampleExtension xmlns="http://my/cmis/extension" xmlns:exampleExtension="http://my/cmis/extension"> <objectId xmlns:ns0="http://my/cmis/extension" ns0:type="cmis:folder">valid-object</objectId> <name>Valid Object</name> </exampleExtension:exampleExtension> </cmisra:object> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/id?id=valid-object" type="application/atom+xml;type=entry" cmisra:id="valid-object"/> <atom:link rel="enclosure" href="http://mockup/mock/id?id=valid-object" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/id?id=valid-object" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=cmis%3Afolder" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=valid-object" type="application/cmisallowableactions+xml"/> <atom:link rel="up" href="http://mockup/mock/parents?id=valid-object" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/children?id=valid-object" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/descendants?id=valid-object" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/foldertree" href="http://mockup/mock/foldertree?id=valid-object" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=valid-object" type="application/cmisacl+xml"/> </atom:entry> ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/type-docLevel1.xml�����������������������������������������������0000664�0001750�0001750�00000050720�13407173247�017312� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:entry xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>http://mockup/mock/obscure id</atom:id> <atom:title>Document Level 1</atom:title> <app:edited>2013-01-25T09:47:39Z</app:edited> <atom:updated>2013-01-25T09:47:39Z</atom:updated> <cmisra:type xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/" xsi:type="cmis:cmisTypeDocumentDefinitionType"> <cmis:id>DocumentLevel1</cmis:id> <cmis:localName>DocumentLevel1</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Document Level 1</cmis:displayName> <cmis:queryName>DocumentLevel1</cmis:queryName> <cmis:description>Description of Document Level 1 Type</cmis:description> <cmis:baseId>cmis:document</cmis:baseId> <cmis:parentId>cmis:document</cmis:parentId> <cmis:creatable>true</cmis:creatable> <cmis:fileable>true</cmis:fileable> <cmis:queryable>false</cmis:queryable> <cmis:fulltextIndexed>false</cmis:fulltextIndexed> <cmis:includedInSupertypeQuery>true</cmis:includedInSupertypeQuery> <cmis:controllablePolicy>false</cmis:controllablePolicy> <cmis:controllableACL>true</cmis:controllableACL> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isLatestMajorVersion</cmis:id> <cmis:localName>cmis:isLatestMajorVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Latest Major Version</cmis:displayName> <cmis:queryName>cmis:isLatestMajorVersion</cmis:queryName> <cmis:description>This is a Is Latest Major Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:contentStreamId</cmis:id> <cmis:localName>cmis:contentStreamId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Stream Id</cmis:displayName> <cmis:queryName>cmis:contentStreamId</cmis:queryName> <cmis:description>This is a Stream Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyIntegerDefinition> <cmis:id>cmis:contentStreamLength</cmis:id> <cmis:localName>cmis:contentStreamLength</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Content Length</cmis:displayName> <cmis:queryName>cmis:contentStreamLength</cmis:queryName> <cmis:description>This is a Content Length property.</cmis:description> <cmis:propertyType>integer</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIntegerDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:versionSeriesCheckedOutBy</cmis:id> <cmis:localName>cmis:versionSeriesCheckedOutBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out By</cmis:displayName> <cmis:queryName>cmis:versionSeriesCheckedOutBy</cmis:queryName> <cmis:description>This is a Checked Out By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectTypeId</cmis:id> <cmis:localName>cmis:objectTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Type-Id</cmis:displayName> <cmis:queryName>cmis:objectTypeId</cmis:queryName> <cmis:description>This is a Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>oncreate</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:versionSeriesCheckedOutId</cmis:id> <cmis:localName>cmis:versionSeriesCheckedOutId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out Id</cmis:displayName> <cmis:queryName>cmis:versionSeriesCheckedOutId</cmis:queryName> <cmis:description>This is a Checked Out Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:name</cmis:id> <cmis:localName>cmis:name</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Name</cmis:displayName> <cmis:queryName>cmis:name</cmis:queryName> <cmis:description>This is a Name property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:contentStreamMimeType</cmis:id> <cmis:localName>cmis:contentStreamMimeType</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Mime Type</cmis:displayName> <cmis:queryName>cmis:contentStreamMimeType</cmis:queryName> <cmis:description>This is a Mime Type property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:versionSeriesId</cmis:id> <cmis:localName>cmis:versionSeriesId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Version Series Id</cmis:displayName> <cmis:queryName>cmis:versionSeriesId</cmis:queryName> <cmis:description>This is a Version Series Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:creationDate</cmis:id> <cmis:localName>cmis:creationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Creation Date</cmis:displayName> <cmis:queryName>cmis:creationDate</cmis:queryName> <cmis:description>This is a Creation Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:changeToken</cmis:id> <cmis:localName>cmis:changeToken</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Change Token</cmis:displayName> <cmis:queryName>cmis:changeToken</cmis:queryName> <cmis:description>This is a Change Token property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isLatestVersion</cmis:id> <cmis:localName>cmis:isLatestVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Latest Version</cmis:displayName> <cmis:queryName>cmis:isLatestVersion</cmis:queryName> <cmis:description>This is a Is Latest Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:versionLabel</cmis:id> <cmis:localName>cmis:versionLabel</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Version Label</cmis:displayName> <cmis:queryName>cmis:versionLabel</cmis:queryName> <cmis:description>This is a Version Label property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isVersionSeriesCheckedOut</cmis:id> <cmis:localName>cmis:isVersionSeriesCheckedOut</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out</cmis:displayName> <cmis:queryName>cmis:isVersionSeriesCheckedOut</cmis:queryName> <cmis:description>This is a Checked Out property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:lastModifiedBy</cmis:id> <cmis:localName>cmis:lastModifiedBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modified By</cmis:displayName> <cmis:queryName>cmis:lastModifiedBy</cmis:queryName> <cmis:description>This is a Modified By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:createdBy</cmis:id> <cmis:localName>cmis:createdBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Created By</cmis:displayName> <cmis:queryName>cmis:createdBy</cmis:queryName> <cmis:description>This is a Created By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:checkinComment</cmis:id> <cmis:localName>cmis:checkinComment</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checkin Comment</cmis:displayName> <cmis:queryName>cmis:checkinComment</cmis:queryName> <cmis:description>This is a Checkin Comment property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectId</cmis:id> <cmis:localName>cmis:objectId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Object Id</cmis:displayName> <cmis:queryName>cmis:objectId</cmis:queryName> <cmis:description>This is a Object Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isMajorVersion</cmis:id> <cmis:localName>cmis:isMajorVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Major Version</cmis:displayName> <cmis:queryName>cmis:isMajorVersion</cmis:queryName> <cmis:description>This is a Is Major Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isImmutable</cmis:id> <cmis:localName>cmis:isImmutable</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Immutable</cmis:displayName> <cmis:queryName>cmis:isImmutable</cmis:queryName> <cmis:description>This is a Immutable property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:baseTypeId</cmis:id> <cmis:localName>cmis:baseTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Base-Type-Id</cmis:displayName> <cmis:queryName>cmis:baseTypeId</cmis:queryName> <cmis:description>This is a Base-Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:lastModificationDate</cmis:id> <cmis:localName>cmis:lastModificationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modification Date</cmis:displayName> <cmis:queryName>cmis:lastModificationDate</cmis:queryName> <cmis:description>This is a Modification Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:contentStreamFileName</cmis:id> <cmis:localName>cmis:contentStreamFileName</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>File Name</cmis:displayName> <cmis:queryName>cmis:contentStreamFileName</cmis:queryName> <cmis:description>This is a File Name property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:versionable>false</cmis:versionable> <cmis:contentStreamAllowed>allowed</cmis:contentStreamAllowed> </cmisra:type> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/type?id=DocumentLevel1" type="application/atom+xml;type=entry" cmisra:id="DocumentLevel1"/> <atom:link rel="enclosure" href="http://mockup/mock/type?id=DocumentLevel1" type="application/atom+xml;type=entry"/> <atom:link rel="up" href="http://mockup/mock/type?id=cmis%3Adocument" type="application/atom+xml;type=entry"/> <atom:link rel="down" href="http://mockup/mock/types?typeId=DocumentLevel1" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/typedesc?typeId=DocumentLevel1" type="application/cmistree+xml"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=cmis%3Adocument" type="application/atom+xml;type=entry"/> </atom:entry> ������������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/test-document-relationships.xml����������������������������������0000664�0001750�0001750�00000036125�13407173247�022175� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:entry xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:published>2013-01-28T14:10:06Z</atom:published> <atom:title>Test Document</atom:title> <app:edited>2013-01-28T14:10:06Z</app:edited> <atom:updated>2013-01-28T14:10:06Z</atom:updated> <atom:content src="http://mockup/mock/content/data.txt?id=test-document" type="text/plain"/> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>12345</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyHtml queryName="HtmlProp" displayName="Sample Html Property" localName="HtmlProp" propertyDefinitionId="HtmlProp"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyId queryName="IdProp" displayName="Sample Id Property" localName="IdProp" propertyDefinitionId="IdProp"/> <cmis:propertyUri queryName="UriProp" displayName="Sample Uri Property" localName="UriProp" propertyDefinitionId="UriProp"/> <cmis:propertyDateTime queryName="DateTimePropMV" displayName="Sample DateTime multi-value Property" localName="DateTimePropMV" propertyDefinitionId="DateTimePropMV"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"/> <cmis:propertyDecimal queryName="DecimalProp" displayName="Sample Decimal Property" localName="DecimalProp" propertyDefinitionId="DecimalProp"/> <cmis:propertyUri queryName="UriPropMV" displayName="Sample Uri multi-value Property" localName="UriPropMV" propertyDefinitionId="UriPropMV"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"/> <cmis:propertyBoolean queryName="BooleanProp" displayName="Sample Boolean Property" localName="BooleanProp" propertyDefinitionId="BooleanProp"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="IdPropMV" displayName="Sample Id Html multi-value Property" localName="IdPropMV" propertyDefinitionId="IdPropMV"/> <cmis:propertyString queryName="PickListProp" displayName="Sample Pick List Property" localName="PickListProp" propertyDefinitionId="PickListProp"> <cmis:value>blue</cmis:value> </cmis:propertyString> <cmis:propertyHtml queryName="HtmlPropMV" displayName="Sample Html multi-value Property" localName="HtmlPropMV" propertyDefinitionId="HtmlPropMV"/> <cmis:propertyInteger queryName="IntProp" displayName="Sample Int Property" localName="IntProp" propertyDefinitionId="IntProp"/> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Test Document</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="StringProp" displayName="Sample String Property" localName="StringProp" propertyDefinitionId="StringProp"> <cmis:value>My Doc StringProperty 6</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359382206736</cmis:value> </cmis:propertyString> <cmis:propertyDecimal queryName="DecimalPropMV" displayName="Sample Decimal multi-value Property" localName="DecimalPropMV" propertyDefinitionId="DecimalPropMV"/> <cmis:propertyDateTime queryName="DateTimeProp" displayName="Sample DateTime Property" localName="DateTimeProp" propertyDefinitionId="DateTimeProp"/> <cmis:propertyBoolean queryName="BooleanPropMV" displayName="Sample Boolean multi-value Property" localName="BooleanPropMV" propertyDefinitionId="BooleanPropMV"/> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>test-document</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyInteger queryName="IntPropMV" displayName="Sample Int multi-value Property" localName="IntPropMV" propertyDefinitionId="IntPropMV"/> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> <cmis:allowableActions> <cmis:canDeleteObject>true</cmis:canDeleteObject> <cmis:canUpdateProperties>true</cmis:canUpdateProperties> <cmis:canGetFolderTree>false</cmis:canGetFolderTree> <cmis:canGetProperties>true</cmis:canGetProperties> <cmis:canGetObjectRelationships>false</cmis:canGetObjectRelationships> <cmis:canGetObjectParents>true</cmis:canGetObjectParents> <cmis:canGetFolderParent>false</cmis:canGetFolderParent> <cmis:canGetDescendants>false</cmis:canGetDescendants> <cmis:canMoveObject>true</cmis:canMoveObject> <cmis:canDeleteContentStream>true</cmis:canDeleteContentStream> <cmis:canCheckOut>true</cmis:canCheckOut> <cmis:canCancelCheckOut>false</cmis:canCancelCheckOut> <cmis:canCheckIn>false</cmis:canCheckIn> <cmis:canSetContentStream>true</cmis:canSetContentStream> <cmis:canGetAllVersions>true</cmis:canGetAllVersions> <cmis:canAddObjectToFolder>true</cmis:canAddObjectToFolder> <cmis:canRemoveObjectFromFolder>true</cmis:canRemoveObjectFromFolder> <cmis:canGetContentStream>true</cmis:canGetContentStream> <cmis:canApplyPolicy>false</cmis:canApplyPolicy> <cmis:canGetAppliedPolicies>false</cmis:canGetAppliedPolicies> <cmis:canRemovePolicy>false</cmis:canRemovePolicy> <cmis:canGetChildren>false</cmis:canGetChildren> <cmis:canCreateDocument>false</cmis:canCreateDocument> <cmis:canCreateFolder>false</cmis:canCreateFolder> <cmis:canCreateRelationship>false</cmis:canCreateRelationship> <cmis:canDeleteTree>false</cmis:canDeleteTree> <cmis:canGetRenditions>false</cmis:canGetRenditions> <cmis:canGetACL>false</cmis:canGetACL> <cmis:canApplyACL>false</cmis:canApplyACL> </cmis:allowableActions> <exampleExtension:exampleExtension xmlns="http://mockup/cmis/extension" xmlns:exampleExtension="http://mockup/cmis/extension"> <objectId xmlns:ns0="http://mockup/cmis/extension" ns0:type="DocumentLevel2">test-document</objectId> <name>Test Document</name> </exampleExtension:exampleExtension> <cmis:relationship> <cmis:properties> <cmis:propertyId displayName="Target Id" localName="targetId" propertyDefinitionId="cmis:targetId" queryName="cmis:targetId"> <cmis:value>workspace://SpacesStore/5d8908d9-1b4a-4265-b1de-5d7244fcea70;2.2</cmis:value> </cmis:propertyId> <cmis:propertyId displayName="Object Type Id" localName="objectTypeId" propertyDefinitionId="cmis:objectTypeId" queryName="cmis:objectTypeId"> <cmis:value>R:cm:original</cmis:value> </cmis:propertyId> <cmis:propertyString displayName="Last Modified By" localName="lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy" queryName="cmis:lastModifiedBy"> <cmis:value>admin</cmis:value> </cmis:propertyString> <cmis:propertyId displayName="Source Id" localName="sourceId" propertyDefinitionId="cmis:sourceId" queryName="cmis:sourceId"> <cmis:value>workspace://SpacesStore/5d8908d9-1b4a-4265-b1de-5d7244fcea70;pwc</cmis:value> </cmis:propertyId> <cmis:propertyString displayName="Name" localName="name" propertyDefinitionId="cmis:name" queryName="cmis:name"> <cmis:value>75|workspace://SpacesStore/3885d9a2-0540-41ab-810a-38ccb1b160d6|workspace://SpacesStore/5d8908d9-1b4a-4265-b1de-5d7244fcea70|{http://www.alfresco.org/model/content/1.0}original</cmis:value> </cmis:propertyString> <cmis:propertyString displayName="Created by" localName="createdBy" propertyDefinitionId="cmis:createdBy" queryName="cmis:createdBy"> <cmis:value>admin</cmis:value> </cmis:propertyString> <cmis:propertyId displayName="Object Id" localName="objectId" propertyDefinitionId="cmis:objectId" queryName="cmis:objectId"> <cmis:value>assoc:75</cmis:value> </cmis:propertyId> <cmis:propertyDateTime displayName="Creation Date" localName="creationDate" propertyDefinitionId="cmis:creationDate" queryName="cmis:creationDate"> <cmis:value>2010-05-01T00:00:00+02:00</cmis:value> </cmis:propertyDateTime> <cmis:propertyString displayName="Change token" localName="changeToken" propertyDefinitionId="cmis:changeToken" queryName="cmis:changeToken"/> <cmis:propertyId displayName="Base Type Id" localName="baseTypeId" propertyDefinitionId="cmis:baseTypeId" queryName="cmis:baseTypeId"> <cmis:value>cmis:relationship</cmis:value> </cmis:propertyId> <cmis:propertyId displayName="Alfresco Node Ref" localName="nodeRef" propertyDefinitionId="alfcmis:nodeRef" queryName="alfcmis:nodeRef"> <cmis:value>75|workspace://SpacesStore/3885d9a2-0540-41ab-810a-38ccb1b160d6|workspace://SpacesStore/5d8908d9-1b4a-4265-b1de-5d7244fcea70|{http://www.alfresco.org/model/content/1.0}original</cmis:value> </cmis:propertyId> <cmis:propertyString displayName="Description" localName="description" propertyDefinitionId="cmis:description" queryName="cmis:description"/> <cmis:propertyDateTime displayName="Last Modified Date" localName="lastModificationDate" propertyDefinitionId="cmis:lastModificationDate" queryName="cmis:lastModificationDate"> <cmis:value>2010-05-01T00:00:00+02:00</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmis:relationship> </cmisra:object> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/id?id=test-document" type="application/atom+xml;type=entry" cmisra:id="test-document"/> <atom:link rel="enclosure" href="http://mockup/mock/id?id=test-document" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/id?id=test-document" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=DocumentLevel2" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=test-document" type="application/cmisallowableactions+xml"/> <atom:link rel="up" href="http://mockup/mock/parents?id=test-document" type="application/atom+xml;type=feed"/> <atom:link rel="edit-media" href="http://mockup/mock/content?id=test-document" type="text/plain"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=test-document" type="application/cmisacl+xml"/> <atom:link rel="version-history" href="http://mockup/mock/versions?id=test-document" type="application/atom+xml;type=feed"/> <atom:link rel="alternate" href="http://mockup/mock/renditions?id=test-document-rendition1" type="image/png" cmisra:renditionKind="cmis:thumbnail" title="picture" length="40385"/> <atom:link rel="alternate" href="http://mockup/mock/renditions?id=test-document-rendition2" type="application/pdf" cmisra:renditionKind="pdf" title="Doc as PDF"/> </atom:entry> �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/create-folder.xml������������������������������������������������0000664�0001750�0001750�00000011350�13407173247�017225� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:entry xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>Admin</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:published>2012-11-29T16:14:47Z</atom:published> <atom:title>create folder</atom:title> <app:edited>2012-11-29T16:14:47Z</app:edited> <atom:updated>2012-11-29T16:14:47Z</atom:updated> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyId queryName="cmis:allowedChildObjectTypeIds" displayName="Allowed Child Types" localName="cmis:allowedChildObjectTypeIds" propertyDefinitionId="cmis:allowedChildObjectTypeIds"> <cmis:value>*</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:path" displayName="Path" localName="cmis:path" propertyDefinitionId="cmis:path"> <cmis:value>/create folder</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>create folder</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>create-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2012-11-29T16:14:47.019Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1354205687020</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyId queryName="cmis:parentId" displayName="Parent Id" localName="cmis:parentId" propertyDefinitionId="cmis:parentId"> <cmis:value>root-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2012-11-29T16:14:47.020Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmisra:object> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/id?id=create-folder" type="application/atom+xml;type=entry" cmisra:id="create-folder"/> <atom:link rel="enclosure" href="http://mockup/mock/id?id=create-folder" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/id?id=create-folder" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=cmis%3Afolder" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=create-folder" type="application/cmisallowableactions+xml"/> <atom:link rel="up" href="http://mockup/mock/parents?id=create-folder" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/children?id=create-folder" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/descendants?id=create-folder" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/foldertree" href="http://mockup/mock/foldertree?id=create-folder" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=create-folder" type="application/cmisacl+xml"/> </atom:entry> ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/working-copy.xml�������������������������������������������������0000664�0001750�0001750�00000017722�13407173247�017152� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:entry xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:published>2013-05-21T13:50:45Z</atom:published> <atom:title>Test Document</atom:title> <app:edited>2013-05-21T13:50:45Z</app:edited> <atom:updated>2013-05-21T13:50:45Z</atom:updated> <atom:content src="http://mockup/mock/content/data.txt?id=working-copy" type="text/plain"/> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>12345</cmis:value> </cmis:propertyInteger> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"> <cmis:value>working-copy</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Test Document</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="VersionedStringProp" displayName="Sample String Property" localName="VersionedStringProp" propertyDefinitionId="VersionedStringProp"/> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"> <cmis:value>version-series</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-05-21T13:50:45.300Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1369144245300</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"> <cmis:value>V 0.2</cmis:value> </cmis:propertyString> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>working-copy</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-05-21T13:50:45.300Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> <exampleExtension:exampleExtension xmlns="http://mockup/cmis/extension" xmlns:exampleExtension="http://mockup/cmis/extension"> <objectId xmlns:ns0="http://mockup/cmis/extension" ns0:type="DocumentLevel2">working-copy</objectId> <name>Test Document</name> </exampleExtension:exampleExtension> </cmisra:object> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/id?id=working-copy" type="application/atom+xml;type=entry" cmisra:id="working-copy"/> <atom:link rel="enclosure" href="http://mockup/mock/id?id=working-copy" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/id?id=working-copy" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=DocumentLevel2" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=working-copy" type="application/cmisallowableactions+xml"/> <atom:link rel="up" href="http://mockup/mock/parents?id=working-copy" type="application/atom+xml;type=feed"/> <atom:link rel="version-history" href="http://mockup/mock/versions?id=working-copy&versionSeries=version-series" type="application/atom+xml;type=feed"/> <atom:link rel="edit-media" href="http://mockup/mock/content?id=working-copy" type="text/plain"/> <atom:link rel="working-copy" href="http://mockup/mock/id?id=working-copy" type="application/atom+xml;type=entry"/> <atom:link rel="via" href="http://mockup/mock/id?id=working-copy" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=working-copy" type="application/cmisacl+xml"/> </atom:entry> ����������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/type-folder.xml��������������������������������������������������0000664�0001750�0001750�00000026474�13407173247�016760� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:entry xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>http://mockup/mock/obscure id</atom:id> <atom:title>CMIS Folder</atom:title> <app:edited>2012-11-29T16:39:44Z</app:edited> <atom:updated>2012-11-29T16:39:44Z</atom:updated> <cmisra:type xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/" xsi:type="cmis:cmisTypeFolderDefinitionType"> <cmis:id>cmis:folder</cmis:id> <cmis:localName>cmis:folder</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>CMIS Folder</cmis:displayName> <cmis:queryName>cmis:folder</cmis:queryName> <cmis:description>Description of CMIS Folder Type</cmis:description> <cmis:baseId>cmis:folder</cmis:baseId> <cmis:creatable>true</cmis:creatable> <cmis:fileable>true</cmis:fileable> <cmis:queryable>false</cmis:queryable> <cmis:fulltextIndexed>false</cmis:fulltextIndexed> <cmis:includedInSupertypeQuery>true</cmis:includedInSupertypeQuery> <cmis:controllablePolicy>false</cmis:controllablePolicy> <cmis:controllableACL>true</cmis:controllableACL> <cmis:propertyIdDefinition> <cmis:id>cmis:allowedChildObjectTypeIds</cmis:id> <cmis:localName>cmis:allowedChildObjectTypeIds</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Allowed Child Types</cmis:displayName> <cmis:queryName>cmis:allowedChildObjectTypeIds</cmis:queryName> <cmis:description>This is a Allowed Child Types property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:path</cmis:id> <cmis:localName>cmis:path</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Path</cmis:displayName> <cmis:queryName>cmis:path</cmis:queryName> <cmis:description>This is a Path property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:lastModifiedBy</cmis:id> <cmis:localName>cmis:lastModifiedBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modified By</cmis:displayName> <cmis:queryName>cmis:lastModifiedBy</cmis:queryName> <cmis:description>This is a Modified By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectTypeId</cmis:id> <cmis:localName>cmis:objectTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Type-Id</cmis:displayName> <cmis:queryName>cmis:objectTypeId</cmis:queryName> <cmis:description>This is a Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>oncreate</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:createdBy</cmis:id> <cmis:localName>cmis:createdBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Created By</cmis:displayName> <cmis:queryName>cmis:createdBy</cmis:queryName> <cmis:description>This is a Created By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:name</cmis:id> <cmis:localName>cmis:name</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Name</cmis:displayName> <cmis:queryName>cmis:name</cmis:queryName> <cmis:description>This is a Name property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectId</cmis:id> <cmis:localName>cmis:objectId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Object Id</cmis:displayName> <cmis:queryName>cmis:objectId</cmis:queryName> <cmis:description>This is a Object Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:creationDate</cmis:id> <cmis:localName>cmis:creationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Creation Date</cmis:displayName> <cmis:queryName>cmis:creationDate</cmis:queryName> <cmis:description>This is a Creation Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:changeToken</cmis:id> <cmis:localName>cmis:changeToken</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Change Token</cmis:displayName> <cmis:queryName>cmis:changeToken</cmis:queryName> <cmis:description>This is a Change Token property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:baseTypeId</cmis:id> <cmis:localName>cmis:baseTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Base-Type-Id</cmis:displayName> <cmis:queryName>cmis:baseTypeId</cmis:queryName> <cmis:description>This is a Base-Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:parentId</cmis:id> <cmis:localName>cmis:parentId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Parent Id</cmis:displayName> <cmis:queryName>cmis:parentId</cmis:queryName> <cmis:description>This is a Parent Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:lastModificationDate</cmis:id> <cmis:localName>cmis:lastModificationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modification Date</cmis:displayName> <cmis:queryName>cmis:lastModificationDate</cmis:queryName> <cmis:description>This is a Modification Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> </cmisra:type> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/type?id=cmis:folder" type="application/atom+xml;type=entry" cmisra:id="cmis:folder"/> <atom:link rel="enclosure" href="http://mockup/mock/type?id=cmis:folder" type="application/atom+xml;type=entry"/> <atom:link rel="down" href="http://mockup/mock/types?typeId=cmis:folder" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/typedesc?typeId=cmis:folder" type="application/cmistree+xml"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=cmis:folder" type="application/atom+xml;type=entry"/> </atom:entry> ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/test-document-updated.xml����������������������������������������0000664�0001750�0001750�00000026605�13407173247�020741� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:entry xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:published>2013-01-28T14:10:06Z</atom:published> <atom:title>New name</atom:title> <app:edited>2013-01-28T14:10:06Z</app:edited> <atom:updated>2013-01-28T14:10:06Z</atom:updated> <atom:content src="http://mockup/mock/content/data.txt?id=test-document" type="text/plain"/> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>12345</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyHtml queryName="HtmlProp" displayName="Sample Html Property" localName="HtmlProp" propertyDefinitionId="HtmlProp"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyId queryName="IdProp" displayName="Sample Id Property" localName="IdProp" propertyDefinitionId="IdProp"/> <cmis:propertyUri queryName="UriProp" displayName="Sample Uri Property" localName="UriProp" propertyDefinitionId="UriProp"/> <cmis:propertyDateTime queryName="DateTimePropMV" displayName="Sample DateTime multi-value Property" localName="DateTimePropMV" propertyDefinitionId="DateTimePropMV"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"/> <cmis:propertyDecimal queryName="DecimalProp" displayName="Sample Decimal Property" localName="DecimalProp" propertyDefinitionId="DecimalProp"/> <cmis:propertyUri queryName="UriPropMV" displayName="Sample Uri multi-value Property" localName="UriPropMV" propertyDefinitionId="UriPropMV"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"/> <cmis:propertyBoolean queryName="BooleanProp" displayName="Sample Boolean Property" localName="BooleanProp" propertyDefinitionId="BooleanProp"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="IdPropMV" displayName="Sample Id Html multi-value Property" localName="IdPropMV" propertyDefinitionId="IdPropMV"/> <cmis:propertyString queryName="PickListProp" displayName="Sample Pick List Property" localName="PickListProp" propertyDefinitionId="PickListProp"> <cmis:value>blue</cmis:value> </cmis:propertyString> <cmis:propertyHtml queryName="HtmlPropMV" displayName="Sample Html multi-value Property" localName="HtmlPropMV" propertyDefinitionId="HtmlPropMV"/> <cmis:propertyInteger queryName="IntProp" displayName="Sample Int Property" localName="IntProp" propertyDefinitionId="IntProp"/> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>New name</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="StringProp" displayName="Sample String Property" localName="StringProp" propertyDefinitionId="StringProp"> <cmis:value>My Doc StringProperty 6</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359382206736</cmis:value> </cmis:propertyString> <cmis:propertyDecimal queryName="DecimalPropMV" displayName="Sample Decimal multi-value Property" localName="DecimalPropMV" propertyDefinitionId="DecimalPropMV"/> <cmis:propertyDateTime queryName="DateTimeProp" displayName="Sample DateTime Property" localName="DateTimeProp" propertyDefinitionId="DateTimeProp"/> <cmis:propertyBoolean queryName="BooleanPropMV" displayName="Sample Boolean multi-value Property" localName="BooleanPropMV" propertyDefinitionId="BooleanPropMV"/> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>test-document</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyInteger queryName="IntPropMV" displayName="Sample Int multi-value Property" localName="IntPropMV" propertyDefinitionId="IntPropMV"/> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> <cmis:allowableActions> <cmis:canDeleteObject>true</cmis:canDeleteObject> <cmis:canUpdateProperties>true</cmis:canUpdateProperties> <cmis:canGetFolderTree>false</cmis:canGetFolderTree> <cmis:canGetProperties>true</cmis:canGetProperties> <cmis:canGetObjectRelationships>false</cmis:canGetObjectRelationships> <cmis:canGetObjectParents>true</cmis:canGetObjectParents> <cmis:canGetFolderParent>false</cmis:canGetFolderParent> <cmis:canGetDescendants>false</cmis:canGetDescendants> <cmis:canMoveObject>true</cmis:canMoveObject> <cmis:canDeleteContentStream>true</cmis:canDeleteContentStream> <cmis:canCheckOut>false</cmis:canCheckOut> <cmis:canCancelCheckOut>false</cmis:canCancelCheckOut> <cmis:canCheckIn>false</cmis:canCheckIn> <cmis:canSetContentStream>true</cmis:canSetContentStream> <cmis:canGetAllVersions>false</cmis:canGetAllVersions> <cmis:canAddObjectToFolder>true</cmis:canAddObjectToFolder> <cmis:canRemoveObjectFromFolder>true</cmis:canRemoveObjectFromFolder> <cmis:canGetContentStream>true</cmis:canGetContentStream> <cmis:canApplyPolicy>false</cmis:canApplyPolicy> <cmis:canGetAppliedPolicies>false</cmis:canGetAppliedPolicies> <cmis:canRemovePolicy>false</cmis:canRemovePolicy> <cmis:canGetChildren>false</cmis:canGetChildren> <cmis:canCreateDocument>false</cmis:canCreateDocument> <cmis:canCreateFolder>false</cmis:canCreateFolder> <cmis:canCreateRelationship>false</cmis:canCreateRelationship> <cmis:canDeleteTree>false</cmis:canDeleteTree> <cmis:canGetRenditions>false</cmis:canGetRenditions> <cmis:canGetACL>false</cmis:canGetACL> <cmis:canApplyACL>false</cmis:canApplyACL> </cmis:allowableActions> <exampleExtension:exampleExtension xmlns="http://mockup/cmis/extension" xmlns:exampleExtension="http://mockup/cmis/extension"> <objectId xmlns:ns0="http://mockup/cmis/extension" ns0:type="DocumentLevel2">test-document</objectId> <name>New name</name> </exampleExtension:exampleExtension> </cmisra:object> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/id?id=test-document" type="application/atom+xml;type=entry" cmisra:id="test-document"/> <atom:link rel="enclosure" href="http://mockup/mock/id?id=test-document" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/id?id=test-document" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=ComplexType" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=test-document" type="application/cmisallowableactions+xml"/> <atom:link rel="up" href="http://mockup/mock/parents?id=test-document" type="application/atom+xml;type=feed"/> <atom:link rel="edit-media" href="http://mockup/mock/content?id=test-document" type="text/plain"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=test-document" type="application/cmisacl+xml"/> </atom:entry> ���������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/create-document.xml����������������������������������������������0000664�0001750�0001750�00000015563�13407173247�017602� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:entry xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:published>2013-01-28T14:10:06Z</atom:published> <atom:title>create document</atom:title> <app:edited>2013-01-28T14:10:06Z</app:edited> <atom:updated>2013-01-28T14:10:06Z</atom:updated> <atom:content src="http://mockup/mock/content/data.txt?id=create-document" type="text/plain"/> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>12345</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>create document</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359382206736</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>create-document</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmisra:object> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/id?id=create-document" type="application/atom+xml;type=entry" cmisra:id="create-document"/> <atom:link rel="enclosure" href="http://mockup/mock/id?id=create-document" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/id?id=create-document" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=cmis:document" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=create-document" type="application/cmisallowableactions+xml"/> <atom:link rel="up" href="http://mockup/mock/parents?id=create-document" type="application/atom+xml;type=feed"/> <atom:link rel="edit-media" href="http://mockup/mock/content?id=create-document" type="text/plain"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=create-document" type="application/cmisacl+xml"/> </atom:entry> ���������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/typechildren-document.xml����������������������������������������0000664�0001750�0001750�00000007164�13407173247�021027� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:feed xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>http://mockup/mock/obscure id</atom:id> <atom:title>CMIS Document</atom:title> <app:edited>2013-01-25T10:05:56Z</app:edited> <atom:updated>2013-01-25T10:05:56Z</atom:updated> <cmisra:numItems>1</cmisra:numItems> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/types?typeId=cmis:document&includePropertyDefinitions=false" type="application/atom+xml;type=entry" cmisra:id="cmis:document"/> <atom:link rel="via" href="http://mockup/mock/type?id=cmis:document" type="application/atom+xml;type=entry"/> <atom:link rel="down" href="http://mockup/mock/typedesc?typeId=cmis:document" type="application/cmistree+xml"/> <atom:link rel="next" href="http://mockup/mock/types?typeId=cmis:document&includePropertyDefinitions=false&skipCount=100&maxItems=100" type="application/atom+xml;type=feed"/> <app:collection href="http://mockup/mock/types?typeId=cmis:document"> <atom:title type="text">Types Collection</atom:title> <app:accept/> </app:collection> <atom:entry> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>http://mockup/mock/obscure id</atom:id> <atom:title>Document Level 1</atom:title> <app:edited>2013-01-25T10:05:56Z</app:edited> <atom:updated>2013-01-25T10:05:56Z</atom:updated> <cmisra:type xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/" xsi:type="cmis:cmisTypeDocumentDefinitionType"> <cmis:id>DocumentLevel1</cmis:id> <cmis:localName>DocumentLevel1</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Document Level 1</cmis:displayName> <cmis:queryName>DocumentLevel1</cmis:queryName> <cmis:description>Description of Document Level 1 Type</cmis:description> <cmis:baseId>cmis:document</cmis:baseId> <cmis:parentId>cmis:document</cmis:parentId> <cmis:creatable>true</cmis:creatable> <cmis:fileable>true</cmis:fileable> <cmis:queryable>false</cmis:queryable> <cmis:fulltextIndexed>false</cmis:fulltextIndexed> <cmis:includedInSupertypeQuery>true</cmis:includedInSupertypeQuery> <cmis:controllablePolicy>false</cmis:controllablePolicy> <cmis:controllableACL>true</cmis:controllableACL> <cmis:versionable>false</cmis:versionable> <cmis:contentStreamAllowed>allowed</cmis:contentStreamAllowed> </cmisra:type> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/type?id=DocumentLevel1" type="application/atom+xml;type=entry" cmisra:id="DocumentLevel1"/> <atom:link rel="enclosure" href="http://mockup/mock/type?id=DocumentLevel1" type="application/atom+xml;type=entry"/> <atom:link rel="up" href="http://mockup/mock/type?id=cmis%3Adocument" type="application/atom+xml;type=entry"/> <atom:link rel="down" href="http://mockup/mock/types?typeId=DocumentLevel1" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/typedesc?typeId=DocumentLevel1" type="application/cmistree+xml"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=cmis%3Adocument" type="application/atom+xml;type=entry"/> </atom:entry> </atom:feed> ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/type-docLevel2.xml�����������������������������������������������0000664�0001750�0001750�00000102777�13407173247�017325� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:entry xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>http://mockup/mock/obscure id</atom:id> <atom:title>Document Level 2</atom:title> <app:edited>2013-01-25T09:46:50Z</app:edited> <atom:updated>2013-01-25T09:46:50Z</atom:updated> <cmisra:type xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/" xsi:type="cmis:cmisTypeDocumentDefinitionType"> <cmis:id>DocumentLevel2</cmis:id> <cmis:localName>DocumentLevel2</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Document Level 2</cmis:displayName> <cmis:queryName>DocumentLevel2</cmis:queryName> <cmis:description>Description of Document Level 2 Type</cmis:description> <cmis:baseId>cmis:document</cmis:baseId> <cmis:parentId>DocumentLevel1</cmis:parentId> <cmis:creatable>true</cmis:creatable> <cmis:fileable>true</cmis:fileable> <cmis:queryable>false</cmis:queryable> <cmis:fulltextIndexed>false</cmis:fulltextIndexed> <cmis:includedInSupertypeQuery>true</cmis:includedInSupertypeQuery> <cmis:controllablePolicy>false</cmis:controllablePolicy> <cmis:controllableACL>true</cmis:controllableACL> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isLatestMajorVersion</cmis:id> <cmis:localName>cmis:isLatestMajorVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Latest Major Version</cmis:displayName> <cmis:queryName>cmis:isLatestMajorVersion</cmis:queryName> <cmis:description>This is a Is Latest Major Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:contentStreamId</cmis:id> <cmis:localName>cmis:contentStreamId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Stream Id</cmis:displayName> <cmis:queryName>cmis:contentStreamId</cmis:queryName> <cmis:description>This is a Stream Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyIntegerDefinition> <cmis:id>cmis:contentStreamLength</cmis:id> <cmis:localName>cmis:contentStreamLength</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Content Length</cmis:displayName> <cmis:queryName>cmis:contentStreamLength</cmis:queryName> <cmis:description>This is a Content Length property.</cmis:description> <cmis:propertyType>integer</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIntegerDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:versionSeriesCheckedOutBy</cmis:id> <cmis:localName>cmis:versionSeriesCheckedOutBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out By</cmis:displayName> <cmis:queryName>cmis:versionSeriesCheckedOutBy</cmis:queryName> <cmis:description>This is a Checked Out By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectTypeId</cmis:id> <cmis:localName>cmis:objectTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Type-Id</cmis:displayName> <cmis:queryName>cmis:objectTypeId</cmis:queryName> <cmis:description>This is a Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>oncreate</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:versionSeriesCheckedOutId</cmis:id> <cmis:localName>cmis:versionSeriesCheckedOutId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out Id</cmis:displayName> <cmis:queryName>cmis:versionSeriesCheckedOutId</cmis:queryName> <cmis:description>This is a Checked Out Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:name</cmis:id> <cmis:localName>cmis:name</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Name</cmis:displayName> <cmis:queryName>cmis:name</cmis:queryName> <cmis:description>This is a Name property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:contentStreamMimeType</cmis:id> <cmis:localName>cmis:contentStreamMimeType</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Mime Type</cmis:displayName> <cmis:queryName>cmis:contentStreamMimeType</cmis:queryName> <cmis:description>This is a Mime Type property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:versionSeriesId</cmis:id> <cmis:localName>cmis:versionSeriesId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Version Series Id</cmis:displayName> <cmis:queryName>cmis:versionSeriesId</cmis:queryName> <cmis:description>This is a Version Series Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:creationDate</cmis:id> <cmis:localName>cmis:creationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Creation Date</cmis:displayName> <cmis:queryName>cmis:creationDate</cmis:queryName> <cmis:description>This is a Creation Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:changeToken</cmis:id> <cmis:localName>cmis:changeToken</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Change Token</cmis:displayName> <cmis:queryName>cmis:changeToken</cmis:queryName> <cmis:description>This is a Change Token property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:versionLabel</cmis:id> <cmis:localName>cmis:versionLabel</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Version Label</cmis:displayName> <cmis:queryName>cmis:versionLabel</cmis:queryName> <cmis:description>This is a Version Label property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isLatestVersion</cmis:id> <cmis:localName>cmis:isLatestVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Latest Version</cmis:displayName> <cmis:queryName>cmis:isLatestVersion</cmis:queryName> <cmis:description>This is a Is Latest Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isVersionSeriesCheckedOut</cmis:id> <cmis:localName>cmis:isVersionSeriesCheckedOut</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out</cmis:displayName> <cmis:queryName>cmis:isVersionSeriesCheckedOut</cmis:queryName> <cmis:description>This is a Checked Out property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:lastModifiedBy</cmis:id> <cmis:localName>cmis:lastModifiedBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modified By</cmis:displayName> <cmis:queryName>cmis:lastModifiedBy</cmis:queryName> <cmis:description>This is a Modified By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:createdBy</cmis:id> <cmis:localName>cmis:createdBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Created By</cmis:displayName> <cmis:queryName>cmis:createdBy</cmis:queryName> <cmis:description>This is a Created By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:checkinComment</cmis:id> <cmis:localName>cmis:checkinComment</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checkin Comment</cmis:displayName> <cmis:queryName>cmis:checkinComment</cmis:queryName> <cmis:description>This is a Checkin Comment property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectId</cmis:id> <cmis:localName>cmis:objectId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Object Id</cmis:displayName> <cmis:queryName>cmis:objectId</cmis:queryName> <cmis:description>This is a Object Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isImmutable</cmis:id> <cmis:localName>cmis:isImmutable</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Immutable</cmis:displayName> <cmis:queryName>cmis:isImmutable</cmis:queryName> <cmis:description>This is a Immutable property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isMajorVersion</cmis:id> <cmis:localName>cmis:isMajorVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Major Version</cmis:displayName> <cmis:queryName>cmis:isMajorVersion</cmis:queryName> <cmis:description>This is a Is Major Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:baseTypeId</cmis:id> <cmis:localName>cmis:baseTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Base-Type-Id</cmis:displayName> <cmis:queryName>cmis:baseTypeId</cmis:queryName> <cmis:description>This is a Base-Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:contentStreamFileName</cmis:id> <cmis:localName>cmis:contentStreamFileName</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>File Name</cmis:displayName> <cmis:queryName>cmis:contentStreamFileName</cmis:queryName> <cmis:description>This is a File Name property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:lastModificationDate</cmis:id> <cmis:localName>cmis:lastModificationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modification Date</cmis:displayName> <cmis:queryName>cmis:lastModificationDate</cmis:queryName> <cmis:description>This is a Modification Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyHtmlDefinition> <cmis:id>HtmlProp</cmis:id> <cmis:localName>HtmlProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Html Property</cmis:displayName> <cmis:queryName>HtmlProp</cmis:queryName> <cmis:description>This is a Sample Html Property property.</cmis:description> <cmis:propertyType>html</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyHtmlDefinition> <cmis:propertyIdDefinition> <cmis:id>IdProp</cmis:id> <cmis:localName>IdProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Id Property</cmis:displayName> <cmis:queryName>IdProp</cmis:queryName> <cmis:description>This is a Sample Id Property property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>DateTimePropMV</cmis:id> <cmis:localName>DateTimePropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample DateTime multi-value Property</cmis:displayName> <cmis:queryName>DateTimePropMV</cmis:queryName> <cmis:description>This is a Sample DateTime multi-value Property property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyUriDefinition> <cmis:id>UriProp</cmis:id> <cmis:localName>UriProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Uri Property</cmis:displayName> <cmis:queryName>UriProp</cmis:queryName> <cmis:description>This is a Sample Uri Property property.</cmis:description> <cmis:propertyType>uri</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyUriDefinition> <cmis:propertyDecimalDefinition> <cmis:id>DecimalProp</cmis:id> <cmis:localName>DecimalProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Decimal Property</cmis:displayName> <cmis:queryName>DecimalProp</cmis:queryName> <cmis:description>This is a Sample Decimal Property property.</cmis:description> <cmis:propertyType>decimal</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDecimalDefinition> <cmis:propertyUriDefinition> <cmis:id>UriPropMV</cmis:id> <cmis:localName>UriPropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Uri multi-value Property</cmis:displayName> <cmis:queryName>UriPropMV</cmis:queryName> <cmis:description>This is a Sample Uri multi-value Property property.</cmis:description> <cmis:propertyType>uri</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyUriDefinition> <cmis:propertyIdDefinition> <cmis:id>IdPropMV</cmis:id> <cmis:localName>IdPropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Id Html multi-value Property</cmis:displayName> <cmis:queryName>IdPropMV</cmis:queryName> <cmis:description>This is a Sample Id Html multi-value Property property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>PickListProp</cmis:id> <cmis:localName>PickListProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Pick List Property</cmis:displayName> <cmis:queryName>PickListProp</cmis:queryName> <cmis:description>This is a Sample Pick List Property property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> <cmis:defaultValue propertyDefinitionId="PickListProp"> <cmis:value>blue</cmis:value> </cmis:defaultValue> <cmis:choice displayName=""> <cmis:value>red</cmis:value> </cmis:choice> <cmis:choice displayName=""> <cmis:value>green</cmis:value> </cmis:choice> <cmis:choice displayName=""> <cmis:value>blue</cmis:value> </cmis:choice> <cmis:choice displayName=""> <cmis:value>black</cmis:value> </cmis:choice> </cmis:propertyStringDefinition> <cmis:propertyIntegerDefinition> <cmis:id>IntProp</cmis:id> <cmis:localName>IntProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Int Property</cmis:displayName> <cmis:queryName>IntProp</cmis:queryName> <cmis:description>This is a Sample Int Property property.</cmis:description> <cmis:propertyType>integer</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIntegerDefinition> <cmis:propertyHtmlDefinition> <cmis:id>HtmlPropMV</cmis:id> <cmis:localName>HtmlPropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Html multi-value Property</cmis:displayName> <cmis:queryName>HtmlPropMV</cmis:queryName> <cmis:description>This is a Sample Html multi-value Property property.</cmis:description> <cmis:propertyType>html</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyHtmlDefinition> <cmis:propertyStringDefinition> <cmis:id>StringProp</cmis:id> <cmis:localName>StringProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample String Property</cmis:displayName> <cmis:queryName>StringProp</cmis:queryName> <cmis:description>This is a Sample String Property property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyDecimalDefinition> <cmis:id>DecimalPropMV</cmis:id> <cmis:localName>DecimalPropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Decimal multi-value Property</cmis:displayName> <cmis:queryName>DecimalPropMV</cmis:queryName> <cmis:description>This is a Sample Decimal multi-value Property property.</cmis:description> <cmis:propertyType>decimal</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDecimalDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>DateTimeProp</cmis:id> <cmis:localName>DateTimeProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample DateTime Property</cmis:displayName> <cmis:queryName>DateTimeProp</cmis:queryName> <cmis:description>This is a Sample DateTime Property property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyBooleanDefinition> <cmis:id>BooleanProp</cmis:id> <cmis:localName>BooleanProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Boolean Property</cmis:displayName> <cmis:queryName>BooleanProp</cmis:queryName> <cmis:description>This is a Sample Boolean Property property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyBooleanDefinition> <cmis:id>BooleanPropMV</cmis:id> <cmis:localName>BooleanPropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Boolean multi-value Property</cmis:displayName> <cmis:queryName>BooleanPropMV</cmis:queryName> <cmis:description>This is a Sample Boolean multi-value Property property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIntegerDefinition> <cmis:id>IntPropMV</cmis:id> <cmis:localName>IntPropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Int multi-value Property</cmis:displayName> <cmis:queryName>IntPropMV</cmis:queryName> <cmis:description>This is a Sample Int multi-value Property property.</cmis:description> <cmis:propertyType>integer</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIntegerDefinition> <cmis:versionable>false</cmis:versionable> <cmis:contentStreamAllowed>allowed</cmis:contentStreamAllowed> </cmisra:type> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/type?id=DocumentLevel2" type="application/atom+xml;type=entry" cmisra:id="DocumentLevel2"/> <atom:link rel="enclosure" href="http://mockup/mock/type?id=DocumentLevel2" type="application/atom+xml;type=entry"/> <atom:link rel="up" href="http://mockup/mock/type?id=DocumentLevel1" type="application/atom+xml;type=entry"/> <atom:link rel="down" href="http://mockup/mock/types?typeId=DocumentLevel2" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/typedesc?typeId=DocumentLevel2" type="application/cmistree+xml"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=cmis:document" type="application/atom+xml;type=entry"/> </atom:entry> �libcmis-0.5.2/qa/libcmis/data/atom/root-children.xml������������������������������������������������0000664�0001750�0001750�00000076044�13407173247�017275� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:feed xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>Admin</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:title>Root Folder</atom:title> <app:edited>2013-01-30T09:26:10Z</app:edited> <atom:updated>2013-01-30T09:26:10Z</atom:updated> <cmisra:numItems>5</cmisra:numItems> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/children?id=root-folder" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=cmis:folder" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=root-folder" type="application/cmisallowableactions+xml"/> <atom:link rel="down" href="http://mockup/mock/children?id=root-folder" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/descendants?id=root-folder" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/foldertree" href="http://mockup/mock/foldertree?id=root-folder" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=root-folder" type="application/cmisacl+xml"/> <app:collection href="http://mockup/mock/children?id=root-folder"> <atom:title type="text">Folder collection</atom:title> <app:accept>application/cmisatom+xml</app:accept> </app:collection> <atom:entry> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:published>2013-01-30T09:26:13Z</atom:published> <atom:title>Child 1</atom:title> <app:edited>2013-01-30T09:26:13Z</app:edited> <atom:updated>2013-01-30T09:26:13Z</atom:updated> <atom:content src="http://mockup/mock/content/data.txt?id=child1" type="text/plain"/> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>33446</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyDateTime queryName="DateTimePropMV" displayName="Sample DateTime multi-value Property" localName="DateTimePropMV" propertyDefinitionId="DateTimePropMV"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Child 1</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-30T09:26:13.932Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359537973932</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>child1</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-30T09:26:13.932Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmisra:object> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/entry?id=child1" type="application/atom+xml;type=entry" cmisra:id="child1"/> <atom:link rel="enclosure" href="http://mockup/mock/entry?id=child1" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/entry?id=child1" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=DocumentLevel2" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=child1" type="application/cmisallowableactions+xml"/> <atom:link rel="up" href="http://mockup/mock/parents?id=child1" type="application/atom+xml;type=feed"/> <atom:link rel="edit-media" href="http://mockup/mock/content?id=child1" type="text/plain"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=child1" type="application/cmisacl+xml"/> </atom:entry> <atom:entry> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:published>2013-01-30T09:26:13Z</atom:published> <atom:title>Child 2</atom:title> <app:edited>2013-01-30T09:26:13Z</app:edited> <atom:updated>2013-01-30T09:26:13Z</atom:updated> <atom:content src="http://mockup/mock/content/data.txt?id=child2" type="text/plain"/> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>33537</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Child 2</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-30T09:26:13.978Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359537973978</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>child2</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-30T09:26:13.978Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmisra:object> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/entry?id=child2" type="application/atom+xml;type=entry" cmisra:id="child2"/> <atom:link rel="enclosure" href="http://mockup/mock/entry?id=child2" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/entry?id=child2" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=DocumentLevel2" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=child2" type="application/cmisallowableactions+xml"/> <atom:link rel="up" href="http://mockup/mock/parents?id=child2" type="application/atom+xml;type=feed"/> <atom:link rel="edit-media" href="http://mockup/mock/content?id=child2" type="text/plain"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=child2" type="application/cmisacl+xml"/> </atom:entry> <atom:entry> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:published>2013-01-30T09:26:14Z</atom:published> <atom:title>Child 3</atom:title> <app:edited>2013-01-30T09:26:14Z</app:edited> <atom:updated>2013-01-30T09:26:14Z</atom:updated> <atom:content src="http://mockup/mock/content/data.txt?id=child3" type="text/plain"/> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>33353</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Child 3</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-30T09:26:14.031Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359537974031</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>child3</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-30T09:26:14.031Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmisra:object> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/entry?id=child3" type="application/atom+xml;type=entry" cmisra:id="child3"/> <atom:link rel="enclosure" href="http://mockup/mock/entry?id=child3" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/entry?id=child3" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=DocumentLevel2" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=child3" type="application/cmisallowableactions+xml"/> <atom:link rel="up" href="http://mockup/mock/parents?id=child3" type="application/atom+xml;type=feed"/> <atom:link rel="edit-media" href="http://mockup/mock/content?id=child3" type="text/plain"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=child3" type="application/cmisacl+xml"/> </atom:entry> <atom:entry> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:published>2013-01-30T09:26:12Z</atom:published> <atom:title>Child 4</atom:title> <app:edited>2013-01-30T09:26:12Z</app:edited> <atom:updated>2013-01-30T09:26:12Z</atom:updated> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyId queryName="cmis:allowedChildObjectTypeIds" displayName="Allowed Child Types" localName="cmis:allowedChildObjectTypeIds" propertyDefinitionId="cmis:allowedChildObjectTypeIds"> <cmis:value>*</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:path" displayName="Path" localName="cmis:path" propertyDefinitionId="cmis:path"> <cmis:value>/Child 4</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Child 4</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>child4</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-30T09:26:12.384Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359537972384</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyId queryName="cmis:parentId" displayName="Parent Id" localName="cmis:parentId" propertyDefinitionId="cmis:parentId"> <cmis:value>root-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-30T09:26:12.384Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmisra:object> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/entry?id=child4" type="application/atom+xml;type=entry" cmisra:id="child4"/> <atom:link rel="enclosure" href="http://mockup/mock/entry?id=child4" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/entry?id=child4" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=cmis:folder" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=child4" type="application/cmisallowableactions+xml"/> <atom:link rel="up" href="http://mockup/mock/parents?id=child4" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/children?id=child4" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/descendants?id=child4" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/foldertree" href="http://mockup/mock/foldertree?id=child4" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=child4" type="application/cmisacl+xml"/> </atom:entry> <atom:entry> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:published>2013-01-30T09:26:13Z</atom:published> <atom:title>Child 5</atom:title> <app:edited>2013-01-30T09:26:13Z</app:edited> <atom:updated>2013-01-30T09:26:13Z</atom:updated> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyId queryName="cmis:allowedChildObjectTypeIds" displayName="Allowed Child Types" localName="cmis:allowedChildObjectTypeIds" propertyDefinitionId="cmis:allowedChildObjectTypeIds"> <cmis:value>*</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:path" displayName="Path" localName="cmis:path" propertyDefinitionId="cmis:path"> <cmis:value>/Child 5</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Child 5</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>child5</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-30T09:26:13.338Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359537973338</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyId queryName="cmis:parentId" displayName="Parent Id" localName="cmis:parentId" propertyDefinitionId="cmis:parentId"> <cmis:value>root-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-30T09:26:13.338Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmisra:object> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/entry?id=child5" type="application/atom+xml;type=entry" cmisra:id="child5"/> <atom:link rel="enclosure" href="http://mockup/mock/entry?id=child5" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/entry?id=child5" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=cmis:folder" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=child5" type="application/cmisallowableactions+xml"/> <atom:link rel="up" href="http://mockup/mock/parents?id=child5" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/children?id=child5" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/descendants?id=child5" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/foldertree" href="http://mockup/mock/foldertree?id=child5" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=child5" type="application/cmisacl+xml"/> </atom:entry> </atom:feed> ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/test-document-parents.xml����������������������������������������0000664�0001750�0001750�00000023316�13407173247�020763� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:feed xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>Some Obscure Id</atom:id> <atom:title>Test Document</atom:title> <app:edited>2013-01-31T08:04:37Z</app:edited> <atom:updated>2013-01-31T08:04:37Z</atom:updated> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/parents?id=test-document" type="application/atom+xml;type=entry"/> <atom:entry> <atom:author> <atom:name>Admin</atom:name> </atom:author> <atom:id>Some Obscure Id</atom:id> <atom:published>2013-01-31T08:04:35Z</atom:published> <atom:title>Parent 1</atom:title> <app:edited>2013-01-31T08:04:35Z</app:edited> <atom:updated>2013-01-31T08:04:35Z</atom:updated> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyId queryName="cmis:allowedChildObjectTypeIds" displayName="Allowed Child Types" localName="cmis:allowedChildObjectTypeIds" propertyDefinitionId="cmis:allowedChildObjectTypeIds"> <cmis:value>*</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:path" displayName="Path" localName="cmis:path" propertyDefinitionId="cmis:path"> <cmis:value>/Parent 1</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Parent 1</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>parent1</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-31T08:04:35.866Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359619475867</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyId queryName="cmis:parentId" displayName="Parent Id" localName="cmis:parentId" propertyDefinitionId="cmis:parentId"> <cmis:value>root-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-31T08:04:35.867Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmisra:object> <cmisra:relativePathSegment>Test Document</cmisra:relativePathSegment> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/entry?id=parent1" type="application/atom+xml;type=entry" cmisra:id="parent1"/> <atom:link rel="enclosure" href="http://mockup/mock/entry?id=parent1" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/entry?id=parent1" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=cmis:folder" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=parent1" type="application/cmisallowableactions+xml"/> <atom:link rel="down" href="http://mockup/mock/children?id=parent1" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/descendants?id=parent1" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/foldertree" href="http://mockup/mock/foldertree?id=parent1" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=parent1" type="application/cmisacl+xml"/> </atom:entry> <atom:entry> <atom:author> <atom:name>Admin</atom:name> </atom:author> <atom:id>Some Obscure Id</atom:id> <atom:published>2013-01-31T08:04:35Z</atom:published> <atom:title>Parent 2</atom:title> <app:edited>2013-01-31T08:04:35Z</app:edited> <atom:updated>2013-01-31T08:04:35Z</atom:updated> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyId queryName="cmis:allowedChildObjectTypeIds" displayName="Allowed Child Types" localName="cmis:allowedChildObjectTypeIds" propertyDefinitionId="cmis:allowedChildObjectTypeIds"> <cmis:value>*</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:path" displayName="Path" localName="cmis:path" propertyDefinitionId="cmis:path"> <cmis:value>/Parent 2</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Parent 2</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>parent2</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-31T08:04:35.866Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359619475867</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyId queryName="cmis:parentId" displayName="Parent Id" localName="cmis:parentId" propertyDefinitionId="cmis:parentId"> <cmis:value>root-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-31T08:04:35.867Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmisra:object> <cmisra:relativePathSegment>Test Document</cmisra:relativePathSegment> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/entry?id=parent2" type="application/atom+xml;type=entry" cmisra:id="parent2"/> <atom:link rel="enclosure" href="http://mockup/mock/entry?id=parent2" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/entry?id=parent2" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=cmis:folder" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=parent2" type="application/cmisallowableactions+xml"/> <atom:link rel="down" href="http://mockup/mock/children?id=parent2" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/descendants?id=parent2" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/foldertree" href="http://mockup/mock/foldertree?id=parent2" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=parent2" type="application/cmisacl+xml"/> </atom:entry> </atom:feed> ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/valid-object.xml�������������������������������������������������0000664�0001750�0001750�00000015406�13407173247�017062� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:entry xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>Admin</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:published>2012-11-29T16:14:47Z</atom:published> <atom:title>Valid Object</atom:title> <app:edited>2012-11-29T16:14:47Z</app:edited> <atom:updated>2012-11-29T16:14:47Z</atom:updated> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyId queryName="cmis:allowedChildObjectTypeIds" displayName="Allowed Child Types" localName="cmis:allowedChildObjectTypeIds" propertyDefinitionId="cmis:allowedChildObjectTypeIds"> <cmis:value>*</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:path" displayName="Path" localName="cmis:path" propertyDefinitionId="cmis:path"> <cmis:value>/Valid Object</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Valid Object</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>valid-object</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2012-11-29T16:14:47.019Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1354205687020</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyId queryName="cmis:parentId" displayName="Parent Id" localName="cmis:parentId" propertyDefinitionId="cmis:parentId"> <cmis:value>root-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2012-11-29T16:14:47.020Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> <cmis:allowableActions> <cmis:canDeleteObject>true</cmis:canDeleteObject> <cmis:canUpdateProperties>true</cmis:canUpdateProperties> <cmis:canGetFolderTree>true</cmis:canGetFolderTree> <cmis:canGetProperties>true</cmis:canGetProperties> <cmis:canGetObjectRelationships>false</cmis:canGetObjectRelationships> <cmis:canGetObjectParents>true</cmis:canGetObjectParents> <cmis:canGetFolderParent>true</cmis:canGetFolderParent> <cmis:canGetDescendants>true</cmis:canGetDescendants> <cmis:canMoveObject>true</cmis:canMoveObject> <cmis:canDeleteContentStream>false</cmis:canDeleteContentStream> <cmis:canCheckOut>false</cmis:canCheckOut> <cmis:canCancelCheckOut>false</cmis:canCancelCheckOut> <cmis:canCheckIn>false</cmis:canCheckIn> <cmis:canSetContentStream>false</cmis:canSetContentStream> <cmis:canGetAllVersions>false</cmis:canGetAllVersions> <cmis:canAddObjectToFolder>false</cmis:canAddObjectToFolder> <cmis:canRemoveObjectFromFolder>false</cmis:canRemoveObjectFromFolder> <cmis:canGetContentStream>false</cmis:canGetContentStream> <cmis:canApplyPolicy>false</cmis:canApplyPolicy> <cmis:canGetAppliedPolicies>false</cmis:canGetAppliedPolicies> <cmis:canRemovePolicy>false</cmis:canRemovePolicy> <cmis:canGetChildren>true</cmis:canGetChildren> <cmis:canCreateDocument>true</cmis:canCreateDocument> <cmis:canCreateFolder>true</cmis:canCreateFolder> <cmis:canCreateRelationship>false</cmis:canCreateRelationship> <cmis:canDeleteTree>true</cmis:canDeleteTree> <cmis:canGetRenditions>false</cmis:canGetRenditions> <cmis:canGetACL>false</cmis:canGetACL> <cmis:canApplyACL>false</cmis:canApplyACL> </cmis:allowableActions> <exampleExtension:exampleExtension xmlns="http://my/cmis/extension" xmlns:exampleExtension="http://my/cmis/extension"> <objectId xmlns:ns0="http://my/cmis/extension" ns0:type="cmis:folder">valid-object</objectId> <name>Valid Object</name> </exampleExtension:exampleExtension> </cmisra:object> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/id?id=valid-object" type="application/atom+xml;type=entry" cmisra:id="valid-object"/> <atom:link rel="enclosure" href="http://mockup/mock/id?id=valid-object" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/id?id=valid-object" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=cmis%3Afolder" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=valid-object" type="application/cmisallowableactions+xml"/> <atom:link rel="up" href="http://mockup/mock/parents?id=valid-object" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/children?id=valid-object" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/descendants?id=valid-object" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/foldertree" href="http://mockup/mock/foldertree?id=valid-object" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=valid-object" type="application/cmisacl+xml"/> </atom:entry> ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/type-document.xml������������������������������������������������0000664�0001750�0001750�00000050462�13407173247�017315� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:entry xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>http://mockup/mock/obscure id</atom:id> <atom:title>CMIS Document</atom:title> <app:edited>2013-01-25T09:47:55Z</app:edited> <atom:updated>2013-01-25T09:47:55Z</atom:updated> <cmisra:type xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/" xsi:type="cmis:cmisTypeDocumentDefinitionType"> <cmis:id>cmis:document</cmis:id> <cmis:localName>cmis:document</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>CMIS Document</cmis:displayName> <cmis:queryName>cmis:document</cmis:queryName> <cmis:description>Description of CMIS Document Type</cmis:description> <cmis:baseId>cmis:document</cmis:baseId> <cmis:creatable>true</cmis:creatable> <cmis:fileable>true</cmis:fileable> <cmis:queryable>false</cmis:queryable> <cmis:fulltextIndexed>false</cmis:fulltextIndexed> <cmis:includedInSupertypeQuery>true</cmis:includedInSupertypeQuery> <cmis:controllablePolicy>false</cmis:controllablePolicy> <cmis:controllableACL>true</cmis:controllableACL> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isLatestMajorVersion</cmis:id> <cmis:localName>cmis:isLatestMajorVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Latest Major Version</cmis:displayName> <cmis:queryName>cmis:isLatestMajorVersion</cmis:queryName> <cmis:description>This is a Is Latest Major Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:contentStreamId</cmis:id> <cmis:localName>cmis:contentStreamId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Stream Id</cmis:displayName> <cmis:queryName>cmis:contentStreamId</cmis:queryName> <cmis:description>This is a Stream Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyIntegerDefinition> <cmis:id>cmis:contentStreamLength</cmis:id> <cmis:localName>cmis:contentStreamLength</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Content Length</cmis:displayName> <cmis:queryName>cmis:contentStreamLength</cmis:queryName> <cmis:description>This is a Content Length property.</cmis:description> <cmis:propertyType>integer</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIntegerDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:versionSeriesCheckedOutBy</cmis:id> <cmis:localName>cmis:versionSeriesCheckedOutBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out By</cmis:displayName> <cmis:queryName>cmis:versionSeriesCheckedOutBy</cmis:queryName> <cmis:description>This is a Checked Out By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectTypeId</cmis:id> <cmis:localName>cmis:objectTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Type-Id</cmis:displayName> <cmis:queryName>cmis:objectTypeId</cmis:queryName> <cmis:description>This is a Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>oncreate</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:versionSeriesCheckedOutId</cmis:id> <cmis:localName>cmis:versionSeriesCheckedOutId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out Id</cmis:displayName> <cmis:queryName>cmis:versionSeriesCheckedOutId</cmis:queryName> <cmis:description>This is a Checked Out Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:name</cmis:id> <cmis:localName>cmis:name</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Name</cmis:displayName> <cmis:queryName>cmis:name</cmis:queryName> <cmis:description>This is a Name property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:contentStreamMimeType</cmis:id> <cmis:localName>cmis:contentStreamMimeType</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Mime Type</cmis:displayName> <cmis:queryName>cmis:contentStreamMimeType</cmis:queryName> <cmis:description>This is a Mime Type property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:versionSeriesId</cmis:id> <cmis:localName>cmis:versionSeriesId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Version Series Id</cmis:displayName> <cmis:queryName>cmis:versionSeriesId</cmis:queryName> <cmis:description>This is a Version Series Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:creationDate</cmis:id> <cmis:localName>cmis:creationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Creation Date</cmis:displayName> <cmis:queryName>cmis:creationDate</cmis:queryName> <cmis:description>This is a Creation Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:changeToken</cmis:id> <cmis:localName>cmis:changeToken</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Change Token</cmis:displayName> <cmis:queryName>cmis:changeToken</cmis:queryName> <cmis:description>This is a Change Token property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:versionLabel</cmis:id> <cmis:localName>cmis:versionLabel</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Version Label</cmis:displayName> <cmis:queryName>cmis:versionLabel</cmis:queryName> <cmis:description>This is a Version Label property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isLatestVersion</cmis:id> <cmis:localName>cmis:isLatestVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Latest Version</cmis:displayName> <cmis:queryName>cmis:isLatestVersion</cmis:queryName> <cmis:description>This is a Is Latest Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isVersionSeriesCheckedOut</cmis:id> <cmis:localName>cmis:isVersionSeriesCheckedOut</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out</cmis:displayName> <cmis:queryName>cmis:isVersionSeriesCheckedOut</cmis:queryName> <cmis:description>This is a Checked Out property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:lastModifiedBy</cmis:id> <cmis:localName>cmis:lastModifiedBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modified By</cmis:displayName> <cmis:queryName>cmis:lastModifiedBy</cmis:queryName> <cmis:description>This is a Modified By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:createdBy</cmis:id> <cmis:localName>cmis:createdBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Created By</cmis:displayName> <cmis:queryName>cmis:createdBy</cmis:queryName> <cmis:description>This is a Created By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:checkinComment</cmis:id> <cmis:localName>cmis:checkinComment</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checkin Comment</cmis:displayName> <cmis:queryName>cmis:checkinComment</cmis:queryName> <cmis:description>This is a Checkin Comment property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectId</cmis:id> <cmis:localName>cmis:objectId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Object Id</cmis:displayName> <cmis:queryName>cmis:objectId</cmis:queryName> <cmis:description>This is a Object Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isImmutable</cmis:id> <cmis:localName>cmis:isImmutable</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Immutable</cmis:displayName> <cmis:queryName>cmis:isImmutable</cmis:queryName> <cmis:description>This is a Immutable property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isMajorVersion</cmis:id> <cmis:localName>cmis:isMajorVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Major Version</cmis:displayName> <cmis:queryName>cmis:isMajorVersion</cmis:queryName> <cmis:description>This is a Is Major Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:baseTypeId</cmis:id> <cmis:localName>cmis:baseTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Base-Type-Id</cmis:displayName> <cmis:queryName>cmis:baseTypeId</cmis:queryName> <cmis:description>This is a Base-Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:contentStreamFileName</cmis:id> <cmis:localName>cmis:contentStreamFileName</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>File Name</cmis:displayName> <cmis:queryName>cmis:contentStreamFileName</cmis:queryName> <cmis:description>This is a File Name property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:lastModificationDate</cmis:id> <cmis:localName>cmis:lastModificationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modification Date</cmis:displayName> <cmis:queryName>cmis:lastModificationDate</cmis:queryName> <cmis:description>This is a Modification Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:versionable>false</cmis:versionable> <cmis:contentStreamAllowed>allowed</cmis:contentStreamAllowed> </cmisra:type> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/type?id=cmis:document" type="application/atom+xml;type=entry" cmisra:id="cmis:document"/> <atom:link rel="enclosure" href="http://mockup/mock/type?id=cmis:document" type="application/atom+xml;type=entry"/> <atom:link rel="down" href="http://mockup/mock/types?typeId=cmis:document" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/typedesc?typeId=cmis:document" type="application/cmistree+xml"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=cmis:document" type="application/atom+xml;type=entry"/> </atom:entry> ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/root-folder.xml��������������������������������������������������0000664�0001750�0001750�00000014421�13407173247�016747� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:entry xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>Admin</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:published>2012-11-29T16:14:47Z</atom:published> <atom:title>Root Folder</atom:title> <app:edited>2012-11-29T16:14:47Z</app:edited> <atom:updated>2012-11-29T16:14:47Z</atom:updated> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyId queryName="cmis:allowedChildObjectTypeIds" displayName="Allowed Child Types" localName="cmis:allowedChildObjectTypeIds" propertyDefinitionId="cmis:allowedChildObjectTypeIds"> <cmis:value>*</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:path" displayName="Path" localName="cmis:path" propertyDefinitionId="cmis:path"> <cmis:value>/</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Root Folder</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>root-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2012-11-29T16:14:47.019Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1354205687020</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyId queryName="cmis:parentId" displayName="Parent Id" localName="cmis:parentId" propertyDefinitionId="cmis:parentId"/> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2012-11-29T16:14:47.020Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> <cmis:allowableActions> <cmis:canDeleteObject>true</cmis:canDeleteObject> <cmis:canUpdateProperties>true</cmis:canUpdateProperties> <cmis:canGetFolderTree>true</cmis:canGetFolderTree> <cmis:canGetProperties>true</cmis:canGetProperties> <cmis:canGetObjectRelationships>false</cmis:canGetObjectRelationships> <cmis:canGetObjectParents>true</cmis:canGetObjectParents> <cmis:canGetFolderParent>true</cmis:canGetFolderParent> <cmis:canGetDescendants>true</cmis:canGetDescendants> <cmis:canMoveObject>true</cmis:canMoveObject> <cmis:canDeleteContentStream>false</cmis:canDeleteContentStream> <cmis:canCheckOut>false</cmis:canCheckOut> <cmis:canCancelCheckOut>false</cmis:canCancelCheckOut> <cmis:canCheckIn>false</cmis:canCheckIn> <cmis:canSetContentStream>false</cmis:canSetContentStream> <cmis:canGetAllVersions>false</cmis:canGetAllVersions> <cmis:canAddObjectToFolder>false</cmis:canAddObjectToFolder> <cmis:canRemoveObjectFromFolder>false</cmis:canRemoveObjectFromFolder> <cmis:canGetContentStream>false</cmis:canGetContentStream> <cmis:canApplyPolicy>false</cmis:canApplyPolicy> <cmis:canGetAppliedPolicies>false</cmis:canGetAppliedPolicies> <cmis:canRemovePolicy>false</cmis:canRemovePolicy> <cmis:canGetChildren>true</cmis:canGetChildren> <cmis:canCreateDocument>true</cmis:canCreateDocument> <cmis:canCreateFolder>true</cmis:canCreateFolder> <cmis:canCreateRelationship>false</cmis:canCreateRelationship> <cmis:canDeleteTree>true</cmis:canDeleteTree> <cmis:canGetRenditions>false</cmis:canGetRenditions> <cmis:canGetACL>false</cmis:canGetACL> <cmis:canApplyACL>false</cmis:canApplyACL> </cmis:allowableActions> </cmisra:object> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/id?id=root-folder" type="application/atom+xml;type=entry" cmisra:id="root-folder"/> <atom:link rel="enclosure" href="http://mockup/mock/id?id=root-folder" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/id?id=root-folder" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=cmis%3Afolder" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=root-folder" type="application/cmisallowableactions+xml"/> <atom:link rel="down" href="http://mockup/mock/children?id=root-folder" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/descendants?id=root-folder" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/foldertree" href="http://mockup/mock/foldertree?id=root-folder" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=root-folder" type="application/cmisacl+xml"/> </atom:entry> �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/test-document.xml������������������������������������������������0000664�0001750�0001750�00000030764�13407173247�017316� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:entry xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:published>2013-01-28T14:10:06Z</atom:published> <atom:title>Test Document</atom:title> <app:edited>2013-01-28T14:10:06Z</app:edited> <atom:updated>2013-01-28T14:10:06Z</atom:updated> <atom:content src="http://mockup/mock/content/data.txt?id=test-document" type="text/plain"/> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>12345</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyHtml queryName="HtmlProp" displayName="Sample Html Property" localName="HtmlProp" propertyDefinitionId="HtmlProp"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyId queryName="IdProp" displayName="Sample Id Property" localName="IdProp" propertyDefinitionId="IdProp"/> <cmis:propertyUri queryName="UriProp" displayName="Sample Uri Property" localName="UriProp" propertyDefinitionId="UriProp"/> <cmis:propertyDateTime queryName="DateTimePropMV" displayName="Sample DateTime multi-value Property" localName="DateTimePropMV" propertyDefinitionId="DateTimePropMV"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"/> <cmis:propertyDecimal queryName="DecimalProp" displayName="Sample Decimal Property" localName="DecimalProp" propertyDefinitionId="DecimalProp"/> <cmis:propertyUri queryName="UriPropMV" displayName="Sample Uri multi-value Property" localName="UriPropMV" propertyDefinitionId="UriPropMV"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"/> <cmis:propertyBoolean queryName="BooleanProp" displayName="Sample Boolean Property" localName="BooleanProp" propertyDefinitionId="BooleanProp"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="IdPropMV" displayName="Sample Id Html multi-value Property" localName="IdPropMV" propertyDefinitionId="IdPropMV"/> <cmis:propertyString queryName="PickListProp" displayName="Sample Pick List Property" localName="PickListProp" propertyDefinitionId="PickListProp"> <cmis:value>blue</cmis:value> </cmis:propertyString> <cmis:propertyHtml queryName="HtmlPropMV" displayName="Sample Html multi-value Property" localName="HtmlPropMV" propertyDefinitionId="HtmlPropMV"/> <cmis:propertyInteger queryName="IntProp" displayName="Sample Int Property" localName="IntProp" propertyDefinitionId="IntProp"/> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Test Document</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="StringProp" displayName="Sample String Property" localName="StringProp" propertyDefinitionId="StringProp"> <cmis:value>My Doc StringProperty 6</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359382206736</cmis:value> </cmis:propertyString> <cmis:propertyDecimal queryName="DecimalPropMV" displayName="Sample Decimal multi-value Property" localName="DecimalPropMV" propertyDefinitionId="DecimalPropMV"/> <cmis:propertyDateTime queryName="DateTimeProp" displayName="Sample DateTime Property" localName="DateTimeProp" propertyDefinitionId="DateTimeProp"/> <cmis:propertyBoolean queryName="BooleanPropMV" displayName="Sample Boolean multi-value Property" localName="BooleanPropMV" propertyDefinitionId="BooleanPropMV"/> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>test-document</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyInteger queryName="IntPropMV" displayName="Sample Int multi-value Property" localName="IntPropMV" propertyDefinitionId="IntPropMV"/> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> <cmis:allowableActions> <cmis:canDeleteObject>true</cmis:canDeleteObject> <cmis:canUpdateProperties>true</cmis:canUpdateProperties> <cmis:canGetFolderTree>false</cmis:canGetFolderTree> <cmis:canGetProperties>true</cmis:canGetProperties> <cmis:canGetObjectRelationships>false</cmis:canGetObjectRelationships> <cmis:canGetObjectParents>true</cmis:canGetObjectParents> <cmis:canGetFolderParent>false</cmis:canGetFolderParent> <cmis:canGetDescendants>false</cmis:canGetDescendants> <cmis:canMoveObject>true</cmis:canMoveObject> <cmis:canDeleteContentStream>true</cmis:canDeleteContentStream> <cmis:canCheckOut>true</cmis:canCheckOut> <cmis:canCancelCheckOut>false</cmis:canCancelCheckOut> <cmis:canCheckIn>false</cmis:canCheckIn> <cmis:canSetContentStream>true</cmis:canSetContentStream> <cmis:canGetAllVersions>true</cmis:canGetAllVersions> <cmis:canAddObjectToFolder>true</cmis:canAddObjectToFolder> <cmis:canRemoveObjectFromFolder>true</cmis:canRemoveObjectFromFolder> <cmis:canGetContentStream>true</cmis:canGetContentStream> <cmis:canApplyPolicy>false</cmis:canApplyPolicy> <cmis:canGetAppliedPolicies>false</cmis:canGetAppliedPolicies> <cmis:canRemovePolicy>false</cmis:canRemovePolicy> <cmis:canGetChildren>false</cmis:canGetChildren> <cmis:canCreateDocument>false</cmis:canCreateDocument> <cmis:canCreateFolder>false</cmis:canCreateFolder> <cmis:canCreateRelationship>false</cmis:canCreateRelationship> <cmis:canDeleteTree>false</cmis:canDeleteTree> <cmis:canGetRenditions>false</cmis:canGetRenditions> <cmis:canGetACL>false</cmis:canGetACL> <cmis:canApplyACL>false</cmis:canApplyACL> </cmis:allowableActions> <exampleExtension:exampleExtension xmlns="http://mockup/cmis/extension" xmlns:exampleExtension="http://mockup/cmis/extension"> <objectId xmlns:ns0="http://mockup/cmis/extension" ns0:type="DocumentLevel2">test-document</objectId> <name>Test Document</name> </exampleExtension:exampleExtension> <cmis:rendition> <cmis:streamId>http://mockup/mock/renditions?id=test-document-rendition1</cmis:streamId> <cmis:mimetype>image/png</cmis:mimetype> <cmis:length>40385</cmis:length> <cmis:kind>cmis:thumbnail</cmis:kind> <cmis:title>picture</cmis:title> <cmis:height>100</cmis:height> <cmis:width>100</cmis:width> </cmis:rendition> <cmis:rendition> <cmis:streamId>http://mockup/mock/renditions?id=test-document-rendition2</cmis:streamId> <cmis:mimetype>application/pdf</cmis:mimetype> <cmis:kind>pdf</cmis:kind> <cmis:title>Doc as PDF</cmis:title> </cmis:rendition> </cmisra:object> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/id?id=test-document" type="application/atom+xml;type=entry" cmisra:id="test-document"/> <atom:link rel="enclosure" href="http://mockup/mock/id?id=test-document" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/id?id=test-document" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=DocumentLevel2" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=test-document" type="application/cmisallowableactions+xml"/> <atom:link rel="up" href="http://mockup/mock/parents?id=test-document" type="application/atom+xml;type=feed"/> <atom:link rel="edit-media" href="http://mockup/mock/content?id=test-document" type="text/plain"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=test-document" type="application/cmisacl+xml"/> <atom:link rel="version-history" href="http://mockup/mock/versions?id=test-document" type="application/atom+xml;type=feed"/> <atom:link rel="alternate" href="http://mockup/mock/renditions?id=test-document-rendition1" type="image/png" cmisra:renditionKind="cmis:thumbnail" title="picture" length="40385"/> <atom:link rel="alternate" href="http://mockup/mock/renditions?id=test-document-rendition2" type="application/pdf" cmisra:renditionKind="pdf" title="Doc as PDF"/> </atom:entry> ������������libcmis-0.5.2/qa/libcmis/data/atom/workspaces.xml���������������������������������������������������0000664�0001750�0001750�00000026726�13407173247�016707� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <app:service xmlns:app="http://www.w3.org/2007/app" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/"> <app:workspace> <atom:title>Mockup</atom:title> <app:collection href="http://mockup/mock/children?id=root"> <cmisra:collectionType>root</cmisra:collectionType> <atom:title type="text">Root Collection</atom:title> <app:accept>application/atom+xml;type=entry</app:accept> <app:accept>application/cmisatom+xml</app:accept> </app:collection> <app:collection href="http://mockup/mock/types"> <cmisra:collectionType>types</cmisra:collectionType> <atom:title type="text">Types Collection</atom:title> <app:accept/> </app:collection> <app:collection href="http://mockup/mock/query"> <cmisra:collectionType>query</cmisra:collectionType> <atom:title type="text">Query Collection</atom:title> <app:accept>application/cmisquery+xml</app:accept> </app:collection> <app:collection href="http://mockup/mock/checkedout"> <cmisra:collectionType>checkedout</cmisra:collectionType> <atom:title type="text">Checked Out Collection</atom:title> <app:accept>application/cmisatom+xml</app:accept> </app:collection> <app:collection href="http://mockup/mock/unfiled"> <cmisra:collectionType>unfiled</cmisra:collectionType> <atom:title type="text">Unfiled Collection</atom:title> <app:accept>application/cmisatom+xml</app:accept> </app:collection> <cmisra:repositoryInfo xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:repositoryId>mock</cmis:repositoryId> <cmis:repositoryName>Mockup</cmis:repositoryName> <cmis:repositoryDescription>Repository sent by mockup server</cmis:repositoryDescription> <cmis:vendorName>libcmis</cmis:vendorName> <cmis:productName>Libcmis mockup</cmis:productName> <cmis:productVersion>some-version</cmis:productVersion> <cmis:rootFolderId>root-folder</cmis:rootFolderId> <cmis:latestChangeLogToken>0</cmis:latestChangeLogToken> <cmis:capabilities> <cmis:capabilityACL>manage</cmis:capabilityACL> <cmis:capabilityAllVersionsSearchable>false</cmis:capabilityAllVersionsSearchable> <cmis:capabilityChanges>none</cmis:capabilityChanges> <cmis:capabilityContentStreamUpdatability>anytime</cmis:capabilityContentStreamUpdatability> <cmis:capabilityGetDescendants>true</cmis:capabilityGetDescendants> <cmis:capabilityGetFolderTree>true</cmis:capabilityGetFolderTree> <cmis:capabilityMultifiling>true</cmis:capabilityMultifiling> <cmis:capabilityPWCSearchable>false</cmis:capabilityPWCSearchable> <cmis:capabilityPWCUpdatable>true</cmis:capabilityPWCUpdatable> <cmis:capabilityQuery>bothcombined</cmis:capabilityQuery> <cmis:capabilityRenditions>none</cmis:capabilityRenditions> <cmis:capabilityUnfiling>true</cmis:capabilityUnfiling> <cmis:capabilityVersionSpecificFiling>false</cmis:capabilityVersionSpecificFiling> <cmis:capabilityJoin>none</cmis:capabilityJoin> </cmis:capabilities> <cmis:aclCapability> <cmis:supportedPermissions>basic</cmis:supportedPermissions> <cmis:propagation>objectonly</cmis:propagation> <cmis:permissions> <cmis:permission>cmis:read</cmis:permission> <cmis:description>Read</cmis:description> </cmis:permissions> <cmis:permissions> <cmis:permission>cmis:write</cmis:permission> <cmis:description>Write</cmis:description> </cmis:permissions> <cmis:permissions> <cmis:permission>cmis:all</cmis:permission> <cmis:description>All</cmis:description> </cmis:permissions> <cmis:mapping> <cmis:key>canGetDescendents.Folder</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canGetChildren.Folder</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canGetParents.Folder</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canGetFolderParent.Object</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canCreateDocument.Folder</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canCreateFolder.Folder</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canCreateRelationship.Source</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canCreateRelationship.Target</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canGetProperties.Object</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canViewContent.Object</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canUpdateProperties.Object</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canMove.Object</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canMove.Target</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canMove.Source</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canDelete.Object</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canDeleteTree.Folder</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canSetContent.Document</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canDeleteContent.Document</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canAddToFolder.Object</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canAddToFolder.Folder</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canRemoveFromFolder.Object</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canRemoveFromFolder.Folder</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canCheckout.Document</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canCancelCheckout.Document</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canCheckin.Document</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canGetAllVersions.VersionSeries</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canGetObjectRelationships.Object</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canAddPolicy.Object</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canAddPolicy.Policy</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canRemovePolicy.Object</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canRemovePolicy.Policy</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canGetAppliedPolicies.Object</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canGetACL.Object</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canApplyACL.Object</cmis:key> <cmis:permission>cmis:all</cmis:permission> </cmis:mapping> </cmis:aclCapability> <cmis:cmisVersionSupported>1.1</cmis:cmisVersionSupported> <cmis:thinClientURI/> <cmis:changesIncomplete>true</cmis:changesIncomplete> <cmis:principalAnonymous>anonymous</cmis:principalAnonymous> <cmis:principalAnyone>anyone</cmis:principalAnyone> </cmisra:repositoryInfo> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/typedescendants" href="http://mockup/mock/typedesc" type="application/atom+xml;type=feed"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/foldertree" href="http://mockup/mock/foldertree?id=root" type="application/cmistree+xml"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/rootdescendants" href="http://mockup/mock/descendants?id=root" type="application/cmistree+xml" cmisra:id="root"/> <cmisra:uritemplate> <cmisra:template>http://mockup/mock/id?id={id}&filter={filter}&includeAllowableActions={includeAllowableActions}&includeACL={includeACL}&includePolicyIds={includePolicyIds}&includeRelationships={includeRelationships}&renditionFilter={renditionFilter}</cmisra:template> <cmisra:type>objectbyid</cmisra:type> <cmisra:mediatype>application/atom+xml;type=entry</cmisra:mediatype> </cmisra:uritemplate> <cmisra:uritemplate> <cmisra:template>http://mockup/mock/path?path={path}&filter={filter}&includeAllowableActions={includeAllowableActions}&includeACL={includeACL}&includePolicyIds={includePolicyIds}&includeRelationships={includeRelationships}&renditionFilter={renditionFilter}</cmisra:template> <cmisra:type>objectbypath</cmisra:type> <cmisra:mediatype>application/atom+xml;type=entry</cmisra:mediatype> </cmisra:uritemplate> <cmisra:uritemplate> <cmisra:template>http://mockup/mock/type?id={id}</cmisra:template> <cmisra:type>typebyid</cmisra:type> <cmisra:mediatype>application/atom+xml;type=entry</cmisra:mediatype> </cmisra:uritemplate> <cmisra:uritemplate> <cmisra:template>http://mockup/mock/query?q={q}&searchAllVersions={searchAllVersions}&includeAllowableActions={includeAllowableActions}&includeRelationships={includeRelationships}&maxItems={maxItems}&skipCount={skipCount}</cmisra:template> <cmisra:type>query</cmisra:type> <cmisra:mediatype>application/atom+xml;type=feed</cmisra:mediatype> </cmisra:uritemplate> </app:workspace> </app:service> ������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/get-versions.xml�������������������������������������������������0000664�0001750�0001750�00000050363�13407173247�017145� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:feed xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:title>Test Document</atom:title> <app:edited>2013-01-28T14:10:06Z</app:edited> <atom:updated>2013-01-28T14:10:06Z</atom:updated> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="via" href="http://mockup/mock/id?id=test-document" type="application/atom+xml;type=entry"/> <atom:entry> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:published>2013-01-28T14:10:06Z</atom:published> <atom:title>Test Document</atom:title> <app:edited>2013-01-28T14:10:06Z</app:edited> <atom:updated>2013-01-28T14:10:06Z</atom:updated> <atom:content src="http://mockup/mock/content/data.txt?id=test-document-1" type="text/plain"/> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>12345</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyHtml queryName="HtmlProp" displayName="Sample Html Property" localName="HtmlProp" propertyDefinitionId="HtmlProp"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyId queryName="IdProp" displayName="Sample Id Property" localName="IdProp" propertyDefinitionId="IdProp"/> <cmis:propertyUri queryName="UriProp" displayName="Sample Uri Property" localName="UriProp" propertyDefinitionId="UriProp"/> <cmis:propertyDateTime queryName="DateTimePropMV" displayName="Sample DateTime multi-value Property" localName="DateTimePropMV" propertyDefinitionId="DateTimePropMV"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"> <cmis:value>version-series</cmis:value> </cmis:propertyId> <cmis:propertyDecimal queryName="DecimalProp" displayName="Sample Decimal Property" localName="DecimalProp" propertyDefinitionId="DecimalProp"/> <cmis:propertyUri queryName="UriPropMV" displayName="Sample Uri multi-value Property" localName="UriPropMV" propertyDefinitionId="UriPropMV"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"> <cmis:value>1.0</cmis:value> </cmis:propertyString> <cmis:propertyBoolean queryName="BooleanProp" displayName="Sample Boolean Property" localName="BooleanProp" propertyDefinitionId="BooleanProp"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="IdPropMV" displayName="Sample Id Html multi-value Property" localName="IdPropMV" propertyDefinitionId="IdPropMV"/> <cmis:propertyString queryName="PickListProp" displayName="Sample Pick List Property" localName="PickListProp" propertyDefinitionId="PickListProp"> <cmis:value>blue</cmis:value> </cmis:propertyString> <cmis:propertyHtml queryName="HtmlPropMV" displayName="Sample Html multi-value Property" localName="HtmlPropMV" propertyDefinitionId="HtmlPropMV"/> <cmis:propertyInteger queryName="IntProp" displayName="Sample Int Property" localName="IntProp" propertyDefinitionId="IntProp"/> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Test Document</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="StringProp" displayName="Sample String Property" localName="StringProp" propertyDefinitionId="StringProp"> <cmis:value>My Doc StringProperty 6</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359382206736</cmis:value> </cmis:propertyString> <cmis:propertyDecimal queryName="DecimalPropMV" displayName="Sample Decimal multi-value Property" localName="DecimalPropMV" propertyDefinitionId="DecimalPropMV"/> <cmis:propertyDateTime queryName="DateTimeProp" displayName="Sample DateTime Property" localName="DateTimeProp" propertyDefinitionId="DateTimeProp"/> <cmis:propertyBoolean queryName="BooleanPropMV" displayName="Sample Boolean multi-value Property" localName="BooleanPropMV" propertyDefinitionId="BooleanPropMV"/> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>test-document-1</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyInteger queryName="IntPropMV" displayName="Sample Int multi-value Property" localName="IntPropMV" propertyDefinitionId="IntPropMV"/> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> <exampleExtension:exampleExtension xmlns="http://mockup/cmis/extension" xmlns:exampleExtension="http://mockup/cmis/extension"> <objectId xmlns:ns0="http://mockup/cmis/extension" ns0:type="DocumentLevel2">test-document-1</objectId> <name>Test Document</name> </exampleExtension:exampleExtension> </cmisra:object> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/id?id=test-document-1" type="application/atom+xml;type=entry" cmisra:id="test-document-1"/> <atom:link rel="enclosure" href="http://mockup/mock/id?id=test-document-1" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/id?id=test-document-1" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=DocumentLevel2" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=test-document-1" type="application/cmisallowableactions+xml"/> <atom:link rel="up" href="http://mockup/mock/parents?id=test-document-1" type="application/atom+xml;type=feed"/> <atom:link rel="edit-media" href="http://mockup/mock/content?id=test-document-1" type="text/plain"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=test-document-1" type="application/cmisacl+xml"/> </atom:entry> <atom:entry> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>Some obscure Id</atom:id> <atom:published>2013-01-28T14:10:06Z</atom:published> <atom:title>Test Document</atom:title> <app:edited>2013-01-28T14:10:06Z</app:edited> <atom:updated>2013-01-28T14:10:06Z</atom:updated> <atom:content src="http://mockup/mock/content/data.txt?id=test-document-0" type="text/plain"/> <cmisra:object xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>12345</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyHtml queryName="HtmlProp" displayName="Sample Html Property" localName="HtmlProp" propertyDefinitionId="HtmlProp"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyId queryName="IdProp" displayName="Sample Id Property" localName="IdProp" propertyDefinitionId="IdProp"/> <cmis:propertyUri queryName="UriProp" displayName="Sample Uri Property" localName="UriProp" propertyDefinitionId="UriProp"/> <cmis:propertyDateTime queryName="DateTimePropMV" displayName="Sample DateTime multi-value Property" localName="DateTimePropMV" propertyDefinitionId="DateTimePropMV"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"> <cmis:value>version-series</cmis:value> </cmis:propertyId> <cmis:propertyDecimal queryName="DecimalProp" displayName="Sample Decimal Property" localName="DecimalProp" propertyDefinitionId="DecimalProp"/> <cmis:propertyUri queryName="UriPropMV" displayName="Sample Uri multi-value Property" localName="UriPropMV" propertyDefinitionId="UriPropMV"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"> <cmis:value>0.1</cmis:value> </cmis:propertyString> <cmis:propertyBoolean queryName="BooleanProp" displayName="Sample Boolean Property" localName="BooleanProp" propertyDefinitionId="BooleanProp"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="IdPropMV" displayName="Sample Id Html multi-value Property" localName="IdPropMV" propertyDefinitionId="IdPropMV"/> <cmis:propertyString queryName="PickListProp" displayName="Sample Pick List Property" localName="PickListProp" propertyDefinitionId="PickListProp"> <cmis:value>blue</cmis:value> </cmis:propertyString> <cmis:propertyHtml queryName="HtmlPropMV" displayName="Sample Html multi-value Property" localName="HtmlPropMV" propertyDefinitionId="HtmlPropMV"/> <cmis:propertyInteger queryName="IntProp" displayName="Sample Int Property" localName="IntProp" propertyDefinitionId="IntProp"/> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Test Document</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="StringProp" displayName="Sample String Property" localName="StringProp" propertyDefinitionId="StringProp"> <cmis:value>My Doc StringProperty 6</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-27T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359382206754</cmis:value> </cmis:propertyString> <cmis:propertyDecimal queryName="DecimalPropMV" displayName="Sample Decimal multi-value Property" localName="DecimalPropMV" propertyDefinitionId="DecimalPropMV"/> <cmis:propertyDateTime queryName="DateTimeProp" displayName="Sample DateTime Property" localName="DateTimeProp" propertyDefinitionId="DateTimeProp"/> <cmis:propertyBoolean queryName="BooleanPropMV" displayName="Sample Boolean multi-value Property" localName="BooleanPropMV" propertyDefinitionId="BooleanPropMV"/> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>test-document-0</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyInteger queryName="IntPropMV" displayName="Sample Int multi-value Property" localName="IntPropMV" propertyDefinitionId="IntPropMV"/> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-27T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> <exampleExtension:exampleExtension xmlns="http://mockup/cmis/extension" xmlns:exampleExtension="http://mockup/cmis/extension"> <objectId xmlns:ns0="http://mockup/cmis/extension" ns0:type="DocumentLevel2">test-document-0</objectId> <name>Test Document</name> </exampleExtension:exampleExtension> </cmisra:object> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/id?id=test-document-0" type="application/atom+xml;type=entry" cmisra:id="test-document-0"/> <atom:link rel="enclosure" href="http://mockup/mock/id?id=test-document-0" type="application/atom+xml;type=entry"/> <atom:link rel="edit" href="http://mockup/mock/id?id=test-document-0" type="application/atom+xml;type=entry"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=DocumentLevel2" type="application/atom+xml;type=entry"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/allowableactions" href="http://mockup/mock/allowableactions?id=test-document-0" type="application/cmisallowableactions+xml"/> <atom:link rel="up" href="http://mockup/mock/parents?id=test-document-0" type="application/atom+xml;type=feed"/> <atom:link rel="edit-media" href="http://mockup/mock/content?id=test-document-0" type="text/plain"/> <atom:link rel="http://docs.oasis-open.org/ns/cmis/link/200908/acl" href="http://mockup/mock/acl?id=test-document-0" type="application/cmisacl+xml"/> </atom:entry> </atom:feed> �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/atom/typechildren-docLevel1.xml���������������������������������������0000664�0001750�0001750�00000007356�13407173247�021032� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="UTF-8"?> <atom:feed xmlns:atom="http://www.w3.org/2005/Atom" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmisra="http://docs.oasis-open.org/ns/cmis/restatom/200908/" xmlns:app="http://www.w3.org/2007/app"> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>http://mockup/mock/obscure id</atom:id> <atom:title>Document Level 1</atom:title> <app:edited>2013-01-25T10:11:03Z</app:edited> <atom:updated>2013-01-25T10:11:03Z</atom:updated> <cmisra:numItems>1</cmisra:numItems> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/types?typeId=DocumentLevel1&includePropertyDefinitions=false" type="application/atom+xml;type=entry" cmisra:id="DocumentLevel1"/> <atom:link rel="via" href="http://mockup/mock/type?id=DocumentLevel1" type="application/atom+xml;type=entry"/> <atom:link rel="down" href="http://mockup/mock/typedesc?typeId=DocumentLevel1" type="application/cmistree+xml"/> <atom:link rel="up" href="http://mockup/mock/type?id=cmis%3Adocument" type="application/atom+xml;type=entry"/> <atom:link rel="next" href="http://mockup/mock/types?typeId=DocumentLevel1&includePropertyDefinitions=false&skipCount=100&maxItems=100" type="application/atom+xml;type=feed"/> <app:collection href="http://mockup/mock/types?typeId=DocumentLevel1"> <atom:title type="text">Types Collection</atom:title> <app:accept/> </app:collection> <atom:entry> <atom:author> <atom:name>unknown</atom:name> </atom:author> <atom:id>http://mockup/mock/obscure id</atom:id> <atom:title>Document Level 2</atom:title> <app:edited>2013-01-25T10:11:03Z</app:edited> <atom:updated>2013-01-25T10:11:03Z</atom:updated> <cmisra:type xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ns3="http://docs.oasis-open.org/ns/cmis/messaging/200908/" xsi:type="cmis:cmisTypeDocumentDefinitionType"> <cmis:id>DocumentLevel2</cmis:id> <cmis:localName>DocumentLevel2</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Document Level 2</cmis:displayName> <cmis:queryName>DocumentLevel2</cmis:queryName> <cmis:description>Description of Document Level 2 Type</cmis:description> <cmis:baseId>cmis:document</cmis:baseId> <cmis:parentId>DocumentLevel1</cmis:parentId> <cmis:creatable>true</cmis:creatable> <cmis:fileable>true</cmis:fileable> <cmis:queryable>false</cmis:queryable> <cmis:fulltextIndexed>false</cmis:fulltextIndexed> <cmis:includedInSupertypeQuery>true</cmis:includedInSupertypeQuery> <cmis:controllablePolicy>false</cmis:controllablePolicy> <cmis:controllableACL>true</cmis:controllableACL> <cmis:versionable>false</cmis:versionable> <cmis:contentStreamAllowed>allowed</cmis:contentStreamAllowed> </cmisra:type> <atom:link rel="service" href="http://mockup/mock" type="application/atomsvc+xml"/> <atom:link rel="self" href="http://mockup/mock/type?id=DocumentLevel2" type="application/atom+xml;type=entry" cmisra:id="DocumentLevel2"/> <atom:link rel="enclosure" href="http://mockup/mock/type?id=DocumentLevel2" type="application/atom+xml;type=entry"/> <atom:link rel="up" href="http://mockup/mock/type?id=DocumentLevel1" type="application/atom+xml;type=entry"/> <atom:link rel="down" href="http://mockup/mock/types?typeId=DocumentLevel2" type="application/atom+xml;type=feed"/> <atom:link rel="down" href="http://mockup/mock/typedesc?typeId=DocumentLevel2" type="application/cmistree+xml"/> <atom:link rel="describedby" href="http://mockup/mock/type?id=cmis%3Adocument" type="application/atom+xml;type=entry"/> </atom:entry> </atom:feed> ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/gdrive/���������������������������������������������������������������0000775�0001750�0001750�00000000000�13407173247�014367� 5����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/gdrive/folder_children.json�������������������������������������������0000664�0001750�0001750�00000000647�13407173247�020334� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "kind": "drive#childrenList", "etag": "A children etag", "selfLink": "SelfLink", "items": [ { "kind": "drive#childrenReference", "id": "aChildFolder", "mimeType": "application/vnd.google-apps.folder", "selfLink": "aSelfLink", "childLink": "AchildrenLink" }, { "kind": "drive#childrenReference", "id": "aChildDocument", "selfLink": "aSelfLink2", "childLink": "AchildrenLink2" } ] } �����������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/gdrive/login1.html����������������������������������������������������0000664�0001750�0001750�00000000761�13407173247�016372� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<!DOCTYPE html> <html lang="en"> <body> <form novalidate="" id="gaia_loginform" action="https://login2/url" method="post"> <input name="Page" type="hidden" value="PasswordSeparationSignIn"> <input name="continue" id="continue" value="redirectLink&scope=Scope" type="hidden"> <input name="service" id="service" value="lso" type="hidden"> <input name="GALX" value="cookie" type="hidden"> <input spellcheck="false" name="Email" id="Email" value="" type="email"> </form> </body> </html> ���������������libcmis-0.5.2/qa/libcmis/data/gdrive/login2.html����������������������������������������������������0000664�0001750�0001750�00000000624�13407173247�016371� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<!DOCTYPE html> <html lang="en"> <body> <form novalidate="" id="gaia_loginform" action="https://login/url" method="post"> <input name="continue" id="continue" value="redirectLink&scope=Scope" type="hidden"> <input name="service" id="service" value="lso" type="hidden"> <input name="GALX" value="cookie" type="hidden"> <input name="Passwd" id="Passwd" type="password"> </form> </body> </html> ������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/gdrive/document.json��������������������������������������������������0000664�0001750�0001750�00000002773�13407173247�017031� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "kind": "drive#file", "id": "aFileId", "etag": "\"an example tag\"", "selfLink": "fileSelfLink", "title": "GDrive File", "mimeType": "application/vnd.google-apps.form", "labels": { "starred": false, "hidden": false, "trashed": false, "restricted": false, "viewed": true }, "createdDate": "2010-04-28T14:53:23.141Z", "modifiedDate": "2010-09-30T21:01:37.504Z", "lastViewedByMeDate": "2013-02-26T15:40:30.404Z", "fileSize": "123", "parents": [ { "kind": "drive#parentReference", "id": "aFolderId", "selfLink": "parentSelfLink", "parentLink": "parentLink", "isRoot": true }, { "kind": "drive#parentReference", "id": "aNewFolderId", "selfLink": "parentSelfLink", "parentLink": "parentLink", "isRoot": true } ], "exportLinks": { "application/pdf": "pdflink", "application/x-vnd.oasis.opendocument.spreadsheet": "https://downloadLink", "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet": "xlslink" }, "thumbnailLink": "https://aThumbnailLink", "userPermission": { "kind": "drive#permission", "id": "me", "role": "owner", "type": "user" }, "quotaBytesUsed": "0", "ownerNames": [ "Owner Real Name" ], "owners": [ { "kind": "drive#user", "displayName": "Mock file owner", "isAuthenticatedUser": true } ], "lastModifyingUserName": "Mock user", "lastModifyingUser": { "kind": "drive#user", "displayName": "User name", "isAuthenticatedUser": false }, "editable": true, "writersCanShare": true, "shared": true } �����libcmis-0.5.2/qa/libcmis/data/gdrive/document_parents.json������������������������������������������0000664�0001750�0001750�00000000363�13407173247�020556� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "kind": "drive#parentList", "etag": "A parent etag", "selfLink": "SelfLink", "items": [ { "kind": "drive#parentReference", "id": "aFolderId", "selfLink": "aSelfLink", "parentLink": "AParentLink", "isRoot": true } ] } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/gdrive/refresh_response.json������������������������������������������0000664�0001750�0001750�00000000126�13407173247�020555� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "access_token":"new-access-token", "expires_in":3920, "token_type":"Bearer" } ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/gdrive/authcode.html��������������������������������������������������0000664�0001750�0001750�00000000145�13407173247�016771� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<!DOCTYPE html> <html> <body> <input id="code" readonly="readonly" value="AuthCode"> </body> </html> ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/gdrive/jsontest-good.json���������������������������������������������0000664�0001750�0001750�00000002517�13407173247�020006� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "kind": "drive#file", "id": "aFileId", "etag": "\"an example tag\"", "selfLink": "fileSelfLink", "title": "a file title", "mimeType": "application/vnd.google-apps.form", "labels": { "starred": false, "hidden": false, "trashed": false, "restricted": false, "viewed": true }, "createdDate": "2010-04-28T14:53:23.141Z", "modifiedDate": "2010-09-30T21:01:37.504Z", "lastViewedByMeDate": "2013-02-26T15:40:30.404Z", "intTest": "-123", "doubleTest": "-123.456", "parents": [ { "kind": "drive#parentReference", "id": "parentId", "selfLink": "parentSelfLink", "parentLink": "parentLink", "isRoot": true } ], "exportLinks": { "application/pdf": "pdflink", "application/x-vnd.oasis.opendocument.spreadsheet": "opendocumentlinks", "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet": "xlslink" }, "userPermission": { "kind": "drive#permission", "id": "me", "role": "owner", "type": "user" }, "quotaBytesUsed": "0", "ownerNames": [ "Owner Real Name" ], "owners": [ { "kind": "drive#user", "displayName": "Mock file owner", "isAuthenticatedUser": true } ], "lastModifyingUserName": "Mock user", "lastModifyingUser": { "kind": "drive#user", "displayName": "User name", "isAuthenticatedUser": false }, "editable": true, "writersCanShare": true, "shared": true } ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/gdrive/document-updated.json������������������������������������������0000664�0001750�0001750�00000002771�13407173247�020453� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "kind": "drive#file", "id": "aFileId", "etag": "\"an example tag\"", "selfLink": "fileSelfLink", "title": "New Title", "mimeType": "application/vnd.google-apps.form", "labels": { "starred": false, "hidden": false, "trashed": false, "restricted": false, "viewed": true }, "createdDate": "2010-04-28T14:53:23.141Z", "modifiedDate": "2010-09-30T21:01:37.504Z", "lastViewedByMeDate": "2013-02-26T15:40:30.404Z", "fileSize": "123", "parents": [ { "kind": "drive#parentReference", "id": "aFolderId", "selfLink": "parentSelfLink", "parentLink": "parentLink", "isRoot": true }, { "kind": "drive#parentReference", "id": "aNewFolderId", "selfLink": "parentSelfLink", "parentLink": "parentLink", "isRoot": true } ], "exportLinks": { "application/pdf": "pdflink", "application/x-vnd.oasis.opendocument.spreadsheet": "https://downloadLink", "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet": "xlslink" }, "thumbnailLink": "https://aThumbnailLink", "userPermission": { "kind": "drive#permission", "id": "me", "role": "owner", "type": "user" }, "quotaBytesUsed": "0", "ownerNames": [ "Owner Real Name" ], "owners": [ { "kind": "drive#user", "displayName": "Mock file owner", "isAuthenticatedUser": true } ], "lastModifyingUserName": "Mock user", "lastModifyingUser": { "kind": "drive#user", "displayName": "User name", "isAuthenticatedUser": false }, "editable": true, "writersCanShare": true, "shared": true } �������libcmis-0.5.2/qa/libcmis/data/gdrive/approve.html���������������������������������������������������0000664�0001750�0001750�00000000434�13407173247�016652� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<!DOCTYPE html> <html> <body> <form action="https://approval/url" method="POST" id="submit_access_form"> <input id="state_wrapper" name="state_wrapper" value="stateWrapper" type="hidden"> <input id="submit_access" name="submit_access" value="" type="hidden"> </form> </body> </html> ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/gdrive/allVersions.json�����������������������������������������������0000664�0001750�0001750�00000002634�13407173247�017510� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "kind": "drive#revisionList", "etag": "revisionEtag", "selfLink": "revisionsLink", "items": [ { "kind": "drive#revision", "etag": "\"anEtag\"", "id": "versionId0", "selfLink": "aSelfLink", "mimeType": "application/vnd.google-apps.form", "modifiedDate": "2010-07-04T12:30:07.355Z", "published": false, "exportLinks": { "application/pdf": "pdfLink", "application/x-vnd.oasis.opendocument.spreadsheet": "ODFLinks", "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet": "msLink" } }, { "kind": "drive#revision", "etag": "\"anEtag\"", "id": "versionId1", "selfLink": "aSelfLink", "mimeType": "application/vnd.google-apps.form", "modifiedDate": "2010-07-04T12:30:07.355Z", "published": false, "exportLinks": { "application/pdf": "pdfLink", "application/x-vnd.oasis.opendocument.spreadsheet": "ODFLinks", "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet": "msLink" } }, { "kind": "drive#revision", "etag": "\"anEtag\"", "id": "versionId2", "selfLink": "aSelfLink", "mimeType": "application/vnd.google-apps.form", "modifiedDate": "2010-07-04T12:30:07.355Z", "published": false, "exportLinks": { "application/pdf": "pdfLink", "application/x-vnd.oasis.opendocument.spreadsheet": "ODFLinks", "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet": "msLink" } } ] } ����������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/gdrive/challenge.html�������������������������������������������������0000664�0001750�0001750�00000001514�13407173247�017120� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<!DOCTYPE html> <html lang="en"> <body> <form novalidate="" id="skip" action="/signin/challenge/skip" method="post"> <input id="skipChallenge" type="submit"> </form> <form novalidate="" id="resend" action="/signin/challenge" method="post"> <input name="subAction" type="hidden" value="startChallenge"> <input name="challengeId" type="hidden" value="1"> </form> <form novalidate="" id="challenge" action="/challenge/url" method="post"> <input name="continue" id="continue" value="redirectLink&scope=Scope" type="hidden"> <input name="service" id="service" value="lso" type="hidden"> <input name="GALX" value="cookie" type="hidden"> <input name="Pin" id="Pin"> </form> <form novalidate="" id="select_challenge" action="/signin/selectchallenge" method="post"> <input id="selectChallenge" type="submit"> </form> </body> </html> ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/gdrive/folder2.json���������������������������������������������������0000664�0001750�0001750�00000002004�13407173247�016533� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "kind": "drive#file", "id": "aNewFolderId", "etag": "a folder etag", "selfLink": "SelfLINK", "title": "testFolder", "mimeType": "application/vnd.google-apps.folder", "labels": { "starred": false, "hidden": false, "trashed": false, "restricted": false, "viewed": true }, "createdDate": "2013-03-22T17:53:10.290Z", "modifiedDate": "2013-03-22T17:53:44.212Z", "modifiedByMeDate": "2013-03-22T17:53:44.212Z", "lastViewedByMeDate": "2013-04-05T15:27:47.261Z", "parents": [ { "kind": "drive#parentReference", "id": "parentID", "isRoot": true } ], "quotaBytesUsed": "0", "ownerNames": [ "User" ], "owners": [ { "kind": "drive#user", "displayName": "User name", "isAuthenticatedUser": true } ], "lastModifyingUserName": "User name of the last person modify", "lastModifyingUser": { "kind": "drive#user", "displayName": "Last mofifying username", "isAuthenticatedUser": true }, "editable": true, "writersCanShare": true, "shared": false, "appDataContents": false } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/gdrive/document2.json�������������������������������������������������0000664�0001750�0001750�00000002445�13407173247�017107� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "kind": "drive#file", "id": "aFileId", "etag": "\"an example tag\"", "selfLink": "fileSelfLink", "title": "GDrive File", "mimeType": "application/vnd.google-apps.form", "labels": { "starred": false, "hidden": false, "trashed": false, "restricted": false, "viewed": true }, "createdDate": "2010-04-28T14:53:23.141Z", "modifiedDate": "2010-09-30T21:01:37.504Z", "lastViewedByMeDate": "2013-02-26T15:40:30.404Z", "fileSize": "123", "downloadUrl": "https://download/url", "parents": [ { "kind": "drive#parentReference", "id": "aFolderId", "selfLink": "parentSelfLink", "parentLink": "parentLink", "isRoot": true }, { "kind": "drive#parentReference", "id": "anotherFolderId", "selfLink": "parentSelfLink", "parentLink": "parentLink", "isRoot": true } ], "userPermission": { "kind": "drive#permission", "id": "me", "role": "owner", "type": "user" }, "quotaBytesUsed": "0", "ownerNames": [ "Owner Real Name" ], "owners": [ { "kind": "drive#user", "displayName": "Mock file owner", "isAuthenticatedUser": true } ], "lastModifyingUserName": "Mock user", "lastModifyingUser": { "kind": "drive#user", "displayName": "User name", "isAuthenticatedUser": false }, "editable": true, "writersCanShare": true, "shared": true } ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/gdrive/gdoc-file.json�������������������������������������������������0000664�0001750�0001750�00000002440�13407173247�017033� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "kind": "drive#file", "id": "aFileId", "etag": "\"an example tag\"", "selfLink": "fileSelfLink", "title": "a file title", "mimeType": "application/vnd.google-apps.form", "labels": { "starred": false, "hidden": false, "trashed": false, "restricted": false, "viewed": true }, "createdDate": "2010-04-28T14:53:23.141Z", "modifiedDate": "2010-09-30T21:01:37.504Z", "lastViewedByMeDate": "2013-02-26T15:40:30.404Z", "parents": [ { "kind": "drive#parentReference", "id": "parentId", "selfLink": "parentSelfLink", "parentLink": "parentLink", "isRoot": true } ], "exportLinks": { "application/pdf": "pdflink", "application/x-vnd.oasis.opendocument.spreadsheet": "opendocumentlinks", "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet": "xlslink" }, "userPermission": { "kind": "drive#permission", "id": "me", "role": "owner", "type": "user" }, "quotaBytesUsed": "0", "ownerNames": [ "Owner Real Name" ], "owners": [ { "kind": "drive#user", "displayName": "Mock file owner", "isAuthenticatedUser": true } ], "lastModifyingUserName": "Mock user", "lastModifyingUser": { "kind": "drive#user", "displayName": "User name", "isAuthenticatedUser": false }, "editable": true, "writersCanShare": true, "shared": true } ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/gdrive/root_child_search.json�����������������������������������������0000664�0001750�0001750�00000000355�13407173247�020660� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "kind": "drive#childrenList", "etag": "A children etag", "selfLink": "SelfLink", "items": [ { "kind": "drive#childrenReference", "id": "aRootChildId2", "selfLink": "aSelfLink2", "childLink": "AchildrenLink2" } ] } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/gdrive/folder.json����������������������������������������������������0000664�0001750�0001750�00000002001�13407173247�016446� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "kind": "drive#file", "id": "aFolderId", "etag": "a folder etag", "selfLink": "SelfLINK", "title": "testFolder", "mimeType": "application/vnd.google-apps.folder", "labels": { "starred": false, "hidden": false, "trashed": false, "restricted": false, "viewed": true }, "createdDate": "2013-03-22T17:53:10.290Z", "modifiedDate": "2013-03-22T17:53:44.212Z", "modifiedByMeDate": "2013-03-22T17:53:44.212Z", "lastViewedByMeDate": "2013-04-05T15:27:47.261Z", "parents": [ { "kind": "drive#parentReference", "id": "parentID", "isRoot": true } ], "quotaBytesUsed": "0", "ownerNames": [ "User" ], "owners": [ { "kind": "drive#user", "displayName": "User name", "isAuthenticatedUser": true } ], "lastModifyingUserName": "User name of the last person modify", "lastModifyingUser": { "kind": "drive#user", "displayName": "Last mofifying username", "isAuthenticatedUser": true }, "editable": true, "writersCanShare": true, "shared": false, "appDataContents": false } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/gdrive/token-response.json��������������������������������������������0000664�0001750�0001750�00000000176�13407173247�020162� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "access_token":"mock-access-token", "expires_in":3920, "token_type":"Bearer", "refresh_token":"mock-refresh-token" }��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/gdrive/root_child_missing.json����������������������������������������0000664�0001750�0001750�00000000023�13407173247�021054� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "items": [ ] } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/onedrive/�������������������������������������������������������������0000775�0001750�0001750�00000000000�13407173247�014722� 5����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/onedrive/folderC.json�������������������������������������������������0000664�0001750�0001750�00000000777�13407173247�017126� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "id": "folderC", "from": { "name": "onedriveUser", "id": "aUserId" }, "name": "Folder C", "description": "short description", "parent_id": "folderB", "size": 42, "upload_location": "uploadLocation", "comments_count": 0, "comments_enabled": true, "is_embeddable": true, "link": "linkUrl", "type": "folder", "shared_with": { "access": "Shared" }, "created_time": "2014-06-09T08:24:04+0000", "updated_time": "2014-06-09T08:24:04+0000", "client_updated_time": "2014-06-09T08:24:04+0000" } �libcmis-0.5.2/qa/libcmis/data/onedrive/new-file.json������������������������������������������������0000664�0001750�0001750�00000000107�13407173247�017241� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "id": "aFileId", "name": "OneDrive File", "source": "sourceUrl" } ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/onedrive/folderA.json�������������������������������������������������0000664�0001750�0001750�00000000772�13407173247�017117� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "id": "folderA", "from": { "name": "onedriveUser", "id": "aUserId" }, "name": "SkyDrive", "description": "short description", "parent_id": null, "size": 42, "upload_location": "uploadLocation", "comments_count": 0, "comments_enabled": true, "is_embeddable": true, "link": "linkUrl", "type": "folder", "shared_with": { "access": "Shared" }, "created_time": "2014-06-09T08:24:04+0000", "updated_time": "2014-06-09T08:24:04+0000", "client_updated_time": "2014-06-09T08:24:04+0000" } ������libcmis-0.5.2/qa/libcmis/data/onedrive/searched-file.json�������������������������������������������0000664�0001750�0001750�00000001055�13407173247�020231� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "id": "rightFile", "from": { "name": "onedriveUser", "id": "aUserId" }, "name": "OneDriveFile", "description": "short description", "parent_id": "folderC", "size": 42, "upload_location": "https://base/url/aFileId/content", "comments_count": 0, "comments_enabled": true, "is_embeddable": true, "source": "sourceUrl", "link": "linkUrl", "type": "file", "shared_with": { "access": "Shared" }, "created_time": "2014-06-09T08:24:04+0000", "updated_time": "2014-06-09T08:24:04+0000", "client_updated_time": "2014-06-09T08:24:04+0000" } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/onedrive/searched-wrong-file.json�������������������������������������0000664�0001750�0001750�00000001055�13407173247�021363� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "id": "wrongFile", "from": { "name": "onedriveUser", "id": "aUserId" }, "name": "OneDriveFile", "description": "short description", "parent_id": "folderA", "size": 42, "upload_location": "https://base/url/aFileId/content", "comments_count": 0, "comments_enabled": true, "is_embeddable": true, "source": "sourceUrl", "link": "linkUrl", "type": "file", "shared_with": { "access": "Shared" }, "created_time": "2014-06-09T08:24:04+0000", "updated_time": "2014-06-09T08:24:04+0000", "client_updated_time": "2014-06-09T08:24:04+0000" } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/onedrive/refresh-response.json����������������������������������������0000664�0001750�0001750�00000000311�13407173247�021022� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "token_type":"bearer", "expires_in":3600, "scope":"wl.signin wl.skydrive", "access_token":"new-access-token", "refresh_token":"mock-refresh-token", "user_id":"mock-user-id" } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/onedrive/file.json����������������������������������������������������0000664�0001750�0001750�00000001055�13407173247�016455� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "id": "aFileId", "from": { "name": "onedriveUser", "id": "aUserId" }, "name": "OneDriveFile", "description": "short description", "parent_id": "aParentId", "size": 42, "upload_location": "https://base/url/aFileId/content", "comments_count": 0, "comments_enabled": true, "is_embeddable": true, "source": "sourceUrl", "link": "linkUrl", "type": "file", "shared_with": { "access": "Shared" }, "created_time": "2014-06-09T08:24:04+0000", "updated_time": "2014-06-09T08:24:04+0000", "client_updated_time": "2014-06-09T08:24:04+0000" } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/onedrive/updated-file.json��������������������������������������������0000664�0001750�0001750�00000000774�13407173247�020110� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "id": "aNewFileId", "from": { "name": "onedriveUser", "id": "aUserId" }, "name": "New File Name", "description": "new description", "parent_id": "aParentId", "size": 42, "upload_location": "uploadLocation", "comments_count": 0, "comments_enabled": true, "is_embeddable": true, "source": "sourceUrl", "link": "linkUrl", "type": "file", "shared_with": { "access": "Shared" }, "created_time": "createdTime", "updated_time": "updatedTime", "client_updated_time": "clientUpdatedTime" } ����libcmis-0.5.2/qa/libcmis/data/onedrive/folder-listed.json�������������������������������������������0000664�0001750�0001750�00000003112�13407173247�020267� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "data": [ { "id": "aFolderId", "from": { "name": "onedriveUser", "id": "aUserId" }, "name": "OneDrive Folder", "description": "short description", "parent_id": "aParentId", "size": 42, "upload_location": "uploadLocation", "comments_count": 0, "comments_enabled": true, "is_embeddable": true, "link": "linkUrl", "type": "folder", "shared_with": { "access": "Shared" }, "created_time": "2014-06-09T08:24:04+0000", "updated_time": "2014-06-09T08:24:04+0000", "client_updated_time": "2014-06-09T08:24:04+0000" }, { "id": "aFileId", "from": { "name": "onedriveUser", "id": "aUserId" }, "name": "OneDrive File", "description": "short description", "parent_id": "aParentId", "size": 42, "upload_location": "uploadLocation", "comments_count": 0, "comments_enabled": true, "is_embeddable": true, "source": "sourceUrl", "link": "linkUrl", "type": "file", "shared_with": { "access": "Shared" }, "created_time": "2014-06-09T08:24:04+0000", "updated_time": "2014-06-09T08:24:04+0000", "client_updated_time": "2014-06-09T08:24:04+0000" } ] } ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/onedrive/parent-folder.json�������������������������������������������0000664�0001750�0001750�00000001003�13407173247�020271� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "id": "aParentId", "from": { "name": "onedriveUser", "id": "aUserId" }, "name": "OneDrive Folder", "description": "short description", "parent_id": null, "size": 42, "upload_location": "uploadLocation", "comments_count": 0, "comments_enabled": true, "is_embeddable": true, "link": "linkUrl", "type": "folder", "shared_with": { "access": "Shared" }, "created_time": "2014-06-09T08:24:04+0000", "updated_time": "2014-06-09T08:24:04+0000", "client_updated_time": "2014-06-09T08:24:04+0000" } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/onedrive/folder.json��������������������������������������������������0000664�0001750�0001750�00000001012�13407173247�017002� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "id": "aFolderId", "from": { "name": "onedriveUser", "id": "aUserId" }, "name": "OneDrive Folder", "description": "short description", "parent_id": "aParentId", "size": 42, "upload_location": "uploadLocation", "comments_count": 0, "comments_enabled": true, "is_embeddable": true, "link": "linkUrl", "type": "folder", "shared_with": { "access": "Shared" }, "created_time": "2014-06-09T08:24:04+0000", "updated_time": "2014-06-09T08:24:04+0000", "client_updated_time": "2014-06-09T08:24:04+0000" } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/onedrive/token-response.json������������������������������������������0000664�0001750�0001750�00000000312�13407173247�020505� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "token_type":"bearer", "expires_in":3600, "scope":"wl.signin wl.skydrive", "access_token":"mock-access-token", "refresh_token":"mock-refresh-token", "user_id":"mock-user-id" } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/onedrive/search-result.json�������������������������������������������0000664�0001750�0001750�00000002512�13407173247�020316� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "data":[ { "id":"wrongFileId", "from":{ "name":"aOneDriveUser", "id":"1b4a1bc1bdb25a14" }, "name":"OneDriveFile", "description":"", "parent_id":"folderA", "size":18047, "upload_location":"https://apis.live.net/v5.0/wrongFileId/content/", "comments_count":0, "comments_enabled":false, "is_embeddable":true, "source":"sourceUrl", "link":"link", "type":"file", "shared_with":{ "access":"Just me" }, "created_time":"2014-07-17T15:16:43+0000", "updated_time":"2014-07-17T15:41:45+0000", "client_updated_time":"2014-07-17T15:41:45+0000" }, { "id":"rightFile", "from":{ "name":"aOneDriveUser", "id":"1b4a1bc1bdb25a14" }, "name":"OneDriveFile", "description":"", "parent_id":"folderC", "size":4, "upload_location":"https://apis.live.net/v5.0/rightFileId/content/", "comments_count":0, "comments_enabled":false, "is_embeddable":true, "source":"sourceUrl", "link":"link", "type":"file", "shared_with":{ "access":"Just me" }, "created_time":"2014-06-17T11:30:14+0000", "updated_time":"2014-06-17T11:30:14+0000", "client_updated_time":"2014-06-17T11:30:14+0000" } ] } ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/onedrive/folderB.json�������������������������������������������������0000664�0001750�0001750�00000000777�13407173247�017125� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������{ "id": "folderB", "from": { "name": "onedriveUser", "id": "aUserId" }, "name": "Folder B", "description": "short description", "parent_id": "folderA", "size": 42, "upload_location": "uploadLocation", "comments_count": 0, "comments_enabled": true, "is_embeddable": true, "link": "linkUrl", "type": "folder", "shared_with": { "access": "Shared" }, "created_time": "2014-06-09T08:24:04+0000", "updated_time": "2014-06-09T08:24:04+0000", "client_updated_time": "2014-06-09T08:24:04+0000" } �libcmis-0.5.2/qa/libcmis/data/ws/�������������������������������������������������������������������0000775�0001750�0001750�00000000000�13407173247�013540� 5����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/getbypath-bad.http�������������������������������������������������0000664�0001750�0001750�00000003015�13407173247�017073� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*abd9e41c-b3aa-40a7-a73a-997c472010e8@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:abd9e41c-b3aa-40a7-a73a-997c472010e8";start-info="text/xml" --uuid:abd9e41c-b3aa-40a7-a73a-997c472010e8 Content-Id: <rootpart*abd9e41c-b3aa-40a7-a73a-997c472010e8@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version="1.0" encoding="UTF-8"?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-30T19:54:27Z</Created> <Expires>2013-10-01T19:54:27Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <S:Fault> <faultcode>S:Server</faultcode> <faultstring>Path '/some/invalid/path' not found</faultstring> <detail> <cmisFault:cmisFault xmlns="http://docs.oasis-open.org/ns/cmis/messaging/200908/" xmlns:cmisFault="http://docs.oasis-open.org/ns/cmis/messaging/200908/" xmlns:ns2="http://docs.oasis-open.org/ns/cmis/core/200908/"> <type>objectNotFound</type> <code>562</code> <message>Path not found: '/some/invalid/path'</message> </cmisFault:cmisFault> </detail> </S:Fault> </S:Body> </S:Envelope> --uuid:abd9e41c-b3aa-40a7-a73a-997c472010e8-- �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/test-document-add-secondary.http�����������������������������������0000664�0001750�0001750�00000031455�13407173247�021677� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getObjectResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:object> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>12345</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyHtml queryName="HtmlProp" displayName="Sample Html Property" localName="HtmlProp" propertyDefinitionId="HtmlProp"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyId queryName="IdProp" displayName="Sample Id Property" localName="IdProp" propertyDefinitionId="IdProp"/> <cmis:propertyUri queryName="UriProp" displayName="Sample Uri Property" localName="UriProp" propertyDefinitionId="UriProp"/> <cmis:propertyDateTime queryName="DateTimePropMV" displayName="Sample DateTime multi-value Property" localName="DateTimePropMV" propertyDefinitionId="DateTimePropMV"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"> <cmis:value>series-id</cmis:value> </cmis:propertyId> <cmis:propertyDecimal queryName="DecimalProp" displayName="Sample Decimal Property" localName="DecimalProp" propertyDefinitionId="DecimalProp"/> <cmis:propertyUri queryName="UriPropMV" displayName="Sample Uri multi-value Property" localName="UriPropMV" propertyDefinitionId="UriPropMV"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"/> <cmis:propertyBoolean queryName="BooleanProp" displayName="Sample Boolean Property" localName="BooleanProp" propertyDefinitionId="BooleanProp"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="IdPropMV" displayName="Sample Id Html multi-value Property" localName="IdPropMV" propertyDefinitionId="IdPropMV"/> <cmis:propertyString queryName="PickListProp" displayName="Sample Pick List Property" localName="PickListProp" propertyDefinitionId="PickListProp"> <cmis:value>blue</cmis:value> </cmis:propertyString> <cmis:propertyHtml queryName="HtmlPropMV" displayName="Sample Html multi-value Property" localName="HtmlPropMV" propertyDefinitionId="HtmlPropMV"/> <cmis:propertyInteger queryName="IntProp" displayName="Sample Int Property" localName="IntProp" propertyDefinitionId="IntProp"/> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Test Document</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="StringProp" displayName="Sample String Property" localName="StringProp" propertyDefinitionId="StringProp"> <cmis:value>My Doc StringProperty 6</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>some-change-token</cmis:value> </cmis:propertyString> <cmis:propertyDecimal queryName="DecimalPropMV" displayName="Sample Decimal multi-value Property" localName="DecimalPropMV" propertyDefinitionId="DecimalPropMV"/> <cmis:propertyDateTime queryName="DateTimeProp" displayName="Sample DateTime Property" localName="DateTimeProp" propertyDefinitionId="DateTimeProp"/> <cmis:propertyBoolean queryName="BooleanPropMV" displayName="Sample Boolean multi-value Property" localName="BooleanPropMV" propertyDefinitionId="BooleanPropMV"/> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>test-document</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyInteger queryName="IntPropMV" displayName="Sample Int multi-value Property" localName="IntPropMV" propertyDefinitionId="IntPropMV"/> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:secondaryObjectTypeIds" displayName="cmis:secondaryObjectTypeIds" localName="cmis:secondaryObjectTypeIds" propertyDefinitionId="cmis:secondaryObjectTypeIds"> <cmis:value>secondary-type</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="secondary-prop" displayName="secondary-prop" localName="secondary-prop" propertyDefinitionId="secondary-prop"> <cmis:value>some-value</cmis:value> </cmis:propertyString> </cmis:properties> <cmis:allowableActions> <cmis:canDeleteObject>true</cmis:canDeleteObject> <cmis:canUpdateProperties>true</cmis:canUpdateProperties> <cmis:canGetFolderTree>false</cmis:canGetFolderTree> <cmis:canGetProperties>true</cmis:canGetProperties> <cmis:canGetObjectRelationships>false</cmis:canGetObjectRelationships> <cmis:canGetObjectParents>true</cmis:canGetObjectParents> <cmis:canGetFolderParent>false</cmis:canGetFolderParent> <cmis:canGetDescendants>false</cmis:canGetDescendants> <cmis:canMoveObject>true</cmis:canMoveObject> <cmis:canDeleteContentStream>true</cmis:canDeleteContentStream> <cmis:canCheckOut>true</cmis:canCheckOut> <cmis:canCancelCheckOut>false</cmis:canCancelCheckOut> <cmis:canCheckIn>false</cmis:canCheckIn> <cmis:canSetContentStream>true</cmis:canSetContentStream> <cmis:canGetAllVersions>true</cmis:canGetAllVersions> <cmis:canAddObjectToFolder>true</cmis:canAddObjectToFolder> <cmis:canRemoveObjectFromFolder>true</cmis:canRemoveObjectFromFolder> <cmis:canGetContentStream>true</cmis:canGetContentStream> <cmis:canApplyPolicy>false</cmis:canApplyPolicy> <cmis:canGetAppliedPolicies>false</cmis:canGetAppliedPolicies> <cmis:canRemovePolicy>false</cmis:canRemovePolicy> <cmis:canGetChildren>false</cmis:canGetChildren> <cmis:canCreateDocument>false</cmis:canCreateDocument> <cmis:canCreateFolder>false</cmis:canCreateFolder> <cmis:canCreateRelationship>false</cmis:canCreateRelationship> <cmis:canDeleteTree>false</cmis:canDeleteTree> <cmis:canGetRenditions>false</cmis:canGetRenditions> <cmis:canGetACL>false</cmis:canGetACL> <cmis:canApplyACL>false</cmis:canApplyACL> </cmis:allowableActions> <exampleExtension:exampleExtension xmlns="http://mockup/cmis/extension" xmlns:exampleExtension="http://mockup/cmis/extension"> <objectId xmlns:ns0="http://mockup/cmis/extension" ns0:type="DocumentLevel2">test-document</objectId> <name>Test Document</name> </exampleExtension:exampleExtension> </cmism:object> </cmism:getObjectResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/create-folder-bad-type.http����������������������������������������0000664�0001750�0001750�00000003160�13407173247�020600� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <S:Fault> <faultcode>S:Server</faultcode> <faultstring>Can't create folder with type cmis:document</faultstring> <detail> <cmisFault:cmisFault xmlns="http://docs.oasis-open.org/ns/cmis/messaging/200908/" xmlns:cmisFault="http://docs.oasis-open.org/ns/cmis/messaging/200908/" xmlns:ns2="http://docs.oasis-open.org/ns/cmis/core/200908/"> <type>constraint</type> <code>562</code> <message>Can't create folder with type cmis:document</message> </cmisFault:cmisFault> </detail> </S:Fault> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/test-document.http�������������������������������������������������0000664�0001750�0001750�00000030361�13407173247�017157� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getObjectResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:object> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>12345</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyHtml queryName="HtmlProp" displayName="Sample Html Property" localName="HtmlProp" propertyDefinitionId="HtmlProp"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyId queryName="IdProp" displayName="Sample Id Property" localName="IdProp" propertyDefinitionId="IdProp"/> <cmis:propertyUri queryName="UriProp" displayName="Sample Uri Property" localName="UriProp" propertyDefinitionId="UriProp"/> <cmis:propertyDateTime queryName="DateTimePropMV" displayName="Sample DateTime multi-value Property" localName="DateTimePropMV" propertyDefinitionId="DateTimePropMV"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"> <cmis:value>series-id</cmis:value> </cmis:propertyId> <cmis:propertyDecimal queryName="DecimalProp" displayName="Sample Decimal Property" localName="DecimalProp" propertyDefinitionId="DecimalProp"/> <cmis:propertyUri queryName="UriPropMV" displayName="Sample Uri multi-value Property" localName="UriPropMV" propertyDefinitionId="UriPropMV"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"/> <cmis:propertyBoolean queryName="BooleanProp" displayName="Sample Boolean Property" localName="BooleanProp" propertyDefinitionId="BooleanProp"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="IdPropMV" displayName="Sample Id Html multi-value Property" localName="IdPropMV" propertyDefinitionId="IdPropMV"/> <cmis:propertyString queryName="PickListProp" displayName="Sample Pick List Property" localName="PickListProp" propertyDefinitionId="PickListProp"> <cmis:value>blue</cmis:value> </cmis:propertyString> <cmis:propertyHtml queryName="HtmlPropMV" displayName="Sample Html multi-value Property" localName="HtmlPropMV" propertyDefinitionId="HtmlPropMV"/> <cmis:propertyInteger queryName="IntProp" displayName="Sample Int Property" localName="IntProp" propertyDefinitionId="IntProp"/> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Test Document</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="StringProp" displayName="Sample String Property" localName="StringProp" propertyDefinitionId="StringProp"> <cmis:value>My Doc StringProperty 6</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>some-change-token</cmis:value> </cmis:propertyString> <cmis:propertyDecimal queryName="DecimalPropMV" displayName="Sample Decimal multi-value Property" localName="DecimalPropMV" propertyDefinitionId="DecimalPropMV"/> <cmis:propertyDateTime queryName="DateTimeProp" displayName="Sample DateTime Property" localName="DateTimeProp" propertyDefinitionId="DateTimeProp"/> <cmis:propertyBoolean queryName="BooleanPropMV" displayName="Sample Boolean multi-value Property" localName="BooleanPropMV" propertyDefinitionId="BooleanPropMV"/> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>test-document</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyInteger queryName="IntPropMV" displayName="Sample Int multi-value Property" localName="IntPropMV" propertyDefinitionId="IntPropMV"/> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> <cmis:allowableActions> <cmis:canDeleteObject>true</cmis:canDeleteObject> <cmis:canUpdateProperties>true</cmis:canUpdateProperties> <cmis:canGetFolderTree>false</cmis:canGetFolderTree> <cmis:canGetProperties>true</cmis:canGetProperties> <cmis:canGetObjectRelationships>false</cmis:canGetObjectRelationships> <cmis:canGetObjectParents>true</cmis:canGetObjectParents> <cmis:canGetFolderParent>false</cmis:canGetFolderParent> <cmis:canGetDescendants>false</cmis:canGetDescendants> <cmis:canMoveObject>true</cmis:canMoveObject> <cmis:canDeleteContentStream>true</cmis:canDeleteContentStream> <cmis:canCheckOut>true</cmis:canCheckOut> <cmis:canCancelCheckOut>false</cmis:canCancelCheckOut> <cmis:canCheckIn>false</cmis:canCheckIn> <cmis:canSetContentStream>true</cmis:canSetContentStream> <cmis:canGetAllVersions>true</cmis:canGetAllVersions> <cmis:canAddObjectToFolder>true</cmis:canAddObjectToFolder> <cmis:canRemoveObjectFromFolder>true</cmis:canRemoveObjectFromFolder> <cmis:canGetContentStream>true</cmis:canGetContentStream> <cmis:canApplyPolicy>false</cmis:canApplyPolicy> <cmis:canGetAppliedPolicies>false</cmis:canGetAppliedPolicies> <cmis:canRemovePolicy>false</cmis:canRemovePolicy> <cmis:canGetChildren>false</cmis:canGetChildren> <cmis:canCreateDocument>false</cmis:canCreateDocument> <cmis:canCreateFolder>false</cmis:canCreateFolder> <cmis:canCreateRelationship>false</cmis:canCreateRelationship> <cmis:canDeleteTree>false</cmis:canDeleteTree> <cmis:canGetRenditions>false</cmis:canGetRenditions> <cmis:canGetACL>false</cmis:canGetACL> <cmis:canApplyACL>false</cmis:canApplyACL> </cmis:allowableActions> <exampleExtension:exampleExtension xmlns="http://mockup/cmis/extension" xmlns:exampleExtension="http://mockup/cmis/extension"> <objectId xmlns:ns0="http://mockup/cmis/extension" ns0:type="DocumentLevel2">test-document</objectId> <name>Test Document</name> </exampleExtension:exampleExtension> </cmism:object> </cmism:getObjectResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/delete-tree.http���������������������������������������������������0000664�0001750�0001750�00000002536�13407173247�016566� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:deleteTreeResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:failedToDelete> <cmism:objectIds>bad-delete</cmism:objectIds> </cmism:failedToDelete> </cmism:deleteTreeResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/set-content-stream.http��������������������������������������������0000664�0001750�0001750�00000002605�13407173247�020120� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:setContentStreamResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:objectId>test-document</cmism:objectId> <cmism:changeToken>set-content-token</cmism:changeToken> </cmism:setContentStreamResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ���������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/type-document.http�������������������������������������������������0000664�0001750�0001750�00000061271�13407173247�017165� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getTypeDefinitionResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:type> <cmis:id>cmis:document</cmis:id> <cmis:localName>cmis:document</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>CMIS Document</cmis:displayName> <cmis:queryName>cmis:document</cmis:queryName> <cmis:description>Description of CMIS Document Type</cmis:description> <cmis:baseId>cmis:document</cmis:baseId> <cmis:creatable>true</cmis:creatable> <cmis:fileable>true</cmis:fileable> <cmis:queryable>false</cmis:queryable> <cmis:fulltextIndexed>false</cmis:fulltextIndexed> <cmis:includedInSupertypeQuery>true</cmis:includedInSupertypeQuery> <cmis:controllablePolicy>false</cmis:controllablePolicy> <cmis:controllableACL>true</cmis:controllableACL> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isLatestMajorVersion</cmis:id> <cmis:localName>cmis:isLatestMajorVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Latest Major Version</cmis:displayName> <cmis:queryName>cmis:isLatestMajorVersion</cmis:queryName> <cmis:description>This is a Is Latest Major Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:contentStreamId</cmis:id> <cmis:localName>cmis:contentStreamId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Stream Id</cmis:displayName> <cmis:queryName>cmis:contentStreamId</cmis:queryName> <cmis:description>This is a Stream Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyIntegerDefinition> <cmis:id>cmis:contentStreamLength</cmis:id> <cmis:localName>cmis:contentStreamLength</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Content Length</cmis:displayName> <cmis:queryName>cmis:contentStreamLength</cmis:queryName> <cmis:description>This is a Content Length property.</cmis:description> <cmis:propertyType>integer</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIntegerDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:versionSeriesCheckedOutBy</cmis:id> <cmis:localName>cmis:versionSeriesCheckedOutBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out By</cmis:displayName> <cmis:queryName>cmis:versionSeriesCheckedOutBy</cmis:queryName> <cmis:description>This is a Checked Out By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectTypeId</cmis:id> <cmis:localName>cmis:objectTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Type-Id</cmis:displayName> <cmis:queryName>cmis:objectTypeId</cmis:queryName> <cmis:description>This is a Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>oncreate</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:versionSeriesCheckedOutId</cmis:id> <cmis:localName>cmis:versionSeriesCheckedOutId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out Id</cmis:displayName> <cmis:queryName>cmis:versionSeriesCheckedOutId</cmis:queryName> <cmis:description>This is a Checked Out Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:name</cmis:id> <cmis:localName>cmis:name</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Name</cmis:displayName> <cmis:queryName>cmis:name</cmis:queryName> <cmis:description>This is a Name property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:contentStreamMimeType</cmis:id> <cmis:localName>cmis:contentStreamMimeType</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Mime Type</cmis:displayName> <cmis:queryName>cmis:contentStreamMimeType</cmis:queryName> <cmis:description>This is a Mime Type property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:versionSeriesId</cmis:id> <cmis:localName>cmis:versionSeriesId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Version Series Id</cmis:displayName> <cmis:queryName>cmis:versionSeriesId</cmis:queryName> <cmis:description>This is a Version Series Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:creationDate</cmis:id> <cmis:localName>cmis:creationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Creation Date</cmis:displayName> <cmis:queryName>cmis:creationDate</cmis:queryName> <cmis:description>This is a Creation Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:changeToken</cmis:id> <cmis:localName>cmis:changeToken</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Change Token</cmis:displayName> <cmis:queryName>cmis:changeToken</cmis:queryName> <cmis:description>This is a Change Token property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:versionLabel</cmis:id> <cmis:localName>cmis:versionLabel</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Version Label</cmis:displayName> <cmis:queryName>cmis:versionLabel</cmis:queryName> <cmis:description>This is a Version Label property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isLatestVersion</cmis:id> <cmis:localName>cmis:isLatestVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Latest Version</cmis:displayName> <cmis:queryName>cmis:isLatestVersion</cmis:queryName> <cmis:description>This is a Is Latest Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isVersionSeriesCheckedOut</cmis:id> <cmis:localName>cmis:isVersionSeriesCheckedOut</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out</cmis:displayName> <cmis:queryName>cmis:isVersionSeriesCheckedOut</cmis:queryName> <cmis:description>This is a Checked Out property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:lastModifiedBy</cmis:id> <cmis:localName>cmis:lastModifiedBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modified By</cmis:displayName> <cmis:queryName>cmis:lastModifiedBy</cmis:queryName> <cmis:description>This is a Modified By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:createdBy</cmis:id> <cmis:localName>cmis:createdBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Created By</cmis:displayName> <cmis:queryName>cmis:createdBy</cmis:queryName> <cmis:description>This is a Created By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:checkinComment</cmis:id> <cmis:localName>cmis:checkinComment</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checkin Comment</cmis:displayName> <cmis:queryName>cmis:checkinComment</cmis:queryName> <cmis:description>This is a Checkin Comment property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectId</cmis:id> <cmis:localName>cmis:objectId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Object Id</cmis:displayName> <cmis:queryName>cmis:objectId</cmis:queryName> <cmis:description>This is a Object Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isImmutable</cmis:id> <cmis:localName>cmis:isImmutable</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Immutable</cmis:displayName> <cmis:queryName>cmis:isImmutable</cmis:queryName> <cmis:description>This is a Immutable property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isMajorVersion</cmis:id> <cmis:localName>cmis:isMajorVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Major Version</cmis:displayName> <cmis:queryName>cmis:isMajorVersion</cmis:queryName> <cmis:description>This is a Is Major Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:baseTypeId</cmis:id> <cmis:localName>cmis:baseTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Base-Type-Id</cmis:displayName> <cmis:queryName>cmis:baseTypeId</cmis:queryName> <cmis:description>This is a Base-Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:contentStreamFileName</cmis:id> <cmis:localName>cmis:contentStreamFileName</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>File Name</cmis:displayName> <cmis:queryName>cmis:contentStreamFileName</cmis:queryName> <cmis:description>This is a File Name property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:lastModificationDate</cmis:id> <cmis:localName>cmis:lastModificationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modification Date</cmis:displayName> <cmis:queryName>cmis:lastModificationDate</cmis:queryName> <cmis:description>This is a Modification Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:versionable>false</cmis:versionable> <cmis:contentStreamAllowed>allowed</cmis:contentStreamAllowed> </cmism:type> </cmism:getTypeDefinitionResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/type-bad.http������������������������������������������������������0000664�0001750�0001750�00000002760�13407173247�016073� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*abd9e41c-b3aa-40a7-a73a-997c472010e8@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:abd9e41c-b3aa-40a7-a73a-997c472010e8";start-info="text/xml" --uuid:abd9e41c-b3aa-40a7-a73a-997c472010e8 Content-Id: <rootpart*abd9e41c-b3aa-40a7-a73a-997c472010e8@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version="1.0" encoding="UTF-8"?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-30T19:54:27Z</Created> <Expires>2013-10-01T19:54:27Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <S:Fault> <faultcode>S:Server</faultcode> <faultstring>Type 'bad' not found</faultstring> <detail> <cmisFault:cmisFault xmlns="http://docs.oasis-open.org/ns/cmis/messaging/200908/" xmlns:cmisFault="http://docs.oasis-open.org/ns/cmis/messaging/200908/" xmlns:ns2="http://docs.oasis-open.org/ns/cmis/core/200908/"> <type>objectNotFound</type> <code>562</code> <message>Unknown type id: 'bad'</message> </cmisFault:cmisFault> </detail> </S:Fault> </S:Body> </S:Envelope> --uuid:abd9e41c-b3aa-40a7-a73a-997c472010e8-- ����������������libcmis-0.5.2/qa/libcmis/data/ws/cancel-checkout.http�����������������������������������������������0000664�0001750�0001750�00000002332�13407173247�017411� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:cancelCheckOutResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"/> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/checkout.http������������������������������������������������������0000664�0001750�0001750�00000002553�13407173247�016173� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:checkOutResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:objectId>working-copy</cmism:objectId> <cmism:contentCopied>true</cmism:contentCopied> </cmism:checkOutResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- �����������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/root-folder.http���������������������������������������������������0000664�0001750�0001750�00000014634�13407173247�016625� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getObjectResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:object> <cmis:properties> <cmis:propertyId queryName="cmis:allowedChildObjectTypeIds" displayName="Allowed Child Types" localName="cmis:allowedChildObjectTypeIds" propertyDefinitionId="cmis:allowedChildObjectTypeIds"> <cmis:value>*</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:path" displayName="Path" localName="cmis:path" propertyDefinitionId="cmis:path"> <cmis:value>/</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Root Folder</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>root-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2012-11-29T16:14:47.019Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1354205687020</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyId queryName="cmis:parentId" displayName="Parent Id" localName="cmis:parentId" propertyDefinitionId="cmis:parentId"/> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2012-11-29T16:14:47.020Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> <cmis:allowableActions> <cmis:canDeleteObject>true</cmis:canDeleteObject> <cmis:canUpdateProperties>true</cmis:canUpdateProperties> <cmis:canGetFolderTree>true</cmis:canGetFolderTree> <cmis:canGetProperties>true</cmis:canGetProperties> <cmis:canGetObjectRelationships>false</cmis:canGetObjectRelationships> <cmis:canGetObjectParents>true</cmis:canGetObjectParents> <cmis:canGetFolderParent>true</cmis:canGetFolderParent> <cmis:canGetDescendants>true</cmis:canGetDescendants> <cmis:canMoveObject>true</cmis:canMoveObject> <cmis:canDeleteContentStream>false</cmis:canDeleteContentStream> <cmis:canCheckOut>false</cmis:canCheckOut> <cmis:canCancelCheckOut>false</cmis:canCancelCheckOut> <cmis:canCheckIn>false</cmis:canCheckIn> <cmis:canSetContentStream>false</cmis:canSetContentStream> <cmis:canGetAllVersions>false</cmis:canGetAllVersions> <cmis:canAddObjectToFolder>false</cmis:canAddObjectToFolder> <cmis:canRemoveObjectFromFolder>false</cmis:canRemoveObjectFromFolder> <cmis:canGetContentStream>false</cmis:canGetContentStream> <cmis:canApplyPolicy>false</cmis:canApplyPolicy> <cmis:canGetAppliedPolicies>false</cmis:canGetAppliedPolicies> <cmis:canRemovePolicy>false</cmis:canRemovePolicy> <cmis:canGetChildren>true</cmis:canGetChildren> <cmis:canCreateDocument>true</cmis:canCreateDocument> <cmis:canCreateFolder>true</cmis:canCreateFolder> <cmis:canCreateRelationship>false</cmis:canCreateRelationship> <cmis:canDeleteTree>true</cmis:canDeleteTree> <cmis:canGetRenditions>false</cmis:canGetRenditions> <cmis:canGetACL>false</cmis:canGetACL> <cmis:canApplyACL>false</cmis:canApplyACL> </cmis:allowableActions> </cmism:object> </cmism:getObjectResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ����������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/CMISWS-Service.wsdl������������������������������������������������0000664�0001750�0001750�00000132256�13407173247�016767� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������<?xml version="1.0" encoding="utf-8"?> <!-- Content Management Interoperability Services (CMIS) Version 1.1 Committee Specification 01 12 November 2012 Copyright (c) OASIS Open 2012. All Rights Reserved. Source: http://docs.oasis-open.org/cmis/CMIS/v1.1/cs01/schema/ --> <!-- CMIS 1.1 WSDL --> <definitions xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/" xmlns:cmisw="http://docs.oasis-open.org/ns/cmis/ws/200908/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:ns="http://schemas.xmlsoap.org/soap/encoding/" xmlns:jaxws="http://java.sun.com/xml/ns/jaxws" targetNamespace="http://docs.oasis-open.org/ns/cmis/ws/200908/" name="CMISWebServices"> <types> <xsd:schema elementFormDefault="qualified" targetNamespace="http://docs.oasis-open.org/ns/cmis/ws/200908/"> <xsd:import schemaLocation="CMIS-Core.xsd" namespace="http://docs.oasis-open.org/ns/cmis/core/200908/"/> <xsd:import schemaLocation="CMIS-Messaging.xsd" namespace="http://docs.oasis-open.org/ns/cmis/messaging/200908/"/> </xsd:schema> </types> <message name="cmisException"> <part name="fault" element="cmism:cmisFault"/> </message> <message name="getACLRequest"> <part name="parameters" element="cmism:getACL"/> </message> <message name="getACLResponse"> <part name="parameters" element="cmism:getACLResponse"/> </message> <message name="applyACLRequest"> <part name="parameters" element="cmism:applyACL"/> </message> <message name="applyACLResponse"> <part name="parameters" element="cmism:applyACLResponse"/> </message> <message name="queryRequest"> <part name="parameters" element="cmism:query"/> </message> <message name="queryResponse"> <part name="parameters" element="cmism:queryResponse"/> </message> <message name="getContentChangesRequest"> <part name="parameters" element="cmism:getContentChanges"/> </message> <message name="getContentChangesResponse"> <part name="parameters" element="cmism:getContentChangesResponse"/> </message> <message name="addObjectToFolderRequest"> <part name="parameters" element="cmism:addObjectToFolder"/> </message> <message name="addObjectToFolderResponse"> <part name="parameters" element="cmism:addObjectToFolderResponse"/> </message> <message name="removeObjectFromFolderRequest"> <part name="parameters" element="cmism:removeObjectFromFolder"/> </message> <message name="removeObjectFromFolderResponse"> <part name="parameters" element="cmism:removeObjectFromFolderResponse"/> </message> <message name="getDescendantsRequest"> <part name="parameters" element="cmism:getDescendants"/> </message> <message name="getDescendantsResponse"> <part name="parameters" element="cmism:getDescendantsResponse"/> </message> <message name="getChildrenRequest"> <part name="parameters" element="cmism:getChildren"/> </message> <message name="getChildrenResponse"> <part name="parameters" element="cmism:getChildrenResponse"/> </message> <message name="getFolderParentRequest"> <part name="parameters" element="cmism:getFolderParent"/> </message> <message name="getFolderParentResponse"> <part name="parameters" element="cmism:getFolderParentResponse"/> </message> <message name="getObjectParentsRequest"> <part name="parameters" element="cmism:getObjectParents"/> </message> <message name="getObjectParentsResponse"> <part name="parameters" element="cmism:getObjectParentsResponse"/> </message> <message name="getRenditionsRequest"> <part name="parameters" element="cmism:getRenditions"/> </message> <message name="getRenditionsResponse"> <part name="parameters" element="cmism:getRenditionsResponse"/> </message> <message name="getCheckedOutDocsRequest"> <part name="parameters" element="cmism:getCheckedOutDocs"/> </message> <message name="getCheckedOutDocsResponse"> <part name="parameters" element="cmism:getCheckedOutDocsResponse"/> </message> <message name="createDocumentRequest"> <part name="parameters" element="cmism:createDocument"/> </message> <message name="createDocumentResponse"> <part name="parameters" element="cmism:createDocumentResponse"/> </message> <message name="createDocumentFromSourceRequest"> <part name="parameters" element="cmism:createDocumentFromSource"/> </message> <message name="createDocumentFromSourceResponse"> <part name="parameters" element="cmism:createDocumentFromSourceResponse"/> </message> <message name="createFolderRequest"> <part name="parameters" element="cmism:createFolder"/> </message> <message name="createFolderResponse"> <part name="parameters" element="cmism:createFolderResponse"/> </message> <message name="createRelationshipRequest"> <part name="parameters" element="cmism:createRelationship"/> </message> <message name="createRelationshipResponse"> <part name="parameters" element="cmism:createRelationshipResponse"/> </message> <message name="createPolicyRequest"> <part name="parameters" element="cmism:createPolicy"/> </message> <message name="createPolicyResponse"> <part name="parameters" element="cmism:createPolicyResponse"/> </message> <message name="createItemRequest"> <part name="parameters" element="cmism:createItem"/> </message> <message name="createItemResponse"> <part name="parameters" element="cmism:createItemResponse"/> </message> <message name="getAllowableActionsRequest"> <part name="parameters" element="cmism:getAllowableActions"/> </message> <message name="getAllowableActionsResponse"> <part name="parameters" element="cmism:getAllowableActionsResponse"/> </message> <message name="getObjectRequest"> <part name="parameters" element="cmism:getObject"/> </message> <message name="getObjectResponse"> <part name="parameters" element="cmism:getObjectResponse"/> </message> <message name="getPropertiesRequest"> <part name="parameters" element="cmism:getProperties"/> </message> <message name="getPropertiesResponse"> <part name="parameters" element="cmism:getPropertiesResponse"/> </message> <message name="getObjectByPathRequest"> <part name="parameters" element="cmism:getObjectByPath"/> </message> <message name="getObjectByPathResponse"> <part name="parameters" element="cmism:getObjectByPathResponse"/> </message> <message name="getContentStreamRequest"> <part name="parameters" element="cmism:getContentStream"/> </message> <message name="getContentStreamResponse"> <part name="parameters" element="cmism:getContentStreamResponse"/> </message> <message name="updatePropertiesRequest"> <part name="parameters" element="cmism:updateProperties"/> </message> <message name="updatePropertiesResponse"> <part name="parameters" element="cmism:updatePropertiesResponse"/> </message> <message name="bulkUpdatePropertiesRequest"> <part name="parameters" element="cmism:bulkUpdateProperties"/> </message> <message name="bulkUpdatePropertiesResponse"> <part name="parameters" element="cmism:bulkUpdatePropertiesResponse"/> </message> <message name="moveObjectRequest"> <part name="parameters" element="cmism:moveObject"/> </message> <message name="moveObjectResponse"> <part name="parameters" element="cmism:moveObjectResponse"/> </message> <message name="deleteObjectRequest"> <part name="parameters" element="cmism:deleteObject"/> </message> <message name="deleteObjectResponse"> <part name="parameters" element="cmism:deleteObjectResponse"/> </message> <message name="deleteTreeRequest"> <part name="parameters" element="cmism:deleteTree"/> </message> <message name="deleteTreeResponse"> <part name="parameters" element="cmism:deleteTreeResponse"/> </message> <message name="setContentStreamRequest"> <part name="parameters" element="cmism:setContentStream"/> </message> <message name="setContentStreamResponse"> <part name="parameters" element="cmism:setContentStreamResponse"/> </message> <message name="appendContentStreamRequest"> <part name="parameters" element="cmism:appendContentStream"/> </message> <message name="appendContentStreamResponse"> <part name="parameters" element="cmism:appendContentStreamResponse"/> </message> <message name="deleteContentStreamRequest"> <part name="parameters" element="cmism:deleteContentStream"/> </message> <message name="deleteContentStreamResponse"> <part name="parameters" element="cmism:deleteContentStreamResponse"/> </message> <message name="applyPolicyRequest"> <part name="parameters" element="cmism:applyPolicy"/> </message> <message name="applyPolicyResponse"> <part name="parameters" element="cmism:applyPolicyResponse"/> </message> <message name="removePolicyRequest"> <part name="parameters" element="cmism:removePolicy"/> </message> <message name="removePolicyResponse"> <part name="parameters" element="cmism:removePolicyResponse"/> </message> <message name="getAppliedPoliciesRequest"> <part name="parameters" element="cmism:getAppliedPolicies"/> </message> <message name="getAppliedPoliciesResponse"> <part name="parameters" element="cmism:getAppliedPoliciesResponse"/> </message> <message name="getObjectRelationshipsRequest"> <part name="parameters" element="cmism:getObjectRelationships"/> </message> <message name="getObjectRelationshipsResponse"> <part name="parameters" element="cmism:getObjectRelationshipsResponse"/> </message> <message name="getRepositoriesRequest"> <part name="parameters" element="cmism:getRepositories"/> </message> <message name="getRepositoriesResponse"> <part name="parameters" element="cmism:getRepositoriesResponse"/> </message> <message name="getRepositoryInfoRequest"> <part name="parameters" element="cmism:getRepositoryInfo"/> </message> <message name="getRepositoryInfoResponse"> <part name="parameters" element="cmism:getRepositoryInfoResponse"/> </message> <message name="getTypeChildrenRequest"> <part name="parameters" element="cmism:getTypeChildren"/> </message> <message name="getTypeChildrenResponse"> <part name="parameters" element="cmism:getTypeChildrenResponse"/> </message> <message name="getTypeDescendantsRequest"> <part name="parameters" element="cmism:getTypeDescendants"/> </message> <message name="getTypeDescendantsResponse"> <part name="parameters" element="cmism:getTypeDescendantsResponse"/> </message> <message name="getTypeDefinitionRequest"> <part name="parameters" element="cmism:getTypeDefinition"/> </message> <message name="getTypeDefinitionResponse"> <part name="parameters" element="cmism:getTypeDefinitionResponse"/> </message> <message name="createTypeRequest"> <part name="parameters" element="cmism:createType"/> </message> <message name="createTypeResponse"> <part name="parameters" element="cmism:createTypeResponse"/> </message> <message name="updateTypeRequest"> <part name="parameters" element="cmism:updateType"/> </message> <message name="updateTypeResponse"> <part name="parameters" element="cmism:updateTypeResponse"/> </message> <message name="deleteTypeRequest"> <part name="parameters" element="cmism:deleteType"/> </message> <message name="deleteTypeResponse"> <part name="parameters" element="cmism:deleteTypeResponse"/> </message> <message name="checkOutRequest"> <part name="parameters" element="cmism:checkOut"/> </message> <message name="checkOutResponse"> <part name="parameters" element="cmism:checkOutResponse"/> </message> <message name="cancelCheckOutRequest"> <part name="parameters" element="cmism:cancelCheckOut"/> </message> <message name="cancelCheckOutResponse"> <part name="parameters" element="cmism:cancelCheckOutResponse"/> </message> <message name="checkInRequest"> <part name="parameters" element="cmism:checkIn"/> </message> <message name="checkInResponse"> <part name="parameters" element="cmism:checkInResponse"/> </message> <message name="getObjectOfLatestVersionRequest"> <part name="parameters" element="cmism:getObjectOfLatestVersion"/> </message> <message name="getObjectOfLatestVersionResponse"> <part name="parameters" element="cmism:getObjectOfLatestVersionResponse"/> </message> <message name="getPropertiesOfLatestVersionRequest"> <part name="parameters" element="cmism:getPropertiesOfLatestVersion"/> </message> <message name="getPropertiesOfLatestVersionResponse"> <part name="parameters" element="cmism:getPropertiesOfLatestVersionResponse"/> </message> <message name="getAllVersionsRequest"> <part name="parameters" element="cmism:getAllVersions"/> </message> <message name="getAllVersionsResponse"> <part name="parameters" element="cmism:getAllVersionsResponse"/> </message> <message name="getFolderTreeRequest"> <part name="parameters" element="cmism:getFolderTree"/> </message> <message name="getFolderTreeResponse"> <part name="parameters" element="cmism:getFolderTreeResponse"/> </message> <portType name="DiscoveryServicePort"> <operation name="query"> <input message="cmisw:queryRequest"/> <output message="cmisw:queryResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getContentChanges"> <input message="cmisw:getContentChangesRequest"/> <output message="cmisw:getContentChangesResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> </portType> <portType name="MultiFilingServicePort"> <operation name="addObjectToFolder"> <input message="cmisw:addObjectToFolderRequest"/> <output message="cmisw:addObjectToFolderResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="removeObjectFromFolder"> <input message="cmisw:removeObjectFromFolderRequest"/> <output message="cmisw:removeObjectFromFolderResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> </portType> <portType name="NavigationServicePort"> <operation name="getDescendants"> <input message="cmisw:getDescendantsRequest"/> <output message="cmisw:getDescendantsResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getChildren"> <input message="cmisw:getChildrenRequest"/> <output message="cmisw:getChildrenResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getFolderParent"> <input message="cmisw:getFolderParentRequest"/> <output message="cmisw:getFolderParentResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getFolderTree"> <input message="cmisw:getFolderTreeRequest"/> <output message="cmisw:getFolderTreeResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getObjectParents"> <input message="cmisw:getObjectParentsRequest"/> <output message="cmisw:getObjectParentsResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getCheckedOutDocs"> <input message="cmisw:getCheckedOutDocsRequest"/> <output message="cmisw:getCheckedOutDocsResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> </portType> <portType name="ObjectServicePort"> <operation name="createDocument"> <input message="cmisw:createDocumentRequest"/> <output message="cmisw:createDocumentResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="createDocumentFromSource"> <input message="cmisw:createDocumentFromSourceRequest"/> <output message="cmisw:createDocumentFromSourceResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="createFolder"> <input message="cmisw:createFolderRequest"/> <output message="cmisw:createFolderResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="createRelationship"> <input message="cmisw:createRelationshipRequest"/> <output message="cmisw:createRelationshipResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="createPolicy"> <input message="cmisw:createPolicyRequest"/> <output message="cmisw:createPolicyResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="createItem"> <input message="cmisw:createItemRequest"/> <output message="cmisw:createItemResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getAllowableActions"> <input message="cmisw:getAllowableActionsRequest"/> <output message="cmisw:getAllowableActionsResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getObject"> <input message="cmisw:getObjectRequest"/> <output message="cmisw:getObjectResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getProperties"> <input message="cmisw:getPropertiesRequest"/> <output message="cmisw:getPropertiesResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getRenditions"> <input message="cmisw:getRenditionsRequest"/> <output message="cmisw:getRenditionsResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getObjectByPath"> <input message="cmisw:getObjectByPathRequest"/> <output message="cmisw:getObjectByPathResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getContentStream"> <input message="cmisw:getContentStreamRequest"/> <output message="cmisw:getContentStreamResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="updateProperties"> <input message="cmisw:updatePropertiesRequest"/> <output message="cmisw:updatePropertiesResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="bulkUpdateProperties"> <input message="cmisw:bulkUpdatePropertiesRequest"/> <output message="cmisw:bulkUpdatePropertiesResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="moveObject"> <input message="cmisw:moveObjectRequest"/> <output message="cmisw:moveObjectResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="deleteObject"> <input message="cmisw:deleteObjectRequest"/> <output message="cmisw:deleteObjectResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="deleteTree"> <input message="cmisw:deleteTreeRequest"/> <output message="cmisw:deleteTreeResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="setContentStream"> <input message="cmisw:setContentStreamRequest"/> <output message="cmisw:setContentStreamResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="appendContentStream"> <input message="cmisw:appendContentStreamRequest"/> <output message="cmisw:appendContentStreamResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="deleteContentStream"> <input message="cmisw:deleteContentStreamRequest"/> <output message="cmisw:deleteContentStreamResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> </portType> <portType name="PolicyServicePort"> <operation name="applyPolicy"> <input message="cmisw:applyPolicyRequest"/> <output message="cmisw:applyPolicyResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="removePolicy"> <input message="cmisw:removePolicyRequest"/> <output message="cmisw:removePolicyResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getAppliedPolicies"> <input message="cmisw:getAppliedPoliciesRequest"/> <output message="cmisw:getAppliedPoliciesResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> </portType> <portType name="RelationshipServicePort"> <operation name="getObjectRelationships"> <input message="cmisw:getObjectRelationshipsRequest"/> <output message="cmisw:getObjectRelationshipsResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> </portType> <portType name="RepositoryServicePort"> <operation name="getRepositories"> <input message="cmisw:getRepositoriesRequest"/> <output message="cmisw:getRepositoriesResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getRepositoryInfo"> <input message="cmisw:getRepositoryInfoRequest"/> <output message="cmisw:getRepositoryInfoResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getTypeChildren"> <input message="cmisw:getTypeChildrenRequest"/> <output message="cmisw:getTypeChildrenResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getTypeDescendants"> <input message="cmisw:getTypeDescendantsRequest"/> <output message="cmisw:getTypeDescendantsResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getTypeDefinition"> <input message="cmisw:getTypeDefinitionRequest"/> <output message="cmisw:getTypeDefinitionResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="createType"> <input message="cmisw:createTypeRequest"/> <output message="cmisw:createTypeResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="updateType"> <input message="cmisw:updateTypeRequest"/> <output message="cmisw:updateTypeResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="deleteType"> <input message="cmisw:deleteTypeRequest"/> <output message="cmisw:deleteTypeResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> </portType> <portType name="VersioningServicePort"> <operation name="checkOut"> <input message="cmisw:checkOutRequest"/> <output message="cmisw:checkOutResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="cancelCheckOut"> <input message="cmisw:cancelCheckOutRequest"/> <output message="cmisw:cancelCheckOutResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="checkIn"> <input message="cmisw:checkInRequest"/> <output message="cmisw:checkInResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getObjectOfLatestVersion"> <input message="cmisw:getObjectOfLatestVersionRequest"/> <output message="cmisw:getObjectOfLatestVersionResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getPropertiesOfLatestVersion"> <input message="cmisw:getPropertiesOfLatestVersionRequest"/> <output message="cmisw:getPropertiesOfLatestVersionResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="getAllVersions"> <input message="cmisw:getAllVersionsRequest"/> <output message="cmisw:getAllVersionsResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> </portType> <portType name="ACLServicePort"> <operation name="getACL"> <input message="cmisw:getACLRequest"/> <output message="cmisw:getACLResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> <operation name="applyACL"> <input message="cmisw:applyACLRequest"/> <output message="cmisw:applyACLResponse"/> <fault message="cmisw:cmisException" name="cmisException"/> </operation> </portType> <binding name="DiscoveryServicePortBinding" type="cmisw:DiscoveryServicePort"> <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> <operation name="query"> <soap:operation soapAction="query"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getContentChanges"> <soap:operation soapAction="getContentChanges"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> </binding> <binding name="MultiFilingServicePortBinding" type="cmisw:MultiFilingServicePort"> <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> <operation name="addObjectToFolder"> <soap:operation soapAction="addObjectToFolder"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="removeObjectFromFolder"> <soap:operation soapAction="removeObjectFromFolder"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> </binding> <binding name="NavigationServicePortBinding" type="cmisw:NavigationServicePort"> <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> <operation name="getDescendants"> <soap:operation soapAction="getDescendants"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getChildren"> <soap:operation soapAction="getChildren"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getFolderParent"> <soap:operation soapAction="getFolderParent"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getFolderTree"> <soap:operation soapAction="getFolderTree"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getObjectParents"> <soap:operation soapAction="getObjectParents"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getCheckedOutDocs"> <soap:operation soapAction="getCheckedOutDocs"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> </binding> <binding name="ObjectServicePortBinding" type="cmisw:ObjectServicePort"> <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> <operation name="createDocument"> <soap:operation soapAction="createDocument"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="createDocumentFromSource"> <soap:operation soapAction="createDocumentFromSource"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="createFolder"> <soap:operation soapAction="createFolder"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="createRelationship"> <soap:operation soapAction="createRelationship"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="createPolicy"> <soap:operation soapAction="createPolicy"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="createItem"> <soap:operation soapAction=""/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getAllowableActions"> <soap:operation soapAction="getAllowableActions"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getObject"> <soap:operation soapAction="getObject"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getProperties"> <soap:operation soapAction="getProperties"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getRenditions"> <soap:operation soapAction="getRenditions"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getObjectByPath"> <soap:operation soapAction="getObjectByPath"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getContentStream"> <soap:operation soapAction="getContentStream"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="updateProperties"> <soap:operation soapAction="updateProperties"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="bulkUpdateProperties"> <soap:operation soapAction="bulkUpdateProperties"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="moveObject"> <soap:operation soapAction="moveObject"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="deleteObject"> <soap:operation soapAction="deleteObject"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="deleteTree"> <soap:operation soapAction="deleteTree"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="setContentStream"> <soap:operation soapAction="setContentStream"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="appendContentStream"> <soap:operation soapAction="appendContentStream"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="deleteContentStream"> <soap:operation soapAction="deleteContentStream"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> </binding> <binding name="PolicyServicePortBinding" type="cmisw:PolicyServicePort"> <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> <operation name="applyPolicy"> <soap:operation soapAction="applyPolicy"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="removePolicy"> <soap:operation soapAction="removePolicy"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getAppliedPolicies"> <soap:operation soapAction="getAppliedPolicies"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> </binding> <binding name="RelationshipServicePortBinding" type="cmisw:RelationshipServicePort"> <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> <operation name="getObjectRelationships"> <soap:operation soapAction="getObjectRelationships"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> </binding> <binding name="RepositoryServicePortBinding" type="cmisw:RepositoryServicePort"> <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> <operation name="getRepositories"> <soap:operation soapAction="getRepositories"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getRepositoryInfo"> <soap:operation soapAction="getRepositoryInfo"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getTypeChildren"> <soap:operation soapAction="getTypeChildren"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getTypeDescendants"> <soap:operation soapAction="getTypeDescendants"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getTypeDefinition"> <soap:operation soapAction="getTypeDefinition"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="createType"> <soap:operation soapAction="createType"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="updateType"> <soap:operation soapAction="updateType"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="deleteType"> <soap:operation soapAction="deleteType"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> </binding> <binding name="VersioningServicePortBinding" type="cmisw:VersioningServicePort"> <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> <operation name="checkOut"> <soap:operation soapAction="checkOut"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="cancelCheckOut"> <soap:operation soapAction="cancelCheckOut"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="checkIn"> <soap:operation soapAction="checkIn"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getObjectOfLatestVersion"> <soap:operation soapAction="getObjectOfLatestVersion"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getPropertiesOfLatestVersion"> <soap:operation soapAction="getPropertiesOfLatestVersion"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="getAllVersions"> <soap:operation soapAction="getAllVersions"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> </binding> <binding name="ACLServicePortBinding" type="cmisw:ACLServicePort"> <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> <operation name="getACL"> <soap:operation soapAction="getACL"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> <operation name="applyACL"> <soap:operation soapAction="applyACL"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> <fault name="cmisException"> <soap:fault name="cmisException" use="literal"/> </fault> </operation> </binding> <service name="DiscoveryService"> <port name="DiscoveryServicePort" binding="cmisw:DiscoveryServicePortBinding"> <soap:address location="http://mockup/ws/services/DiscoveryService"/> </port> </service> <service name="MultiFilingService"> <port name="MultiFilingServicePort" binding="cmisw:MultiFilingServicePortBinding"> <soap:address location="http://mockup/ws/services/MultiFilingService"/> </port> </service> <service name="NavigationService"> <port name="NavigationServicePort" binding="cmisw:NavigationServicePortBinding"> <soap:address location="http://mockup/ws/services/NavigationService"/> </port> </service> <service name="ObjectService"> <port name="ObjectServicePort" binding="cmisw:ObjectServicePortBinding"> <soap:address location="http://mockup/ws/services/ObjectService"/> </port> </service> <service name="PolicyService"> <port name="PolicyServicePort" binding="cmisw:PolicyServicePortBinding"> <soap:address location="http://mockup/ws/services/PolicyService"/> </port> </service> <service name="RelationshipService"> <port name="RelationshipServicePort" binding="cmisw:RelationshipServicePortBinding"> <soap:address location="http://mockup/ws/services/RelationshipService"/> </port> </service> <service name="RepositoryService"> <port name="RepositoryServicePort" binding="cmisw:RepositoryServicePortBinding"> <soap:address location="http://mockup/ws/services/RepositoryService"/> </port> </service> <service name="VersioningService"> <port name="VersioningServicePort" binding="cmisw:VersioningServicePortBinding"> <soap:address location="http://mockup/ws/services/VersioningService"/> </port> </service> <service name="ACLService"> <port name="ACLServicePort" binding="cmisw:ACLServicePortBinding"> <soap:address location="http://mockup/ws/services/ACLService"/> </port> </service> </definitions> ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/type-docLevel2-secondary.http��������������������������������������0000664�0001750�0001750�00000123760�13407173247�021155� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getTypeDefinitionResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:type> <cmis:id>DocumentLevel2</cmis:id> <cmis:localName>DocumentLevel2</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Document Level 2</cmis:displayName> <cmis:queryName>DocumentLevel2</cmis:queryName> <cmis:description>Description of Document Level 2 Type</cmis:description> <cmis:baseId>cmis:document</cmis:baseId> <cmis:parentId>DocumentLevel1</cmis:parentId> <cmis:creatable>true</cmis:creatable> <cmis:fileable>true</cmis:fileable> <cmis:queryable>false</cmis:queryable> <cmis:fulltextIndexed>false</cmis:fulltextIndexed> <cmis:includedInSupertypeQuery>true</cmis:includedInSupertypeQuery> <cmis:controllablePolicy>false</cmis:controllablePolicy> <cmis:controllableACL>true</cmis:controllableACL> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isLatestMajorVersion</cmis:id> <cmis:localName>cmis:isLatestMajorVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Latest Major Version</cmis:displayName> <cmis:queryName>cmis:isLatestMajorVersion</cmis:queryName> <cmis:description>This is a Is Latest Major Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:contentStreamId</cmis:id> <cmis:localName>cmis:contentStreamId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Stream Id</cmis:displayName> <cmis:queryName>cmis:contentStreamId</cmis:queryName> <cmis:description>This is a Stream Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyIntegerDefinition> <cmis:id>cmis:contentStreamLength</cmis:id> <cmis:localName>cmis:contentStreamLength</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Content Length</cmis:displayName> <cmis:queryName>cmis:contentStreamLength</cmis:queryName> <cmis:description>This is a Content Length property.</cmis:description> <cmis:propertyType>integer</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIntegerDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:versionSeriesCheckedOutBy</cmis:id> <cmis:localName>cmis:versionSeriesCheckedOutBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out By</cmis:displayName> <cmis:queryName>cmis:versionSeriesCheckedOutBy</cmis:queryName> <cmis:description>This is a Checked Out By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectTypeId</cmis:id> <cmis:localName>cmis:objectTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Type-Id</cmis:displayName> <cmis:queryName>cmis:objectTypeId</cmis:queryName> <cmis:description>This is a Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>oncreate</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:versionSeriesCheckedOutId</cmis:id> <cmis:localName>cmis:versionSeriesCheckedOutId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out Id</cmis:displayName> <cmis:queryName>cmis:versionSeriesCheckedOutId</cmis:queryName> <cmis:description>This is a Checked Out Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:name</cmis:id> <cmis:localName>cmis:name</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Name</cmis:displayName> <cmis:queryName>cmis:name</cmis:queryName> <cmis:description>This is a Name property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:contentStreamMimeType</cmis:id> <cmis:localName>cmis:contentStreamMimeType</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Mime Type</cmis:displayName> <cmis:queryName>cmis:contentStreamMimeType</cmis:queryName> <cmis:description>This is a Mime Type property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:versionSeriesId</cmis:id> <cmis:localName>cmis:versionSeriesId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Version Series Id</cmis:displayName> <cmis:queryName>cmis:versionSeriesId</cmis:queryName> <cmis:description>This is a Version Series Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:creationDate</cmis:id> <cmis:localName>cmis:creationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Creation Date</cmis:displayName> <cmis:queryName>cmis:creationDate</cmis:queryName> <cmis:description>This is a Creation Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:changeToken</cmis:id> <cmis:localName>cmis:changeToken</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Change Token</cmis:displayName> <cmis:queryName>cmis:changeToken</cmis:queryName> <cmis:description>This is a Change Token property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:versionLabel</cmis:id> <cmis:localName>cmis:versionLabel</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Version Label</cmis:displayName> <cmis:queryName>cmis:versionLabel</cmis:queryName> <cmis:description>This is a Version Label property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isLatestVersion</cmis:id> <cmis:localName>cmis:isLatestVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Latest Version</cmis:displayName> <cmis:queryName>cmis:isLatestVersion</cmis:queryName> <cmis:description>This is a Is Latest Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isVersionSeriesCheckedOut</cmis:id> <cmis:localName>cmis:isVersionSeriesCheckedOut</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out</cmis:displayName> <cmis:queryName>cmis:isVersionSeriesCheckedOut</cmis:queryName> <cmis:description>This is a Checked Out property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:lastModifiedBy</cmis:id> <cmis:localName>cmis:lastModifiedBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modified By</cmis:displayName> <cmis:queryName>cmis:lastModifiedBy</cmis:queryName> <cmis:description>This is a Modified By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:createdBy</cmis:id> <cmis:localName>cmis:createdBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Created By</cmis:displayName> <cmis:queryName>cmis:createdBy</cmis:queryName> <cmis:description>This is a Created By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:checkinComment</cmis:id> <cmis:localName>cmis:checkinComment</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checkin Comment</cmis:displayName> <cmis:queryName>cmis:checkinComment</cmis:queryName> <cmis:description>This is a Checkin Comment property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectId</cmis:id> <cmis:localName>cmis:objectId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Object Id</cmis:displayName> <cmis:queryName>cmis:objectId</cmis:queryName> <cmis:description>This is a Object Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isImmutable</cmis:id> <cmis:localName>cmis:isImmutable</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Immutable</cmis:displayName> <cmis:queryName>cmis:isImmutable</cmis:queryName> <cmis:description>This is a Immutable property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isMajorVersion</cmis:id> <cmis:localName>cmis:isMajorVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Major Version</cmis:displayName> <cmis:queryName>cmis:isMajorVersion</cmis:queryName> <cmis:description>This is a Is Major Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:baseTypeId</cmis:id> <cmis:localName>cmis:baseTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Base-Type-Id</cmis:displayName> <cmis:queryName>cmis:baseTypeId</cmis:queryName> <cmis:description>This is a Base-Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:contentStreamFileName</cmis:id> <cmis:localName>cmis:contentStreamFileName</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>File Name</cmis:displayName> <cmis:queryName>cmis:contentStreamFileName</cmis:queryName> <cmis:description>This is a File Name property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:lastModificationDate</cmis:id> <cmis:localName>cmis:lastModificationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modification Date</cmis:displayName> <cmis:queryName>cmis:lastModificationDate</cmis:queryName> <cmis:description>This is a Modification Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyHtmlDefinition> <cmis:id>HtmlProp</cmis:id> <cmis:localName>HtmlProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Html Property</cmis:displayName> <cmis:queryName>HtmlProp</cmis:queryName> <cmis:description>This is a Sample Html Property property.</cmis:description> <cmis:propertyType>html</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyHtmlDefinition> <cmis:propertyIdDefinition> <cmis:id>IdProp</cmis:id> <cmis:localName>IdProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Id Property</cmis:displayName> <cmis:queryName>IdProp</cmis:queryName> <cmis:description>This is a Sample Id Property property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>DateTimePropMV</cmis:id> <cmis:localName>DateTimePropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample DateTime multi-value Property</cmis:displayName> <cmis:queryName>DateTimePropMV</cmis:queryName> <cmis:description>This is a Sample DateTime multi-value Property property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyUriDefinition> <cmis:id>UriProp</cmis:id> <cmis:localName>UriProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Uri Property</cmis:displayName> <cmis:queryName>UriProp</cmis:queryName> <cmis:description>This is a Sample Uri Property property.</cmis:description> <cmis:propertyType>uri</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyUriDefinition> <cmis:propertyDecimalDefinition> <cmis:id>DecimalProp</cmis:id> <cmis:localName>DecimalProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Decimal Property</cmis:displayName> <cmis:queryName>DecimalProp</cmis:queryName> <cmis:description>This is a Sample Decimal Property property.</cmis:description> <cmis:propertyType>decimal</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDecimalDefinition> <cmis:propertyUriDefinition> <cmis:id>UriPropMV</cmis:id> <cmis:localName>UriPropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Uri multi-value Property</cmis:displayName> <cmis:queryName>UriPropMV</cmis:queryName> <cmis:description>This is a Sample Uri multi-value Property property.</cmis:description> <cmis:propertyType>uri</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyUriDefinition> <cmis:propertyIdDefinition> <cmis:id>IdPropMV</cmis:id> <cmis:localName>IdPropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Id Html multi-value Property</cmis:displayName> <cmis:queryName>IdPropMV</cmis:queryName> <cmis:description>This is a Sample Id Html multi-value Property property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>PickListProp</cmis:id> <cmis:localName>PickListProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Pick List Property</cmis:displayName> <cmis:queryName>PickListProp</cmis:queryName> <cmis:description>This is a Sample Pick List Property property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> <cmis:defaultValue propertyDefinitionId="PickListProp"> <cmis:value>blue</cmis:value> </cmis:defaultValue> <cmis:choice displayName=""> <cmis:value>red</cmis:value> </cmis:choice> <cmis:choice displayName=""> <cmis:value>green</cmis:value> </cmis:choice> <cmis:choice displayName=""> <cmis:value>blue</cmis:value> </cmis:choice> <cmis:choice displayName=""> <cmis:value>black</cmis:value> </cmis:choice> </cmis:propertyStringDefinition> <cmis:propertyIntegerDefinition> <cmis:id>IntProp</cmis:id> <cmis:localName>IntProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Int Property</cmis:displayName> <cmis:queryName>IntProp</cmis:queryName> <cmis:description>This is a Sample Int Property property.</cmis:description> <cmis:propertyType>integer</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIntegerDefinition> <cmis:propertyHtmlDefinition> <cmis:id>HtmlPropMV</cmis:id> <cmis:localName>HtmlPropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Html multi-value Property</cmis:displayName> <cmis:queryName>HtmlPropMV</cmis:queryName> <cmis:description>This is a Sample Html multi-value Property property.</cmis:description> <cmis:propertyType>html</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyHtmlDefinition> <cmis:propertyStringDefinition> <cmis:id>StringProp</cmis:id> <cmis:localName>StringProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample String Property</cmis:displayName> <cmis:queryName>StringProp</cmis:queryName> <cmis:description>This is a Sample String Property property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyDecimalDefinition> <cmis:id>DecimalPropMV</cmis:id> <cmis:localName>DecimalPropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Decimal multi-value Property</cmis:displayName> <cmis:queryName>DecimalPropMV</cmis:queryName> <cmis:description>This is a Sample Decimal multi-value Property property.</cmis:description> <cmis:propertyType>decimal</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDecimalDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>DateTimeProp</cmis:id> <cmis:localName>DateTimeProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample DateTime Property</cmis:displayName> <cmis:queryName>DateTimeProp</cmis:queryName> <cmis:description>This is a Sample DateTime Property property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyBooleanDefinition> <cmis:id>BooleanProp</cmis:id> <cmis:localName>BooleanProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Boolean Property</cmis:displayName> <cmis:queryName>BooleanProp</cmis:queryName> <cmis:description>This is a Sample Boolean Property property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyBooleanDefinition> <cmis:id>BooleanPropMV</cmis:id> <cmis:localName>BooleanPropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Boolean multi-value Property</cmis:displayName> <cmis:queryName>BooleanPropMV</cmis:queryName> <cmis:description>This is a Sample Boolean multi-value Property property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIntegerDefinition> <cmis:id>IntPropMV</cmis:id> <cmis:localName>IntPropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Int multi-value Property</cmis:displayName> <cmis:queryName>IntPropMV</cmis:queryName> <cmis:description>This is a Sample Int multi-value Property property.</cmis:description> <cmis:propertyType>integer</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIntegerDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:secondaryObjectTypeIds</cmis:id> <cmis:localName>cmis:secondaryObjectTypeIds</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>cmis:secondaryObjectTypeIds</cmis:displayName> <cmis:queryName>cmis:secondaryObjectTypeIds</cmis:queryName> <cmis:description>This the property holding the Ids of the secondary types.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:versionable>false</cmis:versionable> <cmis:contentStreamAllowed>allowed</cmis:contentStreamAllowed> </cmism:type> </cmism:getTypeDefinitionResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ����������������libcmis-0.5.2/qa/libcmis/data/ws/type-docLevel1.http������������������������������������������������0000664�0001750�0001750�00000061350�13407173247�017163� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getTypeDefinitionResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:type> <cmis:id>DocumentLevel1</cmis:id> <cmis:localName>DocumentLevel1</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Document Level 1</cmis:displayName> <cmis:queryName>DocumentLevel1</cmis:queryName> <cmis:description>Description of Document Level 1 Type</cmis:description> <cmis:baseId>cmis:document</cmis:baseId> <cmis:parentId>cmis:document</cmis:parentId> <cmis:creatable>true</cmis:creatable> <cmis:fileable>true</cmis:fileable> <cmis:queryable>false</cmis:queryable> <cmis:fulltextIndexed>false</cmis:fulltextIndexed> <cmis:includedInSupertypeQuery>true</cmis:includedInSupertypeQuery> <cmis:controllablePolicy>false</cmis:controllablePolicy> <cmis:controllableACL>true</cmis:controllableACL> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isLatestMajorVersion</cmis:id> <cmis:localName>cmis:isLatestMajorVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Latest Major Version</cmis:displayName> <cmis:queryName>cmis:isLatestMajorVersion</cmis:queryName> <cmis:description>This is a Is Latest Major Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:contentStreamId</cmis:id> <cmis:localName>cmis:contentStreamId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Stream Id</cmis:displayName> <cmis:queryName>cmis:contentStreamId</cmis:queryName> <cmis:description>This is a Stream Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyIntegerDefinition> <cmis:id>cmis:contentStreamLength</cmis:id> <cmis:localName>cmis:contentStreamLength</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Content Length</cmis:displayName> <cmis:queryName>cmis:contentStreamLength</cmis:queryName> <cmis:description>This is a Content Length property.</cmis:description> <cmis:propertyType>integer</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIntegerDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:versionSeriesCheckedOutBy</cmis:id> <cmis:localName>cmis:versionSeriesCheckedOutBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out By</cmis:displayName> <cmis:queryName>cmis:versionSeriesCheckedOutBy</cmis:queryName> <cmis:description>This is a Checked Out By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectTypeId</cmis:id> <cmis:localName>cmis:objectTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Type-Id</cmis:displayName> <cmis:queryName>cmis:objectTypeId</cmis:queryName> <cmis:description>This is a Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>oncreate</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:versionSeriesCheckedOutId</cmis:id> <cmis:localName>cmis:versionSeriesCheckedOutId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out Id</cmis:displayName> <cmis:queryName>cmis:versionSeriesCheckedOutId</cmis:queryName> <cmis:description>This is a Checked Out Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:name</cmis:id> <cmis:localName>cmis:name</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Name</cmis:displayName> <cmis:queryName>cmis:name</cmis:queryName> <cmis:description>This is a Name property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:contentStreamMimeType</cmis:id> <cmis:localName>cmis:contentStreamMimeType</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Mime Type</cmis:displayName> <cmis:queryName>cmis:contentStreamMimeType</cmis:queryName> <cmis:description>This is a Mime Type property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:versionSeriesId</cmis:id> <cmis:localName>cmis:versionSeriesId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Version Series Id</cmis:displayName> <cmis:queryName>cmis:versionSeriesId</cmis:queryName> <cmis:description>This is a Version Series Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:creationDate</cmis:id> <cmis:localName>cmis:creationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Creation Date</cmis:displayName> <cmis:queryName>cmis:creationDate</cmis:queryName> <cmis:description>This is a Creation Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:changeToken</cmis:id> <cmis:localName>cmis:changeToken</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Change Token</cmis:displayName> <cmis:queryName>cmis:changeToken</cmis:queryName> <cmis:description>This is a Change Token property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:versionLabel</cmis:id> <cmis:localName>cmis:versionLabel</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Version Label</cmis:displayName> <cmis:queryName>cmis:versionLabel</cmis:queryName> <cmis:description>This is a Version Label property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isLatestVersion</cmis:id> <cmis:localName>cmis:isLatestVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Latest Version</cmis:displayName> <cmis:queryName>cmis:isLatestVersion</cmis:queryName> <cmis:description>This is a Is Latest Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isVersionSeriesCheckedOut</cmis:id> <cmis:localName>cmis:isVersionSeriesCheckedOut</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out</cmis:displayName> <cmis:queryName>cmis:isVersionSeriesCheckedOut</cmis:queryName> <cmis:description>This is a Checked Out property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:lastModifiedBy</cmis:id> <cmis:localName>cmis:lastModifiedBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modified By</cmis:displayName> <cmis:queryName>cmis:lastModifiedBy</cmis:queryName> <cmis:description>This is a Modified By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:createdBy</cmis:id> <cmis:localName>cmis:createdBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Created By</cmis:displayName> <cmis:queryName>cmis:createdBy</cmis:queryName> <cmis:description>This is a Created By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:checkinComment</cmis:id> <cmis:localName>cmis:checkinComment</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checkin Comment</cmis:displayName> <cmis:queryName>cmis:checkinComment</cmis:queryName> <cmis:description>This is a Checkin Comment property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectId</cmis:id> <cmis:localName>cmis:objectId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Object Id</cmis:displayName> <cmis:queryName>cmis:objectId</cmis:queryName> <cmis:description>This is a Object Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isImmutable</cmis:id> <cmis:localName>cmis:isImmutable</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Immutable</cmis:displayName> <cmis:queryName>cmis:isImmutable</cmis:queryName> <cmis:description>This is a Immutable property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isMajorVersion</cmis:id> <cmis:localName>cmis:isMajorVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Major Version</cmis:displayName> <cmis:queryName>cmis:isMajorVersion</cmis:queryName> <cmis:description>This is a Is Major Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:baseTypeId</cmis:id> <cmis:localName>cmis:baseTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Base-Type-Id</cmis:displayName> <cmis:queryName>cmis:baseTypeId</cmis:queryName> <cmis:description>This is a Base-Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:contentStreamFileName</cmis:id> <cmis:localName>cmis:contentStreamFileName</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>File Name</cmis:displayName> <cmis:queryName>cmis:contentStreamFileName</cmis:queryName> <cmis:description>This is a File Name property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:lastModificationDate</cmis:id> <cmis:localName>cmis:lastModificationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modification Date</cmis:displayName> <cmis:queryName>cmis:lastModificationDate</cmis:queryName> <cmis:description>This is a Modification Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:versionable>false</cmis:versionable> <cmis:contentStreamAllowed>allowed</cmis:contentStreamAllowed> </cmism:type> </cmism:getTypeDefinitionResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/get-versions.http��������������������������������������������������0000664�0001750�0001750�00000045654�13407173247�017024� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getAllVersionsResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:objects> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>12345</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyHtml queryName="HtmlProp" displayName="Sample Html Property" localName="HtmlProp" propertyDefinitionId="HtmlProp"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyId queryName="IdProp" displayName="Sample Id Property" localName="IdProp" propertyDefinitionId="IdProp"/> <cmis:propertyUri queryName="UriProp" displayName="Sample Uri Property" localName="UriProp" propertyDefinitionId="UriProp"/> <cmis:propertyDateTime queryName="DateTimePropMV" displayName="Sample DateTime multi-value Property" localName="DateTimePropMV" propertyDefinitionId="DateTimePropMV"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"> <cmis:value>version-series</cmis:value> </cmis:propertyId> <cmis:propertyDecimal queryName="DecimalProp" displayName="Sample Decimal Property" localName="DecimalProp" propertyDefinitionId="DecimalProp"/> <cmis:propertyUri queryName="UriPropMV" displayName="Sample Uri multi-value Property" localName="UriPropMV" propertyDefinitionId="UriPropMV"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"> <cmis:value>1.0</cmis:value> </cmis:propertyString> <cmis:propertyBoolean queryName="BooleanProp" displayName="Sample Boolean Property" localName="BooleanProp" propertyDefinitionId="BooleanProp"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="IdPropMV" displayName="Sample Id Html multi-value Property" localName="IdPropMV" propertyDefinitionId="IdPropMV"/> <cmis:propertyString queryName="PickListProp" displayName="Sample Pick List Property" localName="PickListProp" propertyDefinitionId="PickListProp"> <cmis:value>blue</cmis:value> </cmis:propertyString> <cmis:propertyHtml queryName="HtmlPropMV" displayName="Sample Html multi-value Property" localName="HtmlPropMV" propertyDefinitionId="HtmlPropMV"/> <cmis:propertyInteger queryName="IntProp" displayName="Sample Int Property" localName="IntProp" propertyDefinitionId="IntProp"/> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Test Document</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="StringProp" displayName="Sample String Property" localName="StringProp" propertyDefinitionId="StringProp"> <cmis:value>My Doc StringProperty 6</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359382206736</cmis:value> </cmis:propertyString> <cmis:propertyDecimal queryName="DecimalPropMV" displayName="Sample Decimal multi-value Property" localName="DecimalPropMV" propertyDefinitionId="DecimalPropMV"/> <cmis:propertyDateTime queryName="DateTimeProp" displayName="Sample DateTime Property" localName="DateTimeProp" propertyDefinitionId="DateTimeProp"/> <cmis:propertyBoolean queryName="BooleanPropMV" displayName="Sample Boolean multi-value Property" localName="BooleanPropMV" propertyDefinitionId="BooleanPropMV"/> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>test-document-1</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyInteger queryName="IntPropMV" displayName="Sample Int multi-value Property" localName="IntPropMV" propertyDefinitionId="IntPropMV"/> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> <exampleExtension:exampleExtension xmlns="http://mockup/cmis/extension" xmlns:exampleExtension="http://mockup/cmis/extension"> <objectId xmlns:ns0="http://mockup/cmis/extension" ns0:type="DocumentLevel2">test-document-1</objectId> <name>Test Document</name> </exampleExtension:exampleExtension> </cmism:objects> <cmism:objects> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>12345</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyHtml queryName="HtmlProp" displayName="Sample Html Property" localName="HtmlProp" propertyDefinitionId="HtmlProp"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyId queryName="IdProp" displayName="Sample Id Property" localName="IdProp" propertyDefinitionId="IdProp"/> <cmis:propertyUri queryName="UriProp" displayName="Sample Uri Property" localName="UriProp" propertyDefinitionId="UriProp"/> <cmis:propertyDateTime queryName="DateTimePropMV" displayName="Sample DateTime multi-value Property" localName="DateTimePropMV" propertyDefinitionId="DateTimePropMV"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"> <cmis:value>version-series</cmis:value> </cmis:propertyId> <cmis:propertyDecimal queryName="DecimalProp" displayName="Sample Decimal Property" localName="DecimalProp" propertyDefinitionId="DecimalProp"/> <cmis:propertyUri queryName="UriPropMV" displayName="Sample Uri multi-value Property" localName="UriPropMV" propertyDefinitionId="UriPropMV"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"> <cmis:value>0.1</cmis:value> </cmis:propertyString> <cmis:propertyBoolean queryName="BooleanProp" displayName="Sample Boolean Property" localName="BooleanProp" propertyDefinitionId="BooleanProp"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="IdPropMV" displayName="Sample Id Html multi-value Property" localName="IdPropMV" propertyDefinitionId="IdPropMV"/> <cmis:propertyString queryName="PickListProp" displayName="Sample Pick List Property" localName="PickListProp" propertyDefinitionId="PickListProp"> <cmis:value>blue</cmis:value> </cmis:propertyString> <cmis:propertyHtml queryName="HtmlPropMV" displayName="Sample Html multi-value Property" localName="HtmlPropMV" propertyDefinitionId="HtmlPropMV"/> <cmis:propertyInteger queryName="IntProp" displayName="Sample Int Property" localName="IntProp" propertyDefinitionId="IntProp"/> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Test Document</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="StringProp" displayName="Sample String Property" localName="StringProp" propertyDefinitionId="StringProp"> <cmis:value>My Doc StringProperty 6</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-27T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359382206754</cmis:value> </cmis:propertyString> <cmis:propertyDecimal queryName="DecimalPropMV" displayName="Sample Decimal multi-value Property" localName="DecimalPropMV" propertyDefinitionId="DecimalPropMV"/> <cmis:propertyDateTime queryName="DateTimeProp" displayName="Sample DateTime Property" localName="DateTimeProp" propertyDefinitionId="DateTimeProp"/> <cmis:propertyBoolean queryName="BooleanPropMV" displayName="Sample Boolean multi-value Property" localName="BooleanPropMV" propertyDefinitionId="BooleanPropMV"/> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>test-document-0</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyInteger queryName="IntPropMV" displayName="Sample Int multi-value Property" localName="IntPropMV" propertyDefinitionId="IntPropMV"/> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-27T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> <exampleExtension:exampleExtension xmlns="http://mockup/cmis/extension" xmlns:exampleExtension="http://mockup/cmis/extension"> <objectId xmlns:ns0="http://mockup/cmis/extension" ns0:type="DocumentLevel2">test-document-0</objectId> <name>Test Document</name> </exampleExtension:exampleExtension> </cmism:objects> </cmism:getAllVersionsResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/repositories.http��������������������������������������������������0000664�0001750�0001750�00000002542�13407173247�017113� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <ns2:getRepositoriesResponse xmlns="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:ns2="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <ns2:repositories><ns2:repositoryId>mock</ns2:repositoryId><ns2:repositoryName>Mockup</ns2:repositoryName></ns2:repositories> </ns2:getRepositoriesResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ��������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/update-properties.http���������������������������������������������0000664�0001750�0001750�00000002550�13407173247�020037� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:updatePropertiesResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:objectId>test-document</cmism:objectId> <cmism:changeToken>some-new-changeToken</cmism:changeToken> </cmism:updatePropertiesResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ��������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/checked-in.http����������������������������������������������������0000664�0001750�0001750�00000030535�13407173247�016361� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getObjectResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:object> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>12345</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyHtml queryName="HtmlProp" displayName="Sample Html Property" localName="HtmlProp" propertyDefinitionId="HtmlProp"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyId queryName="IdProp" displayName="Sample Id Property" localName="IdProp" propertyDefinitionId="IdProp"/> <cmis:propertyUri queryName="UriProp" displayName="Sample Uri Property" localName="UriProp" propertyDefinitionId="UriProp"/> <cmis:propertyDateTime queryName="DateTimePropMV" displayName="Sample DateTime multi-value Property" localName="DateTimePropMV" propertyDefinitionId="DateTimePropMV"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"/> <cmis:propertyDecimal queryName="DecimalProp" displayName="Sample Decimal Property" localName="DecimalProp" propertyDefinitionId="DecimalProp"/> <cmis:propertyUri queryName="UriPropMV" displayName="Sample Uri multi-value Property" localName="UriPropMV" propertyDefinitionId="UriPropMV"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"> <cmis:value>2.0</cmis:value> </cmis:propertyString> <cmis:propertyBoolean queryName="BooleanProp" displayName="Sample Boolean Property" localName="BooleanProp" propertyDefinitionId="BooleanProp"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="IdPropMV" displayName="Sample Id Html multi-value Property" localName="IdPropMV" propertyDefinitionId="IdPropMV"/> <cmis:propertyString queryName="PickListProp" displayName="Sample Pick List Property" localName="PickListProp" propertyDefinitionId="PickListProp"> <cmis:value>blue</cmis:value> </cmis:propertyString> <cmis:propertyHtml queryName="HtmlPropMV" displayName="Sample Html multi-value Property" localName="HtmlPropMV" propertyDefinitionId="HtmlPropMV"/> <cmis:propertyInteger queryName="IntProp" displayName="Sample Int Property" localName="IntProp" propertyDefinitionId="IntProp"/> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Test Document</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="StringProp" displayName="Sample String Property" localName="StringProp" propertyDefinitionId="StringProp"> <cmis:value>My Doc StringProperty 6</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>some-other-token</cmis:value> </cmis:propertyString> <cmis:propertyDecimal queryName="DecimalPropMV" displayName="Sample Decimal multi-value Property" localName="DecimalPropMV" propertyDefinitionId="DecimalPropMV"/> <cmis:propertyDateTime queryName="DateTimeProp" displayName="Sample DateTime Property" localName="DateTimeProp" propertyDefinitionId="DateTimeProp"/> <cmis:propertyBoolean queryName="BooleanPropMV" displayName="Sample Boolean multi-value Property" localName="BooleanPropMV" propertyDefinitionId="BooleanPropMV"/> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"> <cmis:value>Some check-in comment</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>test-document</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyInteger queryName="IntPropMV" displayName="Sample Int multi-value Property" localName="IntPropMV" propertyDefinitionId="IntPropMV"/> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>filename.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> <cmis:allowableActions> <cmis:canDeleteObject>true</cmis:canDeleteObject> <cmis:canUpdateProperties>true</cmis:canUpdateProperties> <cmis:canGetFolderTree>false</cmis:canGetFolderTree> <cmis:canGetProperties>true</cmis:canGetProperties> <cmis:canGetObjectRelationships>false</cmis:canGetObjectRelationships> <cmis:canGetObjectParents>true</cmis:canGetObjectParents> <cmis:canGetFolderParent>false</cmis:canGetFolderParent> <cmis:canGetDescendants>false</cmis:canGetDescendants> <cmis:canMoveObject>true</cmis:canMoveObject> <cmis:canDeleteContentStream>true</cmis:canDeleteContentStream> <cmis:canCheckOut>true</cmis:canCheckOut> <cmis:canCancelCheckOut>false</cmis:canCancelCheckOut> <cmis:canCheckIn>false</cmis:canCheckIn> <cmis:canSetContentStream>true</cmis:canSetContentStream> <cmis:canGetAllVersions>true</cmis:canGetAllVersions> <cmis:canAddObjectToFolder>true</cmis:canAddObjectToFolder> <cmis:canRemoveObjectFromFolder>true</cmis:canRemoveObjectFromFolder> <cmis:canGetContentStream>true</cmis:canGetContentStream> <cmis:canApplyPolicy>false</cmis:canApplyPolicy> <cmis:canGetAppliedPolicies>false</cmis:canGetAppliedPolicies> <cmis:canRemovePolicy>false</cmis:canRemovePolicy> <cmis:canGetChildren>false</cmis:canGetChildren> <cmis:canCreateDocument>false</cmis:canCreateDocument> <cmis:canCreateFolder>false</cmis:canCreateFolder> <cmis:canCreateRelationship>false</cmis:canCreateRelationship> <cmis:canDeleteTree>false</cmis:canDeleteTree> <cmis:canGetRenditions>false</cmis:canGetRenditions> <cmis:canGetACL>false</cmis:canGetACL> <cmis:canApplyACL>false</cmis:canApplyACL> </cmis:allowableActions> <exampleExtension:exampleExtension xmlns="http://mockup/cmis/extension" xmlns:exampleExtension="http://mockup/cmis/extension"> <objectId xmlns:ns0="http://mockup/cmis/extension" ns0:type="DocumentLevel2">test-document</objectId> <name>Test Document</name> </exampleExtension:exampleExtension> </cmism:object> </cmism:getObjectResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- �������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/create-document.http�����������������������������������������������0000664�0001750�0001750�00000002437�13407173247�017446� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:createDocumentResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:objectId>created-document</cmism:objectId> </cmism:createDocumentResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/get-renditions.http������������������������������������������������0000664�0001750�0001750�00000003702�13407173247�017316� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getRenditionsResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:renditions> <cmis:streamId>test-document-rendition1</cmis:streamId> <cmis:mimetype>image/png</cmis:mimetype> <cmis:length>40385</cmis:length> <cmis:kind>cmis:thumbnail</cmis:kind> <cmis:title>picture</cmis:title> <cmis:height>100</cmis:height> <cmis:width>100</cmis:width> </cmism:renditions> <cmism:renditions> <cmis:streamId>test-document-rendition2</cmis:streamId> <cmis:mimetype>application/pdf</cmis:mimetype> <cmis:kind>pdf</cmis:kind> <cmis:title>Doc as PDF</cmis:title> </cmism:renditions> </cmism:getRenditionsResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ��������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/created-document.http����������������������������������������������0000664�0001750�0001750�00000015711�13407173247�017611� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getObjectResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:object> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>12345</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>create document</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359382206736</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>create-document</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmism:object> </cmism:getObjectResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- �������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/repository-infos-bad.http������������������������������������������0000664�0001750�0001750�00000002775�13407173247�020453� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*abd9e41c-b3aa-40a7-a73a-997c472010e8@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:abd9e41c-b3aa-40a7-a73a-997c472010e8";start-info="text/xml" --uuid:abd9e41c-b3aa-40a7-a73a-997c472010e8 Content-Id: <rootpart*abd9e41c-b3aa-40a7-a73a-997c472010e8@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version="1.0" encoding="UTF-8"?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-30T19:54:27Z</Created> <Expires>2013-10-01T19:54:27Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <S:Fault> <faultcode>S:Server</faultcode> <faultstring>Repository 'bad' not found</faultstring> <detail> <cmisFault:cmisFault xmlns="http://docs.oasis-open.org/ns/cmis/messaging/200908/" xmlns:cmisFault="http://docs.oasis-open.org/ns/cmis/messaging/200908/" xmlns:ns2="http://docs.oasis-open.org/ns/cmis/core/200908/"> <type>invalidArgument</type> <code>562</code> <message>Unknown repository id: 'bad'</message> </cmisFault:cmisFault> </detail> </S:Fault> </S:Body> </S:Envelope> --uuid:abd9e41c-b3aa-40a7-a73a-997c472010e8-- ���libcmis-0.5.2/qa/libcmis/data/ws/test-document-parents.http�����������������������������������������0000664�0001750�0001750�00000017434�13407173247�020637� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getObjectParentsResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:parents> <cmism:object> <cmis:properties> <cmis:propertyId queryName="cmis:allowedChildObjectTypeIds" displayName="Allowed Child Types" localName="cmis:allowedChildObjectTypeIds" propertyDefinitionId="cmis:allowedChildObjectTypeIds"> <cmis:value>*</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:path" displayName="Path" localName="cmis:path" propertyDefinitionId="cmis:path"> <cmis:value>/Parent 1</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Parent 1</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>parent1</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-31T08:04:35.866Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359619475867</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyId queryName="cmis:parentId" displayName="Parent Id" localName="cmis:parentId" propertyDefinitionId="cmis:parentId"> <cmis:value>root-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-31T08:04:35.867Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmism:object> <cmism:object> <cmis:properties> <cmis:propertyId queryName="cmis:allowedChildObjectTypeIds" displayName="Allowed Child Types" localName="cmis:allowedChildObjectTypeIds" propertyDefinitionId="cmis:allowedChildObjectTypeIds"> <cmis:value>*</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:path" displayName="Path" localName="cmis:path" propertyDefinitionId="cmis:path"> <cmis:value>/Parent 2</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Parent 2</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>parent2</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-31T08:04:35.866Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359619475867</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyId queryName="cmis:parentId" displayName="Parent Id" localName="cmis:parentId" propertyDefinitionId="cmis:parentId"> <cmis:value>root-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-31T08:04:35.867Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmism:object> </cmism:parents> </cmism:getObjectParentsResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/working-copy.http��������������������������������������������������0000664�0001750�0001750�00000017536�13407173247�017025� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getObjectResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:object> <cmis:properties> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>12345</cmis:value> </cmis:propertyInteger> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"> <cmis:value>working-copy</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Test Document</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="VersionedStringProp" displayName="Sample String Property" localName="VersionedStringProp" propertyDefinitionId="VersionedStringProp"/> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"> <cmis:value>version-series</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-05-21T13:50:45.300Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1369144245300</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"> <cmis:value>V 0.2</cmis:value> </cmis:propertyString> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>working-copy</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-05-21T13:50:45.300Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> <exampleExtension:exampleExtension xmlns="http://mockup/cmis/extension" xmlns:exampleExtension="http://mockup/cmis/extension"> <objectId xmlns:ns0="http://mockup/cmis/extension" ns0:type="DocumentLevel2">working-copy</objectId> <name>Test Document</name> </exampleExtension:exampleExtension> </cmism:object> </cmism:getObjectResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/root-children.http�������������������������������������������������0000664�0001750�0001750�00000065121�13407173247�017137� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getChildrenResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:objects> <cmism:objects> <cmism:object> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>33446</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyDateTime queryName="DateTimePropMV" displayName="Sample DateTime multi-value Property" localName="DateTimePropMV" propertyDefinitionId="DateTimePropMV"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Child 1</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-30T09:26:13.932Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359537973932</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>child1</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-30T09:26:13.932Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmism:object> <cmism:object> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>33537</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Child 2</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-30T09:26:13.978Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359537973978</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>child2</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-30T09:26:13.978Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmism:object> <cmism:object> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>33353</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Child 3</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-30T09:26:14.031Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359537974031</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>child3</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-30T09:26:14.031Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmism:object> <cmism:object> <cmis:properties> <cmis:propertyId queryName="cmis:allowedChildObjectTypeIds" displayName="Allowed Child Types" localName="cmis:allowedChildObjectTypeIds" propertyDefinitionId="cmis:allowedChildObjectTypeIds"> <cmis:value>*</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:path" displayName="Path" localName="cmis:path" propertyDefinitionId="cmis:path"> <cmis:value>/Child 4</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Child 4</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>child4</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-30T09:26:12.384Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359537972384</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyId queryName="cmis:parentId" displayName="Parent Id" localName="cmis:parentId" propertyDefinitionId="cmis:parentId"> <cmis:value>root-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-30T09:26:12.384Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmism:object> <cmism:object> <cmis:properties> <cmis:propertyId queryName="cmis:allowedChildObjectTypeIds" displayName="Allowed Child Types" localName="cmis:allowedChildObjectTypeIds" propertyDefinitionId="cmis:allowedChildObjectTypeIds"> <cmis:value>*</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:path" displayName="Path" localName="cmis:path" propertyDefinitionId="cmis:path"> <cmis:value>/Child 5</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Child 5</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>child5</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-30T09:26:13.338Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1359537973338</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyId queryName="cmis:parentId" displayName="Parent Id" localName="cmis:parentId" propertyDefinitionId="cmis:parentId"> <cmis:value>root-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-30T09:26:13.338Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmism:object> </cmism:objects> </cmism:objects> </cmism:getChildrenResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/move-object.http���������������������������������������������������0000664�0001750�0001750�00000002464�13407173247�016601� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:moveObjectResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:objectId>test-document</cmism:objectId> </cmism:moveObjectResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/type-docLevel2.http������������������������������������������������0000664�0001750�0001750�00000121716�13407173247�017167� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getTypeDefinitionResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:type> <cmis:id>DocumentLevel2</cmis:id> <cmis:localName>DocumentLevel2</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Document Level 2</cmis:displayName> <cmis:queryName>DocumentLevel2</cmis:queryName> <cmis:description>Description of Document Level 2 Type</cmis:description> <cmis:baseId>cmis:document</cmis:baseId> <cmis:parentId>DocumentLevel1</cmis:parentId> <cmis:creatable>true</cmis:creatable> <cmis:fileable>true</cmis:fileable> <cmis:queryable>false</cmis:queryable> <cmis:fulltextIndexed>false</cmis:fulltextIndexed> <cmis:includedInSupertypeQuery>true</cmis:includedInSupertypeQuery> <cmis:controllablePolicy>false</cmis:controllablePolicy> <cmis:controllableACL>true</cmis:controllableACL> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isLatestMajorVersion</cmis:id> <cmis:localName>cmis:isLatestMajorVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Latest Major Version</cmis:displayName> <cmis:queryName>cmis:isLatestMajorVersion</cmis:queryName> <cmis:description>This is a Is Latest Major Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:contentStreamId</cmis:id> <cmis:localName>cmis:contentStreamId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Stream Id</cmis:displayName> <cmis:queryName>cmis:contentStreamId</cmis:queryName> <cmis:description>This is a Stream Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyIntegerDefinition> <cmis:id>cmis:contentStreamLength</cmis:id> <cmis:localName>cmis:contentStreamLength</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Content Length</cmis:displayName> <cmis:queryName>cmis:contentStreamLength</cmis:queryName> <cmis:description>This is a Content Length property.</cmis:description> <cmis:propertyType>integer</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIntegerDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:versionSeriesCheckedOutBy</cmis:id> <cmis:localName>cmis:versionSeriesCheckedOutBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out By</cmis:displayName> <cmis:queryName>cmis:versionSeriesCheckedOutBy</cmis:queryName> <cmis:description>This is a Checked Out By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectTypeId</cmis:id> <cmis:localName>cmis:objectTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Type-Id</cmis:displayName> <cmis:queryName>cmis:objectTypeId</cmis:queryName> <cmis:description>This is a Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>oncreate</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:versionSeriesCheckedOutId</cmis:id> <cmis:localName>cmis:versionSeriesCheckedOutId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out Id</cmis:displayName> <cmis:queryName>cmis:versionSeriesCheckedOutId</cmis:queryName> <cmis:description>This is a Checked Out Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:name</cmis:id> <cmis:localName>cmis:name</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Name</cmis:displayName> <cmis:queryName>cmis:name</cmis:queryName> <cmis:description>This is a Name property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:contentStreamMimeType</cmis:id> <cmis:localName>cmis:contentStreamMimeType</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Mime Type</cmis:displayName> <cmis:queryName>cmis:contentStreamMimeType</cmis:queryName> <cmis:description>This is a Mime Type property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:versionSeriesId</cmis:id> <cmis:localName>cmis:versionSeriesId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Version Series Id</cmis:displayName> <cmis:queryName>cmis:versionSeriesId</cmis:queryName> <cmis:description>This is a Version Series Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:creationDate</cmis:id> <cmis:localName>cmis:creationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Creation Date</cmis:displayName> <cmis:queryName>cmis:creationDate</cmis:queryName> <cmis:description>This is a Creation Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:changeToken</cmis:id> <cmis:localName>cmis:changeToken</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Change Token</cmis:displayName> <cmis:queryName>cmis:changeToken</cmis:queryName> <cmis:description>This is a Change Token property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:versionLabel</cmis:id> <cmis:localName>cmis:versionLabel</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Version Label</cmis:displayName> <cmis:queryName>cmis:versionLabel</cmis:queryName> <cmis:description>This is a Version Label property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isLatestVersion</cmis:id> <cmis:localName>cmis:isLatestVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Latest Version</cmis:displayName> <cmis:queryName>cmis:isLatestVersion</cmis:queryName> <cmis:description>This is a Is Latest Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isVersionSeriesCheckedOut</cmis:id> <cmis:localName>cmis:isVersionSeriesCheckedOut</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out</cmis:displayName> <cmis:queryName>cmis:isVersionSeriesCheckedOut</cmis:queryName> <cmis:description>This is a Checked Out property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:lastModifiedBy</cmis:id> <cmis:localName>cmis:lastModifiedBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modified By</cmis:displayName> <cmis:queryName>cmis:lastModifiedBy</cmis:queryName> <cmis:description>This is a Modified By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:createdBy</cmis:id> <cmis:localName>cmis:createdBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Created By</cmis:displayName> <cmis:queryName>cmis:createdBy</cmis:queryName> <cmis:description>This is a Created By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:checkinComment</cmis:id> <cmis:localName>cmis:checkinComment</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checkin Comment</cmis:displayName> <cmis:queryName>cmis:checkinComment</cmis:queryName> <cmis:description>This is a Checkin Comment property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectId</cmis:id> <cmis:localName>cmis:objectId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Object Id</cmis:displayName> <cmis:queryName>cmis:objectId</cmis:queryName> <cmis:description>This is a Object Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isImmutable</cmis:id> <cmis:localName>cmis:isImmutable</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Immutable</cmis:displayName> <cmis:queryName>cmis:isImmutable</cmis:queryName> <cmis:description>This is a Immutable property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isMajorVersion</cmis:id> <cmis:localName>cmis:isMajorVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Major Version</cmis:displayName> <cmis:queryName>cmis:isMajorVersion</cmis:queryName> <cmis:description>This is a Is Major Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:baseTypeId</cmis:id> <cmis:localName>cmis:baseTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Base-Type-Id</cmis:displayName> <cmis:queryName>cmis:baseTypeId</cmis:queryName> <cmis:description>This is a Base-Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:contentStreamFileName</cmis:id> <cmis:localName>cmis:contentStreamFileName</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>File Name</cmis:displayName> <cmis:queryName>cmis:contentStreamFileName</cmis:queryName> <cmis:description>This is a File Name property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:lastModificationDate</cmis:id> <cmis:localName>cmis:lastModificationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modification Date</cmis:displayName> <cmis:queryName>cmis:lastModificationDate</cmis:queryName> <cmis:description>This is a Modification Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyHtmlDefinition> <cmis:id>HtmlProp</cmis:id> <cmis:localName>HtmlProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Html Property</cmis:displayName> <cmis:queryName>HtmlProp</cmis:queryName> <cmis:description>This is a Sample Html Property property.</cmis:description> <cmis:propertyType>html</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyHtmlDefinition> <cmis:propertyIdDefinition> <cmis:id>IdProp</cmis:id> <cmis:localName>IdProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Id Property</cmis:displayName> <cmis:queryName>IdProp</cmis:queryName> <cmis:description>This is a Sample Id Property property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>DateTimePropMV</cmis:id> <cmis:localName>DateTimePropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample DateTime multi-value Property</cmis:displayName> <cmis:queryName>DateTimePropMV</cmis:queryName> <cmis:description>This is a Sample DateTime multi-value Property property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyUriDefinition> <cmis:id>UriProp</cmis:id> <cmis:localName>UriProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Uri Property</cmis:displayName> <cmis:queryName>UriProp</cmis:queryName> <cmis:description>This is a Sample Uri Property property.</cmis:description> <cmis:propertyType>uri</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyUriDefinition> <cmis:propertyDecimalDefinition> <cmis:id>DecimalProp</cmis:id> <cmis:localName>DecimalProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Decimal Property</cmis:displayName> <cmis:queryName>DecimalProp</cmis:queryName> <cmis:description>This is a Sample Decimal Property property.</cmis:description> <cmis:propertyType>decimal</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDecimalDefinition> <cmis:propertyUriDefinition> <cmis:id>UriPropMV</cmis:id> <cmis:localName>UriPropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Uri multi-value Property</cmis:displayName> <cmis:queryName>UriPropMV</cmis:queryName> <cmis:description>This is a Sample Uri multi-value Property property.</cmis:description> <cmis:propertyType>uri</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyUriDefinition> <cmis:propertyIdDefinition> <cmis:id>IdPropMV</cmis:id> <cmis:localName>IdPropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Id Html multi-value Property</cmis:displayName> <cmis:queryName>IdPropMV</cmis:queryName> <cmis:description>This is a Sample Id Html multi-value Property property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>PickListProp</cmis:id> <cmis:localName>PickListProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Pick List Property</cmis:displayName> <cmis:queryName>PickListProp</cmis:queryName> <cmis:description>This is a Sample Pick List Property property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> <cmis:defaultValue propertyDefinitionId="PickListProp"> <cmis:value>blue</cmis:value> </cmis:defaultValue> <cmis:choice displayName=""> <cmis:value>red</cmis:value> </cmis:choice> <cmis:choice displayName=""> <cmis:value>green</cmis:value> </cmis:choice> <cmis:choice displayName=""> <cmis:value>blue</cmis:value> </cmis:choice> <cmis:choice displayName=""> <cmis:value>black</cmis:value> </cmis:choice> </cmis:propertyStringDefinition> <cmis:propertyIntegerDefinition> <cmis:id>IntProp</cmis:id> <cmis:localName>IntProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Int Property</cmis:displayName> <cmis:queryName>IntProp</cmis:queryName> <cmis:description>This is a Sample Int Property property.</cmis:description> <cmis:propertyType>integer</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIntegerDefinition> <cmis:propertyHtmlDefinition> <cmis:id>HtmlPropMV</cmis:id> <cmis:localName>HtmlPropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Html multi-value Property</cmis:displayName> <cmis:queryName>HtmlPropMV</cmis:queryName> <cmis:description>This is a Sample Html multi-value Property property.</cmis:description> <cmis:propertyType>html</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyHtmlDefinition> <cmis:propertyStringDefinition> <cmis:id>StringProp</cmis:id> <cmis:localName>StringProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample String Property</cmis:displayName> <cmis:queryName>StringProp</cmis:queryName> <cmis:description>This is a Sample String Property property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyDecimalDefinition> <cmis:id>DecimalPropMV</cmis:id> <cmis:localName>DecimalPropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Decimal multi-value Property</cmis:displayName> <cmis:queryName>DecimalPropMV</cmis:queryName> <cmis:description>This is a Sample Decimal multi-value Property property.</cmis:description> <cmis:propertyType>decimal</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDecimalDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>DateTimeProp</cmis:id> <cmis:localName>DateTimeProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample DateTime Property</cmis:displayName> <cmis:queryName>DateTimeProp</cmis:queryName> <cmis:description>This is a Sample DateTime Property property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyBooleanDefinition> <cmis:id>BooleanProp</cmis:id> <cmis:localName>BooleanProp</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Boolean Property</cmis:displayName> <cmis:queryName>BooleanProp</cmis:queryName> <cmis:description>This is a Sample Boolean Property property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyBooleanDefinition> <cmis:id>BooleanPropMV</cmis:id> <cmis:localName>BooleanPropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Boolean multi-value Property</cmis:displayName> <cmis:queryName>BooleanPropMV</cmis:queryName> <cmis:description>This is a Sample Boolean multi-value Property property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIntegerDefinition> <cmis:id>IntPropMV</cmis:id> <cmis:localName>IntPropMV</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Sample Int multi-value Property</cmis:displayName> <cmis:queryName>IntPropMV</cmis:queryName> <cmis:description>This is a Sample Int multi-value Property property.</cmis:description> <cmis:propertyType>integer</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIntegerDefinition> <cmis:versionable>false</cmis:versionable> <cmis:contentStreamAllowed>allowed</cmis:contentStreamAllowed> </cmism:type> </cmism:getTypeDefinitionResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ��������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/checkin.http�������������������������������������������������������0000664�0001750�0001750�00000002456�13407173247�015774� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:checkInResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:objectId>test-document</cmism:objectId> </cmism:checkInResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/created-folder.http������������������������������������������������0000664�0001750�0001750�00000010622�13407173247�017242� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getObjectResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:object> <cmis:properties> <cmis:propertyId queryName="cmis:allowedChildObjectTypeIds" displayName="Allowed Child Types" localName="cmis:allowedChildObjectTypeIds" propertyDefinitionId="cmis:allowedChildObjectTypeIds"> <cmis:value>*</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:path" displayName="Path" localName="cmis:path" propertyDefinitionId="cmis:path"> <cmis:value>/create folder</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>create folder</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>create-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2012-11-29T16:14:47.019Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1354205687020</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyId queryName="cmis:parentId" displayName="Parent Id" localName="cmis:parentId" propertyDefinitionId="cmis:parentId"> <cmis:value>root-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2012-11-29T16:14:47.020Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> </cmism:object> </cmism:getObjectResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ��������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/typechildren-document.http�����������������������������������������0000664�0001750�0001750�00000064447�13407173247�020706� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getTypeChildrenResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:types> <cmism:types> <cmis:id>DocumentLevel1</cmis:id> <cmis:localName>DocumentLevel1</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Document Level 1</cmis:displayName> <cmis:queryName>DocumentLevel1</cmis:queryName> <cmis:description>Description of Document Level 1 Type</cmis:description> <cmis:baseId>cmis:document</cmis:baseId> <cmis:parentId>cmis:document</cmis:parentId> <cmis:creatable>true</cmis:creatable> <cmis:fileable>true</cmis:fileable> <cmis:queryable>false</cmis:queryable> <cmis:fulltextIndexed>false</cmis:fulltextIndexed> <cmis:includedInSupertypeQuery>true</cmis:includedInSupertypeQuery> <cmis:controllablePolicy>false</cmis:controllablePolicy> <cmis:controllableACL>true</cmis:controllableACL> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isLatestMajorVersion</cmis:id> <cmis:localName>cmis:isLatestMajorVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Latest Major Version</cmis:displayName> <cmis:queryName>cmis:isLatestMajorVersion</cmis:queryName> <cmis:description>This is a Is Latest Major Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:contentStreamId</cmis:id> <cmis:localName>cmis:contentStreamId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Stream Id</cmis:displayName> <cmis:queryName>cmis:contentStreamId</cmis:queryName> <cmis:description>This is a Stream Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyIntegerDefinition> <cmis:id>cmis:contentStreamLength</cmis:id> <cmis:localName>cmis:contentStreamLength</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Content Length</cmis:displayName> <cmis:queryName>cmis:contentStreamLength</cmis:queryName> <cmis:description>This is a Content Length property.</cmis:description> <cmis:propertyType>integer</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIntegerDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:versionSeriesCheckedOutBy</cmis:id> <cmis:localName>cmis:versionSeriesCheckedOutBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out By</cmis:displayName> <cmis:queryName>cmis:versionSeriesCheckedOutBy</cmis:queryName> <cmis:description>This is a Checked Out By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectTypeId</cmis:id> <cmis:localName>cmis:objectTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Type-Id</cmis:displayName> <cmis:queryName>cmis:objectTypeId</cmis:queryName> <cmis:description>This is a Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>oncreate</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:versionSeriesCheckedOutId</cmis:id> <cmis:localName>cmis:versionSeriesCheckedOutId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out Id</cmis:displayName> <cmis:queryName>cmis:versionSeriesCheckedOutId</cmis:queryName> <cmis:description>This is a Checked Out Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:name</cmis:id> <cmis:localName>cmis:name</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Name</cmis:displayName> <cmis:queryName>cmis:name</cmis:queryName> <cmis:description>This is a Name property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:contentStreamMimeType</cmis:id> <cmis:localName>cmis:contentStreamMimeType</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Mime Type</cmis:displayName> <cmis:queryName>cmis:contentStreamMimeType</cmis:queryName> <cmis:description>This is a Mime Type property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:versionSeriesId</cmis:id> <cmis:localName>cmis:versionSeriesId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Version Series Id</cmis:displayName> <cmis:queryName>cmis:versionSeriesId</cmis:queryName> <cmis:description>This is a Version Series Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:creationDate</cmis:id> <cmis:localName>cmis:creationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Creation Date</cmis:displayName> <cmis:queryName>cmis:creationDate</cmis:queryName> <cmis:description>This is a Creation Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:changeToken</cmis:id> <cmis:localName>cmis:changeToken</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Change Token</cmis:displayName> <cmis:queryName>cmis:changeToken</cmis:queryName> <cmis:description>This is a Change Token property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isLatestVersion</cmis:id> <cmis:localName>cmis:isLatestVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Latest Version</cmis:displayName> <cmis:queryName>cmis:isLatestVersion</cmis:queryName> <cmis:description>This is a Is Latest Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:versionLabel</cmis:id> <cmis:localName>cmis:versionLabel</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Version Label</cmis:displayName> <cmis:queryName>cmis:versionLabel</cmis:queryName> <cmis:description>This is a Version Label property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isVersionSeriesCheckedOut</cmis:id> <cmis:localName>cmis:isVersionSeriesCheckedOut</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checked Out</cmis:displayName> <cmis:queryName>cmis:isVersionSeriesCheckedOut</cmis:queryName> <cmis:description>This is a Checked Out property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:lastModifiedBy</cmis:id> <cmis:localName>cmis:lastModifiedBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modified By</cmis:displayName> <cmis:queryName>cmis:lastModifiedBy</cmis:queryName> <cmis:description>This is a Modified By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:createdBy</cmis:id> <cmis:localName>cmis:createdBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Created By</cmis:displayName> <cmis:queryName>cmis:createdBy</cmis:queryName> <cmis:description>This is a Created By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:checkinComment</cmis:id> <cmis:localName>cmis:checkinComment</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Checkin Comment</cmis:displayName> <cmis:queryName>cmis:checkinComment</cmis:queryName> <cmis:description>This is a Checkin Comment property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectId</cmis:id> <cmis:localName>cmis:objectId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Object Id</cmis:displayName> <cmis:queryName>cmis:objectId</cmis:queryName> <cmis:description>This is a Object Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isMajorVersion</cmis:id> <cmis:localName>cmis:isMajorVersion</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Is Major Version</cmis:displayName> <cmis:queryName>cmis:isMajorVersion</cmis:queryName> <cmis:description>This is a Is Major Version property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyBooleanDefinition> <cmis:id>cmis:isImmutable</cmis:id> <cmis:localName>cmis:isImmutable</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Immutable</cmis:displayName> <cmis:queryName>cmis:isImmutable</cmis:queryName> <cmis:description>This is a Immutable property.</cmis:description> <cmis:propertyType>boolean</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyBooleanDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:baseTypeId</cmis:id> <cmis:localName>cmis:baseTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Base-Type-Id</cmis:displayName> <cmis:queryName>cmis:baseTypeId</cmis:queryName> <cmis:description>This is a Base-Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:lastModificationDate</cmis:id> <cmis:localName>cmis:lastModificationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modification Date</cmis:displayName> <cmis:queryName>cmis:lastModificationDate</cmis:queryName> <cmis:description>This is a Modification Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:contentStreamFileName</cmis:id> <cmis:localName>cmis:contentStreamFileName</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>File Name</cmis:displayName> <cmis:queryName>cmis:contentStreamFileName</cmis:queryName> <cmis:description>This is a File Name property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>true</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:versionable>false</cmis:versionable> <cmis:contentStreamAllowed>allowed</cmis:contentStreamAllowed> </cmism:types> </cmism:types> </cmism:getTypeChildrenResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/repository-infos.http����������������������������������������������0000664�0001750�0001750�00000022331�13407173247�017715� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*abd9e41c-b3aa-40a7-a73a-997c472010e8@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:abd9e41c-b3aa-40a7-a73a-997c472010e8";start-info="text/xml" --uuid:abd9e41c-b3aa-40a7-a73a-997c472010e8 Content-Id: <rootpart*abd9e41c-b3aa-40a7-a73a-997c472010e8@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version="1.0" encoding="UTF-8"?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-30T19:54:27Z</Created> <Expires>2013-10-01T19:54:27Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <getRepositoryInfoResponse xmlns="http://docs.oasis-open.org/ns/cmis/messaging/200908/" xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/"> <repositoryInfo> <cmis:repositoryId>mock</cmis:repositoryId> <cmis:repositoryName>Mockup</cmis:repositoryName> <cmis:repositoryDescription>Repository sent by mockup server</cmis:repositoryDescription> <cmis:vendorName>libcmis</cmis:vendorName> <cmis:productName>Libcmis mockup</cmis:productName> <cmis:productVersion>some-version</cmis:productVersion> <cmis:rootFolderId>root-folder</cmis:rootFolderId> <cmis:latestChangeLogToken>0</cmis:latestChangeLogToken> <cmis:capabilities> <cmis:capabilityACL>manage</cmis:capabilityACL> <cmis:capabilityAllVersionsSearchable>false</cmis:capabilityAllVersionsSearchable> <cmis:capabilityChanges>none</cmis:capabilityChanges> <cmis:capabilityContentStreamUpdatability>anytime</cmis:capabilityContentStreamUpdatability> <cmis:capabilityGetDescendants>true</cmis:capabilityGetDescendants> <cmis:capabilityGetFolderTree>true</cmis:capabilityGetFolderTree> <cmis:capabilityMultifiling>true</cmis:capabilityMultifiling> <cmis:capabilityPWCSearchable>false</cmis:capabilityPWCSearchable> <cmis:capabilityPWCUpdatable>true</cmis:capabilityPWCUpdatable> <cmis:capabilityQuery>bothcombined</cmis:capabilityQuery> <cmis:capabilityRenditions>read</cmis:capabilityRenditions> <cmis:capabilityUnfiling>true</cmis:capabilityUnfiling> <cmis:capabilityVersionSpecificFiling>false</cmis:capabilityVersionSpecificFiling> <cmis:capabilityJoin>none</cmis:capabilityJoin> </cmis:capabilities> <cmis:aclCapability> <cmis:supportedPermissions>basic</cmis:supportedPermissions> <cmis:propagation>objectonly</cmis:propagation> <cmis:permissions> <cmis:permission>cmis:read</cmis:permission> <cmis:description>Read</cmis:description> </cmis:permissions> <cmis:permissions> <cmis:permission>cmis:write</cmis:permission> <cmis:description>Write</cmis:description> </cmis:permissions> <cmis:permissions> <cmis:permission>cmis:all</cmis:permission> <cmis:description>All</cmis:description> </cmis:permissions> <cmis:mapping> <cmis:key>canGetDescendents.Folder</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canGetChildren.Folder</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canGetParents.Folder</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canGetFolderParent.Object</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canCreateDocument.Folder</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canCreateFolder.Folder</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canCreateRelationship.Source</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canCreateRelationship.Target</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canGetProperties.Object</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canViewContent.Object</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canUpdateProperties.Object</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canMove.Object</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canMove.Target</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canMove.Source</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canDelete.Object</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canDeleteTree.Folder</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canSetContent.Document</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canDeleteContent.Document</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canAddToFolder.Object</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canAddToFolder.Folder</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canRemoveFromFolder.Object</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canRemoveFromFolder.Folder</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canCheckout.Document</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canCancelCheckout.Document</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canCheckin.Document</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canGetAllVersions.VersionSeries</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canGetObjectRelationships.Object</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canAddPolicy.Object</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canAddPolicy.Policy</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canRemovePolicy.Object</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canRemovePolicy.Policy</cmis:key> <cmis:permission>cmis:write</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canGetAppliedPolicies.Object</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canGetACL.Object</cmis:key> <cmis:permission>cmis:read</cmis:permission> </cmis:mapping> <cmis:mapping> <cmis:key>canApplyACL.Object</cmis:key> <cmis:permission>cmis:all</cmis:permission> </cmis:mapping> </cmis:aclCapability> <cmis:cmisVersionSupported>1.0</cmis:cmisVersionSupported> <cmis:thinClientURI/> <cmis:changesIncomplete>true</cmis:changesIncomplete> <cmis:principalAnonymous>anonymous</cmis:principalAnonymous> <cmis:principalAnyone>anyone</cmis:principalAnyone> </repositoryInfo> </getRepositoryInfoResponse> </S:Body> </S:Envelope> --uuid:abd9e41c-b3aa-40a7-a73a-997c472010e8-- �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/test-document-updated.http�����������������������������������������0000664�0001750�0001750�00000030225�13407173247�020602� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getObjectResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:object> <cmis:properties> <cmis:propertyInteger queryName="cmis:contentStreamLength" displayName="Content Length" localName="cmis:contentStreamLength" propertyDefinitionId="cmis:contentStreamLength"> <cmis:value>12345</cmis:value> </cmis:propertyInteger> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>DocumentLevel2</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:versionSeriesCheckedOutBy" displayName="Checked Out By" localName="cmis:versionSeriesCheckedOutBy" propertyDefinitionId="cmis:versionSeriesCheckedOutBy"/> <cmis:propertyHtml queryName="HtmlProp" displayName="Sample Html Property" localName="HtmlProp" propertyDefinitionId="HtmlProp"/> <cmis:propertyId queryName="cmis:versionSeriesCheckedOutId" displayName="Checked Out Id" localName="cmis:versionSeriesCheckedOutId" propertyDefinitionId="cmis:versionSeriesCheckedOutId"/> <cmis:propertyId queryName="IdProp" displayName="Sample Id Property" localName="IdProp" propertyDefinitionId="IdProp"/> <cmis:propertyUri queryName="UriProp" displayName="Sample Uri Property" localName="UriProp" propertyDefinitionId="UriProp"/> <cmis:propertyDateTime queryName="DateTimePropMV" displayName="Sample DateTime multi-value Property" localName="DateTimePropMV" propertyDefinitionId="DateTimePropMV"/> <cmis:propertyId queryName="cmis:versionSeriesId" displayName="Version Series Id" localName="cmis:versionSeriesId" propertyDefinitionId="cmis:versionSeriesId"/> <cmis:propertyDecimal queryName="DecimalProp" displayName="Sample Decimal Property" localName="DecimalProp" propertyDefinitionId="DecimalProp"/> <cmis:propertyUri queryName="UriPropMV" displayName="Sample Uri multi-value Property" localName="UriPropMV" propertyDefinitionId="UriPropMV"/> <cmis:propertyBoolean queryName="cmis:isLatestVersion" displayName="Is Latest Version" localName="cmis:isLatestVersion" propertyDefinitionId="cmis:isLatestVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:versionLabel" displayName="Version Label" localName="cmis:versionLabel" propertyDefinitionId="cmis:versionLabel"/> <cmis:propertyBoolean queryName="BooleanProp" displayName="Sample Boolean Property" localName="BooleanProp" propertyDefinitionId="BooleanProp"/> <cmis:propertyBoolean queryName="cmis:isVersionSeriesCheckedOut" displayName="Checked Out" localName="cmis:isVersionSeriesCheckedOut" propertyDefinitionId="cmis:isVersionSeriesCheckedOut"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>unknown</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="IdPropMV" displayName="Sample Id Html multi-value Property" localName="IdPropMV" propertyDefinitionId="IdPropMV"/> <cmis:propertyString queryName="PickListProp" displayName="Sample Pick List Property" localName="PickListProp" propertyDefinitionId="PickListProp"> <cmis:value>blue</cmis:value> </cmis:propertyString> <cmis:propertyHtml queryName="HtmlPropMV" displayName="Sample Html multi-value Property" localName="HtmlPropMV" propertyDefinitionId="HtmlPropMV"/> <cmis:propertyInteger queryName="IntProp" displayName="Sample Int Property" localName="IntProp" propertyDefinitionId="IntProp"/> <cmis:propertyBoolean queryName="cmis:isLatestMajorVersion" displayName="Is Latest Major Version" localName="cmis:isLatestMajorVersion" propertyDefinitionId="cmis:isLatestMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyString queryName="cmis:contentStreamId" displayName="Stream Id" localName="cmis:contentStreamId" propertyDefinitionId="cmis:contentStreamId"/> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>New name</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:contentStreamMimeType" displayName="Mime Type" localName="cmis:contentStreamMimeType" propertyDefinitionId="cmis:contentStreamMimeType"> <cmis:value>text/plain</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="StringProp" displayName="Sample String Property" localName="StringProp" propertyDefinitionId="StringProp"> <cmis:value>My Doc StringProperty 6</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>some-new-change-token</cmis:value> </cmis:propertyString> <cmis:propertyDecimal queryName="DecimalPropMV" displayName="Sample Decimal multi-value Property" localName="DecimalPropMV" propertyDefinitionId="DecimalPropMV"/> <cmis:propertyDateTime queryName="DateTimeProp" displayName="Sample DateTime Property" localName="DateTimeProp" propertyDefinitionId="DateTimeProp"/> <cmis:propertyBoolean queryName="BooleanPropMV" displayName="Sample Boolean multi-value Property" localName="BooleanPropMV" propertyDefinitionId="BooleanPropMV"/> <cmis:propertyString queryName="cmis:checkinComment" displayName="Checkin Comment" localName="cmis:checkinComment" propertyDefinitionId="cmis:checkinComment"/> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>test-document</cmis:value> </cmis:propertyId> <cmis:propertyBoolean queryName="cmis:isImmutable" displayName="Immutable" localName="cmis:isImmutable" propertyDefinitionId="cmis:isImmutable"> <cmis:value>false</cmis:value> </cmis:propertyBoolean> <cmis:propertyBoolean queryName="cmis:isMajorVersion" displayName="Is Major Version" localName="cmis:isMajorVersion" propertyDefinitionId="cmis:isMajorVersion"> <cmis:value>true</cmis:value> </cmis:propertyBoolean> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:document</cmis:value> </cmis:propertyId> <cmis:propertyInteger queryName="IntPropMV" displayName="Sample Int multi-value Property" localName="IntPropMV" propertyDefinitionId="IntPropMV"/> <cmis:propertyString queryName="cmis:contentStreamFileName" displayName="File Name" localName="cmis:contentStreamFileName" propertyDefinitionId="cmis:contentStreamFileName"> <cmis:value>data.txt</cmis:value> </cmis:propertyString> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2013-01-28T14:10:06.736Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> <cmis:allowableActions> <cmis:canDeleteObject>true</cmis:canDeleteObject> <cmis:canUpdateProperties>true</cmis:canUpdateProperties> <cmis:canGetFolderTree>false</cmis:canGetFolderTree> <cmis:canGetProperties>true</cmis:canGetProperties> <cmis:canGetObjectRelationships>false</cmis:canGetObjectRelationships> <cmis:canGetObjectParents>true</cmis:canGetObjectParents> <cmis:canGetFolderParent>false</cmis:canGetFolderParent> <cmis:canGetDescendants>false</cmis:canGetDescendants> <cmis:canMoveObject>true</cmis:canMoveObject> <cmis:canDeleteContentStream>true</cmis:canDeleteContentStream> <cmis:canCheckOut>true</cmis:canCheckOut> <cmis:canCancelCheckOut>false</cmis:canCancelCheckOut> <cmis:canCheckIn>false</cmis:canCheckIn> <cmis:canSetContentStream>true</cmis:canSetContentStream> <cmis:canGetAllVersions>true</cmis:canGetAllVersions> <cmis:canAddObjectToFolder>true</cmis:canAddObjectToFolder> <cmis:canRemoveObjectFromFolder>true</cmis:canRemoveObjectFromFolder> <cmis:canGetContentStream>true</cmis:canGetContentStream> <cmis:canApplyPolicy>false</cmis:canApplyPolicy> <cmis:canGetAppliedPolicies>false</cmis:canGetAppliedPolicies> <cmis:canRemovePolicy>false</cmis:canRemovePolicy> <cmis:canGetChildren>false</cmis:canGetChildren> <cmis:canCreateDocument>false</cmis:canCreateDocument> <cmis:canCreateFolder>false</cmis:canCreateFolder> <cmis:canCreateRelationship>false</cmis:canCreateRelationship> <cmis:canDeleteTree>false</cmis:canDeleteTree> <cmis:canGetRenditions>false</cmis:canGetRenditions> <cmis:canGetACL>false</cmis:canGetACL> <cmis:canApplyACL>false</cmis:canApplyACL> </cmis:allowableActions> <exampleExtension:exampleExtension xmlns="http://mockup/cmis/extension" xmlns:exampleExtension="http://mockup/cmis/extension"> <objectId xmlns:ns0="http://mockup/cmis/extension" ns0:type="DocumentLevel2">test-document</objectId> <name>Test Document</name> </exampleExtension:exampleExtension> </cmism:object> </cmism:getObjectResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/secondary-type.http������������������������������������������������0000664�0001750�0001750�00000006271�13407173247�017335� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getTypeDefinitionResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:type> <cmis:id>secondary-type</cmis:id> <cmis:localName>secondary-type</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Secondary Type</cmis:displayName> <cmis:queryName>secondary-type</cmis:queryName> <cmis:description>Description of Secondary Type</cmis:description> <cmis:baseId>cmis:secondary</cmis:baseId> <cmis:parentId>cmis:secondary</cmis:parentId> <cmis:creatable>false</cmis:creatable> <cmis:fileable>false</cmis:fileable> <cmis:queryable>false</cmis:queryable> <cmis:fulltextIndexed>false</cmis:fulltextIndexed> <cmis:includedInSupertypeQuery>true</cmis:includedInSupertypeQuery> <cmis:controllablePolicy>false</cmis:controllablePolicy> <cmis:controllableACL>false</cmis:controllableACL> <cmis:propertyStringDefinition> <cmis:id>secondary-prop</cmis:id> <cmis:localName>secondary-prop</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>secondary-prop</cmis:displayName> <cmis:queryName>secondary-prop</cmis:queryName> <cmis:description>This is a Secondary type property</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> </cmism:type> </cmism:getTypeDefinitionResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/delete-object.http�������������������������������������������������0000664�0001750�0001750�00000002270�13407173247�017070� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:deleteObjectResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"/> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/get-content-stream.http��������������������������������������������0000664�0001750�0001750�00000003436�13407173247�020107� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getContentStreamResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:contentStream> <cmism:mimeType>text/plain</cmism:mimeType> <cmism:filename>test.txt</cmism:filename> <cmism:stream> <xop:Include xmlns:xop="http://www.w3.org/2004/08/xop/include" href="cid:stream*someid"/></cmism:stream> </cmism:contentStream> </cmism:getContentStreamResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <stream*someid> Content-Type: application/xop+xml;charset=utf-8;type="text/plain" Content-Transfer-Encoding: binary Some content stream --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/create-folder.http�������������������������������������������������0000664�0001750�0001750�00000002431�13407173247�017075� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:createFolderResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:objectId>created-folder</cmism:objectId> </cmism:createFolderResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/valid-object.http��������������������������������������������������0000664�0001750�0001750�00000015537�13407173247�016737� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getObjectResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:object> <cmis:properties> <cmis:propertyId queryName="cmis:allowedChildObjectTypeIds" displayName="Allowed Child Types" localName="cmis:allowedChildObjectTypeIds" propertyDefinitionId="cmis:allowedChildObjectTypeIds"> <cmis:value>*</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:path" displayName="Path" localName="cmis:path" propertyDefinitionId="cmis:path"> <cmis:value>/Valid Object</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:lastModifiedBy" displayName="Modified By" localName="cmis:lastModifiedBy" propertyDefinitionId="cmis:lastModifiedBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectTypeId" displayName="Type-Id" localName="cmis:objectTypeId" propertyDefinitionId="cmis:objectTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyString queryName="cmis:createdBy" displayName="Created By" localName="cmis:createdBy" propertyDefinitionId="cmis:createdBy"> <cmis:value>Admin</cmis:value> </cmis:propertyString> <cmis:propertyString queryName="cmis:name" displayName="Name" localName="cmis:name" propertyDefinitionId="cmis:name"> <cmis:value>Valid Object</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:objectId" displayName="Object Id" localName="cmis:objectId" propertyDefinitionId="cmis:objectId"> <cmis:value>valid-object</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:creationDate" displayName="Creation Date" localName="cmis:creationDate" propertyDefinitionId="cmis:creationDate"> <cmis:value>2012-11-29T16:14:47.019Z</cmis:value> </cmis:propertyDateTime> <cmis:propertyString queryName="cmis:changeToken" displayName="Change Token" localName="cmis:changeToken" propertyDefinitionId="cmis:changeToken"> <cmis:value>1354205687020</cmis:value> </cmis:propertyString> <cmis:propertyId queryName="cmis:baseTypeId" displayName="Base-Type-Id" localName="cmis:baseTypeId" propertyDefinitionId="cmis:baseTypeId"> <cmis:value>cmis:folder</cmis:value> </cmis:propertyId> <cmis:propertyId queryName="cmis:parentId" displayName="Parent Id" localName="cmis:parentId" propertyDefinitionId="cmis:parentId"> <cmis:value>root-folder</cmis:value> </cmis:propertyId> <cmis:propertyDateTime queryName="cmis:lastModificationDate" displayName="Modification Date" localName="cmis:lastModificationDate" propertyDefinitionId="cmis:lastModificationDate"> <cmis:value>2012-11-29T16:14:47.020Z</cmis:value> </cmis:propertyDateTime> </cmis:properties> <cmis:allowableActions> <cmis:canDeleteObject>true</cmis:canDeleteObject> <cmis:canUpdateProperties>true</cmis:canUpdateProperties> <cmis:canGetFolderTree>true</cmis:canGetFolderTree> <cmis:canGetProperties>true</cmis:canGetProperties> <cmis:canGetObjectRelationships>false</cmis:canGetObjectRelationships> <cmis:canGetObjectParents>true</cmis:canGetObjectParents> <cmis:canGetFolderParent>true</cmis:canGetFolderParent> <cmis:canGetDescendants>true</cmis:canGetDescendants> <cmis:canMoveObject>true</cmis:canMoveObject> <cmis:canDeleteContentStream>false</cmis:canDeleteContentStream> <cmis:canCheckOut>false</cmis:canCheckOut> <cmis:canCancelCheckOut>false</cmis:canCancelCheckOut> <cmis:canCheckIn>false</cmis:canCheckIn> <cmis:canSetContentStream>false</cmis:canSetContentStream> <cmis:canGetAllVersions>false</cmis:canGetAllVersions> <cmis:canAddObjectToFolder>false</cmis:canAddObjectToFolder> <cmis:canRemoveObjectFromFolder>false</cmis:canRemoveObjectFromFolder> <cmis:canGetContentStream>false</cmis:canGetContentStream> <cmis:canApplyPolicy>false</cmis:canApplyPolicy> <cmis:canGetAppliedPolicies>false</cmis:canGetAppliedPolicies> <cmis:canRemovePolicy>false</cmis:canRemovePolicy> <cmis:canGetChildren>true</cmis:canGetChildren> <cmis:canCreateDocument>true</cmis:canCreateDocument> <cmis:canCreateFolder>true</cmis:canCreateFolder> <cmis:canCreateRelationship>false</cmis:canCreateRelationship> <cmis:canDeleteTree>true</cmis:canDeleteTree> <cmis:canGetRenditions>false</cmis:canGetRenditions> <cmis:canGetACL>false</cmis:canGetACL> <cmis:canApplyACL>false</cmis:canApplyACL> </cmis:allowableActions> <exampleExtension:exampleExtension xmlns="http://my/cmis/extension" xmlns:exampleExtension="http://my/cmis/extension"> <objectId xmlns:ns0="http://my/cmis/extension" ns0:type="cmis:folder">valid-object</objectId> <name>Valid Object</name> </exampleExtension:exampleExtension> </cmism:object> </cmism:getObjectResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- �����������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/data/ws/type-folder.http���������������������������������������������������0000664�0001750�0001750�00000033173�13407173247�016622� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������Content-Type: multipart/related;start="<rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com>";type="application/xop+xml";boundary="uuid:846b7f14-435a-4809-845f-b98822f936ab";start-info="text/xml" --uuid:846b7f14-435a-4809-845f-b98822f936ab Content-Id: <rootpart*846b7f14-435a-4809-845f-b98822f936ab@example.jaxws.sun.com> Content-Type: application/xop+xml;charset=utf-8;type="text/xml" Content-Transfer-Encoding: binary <?xml version='1.0' encoding='UTF-8'?> <S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"> <S:Header> <Security xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"> <Timestamp xmlns="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"> <Created>2013-09-16T13:34:16Z</Created> <Expires>2013-09-17T13:34:16Z</Expires> </Timestamp> </Security> </S:Header> <S:Body> <cmism:getTypeDefinitionResponse xmlns:cmis="http://docs.oasis-open.org/ns/cmis/core/200908/" xmlns:cmism="http://docs.oasis-open.org/ns/cmis/messaging/200908/"> <cmism:type> <cmis:id>cmis:folder</cmis:id> <cmis:localName>cmis:folder</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>CMIS Folder</cmis:displayName> <cmis:queryName>cmis:folder</cmis:queryName> <cmis:description>Description of CMIS Folder Type</cmis:description> <cmis:baseId>cmis:folder</cmis:baseId> <cmis:creatable>true</cmis:creatable> <cmis:fileable>true</cmis:fileable> <cmis:queryable>false</cmis:queryable> <cmis:fulltextIndexed>false</cmis:fulltextIndexed> <cmis:includedInSupertypeQuery>true</cmis:includedInSupertypeQuery> <cmis:controllablePolicy>false</cmis:controllablePolicy> <cmis:controllableACL>true</cmis:controllableACL> <cmis:propertyIdDefinition> <cmis:id>cmis:allowedChildObjectTypeIds</cmis:id> <cmis:localName>cmis:allowedChildObjectTypeIds</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Allowed Child Types</cmis:displayName> <cmis:queryName>cmis:allowedChildObjectTypeIds</cmis:queryName> <cmis:description>This is a Allowed Child Types property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>multi</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:path</cmis:id> <cmis:localName>cmis:path</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Path</cmis:displayName> <cmis:queryName>cmis:path</cmis:queryName> <cmis:description>This is a Path property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:lastModifiedBy</cmis:id> <cmis:localName>cmis:lastModifiedBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modified By</cmis:displayName> <cmis:queryName>cmis:lastModifiedBy</cmis:queryName> <cmis:description>This is a Modified By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectTypeId</cmis:id> <cmis:localName>cmis:objectTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Type-Id</cmis:displayName> <cmis:queryName>cmis:objectTypeId</cmis:queryName> <cmis:description>This is a Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>oncreate</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:createdBy</cmis:id> <cmis:localName>cmis:createdBy</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Created By</cmis:displayName> <cmis:queryName>cmis:createdBy</cmis:queryName> <cmis:description>This is a Created By property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:name</cmis:id> <cmis:localName>cmis:name</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Name</cmis:displayName> <cmis:queryName>cmis:name</cmis:queryName> <cmis:description>This is a Name property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readwrite</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>true</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:objectId</cmis:id> <cmis:localName>cmis:objectId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Object Id</cmis:displayName> <cmis:queryName>cmis:objectId</cmis:queryName> <cmis:description>This is a Object Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:creationDate</cmis:id> <cmis:localName>cmis:creationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Creation Date</cmis:displayName> <cmis:queryName>cmis:creationDate</cmis:queryName> <cmis:description>This is a Creation Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> <cmis:propertyStringDefinition> <cmis:id>cmis:changeToken</cmis:id> <cmis:localName>cmis:changeToken</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Change Token</cmis:displayName> <cmis:queryName>cmis:changeToken</cmis:queryName> <cmis:description>This is a Change Token property.</cmis:description> <cmis:propertyType>string</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyStringDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:baseTypeId</cmis:id> <cmis:localName>cmis:baseTypeId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Base-Type-Id</cmis:displayName> <cmis:queryName>cmis:baseTypeId</cmis:queryName> <cmis:description>This is a Base-Type-Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyIdDefinition> <cmis:id>cmis:parentId</cmis:id> <cmis:localName>cmis:parentId</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Parent Id</cmis:displayName> <cmis:queryName>cmis:parentId</cmis:queryName> <cmis:description>This is a Parent Id property.</cmis:description> <cmis:propertyType>id</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyIdDefinition> <cmis:propertyDateTimeDefinition> <cmis:id>cmis:lastModificationDate</cmis:id> <cmis:localName>cmis:lastModificationDate</cmis:localName> <cmis:localNamespace>local</cmis:localNamespace> <cmis:displayName>Modification Date</cmis:displayName> <cmis:queryName>cmis:lastModificationDate</cmis:queryName> <cmis:description>This is a Modification Date property.</cmis:description> <cmis:propertyType>datetime</cmis:propertyType> <cmis:cardinality>single</cmis:cardinality> <cmis:updatability>readonly</cmis:updatability> <cmis:inherited>false</cmis:inherited> <cmis:required>false</cmis:required> <cmis:queryable>true</cmis:queryable> <cmis:orderable>true</cmis:orderable> <cmis:openChoice>false</cmis:openChoice> </cmis:propertyDateTimeDefinition> </cmism:type> </cmism:getTypeDefinitionResponse> </S:Body> </S:Envelope> --uuid:846b7f14-435a-4809-845f-b98822f936ab-- �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/test-mockup-helpers.cxx����������������������������������������������������0000664�0001750�0001750�00000003246�13407173247�016562� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <test-helpers.hxx> #include <mockup-config.h> using namespace std; namespace test { void addWsResponse( const char* url, const char* filename, const char* bodyMatch = 0 ) { string outBuf; loadFromFile( filename, outBuf ); string emptyLine = ( "\n\n" ); size_t pos = outBuf.find( emptyLine ); string headers = outBuf.substr( 0, pos ); string body = outBuf.substr( pos + emptyLine.size() ); curl_mockup_addResponse( url, "", "POST", body.c_str(), 0, false, headers.c_str(), bodyMatch ); } } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/test-onedrive.cxx����������������������������������������������������������0000664�0001750�0001750�00000077266�13407414352�015447� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga <mihai.mv13@gmail.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <cppunit/extensions/HelperMacros.h> #include <cppunit/TestFixture.h> #include <cppunit/TestAssert.h> #include <string> #if defined __clang__ #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wkeyword-macro" #endif #define private public #define protected public #if defined __clang__ #pragma clang diagnostic pop #endif #include <mockup-config.h> #include <fstream> #include <libcmis/document.hxx> #include "onedrive-object.hxx" #include "onedrive-property.hxx" #include "onedrive-session.hxx" #include "oauth2-handler.hxx" using namespace std; using namespace libcmis; static const string CLIENT_ID ( "mock-id" ); static const string CLIENT_SECRET ( "mock-secret" ); static const string USERNAME( "mock-user" ); static const string PASSWORD( "mock-password" ); static const string LOGIN_URL ("https://login/url" ); static const string LOGIN_URL2 ("https://login2/url" ); static const string APPROVAL_URL ("https://approval/url" ); static const string AUTH_URL ( "https://auth/url" ); static const string TOKEN_URL ( "https://token/url" ); static const string SCOPE ( "https://scope/url" ); static const string REDIRECT_URI ("redirect:uri" ); static const string BASE_URL ( "https://base/url" ); class OneDriveTest : public CppUnit::TestFixture { public: void sessionAuthenticationTest( ); void sessionExpiryTokenGetTest( ); void getRepositoriesTest( ); void getObjectTypeDocumentTest( ); void getObjectTypeFolderTest( ); void getObjectTest( ); void filePropertyTest( ); void deleteTest( ); void updatePropertiesTest( ); void getFileAllowableActionsTest( ); void getFolderAllowableActionsTest( ); void getFolderTest( ); void getChildrenTest( ); void moveTest( ); void getDocumentTest( ); void getDocumentParentTest( ); void getContentStreamTest( ); void setContentStreamTest( ); void createDocumentTest( ); void getObjectByPathTest( ); CPPUNIT_TEST_SUITE( OneDriveTest ); CPPUNIT_TEST( sessionAuthenticationTest ); CPPUNIT_TEST( sessionExpiryTokenGetTest ); CPPUNIT_TEST( getRepositoriesTest ); CPPUNIT_TEST( getObjectTypeDocumentTest ); CPPUNIT_TEST( getObjectTypeFolderTest ); CPPUNIT_TEST( getObjectTest ); CPPUNIT_TEST( filePropertyTest ); CPPUNIT_TEST( deleteTest ); CPPUNIT_TEST( updatePropertiesTest ); CPPUNIT_TEST( getFileAllowableActionsTest ); CPPUNIT_TEST( getFolderAllowableActionsTest ); CPPUNIT_TEST( getFolderTest ); CPPUNIT_TEST( getChildrenTest ); CPPUNIT_TEST( moveTest ); CPPUNIT_TEST( getDocumentTest ); CPPUNIT_TEST( getDocumentParentTest ); CPPUNIT_TEST( getContentStreamTest ); CPPUNIT_TEST( setContentStreamTest ); CPPUNIT_TEST( createDocumentTest ); CPPUNIT_TEST( getObjectByPathTest ); CPPUNIT_TEST_SUITE_END( ); private: OneDriveSession getTestSession( string username, string password ); }; OneDriveSession OneDriveTest::getTestSession( string username, string password ) { libcmis::OAuth2DataPtr oauth2( new libcmis::OAuth2Data( AUTH_URL, TOKEN_URL, SCOPE, REDIRECT_URI, CLIENT_ID, CLIENT_SECRET )); curl_mockup_reset( ); string empty; // login, authentication & approval are done manually at the moment, so I'll // temporarily borrow them from gdrive //login response string loginIdentifier = string("scope=") + SCOPE + string("&redirect_uri=") + REDIRECT_URI + string("&response_type=code") + string("&client_id=") + CLIENT_ID; curl_mockup_addResponse ( AUTH_URL.c_str(), loginIdentifier.c_str( ), "GET", DATA_DIR "/gdrive/login1.html", 200, true); //authentication email curl_mockup_addResponse( LOGIN_URL2.c_str( ), empty.c_str( ), "POST", DATA_DIR "/gdrive/login2.html", 200, true); //authentication password curl_mockup_addResponse( LOGIN_URL.c_str( ), empty.c_str( ), "POST", DATA_DIR "/gdrive/approve.html", 200, true); //approval response curl_mockup_addResponse( APPROVAL_URL.c_str( ), empty.c_str( ), "POST", DATA_DIR "/gdrive/authcode.html", 200, true); // token response curl_mockup_addResponse ( TOKEN_URL.c_str( ), empty.c_str( ), "POST", DATA_DIR "/onedrive/token-response.json", 200, true ); return OneDriveSession( BASE_URL, username, password, oauth2, false ); } void OneDriveTest::sessionAuthenticationTest( ) { OneDriveSession session = getTestSession( USERNAME, PASSWORD ); string empty; // Check token request string expectedTokenRequest = string( "code=AuthCode") + string( "&client_id=") + CLIENT_ID + string( "&client_secret=") + CLIENT_SECRET + string( "&redirect_uri=") + REDIRECT_URI + string( "&grant_type=authorization_code" ); string tokenRequest( curl_mockup_getRequestBody( TOKEN_URL.c_str(), empty.c_str( ), "POST" ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong token request", expectedTokenRequest, tokenRequest ); // Check token CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong access token", string ( "mock-access-token" ), session.m_oauth2Handler->getAccessToken( )); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong refresh token", string ("mock-refresh-token"), session.m_oauth2Handler->getRefreshToken( )); } void OneDriveTest::sessionExpiryTokenGetTest( ) { // Access_token will expire after expires_in seconds, // We need to use the refresh key to get a new one. curl_mockup_reset( ); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); curl_mockup_reset( ); static const string objectId("aFileId"); string url = BASE_URL + "/me/skydrive/files/" + objectId; // 401 response, token is expired curl_mockup_addResponse( url.c_str( ),"", "GET", "", 401, false ); curl_mockup_addResponse( TOKEN_URL.c_str(), "", "POST", DATA_DIR "/onedrive/refresh-response.json", 200, true); try { // GET expires, need to refresh then GET again libcmis::ObjectPtr obj = session.getObject( objectId ); } catch ( ... ) { if ( session.getHttpStatus( ) == 401 ) { // Check if access token is refreshed CPPUNIT_ASSERT_EQUAL_MESSAGE( "wrong access token", string ( "new-access-token" ), session.m_oauth2Handler->getAccessToken( ) ); } } } void OneDriveTest::getRepositoriesTest( ) { curl_mockup_reset( ); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); vector< libcmis::RepositoryPtr > actual = session.getRepositories( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of repositories", size_t( 1 ), actual.size( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong repository found", string ( "OneDrive" ), actual.front()->getId( ) ); } void OneDriveTest::getObjectTypeDocumentTest() { curl_mockup_reset( ); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); libcmis::ObjectTypePtr actual = session.getType("cmis:document"); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong type ID", string("cmis:document"), actual->getId() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong type queryName", string("cmis:document"), actual->getQueryName() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong parent", string(""), actual->getParentTypeId() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong base type", string("cmis:document"), actual->getBaseTypeId() ); CPPUNIT_ASSERT( actual->getParentType().get() == NULL ); CPPUNIT_ASSERT_EQUAL( string( "cmis:document" ), actual->getBaseType()->getId() ); CPPUNIT_ASSERT( actual->isCreatable() ); CPPUNIT_ASSERT( !actual->isVersionable() ); CPPUNIT_ASSERT( actual->isFileable() ); CPPUNIT_ASSERT( actual->isQueryable() ); CPPUNIT_ASSERT( actual->isFulltextIndexed() ); CPPUNIT_ASSERT_EQUAL( libcmis::ObjectType::Allowed, actual->getContentStreamAllowed() ); map< string, libcmis::PropertyTypePtr > props = actual->getPropertiesTypes(); CPPUNIT_ASSERT_MESSAGE( "Missing property cmis:name", props.find("cmis:name") != props.end() ); CPPUNIT_ASSERT_MESSAGE( "Missing property cmis:name", props.find("cmis:name") != props.end() ); CPPUNIT_ASSERT_MESSAGE( "Missing property cmis:contentStreamFileName", props.find("cmis:contentStreamFileName") != props.end() ); CPPUNIT_ASSERT_MESSAGE( "Missing property cmis:contentStreamLength", props.find("cmis:contentStreamLength") != props.end() ); } void OneDriveTest::getObjectTypeFolderTest() { curl_mockup_reset( ); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); libcmis::ObjectTypePtr actual = session.getType("cmis:folder"); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong type ID", string("cmis:folder"), actual->getId() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong type queryName", string("cmis:folder"), actual->getQueryName() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong parent", string(""), actual->getParentTypeId() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong base type", string("cmis:folder"), actual->getBaseTypeId() ); CPPUNIT_ASSERT( actual->getParentType().get() == NULL ); CPPUNIT_ASSERT_EQUAL( string( "cmis:folder" ), actual->getBaseType()->getId() ); CPPUNIT_ASSERT( actual->isCreatable() ); CPPUNIT_ASSERT( !actual->isVersionable() ); CPPUNIT_ASSERT( actual->isFileable() ); CPPUNIT_ASSERT( actual->isQueryable() ); CPPUNIT_ASSERT( !actual->isFulltextIndexed() ); CPPUNIT_ASSERT_EQUAL( libcmis::ObjectType::NotAllowed, actual->getContentStreamAllowed() ); map< string, libcmis::PropertyTypePtr > props = actual->getPropertiesTypes(); CPPUNIT_ASSERT_MESSAGE( "Missing property cmis:name", props.find("cmis:name") != props.end() ); CPPUNIT_ASSERT_MESSAGE( "Property cmis:contentStreamFileName shouldn't be set", props.find("cmis:contentStreamFileName") == props.end() ); CPPUNIT_ASSERT_MESSAGE( "Property cmis:contentStreamLength shouldn't be set", props.find("cmis:contentStreamLength") == props.end() ); } void OneDriveTest::getObjectTest() { static const string objectId ("aFileId"); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); string url = BASE_URL + "/" + objectId; curl_mockup_addResponse ( url.c_str( ), "", "GET", DATA_DIR "/onedrive/file.json", 200, true); libcmis::ObjectPtr object = session.getObject( objectId ); boost::shared_ptr<OneDriveObject> obj = boost::dynamic_pointer_cast <OneDriveObject>( object ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong Object Id", objectId, obj->getId( ) ); } void OneDriveTest::filePropertyTest( ) { curl_mockup_reset( ); static const string objectId ("aFileId"); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); string url = BASE_URL + "/" + objectId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/onedrive/file.json", 200, true); libcmis::ObjectPtr obj = session.getObject( objectId ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong creation date", string ( "2014-06-09T08:24:04+0000" ), obj->getStringProperty( "cmis:creationDate" ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong object id", string ( "aFileId" ), obj->getStringProperty( "cmis:objectId" ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong author", string ( "onedriveUser" ), obj->getStringProperty( "cmis:createdBy" ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong file name", string ( "OneDriveFile" ), obj->getStringProperty( "cmis:contentStreamFileName" ) ); } void OneDriveTest::deleteTest( ) { curl_mockup_reset( ); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); const string objectId( "aFileId" ); string url = BASE_URL + "/" + objectId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/onedrive/file.json", 200, true); curl_mockup_addResponse( url.c_str( ),"", "DELETE", "", 204, false); libcmis::ObjectPtr object = session.getObject( objectId ); object->remove( ); const struct HttpRequest* deleteRequest = curl_mockup_getRequest( url.c_str( ), "", "DELETE" ); CPPUNIT_ASSERT_MESSAGE( "Delete request not sent", deleteRequest ); curl_mockup_HttpRequest_free( deleteRequest ); } void OneDriveTest::updatePropertiesTest( ) { curl_mockup_reset( ); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); const string objectId( "aFileId" ); const string newObjectId( "aNewFileId" ); const string objectUrl = BASE_URL + "/" + objectId; const string newObjectUrl = BASE_URL + "/" + newObjectId; curl_mockup_addResponse( objectUrl.c_str( ), "", "GET", DATA_DIR "/onedrive/file.json", 200, true ); curl_mockup_addResponse( newObjectUrl.c_str( ), "", "GET", DATA_DIR "/onedrive/updated-file.json", 200, true ); curl_mockup_addResponse( objectUrl.c_str( ), "", "PUT", DATA_DIR "/onedrive/updated-file.json", 200, true ); libcmis::ObjectPtr object = session.getObject( objectId ); libcmis::ObjectPtr newObject = session.getObject( newObjectId ); object->updateProperties( newObject->getProperties( ) ); const char* updateRequest = curl_mockup_getRequestBody( objectUrl.c_str( ), "", "PUT" ); Json json = Json::parse( string( updateRequest ) ); string name = json["name"].toString( ); string description = json["description"].toString( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Name key not converted", string( "New File Name"), name ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Description key not converted", string( "new description"), description ); } void OneDriveTest::getFileAllowableActionsTest( ) { curl_mockup_reset( ); static const string objectId ("aFileId"); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); string url = BASE_URL + "/" + objectId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/onedrive/file.json", 200, true); libcmis::ObjectPtr object = session.getObject( objectId ); boost::shared_ptr< libcmis::AllowableActions > actions = object->getAllowableActions( ); CPPUNIT_ASSERT_MESSAGE( "GetContentStream allowable action should be true", actions->isDefined( libcmis::ObjectAction::GetContentStream ) && actions->isAllowed( libcmis::ObjectAction::GetContentStream ) ); CPPUNIT_ASSERT_MESSAGE( "CreateDocument allowable action should be false", actions->isDefined( libcmis::ObjectAction::CreateDocument ) && !actions->isAllowed( libcmis::ObjectAction::CreateDocument ) ); } void OneDriveTest::getFolderAllowableActionsTest( ) { curl_mockup_reset( ); static const string objectId ("aFolderId"); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); string url = BASE_URL + "/" + objectId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/onedrive/folder.json", 200, true); libcmis::ObjectPtr object = session.getObject( objectId ); boost::shared_ptr< libcmis::AllowableActions > actions = object->getAllowableActions( ); CPPUNIT_ASSERT_MESSAGE( "CreateDocument allowable action should be true", actions->isDefined( libcmis::ObjectAction::CreateDocument ) && actions->isAllowed( libcmis::ObjectAction::CreateDocument ) ); CPPUNIT_ASSERT_MESSAGE( "GetContentStream allowable action should be false", actions->isDefined( libcmis::ObjectAction::GetContentStream ) && !actions->isAllowed( libcmis::ObjectAction::GetContentStream ) ); } void OneDriveTest::getFolderTest( ) { curl_mockup_reset( ); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); static const string folderId( "aFolderId" ); static const string parentId( "aParentId" ); string url = BASE_URL + "/" + folderId; string parentUrl = BASE_URL + "/" + parentId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/onedrive/folder.json", 200, true); curl_mockup_addResponse( parentUrl.c_str( ), "", "GET", DATA_DIR "/onedrive/parent-folder.json", 200, true); libcmis::FolderPtr folder = session.getFolder( folderId ); CPPUNIT_ASSERT_MESSAGE( "Fetched object should be an instance of libcmis::FolderPtr", NULL != folder ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong folder ID", folderId, folder->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong folder name", string( "OneDrive Folder" ), folder->getName( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong base type", string( "cmis:folder" ), folder->getBaseType( ) ); CPPUNIT_ASSERT_MESSAGE( "Missing folder parent", folder->getFolderParent( ).get( ) ); CPPUNIT_ASSERT_MESSAGE( "Not a root folder", !folder->isRootFolder() ); CPPUNIT_ASSERT_MESSAGE( "CreatedBy is missing", !folder->getCreatedBy( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "CreationDate is missing", !folder->getCreationDate( ).is_not_a_date_time() ); CPPUNIT_ASSERT_MESSAGE( "LastModificationDate is missing", !folder->getLastModificationDate( ).is_not_a_date_time() ); } void OneDriveTest::getChildrenTest( ) { curl_mockup_reset( ); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); static const string folderId ("aFolderId"); string url = BASE_URL + "/" + folderId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/onedrive/folder.json", 200, true); libcmis::ObjectPtr obj = session.getObject( folderId ); libcmis::FolderPtr folder = session.getFolder( folderId ); CPPUNIT_ASSERT_MESSAGE( "Fetched object should be an instance of libcmis::FolderPtr", NULL != folder ); string childrenUrl = BASE_URL + "/" + folderId + "/files"; curl_mockup_addResponse( childrenUrl.c_str( ), "", "GET", DATA_DIR "/onedrive/folder-listed.json", 200, true); vector< libcmis::ObjectPtr > children= folder->getChildren( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad number of children", size_t( 2 ), children.size() ); int folderCount = 0; int fileCount = 0; for ( vector< libcmis::ObjectPtr >::iterator it = children.begin( ); it != children.end( ); ++it ) { if ( NULL != boost::dynamic_pointer_cast< libcmis::Folder >( *it ) ) ++folderCount; else ++fileCount; } CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of folder children", 1, folderCount ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of file children", 1, fileCount ); } void OneDriveTest::moveTest( ) { curl_mockup_reset( ); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); const string objectId( "aFileId" ); const string sourceId( "aFolderId" ); const string desId( "aParentId" ); string url = BASE_URL + "/" + objectId; string sourceUrl = BASE_URL + "/" + sourceId; string desUrl = BASE_URL + "/" + desId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/onedrive/file.json", 200, true ); curl_mockup_addResponse( url.c_str( ), "method=MOVE", "POST", DATA_DIR "/onedrive/file.json", 200, true ); curl_mockup_addResponse( desUrl.c_str( ), "", "GET", DATA_DIR "/onedrive/parent-folder.json", 200, true ); curl_mockup_addResponse( sourceUrl.c_str( ), "", "GET", DATA_DIR "/onedrive/folder.json", 200, true ); libcmis::ObjectPtr object = session.getObject( objectId ); libcmis::FolderPtr source = session.getFolder( sourceId ); libcmis::FolderPtr destination = session.getFolder( desId ); object->move( source, destination ); const char* moveRequest = curl_mockup_getRequestBody( url.c_str( ), "method=MOVE", "POST" ); Json parentJson = Json::parse( string( moveRequest ) ); string newParentId = parentJson["destination"].toString( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad new parent folder", desId, newParentId); } void OneDriveTest::getDocumentTest( ) { curl_mockup_reset( ); static const string objectId ("aFileId"); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); string url = BASE_URL + "/" + objectId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/onedrive/file.json", 200, true); libcmis::ObjectPtr obj = session.getObject( objectId ); // Check if we got the document object. libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( obj ); CPPUNIT_ASSERT_MESSAGE( "Fetched object should be an instance of libcmis::DocumentPtr", NULL != document ); // Test the document properties CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong document ID", objectId, document->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong document name", string( "OneDriveFile" ), document->getName( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong base type", string( "cmis:document" ), document->getBaseType( ) ); CPPUNIT_ASSERT_MESSAGE( "CreatedBy is missing", !document->getCreatedBy( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "CreationDate is missing", !document->getCreationDate( ).is_not_a_date_time() ); CPPUNIT_ASSERT_MESSAGE( "LastModificationDate is missing", !document->getLastModificationDate( ).is_not_a_date_time() ); CPPUNIT_ASSERT_MESSAGE( "Content length is incorrect", 42 == document->getContentLength( ) ); } void OneDriveTest::getDocumentParentTest( ) { curl_mockup_reset( ); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); static const string documentId( "aFileId" ); static const string parentId( "aParentId" ); string url = BASE_URL + "/" + documentId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/onedrive/file.json", 200, true); string parentUrl = BASE_URL + "/" + parentId; curl_mockup_addResponse( parentUrl.c_str( ), "", "GET", DATA_DIR "/onedrive/parent-folder.json", 200, true); libcmis::ObjectPtr object = session.getObject( "aFileId" ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); CPPUNIT_ASSERT_MESSAGE( "Document expected", document != NULL ); vector< libcmis::FolderPtr > parents= document->getParents( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad number of parents", size_t( 1 ), parents.size() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong parent Id", parentId, parents[0]->getId( ) ); } void OneDriveTest::getContentStreamTest( ) { curl_mockup_reset( ); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); static const string documentId( "aFileId" ); string url = BASE_URL + "/" + documentId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/onedrive/file.json", 200, true); string expectedContent( "Test content stream" ); string downloadUrl = "sourceUrl"; curl_mockup_addResponse( downloadUrl.c_str( ), "", "GET", expectedContent.c_str( ), 0, false ); libcmis::ObjectPtr object = session.getObject( documentId ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); try { boost::shared_ptr< istream > is = document->getContentStream( ); ostringstream out; out << is->rdbuf(); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Content stream doesn't match", expectedContent, out.str( ) ); } catch ( const libcmis::Exception& e ) { string msg = "Unexpected exception: "; msg += e.what(); CPPUNIT_FAIL( msg.c_str() ); } } void OneDriveTest::setContentStreamTest( ) { curl_mockup_reset( ); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); const string documentId( "aFileId" ); string url = BASE_URL + "/" + documentId; string putUrl = BASE_URL + "/aParentId/files/OneDriveFile"; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/onedrive/file.json", 200, true); libcmis::ObjectPtr object = session.getObject( documentId ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); curl_mockup_addResponse( url.c_str( ), "", "PUT", DATA_DIR "/onedrive/file.json", 200, true); curl_mockup_addResponse( putUrl.c_str( ), "overwrite=true", "PUT", "Updated", 0, false ); try { string expectedContent( "Test set content stream" ); boost::shared_ptr< ostream > os ( new stringstream ( expectedContent ) ); string filename( "aFileName" ); document->setContentStream( os, "text/plain", filename ); CPPUNIT_ASSERT_MESSAGE( "Object not refreshed during setContentStream", object->getRefreshTimestamp( ) > 0 ); // Check if metadata has been properly uploaded const char* meta = curl_mockup_getRequestBody( url.c_str( ), "", "PUT" ); string expectedMeta = "{\n \"name\": \"aFileName\"\n}\n"; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad meta uploaded", expectedMeta, string( meta ) ); // Check the content has been properly uploaded const char* content = curl_mockup_getRequestBody( putUrl.c_str( ), "", "PUT" ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad content uploaded", expectedContent, string( content ) ); } catch ( const libcmis::Exception& e ) { string msg = "Unexpected exception: "; msg += e.what(); CPPUNIT_FAIL( msg.c_str() ); } } void OneDriveTest::createDocumentTest( ) { curl_mockup_reset( ); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); const string documentId( "aFileId" ); const string folderId( "aParentId" ); const string filename( "aFileName" ); const string folderUrl = BASE_URL + "/" + folderId; const string uploadUrl = folderUrl + "/files/" + filename; const string documentUrl = BASE_URL + "/" + documentId; curl_mockup_addResponse( folderUrl.c_str( ), "", "GET", DATA_DIR "/onedrive/parent-folder.json", 200, true ); curl_mockup_addResponse( uploadUrl.c_str( ), "", "PUT", DATA_DIR "/onedrive/new-file.json", 200, true ); curl_mockup_addResponse( documentUrl.c_str( ), "", "PUT", DATA_DIR "/onedrive/file.json", 200, true ); curl_mockup_addResponse( documentUrl.c_str( ), "", "GET", DATA_DIR "/onedrive/file.json", 200, true ); libcmis::FolderPtr parent = session.getFolder( folderId ); try { string expectedContent( "Test set content stream" ); boost::shared_ptr< ostream > os ( new stringstream ( expectedContent ) ); PropertyPtrMap properties; parent->createDocument( properties, os, "text/plain", filename ); curl_mockup_getRequestBody( documentUrl.c_str( ), "", "PUT" ); const char* content = curl_mockup_getRequestBody( uploadUrl.c_str( ), "", "PUT" ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad content uploaded", expectedContent, string( content ) ); } catch ( const libcmis::Exception& e ) { string msg = "Unexpected exception: "; msg += e.what( ); CPPUNIT_FAIL( msg.c_str( ) ); } } void OneDriveTest::getObjectByPathTest( ) { curl_mockup_reset( ); OneDriveSession session = getTestSession( USERNAME, PASSWORD ); const string documentId( "rightFile" ); const string wrongDocumentId( "wrongFile" ); const string folderAId( "folderA" ); // root const string folderBId( "folderB" ); const string folderCId( "folderC" ); const string path( "/Folder B/Folder C/OneDriveFile" ); const string documentUrl = BASE_URL + "/" + documentId; const string wrongDocumentUrl = BASE_URL + "/" + wrongDocumentId; const string folderAUrl = BASE_URL + "/" + folderAId; const string folderBUrl = BASE_URL + "/" + folderBId; const string folderCUrl = BASE_URL + "/" + folderCId; const string searchUrl = BASE_URL + "/me/skydrive/search"; curl_mockup_addResponse( documentUrl.c_str( ), "", "GET", DATA_DIR "/onedrive/searched-file.json", 200, true ); curl_mockup_addResponse( wrongDocumentUrl.c_str( ), "", "GET", DATA_DIR "/onedrive/searched-wrong-file.json", 200, true ); curl_mockup_addResponse( searchUrl.c_str( ), "q=OneDriveFile", "GET", DATA_DIR "/onedrive/search-result.json", 200, true ); curl_mockup_addResponse( folderAUrl.c_str( ), "", "GET", DATA_DIR "/onedrive/folderA.json", 200, true ); curl_mockup_addResponse( folderBUrl.c_str( ), "", "GET", DATA_DIR "/onedrive/folderB.json", 200, true ); curl_mockup_addResponse( folderCUrl.c_str( ), "", "GET", DATA_DIR "/onedrive/folderC.json", 200, true ); libcmis::ObjectPtr object = session.getObjectByPath( path ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong objectFetched", documentId, object->getId( ) ); } CPPUNIT_TEST_SUITE_REGISTRATION( OneDriveTest ); ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/test-main.cxx��������������������������������������������������������������0000664�0001750�0001750�00000002640�13407173247�014545� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <cppunit/extensions/TestFactoryRegistry.h> #include <cppunit/ui/text/TestRunner.h> int main( int, char** ) { CppUnit::TextUi::TestRunner runner; CppUnit::TestFactoryRegistry ®istry = CppUnit::TestFactoryRegistry::getRegistry(); runner.addTest( registry.makeTest() ); bool wasSuccess = runner.run( "", false ); return !wasSuccess; } ������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/test-decoder.cxx�����������������������������������������������������������0000664�0001750�0001750�00000014010�13407414352�015213� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <cppunit/extensions/HelperMacros.h> #include <cppunit/TestFixture.h> #include <cppunit/TestAssert.h> #include <cppunit/ui/text/TestRunner.h> #include <libcmis/xml-utils.hxx> #define BASE64_ENCODING string( "base64" ) using namespace std; class DecoderTest : public CppUnit::TestFixture { private: libcmis::EncodedData* data; FILE* stream; string getActual( ); public: DecoderTest( ); DecoderTest( const DecoderTest& rCopy ); DecoderTest& operator=( const DecoderTest& rCopy ); void setUp( ); void tearDown( ); void noEncodingTest(); void base64DecodeSimpleBlockTest( ); void base64DecodePaddedBlockTest( ); void base64DecodeNoEqualsPaddedBlockTest( ); void base64DecodeSplitRunsTest( ); void base64EncodeSimpleBlockTest( ); void base64EncodePaddedBlockTest( ); void base64EncodeSplitRunsTest( ); void base64encodeTest( ); CPPUNIT_TEST_SUITE( DecoderTest ); CPPUNIT_TEST( noEncodingTest ); CPPUNIT_TEST( base64DecodeSimpleBlockTest ); CPPUNIT_TEST( base64DecodePaddedBlockTest ); CPPUNIT_TEST( base64DecodeNoEqualsPaddedBlockTest ); CPPUNIT_TEST( base64DecodeSplitRunsTest ); CPPUNIT_TEST( base64EncodeSimpleBlockTest ); CPPUNIT_TEST( base64EncodePaddedBlockTest ); CPPUNIT_TEST( base64EncodeSplitRunsTest ); CPPUNIT_TEST( base64encodeTest ); CPPUNIT_TEST_SUITE_END( ); }; DecoderTest::DecoderTest( ) : CppUnit::TestFixture( ), data( NULL ), stream( NULL ) { } DecoderTest::DecoderTest( const DecoderTest& rCopy ) : CppUnit::TestFixture( ), data( rCopy.data ), stream( rCopy.stream ) { } DecoderTest& DecoderTest::operator=( const DecoderTest& rCopy ) { if ( this != &rCopy ) { data = rCopy.data; stream = rCopy.stream; } return *this; } void DecoderTest::setUp( ) { stream = tmpfile(); data = new libcmis::EncodedData( stream ); } void DecoderTest::tearDown( ) { fclose( stream ); delete data; } string DecoderTest::getActual( ) { string actual; rewind( stream ); size_t bufSize = 100; char buf[100]; size_t readBytes = 0; do { readBytes = fread( buf, 1, bufSize, stream ); actual += string( buf, readBytes ); } while ( readBytes == bufSize ); return actual; } void DecoderTest::noEncodingTest() { data->decode( ( void* )"pleasure.", 1, 9 ); data->finish( ); CPPUNIT_ASSERT_EQUAL( string( "pleasure." ), getActual( ) ); } /* * All the test values for the Base64 have been taken from * the wikipedia article: http://en.wikipedia.org/wiki/Base64 */ void DecoderTest::base64DecodeSimpleBlockTest( ) { data->setEncoding( BASE64_ENCODING ); string input( "cGxlYXN1cmUu" ); data->decode( ( void* )input.c_str( ), 1, input.size() ); data->finish( ); CPPUNIT_ASSERT_EQUAL( string( "pleasure." ), getActual( ) ); } void DecoderTest::base64DecodePaddedBlockTest( ) { data->setEncoding( BASE64_ENCODING ); string input( "c3VyZS4=" ); data->decode( ( void* )input.c_str( ), 1, input.size( ) ); data->finish( ); CPPUNIT_ASSERT_EQUAL( string( "sure." ), getActual( ) ); } void DecoderTest::base64DecodeNoEqualsPaddedBlockTest( ) { data->setEncoding( BASE64_ENCODING ); string input( "c3VyZS4" ); data->decode( ( void* )input.c_str( ), 1, input.size( ) ); data->finish( ); CPPUNIT_ASSERT_EQUAL( string( "sure." ), getActual( ) ); } void DecoderTest::base64DecodeSplitRunsTest( ) { data->setEncoding( BASE64_ENCODING ); string input1( "cGxlYXN1c" ); data->decode( ( void* )input1.c_str( ), 1, input1.size( ) ); string input2( "mUu" ); data->decode( ( void* )input2.c_str( ), 1, input2.size( ) ); data->finish( ); CPPUNIT_ASSERT_EQUAL( string( "pleasure." ), getActual( ) ); } void DecoderTest::base64EncodeSimpleBlockTest( ) { data->setEncoding( BASE64_ENCODING ); string input( "pleasure." ); data->encode( ( void* )input.c_str(), 1, input.size() ); data->finish( ); CPPUNIT_ASSERT_EQUAL( string( "cGxlYXN1cmUu" ), getActual( ) ); } void DecoderTest::base64EncodePaddedBlockTest( ) { data->setEncoding( BASE64_ENCODING ); string input( "sure." ); data->encode( ( void* )input.c_str(), 1, input.size() ); data->finish( ); CPPUNIT_ASSERT_EQUAL( string( "c3VyZS4=" ), getActual( ) ); } void DecoderTest::base64EncodeSplitRunsTest( ) { data->setEncoding( BASE64_ENCODING ); string input1( "plea" ); data->encode( ( void* )input1.c_str(), 1, input1.size() ); string input2( "sure." ); data->encode( ( void* )input2.c_str(), 1, input2.size() ); data->finish( ); CPPUNIT_ASSERT_EQUAL( string( "cGxlYXN1cmUu" ), getActual( ) ); } void DecoderTest::base64encodeTest( ) { string actual = libcmis::base64encode( "sure." ); CPPUNIT_ASSERT_EQUAL( string( "c3VyZS4=" ), actual ); } CPPUNIT_TEST_SUITE_REGISTRATION( DecoderTest ); ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/test-commons.cxx�����������������������������������������������������������0000664�0001750�0001750�00000016013�13407414352�015266� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 SUSE <cedric@bosdonnat.fr> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <time.h> #include <cppunit/extensions/HelperMacros.h> #include <cppunit/TestFixture.h> #include <cppunit/TestAssert.h> #include <cppunit/ui/text/TestRunner.h> #include <libxml/tree.h> #if defined __clang__ #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wkeyword-macro" #endif #define private public #define protected public #if defined __clang__ #pragma clang diagnostic pop #endif #include <libcmis/oauth2-data.hxx> #include <libcmis/object-type.hxx> #include "oauth2-handler.hxx" using namespace libcmis; using namespace std; class CommonsTest : public CppUnit::TestFixture { public: // constructors tests void oauth2DataCopyTest(); void oauth2HandlerCopyTest(); void objectTypeCopyTest(); // Methods that should never be called void objectTypeNocallTest(); CPPUNIT_TEST_SUITE( CommonsTest ); CPPUNIT_TEST( oauth2DataCopyTest ); CPPUNIT_TEST( oauth2HandlerCopyTest ); CPPUNIT_TEST( objectTypeCopyTest ); CPPUNIT_TEST( objectTypeNocallTest ); CPPUNIT_TEST_SUITE_END( ); }; static void assertOAuth2DataEquals( const OAuth2Data& expected, const OAuth2Data& actual ) { CPPUNIT_ASSERT_EQUAL( expected.m_authUrl, actual.m_authUrl ); CPPUNIT_ASSERT_EQUAL( expected.m_tokenUrl, actual.m_tokenUrl ); CPPUNIT_ASSERT_EQUAL( expected.m_scope, actual.m_scope ); CPPUNIT_ASSERT_EQUAL( expected.m_redirectUri, actual.m_redirectUri ); CPPUNIT_ASSERT_EQUAL( expected.m_clientId, actual.m_clientId ); CPPUNIT_ASSERT_EQUAL( expected.m_clientSecret, actual.m_clientSecret ); } void CommonsTest::oauth2DataCopyTest( ) { OAuth2Data data( "url", "token", "scope", "redirect", "clientid", "clientsecret" ); { OAuth2Data copy; copy = data; assertOAuth2DataEquals( data, copy ); } { OAuth2Data copy( data ); assertOAuth2DataEquals( data, copy ); } } string DummyOAuth2Parser( HttpSession*, const string&, const string&, const string& ) { return "Fake"; } void CommonsTest::oauth2HandlerCopyTest( ) { OAuth2DataPtr data( new OAuth2Data ( "url", "token", "scope", "redirect", "clientid", "clientsecret" ) ); HttpSession session( "user", "pass" ); OAuth2Handler handler( &session, data ); handler.m_access = "access"; handler.m_refresh = "refresh"; handler.m_oauth2Parser = &DummyOAuth2Parser; { OAuth2Handler copy; copy = handler; CPPUNIT_ASSERT_EQUAL( &session, copy.m_session ); CPPUNIT_ASSERT_EQUAL( data, copy.m_data ); CPPUNIT_ASSERT_EQUAL( handler.m_access, copy.m_access ); CPPUNIT_ASSERT_EQUAL( handler.m_refresh, copy.m_refresh ); CPPUNIT_ASSERT_EQUAL( &DummyOAuth2Parser, copy.m_oauth2Parser ); } { OAuth2Handler copy( handler ); CPPUNIT_ASSERT_EQUAL( &session, copy.m_session ); CPPUNIT_ASSERT_EQUAL( data, copy.m_data ); CPPUNIT_ASSERT_EQUAL( handler.m_access, copy.m_access ); CPPUNIT_ASSERT_EQUAL( handler.m_refresh, copy.m_refresh ); CPPUNIT_ASSERT_EQUAL( &DummyOAuth2Parser, copy.m_oauth2Parser ); } } static void assertObjectTypeEquals( const ObjectType& expected, const ObjectType& actual ) { CPPUNIT_ASSERT_EQUAL( expected.getRefreshTimestamp(), actual.getRefreshTimestamp() ); CPPUNIT_ASSERT_EQUAL( expected.getId(), actual.getId() ); CPPUNIT_ASSERT_EQUAL( expected.getLocalName(), actual.getLocalName() ); CPPUNIT_ASSERT_EQUAL( expected.getLocalNamespace(), actual.getLocalNamespace() ); CPPUNIT_ASSERT_EQUAL( expected.getDisplayName(), actual.getDisplayName() ); CPPUNIT_ASSERT_EQUAL( expected.getQueryName(), actual.getQueryName() ); CPPUNIT_ASSERT_EQUAL( expected.getDescription(), actual.getDescription() ); CPPUNIT_ASSERT_EQUAL( expected.getParentTypeId(), actual.getParentTypeId() ); CPPUNIT_ASSERT_EQUAL( expected.getBaseTypeId(), actual.getBaseTypeId() ); CPPUNIT_ASSERT_EQUAL( expected.isCreatable(), actual.isCreatable() ); CPPUNIT_ASSERT_EQUAL( expected.isFileable(), actual.isFileable() ); CPPUNIT_ASSERT_EQUAL( expected.isQueryable(), actual.isQueryable() ); CPPUNIT_ASSERT_EQUAL( expected.isFulltextIndexed(), actual.isFulltextIndexed() ); CPPUNIT_ASSERT_EQUAL( expected.isIncludedInSupertypeQuery(), actual.isIncludedInSupertypeQuery() ); CPPUNIT_ASSERT_EQUAL( expected.isControllablePolicy(), actual.isControllablePolicy() ); CPPUNIT_ASSERT_EQUAL( expected.isControllableACL(), actual.isControllableACL() ); CPPUNIT_ASSERT_EQUAL( expected.isVersionable(), actual.isVersionable() ); CPPUNIT_ASSERT_EQUAL( expected.getContentStreamAllowed(), actual.getContentStreamAllowed() ); CPPUNIT_ASSERT_EQUAL( const_cast< ObjectType& >( expected ).getPropertiesTypes().size(), const_cast< ObjectType& >( actual ).getPropertiesTypes().size() ); } void CommonsTest::objectTypeCopyTest( ) { ObjectType type; time_t refresh = time( NULL ); type.m_refreshTimestamp = refresh; type.m_id = "id"; type.m_baseTypeId = "base"; { ObjectType copy; copy = type; assertObjectTypeEquals( type, copy ); } { ObjectType copy ( type ); assertObjectTypeEquals( type, copy ); } } void CommonsTest::objectTypeNocallTest( ) { ObjectType type; try { type.refresh(); CPPUNIT_FAIL( "refresh() shouldn't succeed" ); } catch ( const Exception& e ) { } try { type.getParentType(); CPPUNIT_FAIL( "getParentType() shouldn't succeed" ); } catch ( const Exception& e ) { } try { type.getBaseType(); CPPUNIT_FAIL( "getBaseType() shouldn't succeed" ); } catch ( const Exception& e ) { } try { type.getChildren(); CPPUNIT_FAIL( "getChildren() shouldn't succeed" ); } catch ( const Exception& e ) { } } CPPUNIT_TEST_SUITE_REGISTRATION( CommonsTest ); ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/test-sharepoint.cxx��������������������������������������������������������0000664�0001750�0001750�00000101512�13407173247�015773� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2014 Mihai Varga <mihai.mv13@gmail.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <cppunit/extensions/HelperMacros.h> #include <cppunit/TestFixture.h> #include <cppunit/TestAssert.h> #include <string> #if defined __clang__ #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wkeyword-macro" #endif #define private public #define protected public #if defined __clang__ #pragma clang diagnostic pop #endif #include <mockup-config.h> #include <fstream> #include "test-helpers.hxx" #include "sharepoint-document.hxx" #include "sharepoint-object.hxx" #include "sharepoint-property.hxx" #include "sharepoint-session.hxx" using namespace std; using namespace libcmis; static const string USERNAME( "mock-user" ); static const string PASSWORD( "mock-password" ); static const string BASE_URL( "http://base/_api/Web" ); static const string CONTEXTINFO_URL( "http://base/_api/contextinfo" ); class SharePointTest : public CppUnit::TestFixture { public: void setRepositoryTest( ); void getRepositoriesTest( ); void getObjectTest( ); void propertiesTest( ); void deleteTest( ); void xdigestExpiredTest( ); void getFileAllowableActionsTest( ); void getFolderAllowableActionsTest( ); void getDocumentTest( ); void getContentStreamTest( ); void setContentStreamTest( ); void checkOutTest( ); void checkInTest( ); void getAllVersionsTest( ); void getFolderTest( ); void getChildrenTest( ); void createFolderTest( ); void createDocumentTest( ); void moveTest( ); void getObjectByPathTest( ); void sessionCopyTest( ); void propertyCopyTest( ); void objectCopyTest( ); CPPUNIT_TEST_SUITE( SharePointTest ); CPPUNIT_TEST( setRepositoryTest ); CPPUNIT_TEST( getRepositoriesTest ); CPPUNIT_TEST( getObjectTest ); CPPUNIT_TEST( propertiesTest ); CPPUNIT_TEST( deleteTest ); CPPUNIT_TEST( xdigestExpiredTest ); CPPUNIT_TEST( getFileAllowableActionsTest ); CPPUNIT_TEST( getFolderAllowableActionsTest ); CPPUNIT_TEST( getDocumentTest ); CPPUNIT_TEST( getContentStreamTest ); CPPUNIT_TEST( setContentStreamTest ); CPPUNIT_TEST( checkOutTest ); CPPUNIT_TEST( checkInTest ); CPPUNIT_TEST( getAllVersionsTest ); CPPUNIT_TEST( getFolderTest ); CPPUNIT_TEST( getChildrenTest ); CPPUNIT_TEST( createFolderTest ); CPPUNIT_TEST( createDocumentTest ); CPPUNIT_TEST( moveTest ); CPPUNIT_TEST( getObjectByPathTest ); CPPUNIT_TEST( sessionCopyTest ); CPPUNIT_TEST( propertyCopyTest ); CPPUNIT_TEST( objectCopyTest ); CPPUNIT_TEST_SUITE_END( ); private: SharePointSession getTestSession( string username, string password ); }; SharePointSession SharePointTest::getTestSession( string username, string password ) { curl_mockup_reset( ); curl_mockup_addResponse( BASE_URL.c_str( ), "", "GET", "", 401, false ); curl_mockup_addResponse( ( BASE_URL + "/currentuser" ).c_str( ), "", "GET", DATA_DIR "/sharepoint/auth-resp.json", 200, true ); curl_mockup_addResponse( CONTEXTINFO_URL.c_str( ), "", "POST", DATA_DIR "/sharepoint/xdigest.json", 200, true ); return SharePointSession( BASE_URL, username, password, false ); } void SharePointTest::setRepositoryTest( ) { curl_mockup_reset( ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); CPPUNIT_ASSERT_MESSAGE( "setRepository should never fail", session.setRepository( "Anything" )); } void SharePointTest::getRepositoriesTest( ) { curl_mockup_reset( ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); vector< libcmis::RepositoryPtr > actual = session.getRepositories( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of repositories", size_t( 1 ), actual.size( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong repository found", string ( "SharePoint" ), actual.front()->getId( ) ); } void SharePointTest::getObjectTest( ) { static const string objectId ( "http://base/_api/Web/aFileId" ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); string authorUrl = objectId + "/Author"; curl_mockup_addResponse ( objectId.c_str( ), "", "GET", DATA_DIR "/sharepoint/file.json", 200, true); curl_mockup_addResponse ( authorUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/author.json", 200, true); libcmis::ObjectPtr object = session.getObject( objectId ); boost::shared_ptr<SharePointObject> obj = boost::dynamic_pointer_cast <SharePointObject>( object ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong Object Id", objectId, obj->getId( ) ); } void SharePointTest::propertiesTest( ) { static const string objectId ( "http://base/_api/Web/aFileId" ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); string authorUrl = objectId + "/Author"; curl_mockup_addResponse ( objectId.c_str( ), "", "GET", DATA_DIR "/sharepoint/file.json", 200, true); curl_mockup_addResponse ( authorUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/author.json", 200, true); libcmis::ObjectPtr object = session.getObject( objectId ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong creation date", string ( "2014-07-08T09:29:29Z" ), object->getStringProperty( "cmis:creationDate" ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong object id", string ( "http://base/_api/Web/aFileId" ), object->getStringProperty( "cmis:objectId" ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong author", string ( "aUserId" ), object->getStringProperty( "cmis:createdBy" ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong file name", string ( "SharePointFile" ), object->getStringProperty( "cmis:contentStreamFileName" ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong checkin comment", string ( "aCheckinComment" ), object->getStringProperty( "cmis:checkinComment" ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong version", string ( "1.0" ), object->getStringProperty( "cmis:versionLabel" ) ); } void SharePointTest::deleteTest( ) { static const string objectId ( "http://base/_api/Web/aFileId" ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); string authorUrl = objectId + "/Author"; curl_mockup_addResponse ( objectId.c_str( ), "", "GET", DATA_DIR "/sharepoint/file.json", 200, true); curl_mockup_addResponse ( authorUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/author.json", 200, true); curl_mockup_addResponse( objectId.c_str( ),"", "DELETE", "", 204, false); libcmis::ObjectPtr object = session.getObject( objectId ); object->remove( ); const struct HttpRequest* deleteRequest = curl_mockup_getRequest( objectId.c_str( ), "", "DELETE" ); CPPUNIT_ASSERT_MESSAGE( "Delete request not sent", deleteRequest ); curl_mockup_HttpRequest_free( deleteRequest ); } void SharePointTest::xdigestExpiredTest( ) { static const string objectId ( "http://base/_api/Web/aFileId" ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); string authorUrl = objectId + "/Author"; curl_mockup_addResponse ( objectId.c_str( ), "", "GET", DATA_DIR "/sharepoint/file.json", 200, true); curl_mockup_addResponse ( authorUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/author.json", 200, true); curl_mockup_addResponse( objectId.c_str( ),"", "DELETE", "", 401, false); curl_mockup_addResponse( CONTEXTINFO_URL.c_str( ), "", "POST", DATA_DIR "/sharepoint/new-xdigest.json", 200, true ); libcmis::ObjectPtr object = session.getObject( objectId ); try { object->remove( ); } catch ( ... ) { if ( session.getHttpStatus( ) == 401 ) { CPPUNIT_ASSERT_EQUAL_MESSAGE( "wrong xdigest code", string ( "new-xdigest-code" ), session.m_digestCode ); } } } void SharePointTest::getFileAllowableActionsTest( ) { static const string objectId ( "http://base/_api/Web/aFileId" ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); string authorUrl = objectId + "/Author"; curl_mockup_addResponse ( objectId.c_str( ), "", "GET", DATA_DIR "/sharepoint/file.json", 200, true); curl_mockup_addResponse ( authorUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/author.json", 200, true); libcmis::ObjectPtr object = session.getObject( objectId ); boost::shared_ptr< libcmis::AllowableActions > actions = object->getAllowableActions( ); CPPUNIT_ASSERT_MESSAGE( "GetContentStream allowable action should be true", actions->isDefined( libcmis::ObjectAction::GetContentStream ) && actions->isAllowed( libcmis::ObjectAction::GetContentStream ) ); CPPUNIT_ASSERT_MESSAGE( "CreateDocument allowable action should be false", actions->isDefined( libcmis::ObjectAction::CreateDocument ) && !actions->isAllowed( libcmis::ObjectAction::CreateDocument ) ); } void SharePointTest::getFolderAllowableActionsTest( ) { static const string objectId ( "http://base/_api/Web/aFolderId" ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); string folderPropUrl = objectId + "/Properties"; curl_mockup_addResponse ( objectId.c_str( ), "", "GET", DATA_DIR "/sharepoint/folder.json", 200, true); curl_mockup_addResponse ( folderPropUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/folder-properties.json", 200, true); libcmis::ObjectPtr object = session.getObject( objectId ); boost::shared_ptr< libcmis::AllowableActions > actions = object->getAllowableActions( ); CPPUNIT_ASSERT_MESSAGE( "CreateDocument allowable action should be true", actions->isDefined( libcmis::ObjectAction::CreateDocument ) && actions->isAllowed( libcmis::ObjectAction::CreateDocument ) ); CPPUNIT_ASSERT_MESSAGE( "GetContentStream allowable action should be false", actions->isDefined( libcmis::ObjectAction::GetContentStream ) && !actions->isAllowed( libcmis::ObjectAction::GetContentStream ) ); } void SharePointTest::getDocumentTest( ) { static const string objectId ( "http://base/_api/Web/aFileId" ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); string authorUrl = objectId + "/Author"; curl_mockup_addResponse ( objectId.c_str( ), "", "GET", DATA_DIR "/sharepoint/file.json", 200, true); curl_mockup_addResponse ( authorUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/author.json", 200, true); libcmis::ObjectPtr object = session.getObject( objectId ); // Check if we got the document object. libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); CPPUNIT_ASSERT_MESSAGE( "Fetched object should be an instance of libcmis::DocumentPtr", NULL != document ); // Test the document properties CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong document ID", objectId, document->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong document name", string( "SharePointFile" ), document->getName( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong base type", string( "cmis:document" ), document->getBaseType( ) ); CPPUNIT_ASSERT_MESSAGE( "CreatedBy is missing", !document->getCreatedBy( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "CreationDate is missing", !document->getCreationDate( ).is_not_a_date_time() ); CPPUNIT_ASSERT_MESSAGE( "LastModificationDate is missing", !document->getLastModificationDate( ).is_not_a_date_time() ); CPPUNIT_ASSERT_MESSAGE( "Content length is incorrect", 18045 == document->getContentLength( ) ); } void SharePointTest::getContentStreamTest( ) { static const string objectId ( "http://base/_api/Web/aFileId" ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); string authorUrl = objectId + "/Author"; string expectedContent( "Test content stream" ); string downloadUrl = objectId + "/%24value"; curl_mockup_addResponse ( objectId.c_str( ), "", "GET", DATA_DIR "/sharepoint/file.json", 200, true); curl_mockup_addResponse ( authorUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/author.json", 200, true); curl_mockup_addResponse( downloadUrl.c_str( ), "", "GET", expectedContent.c_str( ), 0, false ); libcmis::ObjectPtr object = session.getObject( objectId ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); try { boost::shared_ptr< istream > is = document->getContentStream( ); ostringstream out; out << is->rdbuf(); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Content stream doesn't match", expectedContent, out.str( ) ); } catch ( const libcmis::Exception& e ) { string msg = "Unexpected exception: "; msg += e.what(); CPPUNIT_FAIL( msg.c_str() ); } } void SharePointTest::setContentStreamTest( ) { static const string objectId ( "http://base/_api/Web/aFileId" ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); string authorUrl = objectId + "/Author"; string expectedContent( "Test content stream" ); string putUrl = objectId + "/%24value"; curl_mockup_addResponse ( objectId.c_str( ), "", "GET", DATA_DIR "/sharepoint/file.json", 200, true); curl_mockup_addResponse ( authorUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/author.json", 200, true); curl_mockup_addResponse( putUrl.c_str( ), "", "PUT", "Updated", 0, false ); libcmis::ObjectPtr object = session.getObject( objectId ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); try { boost::shared_ptr< ostream > os ( new stringstream ( expectedContent ) ); string filename( "aFileName" ); document->setContentStream( os, "text/plain", filename ); CPPUNIT_ASSERT_MESSAGE( "Object not refreshed during setContentStream", object->getRefreshTimestamp( ) > 0 ); // Check the content has been properly uploaded const char* content = curl_mockup_getRequestBody( putUrl.c_str( ), "", "PUT" ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad content uploaded", expectedContent, string( content ) ); } catch ( const libcmis::Exception& e ) { string msg = "Unexpected exception: "; msg += e.what(); CPPUNIT_FAIL( msg.c_str() ); } } void SharePointTest::checkOutTest( ) { static const string objectId ( "http://base/_api/Web/aFileId" ); static const string authorUrl = objectId + "/Author"; static const string checkOutUrl = objectId + "/checkout"; static const string cancelCheckOutUrl = objectId + "/undocheckout"; SharePointSession session = getTestSession( USERNAME, PASSWORD ); curl_mockup_addResponse( objectId.c_str( ), "", "GET", DATA_DIR "/sharepoint/file.json", 200, true ); curl_mockup_addResponse( authorUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/author.json", 200, true ); curl_mockup_addResponse( checkOutUrl.c_str( ), "", "POST", DATA_DIR "/sharepoint/file.json", 200, true ); curl_mockup_addResponse( cancelCheckOutUrl.c_str( ), "", "POST", DATA_DIR "/sharepoint/file.json", 200, true ); libcmis::ObjectPtr object = session.getObject( objectId ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); libcmis::DocumentPtr checkedOutDocument = document->checkOut( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong checkedOut document", objectId, checkedOutDocument->getId( ) ); checkedOutDocument->cancelCheckout( ); } void SharePointTest::checkInTest( ) { static const string objectId( "http://base/_api/Web/aFileId" ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); string authorUrl = objectId + "/Author"; string expectedContent( "Test content stream" ); string putUrl = objectId + "/%24value"; string checkInUrl = objectId + "/checkin(comment='checkin_comment',checkintype=1)"; curl_mockup_addResponse ( objectId.c_str( ), "", "GET", DATA_DIR "/sharepoint/file.json", 200, true); curl_mockup_addResponse ( authorUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/author.json", 200, true); curl_mockup_addResponse( putUrl.c_str( ), "", "PUT", "Updated", 0, false ); curl_mockup_addResponse( checkInUrl.c_str( ), "", "POST", DATA_DIR "/sharepoint/file.json", 200, true ); libcmis::ObjectPtr object = session.getObject( objectId ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); PropertyPtrMap properties; boost::shared_ptr< ostream > os ( new stringstream ( expectedContent ) ); string fileName( "aFileName" ); string checkInComment( "checkin_comment" ); libcmis::DocumentPtr checkedInDocument; checkedInDocument = document->checkIn( true, checkInComment, properties, os, "", fileName ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong checkedIn document", objectId, checkedInDocument->getId( ) ); } void SharePointTest::getAllVersionsTest( ) { static const string objectId( "http://base/_api/Web/aFileId" ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); string authorUrl = objectId + "/Author"; string versionsUrl = objectId + "/Versions"; string objectV1Url = versionsUrl +"(1)"; string objectV2Url = versionsUrl +"(2)"; string objectV1Id = objectId + "-v1"; curl_mockup_addResponse ( objectId.c_str( ), "", "GET", DATA_DIR "/sharepoint/file.json", 200, true); curl_mockup_addResponse ( authorUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/author.json", 200, true); curl_mockup_addResponse ( versionsUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/versions.json", 200, true); curl_mockup_addResponse ( objectV1Url.c_str( ), "", "GET", DATA_DIR "/sharepoint/file.json", 200, true); curl_mockup_addResponse ( objectV2Url.c_str( ), "", "GET", DATA_DIR "/sharepoint/file-v1.json", 200, true); libcmis::ObjectPtr object = session.getObject( objectId ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); vector< libcmis::DocumentPtr > allVersions = document->getAllVersions( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong version of the document - 1", objectId, allVersions[1]->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong version of the document - 2", objectV1Id, allVersions[2]->getId( ) ); } void SharePointTest::getFolderTest( ) { static const string folderId( "http://base/_api/Web/aFolderId" ); static const string parentId( "http://base/_api/Web/rootFolderId" ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); string parentUrl = folderId + "/ParentFolder"; string folderPropUrl = folderId + "/Properties"; string parentFolderPropUrl = parentId + "/Properties"; curl_mockup_addResponse( folderId.c_str( ), "", "GET", DATA_DIR "/sharepoint/folder.json", 200, true ); curl_mockup_addResponse( folderPropUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/folder-properties.json", 200, true ); curl_mockup_addResponse( parentFolderPropUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/folder-properties.json", 200, true ); curl_mockup_addResponse( parentUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/root-folder.json", 200, true ); curl_mockup_addResponse( parentId.c_str( ), "", "GET", DATA_DIR "/sharepoint/root-folder.json", 200, true ); libcmis::FolderPtr folder = session.getFolder( folderId ); CPPUNIT_ASSERT_MESSAGE( "Fetched object should be an instance of libcmis::FolderPtr", NULL != folder ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong folder ID", folderId, folder->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong folder name", string( "SharePointFolder" ), folder->getName( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong base type", string( "cmis:folder" ), folder->getBaseType( ) ); CPPUNIT_ASSERT_MESSAGE( "Missing folder parent", folder->getFolderParent( ).get( ) ); CPPUNIT_ASSERT_MESSAGE( "Not a root folder", !folder->isRootFolder() ); } void SharePointTest::getChildrenTest( ) { static const string folderId( "http://base/_api/Web/aFolderId" ); static const string authorUrl( "http://base/_api/Web/aFileId/Author" ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); string filesUrl = folderId + "/Files"; string foldersUrl = folderId + "/Folders"; string folderPropUrl = folderId + "/Properties"; curl_mockup_addResponse( folderId.c_str( ), "", "GET", DATA_DIR "/sharepoint/folder.json", 200, true ); curl_mockup_addResponse( folderPropUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/folder-properties.json", 200, true ); curl_mockup_addResponse( filesUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/children-files.json", 200, true ); curl_mockup_addResponse( foldersUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/children-folders.json", 200, true ); curl_mockup_addResponse ( authorUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/author.json", 200, true); libcmis::FolderPtr folder = session.getFolder( folderId ); CPPUNIT_ASSERT_MESSAGE( "Fetched object should be an instance of libcmis::FolderPtr", NULL != folder ); vector< libcmis::ObjectPtr > children= folder->getChildren( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad number of children", size_t( 2 ), children.size() ); int folderCount = 0; int fileCount = 0; for ( vector< libcmis::ObjectPtr >::iterator it = children.begin( ); it != children.end( ); ++it ) { if ( NULL != boost::dynamic_pointer_cast< libcmis::Folder >( *it ) ) ++folderCount; else { ++fileCount; libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( *it ); vector< libcmis::FolderPtr > parents= document->getParents( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad number of parents", size_t( 1 ), parents.size() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong parent Id", folderId, parents[0]->getId( ) ); } } CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of folder children", 1, folderCount ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of file children", 1, fileCount ); } void SharePointTest::createFolderTest( ) { static const string folderId( "http://base/_api/Web/aFolderId" ); static const string parentId( "http://base/_api/Web/rootFolderId" ); static const string newFolderUrl ( "http://base/_api/Web/folders/add('/SharePointFolder')" ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); string folderPropUrl = folderId + "/Properties"; string parentFolderPropUrl = parentId + "/Properties"; curl_mockup_addResponse( folderId.c_str( ), "", "GET", DATA_DIR "/sharepoint/folder.json", 200, true ); curl_mockup_addResponse( folderPropUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/folder-properties.json", 200, true ); curl_mockup_addResponse( parentFolderPropUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/folder-properties.json", 200, true ); curl_mockup_addResponse( parentId.c_str( ), "", "GET", DATA_DIR "/sharepoint/root-folder.json", 200, true ); curl_mockup_addResponse( newFolderUrl.c_str( ), "", "POST", DATA_DIR "/sharepoint/folder.json", 200, true ); libcmis::FolderPtr folder = session.getFolder( parentId ); PropertyPtrMap properties = session.getFolder( folderId )->getProperties( ); libcmis::FolderPtr newFolder = folder->createFolder( properties ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "New folder not created", folderId, newFolder->getId( ) ); } void SharePointTest::createDocumentTest( ) { static const string folderId( "http://base/_api/Web/aFolderId" ); static const string fileId( "http://base/_api/Web/aFileId" ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); string folderPropUrl = folderId + "/Properties"; string newDocUrl = folderId + "/files/add(overwrite=true,url='NewDoc')"; string authorUrl = fileId + "/Author"; curl_mockup_addResponse( folderId.c_str( ), "", "GET", DATA_DIR "/sharepoint/folder.json", 200, true ); curl_mockup_addResponse( folderPropUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/folder-properties.json", 200, true ); curl_mockup_addResponse( newDocUrl.c_str( ), "", "POST", DATA_DIR "/sharepoint/file.json", 200, true ); curl_mockup_addResponse( authorUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/author.json", 200, true ); libcmis::FolderPtr folder = session.getFolder( folderId ); try { string expectedContent( "Test set content stream" ); boost::shared_ptr< ostream > os ( new stringstream ( expectedContent ) ); PropertyPtrMap properties; string fileName = "NewDoc"; libcmis::DocumentPtr document = folder->createDocument( properties, os, "text/plain", fileName ); const char* content = curl_mockup_getRequestBody( newDocUrl.c_str( ), "", "POST" ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad content uploaded", expectedContent, string( content ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad document id", fileId, document->getId( ) ); } catch ( const libcmis::Exception& e ) { string msg = "Unexpected exception: "; msg += e.what( ); CPPUNIT_FAIL( msg.c_str( ) ); } } void SharePointTest::moveTest( ) { static const string fileId ( "http://base/_api/Web/aFileId" ); static const string folderId( "http://base/_api/Web/aFolderId" ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); string authorUrl = fileId + "/Author"; string folderPropUrl = folderId + "/Properties"; string moveUrl = fileId + "/moveto(newurl='/SharePointFolder/SharePointFile',flags=1)"; curl_mockup_addResponse ( fileId.c_str( ), "", "GET", DATA_DIR "/sharepoint/file.json", 200, true); curl_mockup_addResponse ( authorUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/author.json", 200, true); curl_mockup_addResponse ( folderId.c_str( ), "", "GET", DATA_DIR "/sharepoint/folder.json", 200, true); curl_mockup_addResponse( folderPropUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/folder-properties.json", 200, true ); curl_mockup_addResponse( moveUrl.c_str( ), "", "POST", DATA_DIR "/sharepoint/file.json", 200, true ); libcmis::ObjectPtr document = session.getObject( fileId ); libcmis::FolderPtr folder = session.getFolder( folderId ); document->move( folder, folder ); // nothing to assert, making the right reqeusts should be enough } void SharePointTest::getObjectByPathTest( ) { static const string folderUrl( "http://base/_api/Web/getFolderByServerRelativeUrl('/SharePointFile')" ); static const string fileUrl( "http://base/_api/Web/getFileByServerRelativeUrl('/SharePointFile')" ); static string authorUrl( "http://base/_api/Web/aFileId/Author" ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); curl_mockup_addResponse( fileUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/file.json", 200, true); curl_mockup_addResponse( folderUrl.c_str( ), "", "GET", "", 400, true); curl_mockup_addResponse( authorUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/author.json", 200, true); libcmis::ObjectPtr object = session.getObjectByPath( "/SharePointFile" ); // Check if we got the document object. libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); CPPUNIT_ASSERT_MESSAGE( "Fetched object should be an instance of libcmis::DocumentPtr", NULL != document ); } void SharePointTest::sessionCopyTest( ) { SharePointSession session = getTestSession( USERNAME, PASSWORD ); { SharePointSession copy; copy = session; CPPUNIT_ASSERT_EQUAL( session.m_bindingUrl, copy.m_bindingUrl ); CPPUNIT_ASSERT_EQUAL( session.m_digestCode, copy.m_digestCode ); } { SharePointSession copy( session ); CPPUNIT_ASSERT_EQUAL( session.m_bindingUrl, copy.m_bindingUrl ); CPPUNIT_ASSERT_EQUAL( session.m_digestCode, copy.m_digestCode ); } } void SharePointTest::propertyCopyTest( ) { SharePointProperty property("Author", "\"__deferred\":{" " \"uri\":\"http://base/_api/Web/aFileId/Author\"" "}"); { SharePointProperty copy; copy = property; CPPUNIT_ASSERT_EQUAL( property.m_propertyType->m_id, copy.m_propertyType->m_id ); CPPUNIT_ASSERT_EQUAL( property.m_strValues[0], copy.m_strValues[0]); } { SharePointProperty copy( property ); CPPUNIT_ASSERT_EQUAL( property.m_propertyType->m_id, copy.m_propertyType->m_id ); CPPUNIT_ASSERT_EQUAL( property.m_strValues[0], copy.m_strValues[0]); } } void SharePointTest::objectCopyTest( ) { static const string objectId ( "http://base/_api/Web/aFileId" ); SharePointSession session = getTestSession( USERNAME, PASSWORD ); string authorUrl = objectId + "/Author"; curl_mockup_addResponse ( objectId.c_str( ), "", "GET", DATA_DIR "/sharepoint/file.json", 200, true); curl_mockup_addResponse ( authorUrl.c_str( ), "", "GET", DATA_DIR "/sharepoint/author.json", 200, true); boost::shared_ptr< SharePointObject > object = boost::dynamic_pointer_cast< SharePointObject >(session.getObject( objectId ) ); { SharePointObject copy( *object ); CPPUNIT_ASSERT_EQUAL( object->m_refreshTimestamp, copy.m_refreshTimestamp ); } { SharePointObject copy( &session ); copy = *object; CPPUNIT_ASSERT_EQUAL( object->m_refreshTimestamp, copy.m_refreshTimestamp ); } } CPPUNIT_TEST_SUITE_REGISTRATION( SharePointTest ); ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/test-gdrive.cxx������������������������������������������������������������0000664�0001750�0001750�00000146156�13407414352�015107� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo <cao.cuong.ngo@gmail.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <cppunit/extensions/HelperMacros.h> #include <cppunit/TestFixture.h> #include <cppunit/TestAssert.h> #include <string> #if defined __clang__ #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wkeyword-macro" #endif #define private public #define protected public #if defined __clang__ #pragma clang diagnostic pop #endif #include <libcmis/document.hxx> #include <libcmis/session-factory.hxx> #include <mockup-config.h> #include "gdrive-session.hxx" #include "gdrive-property.hxx" #include "oauth2-handler.hxx" #include "gdrive-object.hxx" using namespace std; using namespace libcmis; static const string CLIENT_ID ( "mock-id" ); static const string CLIENT_SECRET ( "mock-secret" ); static const string USERNAME( "mock-user" ); static const string PASSWORD( "mock-password" ); static const string USERNAME2( "mock-user2" ); static const string PASSWORD2( "mock-password2" ); static const string LOGIN_URL ("https://login/url" ); static const string LOGIN_URL2 ("https://login2/url" ); static const string APPROVAL_URL ("https://approval/url" ); static const string CHALLENGE_URL ("https://accounts.google.com/challenge/url" ); static const string AUTH_URL ( "https://auth/url" ); static const string TOKEN_URL ( "https://token/url" ); static const string SCOPE ( "https://scope/url" ); static const string REDIRECT_URI ("redirect:uri" ); static const string BASE_URL ( "https://base/url" ); #define PIN "123321" namespace { char* lcl_authCodeFallback( const char* /*url*/, const char* /*username*/, const char* /*password*/ ) { char *authCode = strdup( PIN ); return authCode; } } class GDriveTest : public CppUnit::TestFixture { public: void sessionAuthenticationTest( ); void sessionAuthenticationTestWith2FA( ); void sessionExpiryTokenGetTest( ); void sessionExpiryTokenPostTest( ); void sessionExpiryTokenPutTest( ); void sessionExpiryTokenDeleteTest( ); void setRepositoryTest( ); void getRepositoriesTest( ); void getTypeTest( ); void getObjectTest( ); void getObjectByPathRootTest( ); void getObjectByPathTest( ); void getObjectByPathMissingTest( ); void getDocumentTest( ); void getFolderTest( ); void getDocumentParentsTest( ); void getContentStreamTest( ); void setContentStreamTest( ); void setContentStreamGdocTest( ); void getChildrenTest( ); void getDocumentAllowableActionsTest( ); void getFolderAllowableActionsTest( ); void checkOutTest( ); void checkInTest( ); void deleteTest( ); void moveTest( ); void createDocumentTest( ); void createFolderTest( ); void updatePropertiesTest( ); void propertyCopyTest( ); void removeTreeTest( ); void getContentStreamWithRenditionsTest( ); void getRefreshTokenTest( ); void getThumbnailUrlTest( ); void getAllVersionsTest( ); CPPUNIT_TEST_SUITE( GDriveTest ); CPPUNIT_TEST( sessionAuthenticationTest ); CPPUNIT_TEST( sessionAuthenticationTestWith2FA ); CPPUNIT_TEST( sessionExpiryTokenGetTest ); CPPUNIT_TEST( sessionExpiryTokenPutTest ); CPPUNIT_TEST( sessionExpiryTokenPostTest ); CPPUNIT_TEST( sessionExpiryTokenDeleteTest ); CPPUNIT_TEST( setRepositoryTest ); CPPUNIT_TEST( getRepositoriesTest ); CPPUNIT_TEST( getTypeTest ); CPPUNIT_TEST( getObjectTest ); CPPUNIT_TEST( getObjectByPathRootTest ); CPPUNIT_TEST( getObjectByPathTest ); CPPUNIT_TEST( getObjectByPathMissingTest ); CPPUNIT_TEST( getDocumentTest ); CPPUNIT_TEST( getFolderTest ); CPPUNIT_TEST( getDocumentParentsTest ); CPPUNIT_TEST( getContentStreamTest ); CPPUNIT_TEST( setContentStreamTest ); CPPUNIT_TEST( setContentStreamGdocTest ); CPPUNIT_TEST( getChildrenTest ); CPPUNIT_TEST( getDocumentAllowableActionsTest ); CPPUNIT_TEST( getFolderAllowableActionsTest ); CPPUNIT_TEST( checkOutTest ); CPPUNIT_TEST( checkInTest ); CPPUNIT_TEST( deleteTest ); CPPUNIT_TEST( moveTest ); CPPUNIT_TEST( createDocumentTest ); CPPUNIT_TEST( createFolderTest ); CPPUNIT_TEST( updatePropertiesTest ); CPPUNIT_TEST( propertyCopyTest ); CPPUNIT_TEST( removeTreeTest ); CPPUNIT_TEST( getContentStreamWithRenditionsTest ); CPPUNIT_TEST( getRefreshTokenTest ); CPPUNIT_TEST( getThumbnailUrlTest ); CPPUNIT_TEST( getAllVersionsTest ); CPPUNIT_TEST_SUITE_END( ); private: GDriveSession getTestSession( string username, string password, bool with2FA = false ); }; GDriveSession GDriveTest::getTestSession( string username, string password, bool with2FA ) { libcmis::OAuth2DataPtr oauth2( new libcmis::OAuth2Data( AUTH_URL, TOKEN_URL, SCOPE, REDIRECT_URI, CLIENT_ID, CLIENT_SECRET )); curl_mockup_reset( ); string empty; //login response string loginIdentifier = string("scope=") + SCOPE + string("&redirect_uri=") + REDIRECT_URI + string("&response_type=code") + string("&client_id=") + CLIENT_ID; curl_mockup_addResponse ( AUTH_URL.c_str(), loginIdentifier.c_str( ), "GET", DATA_DIR "/gdrive/login1.html", 200, true); //authentication email curl_mockup_addResponse( LOGIN_URL2.c_str( ), empty.c_str( ), "POST", DATA_DIR "/gdrive/login2.html", 200, true); //challenge - pin code if( with2FA == true ) { curl_mockup_addResponse( LOGIN_URL.c_str( ), empty.c_str( ), "POST", DATA_DIR "/gdrive/challenge.html", 200, true); //approval response curl_mockup_addResponse( CHALLENGE_URL.c_str( ), empty.c_str( ), "POST", DATA_DIR "/gdrive/approve.html", 200, true); } else { //authentication password, curl_mockup_addResponse( LOGIN_URL.c_str( ), empty.c_str( ), "POST", DATA_DIR "/gdrive/approve.html", 200, true); } //approval response curl_mockup_addResponse( APPROVAL_URL.c_str( ), empty.c_str( ), "POST", DATA_DIR "/gdrive/authcode.html", 200, true); curl_mockup_addResponse ( TOKEN_URL.c_str( ), empty.c_str( ), "POST", DATA_DIR "/gdrive/token-response.json", 200, true ); return GDriveSession( BASE_URL, username, password, oauth2, false ); } void GDriveTest::sessionAuthenticationTest( ) { GDriveSession session = getTestSession( USERNAME, PASSWORD ); string empty; // Check authentication request for email string authRequestEmail( curl_mockup_getRequestBody( LOGIN_URL2.c_str(), empty.c_str( ), "POST" ) ); string expectedAuthRequestEmail = string ( "Page=PasswordSeparationSignIn&continue=redirectLink&scope=Scope&service=lso&GALX=cookie" "&Email=") + USERNAME; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong authentication request for Email", expectedAuthRequestEmail, authRequestEmail ); // Check authentication request for password string authRequestPassword( curl_mockup_getRequestBody( LOGIN_URL.c_str(), empty.c_str( ), "POST" ) ); string expectedAuthRequestPassword = string ( "continue=redirectLink&scope=Scope&service=lso&GALX=cookie" "&Passwd=") + PASSWORD; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong authentication request for Password", expectedAuthRequestPassword, authRequestPassword ); // Check code request string codeRequest( curl_mockup_getRequestBody( APPROVAL_URL.c_str(), empty.c_str( ), "POST" ) ); string expectedCodeRequest = string( "state_wrapper=stateWrapper&submit_access=true" ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong approval request", expectedCodeRequest, codeRequest); // Check token request string expectedTokenRequest = string( "code=AuthCode") + string( "&client_id=") + CLIENT_ID + string( "&client_secret=") + CLIENT_SECRET + string( "&redirect_uri=") + REDIRECT_URI + string( "&grant_type=authorization_code" ); string tokenRequest( curl_mockup_getRequestBody( TOKEN_URL.c_str(), empty.c_str( ), "POST" ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong token request", expectedTokenRequest, tokenRequest ); // Check token CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong access token", string ( "mock-access-token" ), session.m_oauth2Handler->getAccessToken( )); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong refresh token", string ("mock-refresh-token"), session.m_oauth2Handler->getRefreshToken( )); } void GDriveTest::sessionAuthenticationTestWith2FA( ) { libcmis::SessionFactory::setOAuth2AuthCodeProvider( lcl_authCodeFallback ); GDriveSession session = getTestSession( USERNAME2, PASSWORD2, true ); string empty; // Check authentication request for email string authRequestEmail( curl_mockup_getRequestBody( LOGIN_URL2.c_str(), empty.c_str( ), "POST" ) ); string expectedAuthRequestEmail = string ( "Page=PasswordSeparationSignIn&continue=redirectLink&scope=Scope&service=lso&GALX=cookie" "&Email=") + USERNAME2; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong authentication request for Email", expectedAuthRequestEmail, authRequestEmail ); // Check authentication request for password string authRequestPassword( curl_mockup_getRequestBody( LOGIN_URL.c_str(), empty.c_str( ), "POST" ) ); string expectedAuthRequestPassword = string ( "continue=redirectLink&scope=Scope&service=lso&GALX=cookie" "&Passwd=") + PASSWORD2; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong authentication request for Password", expectedAuthRequestPassword, authRequestPassword ); // Check request for pin code string authRequestPin( curl_mockup_getRequestBody( CHALLENGE_URL.c_str(), empty.c_str( ), "POST" ) ); string expectedAuthRequestPin = string ( "continue=redirectLink&scope=Scope&service=lso&GALX=cookie" "&Pin=") + PIN; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong authentication request for Pin", expectedAuthRequestPin, authRequestPin ); // Check code request string codeRequest( curl_mockup_getRequestBody( APPROVAL_URL.c_str(), empty.c_str( ), "POST" ) ); string expectedCodeRequest = string( "state_wrapper=stateWrapper&submit_access=true" ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong approval request", expectedCodeRequest, codeRequest); // Check token request string expectedTokenRequest = string( "code=AuthCode") + string( "&client_id=") + CLIENT_ID + string( "&client_secret=") + CLIENT_SECRET + string( "&redirect_uri=") + REDIRECT_URI + string( "&grant_type=authorization_code" ); string tokenRequest( curl_mockup_getRequestBody( TOKEN_URL.c_str(), empty.c_str( ), "POST" ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong token request", expectedTokenRequest, tokenRequest ); // Check token CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong access token", string ( "mock-access-token" ), session.m_oauth2Handler->getAccessToken( )); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong refresh token", string ("mock-refresh-token"), session.m_oauth2Handler->getRefreshToken( )); } void GDriveTest::sessionExpiryTokenGetTest( ) { // Access_token will expire after expires_in seconds, // We need to use the refresh key to get a new one. curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); curl_mockup_reset( ); static const string objectId("aFileId"); string url = BASE_URL + "/files/" + objectId; // 401 response, token is expired curl_mockup_addResponse( url.c_str( ),"", "GET", "", 401, false ); curl_mockup_addResponse( TOKEN_URL.c_str(), "", "POST", DATA_DIR "/gdrive/refresh_response.json", 200, true); try { // GET expires, need to refresh then GET again libcmis::ObjectPtr obj = session.getObject( objectId ); } catch ( ... ) { if ( session.getHttpStatus( ) == 401 ) { // Check if access token is refreshed CPPUNIT_ASSERT_EQUAL_MESSAGE( "wrong access token", string ( "new-access-token" ), session.m_oauth2Handler->getAccessToken( ) ); } } } void GDriveTest::sessionExpiryTokenPostTest( ) { // Access_token will expire after expires_in seconds, // We need to use the refresh key to get a new one. curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); curl_mockup_reset( ); static const string folderId("aFileId"); const string folderUrl = BASE_URL + "/files/" + folderId; const string metaUrl = BASE_URL + "/files"; curl_mockup_addResponse( TOKEN_URL.c_str(), "", "POST", DATA_DIR "/gdrive/refresh_response.json", 200, true); curl_mockup_addResponse( folderUrl.c_str( ), "", "GET", DATA_DIR "/gdrive/folder.json", 200, true ); // 401 response, token is expired // refresh and then POST again curl_mockup_addResponse( metaUrl.c_str( ), "", "POST", "", 401, false ); libcmis::FolderPtr parent = session.getFolder( folderId ); try { PropertyPtrMap properties; // POST expires, need to refresh then POST again parent->createFolder( properties ); } catch ( ... ) { if ( session.getHttpStatus( ) == 401 ) { // Check if access token is refreshed CPPUNIT_ASSERT_EQUAL_MESSAGE( "wrong access token", string ( "new-access-token" ), session.m_oauth2Handler->getAccessToken( ) ); } } } void GDriveTest::sessionExpiryTokenDeleteTest( ) { // Access_token will expire after expires_in seconds, // We need to use the refresh key to get a new one. curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); curl_mockup_reset( ); static const string objectId("aFileId"); string url = BASE_URL + "/files/" + objectId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/gdrive/document2.json", 200, true); curl_mockup_addResponse( TOKEN_URL.c_str(), "", "POST", DATA_DIR "/gdrive/refresh_response.json", 200, true); // 401 response, token is expired curl_mockup_addResponse( url.c_str( ),"", "DELETE", "", 401, false); libcmis::ObjectPtr obj = session.getObject( objectId ); libcmis::ObjectPtr object = session.getObject( objectId ); try { // DELETE expires, need to refresh then DELETE again object->remove( ); } catch ( ... ) { if ( session.getHttpStatus( ) == 401 ) { // Check if access token is refreshed CPPUNIT_ASSERT_EQUAL_MESSAGE( "wrong access token", string ( "new-access-token" ), session.m_oauth2Handler->getAccessToken( ) ); const struct HttpRequest* deleteRequest = curl_mockup_getRequest( url.c_str( ), "", "DELETE" ); CPPUNIT_ASSERT_MESSAGE( "Delete request not sent", deleteRequest ); curl_mockup_HttpRequest_free( deleteRequest ); } } } void GDriveTest::sessionExpiryTokenPutTest( ) { // Access_token will expire after expires_in seconds, // We need to use the refresh key to get a new one. curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); curl_mockup_reset( ); static const string objectId("aFileId"); string url = BASE_URL + "/files/" + objectId; curl_mockup_addResponse( TOKEN_URL.c_str(), "", "POST", DATA_DIR "/gdrive/refresh_response.json", 200, true); curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/gdrive/document.json", 200, true ); // 401 response, token is expired curl_mockup_addResponse( url.c_str( ),"", "PUT", "", 401, false ); libcmis::ObjectPtr object = session.getObject( objectId ); try { // PUT expires, need to refresh then PUT again object->updateProperties( object->getProperties( ) ); } catch ( ... ) { if ( session.getHttpStatus( ) == 401 ) { // Check if access token is refreshed CPPUNIT_ASSERT_EQUAL_MESSAGE( "wrong access token", string ( "new-access-token" ), session.m_oauth2Handler->getAccessToken( ) ); } } } void GDriveTest::setRepositoryTest( ) { GDriveSession session; CPPUNIT_ASSERT_MESSAGE( "Should never fail", session.setRepository( "foobar" ) ); } void GDriveTest::getDocumentTest( ) { curl_mockup_reset( ); static const string objectId ("aFileId"); GDriveSession session = getTestSession( USERNAME, PASSWORD ); string url = BASE_URL + "/files/" + objectId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/gdrive/document.json", 200, true); libcmis::ObjectPtr obj = session.getObject( objectId ); // Check if we got the document object. libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( obj ); CPPUNIT_ASSERT_MESSAGE( "Fetched object should be an instance of libcmis::DocumentPtr", NULL != document ); // Test the document properties CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong document ID", objectId, document->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong document name", string( "GDrive File" ), document->getName( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong document type", string( "application/vnd.google-apps.form" ), document->getContentType( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong base type", string( "cmis:document" ), document->getBaseType( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong type", string( "cmis:document" ), document->getType( ) ); CPPUNIT_ASSERT_MESSAGE( "CreatedBy is missing", !document->getCreatedBy( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "CreationDate is missing", !document->getCreationDate( ).is_not_a_date_time() ); CPPUNIT_ASSERT_MESSAGE( "LastModifiedBy is missing", !document->getLastModifiedBy( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "LastModificationDate is missing", !document->getLastModificationDate( ).is_not_a_date_time() ); CPPUNIT_ASSERT_MESSAGE( "Content length is incorrect", 123 == document->getContentLength( ) ); } void GDriveTest::getFolderTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); static const string folderId( "aFolderId" ); static const string parentId( "parentID" ); string url = BASE_URL + "/files/" + folderId; string parentUrl = BASE_URL + "/files/" + parentId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/gdrive/folder.json", 200, true); curl_mockup_addResponse( parentUrl.c_str( ), "", "GET", DATA_DIR "/gdrive/folder.json", 200, true); // Check if we got the Folder object. libcmis::FolderPtr folder = session.getFolder( folderId ); CPPUNIT_ASSERT_MESSAGE( "Fetched object should be an instance of libcmis::FolderPtr", NULL != folder ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong folder ID", folderId, folder->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong folder name", string( "testFolder" ), folder->getName( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong base type", string( "cmis:folder" ), folder->getBaseType( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong type", string( "cmis:folder" ), folder->getType( ) ); CPPUNIT_ASSERT_MESSAGE( "Missing folder parent", folder->getFolderParent( ).get( ) ); CPPUNIT_ASSERT_MESSAGE( "Not a root folder", !folder->isRootFolder() ); CPPUNIT_ASSERT_MESSAGE( "CreatedBy is missing", !folder->getCreatedBy( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "CreationDate is missing", !folder->getCreationDate( ).is_not_a_date_time() ); CPPUNIT_ASSERT_MESSAGE( "LastModifiedBy is missing", !folder->getLastModifiedBy( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "LastModificationDate is missing", !folder->getLastModificationDate( ).is_not_a_date_time() ); } void GDriveTest::getDocumentParentsTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); static const string documentId( "aFileId" ); static const string parentId( "aFolderId" ); static const string parentId2( "aNewFolderId" ); string url = BASE_URL + "/files/" + documentId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/gdrive/document.json", 200, true); string parent1Url = BASE_URL + "/files/" + parentId; string parent2Url = BASE_URL + "/files/" + parentId2; curl_mockup_addResponse( parent1Url.c_str( ), "", "GET", DATA_DIR "/gdrive/folder.json", 200, true); curl_mockup_addResponse( parent2Url.c_str( ), "", "GET", DATA_DIR "/gdrive/folder2.json", 200, true); libcmis::ObjectPtr object = session.getObject( "aFileId" ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); CPPUNIT_ASSERT_MESSAGE( "Document expected", document != NULL ); vector< libcmis::FolderPtr > parents= document->getParents( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad number of parents", size_t( 2 ), parents.size() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong parent Id", parentId, parents[0]->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong parent Id", parentId2, parents[1]->getId( ) ); } void GDriveTest::getContentStreamTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); static const string documentId( "aFileId" ); string url = BASE_URL + "/files/" + documentId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/gdrive/document.json", 200, true); string expectedContent( "Test content stream" ); string downloadUrl = "https://downloadLink"; curl_mockup_addResponse( downloadUrl.c_str( ), "", "GET", expectedContent.c_str( ), 0, false ); libcmis::ObjectPtr object = session.getObject( documentId ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); try { boost::shared_ptr< istream > is = document->getContentStream( ); ostringstream out; out << is->rdbuf(); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Content stream doesn't match", expectedContent, out.str( ) ); } catch ( const libcmis::Exception& e ) { string msg = "Unexpected exception: "; msg += e.what(); CPPUNIT_FAIL( msg.c_str() ); } } void GDriveTest::setContentStreamTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); const string documentId( "aFileId" ); const string uploadBaseUrl = "https://www.googleapis.com/upload/drive/v2/files/"; string url = BASE_URL + "/files/" + documentId; string putUrl = uploadBaseUrl + documentId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/gdrive/document2.json", 200, true); libcmis::ObjectPtr object = session.getObject( documentId ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); curl_mockup_addResponse( url.c_str( ), "", "PUT", DATA_DIR "/gdrive/document2.json", 200, true); curl_mockup_addResponse( putUrl.c_str( ), "", "PUT", "Updated", 0, false ); try { string expectedContent( "Test set content stream" ); boost::shared_ptr< ostream > os ( new stringstream ( expectedContent ) ); string filename( "aFileName" ); document->setContentStream( os, "text/plain", filename ); CPPUNIT_ASSERT_MESSAGE( "Object not refreshed during setContentStream", object->getRefreshTimestamp( ) > 0 ); // Check if metadata has been properly uploaded const char* meta = curl_mockup_getRequestBody( url.c_str( ), "", "PUT" ); string expectedMeta = "{\n \"title\": \"aFileName\"\n}\n"; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad meta uploaded", expectedMeta, string( meta ) ); // Check the content has been properly uploaded const char* content = curl_mockup_getRequestBody( putUrl.c_str( ), "", "PUT" ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad content uploaded", expectedContent, string( content ) ); } catch ( const libcmis::Exception& e ) { string msg = "Unexpected exception: "; msg += e.what(); CPPUNIT_FAIL( msg.c_str() ); } } void GDriveTest::setContentStreamGdocTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); const string documentId( "aFileId" ); const string uploadBaseUrl = "https://www.googleapis.com/upload/drive/v2/files/"; string url = BASE_URL + "/files/" + documentId; string putUrl = uploadBaseUrl + documentId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/gdrive/document.json", 200, true); libcmis::ObjectPtr object = session.getObject( documentId ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); curl_mockup_addResponse( url.c_str( ), "convert=true", "PUT", DATA_DIR "/gdrive/document.json", 200, true); curl_mockup_addResponse( putUrl.c_str( ), "convert=true", "PUT", "Updated", 0, false ); try { string expectedContent( "Test set content stream" ); boost::shared_ptr< ostream > os ( new stringstream ( expectedContent ) ); string filename( "aFileName" ); document->setContentStream( os, "text/plain", filename ); CPPUNIT_ASSERT_MESSAGE( "Object not refreshed during setContentStream", object->getRefreshTimestamp( ) > 0 ); // Check the content has been properly uploaded const char* content = curl_mockup_getRequestBody( putUrl.c_str( ), "", "PUT" ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad content uploaded", expectedContent, string( content ) ); } catch ( const libcmis::Exception& e ) { string msg = "Unexpected exception: "; msg += e.what(); CPPUNIT_FAIL( msg.c_str() ); } } void GDriveTest::getChildrenTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); static const string folderId ("aFolderId"); string url = BASE_URL + "/files/" + folderId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/gdrive/folder.json", 200, true); string urlChildFolder = BASE_URL + "/files/" + string ("aChildFolder"); curl_mockup_addResponse( urlChildFolder.c_str( ), "", "GET", DATA_DIR "/gdrive/folder.json", 200, true); string urlChildDocument = BASE_URL + "/files/" + string ("aChildDocument"); curl_mockup_addResponse( urlChildDocument.c_str( ), "", "GET", DATA_DIR "/gdrive/document.json", 200, true); libcmis::ObjectPtr obj = session.getObject( folderId ); // Check if we got the Folder object. libcmis::FolderPtr folder = boost::dynamic_pointer_cast< libcmis::Folder >( obj ); CPPUNIT_ASSERT_MESSAGE( "Folder expected", folder != NULL ); string query = "q=\"" + folderId + "\"+in+parents+and+trashed+=+false"; string childrenUrl = BASE_URL + "/files"; curl_mockup_addResponse( childrenUrl.c_str( ), query.c_str( ), "GET", DATA_DIR "/gdrive/folder_children.json", 200, true); vector< libcmis::ObjectPtr > children= folder->getChildren( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad number of children", size_t( 2 ), children.size() ); int folderCount = 0; int documentCount = 0; for ( vector< libcmis::ObjectPtr >::iterator it = children.begin( ); it != children.end( ); ++it ) { if ( NULL != boost::dynamic_pointer_cast< libcmis::Folder >( *it ) ) ++folderCount; else if ( NULL != boost::dynamic_pointer_cast< libcmis::Document >( *it ) ) ++documentCount; } CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of folder children", 1, folderCount ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of document children", 1, documentCount ); } void GDriveTest::getTypeTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); string expectedId( "cmis:document" ); libcmis::ObjectTypePtr actual = session.getType( expectedId ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong Id for fetched type", expectedId, actual->getId( ) ); } void GDriveTest::getRepositoriesTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); vector< libcmis::RepositoryPtr > actual = session.getRepositories( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of repositories", size_t( 1 ), actual.size( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong repository found", string ( "GoogleDrive" ), actual.front()->getId( ) ); } void GDriveTest::getObjectTest() { static const string objectId ("aFileId"); GDriveSession session = getTestSession( USERNAME, PASSWORD ); string url = BASE_URL + "/files/" + objectId; curl_mockup_addResponse ( url.c_str( ), "", "GET", DATA_DIR "/gdrive/gdoc-file.json", 200, true); libcmis::ObjectPtr object = session.getObject( objectId ); boost::shared_ptr<GDriveObject> obj = boost::dynamic_pointer_cast <GDriveObject>(object); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong Object Id", objectId, obj->getId( ) ); } void GDriveTest::getObjectByPathRootTest() { GDriveSession session = getTestSession( USERNAME, PASSWORD ); string rootUrl = BASE_URL + "/files/root"; curl_mockup_addResponse ( rootUrl.c_str( ), "", "GET", DATA_DIR "/gdrive/folder.json", 200, true); libcmis::ObjectPtr object = session.getObjectByPath( "/" ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong Object Id", string("testFolder"), object->getName( ) ); } void GDriveTest::getObjectByPathTest() { // Mockup setup GDriveSession session = getTestSession( USERNAME, PASSWORD ); string rootChildUrl = BASE_URL + "/files/root/children/"; curl_mockup_addResponse ( rootChildUrl.c_str( ), "q=title+=+'GDrive File'", "GET", DATA_DIR "/gdrive/root_child_search.json", 200, true ); string urlRootChildDoc = BASE_URL + "/files/aRootChildId2"; curl_mockup_addResponse( urlRootChildDoc.c_str( ), "", "GET", DATA_DIR "/gdrive/document.json", 200, true ); // Tested method libcmis::ObjectPtr object = session.getObjectByPath( "/GDrive File" ); // Check the result CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong Object", string("GDrive File"), object->getName( ) ); } void GDriveTest::getObjectByPathMissingTest() { // Mockup setup GDriveSession session = getTestSession( USERNAME, PASSWORD ); string rootChildUrl = BASE_URL + "/files/root/children/"; curl_mockup_addResponse ( rootChildUrl.c_str( ), "q=title+=+'GDrive File'", "GET", DATA_DIR "/gdrive/root_child_missing.json", 200, true ); // Tested method try { libcmis::ObjectPtr object = session.getObjectByPath( "/GDrive File" ); CPPUNIT_FAIL( "objectNotFound exception expected" ); } catch ( libcmis::Exception& e ) { CPPUNIT_ASSERT_EQUAL_MESSAGE("Bad exception type", string( "objectNotFound" ), e.getType( ) ); } } void GDriveTest::getDocumentAllowableActionsTest( ) { curl_mockup_reset( ); static const string objectId ("aFileId"); GDriveSession session = getTestSession( USERNAME, PASSWORD ); string url = BASE_URL + "/files/" + objectId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/gdrive/document.json", 200, true); libcmis::ObjectPtr obj = session.getObject( objectId ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( obj ); boost::shared_ptr< libcmis::AllowableActions > actions = document->getAllowableActions( ); CPPUNIT_ASSERT_MESSAGE( "GetContentStream allowable action should be true", actions->isDefined( libcmis::ObjectAction::GetContentStream ) && actions->isAllowed( libcmis::ObjectAction::GetContentStream ) ); CPPUNIT_ASSERT_MESSAGE( "CreateDocument allowable action should be false", actions->isDefined( libcmis::ObjectAction::CreateDocument ) && !actions->isAllowed( libcmis::ObjectAction::CreateDocument ) ); } void GDriveTest::getFolderAllowableActionsTest( ) { curl_mockup_reset( ); static const string folderId ("aFolderId"); GDriveSession session = getTestSession( USERNAME, PASSWORD ); string url = BASE_URL + "/files/" + folderId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/gdrive/folder.json", 200, true); libcmis::FolderPtr folder = session.getFolder( folderId ); boost::shared_ptr< libcmis::AllowableActions > actions = folder->getAllowableActions( ); CPPUNIT_ASSERT_MESSAGE( "CreateDocument allowable action should be true", actions->isDefined( libcmis::ObjectAction::CreateDocument ) && actions->isAllowed( libcmis::ObjectAction::CreateDocument ) ); CPPUNIT_ASSERT_MESSAGE( "GetContentStream allowable action should be false", actions->isDefined( libcmis::ObjectAction::GetContentStream ) && !actions->isAllowed( libcmis::ObjectAction::GetContentStream ) ); } void GDriveTest::checkOutTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); static const string documentId( "aFileId" ); string url = BASE_URL + "/files/" + documentId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/gdrive/document.json", 200, true); libcmis::ObjectPtr object = session.getObject( documentId ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); libcmis::DocumentPtr checkout = document->checkOut( ); CPPUNIT_ASSERT_MESSAGE( "CheckOut failed", NULL != checkout ); } void GDriveTest::checkInTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); const string documentId( "aFileId" ); const string uploadBaseUrl = "https://www.googleapis.com/upload/drive/v2/files/"; string url = BASE_URL + "/files/" + documentId; string putUrl = uploadBaseUrl + documentId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/gdrive/document2.json", 200, true); libcmis::ObjectPtr object = session.getObject( documentId ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); curl_mockup_addResponse( url.c_str( ), "", "PUT", DATA_DIR "/gdrive/document2.json", 200, true); curl_mockup_addResponse( putUrl.c_str( ), "", "PUT", "Updated", 0, false ); string expectedContent( "content stream" ); boost::shared_ptr< ostream > os ( new stringstream ( expectedContent ) ); string filename( "aFileName" ); const PropertyPtrMap& properties = document->getProperties( ); libcmis::DocumentPtr checkIn = document->checkIn( true, "", properties, os, "text/plain", filename); CPPUNIT_ASSERT_MESSAGE( "CheckIn failed", NULL != checkIn ); } void GDriveTest::deleteTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); const string objectId( "aFileId" ); string url = BASE_URL + "/files/" + objectId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/gdrive/document2.json", 200, true); curl_mockup_addResponse( url.c_str( ),"", "DELETE", "", 204, false); libcmis::ObjectPtr object = session.getObject( objectId ); object->remove( ); const struct HttpRequest* deleteRequest = curl_mockup_getRequest( url.c_str( ), "", "DELETE" ); CPPUNIT_ASSERT_MESSAGE( "Delete request not sent", deleteRequest ); curl_mockup_HttpRequest_free( deleteRequest ); } void GDriveTest::moveTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); const string objectId( "aFileId" ); const string sourceId( "aFolderId" ); const string desId( "aNewFolderId" ); string url = BASE_URL + "/files/" + objectId; string sourceUrl = BASE_URL + "/files/" + sourceId; string desUrl = BASE_URL + "/files/" + desId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/gdrive/document2.json", 200, true ); curl_mockup_addResponse( url.c_str( ), "", "PUT", DATA_DIR "/gdrive/document2.json", 200, true ); curl_mockup_addResponse( sourceUrl.c_str( ), "", "GET", DATA_DIR "/gdrive/folder.json", 200, true ); curl_mockup_addResponse( desUrl.c_str( ), "", "GET", DATA_DIR "/gdrive/folder2.json", 200, true ); libcmis::ObjectPtr object = session.getObject( objectId ); libcmis::FolderPtr source = session.getFolder( sourceId ); libcmis::FolderPtr destination = session.getFolder( desId ); object->move( source, destination ); const char* moveRequest = curl_mockup_getRequestBody( url.c_str( ), "", "PUT" ); Json parentJson = Json::parse( string( moveRequest ) ); string newParentId = parentJson["parents"].getList().front()["id"].toString( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad new parent folder", desId, newParentId); } void GDriveTest::createDocumentTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); const string documentId( "aFileId" ); const string folderId( "aFolderId" ); const string folderUrl = BASE_URL + "/files/" + folderId; const string metaUrl = BASE_URL + "/files/"; const string uploadBaseUrl = "https://www.googleapis.com/upload/drive/v2/files/"; string uploadUrl = uploadBaseUrl + documentId; string documentUrl = metaUrl + documentId; curl_mockup_addResponse( folderUrl.c_str( ), "", "GET", DATA_DIR "/gdrive/folder.json", 200, true ); curl_mockup_addResponse( metaUrl.c_str( ), "", "POST", DATA_DIR "/gdrive/document.json", 200, true ); curl_mockup_addResponse( uploadUrl.c_str( ), "", "PUT", "updated", 0, false ); curl_mockup_addResponse( documentUrl.c_str( ), "", "GET", DATA_DIR "/gdrive/document2.json", 200, true); libcmis::FolderPtr parent = session.getFolder( folderId ); try { string expectedContent( "Test set content stream" ); boost::shared_ptr< ostream > os ( new stringstream ( expectedContent ) ); string filename( "aFileName" ); PropertyPtrMap properties; // function to test parent->createDocument( properties, os, "text/plain", filename ); const char* createRequest = curl_mockup_getRequestBody( metaUrl.c_str( ), "", "POST" ); Json request = Json::parse( string( createRequest ) ); string sentParentId = request["parents"].getList( ).front( )["id"].toString( ); string sentFilename = request["title"].toString( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad parents sent", folderId, sentParentId ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad filename sent", filename, sentFilename ); const char* content = curl_mockup_getRequestBody( uploadUrl.c_str( ), "", "PUT" ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad content uploaded", expectedContent, string( content ) ); } catch ( const libcmis::Exception& e ) { string msg = "Unexpected exception: "; msg += e.what(); CPPUNIT_FAIL( msg.c_str() ); } } void GDriveTest::createFolderTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); const string folderId( "aFolderId" ); const string folderUrl = BASE_URL + "/files/" + folderId; const string metaUrl = BASE_URL + "/files/"; curl_mockup_addResponse( folderUrl.c_str( ), "", "GET", DATA_DIR "/gdrive/folder.json", 200, true ); curl_mockup_addResponse( metaUrl.c_str( ), "", "POST", DATA_DIR "/gdrive/folder2.json", 200, true ); libcmis::FolderPtr parent = session.getFolder( folderId ); try { PropertyPtrMap properties; // function to test parent->createFolder( properties ); const char* createRequest = curl_mockup_getRequestBody( metaUrl.c_str( ), "", "POST" ); Json request = Json::parse( string( createRequest ) ); string sentParentId = request["parents"].getList( ).front( )["id"].toString( ); string sentMimeType = request["mimeType"].toString( ); string expectedMimeType( "application/vnd.google-apps.folder" ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad parents sent", folderId, sentParentId ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad mimeType", expectedMimeType, sentMimeType ); } catch ( const libcmis::Exception& e ) { string msg = "Unexpected exception: "; msg += e.what(); CPPUNIT_FAIL( msg.c_str() ); } } void GDriveTest::removeTreeTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); const string folderId( "aFolderId" ); const string folderUrl = BASE_URL + "/files/" + folderId; const string trashUrl = folderUrl + "/trash"; curl_mockup_addResponse( folderUrl.c_str( ), "", "GET", DATA_DIR "/gdrive/folder.json", 200, true ); curl_mockup_addResponse( trashUrl.c_str( ), "", "POST", "", 200, false ); libcmis::FolderPtr folder = session.getFolder( folderId ); // just make sure it doesn't crash folder->removeTree( ); } void GDriveTest::getContentStreamWithRenditionsTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); static const string documentId( "aFileId" ); string url = BASE_URL + "/files/" + documentId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/gdrive/document.json", 200, true); libcmis::ObjectPtr object = session.getObject( documentId ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); // pdf stream string pdfContent( "pdf Content stream" ); string pdfUrl = "pdflink"; curl_mockup_addResponse( pdfUrl.c_str( ), "", "GET", pdfContent.c_str( ), 0, false ); try { boost::shared_ptr< istream > is = document->getContentStream( "application/pdf" ); ostringstream out; out << is->rdbuf(); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Content stream doesn't match", pdfContent, out.str( ) ); } catch ( const libcmis::Exception& e ) { string msg = "Unexpected exception: "; msg += e.what(); CPPUNIT_FAIL( msg.c_str() ); } // ODF stream string odfContent( "open document Content stream" ); string odfUrl = "https://downloadLink"; curl_mockup_addResponse( odfUrl.c_str( ), "", "GET", odfContent.c_str( ), 0, false ); try { boost::shared_ptr< istream > is = document->getContentStream( "application/x-vnd.oasis.opendocument.spreadsheet" ); ostringstream out; out << is->rdbuf(); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Content stream doesn't match", odfContent, out.str( ) ); } catch ( const libcmis::Exception& e ) { string msg = "Unexpected exception: "; msg += e.what(); CPPUNIT_FAIL( msg.c_str() ); } // MS stream string msContent( "office document Content stream" ); string msUrl = "xlslink"; curl_mockup_addResponse( msUrl.c_str( ), "", "GET", msContent.c_str( ), 0, false ); try { boost::shared_ptr< istream > is = document->getContentStream( "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet" ); ostringstream out; out << is->rdbuf(); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Content stream doesn't match", msContent, out.str( ) ); } catch ( const libcmis::Exception& e ) { string msg = "Unexpected exception: "; msg += e.what(); CPPUNIT_FAIL( msg.c_str() ); } } void GDriveTest::updatePropertiesTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); const string documentId( "aFileId" ); const string documentUrl = BASE_URL + "/files/" + documentId; curl_mockup_addResponse( documentUrl.c_str( ), "", "GET", DATA_DIR "/gdrive/document.json", 200, true ); curl_mockup_addResponse( documentUrl.c_str( ), "", "PUT", DATA_DIR "/gdrive/document-updated.json", 200, true ); // Values for the test string propertyName( "cmis:name" ); string expectedValue( "New Title" ); libcmis::ObjectPtr object = session.getObject( documentId ); // Fill the map of properties to change PropertyPtrMap newProperties; libcmis::ObjectTypePtr objectType = object->getTypeDescription( ); map< string, libcmis::PropertyTypePtr >::iterator it = objectType->getPropertiesTypes( ).find( propertyName ); vector< string > values; values.push_back( expectedValue ); libcmis::PropertyPtr property( new libcmis::Property( it->second, values ) ); newProperties[ propertyName ] = property; // Update the properties (method to test) object->updateProperties( newProperties ); // Check that the sent request is OK const char* updateRequest = curl_mockup_getRequestBody( documentUrl.c_str( ), "", "PUT" ); // Check the sent properties Json json = Json::parse( string( updateRequest ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Only the updated properties should be sent", size_t( 1 ), json.getObjects().size( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "title key not present", expectedValue, json["title"].toString( ) ); // Check that the object is updated CPPUNIT_ASSERT_EQUAL_MESSAGE( "Object not updated", expectedValue, object->getName() ); } void GDriveTest::propertyCopyTest( ) { string name = "cmis:name"; string value = "some value"; GDriveProperty property( name, Json( value.c_str() ) ); { GDriveProperty copy = property; CPPUNIT_ASSERT_EQUAL( name, copy.getPropertyType()->getId() ); CPPUNIT_ASSERT_EQUAL( value, copy.getStrings()[0] ); } { GDriveProperty copy; copy = property; CPPUNIT_ASSERT_EQUAL( name, copy.getPropertyType()->getId() ); CPPUNIT_ASSERT_EQUAL( value, copy.getStrings()[0] ); } } void GDriveTest::getRefreshTokenTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Refresh token does not match", string ("mock-refresh-token"), session.getRefreshToken( ) ); } void GDriveTest::getThumbnailUrlTest( ) { curl_mockup_reset( ); GDriveSession session = getTestSession( USERNAME, PASSWORD ); const string documentId( "aFileId" ); const string documentUrl = BASE_URL + "/files/" + documentId; curl_mockup_addResponse( documentUrl.c_str( ), "", "GET", DATA_DIR "/gdrive/document.json", 200, true ); libcmis::ObjectPtr document = session.getObject( documentId ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Thumbnail URL does not match", string ("https://aThumbnailLink"), document->getThumbnailUrl( ) ); } void GDriveTest::getAllVersionsTest( ) { curl_mockup_reset( ); static const string objectId ("aFileId"); GDriveSession session = getTestSession( USERNAME, PASSWORD ); string url = BASE_URL + "/files/" + objectId; curl_mockup_addResponse( url.c_str( ), "", "GET", DATA_DIR "/gdrive/document.json", 200, true); string revisionUrl = url + "/revisions"; curl_mockup_addResponse( revisionUrl.c_str( ), "", "GET", DATA_DIR "/gdrive/allVersions.json", 200, true); libcmis::ObjectPtr obj = session.getObject( objectId ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( obj ); // Method to test vector< libcmis::DocumentPtr > versions = document->getAllVersions( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of versions", size_t( 3 ), versions.size( ) ); } CPPUNIT_TEST_SUITE_REGISTRATION( GDriveTest ); ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/test-jsonutils.cxx���������������������������������������������������������0000664�0001750�0001750�00000013512�13407414352�015646� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2013 Cao Cuong Ngo <cao.cuong.ngo@gmail.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <cppunit/extensions/HelperMacros.h> #include <cppunit/TestFixture.h> #include <cppunit/TestAssert.h> #include <string> #include <fstream> #include <cerrno> #if defined __clang__ #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wkeyword-macro" #endif #define private public #define protected public #if defined __clang__ #pragma clang diagnostic pop #endif #include <libcmis/property.hxx> #include <libcmis/property-type.hxx> #include "json-utils.hxx" using namespace std; using namespace libcmis; class JsonTest : public CppUnit::TestFixture { public: void parseTest( ); void parseTypeTest( ); void createFromPropertyTest( ); void createFromPropertiesTest( ); void badKeyTest( ); void addTest( ); CPPUNIT_TEST_SUITE( JsonTest ); CPPUNIT_TEST( parseTest ); CPPUNIT_TEST( parseTypeTest ); CPPUNIT_TEST( createFromPropertyTest ); CPPUNIT_TEST( createFromPropertiesTest ); CPPUNIT_TEST( badKeyTest ); CPPUNIT_TEST( addTest ); CPPUNIT_TEST_SUITE_END( ); }; string getFileContents( const char *filename) { std::ifstream in( filename, std::ios::in | std::ios::binary ); if (in) { std::string contents; in.seekg( 0, std::ios::end ); contents.resize(in.tellg( ) ); in.seekg( 0, std::ios::beg ); in.read( &contents[0], contents.size( ) ); in.close( ); return contents; } throw ( errno ); } Json parseFile( string fileName ) { Json json = Json::parse( getFileContents( fileName.c_str( ) ) ); return json; } void JsonTest::parseTest( ) { Json json = parseFile( DATA_DIR "/gdrive/jsontest-good.json" ); string kind = json["kind"].toString( ); string id = json["id"].toString( ); string mimeType = json["mimeType"].toString( ); string createdDate = json["createdDate"].toString( ); string intTest = json["intTest"].toString( ); string doubleTest = json["doubleTest"].toString( ); string editable = json["editable"].toString( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong kind", string( "drive#file" ), kind ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong id", string( "aFileId"), id ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong mimeType", string( "application/vnd.google-apps.form"), mimeType ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong createdDate", string( "2010-04-28T14:53:23.141Z"), createdDate ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong intTest", string("-123"), intTest ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong doubleTest", string("-123.456"), doubleTest ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong editable", string( "true"), editable ); } void JsonTest::parseTypeTest( ) { Json json = parseFile( DATA_DIR "/gdrive/jsontest-good.json" ); Json::Type stringType = json["kind"].getDataType( ); Json::Type boolType = json["editable"].getDataType( ); Json::Type intType = json["intTest"].getDataType( ); Json::Type doubleType = json["doubleTest"].getDataType( ); Json::Type dateTimeType = json["createdDate"].getDataType( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong string type", Json::json_string, stringType ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong bool type", Json::json_bool, boolType ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong int type", Json::json_int, intType ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong double type", Json::json_double, doubleType ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong datetime type", Json::json_datetime, dateTimeType ); } void JsonTest::createFromPropertyTest( ) { vector< string > values; string expected("Value 1" ); values.push_back( expected ); PropertyTypePtr propertyType( new PropertyType( ) ); PropertyPtr property( new Property( propertyType, values ) ); Json json( property ); CPPUNIT_ASSERT_EQUAL( expected, json.toString( ) ); } void JsonTest::createFromPropertiesTest( ) { vector< string > values; string expected( "value" ); values.push_back( "value" ); PropertyTypePtr propertyType( new PropertyType( ) ); PropertyPtr property( new libcmis::Property( propertyType, values ) ); PropertyPtrMap properties; properties[ "key" ] = property; Json json( properties ); CPPUNIT_ASSERT_EQUAL( expected, json["key"].toString( ) ); } void JsonTest::badKeyTest( ) { Json json = parseFile( DATA_DIR "/gdrive/jsontest-good.json" ); // just make sure it doesn't crash here string notExist = json["nonExistedKey"].toString( ); CPPUNIT_ASSERT_EQUAL( string( ), notExist); } void JsonTest::addTest( ) { Json json = parseFile( DATA_DIR "/gdrive/jsontest-good.json" ); Json addJson("added"); json.add( "new", addJson); CPPUNIT_ASSERT_EQUAL( addJson.toString( ), json["new"].toString( ) ); } CPPUNIT_TEST_SUITE_REGISTRATION( JsonTest ); ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/test-atom.cxx��������������������������������������������������������������0000664�0001750�0001750�00000165551�13407414352�014567� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <cppunit/extensions/HelperMacros.h> #include <cppunit/TestFixture.h> #include <cppunit/TestAssert.h> #include <sstream> #define SERVER_URL string( "http://mockup/binding" ) #define SERVER_REPOSITORY string( "mock" ) #define SERVER_USERNAME "tester" #define SERVER_PASSWORD "somepass" #if defined __clang__ #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wkeyword-macro" #endif #define private public #define protected public #if defined __clang__ #pragma clang diagnostic pop #endif #include <libcmis/document.hxx> #include <libcmis/session-factory.hxx> #include <mockup-config.h> #include "test-helpers.hxx" #include "atom-session.hxx" using namespace std; using libcmis::PropertyPtrMap; class AtomTest : public CppUnit::TestFixture { public: void sessionCreationTest( ); void sessionCreationBadAuthTest( ); void sessionCreationProxyTest( ); void authCallbackTest( ); void invalidSSLTest( ); void getRepositoriesTest( ); void getTypeTest( ); void getUnexistantTypeTest( ); void getTypeParentsTest( ); void getTypeChildrenTest( ); void getObjectTest( ); void getDocumentTest( ); void getDocumentRelationshipsTest( ); void getUnexistantObjectTest( ); void getFolderTest( ); void getFolderBadTypeTest( ); void getByPathValidTest( ); void getByPathInvalidTest( ); void getRenditionsTest( ); void getAllowableActionsTest( ); void getAllowableActionsNotIncludedTest( ); void getChildrenTest( ); void getDocumentParentsTest( ); void getContentStreamTest( ); void setContentStreamTest( ); void updatePropertiesTest( ); void updatePropertiesEmptyTest( ); void createFolderTest( ); void createFolderBadTypeTest( ); void createDocumentTest( ); void deleteDocumentTest( ); void deleteFolderTreeTest( ); void checkOutTest( ); void cancelCheckOutTest( ); void checkInTest( ); void getAllVersionsTest( ); void moveTest( ); CPPUNIT_TEST_SUITE( AtomTest ); CPPUNIT_TEST( sessionCreationTest ); CPPUNIT_TEST( sessionCreationBadAuthTest ); CPPUNIT_TEST( sessionCreationProxyTest ); CPPUNIT_TEST( authCallbackTest ); CPPUNIT_TEST( invalidSSLTest ); CPPUNIT_TEST( getRepositoriesTest ); CPPUNIT_TEST( getTypeTest ); CPPUNIT_TEST( getUnexistantTypeTest ); CPPUNIT_TEST( getTypeParentsTest ); CPPUNIT_TEST( getTypeChildrenTest ); CPPUNIT_TEST( getObjectTest ); CPPUNIT_TEST( getDocumentTest ); CPPUNIT_TEST( getDocumentRelationshipsTest ); CPPUNIT_TEST( getUnexistantObjectTest ); CPPUNIT_TEST( getFolderTest ); CPPUNIT_TEST( getFolderBadTypeTest ); CPPUNIT_TEST( getByPathValidTest ); CPPUNIT_TEST( getByPathInvalidTest ); CPPUNIT_TEST( getRenditionsTest ); CPPUNIT_TEST( getAllowableActionsTest ); CPPUNIT_TEST( getAllowableActionsNotIncludedTest ); CPPUNIT_TEST( getChildrenTest ); CPPUNIT_TEST( getDocumentParentsTest ); CPPUNIT_TEST( getContentStreamTest ); CPPUNIT_TEST( setContentStreamTest ); CPPUNIT_TEST( updatePropertiesTest ); CPPUNIT_TEST( updatePropertiesEmptyTest ); CPPUNIT_TEST( createFolderTest ); CPPUNIT_TEST( createFolderBadTypeTest ); CPPUNIT_TEST( createDocumentTest ); CPPUNIT_TEST( deleteDocumentTest ); CPPUNIT_TEST( deleteFolderTreeTest ); CPPUNIT_TEST( checkOutTest ); CPPUNIT_TEST( cancelCheckOutTest ); CPPUNIT_TEST( checkInTest ); CPPUNIT_TEST( getAllVersionsTest ); CPPUNIT_TEST( moveTest ); CPPUNIT_TEST_SUITE_END( ); AtomPubSession getTestSession( string username = string( ), string password = string( ) ); }; class TestAuthProvider : public libcmis::AuthProvider { bool m_fail; public: TestAuthProvider( bool fail ) : m_fail( fail ) { } bool authenticationQuery( std::string&, std::string& password ) { password = SERVER_PASSWORD; return !m_fail; } }; class TestCertValidationHandler : public libcmis::CertValidationHandler { public: bool m_fail; vector< string > m_chain; TestCertValidationHandler( bool fail ) : m_fail( fail ), m_chain() { } bool validateCertificate( vector< string > chain ) { m_chain = chain; return !m_fail; } }; CPPUNIT_TEST_SUITE_REGISTRATION( AtomTest ); void AtomTest::sessionCreationTest( ) { // Response showing one mock repository curl_mockup_reset( ); curl_mockup_setResponse( DATA_DIR "/atom/workspaces.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session( SERVER_URL, SERVER_REPOSITORY, SERVER_USERNAME, SERVER_PASSWORD ); // Check for the mandatory collection URLs CPPUNIT_ASSERT_MESSAGE( "root collection URL missing", !session.getAtomRepository()->getCollectionUrl( Collection::Root ).empty() ); CPPUNIT_ASSERT_MESSAGE( "types collection URL missing", !session.getAtomRepository()->getCollectionUrl( Collection::Types ).empty() ); CPPUNIT_ASSERT_MESSAGE( "query collection URL missing", !session.getAtomRepository()->getCollectionUrl( Collection::Query ).empty() ); // The optional collection URLs are present on InMemory, so check them CPPUNIT_ASSERT_MESSAGE( "checkedout collection URL missing", !session.getAtomRepository()->getCollectionUrl( Collection::CheckedOut ).empty() ); CPPUNIT_ASSERT_MESSAGE( "unfiled collection URL missing", !session.getAtomRepository()->getCollectionUrl( Collection::Unfiled ).empty() ); // Check for the mandatory URI template URLs CPPUNIT_ASSERT_MESSAGE( "objectbyid URI template URL missing", !session.getAtomRepository()->getUriTemplate( UriTemplate::ObjectById ).empty() ); CPPUNIT_ASSERT_MESSAGE( "objectbypath URI template URL missing", !session.getAtomRepository()->getUriTemplate( UriTemplate::ObjectByPath ).empty() ); CPPUNIT_ASSERT_MESSAGE( "typebyid URI template URL missing", !session.getAtomRepository()->getUriTemplate( UriTemplate::TypeById ).empty() ); // The optional URI template URL is present on InMemory, so check it CPPUNIT_ASSERT_MESSAGE( "query URI template URL missing", !session.getAtomRepository()->getUriTemplate( UriTemplate::Query ).empty() ); // Check that the root id is defined CPPUNIT_ASSERT_MESSAGE( "Root node ID is missing", !session.getRootId().empty() ); } void AtomTest::sessionCreationBadAuthTest( ) { // Response showing one mock repository curl_mockup_reset( ); curl_mockup_setResponse( DATA_DIR "/atom/workspaces.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); try { AtomPubSession session( SERVER_URL, SERVER_REPOSITORY, "bad", "bad" ); CPPUNIT_FAIL( "Exception should have been thrown" ); } catch ( const libcmis::Exception& e ) { CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong error type", string( "permissionDenied" ), e.getType( ) ); } } void AtomTest::sessionCreationProxyTest( ) { // Response showing one mock repository curl_mockup_reset( ); curl_mockup_setResponse( DATA_DIR "/atom/workspaces.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); string proxy( "proxy" ); string noProxy( "noProxy" ); string proxyUser( "proxyUser" ); string proxyPass( "proxyPass" ); libcmis::SessionFactory::setProxySettings( proxy, noProxy, proxyUser, proxyPass ); AtomPubSession session( SERVER_URL, SERVER_REPOSITORY, SERVER_USERNAME, SERVER_PASSWORD ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Proxy not set", proxy, string( curl_mockup_getProxy( session.m_curlHandle ) ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "NoProxy not set", noProxy, string( curl_mockup_getNoProxy( session.m_curlHandle ) ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Proxy User not set", proxyUser, string( curl_mockup_getProxyUser( session.m_curlHandle ) ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Proxy Pass not set", proxyPass, string( curl_mockup_getProxyPass( session.m_curlHandle ) ) ); // Reset proxy settings to default for next tests libcmis::SessionFactory::setProxySettings( string(), string(), string(), string() ); } void AtomTest::authCallbackTest( ) { // Response showing one mock repository curl_mockup_reset( ); curl_mockup_setResponse( DATA_DIR "/atom/workspaces.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); // Test cancelled authentication { libcmis::AuthProviderPtr authProvider( new TestAuthProvider( true ) ); libcmis::SessionFactory::setAuthenticationProvider( authProvider ); try { AtomPubSession session( SERVER_URL, SERVER_REPOSITORY, SERVER_USERNAME, string( ) ); CPPUNIT_FAIL( "Should raise an exception saying the user cancelled the authentication" ); } catch ( const libcmis::Exception& e ) { CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong exception message", string( "User cancelled authentication request" ), string( e.what() ) ); } } // Test provided authentication { libcmis::AuthProviderPtr authProvider( new TestAuthProvider( false ) ); libcmis::SessionFactory::setAuthenticationProvider( authProvider ); AtomPubSession session( SERVER_URL, SERVER_REPOSITORY, SERVER_USERNAME, string( ) ); } } void AtomTest::invalidSSLTest( ) { // Response showing one mock repository curl_mockup_reset( ); curl_mockup_setResponse( DATA_DIR "/atom/workspaces.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); string badCert( "A really invalid SSL Certificate" ); curl_mockup_setSSLBadCertificate( badCert.c_str() ); // Test validated certificate case { libcmis::CertValidationHandlerPtr handler( new TestCertValidationHandler( false ) ); libcmis::SessionFactory::setCertificateValidationHandler( handler ); AtomPubSession session( SERVER_URL, SERVER_REPOSITORY, SERVER_USERNAME, SERVER_PASSWORD ); TestCertValidationHandler* handler_impl = static_cast< TestCertValidationHandler* >( handler.get( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of certificates provided", size_t( 1 ), handler_impl->m_chain.size( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad certificate provided", badCert, handler_impl->m_chain.front() ); } // Test cancelled validation case { libcmis::CertValidationHandlerPtr handler( new TestCertValidationHandler( true ) ); libcmis::SessionFactory::setCertificateValidationHandler( handler ); try { AtomPubSession session( SERVER_URL, SERVER_REPOSITORY, SERVER_USERNAME, SERVER_PASSWORD ); CPPUNIT_FAIL( "Should raise an exception saying the user didn't validate the SSL certificate" ); } catch ( const libcmis::Exception& e ) { CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong exception message", string( "Invalid SSL certificate" ), string( e.what() ) ); } } } void AtomTest::getRepositoriesTest( ) { // Response showing one mock repository curl_mockup_reset( ); curl_mockup_setResponse( DATA_DIR "/atom/workspaces.xml" ); AtomPubSession session( SERVER_URL, SERVER_REPOSITORY, SERVER_USERNAME, SERVER_PASSWORD ); vector< libcmis::RepositoryPtr > actual = session.getRepositories( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of repositories", size_t( 1 ), actual.size( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong repository found", SERVER_REPOSITORY, actual.front()->getId( ) ); } void AtomTest::getTypeTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/type", "id=cmis:folder", "GET", DATA_DIR "/atom/type-folder.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); string expectedId( "cmis:folder" ); libcmis::ObjectTypePtr actual = session.getType( expectedId ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong Id for fetched type", expectedId, actual->getId( ) ); } void AtomTest::getUnexistantTypeTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); string expectedId( "bad_type" ); try { session.getType( expectedId ); CPPUNIT_FAIL( "Exception should be raised: invalid ID" ); } catch ( const libcmis::Exception& e ) { CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong error type", string( "objectNotFound" ), e.getType() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong exception message", string( "No such type: bad_type" ), string( e.what() ) ); } } void AtomTest::getTypeParentsTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel2", "GET", DATA_DIR "/atom/type-docLevel2.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel1", "GET", DATA_DIR "/atom/type-docLevel1.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=cmis:document", "GET", DATA_DIR "/atom/type-document.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); libcmis::ObjectTypePtr actual = session.getType( "DocumentLevel2" ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong Parent type", string( "DocumentLevel1" ), actual->getParentType( )->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong Base type", string( "cmis:document" ), actual->getBaseType( )->getId( ) ); } void AtomTest::getTypeChildrenTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel1", "GET", DATA_DIR "/atom/type-docLevel1.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=cmis:document", "GET", DATA_DIR "/atom/type-document.xml" ); curl_mockup_addResponse( "http://mockup/mock/types", "typeId=cmis:document", "GET", DATA_DIR "/atom/typechildren-document.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); libcmis::ObjectTypePtr actual = session.getType( "cmis:document" ); vector< libcmis::ObjectTypePtr > children = actual->getChildren( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of children", size_t( 1 ), children.size( ) ); } void AtomTest::getObjectTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/id", "id=valid-object", "GET", DATA_DIR "/atom/valid-object.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=cmis:folder", "GET", DATA_DIR "/atom/type-folder.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); string expectedId( "valid-object" ); libcmis::ObjectPtr actual = session.getObject( expectedId ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong Id for fetched object", expectedId, actual->getId( ) ); } void AtomTest::getDocumentTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/id", "id=test-document", "GET", DATA_DIR "/atom/test-document.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel2", "GET", DATA_DIR "/atom/type-docLevel2.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); string expectedId( "test-document" ); libcmis::ObjectPtr actual = session.getObject( expectedId ); // Do we have a document? libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( actual ); CPPUNIT_ASSERT_MESSAGE( "Fetched object should be an instance of libcmis::DocumentPtr", NULL != document ); // Test the document properties CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong document ID", expectedId, document->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong document name", string( "Test Document" ), document->getName( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong document type", string( "text/plain" ), document->getContentType( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong base type", string( "cmis:document" ), document->getBaseType( ) ); CPPUNIT_ASSERT_MESSAGE( "CreatedBy is missing", !document->getCreatedBy( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "CreationDate is missing", !document->getCreationDate( ).is_not_a_date_time() ); CPPUNIT_ASSERT_MESSAGE( "LastModifiedBy is missing", !document->getLastModifiedBy( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "LastModificationDate is missing", !document->getLastModificationDate( ).is_not_a_date_time() ); CPPUNIT_ASSERT_MESSAGE( "ChangeToken is missing", !document->getChangeToken( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "Content length is missing", 12345 == document->getContentLength( ) ); } void AtomTest::getDocumentRelationshipsTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/id", "id=test-document", "GET", DATA_DIR "/atom/test-document-relationships.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel2", "GET", DATA_DIR "/atom/type-docLevel2.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); string expectedId( "test-document" ); libcmis::ObjectPtr actual = session.getObject( expectedId ); // Do we have a document? libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( actual ); CPPUNIT_ASSERT_MESSAGE( "Fetched object should be an instance of libcmis::DocumentPtr", NULL != document ); // Test the document properties CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong document ID", expectedId, document->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong document name", string( "Test Document" ), document->getName( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong document type", string( "text/plain" ), document->getContentType( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong base type", string( "cmis:document" ), document->getBaseType( ) ); CPPUNIT_ASSERT_MESSAGE( "CreatedBy is missing", !document->getCreatedBy( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "CreationDate is missing", !document->getCreationDate( ).is_not_a_date_time() ); CPPUNIT_ASSERT_MESSAGE( "LastModifiedBy is missing", !document->getLastModifiedBy( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "LastModificationDate is missing", !document->getLastModificationDate( ).is_not_a_date_time() ); CPPUNIT_ASSERT_MESSAGE( "ChangeToken is missing", !document->getChangeToken( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "Content length is missing", 12345 == document->getContentLength( ) ); } void AtomTest::getFolderTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/id", "id=valid-object", "GET", DATA_DIR "/atom/valid-object.xml" ); curl_mockup_addResponse( "http://mockup/mock/id", "id=root-folder", "GET", DATA_DIR "/atom/root-folder.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=cmis:folder", "GET", DATA_DIR "/atom/type-folder.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); string expectedId( "valid-object" ); libcmis::FolderPtr actual = session.getFolder( expectedId ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong folder ID", expectedId, actual->getId( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong folder name", string( "Valid Object" ), actual->getName( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong folder path", string( "/Valid Object" ), actual->getPath( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong folder paths", string( "/Valid Object" ), actual->getPaths( )[0] ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Folder should have only one path", size_t(1), actual->getPaths( ).size() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong base type", string( "cmis:folder" ), actual->getBaseType( ) ); CPPUNIT_ASSERT_MESSAGE( "Missing folder parent", actual->getFolderParent( ).get( ) ); CPPUNIT_ASSERT_MESSAGE( "Not a root folder", !actual->isRootFolder() ); CPPUNIT_ASSERT_MESSAGE( "CreatedBy is missing", !actual->getCreatedBy( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "CreationDate is missing", !actual->getCreationDate( ).is_not_a_date_time() ); CPPUNIT_ASSERT_MESSAGE( "LastModifiedBy is missing", !actual->getLastModifiedBy( ).empty( ) ); CPPUNIT_ASSERT_MESSAGE( "LastModificationDate is missing", !actual->getLastModificationDate( ).is_not_a_date_time() ); CPPUNIT_ASSERT_MESSAGE( "ChangeToken is missing", !actual->getChangeToken( ).empty( ) ); } void AtomTest::getFolderBadTypeTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/id", "id=test-document", "GET", DATA_DIR "/atom/test-document.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel2", "GET", DATA_DIR "/atom/type-docLevel2.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); libcmis::FolderPtr actual = session.getFolder( "test-document" ); CPPUNIT_ASSERT_MESSAGE( "returned folder should be an empty pointer", NULL == actual ); } void AtomTest::getUnexistantObjectTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); string id( "bad_object" ); try { session.getObject( id ); CPPUNIT_FAIL( "Exception should be raised: invalid ID" ); } catch ( const libcmis::Exception& e ) { CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong CMIS exception type", string( "objectNotFound" ), e.getType() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong exception message", string( "No such node: " ) + id, string( e.what() ) ); } } void AtomTest::getByPathValidTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/path", "path=/Valid Object", "GET", DATA_DIR "/atom/valid-object.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=cmis:folder", "GET", DATA_DIR "/atom/type-folder.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); libcmis::ObjectPtr actual = session.getObjectByPath( string( "/Valid Object" ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong Id for fetched object", string( "valid-object" ), actual->getId( ) ); } void AtomTest::getByPathInvalidTest( ) { curl_mockup_reset( ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); try { session.getObjectByPath( string( "/some/invalid/path" ) ); CPPUNIT_FAIL( "Exception should be thrown: invalid Path" ); } catch ( const libcmis::Exception& e ) { CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong error type", string( "objectNotFound" ), e.getType() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong exception message", string( "No node corresponding to path: /some/invalid/path" ), string( e.what() ) ); } } void AtomTest::getRenditionsTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/id", "id=test-document", "GET", DATA_DIR "/atom/test-document.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel2", "GET", DATA_DIR "/atom/type-docLevel2.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); string expectedId( "test-document" ); libcmis::ObjectPtr actual = session.getObject( expectedId ); std::vector< libcmis::RenditionPtr > renditions = actual->getRenditions( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad renditions count", size_t( 2 ), renditions.size( ) ); libcmis::RenditionPtr rendition = renditions[0]; CPPUNIT_ASSERT( rendition->isThumbnail() ); rendition = renditions[1]; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad rendition mime type", string( "application/pdf" ), rendition->getMimeType( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad rendition href", string( "http://mockup/mock/renditions?id=test-document-rendition2" ), rendition->getUrl() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad rendition length - default case", long( -1 ), rendition->getLength( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad rendition Title", string( "Doc as PDF" ), rendition->getTitle( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad rendition kind", string( "pdf" ), rendition->getKind( ) ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad rendition length - filled case", long( 40385 ), renditions[0]->getLength( ) ); } void AtomTest::getAllowableActionsTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/id", "id=valid-object", "GET", DATA_DIR "/atom/valid-object.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=cmis:folder", "GET", DATA_DIR "/atom/type-folder.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); string expectedId( "valid-object" ); libcmis::FolderPtr actual = session.getFolder( expectedId ); boost::shared_ptr< libcmis::AllowableActions > toCheck = actual->getAllowableActions( ); CPPUNIT_ASSERT_MESSAGE( "ApplyACL allowable action not defined... are all the actions read?", toCheck->isDefined( libcmis::ObjectAction::ApplyACL ) ); CPPUNIT_ASSERT_MESSAGE( "GetChildren allowable action should be true", toCheck->isDefined( libcmis::ObjectAction::GetChildren ) && toCheck->isAllowed( libcmis::ObjectAction::GetChildren ) ); } void AtomTest::getAllowableActionsNotIncludedTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/id", "id=valid-object", "GET", DATA_DIR "/atom/valid-object-noactions.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=cmis:folder", "GET", DATA_DIR "/atom/type-folder.xml" ); curl_mockup_addResponse( "http://mockup/mock/allowableactions", "id=valid-object", "GET", DATA_DIR "/atom/allowable-actions.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); string expectedId( "valid-object" ); libcmis::FolderPtr actual = session.getFolder( expectedId ); // In some cases (mostly when getting folder children), we may not have the allowable actions // included in the object answer. Test that we are querying them when needed in those cases. boost::shared_ptr< libcmis::AllowableActions > toCheck = actual->getAllowableActions( ); CPPUNIT_ASSERT_MESSAGE( "ApplyACL allowable action not defined... are all the actions read?", toCheck->isDefined( libcmis::ObjectAction::ApplyACL ) ); CPPUNIT_ASSERT_MESSAGE( "GetChildren allowable action should be true", toCheck->isDefined( libcmis::ObjectAction::GetChildren ) && toCheck->isAllowed( libcmis::ObjectAction::GetChildren ) ); } void AtomTest::getChildrenTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/children", "id=root-folder", "GET", DATA_DIR "/atom/root-children.xml" ); curl_mockup_addResponse( "http://mockup/mock/id", "id=root-folder", "GET", DATA_DIR "/atom/root-folder.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=cmis:folder", "GET", DATA_DIR "/atom/type-folder.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel2", "GET", DATA_DIR "/atom/type-docLevel2.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); vector< libcmis::ObjectPtr > children = session.getRootFolder()->getChildren( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of children", size_t( 5 ), children.size() ); int folderCount = 0; int documentCount = 0; for ( vector< libcmis::ObjectPtr >::iterator it = children.begin( ); it != children.end( ); ++it ) { if ( NULL != boost::dynamic_pointer_cast< libcmis::Folder >( *it ) ) ++folderCount; else if ( NULL != boost::dynamic_pointer_cast< libcmis::Document >( *it ) ) ++documentCount; } CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of folder children", 2, folderCount ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of document children", 3, documentCount ); } void AtomTest::getDocumentParentsTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/parents", "id=test-document", "GET", DATA_DIR "/atom/test-document-parents.xml" ); curl_mockup_addResponse( "http://mockup/mock/id", "id=test-document", "GET", DATA_DIR "/atom/test-document.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=cmis:folder", "GET", DATA_DIR "/atom/type-folder.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel2", "GET", DATA_DIR "/atom/type-docLevel2.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); libcmis::ObjectPtr object = session.getObject( "test-document" ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); CPPUNIT_ASSERT_MESSAGE( "Document expected", document != NULL ); vector< libcmis::FolderPtr > actual = document->getParents( ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad number of parents", size_t( 2 ), actual.size() ); vector< string > paths = document->getPaths(); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad number of paths", size_t( 2 ), paths.size() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad document paths", string( "/Parent 1/Test Document" ), paths[0] ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad document paths", string( "/Parent 2/Test Document" ), paths[1] ); } void AtomTest::getContentStreamTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/id", "id=test-document", "GET", DATA_DIR "/atom/test-document.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel2", "GET", DATA_DIR "/atom/type-docLevel2.xml" ); string expectedContent( "Some content stream" ); curl_mockup_addResponse( "http://mockup/mock/content/data.txt", "id=test-document", "GET", expectedContent.c_str( ), 0, false ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); libcmis::ObjectPtr object = session.getObject( "test-document" ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); try { boost::shared_ptr< istream > is = document->getContentStream( ); ostringstream out; out << is->rdbuf(); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Content stream doesn't match", expectedContent, out.str( ) ); } catch ( const libcmis::Exception& e ) { string msg = "Unexpected exception: "; msg += e.what(); CPPUNIT_FAIL( msg.c_str() ); } } void AtomTest::setContentStreamTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/id", "id=test-document", "GET", DATA_DIR "/atom/test-document.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel2", "GET", DATA_DIR "/atom/type-docLevel2.xml" ); curl_mockup_addResponse( "http://mockup/mock/content/data.txt", "id=test-document", "PUT", "Updated", 0, false ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); libcmis::ObjectPtr object = session.getObject( "test-document" ); libcmis::DocumentPtr document = boost::dynamic_pointer_cast< libcmis::Document >( object ); try { string expectedContent( "Some content stream to set" ); boost::shared_ptr< ostream > os ( new stringstream ( expectedContent ) ); string filename( "name.txt" ); document->setContentStream( os, "text/plain", filename ); CPPUNIT_ASSERT_MESSAGE( "Object not refreshed during setContentStream", object->getRefreshTimestamp( ) > 0 ); // Check the content has been properly uploaded const char* content = curl_mockup_getRequestBody( "http://mockup/mock/content/", "id=test-document", "PUT" ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Bad content uploaded", expectedContent, string( content ) ); } catch ( const libcmis::Exception& e ) { string msg = "Unexpected exception: "; msg += e.what(); CPPUNIT_FAIL( msg.c_str() ); } } void AtomTest::updatePropertiesTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/id", "id=test-document", "GET", DATA_DIR "/atom/test-document.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel2", "GET", DATA_DIR "/atom/type-docLevel2.xml" ); curl_mockup_addResponse( "http://mockup/mock/id", "id=test-document", "PUT", DATA_DIR "/atom/test-document-updated.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); // Values for the test libcmis::ObjectPtr object = session.getObject( "test-document" ); string propertyName( "cmis:name" ); string expectedValue( "New name" ); // Fill the map of properties to change PropertyPtrMap newProperties; libcmis::ObjectTypePtr objectType = object->getTypeDescription( ); map< string, libcmis::PropertyTypePtr >::iterator it = objectType->getPropertiesTypes( ).find( propertyName ); vector< string > values; values.push_back( expectedValue ); libcmis::PropertyPtr property( new libcmis::Property( it->second, values ) ); newProperties[ propertyName ] = property; // Update the properties (method to test) libcmis::ObjectPtr updated = object->updateProperties( newProperties ); // Check that the proper request has been send // In order to avoid to check changing strings (containing a timestamp), // get the cmisra:object tree and compare it. string request( curl_mockup_getRequestBody( "http://mockup/mock/id", "id=test-document", "PUT" ) ); string actualObject = test::getXmlNodeAsString( request, "/atom:entry/cmisra:object" ); string expectedObject = "<cmisra:object>" "<cmis:properties>" "<cmis:propertyString propertyDefinitionId=\"cmis:name\" localName=\"cmis:name\" " "displayName=\"Name\" queryName=\"cmis:name\">" "<cmis:value>New name</cmis:value>" "</cmis:propertyString>" "</cmis:properties>" "</cmisra:object>"; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request content sent", expectedObject, actualObject ); // Check that the properties are updated after the call PropertyPtrMap::iterator propIt = updated->getProperties( ).find( propertyName ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong value after refresh", expectedValue, propIt->second->getStrings().front( ) ); } void AtomTest::updatePropertiesEmptyTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/id", "id=test-document", "GET", DATA_DIR "/atom/test-document.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel2", "GET", DATA_DIR "/atom/type-docLevel2.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); // Values for the test libcmis::ObjectPtr object = session.getObject( "test-document" ); // Just leave the map empty and update PropertyPtrMap emptyProperties; libcmis::ObjectPtr updated = object->updateProperties( emptyProperties ); // Check that no HTTP request was sent int count = curl_mockup_getRequestsCount( "http://mockup/mock/id", "id=test-document", "PUT" ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "No HTTP request should have been sent", 0, count ); // Check that the object we got is the same than previous one CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong change token", object->getChangeToken(), updated->getChangeToken() ); } void AtomTest::createFolderTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/children", "id=root-folder", "POST", DATA_DIR "/atom/create-folder.xml" ); curl_mockup_addResponse( "http://mockup/mock/id", "id=root-folder", "GET", DATA_DIR "/atom/root-folder.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=cmis:folder", "GET", DATA_DIR "/atom/type-folder.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); libcmis::FolderPtr parent = session.getRootFolder( ); // Prepare the properties for the new object, object type is cmis:folder PropertyPtrMap props; libcmis::ObjectTypePtr type = session.getType( "cmis:folder" ); map< string, libcmis::PropertyTypePtr > propTypes = type->getPropertiesTypes( ); // Set the object name string expectedName( "create folder" ); map< string, libcmis::PropertyTypePtr >::iterator it = propTypes.find( string( "cmis:name" ) ); vector< string > nameValues; nameValues.push_back( expectedName ); libcmis::PropertyPtr nameProperty( new libcmis::Property( it->second, nameValues ) ); props.insert( pair< string, libcmis::PropertyPtr >( string( "cmis:name" ), nameProperty ) ); // set the object type it = propTypes.find( string( "cmis:objectTypeId" ) ); vector< string > typeValues; typeValues.push_back( "cmis:folder" ); libcmis::PropertyPtr typeProperty( new libcmis::Property( it->second, typeValues ) ); props.insert( pair< string, libcmis::PropertyPtr >( string( "cmis:objectTypeId" ), typeProperty ) ); // Actually send the folder creation request libcmis::FolderPtr created = parent->createFolder( props ); // Check that something came back CPPUNIT_ASSERT_MESSAGE( "Change token shouldn't be empty: object should have been refreshed", !created->getChangeToken( ).empty() ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong name", expectedName, created->getName( ) ); // Check that the proper request has been sent string request( curl_mockup_getRequestBody( "http://mockup/mock/children", "id=root-folder", "POST" ) ); string actualObject = test::getXmlNodeAsString( request, "/atom:entry/cmisra:object" ); string expectedObject = "<cmisra:object>" "<cmis:properties>" "<cmis:propertyString propertyDefinitionId=\"cmis:name\" localName=\"cmis:name\" " "displayName=\"Name\" queryName=\"cmis:name\">" "<cmis:value>create folder</cmis:value>" "</cmis:propertyString>" "<cmis:propertyId propertyDefinitionId=\"cmis:objectTypeId\" localName=\"cmis:objectTypeId\"" " displayName=\"Type-Id\" queryName=\"cmis:objectTypeId\">" "<cmis:value>cmis:folder</cmis:value>" "</cmis:propertyId>" "</cmis:properties>" "</cmisra:object>"; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request content sent", expectedObject, actualObject ); } void AtomTest::createFolderBadTypeTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/children", "id=root-folder", "POST", "Not a cmis:folder derived type", 409, false ); curl_mockup_addResponse( "http://mockup/mock/id", "id=root-folder", "GET", DATA_DIR "/atom/root-folder.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=cmis:folder", "GET", DATA_DIR "/atom/type-folder.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=cmis:document", "GET", DATA_DIR "/atom/type-document.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); libcmis::FolderPtr parent = session.getRootFolder( ); // Prepare the properties for the new object, object type is cmis:folder PropertyPtrMap props; libcmis::ObjectTypePtr type = session.getType( "cmis:folder" ); map< string, libcmis::PropertyTypePtr > propTypes = type->getPropertiesTypes( ); // Set the object name string expectedName( "create folder" ); map< string, libcmis::PropertyTypePtr >::iterator it = propTypes.find( string( "cmis:name" ) ); vector< string > nameValues; nameValues.push_back( expectedName ); libcmis::PropertyPtr nameProperty( new libcmis::Property( it->second, nameValues ) ); props.insert( pair< string, libcmis::PropertyPtr >( string( "cmis:name" ), nameProperty ) ); // set the object type it = propTypes.find( string( "cmis:objectTypeId" ) ); vector< string > typeValues; typeValues.push_back( "cmis:document" ); libcmis::PropertyPtr typeProperty( new libcmis::Property( it->second, typeValues ) ); props.insert( pair< string, libcmis::PropertyPtr >( string( "cmis:objectTypeId" ), typeProperty ) ); // Actually send the folder creation request try { parent->createFolder( props ); CPPUNIT_FAIL( "Should not succeed to return a folder" ); } catch ( libcmis::Exception& e ) { CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong error type", string( "constraint" ), e.getType() ); } // Check that the proper request has been sent string request( curl_mockup_getRequestBody( "http://mockup/mock/children", "id=root-folder", "POST" ) ); string actualObject = test::getXmlNodeAsString( request, "/atom:entry/cmisra:object" ); string expectedObject = "<cmisra:object>" "<cmis:properties>" "<cmis:propertyString propertyDefinitionId=\"cmis:name\" localName=\"cmis:name\" " "displayName=\"Name\" queryName=\"cmis:name\">" "<cmis:value>create folder</cmis:value>" "</cmis:propertyString>" "<cmis:propertyId propertyDefinitionId=\"cmis:objectTypeId\" localName=\"cmis:objectTypeId\"" " displayName=\"Type-Id\" queryName=\"cmis:objectTypeId\">" "<cmis:value>cmis:document</cmis:value>" "</cmis:propertyId>" "</cmis:properties>" "</cmisra:object>"; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request content sent", expectedObject, actualObject ); } void AtomTest::createDocumentTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/children", "id=root-folder", "POST", "Response body up to server", 201, false, "Location: http://mockup/mock/id?id=create-document\r\n" ); curl_mockup_addResponse( "http://mockup/mock/id", "id=create-document", "GET", DATA_DIR "/atom/create-document.xml" ); curl_mockup_addResponse( "http://mockup/mock/id", "id=root-folder", "GET", DATA_DIR "/atom/root-folder.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=cmis:folder", "GET", DATA_DIR "/atom/type-folder.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=cmis:document", "GET", DATA_DIR "/atom/type-document.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); libcmis::FolderPtr parent = session.getRootFolder( ); // Prepare the properties for the new object, object type is cmis:folder PropertyPtrMap props; libcmis::ObjectTypePtr type = session.getType( "cmis:document" ); map< string, libcmis::PropertyTypePtr > propTypes = type->getPropertiesTypes( ); // Set the object name string expectedName( "create document" ); map< string, libcmis::PropertyTypePtr >::iterator it = propTypes.find( string( "cmis:name" ) ); vector< string > nameValues; nameValues.push_back( expectedName ); libcmis::PropertyPtr nameProperty( new libcmis::Property( it->second, nameValues ) ); props.insert( pair< string, libcmis::PropertyPtr >( string( "cmis:name" ), nameProperty ) ); // set the object type it = propTypes.find( string( "cmis:objectTypeId" ) ); vector< string > typeValues; typeValues.push_back( "cmis:document" ); libcmis::PropertyPtr typeProperty( new libcmis::Property( it->second, typeValues ) ); props.insert( pair< string, libcmis::PropertyPtr >( string( "cmis:objectTypeId" ), typeProperty ) ); // Actually send the document creation request string content = "Some content"; boost::shared_ptr< ostream > os ( new stringstream( content ) ); string contentType = "text/plain"; string filename( "name.txt" ); libcmis::DocumentPtr created = parent->createDocument( props, os, contentType, filename ); // Check that something came back CPPUNIT_ASSERT_MESSAGE( "Change token shouldn't be empty: object should have been refreshed", !created->getChangeToken( ).empty() ); // Check that the name is ok CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong name set", expectedName, created->getName( ) ); // Check that the request is the expected one string request( curl_mockup_getRequestBody( "http://mockup/mock/children", "id=root-folder", "POST" ) ); string actualContent = test::getXmlNodeAsString( request, "/atom:entry/cmisra:content" ); string expectedContent = "<cmisra:content>" "<cmisra:mediatype>text/plain</cmisra:mediatype>" "<cmisra:base64>U29tZSBjb250ZW50</cmisra:base64>" "</cmisra:content>"; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request content sent", expectedContent, actualContent ); string actualObject = test::getXmlNodeAsString( request, "/atom:entry/cmisra:object" ); string expectedObject = "<cmisra:object>" "<cmis:properties>" "<cmis:propertyString propertyDefinitionId=\"cmis:name\" localName=\"cmis:name\" " "displayName=\"Name\" queryName=\"cmis:name\">" "<cmis:value>create document</cmis:value>" "</cmis:propertyString>" "<cmis:propertyId propertyDefinitionId=\"cmis:objectTypeId\" localName=\"cmis:objectTypeId\"" " displayName=\"Type-Id\" queryName=\"cmis:objectTypeId\">" "<cmis:value>cmis:document</cmis:value>" "</cmis:propertyId>" "</cmis:properties>" "</cmisra:object>"; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request object sent", expectedObject, actualObject ); } void AtomTest::deleteDocumentTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/id", "id=test-document", "GET", DATA_DIR "/atom/test-document.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel2", "GET", DATA_DIR "/atom/type-docLevel2.xml" ); curl_mockup_addResponse( "http://mockup/mock/id", "id=test-document", "DELETE", "", 204, false ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); libcmis::ObjectPtr object = session.getObject( "test-document" ); libcmis::Document* document = dynamic_cast< libcmis::Document* >( object.get() ); document->remove( ); // Test the sent request const char* request = curl_mockup_getRequestBody( "http://mockup/mock/id", "id=test-document", "DELETE" ); CPPUNIT_ASSERT_MESSAGE( "DELETE request not sent", request ); } void AtomTest::deleteFolderTreeTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/id", "id=valid-object", "GET", DATA_DIR "/atom/valid-object.xml" ); curl_mockup_addResponse( "http://mockup/mock/descendants", "id=valid-object", "DELETE", "", 204, false ); curl_mockup_addResponse( "http://mockup/mock/type", "id=cmis:folder", "GET", DATA_DIR "/atom/type-folder.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); libcmis::ObjectPtr object = session.getObject( "valid-object" ); libcmis::Folder* folder = dynamic_cast< libcmis::Folder* >( object.get() ); folder->removeTree( ); // Test the sent request const struct HttpRequest* request = curl_mockup_getRequest( "http://mockup/mock/descendants", "id=valid-object", "DELETE" ); CPPUNIT_ASSERT_MESSAGE( "DELETE request not sent", request ); curl_mockup_HttpRequest_free( request ); } void AtomTest::checkOutTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/id", "id=test-document", "GET", DATA_DIR "/atom/test-document.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel2", "GET", DATA_DIR "/atom/type-docLevel2.xml" ); curl_mockup_addResponse( "http://mockup/mock/checkedout", "", "POST", DATA_DIR "/atom/working-copy.xml", 201 ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); libcmis::ObjectPtr object = session.getObject( "test-document" ); libcmis::Document* document = dynamic_cast< libcmis::Document* >( object.get() ); libcmis::DocumentPtr pwc = document->checkOut( ); CPPUNIT_ASSERT_MESSAGE( "Missing returned Private Working Copy", pwc.get( ) != NULL ); PropertyPtrMap::iterator it = pwc->getProperties( ).find( string( "cmis:isVersionSeriesCheckedOut" ) ); vector< bool > values = it->second->getBools( ); CPPUNIT_ASSERT_MESSAGE( "cmis:isVersionSeriesCheckedOut isn't true", values.front( ) ); } void AtomTest::cancelCheckOutTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/id", "id=working-copy", "GET", DATA_DIR "/atom/working-copy.xml" ); curl_mockup_addResponse( "http://mockup/mock/id", "id=working-copy", "DELETE", "", 204, false ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel2", "GET", DATA_DIR "/atom/type-docLevel2.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); // First get a checked out document libcmis::ObjectPtr object = session.getObject( "working-copy" ); libcmis::DocumentPtr pwc = boost::dynamic_pointer_cast< libcmis::Document >( object ); pwc->cancelCheckout( ); // Check that the DELETE request was sent out const struct HttpRequest* request = curl_mockup_getRequest( "http://mockup/mock/id", "id=working-copy", "DELETE" ); CPPUNIT_ASSERT_MESSAGE( "DELETE request not sent", request ); curl_mockup_HttpRequest_free( request ); } void AtomTest::checkInTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel2", "GET", DATA_DIR "/atom/type-docLevel2.xml" ); curl_mockup_addResponse( "http://mockup/mock/id", "id=working-copy", "GET", DATA_DIR "/atom/working-copy.xml" ); curl_mockup_addResponse( "http://mockup/mock/id", "id=working-copy", "PUT", DATA_DIR "/atom/test-document.xml", 200, true, "Location: http://mockup/mock/id?id=valid-object" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); // First get a checked out document libcmis::ObjectPtr object = session.getObject( "working-copy" ); libcmis::DocumentPtr pwc = boost::dynamic_pointer_cast< libcmis::Document >( object ); // Do the checkin bool isMajor = true; string comment( "Some check-in comment" ); PropertyPtrMap properties; string newContent = "Some New content to check in"; boost::shared_ptr< ostream > stream ( new stringstream( newContent ) ); pwc->checkIn( isMajor, comment, properties, stream, "text/plain", "filename.txt" ); // Make sure that the expected request has been sent const struct HttpRequest* request = curl_mockup_getRequest( "http://mockup/mock/id", "id=working-copy", "PUT" ); CPPUNIT_ASSERT_MESSAGE( "PUT request not sent", request ); string actualContent = test::getXmlNodeAsString( request->body, "/atom:entry/cmisra:content" ); string expectedContent = "<cmisra:content><cmisra:mediatype>text/plain</cmisra:mediatype><cmisra:base64>U29tZSBOZXcgY29udGVudCB0byBjaGVjayBpbg==</cmisra:base64></cmisra:content>"; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong content sent", expectedContent, actualContent ); // Still needs to test that checkin request parameters were OK string url( request->url ); CPPUNIT_ASSERT_MESSAGE( "Sent checkin request has wrong major parameter", url.find("major=true") != string::npos ); CPPUNIT_ASSERT_MESSAGE( "Sent checkin request has wrong checkinComment parameter", url.find( "checkinComment=" + comment ) != string::npos ); CPPUNIT_ASSERT_MESSAGE( "Sent checkin request has no checkin parameter", url.find("checkin=true") != string::npos ); curl_mockup_HttpRequest_free( request ); } void AtomTest::getAllVersionsTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel2", "GET", DATA_DIR "/atom/type-docLevel2.xml" ); curl_mockup_addResponse( "http://mockup/mock/id", "id=test-document", "GET", DATA_DIR "/atom/test-document.xml" ); curl_mockup_addResponse( "http://mockup/mock/versions", "id=test-document", "GET", DATA_DIR "/atom/get-versions.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); // First get a document libcmis::ObjectPtr object = session.getObject( "test-document" ); libcmis::DocumentPtr doc = boost::dynamic_pointer_cast< libcmis::Document >( object ); // Get all the versions (method to check) vector< libcmis::DocumentPtr > versions = doc->getAllVersions( ); // Checks CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong number of versions", size_t( 2 ), versions.size( ) ); } void AtomTest::moveTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( "http://mockup/mock/type", "id=DocumentLevel2", "GET", DATA_DIR "/atom/type-docLevel2.xml" ); curl_mockup_addResponse( "http://mockup/mock/id", "id=test-document", "GET", DATA_DIR "/atom/test-document.xml" ); curl_mockup_addResponse( "http://mockup/mock/parents", "id=test-document", "GET", DATA_DIR "/atom/test-document-parents.xml" ); curl_mockup_addResponse( "http://mockup/mock/id", "id=valid-object", "GET", DATA_DIR "/atom/valid-object.xml" ); curl_mockup_addResponse( "http://mockup/mock/type", "id=cmis:folder", "GET", DATA_DIR "/atom/type-folder.xml" ); curl_mockup_addResponse( "http://mockup/mock/children", "id=valid-object", "POST", DATA_DIR "/atom/test-document.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); AtomPubSession session = getTestSession( SERVER_USERNAME, SERVER_PASSWORD ); libcmis::ObjectPtr object = session.getObject( "test-document" ); libcmis::Document* document = dynamic_cast< libcmis::Document* >( object.get() ); string destFolderId = "valid-object"; libcmis::FolderPtr src = document->getParents( ).front( ); libcmis::FolderPtr dest = session.getFolder( destFolderId ); document->move( src, dest ); // Check that the sent request has the expected params const struct HttpRequest* request = curl_mockup_getRequest( "http://mockup/mock/children", "id=valid-object", "POST" ); string url( request->url ); CPPUNIT_ASSERT_MESSAGE( "Sent move request has wrong or missing sourceFolderId", url.find("sourceFolderId=parent1") != string::npos ); // Check that we had the atom entry in the request body string actualObject = test::getXmlNodeAsString( request->body, "/atom:entry/cmisra:object/cmis:properties/cmis:propertyId[@propertyDefinitionId='cmis:objectId']" ); string expectedObject = "<cmis:propertyId propertyDefinitionId=\"cmis:objectId\" localName=\"cmis:objectId\"" " displayName=\"Object Id\" queryName=\"cmis:objectId\">" "<cmis:value>test-document</cmis:value>" "</cmis:propertyId>"; CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong request object sent", expectedObject, actualObject ); curl_mockup_HttpRequest_free( request ); } AtomPubSession AtomTest::getTestSession( string username, string password ) { AtomPubSession session; string buf; test::loadFromFile( DATA_DIR "/atom/workspaces.xml", buf ); session.parseServiceDocument( buf ); session.m_username = username; session.m_password = password; return session; } �������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/test-factory.cxx�����������������������������������������������������������0000664�0001750�0001750�00000030174�13407723631�015271� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <memory> #include <cppunit/extensions/HelperMacros.h> #include <cppunit/TestFixture.h> #include <cppunit/TestAssert.h> #if defined __clang__ #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wkeyword-macro" #endif #define private public #define protected public #if defined __clang__ #pragma clang diagnostic pop #endif #include <libcmis/session-factory.hxx> #include <atom-session.hxx> #include <ws-session.hxx> #include <gdrive-session.hxx> #include <onedrive-session.hxx> #include <sharepoint-session.hxx> #include <mockup-config.h> #include <test-helpers.hxx> #include <test-mockup-helpers.hxx> #define BINDING_ATOM string( "http://mockup/atom" ) #define BINDING_WS string( "http://mockup/ws" ) #define BINDING_SHAREPOINT string ( "http://mockup/sharepoint/_api/web" ) #define CONTEXTINFO_URL string ( "http://mockup/sharepoint/_api/contextinfo" ) #define BINDING_BAD "http://mockup/bad" #define BINDING_GDRIVE string ( "https://www.googleapis.com/drive/v2" ) #define BINDING_ONEDRIVE string ( "https://apis.live.net/v5.0" ) #define SERVER_REPOSITORY string( "mock" ) #define SERVER_USERNAME "tester" #define SERVER_PASSWORD "somepass" #define OAUTH_CLIENT_ID string ( "mock-id" ) #define OAUTH_CLIENT_SECRET string ( "mock-secret" ) #define OAUTH_SCOPE string ( "https://scope/url" ) #define OAUTH_REDIRECT_URI string ("redirect:uri" ) #define GDRIVE_AUTH_URL string ( "https://auth/url" ) #define GDRIVE_LOGIN_URL string ("https://login/url" ) #define GDRIVE_LOGIN_URL2 string ("https://login2/url" ) #define GDRIVE_APPROVAL_URL string ("https://approval/url" ) #define GDRIVE_TOKEN_URL string ( "https://token/url" ) #define ONEDRIVE_AUTH_URL string ( "https://auth/url" ) #define ONEDRIVE_TOKEN_URL string ( "https://token/url" ) using namespace std; namespace { void lcl_init_mockup_ws( ) { curl_mockup_reset( ); curl_mockup_addResponse( BINDING_WS.c_str( ), "", "GET", DATA_DIR "/ws/CMISWS-Service.wsdl" ); test::addWsResponse( string( BINDING_WS + "/services/RepositoryService" ).c_str(), DATA_DIR "/ws/repositories.http" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); } void lcl_init_mockup_atom( ) { curl_mockup_reset( ); curl_mockup_addResponse( BINDING_ATOM.c_str( ), "", "GET", DATA_DIR "/atom/workspaces.xml" ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); } void lcl_init_mockup_gdrive( ) { curl_mockup_reset( ); //login response string loginIdentifier = string("scope=") + OAUTH_SCOPE + string("&redirect_uri=") + OAUTH_REDIRECT_URI + string("&response_type=code") + string("&client_id=") + OAUTH_CLIENT_ID; curl_mockup_addResponse ( GDRIVE_AUTH_URL.c_str(), loginIdentifier.c_str( ), "GET", DATA_DIR "/gdrive/login1.html", 200, true); //authentication email curl_mockup_addResponse( GDRIVE_LOGIN_URL2.c_str( ), "", "POST", DATA_DIR "/gdrive/login2.html", 200, true); //authentication password, curl_mockup_addResponse( GDRIVE_LOGIN_URL.c_str( ), "", "POST", DATA_DIR "/gdrive/approve.html", 200, true); //approval response curl_mockup_addResponse( GDRIVE_APPROVAL_URL.c_str( ), "", "POST", DATA_DIR "/gdrive/authcode.html", 200, true); curl_mockup_addResponse ( GDRIVE_TOKEN_URL.c_str( ), "", "POST", DATA_DIR "/gdrive/token-response.json", 200, true ); } char* authCodeFallback( const char* /*url*/, const char* /*username*/, const char* /*password*/ ) { char *authCode = strdup( "authCode" ); return authCode; } void lcl_init_mockup_sharepoint( ) { curl_mockup_reset( ); curl_mockup_addResponse( BINDING_SHAREPOINT.c_str( ), "", "GET", "", 401, false ); curl_mockup_addResponse( ( BINDING_SHAREPOINT + "/currentuser" ).c_str( ), "", "GET", DATA_DIR "/sharepoint/auth-resp.json", 200, true ); curl_mockup_addResponse( CONTEXTINFO_URL.c_str( ), "", "POST", DATA_DIR "/sharepoint/xdigest.json", 200, true ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); } } class FactoryTest : public CppUnit::TestFixture { public: void createSessionAtomTest( ); void createSessionAtomBadAuthTest( ); void createSessionWSTest( ); void createSessionWSBadAuthTest( ); void createSessionNoCmisTest( ); void createSessionGDriveTest( ); void createSessionOneDriveTest( ); void createSessionSharePointTest( ); void createSessionSharePointDefaultAuthTest( ); void createSessionSharePointBadAuthTest( ); CPPUNIT_TEST_SUITE( FactoryTest ); CPPUNIT_TEST( createSessionAtomTest ); CPPUNIT_TEST( createSessionAtomBadAuthTest ); CPPUNIT_TEST( createSessionWSTest ); CPPUNIT_TEST( createSessionWSBadAuthTest ); CPPUNIT_TEST( createSessionNoCmisTest ); CPPUNIT_TEST( createSessionGDriveTest ); CPPUNIT_TEST( createSessionOneDriveTest ); CPPUNIT_TEST( createSessionSharePointTest ); CPPUNIT_TEST( createSessionSharePointDefaultAuthTest ); CPPUNIT_TEST( createSessionSharePointBadAuthTest ); CPPUNIT_TEST_SUITE_END( ); }; CPPUNIT_TEST_SUITE_REGISTRATION( FactoryTest ); void FactoryTest::createSessionAtomTest( ) { lcl_init_mockup_atom( ); unique_ptr< libcmis::Session > session( libcmis::SessionFactory::createSession( BINDING_ATOM, SERVER_USERNAME, SERVER_PASSWORD, SERVER_REPOSITORY ) ); CPPUNIT_ASSERT_MESSAGE( "Not an AtomPubSession", dynamic_cast< AtomPubSession* >( session.get() ) != NULL ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "More than one request for the binding", int( 1 ), curl_mockup_getRequestsCount( BINDING_ATOM.c_str( ), "", "GET" ) ); } void FactoryTest::createSessionAtomBadAuthTest( ) { lcl_init_mockup_atom( ); try { libcmis::SessionFactory::createSession( BINDING_ATOM, "Bad user", "Bad Password", SERVER_REPOSITORY ); CPPUNIT_FAIL( "Should throw exception" ); } catch ( const libcmis::Exception& e ) { CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong exception type", string( "permissionDenied" ), e.getType( ) ); } } void FactoryTest::createSessionWSTest( ) { lcl_init_mockup_ws( ); unique_ptr< libcmis::Session > session( libcmis::SessionFactory::createSession( BINDING_WS, SERVER_USERNAME, SERVER_PASSWORD, SERVER_REPOSITORY ) ); CPPUNIT_ASSERT_MESSAGE( "Not a WSSession", dynamic_cast< WSSession* >( session.get() ) != NULL ); CPPUNIT_ASSERT_EQUAL_MESSAGE( "More than one request for the binding", int( 1 ), curl_mockup_getRequestsCount( BINDING_WS.c_str( ), "", "GET" ) ); } void FactoryTest::createSessionWSBadAuthTest( ) { lcl_init_mockup_ws( ); try { libcmis::SessionFactory::createSession( BINDING_WS, "Bad User", "Bad Pass", SERVER_REPOSITORY ); CPPUNIT_FAIL( "Should throw exception" ); } catch ( const libcmis::Exception& e ) { CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong exception type", string( "permissionDenied" ), e.getType( ) ); } } void FactoryTest::createSessionGDriveTest( ) { lcl_init_mockup_gdrive( ); libcmis::OAuth2DataPtr oauth2Data( new libcmis::OAuth2Data( GDRIVE_AUTH_URL, GDRIVE_TOKEN_URL, OAUTH_SCOPE, OAUTH_REDIRECT_URI, OAUTH_CLIENT_ID, OAUTH_CLIENT_SECRET )); unique_ptr< libcmis::Session > session( libcmis::SessionFactory::createSession( BINDING_GDRIVE, SERVER_USERNAME, SERVER_PASSWORD, SERVER_REPOSITORY, false, oauth2Data ) ); CPPUNIT_ASSERT_MESSAGE( "Not a GDriveSession", dynamic_cast< GDriveSession* >( session.get() ) != NULL ); } void FactoryTest::createSessionOneDriveTest( ) { lcl_init_mockup_gdrive( ); libcmis::OAuth2DataPtr oauth2Data( new libcmis::OAuth2Data( ONEDRIVE_AUTH_URL, ONEDRIVE_TOKEN_URL, OAUTH_SCOPE, OAUTH_REDIRECT_URI, OAUTH_CLIENT_ID, OAUTH_CLIENT_SECRET )); libcmis::SessionFactory::setOAuth2AuthCodeProvider( authCodeFallback ); unique_ptr< libcmis::Session > session( libcmis::SessionFactory::createSession( BINDING_ONEDRIVE, SERVER_USERNAME, SERVER_PASSWORD, SERVER_REPOSITORY, false, oauth2Data ) ); CPPUNIT_ASSERT_MESSAGE( "Not a OneDriveSession", dynamic_cast< OneDriveSession* >( session.get() ) != NULL ); } void FactoryTest::createSessionSharePointTest( ) { lcl_init_mockup_sharepoint( ); unique_ptr< libcmis::Session > session( libcmis::SessionFactory::createSession( BINDING_SHAREPOINT, SERVER_USERNAME, SERVER_PASSWORD, SERVER_REPOSITORY ) ); CPPUNIT_ASSERT_MESSAGE( "Not a SharePoint Session", dynamic_cast< SharePointSession* >( session.get() ) != NULL ); } void FactoryTest::createSessionSharePointDefaultAuthTest( ) { curl_mockup_addResponse( BINDING_SHAREPOINT.c_str( ), "", "GET", DATA_DIR "/sharepoint/auth-xml-resp.xml", 200, true ); curl_mockup_addResponse( CONTEXTINFO_URL.c_str( ), "", "POST", DATA_DIR "/sharepoint/xdigest.json", 200, true ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); unique_ptr< libcmis::Session > session( libcmis::SessionFactory::createSession( BINDING_SHAREPOINT, SERVER_USERNAME, SERVER_PASSWORD, SERVER_REPOSITORY ) ); CPPUNIT_ASSERT_MESSAGE( "Not a SharePoint Session", dynamic_cast< SharePointSession* >( session.get() ) != NULL ); } void FactoryTest::createSessionSharePointBadAuthTest( ) { lcl_init_mockup_sharepoint( ); try { libcmis::SessionFactory::createSession( BINDING_ATOM, "Bad user", "Bad Password", SERVER_REPOSITORY ); CPPUNIT_FAIL( "Should throw exception" ); } catch ( const libcmis::Exception& e ) { CPPUNIT_ASSERT_EQUAL_MESSAGE( "Wrong exception type", string( "permissionDenied" ), e.getType( ) ); } } void FactoryTest::createSessionNoCmisTest( ) { curl_mockup_reset( ); curl_mockup_addResponse( BINDING_BAD, "", "GET", "<p>Some non CMIS content</p>", 200, false ); curl_mockup_setCredentials( SERVER_USERNAME, SERVER_PASSWORD ); unique_ptr< libcmis::Session > session( libcmis::SessionFactory::createSession( BINDING_BAD, SERVER_USERNAME, SERVER_PASSWORD, SERVER_REPOSITORY ) ); CPPUNIT_ASSERT_MESSAGE( "Session should be NULL", !session ); } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/Makefile.am����������������������������������������������������������������0000664�0001750�0001750�00000007053�13407647300�014153� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������if !OS_WIN32 mockup_tests = \ test-atom \ test-factory \ test-gdrive \ test-onedrive \ test-sharepoint \ test-ws endif check_PROGRAMS = \ test-json \ test-utils \ ${mockup_tests} check_LIBRARIES = \ libtest.a libtest_a_SOURCES = \ test-helpers.cxx \ test-helpers.hxx \ test-main.cxx if !OS_WIN32 libtest_a_SOURCES += \ test-mockup-helpers.cxx \ test-mockup-helpers.hxx endif libtest_a_CPPFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ -I$(top_srcdir)/qa/mockup \ $(XML2_CFLAGS) \ $(CURL_CFLAGS) \ $(BOOST_CPPFLAGS) test_utils_SOURCES = \ test-commons.cxx \ test-decoder.cxx \ test-soap.cxx \ test-xmlutils.cxx test_utils_CPPFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ $(XML2_CFLAGS) \ $(CURL_CFLAGS) \ $(BOOST_CPPFLAGS) test_utils_LDADD = \ libtest.a \ $(top_builddir)/src/libcmis/libcmis.la \ $(XML2_LIBS) \ $(CURL_LIBS) \ $(CPPUNIT_LIBS) \ $(BOOST_DATE_TIME_LIBS) test_atom_SOURCES = \ test-atom.cxx test_atom_CPPFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ -I$(top_srcdir)/qa/mockup \ $(XML2_CFLAGS) \ $(BOOST_CPPFLAGS) \ -DDATA_DIR=\"$(top_srcdir)/qa/libcmis/data\" test_atom_LDADD = \ libtest.a \ $(top_builddir)/qa/mockup/libcmis-mockup.la \ $(XML2_LIBS) \ $(CPPUNIT_LIBS) \ $(BOOST_DATE_TIME_LIBS) test_gdrive_SOURCES = \ test-gdrive.cxx test_gdrive_CPPFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ -I$(top_srcdir)/qa/mockup \ $(XML2_CFLAGS) \ $(BOOST_CPPFLAGS) \ -DDATA_DIR=\"$(top_srcdir)/qa/libcmis/data\" test_gdrive_LDADD = \ libtest.a \ $(top_builddir)/qa/mockup/libcmis-mockup.la \ $(XML2_LIBS) \ $(CPPUNIT_LIBS) \ $(BOOST_DATE_TIME_LIBS) test_onedrive_SOURCES = \ test-onedrive.cxx test_onedrive_CPPFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ -I$(top_srcdir)/qa/mockup \ $(XML2_CFLAGS) \ $(BOOST_CPPFLAGS) \ -DDATA_DIR=\"$(top_srcdir)/qa/libcmis/data\" test_onedrive_LDADD = \ libtest.a \ $(top_builddir)/qa/mockup/libcmis-mockup.la \ $(XML2_LIBS) \ $(CPPUNIT_LIBS) \ $(BOOST_DATE_TIME_LIBS) test_sharepoint_SOURCES = \ test-sharepoint.cxx test_sharepoint_CPPFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ -I$(top_srcdir)/qa/mockup \ $(XML2_CFLAGS) \ $(BOOST_CPPFLAGS) \ -DDATA_DIR=\"$(top_srcdir)/qa/libcmis/data\" test_sharepoint_LDADD = \ libtest.a \ $(top_builddir)/qa/mockup/libcmis-mockup.la \ $(XML2_LIBS) \ $(CPPUNIT_LIBS) \ $(BOOST_DATE_TIME_LIBS) test_ws_SOURCES = \ test-ws.cxx test_ws_CPPFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ -I$(top_srcdir)/qa/mockup \ $(XML2_CFLAGS) \ $(BOOST_CPPFLAGS) \ -DDATA_DIR=\"$(top_srcdir)/qa/libcmis/data\" test_ws_LDADD = \ libtest.a \ $(top_builddir)/qa/mockup/libcmis-mockup.la \ $(XML2_LIBS) \ $(CPPUNIT_LIBS) \ $(BOOST_DATE_TIME_LIBS) test_json_SOURCES = \ test-jsonutils.cxx test_json_CPPFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ $(XML2_CFLAGS) \ $(BOOST_CPPFLAGS) \ -DDATA_DIR=\"$(top_srcdir)/qa/libcmis/data\" test_json_LDADD = \ libtest.a \ $(top_builddir)/src/libcmis/libcmis.la \ $(XML2_LIBS) \ $(CPPUNIT_LIBS) \ $(CURL_LIBS) \ $(BOOST_DATE_TIME_LIBS) test_factory_SOURCES = \ test-factory.cxx test_factory_CPPFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis \ -I$(top_srcdir)/qa/mockup \ $(XML2_CFLAGS) \ $(BOOST_CPPFLAGS) \ -DDATA_DIR=\"$(top_srcdir)/qa/libcmis/data\" test_factory_LDADD = \ libtest.a \ $(top_builddir)/qa/mockup/libcmis-mockup.la \ $(XML2_LIBS) \ $(CPPUNIT_LIBS) \ $(BOOST_DATE_TIME_LIBS) TESTS = test-utils test-json ${mockup_tests} �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/test-helpers.cxx�����������������������������������������������������������0000664�0001750�0001750�00000014136�13407414352�015261� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <libxml/parser.h> #include <libxml/tree.h> #include <libcmis/xml-utils.hxx> #include "test-helpers.hxx" using namespace std; using libcmis::PropertyPtrMap; namespace test { XmlNodeRef::XmlNodeRef( xmlNodePtr node, boost::shared_ptr< xmlDoc > doc ) : m_node( node ) , m_doc( doc ) { } XmlNodeRef::XmlNodeRef( const XmlNodeRef& other ) : m_node( other.m_node ) , m_doc( other.m_doc ) { } XmlNodeRef& XmlNodeRef::operator=( const XmlNodeRef& other ) { m_node = other.m_node; m_doc = other.m_doc; return *this; } XmlNodeRef::operator xmlNodePtr( ) const { return m_node; } XmlNodeRef getXmlNode( string str ) { xmlNodePtr node = NULL; const boost::shared_ptr< xmlDoc > doc( xmlReadMemory( str.c_str( ), str.size( ), "tester", NULL, 0 ), xmlFreeDoc ); if ( bool( doc ) ) node = xmlDocGetRootElement( doc.get() ); return XmlNodeRef( node, doc ); } const char* getXmlns( ) { return "xmlns:cmis=\"http://docs.oasis-open.org/ns/cmis/core/200908/\" xmlns:cmisra=\"http://docs.oasis-open.org/ns/cmis/restatom/200908/\" "; } string writeXml( boost::shared_ptr< libcmis::XmlSerializable > serializable ) { xmlBufferPtr buf = xmlBufferCreate( ); xmlTextWriterPtr writer = xmlNewTextWriterMemory( buf, 0 ); xmlTextWriterStartDocument( writer, NULL, NULL, NULL ); serializable->toXml( writer ); xmlTextWriterEndDocument( writer ); string str( ( const char * )xmlBufferContent( buf ) ); xmlFreeTextWriter( writer ); xmlBufferFree( buf ); return str; } string getXmlNodeAsString( const string& xmlDoc, const string& xpath ) { string result; xmlDocPtr doc = xmlReadMemory( xmlDoc.c_str(), xmlDoc.size(), "", NULL, 0 ); if ( NULL != doc ) { xmlXPathContextPtr xpathCtx = xmlXPathNewContext( doc ); libcmis::registerNamespaces( xpathCtx ); libcmis::registerCmisWSNamespaces( xpathCtx ); if ( NULL != xpathCtx ) { xmlXPathObjectPtr xpathObj = xmlXPathEvalExpression( BAD_CAST( xpath.c_str() ), xpathCtx ); if ( xpathObj != NULL ) { int nbResults = 0; if ( xpathObj->nodesetval ) nbResults = xpathObj->nodesetval->nodeNr; for ( int i = 0; i < nbResults; ++i ) { xmlNodePtr node = xpathObj->nodesetval->nodeTab[i]; xmlBufferPtr buf = xmlBufferCreate( ); xmlNodeDump( buf, doc, node, 0, 0 ); result += string( ( char * )xmlBufferContent( buf ) ); xmlBufferFree( buf ); } } xmlXPathFreeObject( xpathObj); } xmlXPathFreeContext( xpathCtx ); } else throw libcmis::Exception( "Failed to parse service document" ); xmlFreeDoc( doc ); return result; } libcmis::DocumentPtr createVersionableDocument( libcmis::Session* session, string docName ) { libcmis::FolderPtr parent = session->getRootFolder( ); // Prepare the properties for the new object, object type is cmis:folder PropertyPtrMap props; libcmis::ObjectTypePtr type = session->getType( "VersionableType" ); map< string, libcmis::PropertyTypePtr > propTypes = type->getPropertiesTypes( ); // Set the object name map< string, libcmis::PropertyTypePtr >::iterator it = propTypes.find( string( "cmis:name" ) ); vector< string > nameValues; nameValues.push_back( docName ); libcmis::PropertyPtr nameProperty( new libcmis::Property( it->second, nameValues ) ); props.insert( pair< string, libcmis::PropertyPtr >( string( "cmis:name" ), nameProperty ) ); // set the object type it = propTypes.find( string( "cmis:objectTypeId" ) ); vector< string > typeValues; typeValues.push_back( "VersionableType" ); libcmis::PropertyPtr typeProperty( new libcmis::Property( it->second, typeValues ) ); props.insert( pair< string, libcmis::PropertyPtr >( string( "cmis:objectTypeId" ), typeProperty ) ); // Actually send the document creation request string contentStr = "Some content"; boost::shared_ptr< ostream > os ( new stringstream( contentStr ) ); string contentType = "text/plain"; string filename( "name.txt" ); return parent->createDocument( props, os, contentType, filename ); } void loadFromFile( const char* path, string& buf ) { ifstream in( path ); in.seekg( 0, ios::end ); int length = in.tellg( ); in.seekg( 0, ios::beg ); char* buffer = new char[length]; in.read( buffer, length ); in.close( ); buf = string( buffer, length ); delete[] buffer; } } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis/test-mockup-helpers.hxx����������������������������������������������������0000664�0001750�0001750�00000002272�13407173247�016565� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ namespace test { void addWsResponse( const char* url, const char* filename, const char* bodyMatch = 0 ); } ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/mockup/����������������������������������������������������������������������������0000775�0001750�0001750�00000000000�13411152400�012031� 5����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/mockup/Makefile.in�����������������������������������������������������������������0000664�0001750�0001750�00000050706�13407705041�014040� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������# Makefile.in generated by automake 1.16.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2018 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = qa/mockup ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \ $(top_srcdir)/m4/ax_cxx_compile_stdcxx_11.m4 \ $(top_srcdir)/m4/ax_gcc_func_attribute.m4 \ $(top_srcdir)/m4/boost.m4 $(top_srcdir)/m4/libtool.m4 \ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = LTLIBRARIES = $(noinst_LTLIBRARIES) @OS_WIN32_FALSE@libcmis_mockup_la_DEPENDENCIES = \ @OS_WIN32_FALSE@ $(top_builddir)/src/libcmis/libcmis.la am__libcmis_mockup_la_SOURCES_DIST = curl-mockup.cxx internals.hxx \ mockup-config.cxx mockup-config.h curl/curl.h @OS_WIN32_FALSE@am_libcmis_mockup_la_OBJECTS = curl-mockup.lo \ @OS_WIN32_FALSE@ mockup-config.lo libcmis_mockup_la_OBJECTS = $(am_libcmis_mockup_la_OBJECTS) AM_V_lt = $(am__v_lt_@AM_V@) am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) am__v_lt_0 = --silent am__v_lt_1 = libcmis_mockup_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX \ $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CXXLD) \ $(AM_CXXFLAGS) $(CXXFLAGS) $(libcmis_mockup_la_LDFLAGS) \ $(LDFLAGS) -o $@ @OS_WIN32_FALSE@am_libcmis_mockup_la_rpath = AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ depcomp = $(SHELL) $(top_srcdir)/depcomp am__maybe_remake_depfiles = depfiles am__depfiles_remade = ./$(DEPDIR)/curl-mockup.Plo \ ./$(DEPDIR)/mockup-config.Plo am__mv = mv -f CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ $(AM_CXXFLAGS) $(CXXFLAGS) AM_V_CXX = $(am__v_CXX_@AM_V@) am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@) am__v_CXX_0 = @echo " CXX " $@; am__v_CXX_1 = CXXLD = $(CXX) CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \ $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ AM_V_CXXLD = $(am__v_CXXLD_@AM_V@) am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@) am__v_CXXLD_0 = @echo " CXXLD " $@; am__v_CXXLD_1 = COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ $(AM_CFLAGS) $(CFLAGS) AM_V_CC = $(am__v_CC_@AM_V@) am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) am__v_CC_0 = @echo " CC " $@; am__v_CC_1 = CCLD = $(CC) LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(AM_LDFLAGS) $(LDFLAGS) -o $@ AM_V_CCLD = $(am__v_CCLD_@AM_V@) am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) am__v_CCLD_0 = @echo " CCLD " $@; am__v_CCLD_1 = SOURCES = $(libcmis_mockup_la_SOURCES) DIST_SOURCES = $(am__libcmis_mockup_la_SOURCES_DIST) am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is # *not* preserved. am__uniquify_input = $(AWK) '\ BEGIN { nonempty = 0; } \ { items[$$0] = 1; nonempty = 1; } \ END { if (nonempty) { for (i in items) print i; }; } \ ' # Make sure the list of sources is unique. This is necessary because, # e.g., the same source file might be shared among _SOURCES variables # for different programs/libraries. am__define_uniq_tagged_files = \ list='$(am__tagged_files)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ BOOST_CPPFLAGS = @BOOST_CPPFLAGS@ BOOST_DATE_TIME_LDFLAGS = @BOOST_DATE_TIME_LDFLAGS@ BOOST_DATE_TIME_LDPATH = @BOOST_DATE_TIME_LDPATH@ BOOST_DATE_TIME_LIBS = @BOOST_DATE_TIME_LIBS@ BOOST_LDPATH = @BOOST_LDPATH@ BOOST_PROGRAM_OPTIONS_LDFLAGS = @BOOST_PROGRAM_OPTIONS_LDFLAGS@ BOOST_PROGRAM_OPTIONS_LDPATH = @BOOST_PROGRAM_OPTIONS_LDPATH@ BOOST_PROGRAM_OPTIONS_LIBS = @BOOST_PROGRAM_OPTIONS_LIBS@ BOOST_ROOT = @BOOST_ROOT@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPCHECK = @CPPCHECK@ CPPCHECK_PARALLELISM = @CPPCHECK_PARALLELISM@ CPPFLAGS = @CPPFLAGS@ CPPUNIT_CFLAGS = @CPPUNIT_CFLAGS@ CPPUNIT_LIBS = @CPPUNIT_LIBS@ CURL_CFLAGS = @CURL_CFLAGS@ CURL_LIBS = @CURL_LIBS@ CXX = @CXX@ CXXCPP = @CXXCPP@ CXXDEPMODE = @CXXDEPMODE@ CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DISTCHECK_CONFIGURE_FLAGS = @DISTCHECK_CONFIGURE_FLAGS@ DLLTOOL = @DLLTOOL@ DOCBOOK2MAN = @DOCBOOK2MAN@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ GENHTML = @GENHTML@ GREP = @GREP@ HAVE_CXX11 = @HAVE_CXX11@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LCOV = @LCOV@ LD = @LD@ LDFLAGS = @LDFLAGS@ LIBCMIS_API_VERSION = @LIBCMIS_API_VERSION@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ NPROC = @NPROC@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SRCDIR = @SRCDIR@ STRIP = @STRIP@ VERSION = @VERSION@ XML2_CFLAGS = @XML2_CFLAGS@ XML2_LIBS = @XML2_LIBS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ @OS_WIN32_FALSE@noinst_LTLIBRARIES = libcmis-mockup.la @OS_WIN32_FALSE@libcmis_mockup_la_SOURCES = \ @OS_WIN32_FALSE@ curl-mockup.cxx \ @OS_WIN32_FALSE@ internals.hxx \ @OS_WIN32_FALSE@ mockup-config.cxx \ @OS_WIN32_FALSE@ mockup-config.h \ @OS_WIN32_FALSE@ curl/curl.h @OS_WIN32_FALSE@libcmis_mockup_la_LIBADD = \ @OS_WIN32_FALSE@ $(top_builddir)/src/libcmis/libcmis.la @OS_WIN32_FALSE@libcmis_mockup_la_LDFLAGS = -export-dynamic -no-undefined all: all-am .SUFFIXES: .SUFFIXES: .cxx .lo .o .obj $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign qa/mockup/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign qa/mockup/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): clean-noinstLTLIBRARIES: -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES) @list='$(noinst_LTLIBRARIES)'; \ locs=`for p in $$list; do echo $$p; done | \ sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \ sort -u`; \ test -z "$$locs" || { \ echo rm -f $${locs}; \ rm -f $${locs}; \ } libcmis-mockup.la: $(libcmis_mockup_la_OBJECTS) $(libcmis_mockup_la_DEPENDENCIES) $(EXTRA_libcmis_mockup_la_DEPENDENCIES) $(AM_V_CXXLD)$(libcmis_mockup_la_LINK) $(am_libcmis_mockup_la_rpath) $(libcmis_mockup_la_OBJECTS) $(libcmis_mockup_la_LIBADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/curl-mockup.Plo@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mockup-config.Plo@am__quote@ # am--include-marker $(am__depfiles_remade): @$(MKDIR_P) $(@D) @echo '# dummy' >$@-t && $(am__mv) $@-t $@ am--depfiles: $(am__depfiles_remade) .cxx.o: @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $< .cxx.obj: @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .cxx.lo: @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LTCXXCOMPILE) -c -o $@ $< mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique tags: tags-am TAGS: tags tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ if test $$# -gt 0; then \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ "$$@" $$unique; \ else \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$unique; \ fi; \ fi ctags: ctags-am CTAGS: ctags ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" cscopelist: cscopelist-am cscopelist-am: $(am__tagged_files) list='$(am__tagged_files)'; \ case "$(srcdir)" in \ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ *) sdir=$(subdir)/$(srcdir) ;; \ esac; \ for i in $$list; do \ if test -f "$$i"; then \ echo "$(subdir)/$$i"; \ else \ echo "$$sdir/$$i"; \ fi; \ done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(LTLIBRARIES) installdirs: install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic clean-libtool clean-noinstLTLIBRARIES \ mostlyclean-am distclean: distclean-am -rm -f ./$(DEPDIR)/curl-mockup.Plo -rm -f ./$(DEPDIR)/mockup-config.Plo -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-tags dvi: dvi-am dvi-am: html: html-am html-am: info: info-am info-am: install-data-am: install-dvi: install-dvi-am install-dvi-am: install-exec-am: install-html: install-html-am install-html-am: install-info: install-info-am install-info-am: install-man: install-pdf: install-pdf-am install-pdf-am: install-ps: install-ps-am install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am -rm -f ./$(DEPDIR)/curl-mockup.Plo -rm -f ./$(DEPDIR)/mockup-config.Plo -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: .MAKE: install-am install-strip .PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-am clean \ clean-generic clean-libtool clean-noinstLTLIBRARIES \ cscopelist-am ctags ctags-am distclean distclean-compile \ distclean-generic distclean-libtool distclean-tags distdir dvi \ dvi-am html html-am info info-am install install-am \ install-data install-data-am install-dvi install-dvi-am \ install-exec install-exec-am install-html install-html-am \ install-info install-info-am install-man install-pdf \ install-pdf-am install-ps install-ps-am install-strip \ installcheck installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ tags tags-am uninstall uninstall-am .PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: ����������������������������������������������������������libcmis-0.5.2/qa/mockup/mockup-config.cxx�����������������������������������������������������������0000664�0001750�0001750�00000031457�13407757661�015301� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "mockup-config.h" #include <memory> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <iostream> #include <boost/algorithm/string.hpp> #include "internals.hxx" using namespace std; namespace { void lcl_splitUrl( const string& url, string& urlBase, string& params ) { size_t pos = url.find( "?" ); urlBase = url; if ( pos != string::npos ) { urlBase = url.substr( 0, pos ); params = url.substr( pos + 1 ); } } const char** lcl_toStringArray( const vector< string >& vect ) { const char** array = new const char*[vect.size() + 1]; for ( size_t i = 0; i < vect.size( ); i++ ) array[i] = vect[i].c_str(); array[vect.size()] = NULL; return array; } } namespace mockup { Response::Response( string response, unsigned int status, bool isFilePath, string headers ) : m_response( response ), m_status( status ), m_isFilePath( isFilePath ), m_headers( headers ) { } Request::Request( string url, string method, string body, vector< string > headers ) : m_url( url ), m_method( method ), m_body( body ), m_headers( headers ) { } RequestMatcher::RequestMatcher( string baseUrl, string matchParam, string method, string matchBody ) : m_baseUrl( baseUrl ), m_matchParam( matchParam ), m_method( method ), m_matchBody( matchBody ) { } bool RequestMatcher::operator< ( const RequestMatcher& compare ) const { int cmpBaseUrl = m_baseUrl.compare( compare.m_baseUrl ) ; if ( cmpBaseUrl != 0 ) return cmpBaseUrl < 0; int cmpMatchParam = m_matchParam.compare( compare.m_matchParam ); if ( cmpMatchParam != 0 ) return cmpMatchParam < 0; int cmpMatchMethod = m_method.compare( compare.m_method ); if ( cmpMatchMethod != 0 ) return cmpMatchMethod < 0; int cmpMatchBody = m_matchBody.compare( compare.m_matchBody ); return cmpMatchBody < 0; } Configuration::Configuration( ) : m_responses( ), m_requests( ), m_username( ), m_password( ), m_badSSLCertificate( ) { } bool Configuration::hasCredentials( ) { return !m_username.empty( ) && !m_password.empty( ); } /** Find a suitable response * using the request as a search key */ CURLcode Configuration::writeResponse( CurlHandle* handle ) { CURLcode code = CURLE_OK; string headers; string response; bool foundResponse = false; bool isFilePath = true; const string& url = handle->m_url; string urlBase = url; string params; lcl_splitUrl( url, urlBase, params ); string method = handle->m_method; string body = m_requests.back().m_body; for ( map< RequestMatcher, Response >::iterator it = m_responses.begin( ); it != m_responses.end( ) && response.empty( ); ++it ) { RequestMatcher matcher = it->first; string& paramFind = matcher.m_matchParam; bool matchBaseUrl = matcher.m_baseUrl.empty() || ( urlBase == matcher.m_baseUrl ); bool matchParams = paramFind.empty( ) || ( params.find( paramFind ) != string::npos ); bool matchMethod = it->first.m_method.empty( ) || ( it->first.m_method == method ); bool matchBody = matcher.m_matchBody.empty( ) || ( body.find( matcher.m_matchBody ) != string::npos ); if ( matchBaseUrl && matchParams && matchMethod && matchBody ) { foundResponse = true; response = it->second.m_response; handle->m_httpError = it->second.m_status; isFilePath = it->second.m_isFilePath; headers = it->second.m_headers; } } // Output headers is any if ( !headers.empty() ) { char* buf = strdup( headers.c_str() ); handle->m_headersFn( buf, 1, headers.size( ), handle->m_headersData ); free( buf ); } // If nothing matched, then send a 404 HTTP error instead if ( !foundResponse || ( foundResponse && isFilePath && response.empty() ) ) handle->m_httpError = 404; else { if ( isFilePath ) { FILE* fd = fopen( response.c_str( ), "r" ); if ( !fd ) { cerr << "Missing test file: " << response << endl; handle->m_httpError = 500; return CURLE_HTTP_RETURNED_ERROR; } size_t bufSize = 2048; char* buf = new char[bufSize]; size_t read = 0; size_t written = 0; do { read = fread( buf, 1, bufSize, fd ); written = handle->m_writeFn( buf, 1, read, handle->m_writeData ); } while ( read == bufSize && written == read ); fclose( fd ); delete[] buf; } else { if ( !response.empty() ) { char* buf = strdup( response.c_str() ); handle->m_writeFn( buf, 1, response.size( ), handle->m_writeData ); free( buf ); } } } // What curl error code to give? if ( handle->m_httpError == 0 ) handle->m_httpError = 200; if ( handle->m_httpError < 200 || handle->m_httpError >= 300 ) code = CURLE_HTTP_RETURNED_ERROR; return code; } unique_ptr<Configuration> config{ new Configuration( ) }; } void curl_mockup_reset( ) { mockup::config.reset( new mockup::Configuration( ) ); } void curl_mockup_addResponse( const char* urlBase, const char* matchParam, const char* method, const char* response, unsigned int status, bool isFilePath, const char* headers, const char* matchBody ) { string matchBodyStr; if ( matchBody ) matchBodyStr = matchBody; mockup::RequestMatcher matcher( urlBase, matchParam, method, matchBodyStr ); map< mockup::RequestMatcher, mockup::Response >::iterator it = mockup::config->m_responses.find( matcher ); if ( it != mockup::config->m_responses.end( ) ) mockup::config->m_responses.erase( it ); string headersStr; if ( headers != NULL ) headersStr = headers; mockup::Response responseDesc( response, status, isFilePath, headersStr ); mockup::config->m_responses.insert( pair< mockup::RequestMatcher, mockup::Response >( matcher, responseDesc ) ); } void curl_mockup_setResponse( const char* filepath ) { mockup::config->m_responses.clear( ); curl_mockup_addResponse( "", "", "", filepath ); } void curl_mockup_setCredentials( const char* username, const char* password ) { mockup::config->m_username = string( username ); mockup::config->m_password = string( password ); } const struct HttpRequest* curl_mockup_getRequest( const char* urlBase, const char* matchParam, const char* method, const char* matchBody ) { struct HttpRequest* request = NULL; string urlBaseString( urlBase ); string matchParamString( matchParam ); string matchBodyStr; if ( matchBody ) matchBodyStr = matchBody; for ( vector< mockup::Request >::iterator it = mockup::config->m_requests.begin( ); it != mockup::config->m_requests.end( ) && request == NULL; ++it ) { string url; string params; if ( it->m_method == string( method ) ) { lcl_splitUrl( it->m_url, url, params ); bool matchBaseUrl = urlBaseString.empty() || boost::starts_with( url, urlBaseString ); bool matchParams = matchParamString.empty( ) || ( params.find( matchParamString ) != string::npos ); bool matchBodyPart = !matchBody || ( it->m_body.find( matchBodyStr ) != string::npos ); if ( matchBaseUrl && matchParams && matchBodyPart ) { request = new HttpRequest; request->url = it->m_url.c_str(); request->body = it->m_body.c_str(); request->headers = lcl_toStringArray( it->m_headers ); } } } return request; } const char* curl_mockup_getRequestBody( const char* urlBase, const char* matchParam, const char* method, const char* matchBody ) { const struct HttpRequest* request = curl_mockup_getRequest( urlBase, matchParam, method, matchBody ); if ( request ) { const char* body = request->body; curl_mockup_HttpRequest_free( request ); return body; } return NULL; } int curl_mockup_getRequestsCount( const char* urlBase, const char* matchParam, const char* method, const char* matchBody ) { int count = 0; string urlBaseString( urlBase ); string matchParamString( matchParam ); string matchBodyStr( matchBody ); for ( vector< mockup::Request >::iterator it = mockup::config->m_requests.begin( ); it != mockup::config->m_requests.end( ); ++it ) { string url; string params; if ( it->m_method == string( method ) ) { lcl_splitUrl( it->m_url, url, params ); bool matchBaseUrl = urlBaseString.empty() || boost::starts_with( url, urlBaseString ); bool matchParams = matchParamString.empty( ) || ( params.find( matchParamString ) != string::npos ); bool matchBodyPart = matchBodyStr.empty() || ( it->m_body.find( matchBodyStr ) != string::npos ); if ( matchBaseUrl && matchParams && matchBodyPart ) { count++; } } } return count; } void curl_mockup_HttpRequest_free( const struct HttpRequest* request ) { delete[] request->headers; delete request; } char* curl_mockup_HttpRequest_getHeader( const struct HttpRequest* request, const char* name ) { char* value = NULL; size_t i = 0; while ( request->headers[i] != NULL && value == NULL ) { string header = request->headers[i]; const string prefix = string( name ) + ":"; size_t pos = header.find( prefix ); if ( pos == 0 ) { value = strdup( header.substr( prefix.size() ).c_str() ); } ++i; } return value; } const char* curl_mockup_getProxy( CURL* curl ) { CurlHandle* handle = static_cast< CurlHandle* >( curl ); if ( NULL != handle ) return handle->m_proxy.c_str(); return NULL; } const char* curl_mockup_getNoProxy( CURL* curl ) { CurlHandle* handle = static_cast< CurlHandle* >( curl ); if ( NULL != handle ) return handle->m_noProxy.c_str(); return NULL; } const char* curl_mockup_getProxyUser( CURL* curl ) { CurlHandle* handle = static_cast< CurlHandle* >( curl ); if ( NULL != handle ) return handle->m_proxyUser.c_str(); return NULL; } const char* curl_mockup_getProxyPass( CURL* curl ) { CurlHandle* handle = static_cast< CurlHandle* >( curl ); if ( NULL != handle ) return handle->m_proxyPass.c_str(); return NULL; } void curl_mockup_setSSLBadCertificate( const char* certificate ) { mockup::config->m_badSSLCertificate = string( certificate ); } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/mockup/curl-mockup.cxx�������������������������������������������������������������0000664�0001750�0001750�00000031570�13407757661�014775� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <stdarg.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <sstream> #include "curl/curl.h" #include "internals.hxx" using namespace std; namespace mockup { extern Configuration* config; } /** Code mostly coming from curl */ struct curl_slist *curl_slist_append( struct curl_slist * list, const char * data ) { struct curl_slist* new_item = ( struct curl_slist* ) malloc( sizeof( struct curl_slist ) ); if( new_item ) { char *dupdata = strdup(data); if ( dupdata ) { new_item->next = NULL; new_item->data = dupdata; } else { free(new_item); return NULL; } } else return NULL; if ( list ) { curl_slist* last = list; while ( last->next ) last = last->next; last->next = new_item; return list; } /* if this is the first item, then new_item *is* the list */ return new_item; } void curl_slist_free_all( struct curl_slist * list ) { if ( list ) { struct curl_slist* item = list; struct curl_slist* next = NULL; do { next = item->next; if ( item->data ) free( item->data ); free(item); item = next; } while ( next ); } } void curl_free( void * p ) { free( p ); } CURLcode curl_global_init( long ) { return CURLE_OK; } CURL *curl_easy_init( void ) { return new CurlHandle(); } void curl_easy_cleanup( CURL * curl ) { CurlHandle* handle = static_cast< CurlHandle* >( curl ); delete( handle ); } void curl_easy_reset( CURL * curl ) { CurlHandle* handle = static_cast< CurlHandle * >( curl ); handle->reset( ); } char *curl_easy_escape( CURL *, const char *string, int length ) { return strndup( string, length ); } char *curl_unescape( const char *string, int length ) { return strndup( string, length ); } char *curl_easy_unescape( CURL *, const char *string, int length, int * ) { return curl_unescape( string, length ); } CURLcode curl_easy_setopt( CURL * curl, long option, ... ) { CurlHandle* handle = static_cast< CurlHandle * >( curl ); va_list arg; va_start( arg, option ); switch ( option ) { /* TODO Add support for more options */ case CURLOPT_POST: { if ( va_arg( arg, long ) ) handle->m_method = string( "POST" ); break; } case CURLOPT_UPLOAD: { if ( 0 != va_arg( arg, long ) ) handle->m_method = string( "PUT" ); break; } case CURLOPT_CUSTOMREQUEST: handle->m_method = string( va_arg( arg, char* ) ); break; case CURLOPT_URL: { handle->m_url = string( va_arg( arg, char* ) ); break; } case CURLOPT_WRITEFUNCTION: { handle->m_writeFn = va_arg( arg, write_callback ); break; } case CURLOPT_WRITEDATA: { handle->m_writeData = va_arg( arg, void* ); break; } case CURLOPT_READFUNCTION: { handle->m_readFn = va_arg( arg, read_callback ); break; } case CURLOPT_READDATA: { handle->m_readData = va_arg( arg, void* ); break; } case CURLOPT_INFILESIZE: { handle->m_readSize = va_arg( arg, long ); break; } case CURLOPT_HEADERFUNCTION: { handle->m_headersFn = va_arg( arg, headers_callback ); break; } case CURLOPT_WRITEHEADER: { handle->m_headersData = va_arg( arg, void* ); break; } case CURLOPT_USERNAME: { handle->m_username = string( va_arg( arg, char* ) ); break; } case CURLOPT_PASSWORD: { handle->m_password = string( va_arg( arg, char* ) ); break; } case CURLOPT_USERPWD: { string userpwd( va_arg( arg, char* ) ); size_t pos = userpwd.find( ':' ); if ( pos != string::npos ) { handle->m_username = userpwd.substr( 0, pos ); handle->m_password = userpwd.substr( pos + 1 ); } break; } case CURLOPT_PROXY: { // FIXME curl does some more complex things with port and type handle->m_proxy = string( va_arg( arg, char* ) ); break; } case CURLOPT_NOPROXY: { handle->m_noProxy = string( va_arg( arg, char* ) ); break; } case CURLOPT_PROXYUSERNAME: { handle->m_proxyUser = string( va_arg( arg, char* ) ); break; } case CURLOPT_PROXYPASSWORD: { handle->m_proxyPass = string( va_arg( arg, char* ) ); break; } case CURLOPT_PROXYUSERPWD: { string userpwd( va_arg( arg, char* ) ); size_t pos = userpwd.find( ':' ); if ( pos != string::npos ) { handle->m_proxyUser = userpwd.substr( 0, pos ); handle->m_proxyPass = userpwd.substr( pos + 1 ); } break; } case CURLOPT_SSL_VERIFYHOST: { handle->m_verifyHost = va_arg( arg, long ) != 0; break; } case CURLOPT_SSL_VERIFYPEER: { handle->m_verifyPeer = va_arg( arg, long ) != 0; break; } case CURLOPT_CERTINFO: { handle->m_certInfo = va_arg( arg, long ); break; } case CURLOPT_HTTPHEADER: { handle->m_headers.clear(); struct curl_slist* headers = va_arg( arg, struct curl_slist* ); while ( headers != NULL ) { handle->m_headers.push_back( string( headers->data ) ); headers = headers->next; } break; } default: { // We surely don't want to break the test for that. } } va_end( arg ); return CURLE_OK; } CURLcode curl_easy_perform( CURL * curl ) { CurlHandle* handle = static_cast< CurlHandle * >( curl ); /* Fake a bad SSL Certificate? */ if ( !mockup::config->m_badSSLCertificate.empty( ) && handle->m_verifyPeer && handle->m_verifyHost ) { return CURLE_SSL_CACERT; } /* Populate the certificate infos */ if ( handle->m_certInfo && !mockup::config->m_badSSLCertificate.empty( ) ) { curl_slist * certData = NULL; string cert( "Cert:" + mockup::config->m_badSSLCertificate ); char* c_cert = strdup( cert.c_str( ) ); certData = curl_slist_append( certData, c_cert ); free( c_cert ); handle->m_certs.num_of_certs = 1; handle->m_certs.certinfo = ( struct curl_slist** )calloc( ( size_t )1, sizeof( struct curl_slist * ) ); handle->m_certs.certinfo[0] = certData; } /* Check the credentials */ if ( mockup::config->hasCredentials( ) && ( handle->m_username != mockup::config->m_username || handle->m_password != mockup::config->m_password ) ) { // Send HTTP 401 handle->m_httpError = 401; return CURLE_HTTP_RETURNED_ERROR; } // Store the requests for later verifications stringstream body; if ( handle->m_readFn && handle->m_readData ) { size_t bufSize = 2048; char* buf = new char[bufSize]; size_t read = 0; do { read = handle->m_readFn( buf, 1, bufSize, handle->m_readData ); body.write( buf, read ); } while ( read == bufSize ); delete[] buf; } mockup::config->m_requests.push_back( mockup::Request( handle->m_url, handle->m_method, body.str( ), handle->m_headers ) ); return mockup::config->writeResponse( handle ); } CURLcode curl_easy_getinfo( CURL * curl, long info, ... ) { CurlHandle* handle = static_cast< CurlHandle * >( curl ); va_list arg; va_start( arg, info ); switch ( info ) { case CURLINFO_RESPONSE_CODE: { long* buf = va_arg( arg, long* ); *buf = handle->m_httpError; break; } case CURLINFO_CERTINFO: { struct curl_slist** param = va_arg( arg, struct curl_slist** ); if ( NULL != param ) { union { struct curl_certinfo * to_certinfo; struct curl_slist * to_slist; } ptr; // Fill it ptr.to_certinfo = &handle->m_certs; *param = ptr.to_slist; } break; } default: { // We surely don't want to break the test for that. } } va_end( arg ); return CURLE_OK; } CurlHandle::CurlHandle( ) : m_url( ), m_writeFn( NULL ), m_writeData( NULL ), m_readFn( NULL ), m_readData( NULL ), m_readSize( 0 ), m_headersFn( NULL ), m_headersData( NULL ), m_username( ), m_password( ), m_proxy( ), m_noProxy( ), m_proxyUser( ), m_proxyPass( ), m_verifyHost( true ), m_verifyPeer( true ), m_certInfo( false ), m_certs( ), m_httpError( 0 ), m_method( "GET" ), m_headers( ) { } CurlHandle::CurlHandle( const CurlHandle& copy ) : m_url( copy.m_url ), m_writeFn( copy.m_writeFn ), m_writeData( copy.m_writeData ), m_readFn( copy.m_readFn ), m_readData( copy.m_readData ), m_readSize( copy.m_readSize ), m_headersFn( copy.m_headersFn ), m_headersData( copy.m_headersData ), m_username( copy.m_username ), m_password( copy.m_password ), m_proxy( copy.m_proxy ), m_noProxy( copy.m_noProxy ), m_proxyUser( copy.m_proxyUser ), m_proxyPass( copy.m_proxyPass ), m_verifyHost( copy.m_verifyHost ), m_verifyPeer( copy.m_verifyPeer ), m_certInfo( copy.m_certInfo ), m_certs( copy.m_certs ), m_httpError( copy.m_httpError ), m_method( copy.m_method ), m_headers( copy.m_headers ) { } CurlHandle& CurlHandle::operator=( const CurlHandle& copy ) { if ( this != © ) { m_url = copy.m_url; m_writeFn = copy.m_writeFn; m_writeData = copy.m_writeData; m_readFn = copy.m_readFn; m_readData = copy.m_readData; m_readSize = copy.m_readSize; m_headersFn = copy.m_headersFn; m_headersData = copy.m_headersData; m_username = copy.m_username; m_password = copy.m_password; m_proxy = copy.m_proxy; m_noProxy = copy.m_noProxy; m_proxyUser = copy.m_proxyUser; m_proxyPass = copy.m_proxyPass; m_verifyHost = copy.m_verifyHost; m_verifyPeer = copy.m_verifyPeer; m_certInfo = copy.m_certInfo; m_certs = copy.m_certs; m_httpError = copy.m_httpError; m_method = copy.m_method; m_headers = copy.m_headers; } return *this; } CurlHandle::~CurlHandle( ) { reset(); } void CurlHandle::reset( ) { m_url = string( ); m_writeFn = NULL; m_writeData = NULL; m_readFn = NULL; m_readData = NULL; m_readSize = 0; m_username = string( ); m_password = string( ); m_proxy = string( ); m_noProxy = string( ); m_proxyUser = string( ); m_proxyPass = string( ); m_verifyHost = true; m_verifyPeer = true; m_certInfo = false; for ( int i = 0; i < m_certs.num_of_certs; ++i ) { curl_slist_free_all( m_certs.certinfo[i] ); m_certs.certinfo[i] = NULL; } free( m_certs.certinfo ); m_certs.certinfo = NULL; m_certs.num_of_certs = 0; m_method = "GET"; m_headers.clear( ); } ����������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/mockup/curl/�����������������������������������������������������������������������0000775�0001750�0001750�00000000000�13411152400�012776� 5����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/mockup/curl/curl.h�����������������������������������������������������������������0000664�0001750�0001750�00000011617�13407173247�014063� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _MOCKUP_CURL_CURL_H_ #define _MOCKUP_CURL_CURL_H_ #ifdef __cplusplus extern "C" { #endif /* Curl used symbols to mockup */ typedef void CURL; typedef enum { CURLIOE_OK, /* I/O operation successful */ CURLIOE_UNKNOWNCMD, /* command was unknown to callback */ CURLIOE_FAILRESTART, /* failed to restart the read */ CURLIOE_LAST /* never use */ } curlioerr; #define CURL_GLOBAL_SSL (1<<0) #define CURL_GLOBAL_WIN32 (1<<1) #define CURL_GLOBAL_ALL (CURL_GLOBAL_SSL|CURL_GLOBAL_WIN32) #define CURLOPTTYPE_LONG 0 #define CURLOPTTYPE_OBJECTPOINT 10000 #define CURLOPTTYPE_FUNCTIONPOINT 20000 #define CURLOPTTYPE_OFF_T 30000 typedef enum { CURLOPT_WRITEFUNCTION = CURLOPTTYPE_FUNCTIONPOINT + 11, CURLOPT_READFUNCTION = CURLOPTTYPE_FUNCTIONPOINT + 12, CURLOPT_WRITEDATA = CURLOPTTYPE_OBJECTPOINT + 1, CURLOPT_HEADERFUNCTION = CURLOPTTYPE_FUNCTIONPOINT + 79, CURLOPT_WRITEHEADER = CURLOPTTYPE_OBJECTPOINT + 29, CURLOPT_FOLLOWLOCATION = CURLOPTTYPE_LONG + 52, CURLOPT_MAXREDIRS = CURLOPTTYPE_LONG + 68, CURLOPT_INFILESIZE = CURLOPTTYPE_LONG + 14, CURLOPT_READDATA = CURLOPTTYPE_OBJECTPOINT + 9, CURLOPT_UPLOAD = CURLOPTTYPE_LONG + 46, CURLOPT_IOCTLFUNCTION = CURLOPTTYPE_FUNCTIONPOINT + 130, CURLOPT_IOCTLDATA = CURLOPTTYPE_OBJECTPOINT + 131, CURLOPT_HTTPHEADER = CURLOPTTYPE_OBJECTPOINT + 23, CURLOPT_POSTFIELDSIZE = CURLOPTTYPE_LONG + 60, CURLOPT_POST = CURLOPTTYPE_LONG + 47, CURLOPT_CUSTOMREQUEST = CURLOPTTYPE_OBJECTPOINT + 36, CURLOPT_URL = CURLOPTTYPE_OBJECTPOINT + 2, CURLOPT_HTTPAUTH = CURLOPTTYPE_LONG + 107, CURLOPT_USERNAME = CURLOPTTYPE_OBJECTPOINT + 173, CURLOPT_PASSWORD = CURLOPTTYPE_OBJECTPOINT + 174, CURLOPT_USERPWD = CURLOPTTYPE_OBJECTPOINT + 5, CURLOPT_ERRORBUFFER = CURLOPTTYPE_OBJECTPOINT + 10, CURLOPT_FAILONERROR = CURLOPTTYPE_LONG + 45, CURLOPT_VERBOSE = CURLOPTTYPE_LONG + 41, CURLOPT_PROXY = CURLOPTTYPE_OBJECTPOINT + 4, CURLOPT_PROXYUSERPWD = CURLOPTTYPE_OBJECTPOINT + 6, CURLOPT_PROXYAUTH = CURLOPTTYPE_LONG + 111, CURLOPT_PROXYUSERNAME = CURLOPTTYPE_OBJECTPOINT + 175, CURLOPT_PROXYPASSWORD = CURLOPTTYPE_OBJECTPOINT + 176, CURLOPT_NOPROXY = CURLOPTTYPE_OBJECTPOINT + 177, CURLOPT_SSL_VERIFYPEER = CURLOPTTYPE_LONG + 64, CURLOPT_SSL_VERIFYHOST = CURLOPTTYPE_LONG + 81, CURLOPT_CERTINFO = CURLOPTTYPE_LONG + 172 } CURLoption; #define CURLAUTH_DIGEST_IE (((unsigned long)1)<<4) #define CURLAUTH_ANY (~CURLAUTH_DIGEST_IE) typedef enum { CURLE_OK = 0, CURLE_HTTP_RETURNED_ERROR = 22, CURLE_SSL_CACERT = 60, /* TODO Add some more error codes from curl? */ CURL_LAST } CURLcode; struct curl_slist { char *data; struct curl_slist *next; }; struct curl_slist *curl_slist_append( struct curl_slist *, const char * ); void curl_slist_free_all( struct curl_slist * ); void curl_free( void *p ); CURLcode curl_global_init( long flags ); CURL *curl_easy_init( void ); void curl_easy_cleanup( CURL *curl ); CURLcode curl_easy_setopt( CURL *curl, long option, ... ); char *curl_easy_escape( CURL *handle, const char *string, int length ); char *curl_unescape( const char *string, int length ); char *curl_easy_unescape( CURL *handle, const char *string, int length, int *outlength ); CURLcode curl_easy_perform( CURL *curl ); void curl_easy_reset( CURL *curl ); struct curl_certinfo { int num_of_certs; struct curl_slist **certinfo; }; #define CURLINFO_LONG 0x200000 #define CURLINFO_SLIST 0x400000 typedef enum { CURLINFO_NONE, CURLINFO_RESPONSE_CODE = CURLINFO_LONG + 2, CURLINFO_CERTINFO = CURLINFO_SLIST + 34, CURLINFO_LASTONE = 42 } CURLINFO; CURLcode curl_easy_getinfo( CURL *curl, long info, ... ); #define LIBCURL_VERSION_MAJOR 7 #define LIBCURL_VERSION_MINOR 26 #define LIBCURL_VERSION_PATCH 0 #ifdef __cplusplus } #endif #endif �����������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/mockup/Makefile.am�����������������������������������������������������������������0000664�0001750�0001750�00000000463�13407173247�014031� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������if !OS_WIN32 noinst_LTLIBRARIES = libcmis-mockup.la libcmis_mockup_la_SOURCES = \ curl-mockup.cxx \ internals.hxx \ mockup-config.cxx \ mockup-config.h \ curl/curl.h libcmis_mockup_la_LIBADD = \ $(top_builddir)/src/libcmis/libcmis.la libcmis_mockup_la_LDFLAGS = -export-dynamic -no-undefined endif �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/mockup/internals.hxx���������������������������������������������������������������0000664�0001750�0001750�00000007250�13407173247�014526� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <map> #include <string> #include <vector> typedef size_t ( *write_callback )( char *ptr, size_t size, size_t nmemb, void *userdata ); typedef size_t ( *read_callback )( char *ptr, size_t size, size_t nmemb, void *userdata ); typedef size_t ( *headers_callback )( char *ptr, size_t size, size_t nmemb, void *userdata ); class CurlHandle { public: CurlHandle( ); CurlHandle( const CurlHandle& copy ); CurlHandle& operator=( const CurlHandle& copy ); ~CurlHandle( ); std::string m_url; write_callback m_writeFn; void* m_writeData; read_callback m_readFn; void* m_readData; long m_readSize; headers_callback m_headersFn; void* m_headersData; std::string m_username; std::string m_password; std::string m_proxy; std::string m_noProxy; std::string m_proxyUser; std::string m_proxyPass; bool m_verifyHost; bool m_verifyPeer; bool m_certInfo; struct curl_certinfo m_certs; long m_httpError; std::string m_method; std::vector< std::string > m_headers; void reset( ); }; namespace mockup { class Response { public: Response( std::string response, unsigned int status, bool isFilePath, std::string headers ); std::string m_response; unsigned int m_status; bool m_isFilePath; std::string m_headers; }; class Request { public: Request( std::string url, std::string method, std::string body, std::vector< std::string > headers ); std::string m_url; std::string m_method; std::string m_body; std::vector< std::string > m_headers; }; class RequestMatcher { public: RequestMatcher( std::string baseUrl, std::string matchParam, std::string method, std::string matchBody ); bool operator< ( const RequestMatcher& compare ) const; std::string m_baseUrl; std::string m_matchParam; std::string m_method; std::string m_matchBody; }; class Configuration { public: Configuration( ); bool hasCredentials( ); CURLcode writeResponse( CurlHandle* handle ); std::map< RequestMatcher, Response > m_responses; std::vector< Request > m_requests; std::string m_username; std::string m_password; std::string m_badSSLCertificate; }; } ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/mockup/mockup-config.h�������������������������������������������������������������0000664�0001750�0001750�00000010540�13407173247�014704� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <curl/curl.h> #ifdef __cplusplus extern "C" { #endif /* Mockup behavior configuration functions */ void curl_mockup_reset( ); /** Add a new HTTP response the server should send. \param baseURL the base URL of the request without parameters \param matchParam a string to find in the parameters part of the URL to match \param method HTTP method to match like PUT, GET, POST or DELETE. An empty string matches any method. \param response a string corresponding either to the file path of the request body to send or directly the content to send. This value has a different meaning depending on isFilePath parameter. \param status the HTTP status to return. 0 means HTTP OK (200). \param isFilePath if this value is true the response value is used as a file path, otherwise, the response value is used as the body of the HTTP response to send. \param headers the HTTP headers block to send with the response. By default no header is sent. \param matchBody a string to find in the request body to match */ void curl_mockup_addResponse( const char* baseUrl, const char* matchParam, const char* method, const char* response, unsigned int status = 0, bool isFilePath = true, const char* headers = 0, const char* matchBody = 0 ); /** Set the HTTP response the server is supposed to send. This will reset all already defined responses. */ void curl_mockup_setResponse( const char* filepath ); void curl_mockup_setCredentials( const char* username, const char* password ); struct HttpRequest { const char* url; const char* body; ///< NULL terminated array of headers. const char** headers; }; const struct HttpRequest* curl_mockup_getRequest( const char* baseUrl, const char* matchParam, const char* method, const char* matchBody = 0 ); const char* curl_mockup_getRequestBody( const char* baseUrl, const char* matchParam, const char* method, const char* matchBody = 0 ); int curl_mockup_getRequestsCount( const char* urlBase, const char* matchParam, const char* method, const char* matchBody = "" ); void curl_mockup_HttpRequest_free( const struct HttpRequest* request ); /** The resulting value is either NULL (no such header found) or the value of the header. In such a case, the result needs to be freed by the caller. */ char* curl_mockup_HttpRequest_getHeader( const struct HttpRequest* request, const char* name ); const char* curl_mockup_getProxy( CURL* handle ); const char* curl_mockup_getNoProxy( CURL* handle ); const char* curl_mockup_getProxyUser( CURL* handle ); const char* curl_mockup_getProxyPass( CURL* handle ); /** Set a fake invalid certificate to raise CURLE_SSL_CACERT. Setting it to an empty string will reset to no certificate. */ void curl_mockup_setSSLBadCertificate( const char* certificate ); #ifdef __cplusplus } #endif ����������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis-c/�������������������������������������������������������������������������0000775�0001750�0001750�00000000000�13411152402�012377� 5����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis-c/Makefile.in��������������������������������������������������������������0000664�0001750�0001750�00000176326�13407705041�014413� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������# Makefile.in generated by automake 1.16.1 from Makefile.am. # @configure_input@ # Copyright (C) 1994-2018 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ am__is_gnu_make = { \ if test -z '$(MAKELEVEL)'; then \ false; \ elif test -n '$(MAKE_HOST)'; then \ true; \ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \ true; \ else \ false; \ fi; \ } am__make_running_with_option = \ case $${target_option-} in \ ?) ;; \ *) echo "am__make_running_with_option: internal error: invalid" \ "target option '$${target_option-}' specified" >&2; \ exit 1;; \ esac; \ has_opt=no; \ sane_makeflags=$$MAKEFLAGS; \ if $(am__is_gnu_make); then \ sane_makeflags=$$MFLAGS; \ else \ case $$MAKEFLAGS in \ *\\[\ \ ]*) \ bs=\\; \ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \ esac; \ fi; \ skip_next=no; \ strip_trailopt () \ { \ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \ }; \ for flg in $$sane_makeflags; do \ test $$skip_next = yes && { skip_next=no; continue; }; \ case $$flg in \ *=*|--*) continue;; \ -*I) strip_trailopt 'I'; skip_next=yes;; \ -*I?*) strip_trailopt 'I';; \ -*O) strip_trailopt 'O'; skip_next=yes;; \ -*O?*) strip_trailopt 'O';; \ -*l) strip_trailopt 'l'; skip_next=yes;; \ -*l?*) strip_trailopt 'l';; \ -[dEDm]) skip_next=yes;; \ -[JT]) skip_next=yes;; \ esac; \ case $$flg in \ *$$target_option*) has_opt=yes; break;; \ esac; \ done; \ test $$has_opt = yes am__make_dryrun = (target_option=n; $(am__make_running_with_option)) am__make_keepgoing = (target_option=k; $(am__make_running_with_option)) pkgdatadir = $(datadir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkglibexecdir = $(libexecdir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ check_PROGRAMS = test-api$(EXEEXT) test-c-build$(EXEEXT) TESTS = test-api$(EXEEXT) subdir = qa/libcmis-c ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/m4/ax_cxx_compile_stdcxx.m4 \ $(top_srcdir)/m4/ax_cxx_compile_stdcxx_11.m4 \ $(top_srcdir)/m4/ax_gcc_func_attribute.m4 \ $(top_srcdir)/m4/boost.m4 $(top_srcdir)/m4/libtool.m4 \ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) DIST_COMMON = $(srcdir)/Makefile.am $(am__DIST_COMMON) mkinstalldirs = $(install_sh) -d CONFIG_CLEAN_FILES = CONFIG_CLEAN_VPATH_FILES = am_test_api_OBJECTS = test_api-test-allowable-actions.$(OBJEXT) \ test_api-test-api.$(OBJEXT) test_api-test-document.$(OBJEXT) \ test_api-test-dummies.$(OBJEXT) test_api-test-folder.$(OBJEXT) \ test_api-test-object-type.$(OBJEXT) \ test_api-test-object.$(OBJEXT) \ test_api-test-property-type.$(OBJEXT) \ test_api-test-property.$(OBJEXT) \ test_api-test-repository.$(OBJEXT) \ test_api-test-session.$(OBJEXT) test_api_OBJECTS = $(am_test_api_OBJECTS) am__DEPENDENCIES_1 = test_api_DEPENDENCIES = $(top_builddir)/src/libcmis-c/libcmis-c-@LIBCMIS_API_VERSION@.la \ $(top_builddir)/src/libcmis/libcmis-@LIBCMIS_API_VERSION@.la \ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) AM_V_lt = $(am__v_lt_@AM_V@) am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@) am__v_lt_0 = --silent am__v_lt_1 = test_api_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(test_api_CXXFLAGS) \ $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ am_test_c_build_OBJECTS = test_c_build-test-build.$(OBJEXT) test_c_build_OBJECTS = $(am_test_c_build_OBJECTS) test_c_build_DEPENDENCIES = $(top_builddir)/src/libcmis-c/libcmis-c-@LIBCMIS_API_VERSION@.la \ $(top_builddir)/src/libcmis/libcmis-@LIBCMIS_API_VERSION@.la \ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) \ $(am__DEPENDENCIES_1) $(am__DEPENDENCIES_1) test_c_build_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(test_c_build_CFLAGS) \ $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) am__v_P_0 = false am__v_P_1 = : AM_V_GEN = $(am__v_GEN_@AM_V@) am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@) am__v_GEN_0 = @echo " GEN " $@; am__v_GEN_1 = AM_V_at = $(am__v_at_@AM_V@) am__v_at_ = $(am__v_at_@AM_DEFAULT_V@) am__v_at_0 = @ am__v_at_1 = DEFAULT_INCLUDES = -I.@am__isrc@ depcomp = $(SHELL) $(top_srcdir)/depcomp am__maybe_remake_depfiles = depfiles am__depfiles_remade = ./$(DEPDIR)/test_api-test-allowable-actions.Po \ ./$(DEPDIR)/test_api-test-api.Po \ ./$(DEPDIR)/test_api-test-document.Po \ ./$(DEPDIR)/test_api-test-dummies.Po \ ./$(DEPDIR)/test_api-test-folder.Po \ ./$(DEPDIR)/test_api-test-object-type.Po \ ./$(DEPDIR)/test_api-test-object.Po \ ./$(DEPDIR)/test_api-test-property-type.Po \ ./$(DEPDIR)/test_api-test-property.Po \ ./$(DEPDIR)/test_api-test-repository.Po \ ./$(DEPDIR)/test_api-test-session.Po \ ./$(DEPDIR)/test_c_build-test-build.Po am__mv = mv -f COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ $(AM_CFLAGS) $(CFLAGS) AM_V_CC = $(am__v_CC_@AM_V@) am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@) am__v_CC_0 = @echo " CC " $@; am__v_CC_1 = CCLD = $(CC) LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(AM_LDFLAGS) $(LDFLAGS) -o $@ AM_V_CCLD = $(am__v_CCLD_@AM_V@) am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@) am__v_CCLD_0 = @echo " CCLD " $@; am__v_CCLD_1 = CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) LTCXXCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=compile $(CXX) $(DEFS) \ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ $(AM_CXXFLAGS) $(CXXFLAGS) AM_V_CXX = $(am__v_CXX_@AM_V@) am__v_CXX_ = $(am__v_CXX_@AM_DEFAULT_V@) am__v_CXX_0 = @echo " CXX " $@; am__v_CXX_1 = CXXLD = $(CXX) CXXLINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX $(AM_LIBTOOLFLAGS) \ $(LIBTOOLFLAGS) --mode=link $(CXXLD) $(AM_CXXFLAGS) \ $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ AM_V_CXXLD = $(am__v_CXXLD_@AM_V@) am__v_CXXLD_ = $(am__v_CXXLD_@AM_DEFAULT_V@) am__v_CXXLD_0 = @echo " CXXLD " $@; am__v_CXXLD_1 = SOURCES = $(test_api_SOURCES) $(test_c_build_SOURCES) DIST_SOURCES = $(test_api_SOURCES) $(test_c_build_SOURCES) am__can_run_installinfo = \ case $$AM_UPDATE_INFO_DIR in \ n|no|NO) false;; \ *) (install-info --version) >/dev/null 2>&1;; \ esac am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP) # Read a list of newline-separated strings from the standard input, # and print each of them once, without duplicates. Input order is # *not* preserved. am__uniquify_input = $(AWK) '\ BEGIN { nonempty = 0; } \ { items[$$0] = 1; nonempty = 1; } \ END { if (nonempty) { for (i in items) print i; }; } \ ' # Make sure the list of sources is unique. This is necessary because, # e.g., the same source file might be shared among _SOURCES variables # for different programs/libraries. am__define_uniq_tagged_files = \ list='$(am__tagged_files)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | $(am__uniquify_input)` ETAGS = etags CTAGS = ctags am__tty_colors_dummy = \ mgn= red= grn= lgn= blu= brg= std=; \ am__color_tests=no am__tty_colors = { \ $(am__tty_colors_dummy); \ if test "X$(AM_COLOR_TESTS)" = Xno; then \ am__color_tests=no; \ elif test "X$(AM_COLOR_TESTS)" = Xalways; then \ am__color_tests=yes; \ elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \ am__color_tests=yes; \ fi; \ if test $$am__color_tests = yes; then \ red=''; \ grn=''; \ lgn=''; \ blu=''; \ mgn=''; \ brg=''; \ std=''; \ fi; \ } am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; am__install_max = 40 am__nobase_strip_setup = \ srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` am__nobase_strip = \ for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" am__nobase_list = $(am__nobase_strip_setup); \ for p in $$list; do echo "$$p $$p"; done | \ sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ if (++n[$$2] == $(am__install_max)) \ { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ END { for (dir in files) print dir, files[dir] }' am__base_list = \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' am__uninstall_files_from_dir = { \ test -z "$$files" \ || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \ || { echo " ( cd '$$dir' && rm -f" $$files ")"; \ $(am__cd) "$$dir" && rm -f $$files; }; \ } am__recheck_rx = ^[ ]*:recheck:[ ]* am__global_test_result_rx = ^[ ]*:global-test-result:[ ]* am__copy_in_global_log_rx = ^[ ]*:copy-in-global-log:[ ]* # A command that, given a newline-separated list of test names on the # standard input, print the name of the tests that are to be re-run # upon "make recheck". am__list_recheck_tests = $(AWK) '{ \ recheck = 1; \ while ((rc = (getline line < ($$0 ".trs"))) != 0) \ { \ if (rc < 0) \ { \ if ((getline line2 < ($$0 ".log")) < 0) \ recheck = 0; \ break; \ } \ else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \ { \ recheck = 0; \ break; \ } \ else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \ { \ break; \ } \ }; \ if (recheck) \ print $$0; \ close ($$0 ".trs"); \ close ($$0 ".log"); \ }' # A command that, given a newline-separated list of test names on the # standard input, create the global log from their .trs and .log files. am__create_global_log = $(AWK) ' \ function fatal(msg) \ { \ print "fatal: making $@: " msg | "cat >&2"; \ exit 1; \ } \ function rst_section(header) \ { \ print header; \ len = length(header); \ for (i = 1; i <= len; i = i + 1) \ printf "="; \ printf "\n\n"; \ } \ { \ copy_in_global_log = 1; \ global_test_result = "RUN"; \ while ((rc = (getline line < ($$0 ".trs"))) != 0) \ { \ if (rc < 0) \ fatal("failed to read from " $$0 ".trs"); \ if (line ~ /$(am__global_test_result_rx)/) \ { \ sub("$(am__global_test_result_rx)", "", line); \ sub("[ ]*$$", "", line); \ global_test_result = line; \ } \ else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \ copy_in_global_log = 0; \ }; \ if (copy_in_global_log) \ { \ rst_section(global_test_result ": " $$0); \ while ((rc = (getline line < ($$0 ".log"))) != 0) \ { \ if (rc < 0) \ fatal("failed to read from " $$0 ".log"); \ print line; \ }; \ printf "\n"; \ }; \ close ($$0 ".trs"); \ close ($$0 ".log"); \ }' # Restructured Text title. am__rst_title = { sed 's/.*/ & /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; } # Solaris 10 'make', and several other traditional 'make' implementations, # pass "-e" to $(SHELL), and POSIX 2008 even requires this. Work around it # by disabling -e (using the XSI extension "set +e") if it's set. am__sh_e_setup = case $$- in *e*) set +e;; esac # Default flags passed to test drivers. am__common_driver_flags = \ --color-tests "$$am__color_tests" \ --enable-hard-errors "$$am__enable_hard_errors" \ --expect-failure "$$am__expect_failure" # To be inserted before the command running the test. Creates the # directory for the log if needed. Stores in $dir the directory # containing $f, in $tst the test, in $log the log. Executes the # developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and # passes TESTS_ENVIRONMENT. Set up options for the wrapper that # will run the test scripts (or their associated LOG_COMPILER, if # thy have one). am__check_pre = \ $(am__sh_e_setup); \ $(am__vpath_adj_setup) $(am__vpath_adj) \ $(am__tty_colors); \ srcdir=$(srcdir); export srcdir; \ case "$@" in \ */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;; \ *) am__odir=.;; \ esac; \ test "x$$am__odir" = x"." || test -d "$$am__odir" \ || $(MKDIR_P) "$$am__odir" || exit $$?; \ if test -f "./$$f"; then dir=./; \ elif test -f "$$f"; then dir=; \ else dir="$(srcdir)/"; fi; \ tst=$$dir$$f; log='$@'; \ if test -n '$(DISABLE_HARD_ERRORS)'; then \ am__enable_hard_errors=no; \ else \ am__enable_hard_errors=yes; \ fi; \ case " $(XFAIL_TESTS) " in \ *[\ \ ]$$f[\ \ ]* | *[\ \ ]$$dir$$f[\ \ ]*) \ am__expect_failure=yes;; \ *) \ am__expect_failure=no;; \ esac; \ $(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT) # A shell command to get the names of the tests scripts with any registered # extension removed (i.e., equivalently, the names of the test logs, with # the '.log' extension removed). The result is saved in the shell variable # '$bases'. This honors runtime overriding of TESTS and TEST_LOGS. Sadly, # we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)", # since that might cause problem with VPATH rewrites for suffix-less tests. # See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'. am__set_TESTS_bases = \ bases='$(TEST_LOGS)'; \ bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \ bases=`echo $$bases` RECHECK_LOGS = $(TEST_LOGS) AM_RECURSIVE_TARGETS = check recheck TEST_SUITE_LOG = test-suite.log TEST_EXTENSIONS = @EXEEXT@ .test LOG_DRIVER = $(SHELL) $(top_srcdir)/test-driver LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS) am__set_b = \ case '$@' in \ */*) \ case '$*' in \ */*) b='$*';; \ *) b=`echo '$@' | sed 's/\.log$$//'`; \ esac;; \ *) \ b='$*';; \ esac am__test_logs1 = $(TESTS:=.log) am__test_logs2 = $(am__test_logs1:@EXEEXT@.log=.log) TEST_LOGS = $(am__test_logs2:.test.log=.log) TEST_LOG_DRIVER = $(SHELL) $(top_srcdir)/test-driver TEST_LOG_COMPILE = $(TEST_LOG_COMPILER) $(AM_TEST_LOG_FLAGS) \ $(TEST_LOG_FLAGS) am__DIST_COMMON = $(srcdir)/Makefile.in $(top_srcdir)/depcomp \ $(top_srcdir)/test-driver DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ BOOST_CPPFLAGS = @BOOST_CPPFLAGS@ BOOST_DATE_TIME_LDFLAGS = @BOOST_DATE_TIME_LDFLAGS@ BOOST_DATE_TIME_LDPATH = @BOOST_DATE_TIME_LDPATH@ BOOST_DATE_TIME_LIBS = @BOOST_DATE_TIME_LIBS@ BOOST_LDPATH = @BOOST_LDPATH@ BOOST_PROGRAM_OPTIONS_LDFLAGS = @BOOST_PROGRAM_OPTIONS_LDFLAGS@ BOOST_PROGRAM_OPTIONS_LDPATH = @BOOST_PROGRAM_OPTIONS_LDPATH@ BOOST_PROGRAM_OPTIONS_LIBS = @BOOST_PROGRAM_OPTIONS_LIBS@ BOOST_ROOT = @BOOST_ROOT@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPCHECK = @CPPCHECK@ CPPCHECK_PARALLELISM = @CPPCHECK_PARALLELISM@ CPPFLAGS = @CPPFLAGS@ CPPUNIT_CFLAGS = @CPPUNIT_CFLAGS@ CPPUNIT_LIBS = @CPPUNIT_LIBS@ CURL_CFLAGS = @CURL_CFLAGS@ CURL_LIBS = @CURL_LIBS@ CXX = @CXX@ CXXCPP = @CXXCPP@ CXXDEPMODE = @CXXDEPMODE@ CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DISTCHECK_CONFIGURE_FLAGS = @DISTCHECK_CONFIGURE_FLAGS@ DLLTOOL = @DLLTOOL@ DOCBOOK2MAN = @DOCBOOK2MAN@ DSYMUTIL = @DSYMUTIL@ DUMPBIN = @DUMPBIN@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ FGREP = @FGREP@ GENHTML = @GENHTML@ GREP = @GREP@ HAVE_CXX11 = @HAVE_CXX11@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LCOV = @LCOV@ LD = @LD@ LDFLAGS = @LDFLAGS@ LIBCMIS_API_VERSION = @LIBCMIS_API_VERSION@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LIPO = @LIPO@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ LT_SYS_LIBRARY_PATH = @LT_SYS_LIBRARY_PATH@ MAKEINFO = @MAKEINFO@ MANIFEST_TOOL = @MANIFEST_TOOL@ MKDIR_P = @MKDIR_P@ NM = @NM@ NMEDIT = @NMEDIT@ NPROC = @NPROC@ OBJDUMP = @OBJDUMP@ OBJEXT = @OBJEXT@ OTOOL = @OTOOL@ OTOOL64 = @OTOOL64@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_URL = @PACKAGE_URL@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ PKG_CONFIG = @PKG_CONFIG@ PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@ PKG_CONFIG_PATH = @PKG_CONFIG_PATH@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ SRCDIR = @SRCDIR@ STRIP = @STRIP@ VERSION = @VERSION@ XML2_CFLAGS = @XML2_CFLAGS@ XML2_LIBS = @XML2_LIBS@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_AR = @ac_ct_AR@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ ac_ct_DUMPBIN = @ac_ct_DUMPBIN@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_build_prefix = @top_build_prefix@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ test_api_SOURCES = \ test-allowable-actions.cxx \ test-api.cxx \ test-document.cxx \ test-dummies.cxx \ test-dummies.hxx \ test-folder.cxx \ test-object-type.cxx \ test-object.cxx \ test-property-type.cxx \ test-property.cxx \ test-repository.cxx \ test-session.cxx test_api_CXXFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis-c/ \ $(XML2_CFLAGS) \ $(BOOST_CPPFLAGS) test_api_LDADD = \ $(top_builddir)/src/libcmis-c/libcmis-c-@LIBCMIS_API_VERSION@.la \ $(top_builddir)/src/libcmis/libcmis-@LIBCMIS_API_VERSION@.la \ $(XML2_LIBS) \ $(CURL_LIBS) \ $(CPPUNIT_LIBS) \ $(BOOST_DATE_TIME_LIBS) test_c_build_SOURCES = \ test-build.c test_c_build_CFLAGS = \ -I$(top_srcdir)/inc \ $(XML2_CFLAGS) test_c_build_LDADD = \ $(top_builddir)/src/libcmis-c/libcmis-c-@LIBCMIS_API_VERSION@.la \ $(top_builddir)/src/libcmis/libcmis-@LIBCMIS_API_VERSION@.la \ $(XML2_LIBS) \ $(CURL_LIBS) \ $(CPPUNIT_LIBS) \ $(BOOST_DATE_TIME_LIBS) all: all-am .SUFFIXES: .SUFFIXES: .c .cxx .lo .log .o .obj .test .test$(EXEEXT) .trs $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ && { if test -f $@; then exit 0; else break; fi; }; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign qa/libcmis-c/Makefile'; \ $(am__cd) $(top_srcdir) && \ $(AUTOMAKE) --foreign qa/libcmis-c/Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__maybe_remake_depfiles);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(am__aclocal_m4_deps): clean-checkPROGRAMS: @list='$(check_PROGRAMS)'; test -n "$$list" || exit 0; \ echo " rm -f" $$list; \ rm -f $$list || exit $$?; \ test -n "$(EXEEXT)" || exit 0; \ list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ echo " rm -f" $$list; \ rm -f $$list test-api$(EXEEXT): $(test_api_OBJECTS) $(test_api_DEPENDENCIES) $(EXTRA_test_api_DEPENDENCIES) @rm -f test-api$(EXEEXT) $(AM_V_CXXLD)$(test_api_LINK) $(test_api_OBJECTS) $(test_api_LDADD) $(LIBS) test-c-build$(EXEEXT): $(test_c_build_OBJECTS) $(test_c_build_DEPENDENCIES) $(EXTRA_test_c_build_DEPENDENCIES) @rm -f test-c-build$(EXEEXT) $(AM_V_CCLD)$(test_c_build_LINK) $(test_c_build_OBJECTS) $(test_c_build_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_api-test-allowable-actions.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_api-test-api.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_api-test-document.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_api-test-dummies.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_api-test-folder.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_api-test-object-type.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_api-test-object.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_api-test-property-type.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_api-test-property.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_api-test-repository.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_api-test-session.Po@am__quote@ # am--include-marker @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_c_build-test-build.Po@am__quote@ # am--include-marker $(am__depfiles_remade): @$(MKDIR_P) $(@D) @echo '# dummy' >$@-t && $(am__mv) $@-t $@ am--depfiles: $(am__depfiles_remade) .c.o: @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $< .c.obj: @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .c.lo: @am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $< test_c_build-test-build.o: test-build.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_c_build_CFLAGS) $(CFLAGS) -MT test_c_build-test-build.o -MD -MP -MF $(DEPDIR)/test_c_build-test-build.Tpo -c -o test_c_build-test-build.o `test -f 'test-build.c' || echo '$(srcdir)/'`test-build.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_c_build-test-build.Tpo $(DEPDIR)/test_c_build-test-build.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test-build.c' object='test_c_build-test-build.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_c_build_CFLAGS) $(CFLAGS) -c -o test_c_build-test-build.o `test -f 'test-build.c' || echo '$(srcdir)/'`test-build.c test_c_build-test-build.obj: test-build.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_c_build_CFLAGS) $(CFLAGS) -MT test_c_build-test-build.obj -MD -MP -MF $(DEPDIR)/test_c_build-test-build.Tpo -c -o test_c_build-test-build.obj `if test -f 'test-build.c'; then $(CYGPATH_W) 'test-build.c'; else $(CYGPATH_W) '$(srcdir)/test-build.c'; fi` @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_c_build-test-build.Tpo $(DEPDIR)/test_c_build-test-build.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='test-build.c' object='test_c_build-test-build.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_c_build_CFLAGS) $(CFLAGS) -c -o test_c_build-test-build.obj `if test -f 'test-build.c'; then $(CYGPATH_W) 'test-build.c'; else $(CYGPATH_W) '$(srcdir)/test-build.c'; fi` .cxx.o: @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ $< .cxx.obj: @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'` .cxx.lo: @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(LTCXXCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(LTCXXCOMPILE) -c -o $@ $< test_api-test-allowable-actions.o: test-allowable-actions.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-allowable-actions.o -MD -MP -MF $(DEPDIR)/test_api-test-allowable-actions.Tpo -c -o test_api-test-allowable-actions.o `test -f 'test-allowable-actions.cxx' || echo '$(srcdir)/'`test-allowable-actions.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-allowable-actions.Tpo $(DEPDIR)/test_api-test-allowable-actions.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-allowable-actions.cxx' object='test_api-test-allowable-actions.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-allowable-actions.o `test -f 'test-allowable-actions.cxx' || echo '$(srcdir)/'`test-allowable-actions.cxx test_api-test-allowable-actions.obj: test-allowable-actions.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-allowable-actions.obj -MD -MP -MF $(DEPDIR)/test_api-test-allowable-actions.Tpo -c -o test_api-test-allowable-actions.obj `if test -f 'test-allowable-actions.cxx'; then $(CYGPATH_W) 'test-allowable-actions.cxx'; else $(CYGPATH_W) '$(srcdir)/test-allowable-actions.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-allowable-actions.Tpo $(DEPDIR)/test_api-test-allowable-actions.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-allowable-actions.cxx' object='test_api-test-allowable-actions.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-allowable-actions.obj `if test -f 'test-allowable-actions.cxx'; then $(CYGPATH_W) 'test-allowable-actions.cxx'; else $(CYGPATH_W) '$(srcdir)/test-allowable-actions.cxx'; fi` test_api-test-api.o: test-api.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-api.o -MD -MP -MF $(DEPDIR)/test_api-test-api.Tpo -c -o test_api-test-api.o `test -f 'test-api.cxx' || echo '$(srcdir)/'`test-api.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-api.Tpo $(DEPDIR)/test_api-test-api.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-api.cxx' object='test_api-test-api.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-api.o `test -f 'test-api.cxx' || echo '$(srcdir)/'`test-api.cxx test_api-test-api.obj: test-api.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-api.obj -MD -MP -MF $(DEPDIR)/test_api-test-api.Tpo -c -o test_api-test-api.obj `if test -f 'test-api.cxx'; then $(CYGPATH_W) 'test-api.cxx'; else $(CYGPATH_W) '$(srcdir)/test-api.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-api.Tpo $(DEPDIR)/test_api-test-api.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-api.cxx' object='test_api-test-api.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-api.obj `if test -f 'test-api.cxx'; then $(CYGPATH_W) 'test-api.cxx'; else $(CYGPATH_W) '$(srcdir)/test-api.cxx'; fi` test_api-test-document.o: test-document.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-document.o -MD -MP -MF $(DEPDIR)/test_api-test-document.Tpo -c -o test_api-test-document.o `test -f 'test-document.cxx' || echo '$(srcdir)/'`test-document.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-document.Tpo $(DEPDIR)/test_api-test-document.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-document.cxx' object='test_api-test-document.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-document.o `test -f 'test-document.cxx' || echo '$(srcdir)/'`test-document.cxx test_api-test-document.obj: test-document.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-document.obj -MD -MP -MF $(DEPDIR)/test_api-test-document.Tpo -c -o test_api-test-document.obj `if test -f 'test-document.cxx'; then $(CYGPATH_W) 'test-document.cxx'; else $(CYGPATH_W) '$(srcdir)/test-document.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-document.Tpo $(DEPDIR)/test_api-test-document.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-document.cxx' object='test_api-test-document.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-document.obj `if test -f 'test-document.cxx'; then $(CYGPATH_W) 'test-document.cxx'; else $(CYGPATH_W) '$(srcdir)/test-document.cxx'; fi` test_api-test-dummies.o: test-dummies.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-dummies.o -MD -MP -MF $(DEPDIR)/test_api-test-dummies.Tpo -c -o test_api-test-dummies.o `test -f 'test-dummies.cxx' || echo '$(srcdir)/'`test-dummies.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-dummies.Tpo $(DEPDIR)/test_api-test-dummies.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-dummies.cxx' object='test_api-test-dummies.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-dummies.o `test -f 'test-dummies.cxx' || echo '$(srcdir)/'`test-dummies.cxx test_api-test-dummies.obj: test-dummies.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-dummies.obj -MD -MP -MF $(DEPDIR)/test_api-test-dummies.Tpo -c -o test_api-test-dummies.obj `if test -f 'test-dummies.cxx'; then $(CYGPATH_W) 'test-dummies.cxx'; else $(CYGPATH_W) '$(srcdir)/test-dummies.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-dummies.Tpo $(DEPDIR)/test_api-test-dummies.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-dummies.cxx' object='test_api-test-dummies.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-dummies.obj `if test -f 'test-dummies.cxx'; then $(CYGPATH_W) 'test-dummies.cxx'; else $(CYGPATH_W) '$(srcdir)/test-dummies.cxx'; fi` test_api-test-folder.o: test-folder.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-folder.o -MD -MP -MF $(DEPDIR)/test_api-test-folder.Tpo -c -o test_api-test-folder.o `test -f 'test-folder.cxx' || echo '$(srcdir)/'`test-folder.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-folder.Tpo $(DEPDIR)/test_api-test-folder.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-folder.cxx' object='test_api-test-folder.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-folder.o `test -f 'test-folder.cxx' || echo '$(srcdir)/'`test-folder.cxx test_api-test-folder.obj: test-folder.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-folder.obj -MD -MP -MF $(DEPDIR)/test_api-test-folder.Tpo -c -o test_api-test-folder.obj `if test -f 'test-folder.cxx'; then $(CYGPATH_W) 'test-folder.cxx'; else $(CYGPATH_W) '$(srcdir)/test-folder.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-folder.Tpo $(DEPDIR)/test_api-test-folder.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-folder.cxx' object='test_api-test-folder.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-folder.obj `if test -f 'test-folder.cxx'; then $(CYGPATH_W) 'test-folder.cxx'; else $(CYGPATH_W) '$(srcdir)/test-folder.cxx'; fi` test_api-test-object-type.o: test-object-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-object-type.o -MD -MP -MF $(DEPDIR)/test_api-test-object-type.Tpo -c -o test_api-test-object-type.o `test -f 'test-object-type.cxx' || echo '$(srcdir)/'`test-object-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-object-type.Tpo $(DEPDIR)/test_api-test-object-type.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-object-type.cxx' object='test_api-test-object-type.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-object-type.o `test -f 'test-object-type.cxx' || echo '$(srcdir)/'`test-object-type.cxx test_api-test-object-type.obj: test-object-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-object-type.obj -MD -MP -MF $(DEPDIR)/test_api-test-object-type.Tpo -c -o test_api-test-object-type.obj `if test -f 'test-object-type.cxx'; then $(CYGPATH_W) 'test-object-type.cxx'; else $(CYGPATH_W) '$(srcdir)/test-object-type.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-object-type.Tpo $(DEPDIR)/test_api-test-object-type.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-object-type.cxx' object='test_api-test-object-type.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-object-type.obj `if test -f 'test-object-type.cxx'; then $(CYGPATH_W) 'test-object-type.cxx'; else $(CYGPATH_W) '$(srcdir)/test-object-type.cxx'; fi` test_api-test-object.o: test-object.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-object.o -MD -MP -MF $(DEPDIR)/test_api-test-object.Tpo -c -o test_api-test-object.o `test -f 'test-object.cxx' || echo '$(srcdir)/'`test-object.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-object.Tpo $(DEPDIR)/test_api-test-object.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-object.cxx' object='test_api-test-object.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-object.o `test -f 'test-object.cxx' || echo '$(srcdir)/'`test-object.cxx test_api-test-object.obj: test-object.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-object.obj -MD -MP -MF $(DEPDIR)/test_api-test-object.Tpo -c -o test_api-test-object.obj `if test -f 'test-object.cxx'; then $(CYGPATH_W) 'test-object.cxx'; else $(CYGPATH_W) '$(srcdir)/test-object.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-object.Tpo $(DEPDIR)/test_api-test-object.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-object.cxx' object='test_api-test-object.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-object.obj `if test -f 'test-object.cxx'; then $(CYGPATH_W) 'test-object.cxx'; else $(CYGPATH_W) '$(srcdir)/test-object.cxx'; fi` test_api-test-property-type.o: test-property-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-property-type.o -MD -MP -MF $(DEPDIR)/test_api-test-property-type.Tpo -c -o test_api-test-property-type.o `test -f 'test-property-type.cxx' || echo '$(srcdir)/'`test-property-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-property-type.Tpo $(DEPDIR)/test_api-test-property-type.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-property-type.cxx' object='test_api-test-property-type.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-property-type.o `test -f 'test-property-type.cxx' || echo '$(srcdir)/'`test-property-type.cxx test_api-test-property-type.obj: test-property-type.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-property-type.obj -MD -MP -MF $(DEPDIR)/test_api-test-property-type.Tpo -c -o test_api-test-property-type.obj `if test -f 'test-property-type.cxx'; then $(CYGPATH_W) 'test-property-type.cxx'; else $(CYGPATH_W) '$(srcdir)/test-property-type.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-property-type.Tpo $(DEPDIR)/test_api-test-property-type.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-property-type.cxx' object='test_api-test-property-type.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-property-type.obj `if test -f 'test-property-type.cxx'; then $(CYGPATH_W) 'test-property-type.cxx'; else $(CYGPATH_W) '$(srcdir)/test-property-type.cxx'; fi` test_api-test-property.o: test-property.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-property.o -MD -MP -MF $(DEPDIR)/test_api-test-property.Tpo -c -o test_api-test-property.o `test -f 'test-property.cxx' || echo '$(srcdir)/'`test-property.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-property.Tpo $(DEPDIR)/test_api-test-property.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-property.cxx' object='test_api-test-property.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-property.o `test -f 'test-property.cxx' || echo '$(srcdir)/'`test-property.cxx test_api-test-property.obj: test-property.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-property.obj -MD -MP -MF $(DEPDIR)/test_api-test-property.Tpo -c -o test_api-test-property.obj `if test -f 'test-property.cxx'; then $(CYGPATH_W) 'test-property.cxx'; else $(CYGPATH_W) '$(srcdir)/test-property.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-property.Tpo $(DEPDIR)/test_api-test-property.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-property.cxx' object='test_api-test-property.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-property.obj `if test -f 'test-property.cxx'; then $(CYGPATH_W) 'test-property.cxx'; else $(CYGPATH_W) '$(srcdir)/test-property.cxx'; fi` test_api-test-repository.o: test-repository.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-repository.o -MD -MP -MF $(DEPDIR)/test_api-test-repository.Tpo -c -o test_api-test-repository.o `test -f 'test-repository.cxx' || echo '$(srcdir)/'`test-repository.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-repository.Tpo $(DEPDIR)/test_api-test-repository.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-repository.cxx' object='test_api-test-repository.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-repository.o `test -f 'test-repository.cxx' || echo '$(srcdir)/'`test-repository.cxx test_api-test-repository.obj: test-repository.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-repository.obj -MD -MP -MF $(DEPDIR)/test_api-test-repository.Tpo -c -o test_api-test-repository.obj `if test -f 'test-repository.cxx'; then $(CYGPATH_W) 'test-repository.cxx'; else $(CYGPATH_W) '$(srcdir)/test-repository.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-repository.Tpo $(DEPDIR)/test_api-test-repository.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-repository.cxx' object='test_api-test-repository.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-repository.obj `if test -f 'test-repository.cxx'; then $(CYGPATH_W) 'test-repository.cxx'; else $(CYGPATH_W) '$(srcdir)/test-repository.cxx'; fi` test_api-test-session.o: test-session.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-session.o -MD -MP -MF $(DEPDIR)/test_api-test-session.Tpo -c -o test_api-test-session.o `test -f 'test-session.cxx' || echo '$(srcdir)/'`test-session.cxx @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-session.Tpo $(DEPDIR)/test_api-test-session.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-session.cxx' object='test_api-test-session.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-session.o `test -f 'test-session.cxx' || echo '$(srcdir)/'`test-session.cxx test_api-test-session.obj: test-session.cxx @am__fastdepCXX_TRUE@ $(AM_V_CXX)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -MT test_api-test-session.obj -MD -MP -MF $(DEPDIR)/test_api-test-session.Tpo -c -o test_api-test-session.obj `if test -f 'test-session.cxx'; then $(CYGPATH_W) 'test-session.cxx'; else $(CYGPATH_W) '$(srcdir)/test-session.cxx'; fi` @am__fastdepCXX_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/test_api-test-session.Tpo $(DEPDIR)/test_api-test-session.Po @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(AM_V_CXX)source='test-session.cxx' object='test_api-test-session.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCXX_FALSE@ DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCXX_FALSE@ $(AM_V_CXX@am__nodep@)$(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(test_api_CXXFLAGS) $(CXXFLAGS) -c -o test_api-test-session.obj `if test -f 'test-session.cxx'; then $(CYGPATH_W) 'test-session.cxx'; else $(CYGPATH_W) '$(srcdir)/test-session.cxx'; fi` mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs ID: $(am__tagged_files) $(am__define_uniq_tagged_files); mkid -fID $$unique tags: tags-am TAGS: tags tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) set x; \ here=`pwd`; \ $(am__define_uniq_tagged_files); \ shift; \ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ if test $$# -gt 0; then \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ "$$@" $$unique; \ else \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$unique; \ fi; \ fi ctags: ctags-am CTAGS: ctags ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files) $(am__define_uniq_tagged_files); \ test -z "$(CTAGS_ARGS)$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && $(am__cd) $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) "$$here" cscopelist: cscopelist-am cscopelist-am: $(am__tagged_files) list='$(am__tagged_files)'; \ case "$(srcdir)" in \ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \ *) sdir=$(subdir)/$(srcdir) ;; \ esac; \ for i in $$list; do \ if test -f "$$i"; then \ echo "$(subdir)/$$i"; \ else \ echo "$$sdir/$$i"; \ fi; \ done >> $(top_builddir)/cscope.files distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags # Recover from deleted '.trs' file; this should ensure that # "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create # both 'foo.log' and 'foo.trs'. Break the recipe in two subshells # to avoid problems with "make -n". .log.trs: rm -f $< $@ $(MAKE) $(AM_MAKEFLAGS) $< # Leading 'am--fnord' is there to ensure the list of targets does not # expand to empty, as could happen e.g. with make check TESTS=''. am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck) am--force-recheck: @: $(TEST_SUITE_LOG): $(TEST_LOGS) @$(am__set_TESTS_bases); \ am__f_ok () { test -f "$$1" && test -r "$$1"; }; \ redo_bases=`for i in $$bases; do \ am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \ done`; \ if test -n "$$redo_bases"; then \ redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \ redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \ if $(am__make_dryrun); then :; else \ rm -f $$redo_logs && rm -f $$redo_results || exit 1; \ fi; \ fi; \ if test -n "$$am__remaking_logs"; then \ echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \ "recursion detected" >&2; \ elif test -n "$$redo_logs"; then \ am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \ fi; \ if $(am__make_dryrun); then :; else \ st=0; \ errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \ for i in $$redo_bases; do \ test -f $$i.trs && test -r $$i.trs \ || { echo "$$errmsg $$i.trs" >&2; st=1; }; \ test -f $$i.log && test -r $$i.log \ || { echo "$$errmsg $$i.log" >&2; st=1; }; \ done; \ test $$st -eq 0 || exit 1; \ fi @$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \ ws='[ ]'; \ results=`for b in $$bases; do echo $$b.trs; done`; \ test -n "$$results" || results=/dev/null; \ all=` grep "^$$ws*:test-result:" $$results | wc -l`; \ pass=` grep "^$$ws*:test-result:$$ws*PASS" $$results | wc -l`; \ fail=` grep "^$$ws*:test-result:$$ws*FAIL" $$results | wc -l`; \ skip=` grep "^$$ws*:test-result:$$ws*SKIP" $$results | wc -l`; \ xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \ xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \ error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \ if test `expr $$fail + $$xpass + $$error` -eq 0; then \ success=true; \ else \ success=false; \ fi; \ br='==================='; br=$$br$$br$$br$$br; \ result_count () \ { \ if test x"$$1" = x"--maybe-color"; then \ maybe_colorize=yes; \ elif test x"$$1" = x"--no-color"; then \ maybe_colorize=no; \ else \ echo "$@: invalid 'result_count' usage" >&2; exit 4; \ fi; \ shift; \ desc=$$1 count=$$2; \ if test $$maybe_colorize = yes && test $$count -gt 0; then \ color_start=$$3 color_end=$$std; \ else \ color_start= color_end=; \ fi; \ echo "$${color_start}# $$desc $$count$${color_end}"; \ }; \ create_testsuite_report () \ { \ result_count $$1 "TOTAL:" $$all "$$brg"; \ result_count $$1 "PASS: " $$pass "$$grn"; \ result_count $$1 "SKIP: " $$skip "$$blu"; \ result_count $$1 "XFAIL:" $$xfail "$$lgn"; \ result_count $$1 "FAIL: " $$fail "$$red"; \ result_count $$1 "XPASS:" $$xpass "$$red"; \ result_count $$1 "ERROR:" $$error "$$mgn"; \ }; \ { \ echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" | \ $(am__rst_title); \ create_testsuite_report --no-color; \ echo; \ echo ".. contents:: :depth: 2"; \ echo; \ for b in $$bases; do echo $$b; done \ | $(am__create_global_log); \ } >$(TEST_SUITE_LOG).tmp || exit 1; \ mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG); \ if $$success; then \ col="$$grn"; \ else \ col="$$red"; \ test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG); \ fi; \ echo "$${col}$$br$${std}"; \ echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}"; \ echo "$${col}$$br$${std}"; \ create_testsuite_report --maybe-color; \ echo "$$col$$br$$std"; \ if $$success; then :; else \ echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}"; \ if test -n "$(PACKAGE_BUGREPORT)"; then \ echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}"; \ fi; \ echo "$$col$$br$$std"; \ fi; \ $$success || exit 1 check-TESTS: $(check_PROGRAMS) @list='$(RECHECK_LOGS)'; test -z "$$list" || rm -f $$list @list='$(RECHECK_LOGS:.log=.trs)'; test -z "$$list" || rm -f $$list @test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) @set +e; $(am__set_TESTS_bases); \ log_list=`for i in $$bases; do echo $$i.log; done`; \ trs_list=`for i in $$bases; do echo $$i.trs; done`; \ log_list=`echo $$log_list`; trs_list=`echo $$trs_list`; \ $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) TEST_LOGS="$$log_list"; \ exit $$?; recheck: all $(check_PROGRAMS) @test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) @set +e; $(am__set_TESTS_bases); \ bases=`for i in $$bases; do echo $$i; done \ | $(am__list_recheck_tests)` || exit 1; \ log_list=`for i in $$bases; do echo $$i.log; done`; \ log_list=`echo $$log_list`; \ $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \ am__force_recheck=am--force-recheck \ TEST_LOGS="$$log_list"; \ exit $$? test-api.log: test-api$(EXEEXT) @p='test-api$(EXEEXT)'; \ b='test-api'; \ $(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \ --log-file $$b.log --trs-file $$b.trs \ $(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \ "$$tst" $(AM_TESTS_FD_REDIRECT) .test.log: @p='$<'; \ $(am__set_b); \ $(am__check_pre) $(TEST_LOG_DRIVER) --test-name "$$f" \ --log-file $$b.log --trs-file $$b.trs \ $(am__common_driver_flags) $(AM_TEST_LOG_DRIVER_FLAGS) $(TEST_LOG_DRIVER_FLAGS) -- $(TEST_LOG_COMPILE) \ "$$tst" $(AM_TESTS_FD_REDIRECT) @am__EXEEXT_TRUE@.test$(EXEEXT).log: @am__EXEEXT_TRUE@ @p='$<'; \ @am__EXEEXT_TRUE@ $(am__set_b); \ @am__EXEEXT_TRUE@ $(am__check_pre) $(TEST_LOG_DRIVER) --test-name "$$f" \ @am__EXEEXT_TRUE@ --log-file $$b.log --trs-file $$b.trs \ @am__EXEEXT_TRUE@ $(am__common_driver_flags) $(AM_TEST_LOG_DRIVER_FLAGS) $(TEST_LOG_DRIVER_FLAGS) -- $(TEST_LOG_COMPILE) \ @am__EXEEXT_TRUE@ "$$tst" $(AM_TESTS_FD_REDIRECT) distdir: $(BUILT_SOURCES) $(MAKE) $(AM_MAKEFLAGS) distdir-am distdir-am: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d "$(distdir)/$$file"; then \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ fi; \ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ else \ test -f "$(distdir)/$$file" \ || cp -p $$d/$$file "$(distdir)/$$file" \ || exit 1; \ fi; \ done check-am: all-am $(MAKE) $(AM_MAKEFLAGS) $(check_PROGRAMS) $(MAKE) $(AM_MAKEFLAGS) check-TESTS check: check-am all-am: Makefile installdirs: install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: if test -z '$(STRIP)'; then \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ install; \ else \ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \ fi mostlyclean-generic: -test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS) -test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs) -test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG) clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-checkPROGRAMS clean-generic clean-libtool \ mostlyclean-am distclean: distclean-am -rm -f ./$(DEPDIR)/test_api-test-allowable-actions.Po -rm -f ./$(DEPDIR)/test_api-test-api.Po -rm -f ./$(DEPDIR)/test_api-test-document.Po -rm -f ./$(DEPDIR)/test_api-test-dummies.Po -rm -f ./$(DEPDIR)/test_api-test-folder.Po -rm -f ./$(DEPDIR)/test_api-test-object-type.Po -rm -f ./$(DEPDIR)/test_api-test-object.Po -rm -f ./$(DEPDIR)/test_api-test-property-type.Po -rm -f ./$(DEPDIR)/test_api-test-property.Po -rm -f ./$(DEPDIR)/test_api-test-repository.Po -rm -f ./$(DEPDIR)/test_api-test-session.Po -rm -f ./$(DEPDIR)/test_c_build-test-build.Po -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-tags dvi: dvi-am dvi-am: html: html-am html-am: info: info-am info-am: install-data-am: install-dvi: install-dvi-am install-dvi-am: install-exec-am: install-html: install-html-am install-html-am: install-info: install-info-am install-info-am: install-man: install-pdf: install-pdf-am install-pdf-am: install-ps: install-ps-am install-ps-am: installcheck-am: maintainer-clean: maintainer-clean-am -rm -f ./$(DEPDIR)/test_api-test-allowable-actions.Po -rm -f ./$(DEPDIR)/test_api-test-api.Po -rm -f ./$(DEPDIR)/test_api-test-document.Po -rm -f ./$(DEPDIR)/test_api-test-dummies.Po -rm -f ./$(DEPDIR)/test_api-test-folder.Po -rm -f ./$(DEPDIR)/test_api-test-object-type.Po -rm -f ./$(DEPDIR)/test_api-test-object.Po -rm -f ./$(DEPDIR)/test_api-test-property-type.Po -rm -f ./$(DEPDIR)/test_api-test-property.Po -rm -f ./$(DEPDIR)/test_api-test-repository.Po -rm -f ./$(DEPDIR)/test_api-test-session.Po -rm -f ./$(DEPDIR)/test_c_build-test-build.Po -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: .MAKE: check-am install-am install-strip .PHONY: CTAGS GTAGS TAGS all all-am am--depfiles check check-TESTS \ check-am clean clean-checkPROGRAMS clean-generic clean-libtool \ cscopelist-am ctags ctags-am distclean distclean-compile \ distclean-generic distclean-libtool distclean-tags distdir dvi \ dvi-am html html-am info info-am install install-am \ install-data install-data-am install-dvi install-dvi-am \ install-exec install-exec-am install-html install-html-am \ install-info install-info-am install-man install-pdf \ install-pdf-am install-ps install-ps-am install-strip \ installcheck installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ recheck tags tags-am uninstall uninstall-am .PRECIOUS: Makefile # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis-c/test-build.c�������������������������������������������������������������0000664�0001750�0001750�00000002257�13407414352�014557� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <libcmis-c/libcmis-c.h> int main ( int argc, char ** argv ) { ( void )argc; ( void )argv; return 0; } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis-c/test-object.cxx����������������������������������������������������������0000664�0001750�0001750�00000035300�13407414352�015301� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <cppunit/extensions/HelperMacros.h> #include <cppunit/TestFixture.h> #include <cppunit/TestAssert.h> #include <libcmis-c/allowable-actions.h> #include <libcmis-c/error.h> #include <libcmis-c/folder.h> #include <libcmis-c/object.h> #include <libcmis-c/object-type.h> #include <libcmis-c/property.h> #include <libcmis-c/property-type.h> #include <libcmis-c/vectors.h> #include "internals.hxx" #include "test-dummies.hxx" using namespace std; class ObjectTest : public CppUnit::TestFixture { private: libcmis_ObjectPtr getTested( bool triggersFaults ); libcmis_FolderPtr getTestFolder( ); public: void getIdTest( ); void getNameTest( ); void getPathsTest( ); void getBaseTypeTest( ); void getTypeTest( ); void getCreatedByTest( ); void getCreationDateTest( ); void getLastModifiedByTest( ); void getLastModificationDateTest( ); void getChangeTokenTest( ); void isImmutableTest( ); void getPropertiesTest( ); void getPropertyTest( ); void getPropertyMissingTest( ); void updatePropertiesTest( ); void updatePropertiesErrorTest( ); void getTypeDescriptionTest( ); void getAllowableActionsTest( ); void refreshTest( ); void refreshErrorTest( ); void removeTest( ); void removeErrorTest( ); void moveTest( ); void moveErrorTest( ); void toStringTest( ); CPPUNIT_TEST_SUITE( ObjectTest ); CPPUNIT_TEST( getIdTest ); CPPUNIT_TEST( getNameTest ); CPPUNIT_TEST( getPathsTest ); CPPUNIT_TEST( getBaseTypeTest ); CPPUNIT_TEST( getTypeTest ); CPPUNIT_TEST( getCreatedByTest ); CPPUNIT_TEST( getCreationDateTest ); CPPUNIT_TEST( getLastModifiedByTest ); CPPUNIT_TEST( getLastModificationDateTest ); CPPUNIT_TEST( getChangeTokenTest ); CPPUNIT_TEST( isImmutableTest ); CPPUNIT_TEST( getPropertiesTest ); CPPUNIT_TEST( getPropertyTest ); CPPUNIT_TEST( getPropertyMissingTest ); CPPUNIT_TEST( updatePropertiesTest ); CPPUNIT_TEST( updatePropertiesErrorTest ); CPPUNIT_TEST( getTypeDescriptionTest ); CPPUNIT_TEST( getAllowableActionsTest ); CPPUNIT_TEST( refreshTest ); CPPUNIT_TEST( refreshErrorTest ); CPPUNIT_TEST( removeTest ); CPPUNIT_TEST( removeErrorTest ); CPPUNIT_TEST( moveTest ); CPPUNIT_TEST( moveErrorTest ); CPPUNIT_TEST( toStringTest ); CPPUNIT_TEST_SUITE_END( ); }; CPPUNIT_TEST_SUITE_REGISTRATION( ObjectTest ); libcmis_ObjectPtr ObjectTest::getTested( bool triggersFaults ) { libcmis_ObjectPtr result = new libcmis_object( ); libcmis::ObjectPtr handle( new dummies::Object( triggersFaults ) ); result->handle = handle; return result; } libcmis_FolderPtr ObjectTest::getTestFolder( ) { libcmis_FolderPtr result = new libcmis_folder( ); libcmis::FolderPtr handle( new dummies::Folder( false, false ) ); result->handle = handle; return result; } void ObjectTest::getIdTest( ) { libcmis_ObjectPtr tested = getTested( false ); char* actual = libcmis_object_getId( tested ); CPPUNIT_ASSERT_EQUAL( string( "Object::Id" ), string( actual ) ); free( actual ); libcmis_object_free( tested ); } void ObjectTest::getNameTest( ) { libcmis_ObjectPtr tested = getTested( false ); char* actual = libcmis_object_getName( tested ); CPPUNIT_ASSERT_EQUAL( string( "Object::Name" ), string( actual ) ); free( actual ); libcmis_object_free( tested ); } void ObjectTest::getPathsTest( ) { libcmis_ObjectPtr tested = getTested( false ); libcmis_vector_string_Ptr actual = libcmis_object_getPaths( tested ); CPPUNIT_ASSERT_EQUAL( size_t( 2 ), libcmis_vector_string_size( actual ) ); CPPUNIT_ASSERT_EQUAL( string( "/Path1/" ), string( libcmis_vector_string_get( actual, 0 ) ) ); libcmis_vector_string_free( actual ); libcmis_object_free( tested ); } void ObjectTest::getBaseTypeTest( ) { libcmis_ObjectPtr tested = getTested( false ); char* actual = libcmis_object_getBaseType( tested ); CPPUNIT_ASSERT_EQUAL( string( "Object::BaseType" ), string( actual ) ); free( actual ); libcmis_object_free( tested ); } void ObjectTest::getTypeTest( ) { libcmis_ObjectPtr tested = getTested( false ); char* actual = libcmis_object_getType( tested ); CPPUNIT_ASSERT_EQUAL( string( "Object::Type" ), string( actual ) ); free( actual ); libcmis_object_free( tested ); } void ObjectTest::getCreatedByTest( ) { libcmis_ObjectPtr tested = getTested( false ); char* actual = libcmis_object_getCreatedBy( tested ); CPPUNIT_ASSERT_EQUAL( string( "Object::CreatedBy" ), string( actual ) ); free( actual ); libcmis_object_free( tested ); } void ObjectTest::getCreationDateTest( ) { libcmis_ObjectPtr tested = getTested( false ); time_t actual = libcmis_object_getCreationDate( tested ); CPPUNIT_ASSERT( 0 != actual ); libcmis_object_free( tested ); } void ObjectTest::getLastModifiedByTest( ) { libcmis_ObjectPtr tested = getTested( false ); char* actual = libcmis_object_getLastModifiedBy( tested ); CPPUNIT_ASSERT_EQUAL( string( "Object::LastModifiedBy" ), string( actual ) ); free( actual ); libcmis_object_free( tested ); } void ObjectTest::getLastModificationDateTest( ) { libcmis_ObjectPtr tested = getTested( false ); time_t actual = libcmis_object_getLastModificationDate( tested ); CPPUNIT_ASSERT( 0 != actual ); libcmis_object_free( tested ); } void ObjectTest::getChangeTokenTest( ) { libcmis_ObjectPtr tested = getTested( false ); char* actual = libcmis_object_getChangeToken( tested ); CPPUNIT_ASSERT_EQUAL( string( "Object::ChangeToken" ), string( actual ) ); free( actual ); libcmis_object_free( tested ); } void ObjectTest::isImmutableTest( ) { libcmis_ObjectPtr tested = getTested( false ); CPPUNIT_ASSERT( libcmis_object_isImmutable( tested ) ); libcmis_object_free( tested ); } void ObjectTest::getPropertiesTest( ) { libcmis_ObjectPtr tested = getTested( false ); libcmis_vector_property_Ptr actual = libcmis_object_getProperties( tested ); CPPUNIT_ASSERT_EQUAL( size_t( 1 ), libcmis_vector_property_size( actual ) ); libcmis_vector_property_free( actual ); libcmis_object_free( tested ); } void ObjectTest::getPropertyTest( ) { libcmis_ObjectPtr tested = getTested( false ); const char* id = "Property1"; libcmis_PropertyPtr actual = libcmis_object_getProperty( tested, id ); CPPUNIT_ASSERT( NULL != actual ); libcmis_property_free( actual ); libcmis_object_free( tested ); } void ObjectTest::getPropertyMissingTest( ) { libcmis_ObjectPtr tested = getTested( false ); const char* id = "MissingProperty"; libcmis_PropertyPtr actual = libcmis_object_getProperty( tested, id ); CPPUNIT_ASSERT( NULL == actual ); libcmis_property_free( actual ); libcmis_object_free( tested ); } void ObjectTest::updatePropertiesTest( ) { libcmis_ObjectPtr tested = getTested( false ); CPPUNIT_ASSERT_MESSAGE( "Timestamp not set to 0 initially", 0 == libcmis_object_getRefreshTimestamp( tested ) ); libcmis_ErrorPtr error = libcmis_error_create( ); // Create the changed properties map libcmis_vector_property_Ptr newProperties = libcmis_vector_property_create( ); libcmis_ObjectTypePtr objectType = libcmis_object_getTypeDescription( tested ); libcmis_PropertyTypePtr propertyType = libcmis_object_type_getPropertyType( objectType, "cmis:Property2" ); size_t size = 2; const char** values = new const char*[size]; values[0] = "Value 1"; values[1] = "Value 2"; libcmis_PropertyPtr newProperty = libcmis_property_create( propertyType, values, size ); delete[ ] values; libcmis_vector_property_append( newProperties, newProperty ); // Update the properties (method under test) libcmis_ObjectPtr updated = libcmis_object_updateProperties( tested, newProperties, error ); // Checks CPPUNIT_ASSERT_MESSAGE( "Timestamp not updated", 0 != libcmis_object_getRefreshTimestamp( tested ) ); CPPUNIT_ASSERT( updated != NULL ); // Free it all libcmis_object_free( updated ); libcmis_property_free( newProperty ); libcmis_property_type_free( propertyType ); libcmis_object_type_free( objectType ); libcmis_vector_property_free( newProperties ); libcmis_error_free( error ); libcmis_object_free( tested ); } void ObjectTest::updatePropertiesErrorTest( ) { libcmis_ObjectPtr tested = getTested( true ); CPPUNIT_ASSERT_MESSAGE( "Timestamp not set to 0 initially", 0 == libcmis_object_getRefreshTimestamp( tested ) ); libcmis_ErrorPtr error = libcmis_error_create( ); // Create the changed properties map libcmis_vector_property_Ptr newProperties = libcmis_vector_property_create( ); libcmis_ObjectTypePtr objectType = libcmis_object_getTypeDescription( tested ); libcmis_PropertyTypePtr propertyType = libcmis_object_type_getPropertyType( objectType, "cmis:Property2" ); size_t size = 2; const char** values = new const char*[size]; values[0] = "Value 1"; values[1] = "Value 2"; libcmis_PropertyPtr newProperty = libcmis_property_create( propertyType, values, size ); delete[ ] values; libcmis_vector_property_append( newProperties, newProperty ); // Update the properties (method under test) libcmis_ObjectPtr updated = libcmis_object_updateProperties( tested, newProperties, error ); // Checks CPPUNIT_ASSERT( updated == NULL ); const char* actualMessage = libcmis_error_getMessage( error ); CPPUNIT_ASSERT( !string( actualMessage ).empty( ) ); // Free it all libcmis_object_free( updated ); libcmis_property_free( newProperty ); libcmis_property_type_free( propertyType ); libcmis_object_type_free( objectType ); libcmis_vector_property_free( newProperties ); libcmis_error_free( error ); libcmis_object_free( tested ); } void ObjectTest::getTypeDescriptionTest( ) { libcmis_ObjectPtr tested = getTested( false ); libcmis_ObjectTypePtr actual = libcmis_object_getTypeDescription( tested ); char* actualId = libcmis_object_type_getId( actual ); CPPUNIT_ASSERT( !string( actualId ).empty( ) ); free( actualId ); libcmis_object_type_free( actual ); libcmis_object_free( tested ); } void ObjectTest::getAllowableActionsTest( ) { libcmis_ObjectPtr tested = getTested( false ); libcmis_AllowableActionsPtr actual = libcmis_object_getAllowableActions( tested ); CPPUNIT_ASSERT( libcmis_allowable_actions_isDefined( actual, libcmis_GetFolderParent ) ); libcmis_allowable_actions_free( actual ); libcmis_object_free( tested ); } void ObjectTest::refreshTest( ) { libcmis_ObjectPtr tested = getTested( false ); CPPUNIT_ASSERT_MESSAGE( "Timestamp not set to 0 initially", 0 == libcmis_object_getRefreshTimestamp( tested ) ); libcmis_ErrorPtr error = libcmis_error_create( ); libcmis_object_refresh( tested, error ); CPPUNIT_ASSERT_MESSAGE( "Timestamp not updated", 0 != libcmis_object_getRefreshTimestamp( tested ) ); libcmis_error_free( error ); libcmis_object_free( tested ); } void ObjectTest::refreshErrorTest( ) { libcmis_ObjectPtr tested = getTested( true ); CPPUNIT_ASSERT_MESSAGE( "Timestamp not set to 0 initially", 0 == libcmis_object_getRefreshTimestamp( tested ) ); libcmis_ErrorPtr error = libcmis_error_create( ); libcmis_object_refresh( tested, error ); const char* actualMessage = libcmis_error_getMessage( error ); CPPUNIT_ASSERT( !string( actualMessage ).empty( ) ); libcmis_error_free( error ); libcmis_object_free( tested ); } void ObjectTest::removeTest( ) { libcmis_ObjectPtr tested = getTested( false ); CPPUNIT_ASSERT_MESSAGE( "Timestamp not set to 0 initially", 0 == libcmis_object_getRefreshTimestamp( tested ) ); libcmis_ErrorPtr error = libcmis_error_create( ); libcmis_object_remove( tested, true, error ); CPPUNIT_ASSERT_MESSAGE( "Timestamp not updated", 0 != libcmis_object_getRefreshTimestamp( tested ) ); libcmis_error_free( error ); libcmis_object_free( tested ); } void ObjectTest::removeErrorTest( ) { libcmis_ObjectPtr tested = getTested( true ); CPPUNIT_ASSERT_MESSAGE( "Timestamp not set to 0 initially", 0 == libcmis_object_getRefreshTimestamp( tested ) ); libcmis_ErrorPtr error = libcmis_error_create( ); libcmis_object_remove( tested, true, error ); const char* actualMessage = libcmis_error_getMessage( error ); CPPUNIT_ASSERT( !string( actualMessage ).empty( ) ); libcmis_error_free( error ); libcmis_object_free( tested ); } void ObjectTest::moveTest( ) { libcmis_ObjectPtr tested = getTested( false ); CPPUNIT_ASSERT_MESSAGE( "Timestamp not set to 0 initially", 0 == libcmis_object_getRefreshTimestamp( tested ) ); libcmis_ErrorPtr error = libcmis_error_create( ); // Move the object from source to dest (tested method) libcmis_FolderPtr source = getTestFolder( ); libcmis_FolderPtr dest = getTestFolder( ); libcmis_object_move( tested, source, dest, error ); // Check CPPUNIT_ASSERT_MESSAGE( "Timestamp not updated", 0 != libcmis_object_getRefreshTimestamp( tested ) ); // Free it all libcmis_folder_free( dest ); libcmis_folder_free( source ); libcmis_error_free( error ); libcmis_object_free( tested ); } void ObjectTest::moveErrorTest( ) { } void ObjectTest::toStringTest( ) { libcmis_ObjectPtr tested = getTested( false ); char* actual = libcmis_object_toString( tested ); CPPUNIT_ASSERT_EQUAL( string( "Object::toString" ), string( actual ) ); free( actual ); libcmis_object_free( tested ); } ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis-c/test-property.cxx��������������������������������������������������������0000664�0001750�0001750�00000021726�13407414352�015726� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <cppunit/extensions/HelperMacros.h> #include <cppunit/TestFixture.h> #include <cppunit/TestAssert.h> #include <libcmis-c/property.h> #include <libcmis-c/property-type.h> #include <libcmis-c/vectors.h> #include "internals.hxx" #include "test-dummies.hxx" using namespace std; class PropertyTest : public CppUnit::TestFixture { private: libcmis_PropertyTypePtr getTestType( string xmlType ); public: void getDateTimesTest( ); void getBoolsTest( ); void getStringsTest( ); void getLongsTest( ); void getDoublesTest( ); void setValuesTest( ); CPPUNIT_TEST_SUITE( PropertyTest ); CPPUNIT_TEST( getDateTimesTest ); CPPUNIT_TEST( getBoolsTest ); CPPUNIT_TEST( getStringsTest ); CPPUNIT_TEST( getLongsTest ); CPPUNIT_TEST( getDoublesTest ); CPPUNIT_TEST( setValuesTest ); CPPUNIT_TEST_SUITE_END( ); }; CPPUNIT_TEST_SUITE_REGISTRATION( PropertyTest ); libcmis_PropertyTypePtr PropertyTest::getTestType( string xmlType ) { libcmis_PropertyTypePtr result = new libcmis_property_type( ); libcmis::PropertyTypePtr handle( new dummies::PropertyType( "Id", xmlType ) ); result->handle = handle; return result; } void PropertyTest::getDateTimesTest( ) { libcmis_PropertyTypePtr type = getTestType( "datetime" ); size_t size = 2; const char** values = new const char*[size]; values[0] = "2012-01-19T09:06:57.388Z"; values[1] = "2012-02-19T09:06:57.388Z"; libcmis_PropertyPtr tested = libcmis_property_create( type, values, size ); libcmis_vector_time_Ptr times = libcmis_property_getDateTimes( tested ); CPPUNIT_ASSERT_EQUAL( size, libcmis_vector_time_size( times ) ); libcmis_vector_time_free( times ); libcmis_vector_string_Ptr strings = libcmis_property_getStrings( tested ); CPPUNIT_ASSERT_EQUAL( size, libcmis_vector_string_size( strings ) ); CPPUNIT_ASSERT_EQUAL( string( values[1] ), string( libcmis_vector_string_get( strings, 1 ) ) ); libcmis_vector_string_free( strings ); delete[] values; libcmis_vector_bool_Ptr bools = libcmis_property_getBools( tested ); CPPUNIT_ASSERT_EQUAL( size_t( 0 ), libcmis_vector_bool_size( bools ) ); libcmis_vector_bool_free( bools ); libcmis_property_free( tested ); libcmis_property_type_free( type ); } void PropertyTest::getBoolsTest( ) { libcmis_PropertyTypePtr type = getTestType( "boolean" ); size_t size = 2; const char** values = new const char*[size]; values[0] = "true"; values[1] = "false"; libcmis_PropertyPtr tested = libcmis_property_create( type, values, size ); libcmis_vector_bool_Ptr bools = libcmis_property_getBools( tested ); CPPUNIT_ASSERT_EQUAL( size, libcmis_vector_bool_size( bools ) ); CPPUNIT_ASSERT_EQUAL( true, libcmis_vector_bool_get( bools, 0 ) ); CPPUNIT_ASSERT_EQUAL( false, libcmis_vector_bool_get( bools, 1 ) ); libcmis_vector_bool_free( bools ); libcmis_vector_string_Ptr strings = libcmis_property_getStrings( tested ); CPPUNIT_ASSERT_EQUAL( size, libcmis_vector_string_size( strings ) ); CPPUNIT_ASSERT_EQUAL( string( values[1] ), string( libcmis_vector_string_get( strings, 1 ) ) ); libcmis_vector_string_free( strings ); delete[] values; libcmis_vector_long_Ptr longs = libcmis_property_getLongs( tested ); CPPUNIT_ASSERT_EQUAL( size_t( 0 ), libcmis_vector_long_size( longs ) ); libcmis_vector_long_free( longs ); libcmis_property_free( tested ); libcmis_property_type_free( type ); } void PropertyTest::getStringsTest( ) { libcmis_PropertyTypePtr type = getTestType( "string" ); size_t size = 2; const char** values = new const char*[size]; values[0] = "string 1"; values[1] = "string 2"; libcmis_PropertyPtr tested = libcmis_property_create( type, values, size ); libcmis_vector_string_Ptr strings = libcmis_property_getStrings( tested ); CPPUNIT_ASSERT_EQUAL( size, libcmis_vector_string_size( strings ) ); CPPUNIT_ASSERT_EQUAL( string( values[0] ), string( libcmis_vector_string_get( strings, 0 ) ) ); CPPUNIT_ASSERT_EQUAL( string( values[1] ), string( libcmis_vector_string_get( strings, 1 ) ) ); libcmis_vector_string_free( strings ); delete[] values; libcmis_vector_double_Ptr doubles = libcmis_property_getDoubles( tested ); CPPUNIT_ASSERT_EQUAL( size_t( 0 ), libcmis_vector_double_size( doubles ) ); libcmis_vector_double_free( doubles ); libcmis_property_free( tested ); libcmis_property_type_free( type ); } void PropertyTest::getLongsTest( ) { libcmis_PropertyTypePtr type = getTestType( "integer" ); size_t size = 2; const char** values = new const char*[size]; values[0] = "123456"; values[1] = "789"; libcmis_PropertyPtr tested = libcmis_property_create( type, values, size ); libcmis_vector_long_Ptr longs = libcmis_property_getLongs( tested ); CPPUNIT_ASSERT_EQUAL( size, libcmis_vector_long_size( longs ) ); CPPUNIT_ASSERT_EQUAL( long( 123456 ), libcmis_vector_long_get( longs, 0 ) ); CPPUNIT_ASSERT_EQUAL( long( 789 ), libcmis_vector_long_get( longs, 1 ) ); libcmis_vector_long_free( longs ); libcmis_vector_string_Ptr strings = libcmis_property_getStrings( tested ); CPPUNIT_ASSERT_EQUAL( size, libcmis_vector_string_size( strings ) ); CPPUNIT_ASSERT_EQUAL( string( values[1] ), string( libcmis_vector_string_get( strings, 1 ) ) ); libcmis_vector_string_free( strings ); delete[] values; libcmis_vector_time_Ptr times = libcmis_property_getDateTimes( tested ); CPPUNIT_ASSERT_EQUAL( size_t( 0 ), libcmis_vector_time_size( times ) ); libcmis_vector_time_free( times ); libcmis_property_free( tested ); libcmis_property_type_free( type ); } void PropertyTest::getDoublesTest( ) { libcmis_PropertyTypePtr type = getTestType( "decimal" ); size_t size = 2; const char** values = new const char*[size]; values[0] = "123.456"; values[1] = "7.89"; libcmis_PropertyPtr tested = libcmis_property_create( type, values, size ); libcmis_vector_double_Ptr doubles = libcmis_property_getDoubles( tested ); CPPUNIT_ASSERT_EQUAL( size, libcmis_vector_double_size( doubles ) ); CPPUNIT_ASSERT_EQUAL( 123.456, libcmis_vector_double_get( doubles, 0 ) ); CPPUNIT_ASSERT_EQUAL( 7.89, libcmis_vector_double_get( doubles, 1 ) ); libcmis_vector_double_free( doubles ); libcmis_vector_string_Ptr strings = libcmis_property_getStrings( tested ); CPPUNIT_ASSERT_EQUAL( size, libcmis_vector_string_size( strings ) ); CPPUNIT_ASSERT_EQUAL( string( values[1] ), string( libcmis_vector_string_get( strings, 1 ) ) ); libcmis_vector_string_free( strings ); delete[] values; libcmis_vector_long_Ptr longs = libcmis_property_getLongs( tested ); CPPUNIT_ASSERT_EQUAL( size_t( 0 ), libcmis_vector_long_size( longs ) ); libcmis_vector_long_free( longs ); libcmis_property_free( tested ); libcmis_property_type_free( type ); } void PropertyTest::setValuesTest( ) { libcmis_PropertyTypePtr type = getTestType( "string" ); size_t size = 1; const char** values = new const char*[size]; values[0] = "string 1"; libcmis_PropertyPtr tested = libcmis_property_create( type, values, size ); delete[] values; size_t newSize = 2; const char** newValues = new const char*[newSize]; newValues[0] = "new string 1"; newValues[1] = "new string 2"; libcmis_property_setValues( tested, newValues, newSize ); libcmis_vector_string_Ptr newStrings = libcmis_property_getStrings( tested ); CPPUNIT_ASSERT_EQUAL( newSize, libcmis_vector_string_size( newStrings ) ); CPPUNIT_ASSERT_EQUAL( string( newValues[0] ), string( libcmis_vector_string_get( newStrings, 0 ) ) ); CPPUNIT_ASSERT_EQUAL( string( newValues[1] ), string( libcmis_vector_string_get( newStrings, 1 ) ) ); libcmis_vector_string_free( newStrings ); delete[] newValues; libcmis_property_free( tested ); libcmis_property_type_free( type ); } ������������������������������������������libcmis-0.5.2/qa/libcmis-c/test-object-type.cxx�����������������������������������������������������0000664�0001750�0001750�00000030637�13407414352�016270� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������ /* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <cppunit/extensions/HelperMacros.h> #include <cppunit/TestFixture.h> #include <cppunit/TestAssert.h> #include <libcmis-c/error.h> #include <libcmis-c/object-type.h> #include <libcmis-c/property-type.h> #include "internals.hxx" #include "test-dummies.hxx" using namespace std; class ObjectTypeTest : public CppUnit::TestFixture { private: libcmis_ObjectTypePtr getTested( bool rootType, bool triggersFaults ); public: void getIdTest( ); void getLocalNameTest( ); void getLocalNamespaceTest( ); void getQueryNameTest( ); void getDisplayNameTest( ); void getDescriptionTest( ); void getParentTypeTest( ); void getParentTypeRootTest( ); void getParentTypeErrorTest( ); void getBaseTypeTest( ); void getBaseTypeErrorTest( ); void getChildrenTest( ); void getChildrenErrorTest( ); void isCreatableTest( ); void isFileableTest( ); void isQueryableTest( ); void isFulltextIndexedTest( ); void isIncludedInSupertypeQueryTest( ); void isControllablePolicyTest( ); void isControllableACLTest( ); void isVersionableTest( ); void getContentStreamAllowedTest( ); void getPropertiesTypesTest( ); void getPropertyTypeTest( ); void toStringTest( ); // TODO Add more tests CPPUNIT_TEST_SUITE( ObjectTypeTest ); CPPUNIT_TEST( getIdTest ); CPPUNIT_TEST( getLocalNameTest ); CPPUNIT_TEST( getLocalNamespaceTest ); CPPUNIT_TEST( getQueryNameTest ); CPPUNIT_TEST( getDisplayNameTest ); CPPUNIT_TEST( getDescriptionTest ); CPPUNIT_TEST( getParentTypeTest ); CPPUNIT_TEST( getParentTypeRootTest ); CPPUNIT_TEST( getParentTypeErrorTest ); CPPUNIT_TEST( getBaseTypeTest ); CPPUNIT_TEST( getBaseTypeErrorTest ); CPPUNIT_TEST( getChildrenTest ); CPPUNIT_TEST( getChildrenErrorTest ); CPPUNIT_TEST( isCreatableTest ); CPPUNIT_TEST( isFileableTest ); CPPUNIT_TEST( isQueryableTest ); CPPUNIT_TEST( isFulltextIndexedTest ); CPPUNIT_TEST( isIncludedInSupertypeQueryTest ); CPPUNIT_TEST( isControllablePolicyTest ); CPPUNIT_TEST( isControllableACLTest ); CPPUNIT_TEST( isVersionableTest ); CPPUNIT_TEST( getContentStreamAllowedTest ); CPPUNIT_TEST( getPropertiesTypesTest ); CPPUNIT_TEST( getPropertyTypeTest ); CPPUNIT_TEST( toStringTest ); CPPUNIT_TEST_SUITE_END( ); }; CPPUNIT_TEST_SUITE_REGISTRATION( ObjectTypeTest ); libcmis_ObjectTypePtr ObjectTypeTest::getTested( bool rootType, bool triggersFaults ) { libcmis_ObjectTypePtr result = new libcmis_object_type( ); libcmis::ObjectTypePtr handle( new dummies::ObjectType( rootType, triggersFaults ) ); result->handle = handle; return result; } void ObjectTypeTest::getIdTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); char* id = libcmis_object_type_getId( tested ); CPPUNIT_ASSERT_EQUAL( string( "ObjectType::Id" ), string( id ) ); free( id ); libcmis_object_type_free( tested ); } void ObjectTypeTest::getLocalNameTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); char* actual = libcmis_object_type_getLocalName( tested ); CPPUNIT_ASSERT_EQUAL( string( "ObjectType::LocalName" ), string( actual ) ); free( actual ); libcmis_object_type_free( tested ); } void ObjectTypeTest::getLocalNamespaceTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); char* actual = libcmis_object_type_getLocalNamespace( tested ); CPPUNIT_ASSERT_EQUAL( string( "ObjectType::LocalNamespace" ), string( actual ) ); free( actual ); libcmis_object_type_free( tested ); } void ObjectTypeTest::getQueryNameTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); char* actual = libcmis_object_type_getQueryName( tested ); CPPUNIT_ASSERT_EQUAL( string( "ObjectType::QueryName" ), string( actual ) ); free( actual ); libcmis_object_type_free( tested ); } void ObjectTypeTest::getDisplayNameTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); char* actual = libcmis_object_type_getDisplayName( tested ); CPPUNIT_ASSERT_EQUAL( string( "ObjectType::DisplayName" ), string( actual ) ); free( actual ); libcmis_object_type_free( tested ); } void ObjectTypeTest::getDescriptionTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); char* actual = libcmis_object_type_getDescription( tested ); CPPUNIT_ASSERT_EQUAL( string( "ObjectType::Description" ), string( actual ) ); free( actual ); libcmis_object_type_free( tested ); } void ObjectTypeTest::getParentTypeTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); libcmis_ErrorPtr error = libcmis_error_create( ); libcmis_ObjectTypePtr parent = libcmis_object_type_getParentType( tested, error ); CPPUNIT_ASSERT( NULL == libcmis_error_getMessage( error ) ); char* id = libcmis_object_type_getId( parent ); CPPUNIT_ASSERT_EQUAL( string( "ParentType::Id" ), string( id ) ); free( id ); libcmis_error_free( error ); libcmis_object_type_free( parent ); libcmis_object_type_free( tested ); } void ObjectTypeTest::getParentTypeRootTest( ) { libcmis_ObjectTypePtr tested = getTested( true, false ); libcmis_ErrorPtr error = libcmis_error_create( ); libcmis_ObjectTypePtr parent = libcmis_object_type_getParentType( tested, error ); CPPUNIT_ASSERT( NULL == libcmis_error_getMessage( error ) ); CPPUNIT_ASSERT( NULL == parent ); libcmis_error_free( error ); libcmis_object_type_free( tested ); } void ObjectTypeTest::getParentTypeErrorTest( ) { libcmis_ObjectTypePtr tested = getTested( false, true ); libcmis_ErrorPtr error = libcmis_error_create( ); libcmis_ObjectTypePtr parent = libcmis_object_type_getParentType( tested, error ); CPPUNIT_ASSERT( NULL != libcmis_error_getMessage( error ) ); CPPUNIT_ASSERT( NULL == parent ); libcmis_error_free( error ); libcmis_object_type_free( tested ); } void ObjectTypeTest::getBaseTypeTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); libcmis_ErrorPtr error = libcmis_error_create( ); libcmis_ObjectTypePtr base = libcmis_object_type_getBaseType( tested, error ); CPPUNIT_ASSERT( NULL == libcmis_error_getMessage( error ) ); char* id = libcmis_object_type_getId( base ); CPPUNIT_ASSERT_EQUAL( string( "RootType::Id" ), string( id ) ); free( id ); libcmis_error_free( error ); libcmis_object_type_free( base ); libcmis_object_type_free( tested ); } void ObjectTypeTest::getBaseTypeErrorTest( ) { libcmis_ObjectTypePtr tested = getTested( false, true ); libcmis_ErrorPtr error = libcmis_error_create( ); libcmis_ObjectTypePtr base = libcmis_object_type_getBaseType( tested, error ); CPPUNIT_ASSERT( NULL != libcmis_error_getMessage( error ) ); CPPUNIT_ASSERT( NULL == base ); libcmis_error_free( error ); libcmis_object_type_free( tested ); } void ObjectTypeTest::getChildrenTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); libcmis_ErrorPtr error = libcmis_error_create( ); libcmis_vector_object_type_Ptr children = libcmis_object_type_getChildren( tested, error ); CPPUNIT_ASSERT( NULL == libcmis_error_getMessage( error ) ); size_t size = libcmis_vector_object_type_size( children ); CPPUNIT_ASSERT_EQUAL( size_t( 2 ), size ); libcmis_error_free( error ); libcmis_vector_object_type_free( children ); libcmis_object_type_free( tested ); } void ObjectTypeTest::getChildrenErrorTest( ) { libcmis_ObjectTypePtr tested = getTested( false, true ); libcmis_ErrorPtr error = libcmis_error_create( ); libcmis_vector_object_type_Ptr children = libcmis_object_type_getChildren( tested, error ); CPPUNIT_ASSERT( NULL != libcmis_error_getMessage( error ) ); CPPUNIT_ASSERT( NULL == children ); libcmis_error_free( error ); libcmis_object_type_free( tested ); } void ObjectTypeTest::isCreatableTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); CPPUNIT_ASSERT( libcmis_object_type_isCreatable( tested ) ); libcmis_object_type_free( tested ); } void ObjectTypeTest::isFileableTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); CPPUNIT_ASSERT( libcmis_object_type_isFileable( tested ) ); libcmis_object_type_free( tested ); } void ObjectTypeTest::isQueryableTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); CPPUNIT_ASSERT( libcmis_object_type_isQueryable( tested ) ); libcmis_object_type_free( tested ); } void ObjectTypeTest::isFulltextIndexedTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); CPPUNIT_ASSERT( libcmis_object_type_isFulltextIndexed( tested ) ); libcmis_object_type_free( tested ); } void ObjectTypeTest::isIncludedInSupertypeQueryTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); CPPUNIT_ASSERT( libcmis_object_type_isIncludedInSupertypeQuery( tested ) ); libcmis_object_type_free( tested ); } void ObjectTypeTest::isControllablePolicyTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); CPPUNIT_ASSERT( libcmis_object_type_isControllablePolicy( tested ) ); libcmis_object_type_free( tested ); } void ObjectTypeTest::isControllableACLTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); CPPUNIT_ASSERT( libcmis_object_type_isControllableACL( tested ) ); libcmis_object_type_free( tested ); } void ObjectTypeTest::isVersionableTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); CPPUNIT_ASSERT( libcmis_object_type_isVersionable( tested ) ); libcmis_object_type_free( tested ); } void ObjectTypeTest::getContentStreamAllowedTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); CPPUNIT_ASSERT_EQUAL( libcmis_Allowed, libcmis_object_type_getContentStreamAllowed( tested ) ); libcmis_object_type_free( tested ); } void ObjectTypeTest::getPropertiesTypesTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); libcmis_vector_property_type_Ptr propertiesTypes = libcmis_object_type_getPropertiesTypes( tested ); CPPUNIT_ASSERT_EQUAL( size_t( 3 ), libcmis_vector_property_type_size( propertiesTypes ) ); libcmis_vector_property_type_free( propertiesTypes ); libcmis_object_type_free( tested ); } void ObjectTypeTest::getPropertyTypeTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); string id( "Property2" ); libcmis_PropertyTypePtr propertyType = libcmis_object_type_getPropertyType( tested, id.c_str( ) ); char* propertyId = libcmis_property_type_getId( propertyType ); CPPUNIT_ASSERT_EQUAL( id, string( propertyId ) ); free( propertyId ); libcmis_property_type_free( propertyType ); libcmis_object_type_free( tested ); } void ObjectTypeTest::toStringTest( ) { libcmis_ObjectTypePtr tested = getTested( false, false ); char* actual = libcmis_object_type_toString( tested ); CPPUNIT_ASSERT_EQUAL( string( "ObjectType::toString" ), string( actual ) ); free( actual ); libcmis_object_type_free( tested ); } �������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis-c/test-dummies.cxx���������������������������������������������������������0000664�0001750�0001750�00000043253�13407414352�015504� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include "test-dummies.hxx" using namespace std; using libcmis::PropertyPtrMap; bool isOutOfMemory = false; /// Ignore all tests results depending on this when running in valgrind void * operator new ( size_t requestedSize ) { if ( isOutOfMemory ) { throw bad_alloc( ); } return malloc( requestedSize ); } void operator delete ( void* ptr ) throw ( ) { free( ptr ); } #if __cplusplus > 201103L void operator delete ( void* ptr, std::size_t ) throw ( ) { free( ptr ); } #endif namespace dummies { Session::Session( ) { } Session::~Session( ) { } libcmis::RepositoryPtr Session::getRepository( ) { libcmis::RepositoryPtr repo( new Repository( ) ); return repo; } bool Session::setRepository( std::string ) { return true; } vector< libcmis::RepositoryPtr > Session::getRepositories( ) { vector< libcmis::RepositoryPtr > repos; libcmis::RepositoryPtr repo1( new Repository( ) ); libcmis::RepositoryPtr repo2( new Repository( ) ); repos.push_back( repo1 ); repos.push_back( repo2 ); return repos; } libcmis::FolderPtr Session::getRootFolder() { libcmis::FolderPtr root( new Folder( true, false ) ); return root; } libcmis::ObjectPtr Session::getObject( string id ) { return getFolder( id ); } libcmis::ObjectPtr Session::getObjectByPath( string path ) { return getFolder( path ); } libcmis::FolderPtr Session::getFolder( string ) { libcmis::FolderPtr result( new Folder( false, false ) ); return result; } libcmis::ObjectTypePtr Session::getType( string ) { libcmis::ObjectTypePtr type( new ObjectType( true, false ) ); return type; } vector< libcmis::ObjectTypePtr > Session::getBaseTypes( ) { vector< libcmis::ObjectTypePtr > types; libcmis::ObjectTypePtr type( new ObjectType( true, false ) ); types.push_back( type ); return types; } std::string Session::getRefreshToken( ) { return string( ); } Repository::Repository( ) : libcmis::Repository( ) { m_id = string( "Repository::Id" ); m_name = string( "Repository::Name" ); m_description = string( "Repository::Description" ); m_vendorName = string( "Repository::VendorName" ); m_productName = string( "Repository::ProductName" ); m_productVersion = string( "Repository::ProductVersion" ); m_rootId = string( "Repository::RootId" ); m_cmisVersionSupported = string( "Repository::CmisVersionSupported" ); m_thinClientUri.reset( new string( "Repository::ThinClientUri" ) ); m_principalAnonymous.reset( new string( "Repository::PrincipalAnonymous" ) ); m_principalAnyone.reset( new string( "Repository::PrincipalAnyone" ) ); } Repository::~Repository( ) { } PropertyType::PropertyType( string id, string xmlType ) : libcmis::PropertyType( ) { setId( id ); setLocalName( string( "PropertyType::LocalName" ) ); setLocalNamespace( string( "PropertyType::LocalNamespace" ) ); setDisplayName( string( "PropertyType::DisplayName" ) ); setQueryName( string( "PropertyType::QueryName" ) ); setTypeFromXml( xmlType ); // Setting true for the tests to see a difference with // the default false result of the tested functions setMultiValued( true ); setUpdatable( true ); setInherited( true ); setRequired( true ); setQueryable( true ); setOrderable( true ); setOpenChoice( true ); } PropertyType::~PropertyType( ) { } AllowableActions::AllowableActions( ) : libcmis::AllowableActions( ) { m_states.insert( pair< libcmis::ObjectAction::Type, bool >( libcmis::ObjectAction::GetProperties, true ) ); m_states.insert( pair< libcmis::ObjectAction::Type, bool >( libcmis::ObjectAction::GetFolderParent, false ) ); } AllowableActions::~AllowableActions( ) { } ObjectType::ObjectType( ) : libcmis::ObjectType( ), m_typeId( ), m_childrenIds( ), m_triggersFaults( false ) { } ObjectType::ObjectType( bool rootType, bool triggersFaults ) : libcmis::ObjectType( ), m_typeId( ), m_childrenIds( ), m_triggersFaults( triggersFaults ) { if ( rootType ) m_typeId = "RootType"; else { m_typeId = "ObjectType"; m_parentTypeId = "ParentType"; m_childrenIds.push_back( "ChildType1" ); m_childrenIds.push_back( "ChildType2" ); } m_baseTypeId = "RootType"; libcmis::PropertyTypePtr propType1( new PropertyType( "Property1", "string" ) ); m_propertiesTypes.insert( pair< string, libcmis::PropertyTypePtr >( propType1->getId( ), propType1 ) ); libcmis::PropertyTypePtr propType2( new PropertyType( "Property2", "string" ) ); m_propertiesTypes.insert( pair< string, libcmis::PropertyTypePtr >( propType2->getId( ), propType2 ) ); libcmis::PropertyTypePtr propType3( new PropertyType( "Property3", "string" ) ); m_propertiesTypes.insert( pair< string, libcmis::PropertyTypePtr >( propType3->getId( ), propType3 ) ); initMembers( ); } void ObjectType::initMembers( ) { m_id = m_typeId + "::Id"; m_localName = m_typeId + "::LocalName"; m_localNamespace = m_typeId + "::LocalNamespace"; m_displayName = m_typeId + "::DisplayName"; m_queryName = m_typeId + "::QueryName"; m_description = m_typeId + "::Description"; m_creatable = true; m_fileable = true; m_queryable = true; m_fulltextIndexed = true; m_includedInSupertypeQuery = true; m_controllablePolicy = true; m_controllableAcl = true; m_versionable = true; m_contentStreamAllowed = libcmis::ObjectType::Allowed; } ObjectType::~ObjectType( ) { } libcmis::ObjectTypePtr ObjectType::getParentType( ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); ObjectType* parent = NULL; if ( !m_parentTypeId.empty( ) ) { parent = new ObjectType( ); parent->m_typeId = m_parentTypeId; parent->m_parentTypeId = m_baseTypeId; parent->m_baseTypeId = m_baseTypeId; parent->m_childrenIds.push_back( m_id ); parent->m_triggersFaults = m_triggersFaults; parent->m_propertiesTypes = m_propertiesTypes; parent->initMembers( ); } libcmis::ObjectTypePtr result( parent ); return result; } libcmis::ObjectTypePtr ObjectType::getBaseType( ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); ObjectType* base = this; if ( m_typeId != m_baseTypeId ) { base = new ObjectType( ); base->m_typeId = m_baseTypeId; base->m_baseTypeId = m_baseTypeId; base->m_childrenIds.push_back( m_id ); base->m_triggersFaults = m_triggersFaults; base->m_propertiesTypes = m_propertiesTypes; base->initMembers( ); } libcmis::ObjectTypePtr result( base ); return result; } vector< libcmis::ObjectTypePtr > ObjectType::getChildren( ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); vector< libcmis::ObjectTypePtr > children; for ( vector< string >::iterator it = m_childrenIds.begin( ); it != m_childrenIds.end( ); ++it ) { ObjectType* child = new ObjectType( ); child->m_typeId = *it; child->m_parentTypeId = m_typeId; child->m_baseTypeId = m_baseTypeId; child->m_triggersFaults = m_triggersFaults; child->m_propertiesTypes = m_propertiesTypes; child->initMembers( ); libcmis::ObjectTypePtr result( child ); children.push_back( result ); } return children; } string ObjectType::toString( ) { return m_typeId + "::toString"; } Object::Object( bool triggersFaults, string type ): libcmis::Object( NULL ), m_type( type ), m_triggersFaults( triggersFaults ) { libcmis::PropertyTypePtr propertyType( new PropertyType( "Property1", "string" ) ); vector< string > values; values.push_back( "Value1" ); libcmis::PropertyPtr property( new libcmis::Property( propertyType, values ) ); m_properties.insert( pair< string, libcmis::PropertyPtr >( propertyType->getId( ), property ) ); } string Object::getId( ) { return m_type + "::Id"; } string Object::getName( ) { return m_type + "::Name"; } vector< string > Object::getPaths( ) { vector< string > paths; paths.push_back( string( "/Path1/" ) ); paths.push_back( string( "/Path2/" ) ); return paths; } string Object::getBaseType( ) { return m_type + "::BaseType"; } string Object::getType( ) { return m_type + "::Type"; } boost::posix_time::ptime Object::getCreationDate( ) { boost::posix_time::ptime now( boost::posix_time::second_clock::local_time( ) ); return now; } boost::posix_time::ptime Object::getLastModificationDate( ) { boost::posix_time::ptime now( boost::posix_time::second_clock::local_time( ) ); return now; } libcmis::ObjectPtr Object::updateProperties( const PropertyPtrMap& ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); time( &m_refreshTimestamp ); libcmis::ObjectPtr result( new Object( false ) ); return result; } libcmis::ObjectTypePtr Object::getTypeDescription( ) { libcmis::ObjectTypePtr type( new ObjectType( false, m_triggersFaults ) ); return type; } libcmis::AllowableActionsPtr Object::getAllowableActions( ) { libcmis::AllowableActionsPtr allowableActions( new AllowableActions( ) ); return allowableActions; } void Object::refresh( ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); time( &m_refreshTimestamp ); } void Object::remove( bool ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); time( &m_refreshTimestamp ); } void Object::move( libcmis::FolderPtr, libcmis::FolderPtr ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); time( &m_refreshTimestamp ); } void Object::toXml( xmlTextWriterPtr ) { } Folder::Folder( bool isRoot, bool triggersFaults ) : libcmis::Object( NULL ), libcmis::Folder( NULL ), dummies::Object( triggersFaults, "Folder" ), m_isRoot( isRoot ) { } libcmis::FolderPtr Folder::getFolderParent( ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); libcmis::FolderPtr parent; if ( !m_isRoot ) parent.reset( new Folder( true, m_triggersFaults ) ); return parent; } vector< libcmis::ObjectPtr > Folder::getChildren( ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); vector< libcmis::ObjectPtr > children; libcmis::ObjectPtr child1( new Object( m_triggersFaults ) ); children.push_back( child1 ); libcmis::ObjectPtr child2( new Object( m_triggersFaults ) ); children.push_back( child2 ); return children; } string Folder::getPath( ) { return string( "/Path/" ); } bool Folder::isRootFolder( ) { return m_isRoot; } libcmis::FolderPtr Folder::createFolder( const PropertyPtrMap& ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); libcmis::FolderPtr created( new Folder( true, m_triggersFaults ) ); return created; } libcmis::DocumentPtr Folder::createDocument( const PropertyPtrMap& properties, boost::shared_ptr< ostream > os, string contentType, string filename ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); dummies::Document* document = new dummies::Document( true, false ); PropertyPtrMap propertiesCopy( properties ); document->getProperties( ).swap( propertiesCopy ); document->setContentStream( os, contentType, filename ); libcmis::DocumentPtr created( document ); return created; } vector< string > Folder::removeTree( bool, libcmis::UnfileObjects::Type, bool ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); time( &m_refreshTimestamp ); vector< string > failed; failed.push_back( "failed 1" ); return failed; } Document::Document( bool isFiled, bool triggersFaults ) : libcmis::Object( NULL ), libcmis::Document( NULL ), dummies::Object( triggersFaults, "Document" ), m_isFiled( isFiled ), m_contentString( "Document::ContentStream" ) { } vector< libcmis::FolderPtr > Document::getParents( ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); vector< libcmis::FolderPtr > parents; if ( m_isFiled ) { libcmis::FolderPtr parent1( new Folder( true, m_triggersFaults ) ); parents.push_back( parent1 ); libcmis::FolderPtr parent2( new Folder( false, m_triggersFaults ) ); parents.push_back( parent2 ); } return parents; } boost::shared_ptr< istream > Document::getContentStream( string /*streamId*/ ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); bool oldOutOfMem = isOutOfMemory; isOutOfMemory = false; boost::shared_ptr< istream > stream( new stringstream( m_contentString ) ); isOutOfMemory = oldOutOfMem; return stream; } void Document::setContentStream( boost::shared_ptr< ostream > os, string, string, bool ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); istream is( os->rdbuf( ) ); stringstream out; is.seekg( 0 ); int bufSize = 2048; char* buf = new char[ bufSize ]; while ( !is.eof( ) ) { is.read( buf, bufSize ); size_t read = is.gcount( ); out.write( buf, read ); } delete[] buf; m_contentString = out.str( ); time( &m_refreshTimestamp ); } string Document::getContentType( ) { return "Document::ContentType"; } string Document::getContentFilename( ) { return "Document::ContentFilename"; } long Document::getContentLength( ) { return long( 12345 ); } libcmis::DocumentPtr Document::checkOut( ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); time( &m_refreshTimestamp ); libcmis::DocumentPtr result( new Document( true, m_triggersFaults ) ); return result; } void Document::cancelCheckout( ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); time( &m_refreshTimestamp ); } libcmis::DocumentPtr Document::checkIn( bool, string, const PropertyPtrMap& properties, boost::shared_ptr< ostream > os, string contentType, string filename ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); m_properties = properties; setContentStream( os, contentType, filename ); time( &m_refreshTimestamp ); return libcmis::DocumentPtr( new Document( true, false ) ); } vector< libcmis::DocumentPtr > Document::getAllVersions( ) { if ( m_triggersFaults ) throw libcmis::Exception( "Fault triggered" ); vector< libcmis::DocumentPtr > versions; libcmis::DocumentPtr version1( new Document( true, false ) ); versions.push_back( version1 ); libcmis::DocumentPtr version2( new Document( true, false ) ); versions.push_back( version2 ); return versions; } } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis-c/test-session.cxx���������������������������������������������������������0000664�0001750�0001750�00000005303�13407414352�015516� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <cppunit/extensions/HelperMacros.h> #include <cppunit/TestFixture.h> #include <cppunit/TestAssert.h> #include <libcmis-c/libcmis-c.h> #include "internals.hxx" #include "test-dummies.hxx" using namespace std; class SessionTest : public CppUnit::TestFixture { private: libcmis_SessionPtr getTested( ); public: void getRepositoriesTest( ); void getBaseTypesTest( ); CPPUNIT_TEST_SUITE( SessionTest ); CPPUNIT_TEST( getRepositoriesTest ); CPPUNIT_TEST( getBaseTypesTest ); CPPUNIT_TEST_SUITE_END( ); }; CPPUNIT_TEST_SUITE_REGISTRATION( SessionTest ); libcmis_SessionPtr SessionTest::getTested( ) { libcmis_SessionPtr result = new libcmis_session(); libcmis::Session* handle = new dummies::Session( ); result->handle = handle; return result; } void SessionTest::getRepositoriesTest( ) { libcmis_SessionPtr session = getTested( ); libcmis_vector_Repository_Ptr repos = libcmis_session_getRepositories( session ); size_t actualSize = libcmis_vector_repository_size( repos ); CPPUNIT_ASSERT_EQUAL( size_t( 2 ), actualSize ); libcmis_vector_repository_free( repos ); libcmis_session_free( session ); } void SessionTest::getBaseTypesTest( ) { libcmis_SessionPtr session = getTested( ); libcmis_ErrorPtr error = libcmis_error_create( ); libcmis_vector_object_type_Ptr types = libcmis_session_getBaseTypes( session, error ); size_t size = libcmis_vector_object_type_size( types ); CPPUNIT_ASSERT_EQUAL( size_t( 1 ), size ); libcmis_error_free( error ); libcmis_vector_object_type_free( types ); libcmis_session_free( session ); } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis-c/test-allowable-actions.cxx�����������������������������������������������0000664�0001750�0001750�00000005300�13407414352�017430� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <cppunit/extensions/HelperMacros.h> #include <cppunit/TestFixture.h> #include <cppunit/TestAssert.h> #include <libcmis-c/allowable-actions.h> #include "internals.hxx" #include "test-dummies.hxx" using namespace std; class AllowableActionsTest : public CppUnit::TestFixture { private: libcmis_AllowableActionsPtr getTested( ); public: void isDefinedTest( ); void isAllowedTest( ); CPPUNIT_TEST_SUITE( AllowableActionsTest ); CPPUNIT_TEST( isDefinedTest ); CPPUNIT_TEST( isAllowedTest ); CPPUNIT_TEST_SUITE_END( ); }; CPPUNIT_TEST_SUITE_REGISTRATION( AllowableActionsTest ); libcmis_AllowableActionsPtr AllowableActionsTest::getTested( ) { libcmis_AllowableActionsPtr result = new libcmis_allowable_actions( ); libcmis::AllowableActionsPtr handle( new dummies::AllowableActions( ) ); result->handle = handle; return result; } void AllowableActionsTest::isDefinedTest( ) { libcmis_AllowableActionsPtr allowableActions = getTested( ); CPPUNIT_ASSERT( !libcmis_allowable_actions_isDefined( allowableActions, libcmis_DeleteObject ) ); CPPUNIT_ASSERT( libcmis_allowable_actions_isDefined( allowableActions, libcmis_GetFolderParent ) ); libcmis_allowable_actions_free( allowableActions ); } void AllowableActionsTest::isAllowedTest( ) { libcmis_AllowableActionsPtr allowableActions = getTested( ); CPPUNIT_ASSERT( libcmis_allowable_actions_isAllowed( allowableActions, libcmis_GetProperties ) ); CPPUNIT_ASSERT( !libcmis_allowable_actions_isAllowed( allowableActions, libcmis_GetFolderParent ) ); libcmis_allowable_actions_free( allowableActions ); } ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis-c/test-folder.cxx����������������������������������������������������������0000664�0001750�0001750�00000036502�13407414352�015313� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <cppunit/extensions/HelperMacros.h> #include <cppunit/TestFixture.h> #include <cppunit/TestAssert.h> #include <libcmis-c/document.h> #include <libcmis-c/error.h> #include <libcmis-c/folder.h> #include <libcmis-c/object.h> #include <libcmis-c/object-type.h> #include <libcmis-c/property.h> #include <libcmis-c/property-type.h> #include <libcmis-c/vectors.h> #include "internals.hxx" #include "test-dummies.hxx" using namespace std; class FolderTest : public CppUnit::TestFixture { private: libcmis_FolderPtr getTested( bool isRoot, bool triggersFaults ); dummies::Document* getDocumentImplementation( libcmis_DocumentPtr document ); public: void objectCastTest( ); void objectCastFailureTest( ); void objectFunctionsTest( ); void getParentTest( ); void getParentRootTest( ); void getParentErrorTest( ); void getChildrenTest( ); void getChildrenErrorTest( ); void getPathTest( ); void createFolderTest( ); void createFolderErrorTest( ); void createDocumentTest( ); void createDocumentErrorTest( ); void removeTreeTest( ); void removeTreeErrorTest( ); CPPUNIT_TEST_SUITE( FolderTest ); CPPUNIT_TEST( objectCastTest ); CPPUNIT_TEST( objectCastFailureTest ); CPPUNIT_TEST( objectFunctionsTest ); CPPUNIT_TEST( getParentTest ); CPPUNIT_TEST( getParentRootTest ); CPPUNIT_TEST( getParentErrorTest ); CPPUNIT_TEST( getChildrenTest ); CPPUNIT_TEST( getChildrenErrorTest ); CPPUNIT_TEST( getPathTest ); CPPUNIT_TEST( createFolderTest ); CPPUNIT_TEST( createFolderErrorTest ); CPPUNIT_TEST( createDocumentTest ); CPPUNIT_TEST( createDocumentErrorTest ); CPPUNIT_TEST( removeTreeTest ); CPPUNIT_TEST( removeTreeErrorTest ); CPPUNIT_TEST_SUITE_END( ); }; CPPUNIT_TEST_SUITE_REGISTRATION( FolderTest ); libcmis_FolderPtr FolderTest::getTested( bool isRoot, bool triggersFaults ) { libcmis_FolderPtr result = new libcmis_folder( ); libcmis::FolderPtr handle( new dummies::Folder( isRoot, triggersFaults ) ); result->handle = handle; return result; } dummies::Document* FolderTest::getDocumentImplementation( libcmis_DocumentPtr document ) { dummies::Document* impl = dynamic_cast< dummies::Document* >( document->handle.get( ) ); return impl; } void FolderTest::objectCastTest( ) { // Create the test object to cast libcmis_ObjectPtr tested = new libcmis_object( ); libcmis::FolderPtr handle( new dummies::Folder( false, false ) ); tested->handle = handle; // Test libcmis_is_folder CPPUNIT_ASSERT( libcmis_is_folder( tested ) ); // Actually cast to a folder libcmis_FolderPtr actual = libcmis_folder_cast( tested ); // Check the result CPPUNIT_ASSERT( NULL != actual ); // Check that the libcmis_object-* functions are working with the cast result char* actualId = libcmis_object_getId( tested ); CPPUNIT_ASSERT_EQUAL( string( "Folder::Id" ), string( actualId ) ); free( actualId ); // Free it all libcmis_folder_free( actual ); libcmis_object_free( tested ); } void FolderTest::objectCastFailureTest( ) { // Create the test object to cast libcmis_ObjectPtr tested = new libcmis_object( ); libcmis::DocumentPtr handle( new dummies::Document( true, false ) ); tested->handle = handle; // Test libcmis_is_folder CPPUNIT_ASSERT( !libcmis_is_folder( tested ) ); // Actually cast to a folder libcmis_FolderPtr actual = libcmis_folder_cast( tested ); // Check the result CPPUNIT_ASSERT( NULL == actual ); libcmis_object_free( tested ); } void FolderTest::objectFunctionsTest( ) { libcmis_FolderPtr tested = getTested( false, false ); char* actual = libcmis_object_getId( tested ); CPPUNIT_ASSERT_EQUAL( string( "Folder::Id" ), string( actual ) ); free( actual ); libcmis_folder_free( tested ); } void FolderTest::getParentTest( ) { libcmis_FolderPtr tested = getTested( false, false ); libcmis_ErrorPtr error = libcmis_error_create( ); libcmis_FolderPtr parent = libcmis_folder_getParent( tested, error ); CPPUNIT_ASSERT( NULL != parent ); CPPUNIT_ASSERT( !libcmis_folder_isRootFolder( tested ) ); libcmis_folder_free( parent ); libcmis_error_free( error ); libcmis_folder_free( tested ); } void FolderTest::getParentRootTest( ) { libcmis_FolderPtr tested = getTested( true, false ); libcmis_ErrorPtr error = libcmis_error_create( ); libcmis_FolderPtr parent = libcmis_folder_getParent( tested, error ); CPPUNIT_ASSERT( NULL == parent ); CPPUNIT_ASSERT( libcmis_folder_isRootFolder( tested ) ); libcmis_error_free( error ); libcmis_folder_free( tested ); } void FolderTest::getParentErrorTest( ) { libcmis_FolderPtr tested = getTested( false, true ); libcmis_ErrorPtr error = libcmis_error_create( ); libcmis_FolderPtr parent = libcmis_folder_getParent( tested, error ); CPPUNIT_ASSERT( NULL == parent ); const char* actualMessage = libcmis_error_getMessage( error ); CPPUNIT_ASSERT( !string( actualMessage ).empty( ) ); libcmis_error_free( error ); libcmis_folder_free( tested ); } void FolderTest::getChildrenTest( ) { libcmis_FolderPtr tested = getTested( false, false ); libcmis_ErrorPtr error = libcmis_error_create( ); libcmis_vector_object_Ptr children = libcmis_folder_getChildren( tested, error ); CPPUNIT_ASSERT_EQUAL( size_t( 2 ), libcmis_vector_object_size( children ) ); libcmis_vector_object_free( children ); libcmis_error_free( error ); libcmis_folder_free( tested ); } void FolderTest::getChildrenErrorTest( ) { libcmis_FolderPtr tested = getTested( false, true ); libcmis_ErrorPtr error = libcmis_error_create( ); libcmis_vector_object_Ptr children = libcmis_folder_getChildren( tested, error ); CPPUNIT_ASSERT( NULL == children ); const char* actualMessage = libcmis_error_getMessage( error ); CPPUNIT_ASSERT( !string( actualMessage ).empty( ) ); libcmis_error_free( error ); libcmis_folder_free( tested ); } void FolderTest::getPathTest( ) { libcmis_FolderPtr tested = getTested( false, false ); char* actual = libcmis_folder_getPath( tested ); CPPUNIT_ASSERT_EQUAL( string( "/Path/" ), string( actual ) ); free( actual ); libcmis_folder_free( tested ); } void FolderTest::createFolderTest( ) { libcmis_FolderPtr tested = getTested( false, false ); libcmis_ErrorPtr error = libcmis_error_create( ); // Create the properties for the new folder libcmis_vector_property_Ptr properties = libcmis_vector_property_create( ); libcmis_ObjectTypePtr objectType = libcmis_object_getTypeDescription( tested ); const char* id = "Property1"; libcmis_PropertyTypePtr propertyType = libcmis_object_type_getPropertyType( objectType, id ); size_t size = 2; const char** values = new const char*[size]; values[0] = "Value 1"; values[1] = "Value 2"; libcmis_PropertyPtr property = libcmis_property_create( propertyType, values, size ); delete[] values; libcmis_vector_property_append( properties, property ); // Create the new folder (method to test) libcmis_FolderPtr created = libcmis_folder_createFolder( tested, properties, error ); // Check CPPUNIT_ASSERT( NULL != created ); // Free everything libcmis_folder_free( created ); libcmis_property_free( property ); libcmis_property_type_free( propertyType ); libcmis_object_type_free( objectType ); libcmis_vector_property_free( properties ); libcmis_error_free( error ); libcmis_folder_free( tested ); } void FolderTest::createFolderErrorTest( ) { libcmis_FolderPtr tested = getTested( false, true ); libcmis_ErrorPtr error = libcmis_error_create( ); // Create the properties for the new folder libcmis_vector_property_Ptr properties = libcmis_vector_property_create( ); libcmis_ObjectTypePtr objectType = libcmis_object_getTypeDescription( tested ); const char* id = "Property1"; libcmis_PropertyTypePtr propertyType = libcmis_object_type_getPropertyType( objectType, id ); size_t size = 2; const char** values = new const char*[size]; values[0] = "Value 1"; values[1] = "Value 2"; libcmis_PropertyPtr property = libcmis_property_create( propertyType, values, size ); delete[] values; libcmis_vector_property_append( properties, property ); // Create the new folder (method to test) libcmis_FolderPtr created = libcmis_folder_createFolder( tested, properties, error ); // Check CPPUNIT_ASSERT( NULL == created ); const char* actualMessage = libcmis_error_getMessage( error ); CPPUNIT_ASSERT( !string( actualMessage ).empty( ) ); // Free everything libcmis_folder_free( created ); libcmis_property_free( property ); libcmis_property_type_free( propertyType ); libcmis_object_type_free( objectType ); libcmis_vector_property_free( properties ); libcmis_error_free( error ); libcmis_folder_free( tested ); } void FolderTest::createDocumentTest( ) { libcmis_FolderPtr tested = getTested( true, false ); libcmis_ErrorPtr error = libcmis_error_create( ); // Prepare the content to set FILE* tmp = tmpfile( ); string expectedStream( "New Content Stream" ); fwrite( expectedStream.c_str( ), 1, expectedStream.size( ), tmp ); rewind( tmp ); // Create the properties for the new version libcmis_vector_property_Ptr properties = libcmis_vector_property_create( ); libcmis_ObjectTypePtr objectType = libcmis_object_getTypeDescription( tested ); const char* id = "Property1"; libcmis_PropertyTypePtr propertyType = libcmis_object_type_getPropertyType( objectType, id ); size_t size = 2; const char** values = new const char*[size]; values[0] = "Value 1"; values[1] = "Value 2"; libcmis_PropertyPtr property = libcmis_property_create( propertyType, values, size ); delete[] values; libcmis_vector_property_append( properties, property ); // get the content into a temporary file (tested method) const char* contentType = "content/type"; const char* filename = "name.txt"; libcmis_DocumentPtr actual = libcmis_folder_createDocument( tested, properties, ( libcmis_readFn )fread, tmp, contentType, filename, error ); fclose( tmp ); // Check string actualStream = getDocumentImplementation( actual )->getContentString( ); CPPUNIT_ASSERT( NULL == libcmis_error_getMessage( error ) ); CPPUNIT_ASSERT_EQUAL( expectedStream, actualStream ); libcmis_PropertyPtr checkedProperty = libcmis_object_getProperty( actual, "Property1" ); libcmis_vector_string_Ptr newValues = libcmis_property_getStrings( checkedProperty ); CPPUNIT_ASSERT_EQUAL( size_t( 2 ), libcmis_vector_string_size( newValues ) ); // Free it all libcmis_vector_string_free( newValues ); libcmis_property_free( checkedProperty ); libcmis_document_free( actual ); libcmis_property_free( property ); libcmis_property_type_free( propertyType ); libcmis_object_type_free( objectType ); libcmis_vector_property_free( properties ); libcmis_error_free( error ); libcmis_folder_free( tested ); } void FolderTest::createDocumentErrorTest( ) { libcmis_FolderPtr tested = getTested( true, true ); libcmis_ErrorPtr error = libcmis_error_create( ); // Prepare the content to set FILE* tmp = tmpfile( ); string newStream( "New Content Stream" ); fwrite( newStream.c_str( ), 1, newStream.size( ), tmp ); rewind( tmp ); // Create the properties for the new version libcmis_vector_property_Ptr properties = libcmis_vector_property_create( ); libcmis_ObjectTypePtr objectType = libcmis_object_getTypeDescription( tested ); const char* id = "Property1"; libcmis_PropertyTypePtr propertyType = libcmis_object_type_getPropertyType( objectType, id ); size_t size = 2; const char** values = new const char*[size]; values[0] = "Value 1"; values[1] = "Value 2"; libcmis_PropertyPtr property = libcmis_property_create( propertyType, values, size ); delete[] values; libcmis_vector_property_append( properties, property ); // get the content into a temporary file (tested method) const char* contentType = "content/type"; const char* filename = "name.txt"; libcmis_DocumentPtr actual = libcmis_folder_createDocument( tested, properties, ( libcmis_readFn )fread, tmp, contentType, filename, error ); fclose( tmp ); // Check CPPUNIT_ASSERT( !string( libcmis_error_getMessage( error ) ).empty( ) ); CPPUNIT_ASSERT( NULL == actual ); // Free it all libcmis_property_free( property ); libcmis_property_type_free( propertyType ); libcmis_object_type_free( objectType ); libcmis_vector_property_free( properties ); libcmis_error_free( error ); libcmis_folder_free( tested ); } void FolderTest::removeTreeTest( ) { libcmis_FolderPtr tested = getTested( false, false ); libcmis_ErrorPtr error = libcmis_error_create( ); CPPUNIT_ASSERT_MESSAGE( "Timestamp not set to 0 initially", 0 == libcmis_object_getRefreshTimestamp( tested ) ); // Remove the tree (method to test) libcmis_vector_string_Ptr failed = libcmis_folder_removeTree( tested, true, libcmis_Delete, true, error ); // Check CPPUNIT_ASSERT_MESSAGE( "Timestamp not updated", 0 != libcmis_object_getRefreshTimestamp( tested ) ); CPPUNIT_ASSERT_EQUAL( size_t( 1 ), libcmis_vector_string_size( failed ) ); CPPUNIT_ASSERT_EQUAL( string( "failed 1" ), string( libcmis_vector_string_get( failed, 0 ) ) ); // Free everything libcmis_vector_string_free( failed ); libcmis_error_free( error ); libcmis_folder_free( tested ); } void FolderTest::removeTreeErrorTest( ) { libcmis_FolderPtr tested = getTested( false, true ); libcmis_ErrorPtr error = libcmis_error_create( ); // Remove the tree (method to test) libcmis_vector_string_Ptr failed = libcmis_folder_removeTree( tested, true, libcmis_Delete, true, error ); // Check const char* actualMessage = libcmis_error_getMessage( error ); CPPUNIT_ASSERT( !string( actualMessage ).empty( ) ); // Free everything libcmis_vector_string_free( failed ); libcmis_error_free( error ); libcmis_folder_free( tested ); } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis-c/test-dummies.hxx���������������������������������������������������������0000664�0001750�0001750�00000020105�13407414352�015500� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #ifndef _LIBCMIS_TEST_DUMMIES_HXX_ #define _LIBCMIS_TEST_DUMMIES_HXX_ #include <libcmis/allowable-actions.hxx> #include <libcmis/document.hxx> #include <libcmis/folder.hxx> #include <libcmis/object.hxx> #include <libcmis/object-type.hxx> #include <libcmis/property-type.hxx> #include <libcmis/repository.hxx> #include <libcmis/session.hxx> /** This namespace contains dummy classes to simulate the libcmis layer in the libcmis-c unit tests. */ namespace dummies { class Session : public libcmis::Session { public: Session( ); ~Session( ); virtual libcmis::RepositoryPtr getRepository( ); virtual bool setRepository( std::string repositoryId ); virtual std::vector< libcmis::RepositoryPtr > getRepositories( ); virtual libcmis::FolderPtr getRootFolder(); virtual libcmis::ObjectPtr getObject( std::string id ); virtual libcmis::ObjectPtr getObjectByPath( std::string path ); virtual libcmis::FolderPtr getFolder( std::string id ); virtual libcmis::ObjectTypePtr getType( std::string id ); virtual std::vector< libcmis::ObjectTypePtr > getBaseTypes( ); virtual std::string getRefreshToken( ); virtual void setNoSSLCertificateCheck( bool /*noCheck*/ ) { } }; class Repository : public libcmis::Repository { public: Repository( ); ~Repository( ); }; class PropertyType : public libcmis::PropertyType { public: PropertyType( std::string id, std::string xmlType ); ~PropertyType( ); }; /** Dummy for testing the C API for allowable actions. The dummy has only the following actions defined: \li \c GetProperties, defined to \c true \li \c GetFolderParent, defined to \c false */ class AllowableActions : public libcmis::AllowableActions { public: AllowableActions( ); ~AllowableActions( ); }; class ObjectType : public libcmis::ObjectType { private: std::string m_typeId; std::vector< std::string > m_childrenIds; bool m_triggersFaults; ObjectType( ); void initMembers( ); public: ObjectType( bool rootType, bool triggersFaults ); ~ObjectType( ); virtual boost::shared_ptr< libcmis::ObjectType > getParentType( ); virtual boost::shared_ptr< libcmis::ObjectType > getBaseType( ); virtual std::vector< boost::shared_ptr< libcmis::ObjectType > > getChildren( ); virtual std::string toString( ); }; class Object : public virtual libcmis::Object { public: std::string m_type; bool m_triggersFaults; public: Object( bool triggersFaults, std::string m_type = "Object" ); ~Object( ) { } virtual std::string getId( ); virtual std::string getName( ); virtual std::vector< std::string > getPaths( ); virtual std::string getBaseType( ); virtual std::string getType( ); virtual std::string getCreatedBy( ) { return m_type + "::CreatedBy"; } virtual boost::posix_time::ptime getCreationDate( ); virtual std::string getLastModifiedBy( ) { return m_type + "::LastModifiedBy"; } virtual boost::posix_time::ptime getLastModificationDate( ); virtual std::string getChangeToken( ) { return m_type + "::ChangeToken"; } virtual bool isImmutable( ) { return true; }; virtual libcmis::ObjectPtr updateProperties( const std::map< std::string, libcmis::PropertyPtr >& properties ); virtual libcmis::ObjectTypePtr getTypeDescription( ); virtual libcmis::AllowableActionsPtr getAllowableActions( ); virtual void refresh( ); virtual void remove( bool allVersions = true ); virtual void move( libcmis::FolderPtr source, libcmis::FolderPtr destination ); virtual std::string toString( ) { return m_type + "::toString"; } virtual void toXml( xmlTextWriterPtr writer ); }; class Folder : public libcmis::Folder, public Object { private: bool m_isRoot; public: Folder( bool isRoot, bool triggersFaults ); ~Folder( ) { } virtual libcmis::FolderPtr getFolderParent( ); virtual std::vector< libcmis::ObjectPtr > getChildren( ); virtual std::string getPath( ); virtual bool isRootFolder( ); virtual libcmis::FolderPtr createFolder( const std::map< std::string, libcmis::PropertyPtr >& properties ); virtual libcmis::DocumentPtr createDocument( const std::map< std::string, libcmis::PropertyPtr >& properties, boost::shared_ptr< std::ostream > os, std::string contentType, std::string filename ); virtual std::vector< std::string > removeTree( bool allVersion = true, libcmis::UnfileObjects::Type unfile = libcmis::UnfileObjects::Delete, bool continueOnError = false ); virtual std::vector< std::string > getPaths( ) { return dummies::Object::getPaths( ); } virtual std::string toString( ) { return dummies::Object::toString( ); } }; class Document : public libcmis::Document, public Object { private: bool m_isFiled; std::string m_contentString; public: Document( bool isFiled, bool triggersFaults ); ~Document( ) { } std::string getContentString( ) { return m_contentString; } virtual std::vector< libcmis::FolderPtr > getParents( ); virtual boost::shared_ptr< std::istream > getContentStream( std::string streamId = std::string( ) ); virtual void setContentStream( boost::shared_ptr< std::ostream > os, std::string contentType, std::string fileName, bool overwrite = true ); virtual std::string getContentType( ); virtual std::string getContentFilename( ); virtual long getContentLength( ); virtual libcmis::DocumentPtr checkOut( ); virtual void cancelCheckout( ); virtual libcmis::DocumentPtr checkIn( bool isMajor, std::string comment, const std::map< std::string, libcmis::PropertyPtr >& properties, boost::shared_ptr< std::ostream > stream, std::string contentType, std::string filename ); virtual std::vector< libcmis::DocumentPtr > getAllVersions( ); virtual std::vector< std::string > getPaths( ) { return dummies::Object::getPaths( ); } virtual std::string toString( ) { return dummies::Object::toString( ); } }; } #endif �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis-c/test-document.cxx��������������������������������������������������������0000664�0001750�0001750�00000050412�13407757456�015671� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <cppunit/extensions/HelperMacros.h> #include <cppunit/TestFixture.h> #include <cppunit/TestAssert.h> #include <libcmis-c/error.h> #include <libcmis-c/folder.h> #include <libcmis-c/document.h> #include <libcmis-c/object.h> #include <libcmis-c/object-type.h> #include <libcmis-c/property.h> #include <libcmis-c/property-type.h> #include <libcmis-c/vectors.h> #include "internals.hxx" #include "test-dummies.hxx" using namespace std; extern bool isOutOfMemory; namespace { string lcl_readFile( FILE* file ) { // Get the size fseek( file, 0, SEEK_END ); long size = ftell( file ); rewind( file ); char* buf = new char[size + 1]; size_t readbytes = fread( buf, 1, size, file ); buf[ readbytes ] = '\0'; string result( buf ); delete[] buf; return result; } } class DocumentTest : public CppUnit::TestFixture { private: libcmis_DocumentPtr getTested( bool isFiled, bool triggersFaults ); dummies::Document* getTestedImplementation( libcmis_DocumentPtr document ); public: void objectCastTest( ); void objectCastFailureTest( ); void objectFunctionsTest( ); void getParentsTest( ); void getParentsUnfiledTest( ); void getParentsErrorTest( ); void getContentStreamTest( ); void getContentStreamErrorTest( ); void getContentStreamBadAllocTest( ); void setContentStreamTest( ); void setContentStreamErrorTest( ); void getContentTypeTest( ); void getContentFilenameTest( ); void getContentLengthTest( ); void checkOutTest( ); void checkOutErrorTest( ); void cancelCheckoutTest( ); void cancelCheckoutErrorTest( ); void checkInTest( ); void checkInErrorTest( ); void getAllVersionsTest( ); void getAllVersionsErrorTest( ); CPPUNIT_TEST_SUITE( DocumentTest ); CPPUNIT_TEST( objectCastTest ); CPPUNIT_TEST( objectCastFailureTest ); CPPUNIT_TEST( objectFunctionsTest ); CPPUNIT_TEST( getParentsTest ); CPPUNIT_TEST( getParentsUnfiledTest ); CPPUNIT_TEST( getParentsErrorTest ); CPPUNIT_TEST( getContentStreamTest ); CPPUNIT_TEST( getContentStreamErrorTest ); CPPUNIT_TEST( getContentStreamBadAllocTest ); CPPUNIT_TEST( setContentStreamTest ); CPPUNIT_TEST( setContentStreamErrorTest ); CPPUNIT_TEST( getContentTypeTest ); CPPUNIT_TEST( getContentFilenameTest ); CPPUNIT_TEST( getContentLengthTest ); CPPUNIT_TEST( checkOutTest ); CPPUNIT_TEST( checkOutErrorTest ); CPPUNIT_TEST( cancelCheckoutTest ); CPPUNIT_TEST( cancelCheckoutErrorTest ); CPPUNIT_TEST( checkInTest ); CPPUNIT_TEST( checkInErrorTest ); CPPUNIT_TEST( getAllVersionsTest ); CPPUNIT_TEST( getAllVersionsErrorTest ); CPPUNIT_TEST_SUITE_END( ); }; CPPUNIT_TEST_SUITE_REGISTRATION( DocumentTest ); libcmis_DocumentPtr DocumentTest::getTested( bool isFiled, bool triggersFaults ) { // Create the document libcmis_DocumentPtr result = new libcmis_document( ); libcmis::DocumentPtr handle( new dummies::Document( isFiled, triggersFaults ) ); result->handle = handle; return result; } dummies::Document* DocumentTest::getTestedImplementation( libcmis_DocumentPtr document ) { dummies::Document* impl = dynamic_cast< dummies::Document* >( document->handle.get( ) ); return impl; } void DocumentTest::objectCastTest( ) { // Create the test object to cast libcmis_ObjectPtr tested = new libcmis_object( ); libcmis::DocumentPtr handle( new dummies::Document( true, false ) ); tested->handle = handle; // Test libcmis_is_document CPPUNIT_ASSERT( libcmis_is_document( tested ) ); // Actually cast to a document libcmis_DocumentPtr actual = libcmis_document_cast( tested ); // Check the result CPPUNIT_ASSERT( NULL != actual ); // Check that the libcmis_object-* functions are working with the cast result char* actualId = libcmis_object_getId( tested ); CPPUNIT_ASSERT_EQUAL( string( "Document::Id" ), string( actualId ) ); free( actualId ); // Free it all libcmis_document_free( actual ); libcmis_object_free( tested ); } void DocumentTest::objectCastFailureTest( ) { // Create the test object to cast libcmis_ObjectPtr tested = new libcmis_object( ); libcmis::FolderPtr handle( new dummies::Folder( false, false ) ); tested->handle = handle; // Test libcmis_is_document CPPUNIT_ASSERT( !libcmis_is_document( tested ) ); // Actually cast to a document libcmis_DocumentPtr actual = libcmis_document_cast( tested ); // Check the result CPPUNIT_ASSERT( NULL == actual ); libcmis_object_free( tested ); } void DocumentTest::objectFunctionsTest( ) { libcmis_DocumentPtr tested = getTested( true, false ); char* actual = libcmis_object_getId( tested ); CPPUNIT_ASSERT_EQUAL( string( "Document::Id" ), string( actual ) ); free( actual ); libcmis_document_free( tested ); } void DocumentTest::getParentsTest( ) { libcmis_DocumentPtr tested = getTested( true, false ); libcmis_ErrorPtr error = libcmis_error_create( ); // get the parent folders (tested method) libcmis_vector_folder_Ptr actual = libcmis_document_getParents( tested, error ); // Check CPPUNIT_ASSERT_EQUAL( size_t( 2 ), libcmis_vector_folder_size( actual ) ); // Free it all libcmis_vector_folder_free( actual ); libcmis_error_free( error ); libcmis_document_free( tested ); } void DocumentTest::getParentsUnfiledTest( ) { libcmis_DocumentPtr tested = getTested( false, false ); libcmis_ErrorPtr error = libcmis_error_create( ); // get the parent folders (tested method) libcmis_vector_folder_Ptr actual = libcmis_document_getParents( tested, error ); // Check CPPUNIT_ASSERT_EQUAL( size_t( 0 ), libcmis_vector_folder_size( actual ) ); // Free it all libcmis_vector_folder_free( actual ); libcmis_error_free( error ); libcmis_document_free( tested ); } void DocumentTest::getParentsErrorTest( ) { libcmis_DocumentPtr tested = getTested( true, true ); libcmis_ErrorPtr error = libcmis_error_create( ); // get the parent folders (tested method) libcmis_vector_folder_Ptr actual = libcmis_document_getParents( tested, error ); // Check CPPUNIT_ASSERT( NULL == actual ); CPPUNIT_ASSERT( !string( libcmis_error_getMessage( error ) ).empty( ) ); // Free it all libcmis_vector_folder_free( actual ); libcmis_error_free( error ); libcmis_document_free( tested ); } void DocumentTest::getContentStreamTest( ) { libcmis_DocumentPtr tested = getTested( true, false ); libcmis_ErrorPtr error = libcmis_error_create( ); // get the content into a temporary file (tested method) FILE* tmp = tmpfile( ); libcmis_document_getContentStream( tested, ( libcmis_writeFn )fwrite, tmp, error ); // Check string expected = getTestedImplementation( tested )->getContentString( ); string actual = lcl_readFile( tmp ); fclose( tmp ); CPPUNIT_ASSERT( NULL == libcmis_error_getMessage( error ) ); CPPUNIT_ASSERT_EQUAL( expected, actual ); // Free it all libcmis_error_free( error ); libcmis_document_free( tested ); } void DocumentTest::getContentStreamErrorTest( ) { libcmis_DocumentPtr tested = getTested( true, true ); libcmis_ErrorPtr error = libcmis_error_create( ); // get the content into a temporary file (tested method) FILE* tmp = tmpfile( ); libcmis_document_getContentStream( tested, ( libcmis_writeFn )fwrite, tmp, error ); // Check string actual = lcl_readFile( tmp ); fclose( tmp ); CPPUNIT_ASSERT_EQUAL( string( ), actual ); CPPUNIT_ASSERT( !string( libcmis_error_getMessage( error ) ).empty( ) ); // Free it all libcmis_error_free( error ); libcmis_document_free( tested ); } void DocumentTest::getContentStreamBadAllocTest( ) { libcmis_DocumentPtr tested = getTested( true, false ); libcmis_ErrorPtr error = libcmis_error_create( ); // get the content into a temporary file (tested method) FILE* tmp = tmpfile( ); isOutOfMemory= true; libcmis_document_getContentStream( tested, ( libcmis_writeFn )fwrite, tmp, error ); isOutOfMemory = false; // Check string actual = lcl_readFile( tmp ); fclose( tmp ); CPPUNIT_ASSERT( !string( libcmis_error_getMessage( error ) ).empty() ); CPPUNIT_ASSERT_EQUAL( string( ), actual ); // Free it all libcmis_error_free( error ); libcmis_document_free( tested ); } void DocumentTest::setContentStreamTest( ) { libcmis_DocumentPtr tested = getTested( true, false ); libcmis_ErrorPtr error = libcmis_error_create( ); // Prepare the content to set FILE* tmp = tmpfile( ); string expected( "New Content Stream" ); fwrite( expected.c_str( ), 1, expected.size( ), tmp ); rewind( tmp ); // get the content into a temporary file (tested method) const char* contentType = "content/type"; const char* filename = "name.txt"; libcmis_document_setContentStream( tested, ( libcmis_readFn )fread, tmp, contentType, filename, true, error ); fclose( tmp ); // Check string actual = getTestedImplementation( tested )->getContentString( ); CPPUNIT_ASSERT( NULL == libcmis_error_getMessage( error ) ); CPPUNIT_ASSERT_EQUAL( expected, actual ); // Free it all libcmis_error_free( error ); libcmis_document_free( tested ); } void DocumentTest::setContentStreamErrorTest( ) { libcmis_DocumentPtr tested = getTested( true, true ); libcmis_ErrorPtr error = libcmis_error_create( ); string expected = getTestedImplementation( tested )->getContentString( ); // Prepare the content to set FILE* tmp = tmpfile( ); string newContent( "New Content Stream" ); fwrite( newContent.c_str( ), 1, newContent.size( ), tmp ); rewind( tmp ); // get the content into a temporary file (tested method) const char* contentType = "content/type"; const char* filename = "name.txt"; libcmis_document_setContentStream( tested, ( libcmis_readFn )fread, tmp, contentType, filename, true, error ); fclose( tmp ); // Check string actual = getTestedImplementation( tested )->getContentString( ); CPPUNIT_ASSERT( !string( libcmis_error_getMessage( error ) ).empty( ) ); CPPUNIT_ASSERT_EQUAL( expected, actual ); // Free it all libcmis_error_free( error ); libcmis_document_free( tested ); } void DocumentTest::getContentTypeTest( ) { libcmis_DocumentPtr tested = getTested( true, false ); char* actual = libcmis_document_getContentType( tested ); CPPUNIT_ASSERT_EQUAL( string( "Document::ContentType" ), string( actual ) ); free( actual ); libcmis_document_free( tested ); } void DocumentTest::getContentFilenameTest( ) { libcmis_DocumentPtr tested = getTested( true, false ); char* actual = libcmis_document_getContentFilename( tested ); CPPUNIT_ASSERT_EQUAL( string( "Document::ContentFilename" ), string( actual ) ); free( actual ); libcmis_document_free( tested ); } void DocumentTest::getContentLengthTest( ) { libcmis_DocumentPtr tested = getTested( true, false ); long actual = libcmis_document_getContentLength( tested ); CPPUNIT_ASSERT( 0 != actual ); libcmis_document_free( tested ); } void DocumentTest::checkOutTest( ) { libcmis_DocumentPtr tested = getTested( true, false ); libcmis_ErrorPtr error = libcmis_error_create( ); // checkout a private working copy (tested method) libcmis_DocumentPtr actual = libcmis_document_checkOut( tested, error ); // Check CPPUNIT_ASSERT( NULL != actual ); // Free it all libcmis_document_free( actual ); libcmis_error_free( error ); libcmis_document_free( tested ); } void DocumentTest::checkOutErrorTest( ) { libcmis_DocumentPtr tested = getTested( true, true ); libcmis_ErrorPtr error = libcmis_error_create( ); // checkout a private working copy (tested method) libcmis_DocumentPtr actual = libcmis_document_checkOut( tested, error ); // Check CPPUNIT_ASSERT( NULL == actual ); CPPUNIT_ASSERT( !string( libcmis_error_getMessage( error ) ).empty( ) ); // Free it all libcmis_document_free( actual ); libcmis_error_free( error ); libcmis_document_free( tested ); } void DocumentTest::cancelCheckoutTest( ) { libcmis_DocumentPtr tested = getTested( true, false ); libcmis_ErrorPtr error = libcmis_error_create( ); // checkout a private working copy (tested method) libcmis_document_cancelCheckout( tested, error ); // Check CPPUNIT_ASSERT( 0 != libcmis_object_getRefreshTimestamp( tested ) ); // Free it all libcmis_error_free( error ); libcmis_document_free( tested ); } void DocumentTest::cancelCheckoutErrorTest( ) { libcmis_DocumentPtr tested = getTested( true, true ); libcmis_ErrorPtr error = libcmis_error_create( ); // checkout a private working copy (tested method) libcmis_document_cancelCheckout( tested, error ); // Check CPPUNIT_ASSERT( 0 == libcmis_object_getRefreshTimestamp( tested ) ); CPPUNIT_ASSERT( !string( libcmis_error_getMessage( error ) ).empty( ) ); // Free it all libcmis_error_free( error ); libcmis_document_free( tested ); } void DocumentTest::checkInTest( ) { libcmis_DocumentPtr tested = getTested( true, false ); libcmis_ErrorPtr error = libcmis_error_create( ); // Prepare the content to set FILE* tmp = tmpfile( ); string expected( "New Content Stream" ); fwrite( expected.c_str( ), 1, expected.size( ), tmp ); rewind( tmp ); // Create the properties for the new version libcmis_vector_property_Ptr properties = libcmis_vector_property_create( ); libcmis_ObjectTypePtr objectType = libcmis_object_getTypeDescription( tested ); const char* id = "Property1"; libcmis_PropertyTypePtr propertyType = libcmis_object_type_getPropertyType( objectType, id ); size_t size = 2; const char** values = new const char*[size]; values[0] = "Value 1"; values[1] = "Value 2"; libcmis_PropertyPtr property = libcmis_property_create( propertyType, values, size ); delete[] values; libcmis_vector_property_append( properties, property ); // get the content into a temporary file (tested method) const char* contentType = "content/type"; const char* comment = "Version comment"; const char* filename = "filename.txt"; libcmis_DocumentPtr newVersion = libcmis_document_checkIn( tested, true, comment, properties, ( libcmis_readFn )fread, tmp, contentType, filename, error ); fclose( tmp ); // Check CPPUNIT_ASSERT( NULL != newVersion ); string actual = getTestedImplementation( tested )->getContentString( ); CPPUNIT_ASSERT( NULL == libcmis_error_getMessage( error ) ); CPPUNIT_ASSERT_EQUAL( expected, actual ); libcmis_PropertyPtr checkedProperty = libcmis_object_getProperty( tested, "Property1" ); libcmis_vector_string_Ptr newValues = libcmis_property_getStrings( checkedProperty ); CPPUNIT_ASSERT_EQUAL( size_t( 2 ), libcmis_vector_string_size( newValues ) ); // Free it all libcmis_vector_string_free( newValues ); libcmis_property_free( checkedProperty ); libcmis_document_free( newVersion ); libcmis_property_free( property ); libcmis_property_type_free( propertyType ); libcmis_object_type_free( objectType ); libcmis_vector_property_free( properties ); libcmis_error_free( error ); libcmis_document_free( tested ); } void DocumentTest::checkInErrorTest( ) { libcmis_DocumentPtr tested = getTested( true, true ); libcmis_ErrorPtr error = libcmis_error_create( ); string expected = getTestedImplementation( tested )->getContentString( ); // Prepare the content to set FILE* tmp = tmpfile( ); string newContent( "New Content Stream" ); fwrite( newContent.c_str( ), 1, newContent.size( ), tmp ); rewind( tmp ); // Create the properties for the new version libcmis_vector_property_Ptr properties = libcmis_vector_property_create( ); libcmis_ObjectTypePtr objectType = libcmis_object_getTypeDescription( tested ); const char* id = "Property1"; libcmis_PropertyTypePtr propertyType = libcmis_object_type_getPropertyType( objectType, id ); size_t size = 2; const char** values = new const char*[size]; values[0] = "Value 1"; values[1] = "Value 2"; libcmis_PropertyPtr property = libcmis_property_create( propertyType, values, size ); delete[] values; libcmis_vector_property_append( properties, property ); // get the content into a temporary file (tested method) const char* contentType = "content/type"; const char* comment = "Version comment"; const char* filename = "filename.txt"; libcmis_DocumentPtr newVersion = libcmis_document_checkIn( tested, true, comment, properties, ( libcmis_readFn )fread, tmp, contentType, filename, error ); fclose( tmp ); // Check CPPUNIT_ASSERT( NULL == newVersion ); string actual = getTestedImplementation( tested )->getContentString( ); CPPUNIT_ASSERT( !string( libcmis_error_getMessage( error ) ).empty( ) ); CPPUNIT_ASSERT_EQUAL( expected, actual ); libcmis_PropertyPtr checkedProperty = libcmis_object_getProperty( tested, "Property1" ); libcmis_vector_string_Ptr newValues = libcmis_property_getStrings( checkedProperty ); CPPUNIT_ASSERT_EQUAL( size_t( 1 ), libcmis_vector_string_size( newValues ) ); // Free it all libcmis_vector_string_free( newValues ); libcmis_property_free( checkedProperty ); libcmis_document_free( newVersion ); libcmis_property_free( property ); libcmis_property_type_free( propertyType ); libcmis_object_type_free( objectType ); libcmis_vector_property_free( properties ); libcmis_error_free( error ); libcmis_document_free( tested ); } void DocumentTest::getAllVersionsTest( ) { libcmis_DocumentPtr tested = getTested( true, false ); libcmis_ErrorPtr error = libcmis_error_create( ); // get all versions (tested method) libcmis_vector_document_Ptr versions = libcmis_document_getAllVersions( tested, error ); // Check CPPUNIT_ASSERT_EQUAL( size_t( 2 ), libcmis_vector_document_size( versions ) ); libcmis_DocumentPtr actualVersion = libcmis_vector_document_get( versions, 0 ); char* actualId = libcmis_object_getId( actualVersion ); CPPUNIT_ASSERT( actualId != NULL ); free( actualId ); // Free it all libcmis_document_free( actualVersion ); libcmis_vector_document_free( versions ); libcmis_error_free( error ); libcmis_document_free( tested ); } void DocumentTest::getAllVersionsErrorTest( ) { libcmis_DocumentPtr tested = getTested( true, true ); libcmis_ErrorPtr error = libcmis_error_create( ); // get all versions (tested method) libcmis_vector_document_Ptr versions = libcmis_document_getAllVersions( tested, error ); // Check CPPUNIT_ASSERT( NULL == versions ); CPPUNIT_ASSERT( !string( libcmis_error_getMessage( error ) ).empty( ) ); // Free it all libcmis_vector_document_free( versions ); libcmis_error_free( error ); libcmis_document_free( tested ); } ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis-c/test-repository.cxx������������������������������������������������������0000664�0001750�0001750�00000014213�13407414352�016252� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <cppunit/extensions/HelperMacros.h> #include <cppunit/TestFixture.h> #include <cppunit/TestAssert.h> #include <libcmis-c/repository.h> #include "internals.hxx" #include "test-dummies.hxx" using namespace std; class RepositoryTest : public CppUnit::TestFixture { private: libcmis_RepositoryPtr getTested( ); public: void getIdTest( ); void getNameTest( ); void getDescriptionTest( ); void getVendorNameTest( ); void getProductNameTest( ); void getProductVersionTest( ); void getRootIdTest( ); void getCmisVersionSupportedTest( ); void getThinClientUriTest( ); void getPrincipalAnonymousTest( ); void getPrincipalAnyoneTest( ); CPPUNIT_TEST_SUITE( RepositoryTest ); CPPUNIT_TEST( getIdTest ); CPPUNIT_TEST( getNameTest ); CPPUNIT_TEST( getDescriptionTest ); CPPUNIT_TEST( getVendorNameTest ); CPPUNIT_TEST( getProductNameTest ); CPPUNIT_TEST( getProductVersionTest ); CPPUNIT_TEST( getRootIdTest ); CPPUNIT_TEST( getCmisVersionSupportedTest ); CPPUNIT_TEST( getThinClientUriTest ); CPPUNIT_TEST( getPrincipalAnonymousTest ); CPPUNIT_TEST( getPrincipalAnyoneTest ); CPPUNIT_TEST_SUITE_END( ); }; CPPUNIT_TEST_SUITE_REGISTRATION( RepositoryTest ); libcmis_RepositoryPtr RepositoryTest::getTested( ) { libcmis_RepositoryPtr result = new libcmis_repository( ); libcmis::RepositoryPtr handle( new dummies::Repository( ) ); result->handle = handle; return result; } void RepositoryTest::getIdTest( ) { libcmis_RepositoryPtr tested = getTested( ); char* actual = libcmis_repository_getId( tested ); string expected( "Repository::Id" ); CPPUNIT_ASSERT_EQUAL( expected, string( actual ) ); free( actual ); libcmis_repository_free( tested ); } void RepositoryTest::getNameTest( ) { libcmis_RepositoryPtr tested = getTested( ); char* actual = libcmis_repository_getName( tested ); string expected( "Repository::Name" ); CPPUNIT_ASSERT_EQUAL( expected, string( actual ) ); free( actual ); libcmis_repository_free( tested ); } void RepositoryTest::getDescriptionTest( ) { libcmis_RepositoryPtr tested = getTested( ); char* actual = libcmis_repository_getDescription( tested ); string expected( "Repository::Description" ); CPPUNIT_ASSERT_EQUAL( expected, string( actual ) ); free( actual ); libcmis_repository_free( tested ); } void RepositoryTest::getVendorNameTest( ) { libcmis_RepositoryPtr tested = getTested( ); char* actual = libcmis_repository_getVendorName( tested ); string expected( "Repository::VendorName" ); CPPUNIT_ASSERT_EQUAL( expected, string( actual ) ); free( actual ); libcmis_repository_free( tested ); } void RepositoryTest::getProductNameTest( ) { libcmis_RepositoryPtr tested = getTested( ); char* actual = libcmis_repository_getProductName( tested ); string expected( "Repository::ProductName" ); CPPUNIT_ASSERT_EQUAL( expected, string( actual ) ); free( actual ); libcmis_repository_free( tested ); } void RepositoryTest::getProductVersionTest( ) { libcmis_RepositoryPtr tested = getTested( ); char* actual = libcmis_repository_getProductVersion( tested ); string expected( "Repository::ProductVersion" ); CPPUNIT_ASSERT_EQUAL( expected, string( actual ) ); free( actual ); libcmis_repository_free( tested ); } void RepositoryTest::getRootIdTest( ) { libcmis_RepositoryPtr tested = getTested( ); char* actual = libcmis_repository_getRootId( tested ); string expected( "Repository::RootId" ); CPPUNIT_ASSERT_EQUAL( expected, string( actual ) ); free( actual ); libcmis_repository_free( tested ); } void RepositoryTest::getCmisVersionSupportedTest( ) { libcmis_RepositoryPtr tested = getTested( ); char* actual = libcmis_repository_getCmisVersionSupported( tested ); string expected( "Repository::CmisVersionSupported" ); CPPUNIT_ASSERT_EQUAL( expected, string( actual ) ); free( actual ); libcmis_repository_free( tested ); } void RepositoryTest::getThinClientUriTest( ) { libcmis_RepositoryPtr tested = getTested( ); char* actual = libcmis_repository_getThinClientUri( tested ); string expected( "Repository::ThinClientUri" ); CPPUNIT_ASSERT_EQUAL( expected, string( actual ) ); free( actual ); libcmis_repository_free( tested ); } void RepositoryTest::getPrincipalAnonymousTest( ) { libcmis_RepositoryPtr tested = getTested( ); char* actual = libcmis_repository_getPrincipalAnonymous( tested ); string expected( "Repository::PrincipalAnonymous" ); CPPUNIT_ASSERT_EQUAL( expected, string( actual ) ); free( actual ); libcmis_repository_free( tested ); } void RepositoryTest::getPrincipalAnyoneTest( ) { libcmis_RepositoryPtr tested = getTested( ); char* actual = libcmis_repository_getPrincipalAnyone( tested ); string expected( "Repository::PrincipalAnyone" ); CPPUNIT_ASSERT_EQUAL( expected, string( actual ) ); free( actual ); libcmis_repository_free( tested ); } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis-c/Makefile.am��������������������������������������������������������������0000664�0001750�0001750�00000001777�13407414352�014401� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������check_PROGRAMS = \ test-api \ test-c-build test_api_SOURCES = \ test-allowable-actions.cxx \ test-api.cxx \ test-document.cxx \ test-dummies.cxx \ test-dummies.hxx \ test-folder.cxx \ test-object-type.cxx \ test-object.cxx \ test-property-type.cxx \ test-property.cxx \ test-repository.cxx \ test-session.cxx test_api_CXXFLAGS = \ -I$(top_srcdir)/inc \ -I$(top_srcdir)/src/libcmis-c/ \ $(XML2_CFLAGS) \ $(BOOST_CPPFLAGS) test_api_LDADD = \ $(top_builddir)/src/libcmis-c/libcmis-c-@LIBCMIS_API_VERSION@.la \ $(top_builddir)/src/libcmis/libcmis-@LIBCMIS_API_VERSION@.la \ $(XML2_LIBS) \ $(CURL_LIBS) \ $(CPPUNIT_LIBS) \ $(BOOST_DATE_TIME_LIBS) test_c_build_SOURCES = \ test-build.c test_c_build_CFLAGS = \ -I$(top_srcdir)/inc \ $(XML2_CFLAGS) test_c_build_LDADD = \ $(top_builddir)/src/libcmis-c/libcmis-c-@LIBCMIS_API_VERSION@.la \ $(top_builddir)/src/libcmis/libcmis-@LIBCMIS_API_VERSION@.la \ $(XML2_LIBS) \ $(CURL_LIBS) \ $(CPPUNIT_LIBS) \ $(BOOST_DATE_TIME_LIBS) TESTS = test-api �libcmis-0.5.2/qa/libcmis-c/test-api.cxx�������������������������������������������������������������0000664�0001750�0001750�00000002631�13407173247�014612� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <cppunit/extensions/HelperMacros.h> #include <cppunit/ui/text/TestRunner.h> int main( int, char** ) { CppUnit::TextUi::TestRunner runner; CppUnit::TestFactoryRegistry ®istry = CppUnit::TestFactoryRegistry::getRegistry(); runner.addTest( registry.makeTest() ); bool wasSuccess = runner.run( "", false ); return !wasSuccess; } �������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/libcmis-c/test-property-type.cxx���������������������������������������������������0000664�0001750�0001750�00000020027�13407414352�016676� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* libcmis * Version: MPL 1.1 / GPLv2+ / LGPLv2+ * * The contents of this file are subject to the Mozilla Public License Version * 1.1 (the "License"); you may not use this file except in compliance with * the License or as specified alternatively below. You may obtain a copy of * the License at http://www.mozilla.org/MPL/ * * Software distributed under the License is distributed on an "AS IS" basis, * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License * for the specific language governing rights and limitations under the * License. * * Major Contributor(s): * Copyright (C) 2011 SUSE <cbosdonnat@suse.com> * * * All Rights Reserved. * * For minor contributions see the git repository. * * Alternatively, the contents of this file may be used under the terms of * either the GNU General Public License Version 2 or later (the "GPLv2+"), or * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"), * in which case the provisions of the GPLv2+ or the LGPLv2+ are applicable * instead of those above. */ #include <cppunit/extensions/HelperMacros.h> #include <cppunit/TestFixture.h> #include <cppunit/TestAssert.h> #include <libcmis-c/property-type.h> #include "internals.hxx" #include "test-dummies.hxx" using namespace std; class PropertyTypeTest : public CppUnit::TestFixture { private: libcmis_PropertyTypePtr getTested( string id, string xmlType ); public: void getIdTest( ); void getLocalNameTest( ); void getLocalNamespaceTest( ); void getDisplayNameTest( ); void getQueryNameTest( ); void getTypeTest( ); void isMultiValuedTest( ); void isUpdatableTest( ); void isInheritedTest( ); void isRequiredTest( ); void isQueryableTest( ); void isOrderableTest( ); void isOpenChoiceTest( ); CPPUNIT_TEST_SUITE( PropertyTypeTest ); CPPUNIT_TEST( getIdTest ); CPPUNIT_TEST( getLocalNameTest ); CPPUNIT_TEST( getLocalNamespaceTest ); CPPUNIT_TEST( getDisplayNameTest ); CPPUNIT_TEST( getQueryNameTest ); CPPUNIT_TEST( getTypeTest ); CPPUNIT_TEST( isMultiValuedTest ); CPPUNIT_TEST( isUpdatableTest ); CPPUNIT_TEST( isInheritedTest ); CPPUNIT_TEST( isRequiredTest ); CPPUNIT_TEST( isQueryableTest ); CPPUNIT_TEST( isOrderableTest ); CPPUNIT_TEST( isOpenChoiceTest ); CPPUNIT_TEST_SUITE_END( ); }; CPPUNIT_TEST_SUITE_REGISTRATION( PropertyTypeTest ); libcmis_PropertyTypePtr PropertyTypeTest::getTested( string id, string xmlType ) { libcmis_PropertyTypePtr result = new libcmis_property_type( ); libcmis::PropertyTypePtr handle( new dummies::PropertyType( id, xmlType ) ); result->handle = handle; return result; } void PropertyTypeTest::getIdTest( ) { string id( "Id" ); libcmis_PropertyTypePtr tested = getTested( id, "string" ); char* actual = libcmis_property_type_getId( tested ); CPPUNIT_ASSERT_EQUAL( id, string( actual ) ); free( actual ); libcmis_property_type_free( tested ); } void PropertyTypeTest::getLocalNameTest( ) { libcmis_PropertyTypePtr tested = getTested( "id", "string" ); char* actual = libcmis_property_type_getLocalName( tested ); CPPUNIT_ASSERT_EQUAL( string( "PropertyType::LocalName" ), string( actual ) ); free( actual ); libcmis_property_type_free( tested ); } void PropertyTypeTest::getLocalNamespaceTest( ) { libcmis_PropertyTypePtr tested = getTested( "id", "string" ); char* actual = libcmis_property_type_getLocalNamespace( tested ); CPPUNIT_ASSERT_EQUAL( string( "PropertyType::LocalNamespace" ), string( actual ) ); free( actual ); libcmis_property_type_free( tested ); } void PropertyTypeTest::getDisplayNameTest( ) { libcmis_PropertyTypePtr tested = getTested( "id", "string" ); char* actual = libcmis_property_type_getDisplayName( tested ); CPPUNIT_ASSERT_EQUAL( string( "PropertyType::DisplayName" ), string( actual ) ); free( actual ); libcmis_property_type_free( tested ); } void PropertyTypeTest::getQueryNameTest( ) { libcmis_PropertyTypePtr tested = getTested( "id", "string" ); char* actual = libcmis_property_type_getQueryName( tested ); CPPUNIT_ASSERT_EQUAL( string( "PropertyType::QueryName" ), string( actual ) ); free( actual ); libcmis_property_type_free( tested ); } void PropertyTypeTest::getTypeTest( ) { // String { libcmis_PropertyTypePtr tested = getTested( "id", "string" ); libcmis_property_type_Type actualType = libcmis_property_type_getType( tested ); CPPUNIT_ASSERT_EQUAL( libcmis_String, actualType ); char* actualXml = libcmis_property_type_getXmlType( tested ); CPPUNIT_ASSERT_EQUAL( string( "String" ), string( actualXml ) ); free( actualXml ); libcmis_property_type_free( tested ); } // DateTime { libcmis_PropertyTypePtr tested = getTested( "id", "datetime" ); libcmis_property_type_Type actualType = libcmis_property_type_getType( tested ); CPPUNIT_ASSERT_EQUAL( libcmis_DateTime, actualType ); char* actualXml = libcmis_property_type_getXmlType( tested ); CPPUNIT_ASSERT_EQUAL( string( "DateTime" ), string( actualXml ) ); free( actualXml ); libcmis_property_type_free( tested ); } // Integer { libcmis_PropertyTypePtr tested = getTested( "id", "integer" ); libcmis_property_type_Type actualType = libcmis_property_type_getType( tested ); CPPUNIT_ASSERT_EQUAL( libcmis_Integer, actualType ); char* actualXml = libcmis_property_type_getXmlType( tested ); CPPUNIT_ASSERT_EQUAL( string( "Integer" ), string( actualXml ) ); free( actualXml ); libcmis_property_type_free( tested ); } // Html { libcmis_PropertyTypePtr tested = getTested( "id", "html" ); libcmis_property_type_Type actualType = libcmis_property_type_getType( tested ); CPPUNIT_ASSERT_EQUAL( libcmis_String, actualType ); char* actualXml = libcmis_property_type_getXmlType( tested ); CPPUNIT_ASSERT_EQUAL( string( "Html" ), string( actualXml ) ); free( actualXml ); libcmis_property_type_free( tested ); } } void PropertyTypeTest::isMultiValuedTest( ) { libcmis_PropertyTypePtr tested = getTested( "id", "string" ); bool actual = libcmis_property_type_isMultiValued( tested ); CPPUNIT_ASSERT_EQUAL( true , actual ); libcmis_property_type_free( tested ); } void PropertyTypeTest::isUpdatableTest( ) { libcmis_PropertyTypePtr tested = getTested( "id", "string" ); bool actual = libcmis_property_type_isUpdatable( tested ); CPPUNIT_ASSERT_EQUAL( true , actual ); libcmis_property_type_free( tested ); } void PropertyTypeTest::isInheritedTest( ) { libcmis_PropertyTypePtr tested = getTested( "id", "string" ); bool actual = libcmis_property_type_isInherited( tested ); CPPUNIT_ASSERT_EQUAL( true , actual ); libcmis_property_type_free( tested ); } void PropertyTypeTest::isRequiredTest( ) { libcmis_PropertyTypePtr tested = getTested( "id", "string" ); bool actual = libcmis_property_type_isRequired( tested ); CPPUNIT_ASSERT_EQUAL( true , actual ); libcmis_property_type_free( tested ); } void PropertyTypeTest::isQueryableTest( ) { libcmis_PropertyTypePtr tested = getTested( "id", "string" ); bool actual = libcmis_property_type_isQueryable( tested ); CPPUNIT_ASSERT_EQUAL( true , actual ); libcmis_property_type_free( tested ); } void PropertyTypeTest::isOrderableTest( ) { libcmis_PropertyTypePtr tested = getTested( "id", "string" ); bool actual = libcmis_property_type_isOrderable( tested ); CPPUNIT_ASSERT_EQUAL( true , actual ); libcmis_property_type_free( tested ); } void PropertyTypeTest::isOpenChoiceTest( ) { libcmis_PropertyTypePtr tested = getTested( "id", "string" ); bool actual = libcmis_property_type_isOpenChoice( tested ); CPPUNIT_ASSERT_EQUAL( true , actual ); libcmis_property_type_free( tested ); } ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/qa/Makefile.am������������������������������������������������������������������������0000664�0001750�0001750�00000000043�13407173247�012525� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������SUBDIRS = mockup libcmis libcmis-c ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/configure�����������������������������������������������������������������������������0000775�0001750�0001750�00002445140�13407705037�012012� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������#! /bin/sh # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.69 for libcmis 0.5.2. # # # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. # # # This configure script is free software; the Free Software Foundation # gives unlimited permission to copy, distribute and modify it. ## -------------------- ## ## M4sh Initialization. ## ## -------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi as_nl=' ' export as_nl # Printing a long string crashes Solaris 7 /usr/bin/printf. as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo # Prefer a ksh shell builtin over an external printf program on Solaris, # but without wasting forks for bash or zsh. if test -z "$BASH_VERSION$ZSH_VERSION" \ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='print -r --' as_echo_n='print -rn --' elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='printf %s\n' as_echo_n='printf %s' else if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' as_echo_n='/usr/ucb/echo -n' else as_echo_body='eval expr "X$1" : "X\\(.*\\)"' as_echo_n_body='eval arg=$1; case $arg in #( *"$as_nl"*) expr "X$arg" : "X\\(.*\\)$as_nl"; arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; esac; expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" ' export as_echo_n_body as_echo_n='sh -c $as_echo_n_body as_echo' fi export as_echo_body as_echo='sh -c $as_echo_body as_echo' fi # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || PATH_SEPARATOR=';' } fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. as_myself= case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 exit 1 fi # Unset variables that we do not need and which cause bugs (e.g. in # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" # suppresses any "Segmentation fault" message there. '((' could # trigger a bug in pdksh 5.2.14. for as_var in BASH_ENV ENV MAIL MAILPATH do eval test x\${$as_var+set} = xset \ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. LC_ALL=C export LC_ALL LANGUAGE=C export LANGUAGE # CDPATH. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH # Use a proper internal environment variable to ensure we don't fall # into an infinite loop, continuously re-executing ourselves. if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then _as_can_reexec=no; export _as_can_reexec; # We cannot yet assume a decent shell, so we have to provide a # neutralization value for shells without unset; and this also # works around shells that cannot unset nonexistent variables. # Preserve -v and -x to the replacement shell. BASH_ENV=/dev/null ENV=/dev/null (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV case $- in # (((( *v*x* | *x*v* ) as_opts=-vx ;; *v* ) as_opts=-v ;; *x* ) as_opts=-x ;; * ) as_opts= ;; esac exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} # Admittedly, this is quite paranoid, since all the known shells bail # out after a failed `exec'. $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 as_fn_exit 255 fi # We don't want this to propagate to other subprocesses. { _as_can_reexec=; unset _as_can_reexec;} if test "x$CONFIG_SHELL" = x; then as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which # is contrary to our usage. Disable this feature. alias -g '\${1+\"\$@\"}'='\"\$@\"' setopt NO_GLOB_SUBST else case \`(set -o) 2>/dev/null\` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi " as_required="as_fn_return () { (exit \$1); } as_fn_success () { as_fn_return 0; } as_fn_failure () { as_fn_return 1; } as_fn_ret_success () { return 0; } as_fn_ret_failure () { return 1; } exitcode=0 as_fn_success || { exitcode=1; echo as_fn_success failed.; } as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : else exitcode=1; echo positional parameters were not saved. fi test x\$exitcode = x0 || exit 1 test -x / || exit 1" as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || ( ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO PATH=/empty FPATH=/empty; export PATH FPATH test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\ || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1 test \$(( 1 + 1 )) = 2 || exit 1" if (eval "$as_required") 2>/dev/null; then : as_have_required=yes else as_have_required=no fi if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR as_found=false for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. as_found=: case $as_dir in #( /*) for as_base in sh bash ksh sh5; do # Try only shells that exist, to save several forks. as_shell=$as_dir/$as_base if { test -f "$as_shell" || test -f "$as_shell.exe"; } && { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : CONFIG_SHELL=$as_shell as_have_required=yes if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : break 2 fi fi done;; esac as_found=false done $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : CONFIG_SHELL=$SHELL as_have_required=yes fi; } IFS=$as_save_IFS if test "x$CONFIG_SHELL" != x; then : export CONFIG_SHELL # We cannot yet assume a decent shell, so we have to provide a # neutralization value for shells without unset; and this also # works around shells that cannot unset nonexistent variables. # Preserve -v and -x to the replacement shell. BASH_ENV=/dev/null ENV=/dev/null (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV case $- in # (((( *v*x* | *x*v* ) as_opts=-vx ;; *v* ) as_opts=-v ;; *x* ) as_opts=-x ;; * ) as_opts= ;; esac exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} # Admittedly, this is quite paranoid, since all the known shells bail # out after a failed `exec'. $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 exit 255 fi if test x$as_have_required = xno; then : $as_echo "$0: This script requires a shell more modern than all" $as_echo "$0: the shells that I found on your system." if test x${ZSH_VERSION+set} = xset ; then $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" $as_echo "$0: be upgraded to zsh 4.3.4 or later." else $as_echo "$0: Please tell bug-autoconf@gnu.org about your system, $0: including any error possibly output before this $0: message. Then install a modern shell, or manually run $0: the script under such a shell if you do have one." fi exit 1 fi fi fi SHELL=${CONFIG_SHELL-/bin/sh} export SHELL # Unset more variables known to interfere with behavior of common tools. CLICOLOR_FORCE= GREP_OPTIONS= unset CLICOLOR_FORCE GREP_OPTIONS ## --------------------- ## ## M4sh Shell Functions. ## ## --------------------- ## # as_fn_unset VAR # --------------- # Portably unset VAR. as_fn_unset () { { eval $1=; unset $1;} } as_unset=as_fn_unset # as_fn_set_status STATUS # ----------------------- # Set $? to STATUS, without forking. as_fn_set_status () { return $1 } # as_fn_set_status # as_fn_exit STATUS # ----------------- # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. as_fn_exit () { set +e as_fn_set_status $1 exit $1 } # as_fn_exit # as_fn_mkdir_p # ------------- # Create "$as_dir" as a directory, including parents if necessary. as_fn_mkdir_p () { case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || eval $as_mkdir_p || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" } # as_fn_mkdir_p # as_fn_executable_p FILE # ----------------------- # Test if FILE is an executable regular file. as_fn_executable_p () { test -f "$1" && test -x "$1" } # as_fn_executable_p # as_fn_append VAR VALUE # ---------------------- # Append the text in VALUE to the end of the definition contained in VAR. Take # advantage of any shell optimizations that allow amortized linear growth over # repeated appends, instead of the typical quadratic growth present in naive # implementations. if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : eval 'as_fn_append () { eval $1+=\$2 }' else as_fn_append () { eval $1=\$$1\$2 } fi # as_fn_append # as_fn_arith ARG... # ------------------ # Perform arithmetic evaluation on the ARGs, and store the result in the # global $as_val. Take advantage of shells that can avoid forks. The arguments # must be portable across $(()) and expr. if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : eval 'as_fn_arith () { as_val=$(( $* )) }' else as_fn_arith () { as_val=`expr "$@" || test $? -eq 1` } fi # as_fn_arith # as_fn_error STATUS ERROR [LINENO LOG_FD] # ---------------------------------------- # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are # provided, also output the error to LOG_FD, referencing LINENO. Then exit the # script with STATUS, using 1 if that was 0. as_fn_error () { as_status=$1; test $as_status -eq 0 && as_status=1 if test "$4"; then as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 fi $as_echo "$as_me: error: $2" >&2 as_fn_exit $as_status } # as_fn_error if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || $as_echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits as_lineno_1=$LINENO as_lineno_1a=$LINENO as_lineno_2=$LINENO as_lineno_2a=$LINENO eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) sed -n ' p /[$]LINENO/= ' <$as_myself | sed ' s/[$]LINENO.*/&-/ t lineno b :lineno N :loop s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ t loop s/-\n.*// ' >$as_me.lineno && chmod +x "$as_me.lineno" || { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } # If we had to re-execute with $CONFIG_SHELL, we're ensured to have # already done that, so ensure we don't try to do so again and fall # in an infinite loop. This has already happened in practice. _as_can_reexec=no; export _as_can_reexec # Don't try to exec as it changes $[0], causing all sort of problems # (the dirname of $[0] is not the place where we might find the # original and so on. Autoconf is especially sensitive to this). . "./$as_me.lineno" # Exit status is that of the last command. exit } ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in #((((( -n*) case `echo 'xy\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. xy) ECHO_C='\c';; *) echo `echo ksh88 bug on AIX 6.1` > /dev/null ECHO_T=' ';; esac;; *) ECHO_N='-n';; esac rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir 2>/dev/null fi if (echo >conf$$.file) 2>/dev/null; then if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -pR'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -pR' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -pR' fi else as_ln_s='cp -pR' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null if mkdir -p . 2>/dev/null; then as_mkdir_p='mkdir -p "$as_dir"' else test -d ./-p && rmdir ./-p as_mkdir_p=false fi as_test_x='test -x' as_executable_p=as_fn_executable_p # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" SHELL=${CONFIG_SHELL-/bin/sh} test -n "$DJDIR" || exec 7<&0 </dev/null exec 6>&1 # Name of the host. # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, # so uname gets run too. ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` # # Initializations. # ac_default_prefix=/usr/local ac_clean_files= ac_config_libobj_dir=. LIBOBJS= cross_compiling=no subdirs= MFLAGS= MAKEFLAGS= # Identity of this package. PACKAGE_NAME='libcmis' PACKAGE_TARNAME='libcmis' PACKAGE_VERSION='0.5.2' PACKAGE_STRING='libcmis 0.5.2' PACKAGE_BUGREPORT='' PACKAGE_URL='' # Factoring default headers for most tests. ac_includes_default="\ #include <stdio.h> #ifdef HAVE_SYS_TYPES_H # include <sys/types.h> #endif #ifdef HAVE_SYS_STAT_H # include <sys/stat.h> #endif #ifdef STDC_HEADERS # include <stdlib.h> # include <stddef.h> #else # ifdef HAVE_STDLIB_H # include <stdlib.h> # endif #endif #ifdef HAVE_STRING_H # if !defined STDC_HEADERS && defined HAVE_MEMORY_H # include <memory.h> # endif # include <string.h> #endif #ifdef HAVE_STRINGS_H # include <strings.h> #endif #ifdef HAVE_INTTYPES_H # include <inttypes.h> #endif #ifdef HAVE_STDINT_H # include <stdint.h> #endif #ifdef HAVE_UNISTD_H # include <unistd.h> #endif" ac_subst_vars='am__EXEEXT_FALSE am__EXEEXT_TRUE LTLIBOBJS LIBOBJS BOOST_PROGRAM_OPTIONS_LIBS BOOST_PROGRAM_OPTIONS_LDPATH BOOST_PROGRAM_OPTIONS_LDFLAGS BOOST_DATE_TIME_LIBS BOOST_LDPATH BOOST_DATE_TIME_LDPATH BOOST_DATE_TIME_LDFLAGS BOOST_CPPFLAGS DISTCHECK_CONFIGURE_FLAGS BOOST_ROOT CPPUNIT_LIBS CPPUNIT_CFLAGS XML2_LIBS XML2_CFLAGS CURL_LIBS CURL_CFLAGS PKG_CONFIG_LIBDIR PKG_CONFIG_PATH PKG_CONFIG CPPCHECK_PARALLELISM NPROC CPPCHECK ENABLE_MAN_FALSE ENABLE_MAN_TRUE DOCBOOK2MAN ENABLE_VISIBILITY_FALSE ENABLE_VISIBILITY_TRUE OS_WIN32_FALSE OS_WIN32_TRUE SRCDIR LIBCMIS_API_VERSION GENHTML LCOV ENABLE_COVERAGE_FALSE ENABLE_COVERAGE_TRUE ENABLE_TESTS_FALSE ENABLE_TESTS_TRUE ENABLE_CLIENT_FALSE ENABLE_CLIENT_TRUE HAVE_CXX11 CXXCPP LT_SYS_LIBRARY_PATH OTOOL64 OTOOL LIPO NMEDIT DSYMUTIL MANIFEST_TOOL RANLIB ac_ct_AR AR DLLTOOL OBJDUMP NM ac_ct_DUMPBIN DUMPBIN LD FGREP EGREP GREP SED host_os host_vendor host_cpu host build_os build_vendor build_cpu build LIBTOOL LN_S am__fastdepCXX_FALSE am__fastdepCXX_TRUE CXXDEPMODE ac_ct_CXX CXXFLAGS CXX CPP am__fastdepCC_FALSE am__fastdepCC_TRUE CCDEPMODE am__nodep AMDEPBACKSLASH AMDEP_FALSE AMDEP_TRUE am__include DEPDIR OBJEXT EXEEXT ac_ct_CC CPPFLAGS LDFLAGS CFLAGS CC AM_BACKSLASH AM_DEFAULT_VERBOSITY AM_DEFAULT_V AM_V am__untar am__tar AMTAR am__leading_dot SET_MAKE AWK mkdir_p MKDIR_P INSTALL_STRIP_PROGRAM STRIP install_sh MAKEINFO AUTOHEADER AUTOMAKE AUTOCONF ACLOCAL VERSION PACKAGE CYGPATH_W am__isrc INSTALL_DATA INSTALL_SCRIPT INSTALL_PROGRAM target_alias host_alias build_alias LIBS ECHO_T ECHO_N ECHO_C DEFS mandir localedir libdir psdir pdfdir dvidir htmldir infodir docdir oldincludedir includedir localstatedir sharedstatedir sysconfdir datadir datarootdir libexecdir sbindir bindir program_transform_name prefix exec_prefix PACKAGE_URL PACKAGE_BUGREPORT PACKAGE_STRING PACKAGE_VERSION PACKAGE_TARNAME PACKAGE_NAME PATH_SEPARATOR SHELL am__quote' ac_subst_files='' ac_user_opts=' enable_option_checking enable_silent_rules enable_dependency_tracking enable_shared enable_static with_pic enable_fast_install with_aix_soname with_gnu_ld with_sysroot enable_libtool_lock enable_client enable_tests enable_coverage with_man enable_werror with_boost enable_static_boost ' ac_precious_vars='build_alias host_alias target_alias CC CFLAGS LDFLAGS LIBS CPPFLAGS CPP CXX CXXFLAGS CCC LT_SYS_LIBRARY_PATH CXXCPP PKG_CONFIG PKG_CONFIG_PATH PKG_CONFIG_LIBDIR CURL_CFLAGS CURL_LIBS XML2_CFLAGS XML2_LIBS CPPUNIT_CFLAGS CPPUNIT_LIBS BOOST_ROOT' # Initialize some variables set by options. ac_init_help= ac_init_version=false ac_unrecognized_opts= ac_unrecognized_sep= # The variables have the same names as the options, with # dashes changed to underlines. cache_file=/dev/null exec_prefix=NONE no_create= no_recursion= prefix=NONE program_prefix=NONE program_suffix=NONE program_transform_name=s,x,x, silent= site= srcdir= verbose= x_includes=NONE x_libraries=NONE # Installation directory options. # These are left unexpanded so users can "make install exec_prefix=/foo" # and all the variables that are supposed to be based on exec_prefix # by default will actually change. # Use braces instead of parens because sh, perl, etc. also accept them. # (The list follows the same order as the GNU Coding Standards.) bindir='${exec_prefix}/bin' sbindir='${exec_prefix}/sbin' libexecdir='${exec_prefix}/libexec' datarootdir='${prefix}/share' datadir='${datarootdir}' sysconfdir='${prefix}/etc' sharedstatedir='${prefix}/com' localstatedir='${prefix}/var' includedir='${prefix}/include' oldincludedir='/usr/include' docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' infodir='${datarootdir}/info' htmldir='${docdir}' dvidir='${docdir}' pdfdir='${docdir}' psdir='${docdir}' libdir='${exec_prefix}/lib' localedir='${datarootdir}/locale' mandir='${datarootdir}/man' ac_prev= ac_dashdash= for ac_option do # If the previous option needs an argument, assign it. if test -n "$ac_prev"; then eval $ac_prev=\$ac_option ac_prev= continue fi case $ac_option in *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; *=) ac_optarg= ;; *) ac_optarg=yes ;; esac # Accept the important Cygnus configure options, so we can diagnose typos. case $ac_dashdash$ac_option in --) ac_dashdash=yes ;; -bindir | --bindir | --bindi | --bind | --bin | --bi) ac_prev=bindir ;; -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) bindir=$ac_optarg ;; -build | --build | --buil | --bui | --bu) ac_prev=build_alias ;; -build=* | --build=* | --buil=* | --bui=* | --bu=*) build_alias=$ac_optarg ;; -cache-file | --cache-file | --cache-fil | --cache-fi \ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) ac_prev=cache_file ;; -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) cache_file=$ac_optarg ;; --config-cache | -C) cache_file=config.cache ;; -datadir | --datadir | --datadi | --datad) ac_prev=datadir ;; -datadir=* | --datadir=* | --datadi=* | --datad=*) datadir=$ac_optarg ;; -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ | --dataroo | --dataro | --datar) ac_prev=datarootdir ;; -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) datarootdir=$ac_optarg ;; -disable-* | --disable-*) ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid feature name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "enable_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval enable_$ac_useropt=no ;; -docdir | --docdir | --docdi | --doc | --do) ac_prev=docdir ;; -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) docdir=$ac_optarg ;; -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) ac_prev=dvidir ;; -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) dvidir=$ac_optarg ;; -enable-* | --enable-*) ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid feature name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "enable_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval enable_$ac_useropt=\$ac_optarg ;; -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | --exec | --exe | --ex) ac_prev=exec_prefix ;; -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | --exec=* | --exe=* | --ex=*) exec_prefix=$ac_optarg ;; -gas | --gas | --ga | --g) # Obsolete; use --with-gas. with_gas=yes ;; -help | --help | --hel | --he | -h) ac_init_help=long ;; -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) ac_init_help=recursive ;; -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) ac_init_help=short ;; -host | --host | --hos | --ho) ac_prev=host_alias ;; -host=* | --host=* | --hos=* | --ho=*) host_alias=$ac_optarg ;; -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) ac_prev=htmldir ;; -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ | --ht=*) htmldir=$ac_optarg ;; -includedir | --includedir | --includedi | --included | --include \ | --includ | --inclu | --incl | --inc) ac_prev=includedir ;; -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | --includ=* | --inclu=* | --incl=* | --inc=*) includedir=$ac_optarg ;; -infodir | --infodir | --infodi | --infod | --info | --inf) ac_prev=infodir ;; -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) infodir=$ac_optarg ;; -libdir | --libdir | --libdi | --libd) ac_prev=libdir ;; -libdir=* | --libdir=* | --libdi=* | --libd=*) libdir=$ac_optarg ;; -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | --libexe | --libex | --libe) ac_prev=libexecdir ;; -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | --libexe=* | --libex=* | --libe=*) libexecdir=$ac_optarg ;; -localedir | --localedir | --localedi | --localed | --locale) ac_prev=localedir ;; -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) localedir=$ac_optarg ;; -localstatedir | --localstatedir | --localstatedi | --localstated \ | --localstate | --localstat | --localsta | --localst | --locals) ac_prev=localstatedir ;; -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) localstatedir=$ac_optarg ;; -mandir | --mandir | --mandi | --mand | --man | --ma | --m) ac_prev=mandir ;; -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) mandir=$ac_optarg ;; -nfp | --nfp | --nf) # Obsolete; use --without-fp. with_fp=no ;; -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | --no-cr | --no-c | -n) no_create=yes ;; -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) no_recursion=yes ;; -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | --oldin | --oldi | --old | --ol | --o) ac_prev=oldincludedir ;; -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) oldincludedir=$ac_optarg ;; -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) ac_prev=prefix ;; -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) prefix=$ac_optarg ;; -program-prefix | --program-prefix | --program-prefi | --program-pref \ | --program-pre | --program-pr | --program-p) ac_prev=program_prefix ;; -program-prefix=* | --program-prefix=* | --program-prefi=* \ | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) program_prefix=$ac_optarg ;; -program-suffix | --program-suffix | --program-suffi | --program-suff \ | --program-suf | --program-su | --program-s) ac_prev=program_suffix ;; -program-suffix=* | --program-suffix=* | --program-suffi=* \ | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) program_suffix=$ac_optarg ;; -program-transform-name | --program-transform-name \ | --program-transform-nam | --program-transform-na \ | --program-transform-n | --program-transform- \ | --program-transform | --program-transfor \ | --program-transfo | --program-transf \ | --program-trans | --program-tran \ | --progr-tra | --program-tr | --program-t) ac_prev=program_transform_name ;; -program-transform-name=* | --program-transform-name=* \ | --program-transform-nam=* | --program-transform-na=* \ | --program-transform-n=* | --program-transform-=* \ | --program-transform=* | --program-transfor=* \ | --program-transfo=* | --program-transf=* \ | --program-trans=* | --program-tran=* \ | --progr-tra=* | --program-tr=* | --program-t=*) program_transform_name=$ac_optarg ;; -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) ac_prev=pdfdir ;; -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) pdfdir=$ac_optarg ;; -psdir | --psdir | --psdi | --psd | --ps) ac_prev=psdir ;; -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) psdir=$ac_optarg ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) silent=yes ;; -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=sbindir ;; -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | --sbi=* | --sb=*) sbindir=$ac_optarg ;; -sharedstatedir | --sharedstatedir | --sharedstatedi \ | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | --sharedst | --shareds | --shared | --share | --shar \ | --sha | --sh) ac_prev=sharedstatedir ;; -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | --sha=* | --sh=*) sharedstatedir=$ac_optarg ;; -site | --site | --sit) ac_prev=site ;; -site=* | --site=* | --sit=*) site=$ac_optarg ;; -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) ac_prev=srcdir ;; -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) srcdir=$ac_optarg ;; -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | --syscon | --sysco | --sysc | --sys | --sy) ac_prev=sysconfdir ;; -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) sysconfdir=$ac_optarg ;; -target | --target | --targe | --targ | --tar | --ta | --t) ac_prev=target_alias ;; -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) target_alias=$ac_optarg ;; -v | -verbose | --verbose | --verbos | --verbo | --verb) verbose=yes ;; -version | --version | --versio | --versi | --vers | -V) ac_init_version=: ;; -with-* | --with-*) ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid package name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "with_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval with_$ac_useropt=\$ac_optarg ;; -without-* | --without-*) ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error $? "invalid package name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "with_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval with_$ac_useropt=no ;; --x) # Obsolete; use --with-x. with_x=yes ;; -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | --x-incl | --x-inc | --x-in | --x-i) ac_prev=x_includes ;; -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) x_includes=$ac_optarg ;; -x-libraries | --x-libraries | --x-librarie | --x-librari \ | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) ac_prev=x_libraries ;; -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) x_libraries=$ac_optarg ;; -*) as_fn_error $? "unrecognized option: \`$ac_option' Try \`$0 --help' for more information" ;; *=*) ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` # Reject names that are not valid shell variable names. case $ac_envvar in #( '' | [0-9]* | *[!_$as_cr_alnum]* ) as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; esac eval $ac_envvar=\$ac_optarg export $ac_envvar ;; *) # FIXME: should be removed in autoconf 3.0. $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" ;; esac done if test -n "$ac_prev"; then ac_option=--`echo $ac_prev | sed 's/_/-/g'` as_fn_error $? "missing argument to $ac_option" fi if test -n "$ac_unrecognized_opts"; then case $enable_option_checking in no) ;; fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; esac fi # Check all directory arguments for consistency. for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ libdir localedir mandir do eval ac_val=\$$ac_var # Remove trailing slashes. case $ac_val in */ ) ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` eval $ac_var=\$ac_val;; esac # Be sure to have absolute directory names. case $ac_val in [\\/$]* | ?:[\\/]* ) continue;; NONE | '' ) case $ac_var in *prefix ) continue;; esac;; esac as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" done # There might be people who depend on the old broken behavior: `$host' # used to hold the argument of --host etc. # FIXME: To remove some day. build=$build_alias host=$host_alias target=$target_alias # FIXME: To remove some day. if test "x$host_alias" != x; then if test "x$build_alias" = x; then cross_compiling=maybe elif test "x$build_alias" != "x$host_alias"; then cross_compiling=yes fi fi ac_tool_prefix= test -n "$host_alias" && ac_tool_prefix=$host_alias- test "$silent" = yes && exec 6>/dev/null ac_pwd=`pwd` && test -n "$ac_pwd" && ac_ls_di=`ls -di .` && ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || as_fn_error $? "working directory cannot be determined" test "X$ac_ls_di" = "X$ac_pwd_ls_di" || as_fn_error $? "pwd does not report name of working directory" # Find the source files, if location was not specified. if test -z "$srcdir"; then ac_srcdir_defaulted=yes # Try the directory containing this script, then the parent directory. ac_confdir=`$as_dirname -- "$as_myself" || $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_myself" : 'X\(//\)[^/]' \| \ X"$as_myself" : 'X\(//\)$' \| \ X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_myself" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` srcdir=$ac_confdir if test ! -r "$srcdir/$ac_unique_file"; then srcdir=.. fi else ac_srcdir_defaulted=no fi if test ! -r "$srcdir/$ac_unique_file"; then test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" fi ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" ac_abs_confdir=`( cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" pwd)` # When building in place, set srcdir=. if test "$ac_abs_confdir" = "$ac_pwd"; then srcdir=. fi # Remove unnecessary trailing slashes from srcdir. # Double slashes in file names in object file debugging info # mess up M-x gdb in Emacs. case $srcdir in */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; esac for ac_var in $ac_precious_vars; do eval ac_env_${ac_var}_set=\${${ac_var}+set} eval ac_env_${ac_var}_value=\$${ac_var} eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} eval ac_cv_env_${ac_var}_value=\$${ac_var} done # # Report the --help message. # if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF \`configure' configures libcmis 0.5.2 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... To assign environment variables (e.g., CC, CFLAGS...), specify them as VAR=VALUE. See below for descriptions of some of the useful variables. Defaults for the options are specified in brackets. Configuration: -h, --help display this help and exit --help=short display options specific to this package --help=recursive display the short help of all the included packages -V, --version display version information and exit -q, --quiet, --silent do not print \`checking ...' messages --cache-file=FILE cache test results in FILE [disabled] -C, --config-cache alias for \`--cache-file=config.cache' -n, --no-create do not create output files --srcdir=DIR find the sources in DIR [configure dir or \`..'] Installation directories: --prefix=PREFIX install architecture-independent files in PREFIX [$ac_default_prefix] --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX [PREFIX] By default, \`make install' will install all the files in \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify an installation prefix other than \`$ac_default_prefix' using \`--prefix', for instance \`--prefix=\$HOME'. For better control, use the options below. Fine tuning of the installation directories: --bindir=DIR user executables [EPREFIX/bin] --sbindir=DIR system admin executables [EPREFIX/sbin] --libexecdir=DIR program executables [EPREFIX/libexec] --sysconfdir=DIR read-only single-machine data [PREFIX/etc] --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] --localstatedir=DIR modifiable single-machine data [PREFIX/var] --libdir=DIR object code libraries [EPREFIX/lib] --includedir=DIR C header files [PREFIX/include] --oldincludedir=DIR C header files for non-gcc [/usr/include] --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] --datadir=DIR read-only architecture-independent data [DATAROOTDIR] --infodir=DIR info documentation [DATAROOTDIR/info] --localedir=DIR locale-dependent data [DATAROOTDIR/locale] --mandir=DIR man documentation [DATAROOTDIR/man] --docdir=DIR documentation root [DATAROOTDIR/doc/libcmis] --htmldir=DIR html documentation [DOCDIR] --dvidir=DIR dvi documentation [DOCDIR] --pdfdir=DIR pdf documentation [DOCDIR] --psdir=DIR ps documentation [DOCDIR] _ACEOF cat <<\_ACEOF Program names: --program-prefix=PREFIX prepend PREFIX to installed program names --program-suffix=SUFFIX append SUFFIX to installed program names --program-transform-name=PROGRAM run sed PROGRAM on installed program names System types: --build=BUILD configure for building on BUILD [guessed] --host=HOST cross-compile to build programs to run on HOST [BUILD] _ACEOF fi if test -n "$ac_init_help"; then case $ac_init_help in short | recursive ) echo "Configuration of libcmis 0.5.2:";; esac cat <<\_ACEOF Optional Features: --disable-option-checking ignore unrecognized --enable/--with options --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) --enable-FEATURE[=ARG] include FEATURE [ARG=yes] --enable-silent-rules less verbose build output (undo: "make V=1") --disable-silent-rules verbose build output (undo: "make V=0") --enable-dependency-tracking do not reject slow dependency extractors --disable-dependency-tracking speeds up one-time build --enable-shared[=PKGS] build shared libraries [default=yes] --enable-static[=PKGS] build static libraries [default=yes] --enable-fast-install[=PKGS] optimize for fast installation [default=yes] --disable-libtool-lock avoid locking (might break parallel builds) --disable-client Compile only the library, not the client tool --disable-tests Do not build the unit tests --enable-coverage Extract test coverage data --disable-werror Treat all warnings as errors, usefull for development --enable-static-boost Prefer the static boost libraries over the shared ones [no] Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use both] --with-aix-soname=aix|svr4|both shared library versioning (aka "SONAME") variant to provide on AIX, [default=aix]. --with-gnu-ld assume the C compiler uses GNU ld [default=no] --with-sysroot[=DIR] Search for dependent libraries within DIR (or the compiler's sysroot if not specified). --without-man Do not build manpage --with-boost=DIR prefix of Boost 1.36 [guess] Some influential environment variables: CC C compiler command CFLAGS C compiler flags LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a nonstandard directory <lib dir> LIBS libraries to pass to the linker, e.g. -l<library> CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if you have headers in a nonstandard directory <include dir> CPP C preprocessor CXX C++ compiler command CXXFLAGS C++ compiler flags LT_SYS_LIBRARY_PATH User-defined run-time library search path. CXXCPP C++ preprocessor PKG_CONFIG path to pkg-config utility PKG_CONFIG_PATH directories to add to pkg-config's search path PKG_CONFIG_LIBDIR path overriding pkg-config's built-in search path CURL_CFLAGS C compiler flags for CURL, overriding pkg-config CURL_LIBS linker flags for CURL, overriding pkg-config XML2_CFLAGS C compiler flags for XML2, overriding pkg-config XML2_LIBS linker flags for XML2, overriding pkg-config CPPUNIT_CFLAGS C compiler flags for CPPUNIT, overriding pkg-config CPPUNIT_LIBS linker flags for CPPUNIT, overriding pkg-config BOOST_ROOT Location of Boost installation Use these variables to override the choices made by `configure' or to help it to find libraries and programs with nonstandard names/locations. Report bugs to the package provider. _ACEOF ac_status=$? fi if test "$ac_init_help" = "recursive"; then # If there are subdirs, report their specific --help. for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue test -d "$ac_dir" || { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || continue ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix cd "$ac_dir" || { ac_status=$?; continue; } # Check for guested configure. if test -f "$ac_srcdir/configure.gnu"; then echo && $SHELL "$ac_srcdir/configure.gnu" --help=recursive elif test -f "$ac_srcdir/configure"; then echo && $SHELL "$ac_srcdir/configure" --help=recursive else $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 fi || ac_status=$? cd "$ac_pwd" || { ac_status=$?; break; } done fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF libcmis configure 0.5.2 generated by GNU Autoconf 2.69 Copyright (C) 2012 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _ACEOF exit fi ## ------------------------ ## ## Autoconf initialization. ## ## ------------------------ ## # ac_fn_c_try_compile LINENO # -------------------------- # Try to compile conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_compile () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack rm -f conftest.$ac_objext if { { ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_compile # ac_fn_c_try_cpp LINENO # ---------------------- # Try to preprocess conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_cpp () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if { { ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } > conftest.i && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_cpp # ac_fn_cxx_try_compile LINENO # ---------------------------- # Try to compile conftest.$ac_ext, and return whether this succeeded. ac_fn_cxx_try_compile () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack rm -f conftest.$ac_objext if { { ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_cxx_try_compile # ac_fn_c_try_link LINENO # ----------------------- # Try to link conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_link () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack rm -f conftest.$ac_objext conftest$ac_exeext if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && { test "$cross_compiling" = yes || test -x conftest$ac_exeext }; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would # interfere with the next link command; also delete a directory that is # left behind by Apple's compiler. We do this before executing the actions. rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_link # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES # ------------------------------------------------------- # Tests whether HEADER exists and can be compiled using the include files in # INCLUDES, setting the cache variable VAR accordingly. ac_fn_c_check_header_compile () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 #include <$2> _ACEOF if ac_fn_c_try_compile "$LINENO"; then : eval "$3=yes" else eval "$3=no" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_header_compile # ac_fn_c_try_run LINENO # ---------------------- # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes # that executables *can* be run. ac_fn_c_try_run () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' { { case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_try") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; }; then : ac_retval=0 else $as_echo "$as_me: program exited with status $ac_status" >&5 $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=$ac_status fi rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_run # ac_fn_c_check_func LINENO FUNC VAR # ---------------------------------- # Tests whether FUNC exists, setting the cache variable VAR accordingly ac_fn_c_check_func () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Define $2 to an innocuous variant, in case <limits.h> declares $2. For example, HP-UX 11i <limits.h> declares gettimeofday. */ #define $2 innocuous_$2 /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $2 (); below. Prefer <limits.h> to <assert.h> if __STDC__ is defined, since <limits.h> exists even on freestanding compilers. */ #ifdef __STDC__ # include <limits.h> #else # include <assert.h> #endif #undef $2 /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char $2 (); /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined __stub_$2 || defined __stub___$2 choke me #endif int main () { return $2 (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : eval "$3=yes" else eval "$3=no" fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_func # ac_fn_cxx_try_cpp LINENO # ------------------------ # Try to preprocess conftest.$ac_ext, and return whether this succeeded. ac_fn_cxx_try_cpp () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if { { ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } > conftest.i && { test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || test ! -s conftest.err }; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_cxx_try_cpp # ac_fn_cxx_try_link LINENO # ------------------------- # Try to link conftest.$ac_ext, and return whether this succeeded. ac_fn_cxx_try_link () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack rm -f conftest.$ac_objext conftest$ac_exeext if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && { test "$cross_compiling" = yes || test -x conftest$ac_exeext }; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would # interfere with the next link command; also delete a directory that is # left behind by Apple's compiler. We do this before executing the actions. rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_cxx_try_link # ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES # --------------------------------------------------------- # Tests whether HEADER exists, giving a warning if it cannot be compiled using # the include files in INCLUDES and setting the cache variable VAR # accordingly. ac_fn_cxx_check_header_mongrel () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack if eval \${$3+:} false; then : { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } else # Is the header compilable? { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 $as_echo_n "checking $2 usability... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 #include <$2> _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : ac_header_compiler=yes else ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 $as_echo "$ac_header_compiler" >&6; } # Is the header present? { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 $as_echo_n "checking $2 presence... " >&6; } cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <$2> _ACEOF if ac_fn_cxx_try_cpp "$LINENO"; then : ac_header_preproc=yes else ac_header_preproc=no fi rm -f conftest.err conftest.i conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 $as_echo "$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #(( yes:no: ) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} ;; no:yes:* ) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else eval "$3=\$ac_header_compiler" fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } fi eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_cxx_check_header_mongrel # ac_fn_cxx_check_type LINENO TYPE VAR INCLUDES # --------------------------------------------- # Tests whether TYPE exists after having included INCLUDES, setting cache # variable VAR accordingly. ac_fn_cxx_check_type () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else eval "$3=no" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main () { if (sizeof ($2)) return 0; ; return 0; } _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ $4 int main () { if (sizeof (($2))) return 0; ; return 0; } _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : else eval "$3=yes" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_cxx_check_type cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. It was created by libcmis $as_me 0.5.2, which was generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ _ACEOF exec 5>>config.log { cat <<_ASUNAME ## --------- ## ## Platform. ## ## --------- ## hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` uname -m = `(uname -m) 2>/dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` _ASUNAME as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. $as_echo "PATH: $as_dir" done IFS=$as_save_IFS } >&5 cat >&5 <<_ACEOF ## ----------- ## ## Core tests. ## ## ----------- ## _ACEOF # Keep a trace of the command line. # Strip out --no-create and --no-recursion so they do not pile up. # Strip out --silent because we don't want to record it for future runs. # Also quote any args containing shell meta-characters. # Make two passes to allow for proper duplicate-argument suppression. ac_configure_args= ac_configure_args0= ac_configure_args1= ac_must_keep_next=false for ac_pass in 1 2 do for ac_arg do case $ac_arg in -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) continue ;; *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac case $ac_pass in 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 2) as_fn_append ac_configure_args1 " '$ac_arg'" if test $ac_must_keep_next = true; then ac_must_keep_next=false # Got value, back to normal. else case $ac_arg in *=* | --config-cache | -C | -disable-* | --disable-* \ | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ | -with-* | --with-* | -without-* | --without-* | --x) case "$ac_configure_args0 " in "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; esac ;; -* ) ac_must_keep_next=true ;; esac fi as_fn_append ac_configure_args " '$ac_arg'" ;; esac done done { ac_configure_args0=; unset ac_configure_args0;} { ac_configure_args1=; unset ac_configure_args1;} # When interrupted or exit'd, cleanup temporary files, and complete # config.log. We remove comments because anyway the quotes in there # would cause problems or look ugly. # WARNING: Use '\'' to represent an apostrophe within the trap. # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. trap 'exit_status=$? # Save into config.log some information that might help in debugging. { echo $as_echo "## ---------------- ## ## Cache variables. ## ## ---------------- ##" echo # The following way of writing the cache mishandles newlines in values, ( for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( *) { eval $ac_var=; unset $ac_var;} ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( *${as_nl}ac_space=\ *) sed -n \ "s/'\''/'\''\\\\'\'''\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" ;; #( *) sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) echo $as_echo "## ----------------- ## ## Output variables. ## ## ----------------- ##" echo for ac_var in $ac_subst_vars do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac $as_echo "$ac_var='\''$ac_val'\''" done | sort echo if test -n "$ac_subst_files"; then $as_echo "## ------------------- ## ## File substitutions. ## ## ------------------- ##" echo for ac_var in $ac_subst_files do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac $as_echo "$ac_var='\''$ac_val'\''" done | sort echo fi if test -s confdefs.h; then $as_echo "## ----------- ## ## confdefs.h. ## ## ----------- ##" echo cat confdefs.h echo fi test "$ac_signal" != 0 && $as_echo "$as_me: caught signal $ac_signal" $as_echo "$as_me: exit $exit_status" } >&5 rm -f core *.core core.conftest.* && rm -f -r conftest* confdefs* conf$$* $ac_clean_files && exit $exit_status ' 0 for ac_signal in 1 2 13 15; do trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal done ac_signal=0 # confdefs.h avoids OS command line length limits that DEFS can exceed. rm -f -r conftest* confdefs.h $as_echo "/* confdefs.h */" > confdefs.h # Predefined preprocessor variables. cat >>confdefs.h <<_ACEOF #define PACKAGE_NAME "$PACKAGE_NAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_TARNAME "$PACKAGE_TARNAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_VERSION "$PACKAGE_VERSION" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_STRING "$PACKAGE_STRING" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_URL "$PACKAGE_URL" _ACEOF # Let the site file select an alternate cache file if it wants to. # Prefer an explicitly selected file to automatically selected ones. ac_site_file1=NONE ac_site_file2=NONE if test -n "$CONFIG_SITE"; then # We do not want a PATH search for config.site. case $CONFIG_SITE in #(( -*) ac_site_file1=./$CONFIG_SITE;; */*) ac_site_file1=$CONFIG_SITE;; *) ac_site_file1=./$CONFIG_SITE;; esac elif test "x$prefix" != xNONE; then ac_site_file1=$prefix/share/config.site ac_site_file2=$prefix/etc/config.site else ac_site_file1=$ac_default_prefix/share/config.site ac_site_file2=$ac_default_prefix/etc/config.site fi for ac_site_file in "$ac_site_file1" "$ac_site_file2" do test "x$ac_site_file" = xNONE && continue if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 $as_echo "$as_me: loading site script $ac_site_file" >&6;} sed 's/^/| /' "$ac_site_file" >&5 . "$ac_site_file" \ || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "failed to load site script $ac_site_file See \`config.log' for more details" "$LINENO" 5; } fi done if test -r "$cache_file"; then # Some versions of bash will fail to source /dev/null (special files # actually), so we avoid doing that. DJGPP emulates it as a regular file. if test /dev/null != "$cache_file" && test -f "$cache_file"; then { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 $as_echo "$as_me: loading cache $cache_file" >&6;} case $cache_file in [\\/]* | ?:[\\/]* ) . "$cache_file";; *) . "./$cache_file";; esac fi else { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 $as_echo "$as_me: creating cache $cache_file" >&6;} >$cache_file fi # Check that the precious variables saved in the cache have kept the same # value. ac_cache_corrupted=false for ac_var in $ac_precious_vars; do eval ac_old_set=\$ac_cv_env_${ac_var}_set eval ac_new_set=\$ac_env_${ac_var}_set eval ac_old_val=\$ac_cv_env_${ac_var}_value eval ac_new_val=\$ac_env_${ac_var}_value case $ac_old_set,$ac_new_set in set,) { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} ac_cache_corrupted=: ;; ,set) { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} ac_cache_corrupted=: ;; ,);; *) if test "x$ac_old_val" != "x$ac_new_val"; then # differences in whitespace do not lead to failure. ac_old_val_w=`echo x $ac_old_val` ac_new_val_w=`echo x $ac_new_val` if test "$ac_old_val_w" != "$ac_new_val_w"; then { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} ac_cache_corrupted=: else { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} eval $ac_var=\$ac_old_val fi { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} fi;; esac # Pass precious variables to config.status. if test "$ac_new_set" = set; then case $ac_new_val in *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; *) ac_arg=$ac_var=$ac_new_val ;; esac case " $ac_configure_args " in *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. *) as_fn_append ac_configure_args " '$ac_arg'" ;; esac fi done if $ac_cache_corrupted; then { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 fi ## -------------------- ## ## Main body of script. ## ## -------------------- ## ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu am__api_version='1.16' ac_aux_dir= for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do if test -f "$ac_dir/install-sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install-sh -c" break elif test -f "$ac_dir/install.sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install.sh -c" break elif test -f "$ac_dir/shtool"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/shtool install -c" break fi done if test -z "$ac_aux_dir"; then as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 fi # These three variables are undocumented and unsupported, # and are intended to be withdrawn in a future Autoconf release. # They can cause serious problems if a builder's source tree is in a directory # whose full name contains unusual characters. ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: # SysV /etc/install, /usr/sbin/install # SunOS /usr/etc/install # IRIX /sbin/install # AIX /bin/install # AmigaOS /C/install, which installs bootblocks on floppy discs # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag # AFS /usr/afsws/bin/install, which mishandles nonexistent args # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # OS/2's system install, which has a completely different semantic # ./install, which can be erroneously created by make from ./install.sh. # Reject install programs that cannot install multiple files. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 $as_echo_n "checking for a BSD-compatible install... " >&6; } if test -z "$INSTALL"; then if ${ac_cv_path_install+:} false; then : $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. # Account for people who put trailing slashes in PATH elements. case $as_dir/ in #(( ./ | .// | /[cC]/* | \ /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ /usr/ucb/* ) ;; *) # OSF1 and SCO ODT 3.0 have their own names for install. # Don't use installbsd from OSF since it installs stuff as root # by default. for ac_prog in ginstall scoinst install; do for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then if test $ac_prog = install && grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. : elif test $ac_prog = install && grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # program-specific install script used by HP pwplus--don't use. : else rm -rf conftest.one conftest.two conftest.dir echo one > conftest.one echo two > conftest.two mkdir conftest.dir if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && test -s conftest.one && test -s conftest.two && test -s conftest.dir/conftest.one && test -s conftest.dir/conftest.two then ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" break 3 fi fi fi done done ;; esac done IFS=$as_save_IFS rm -rf conftest.one conftest.two conftest.dir fi if test "${ac_cv_path_install+set}" = set; then INSTALL=$ac_cv_path_install else # As a last resort, use the slow shell script. Don't cache a # value for INSTALL within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the value is a relative name. INSTALL=$ac_install_sh fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 $as_echo "$INSTALL" >&6; } # Use test -z because SunOS4 sh mishandles braces in ${var-val}. # It thinks the first close brace ends the variable substitution. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 $as_echo_n "checking whether build environment is sane... " >&6; } # Reject unsafe characters in $srcdir or the absolute working directory # name. Accept space and tab only in the latter. am_lf=' ' case `pwd` in *[\\\"\#\$\&\'\`$am_lf]*) as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;; esac case $srcdir in *[\\\"\#\$\&\'\`$am_lf\ \ ]*) as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;; esac # Do 'set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( am_has_slept=no for am_try in 1 2; do echo "timestamp, slept: $am_has_slept" > conftest.file set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` if test "$*" = "X"; then # -L didn't work. set X `ls -t "$srcdir/configure" conftest.file` fi if test "$*" != "X $srcdir/configure conftest.file" \ && test "$*" != "X conftest.file $srcdir/configure"; then # If neither matched, then we have a broken ls. This can happen # if, for instance, CONFIG_SHELL is bash and it inherits a # broken ls alias from the environment. This has actually # happened. Such a system could not be considered "sane". as_fn_error $? "ls -t appears to fail. Make sure there is not a broken alias in your environment" "$LINENO" 5 fi if test "$2" = conftest.file || test $am_try -eq 2; then break fi # Just in case. sleep 1 am_has_slept=yes done test "$2" = conftest.file ) then # Ok. : else as_fn_error $? "newly created file is older than distributed files! Check your system clock" "$LINENO" 5 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } # If we didn't sleep, we still need to ensure time stamps of config.status and # generated files are strictly newer. am_sleep_pid= if grep 'slept: no' conftest.file >/dev/null 2>&1; then ( sleep 1 ) & am_sleep_pid=$! fi rm -f conftest.file test "$program_prefix" != NONE && program_transform_name="s&^&$program_prefix&;$program_transform_name" # Use a double $ so make ignores it. test "$program_suffix" != NONE && program_transform_name="s&\$&$program_suffix&;$program_transform_name" # Double any \ or $. # By default was `s,x,x', remove it if useless. ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` # Expand $ac_aux_dir to an absolute path. am_aux_dir=`cd "$ac_aux_dir" && pwd` if test x"${MISSING+set}" != xset; then case $am_aux_dir in *\ * | *\ *) MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; *) MISSING="\${SHELL} $am_aux_dir/missing" ;; esac fi # Use eval to expand $SHELL if eval "$MISSING --is-lightweight"; then am_missing_run="$MISSING " else am_missing_run= { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5 $as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;} fi if test x"${install_sh+set}" != xset; then case $am_aux_dir in *\ * | *\ *) install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; *) install_sh="\${SHELL} $am_aux_dir/install-sh" esac fi # Installed binaries are usually stripped using 'strip' when the user # run "make install-strip". However 'strip' might not be the right # tool to use in cross-compilation environments, therefore Automake # will honor the 'STRIP' environment variable to overrule this program. if test "$cross_compiling" != no; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$STRIP"; then ac_cv_prog_STRIP="$STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 $as_echo "$STRIP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_STRIP"; then ac_ct_STRIP=$STRIP # Extract the first word of "strip", so it can be a program name with args. set dummy strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_STRIP"; then ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_STRIP="strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 $as_echo "$ac_ct_STRIP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_STRIP" = x; then STRIP=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac STRIP=$ac_ct_STRIP fi else STRIP="$ac_cv_prog_STRIP" fi fi INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; } if test -z "$MKDIR_P"; then if ${ac_cv_path_mkdir+:} false; then : $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in mkdir gmkdir; do for ac_exec_ext in '' $ac_executable_extensions; do as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( 'mkdir (GNU coreutils) '* | \ 'mkdir (coreutils) '* | \ 'mkdir (fileutils) '4.1*) ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext break 3;; esac done done done IFS=$as_save_IFS fi test -d ./--version && rmdir ./--version if test "${ac_cv_path_mkdir+set}" = set; then MKDIR_P="$ac_cv_path_mkdir -p" else # As a last resort, use the slow shell script. Don't cache a # value for MKDIR_P within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the value is a relative name. MKDIR_P="$ac_install_sh -d" fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 $as_echo "$MKDIR_P" >&6; } for ac_prog in gawk mawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_AWK+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$AWK"; then ac_cv_prog_AWK="$AWK" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_AWK="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi AWK=$ac_cv_prog_AWK if test -n "$AWK"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 $as_echo "$AWK" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$AWK" && break done { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } set x ${MAKE-make} ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : $as_echo_n "(cached) " >&6 else cat >conftest.make <<\_ACEOF SHELL = /bin/sh all: @echo '@@@%%%=$(MAKE)=@@@%%%' _ACEOF # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. case `${MAKE-make} -f conftest.make 2>/dev/null` in *@@@%%%=?*=@@@%%%*) eval ac_cv_prog_make_${ac_make}_set=yes;; *) eval ac_cv_prog_make_${ac_make}_set=no;; esac rm -f conftest.make fi if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } SET_MAKE= else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } SET_MAKE="MAKE=${MAKE-make}" fi rm -rf .tst 2>/dev/null mkdir .tst 2>/dev/null if test -d .tst; then am__leading_dot=. else am__leading_dot=_ fi rmdir .tst 2>/dev/null # Check whether --enable-silent-rules was given. if test "${enable_silent_rules+set}" = set; then : enableval=$enable_silent_rules; fi case $enable_silent_rules in # ((( yes) AM_DEFAULT_VERBOSITY=0;; no) AM_DEFAULT_VERBOSITY=1;; *) AM_DEFAULT_VERBOSITY=1;; esac am_make=${MAKE-make} { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 $as_echo_n "checking whether $am_make supports nested variables... " >&6; } if ${am_cv_make_support_nested_variables+:} false; then : $as_echo_n "(cached) " >&6 else if $as_echo 'TRUE=$(BAR$(V)) BAR0=false BAR1=true V=1 am__doit: @$(TRUE) .PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then am_cv_make_support_nested_variables=yes else am_cv_make_support_nested_variables=no fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 $as_echo "$am_cv_make_support_nested_variables" >&6; } if test $am_cv_make_support_nested_variables = yes; then AM_V='$(V)' AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' else AM_V=$AM_DEFAULT_VERBOSITY AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY fi AM_BACKSLASH='\' if test "`cd $srcdir && pwd`" != "`pwd`"; then # Use -I$(srcdir) only when $(srcdir) != ., so that make's output # is not polluted with repeated "-I." am__isrc=' -I$(srcdir)' # test to see if srcdir already configured if test -f $srcdir/config.status; then as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 fi fi # test whether we have cygpath if test -z "$CYGPATH_W"; then if (cygpath --version) >/dev/null 2>/dev/null; then CYGPATH_W='cygpath -w' else CYGPATH_W=echo fi fi # Define the identity of the package. PACKAGE='libcmis' VERSION='0.5.2' cat >>confdefs.h <<_ACEOF #define PACKAGE "$PACKAGE" _ACEOF cat >>confdefs.h <<_ACEOF #define VERSION "$VERSION" _ACEOF # Some tools Automake needs. ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} # For better backward compatibility. To be removed once Automake 1.9.x # dies out for good. For more background, see: # <https://lists.gnu.org/archive/html/automake/2012-07/msg00001.html> # <https://lists.gnu.org/archive/html/automake/2012-07/msg00014.html> mkdir_p='$(MKDIR_P)' # We need awk for the "check" target (and possibly the TAP driver). The # system "awk" is bad on some platforms. # Always define AMTAR for backward compatibility. Yes, it's still used # in the wild :-( We should find a proper way to deprecate it ... AMTAR='$${TAR-tar}' # We'll loop over all known methods to create a tar archive until one works. _am_tools='gnutar pax cpio none' am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -' # POSIX will say in a future version that running "rm -f" with no argument # is OK; and we want to be able to make that assumption in our Makefile # recipes. So use an aggressive probe to check that the usage we want is # actually supported "in the wild" to an acceptable degree. # See automake bug#10828. # To make any issue more visible, cause the running configure to be aborted # by default if the 'rm' program in use doesn't match our expectations; the # user can still override this though. if rm -f && rm -fr && rm -rf; then : OK; else cat >&2 <<'END' Oops! Your 'rm' program seems unable to run without file operands specified on the command line, even when the '-f' option is present. This is contrary to the behaviour of most rm programs out there, and not conforming with the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542> Please tell bug-automake@gnu.org about your system, including the value of your $PATH and any error possibly output before this message. This can help us improve future automake versions. END if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then echo 'Configuration will proceed anyway, since you have set the' >&2 echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2 echo >&2 else cat >&2 <<'END' Aborting the configuration process, to ensure you take notice of the issue. You can download and install GNU coreutils to get an 'rm' implementation that behaves properly: <https://www.gnu.org/software/coreutils/>. If you want to complete the configuration process using your problematic 'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM to "yes", and re-run configure. END as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5 fi fi # Check whether --enable-silent-rules was given. if test "${enable_silent_rules+set}" = set; then : enableval=$enable_silent_rules; fi case $enable_silent_rules in # ((( yes) AM_DEFAULT_VERBOSITY=0;; no) AM_DEFAULT_VERBOSITY=1;; *) AM_DEFAULT_VERBOSITY=0;; esac am_make=${MAKE-make} { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5 $as_echo_n "checking whether $am_make supports nested variables... " >&6; } if ${am_cv_make_support_nested_variables+:} false; then : $as_echo_n "(cached) " >&6 else if $as_echo 'TRUE=$(BAR$(V)) BAR0=false BAR1=true V=1 am__doit: @$(TRUE) .PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then am_cv_make_support_nested_variables=yes else am_cv_make_support_nested_variables=no fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5 $as_echo "$am_cv_make_support_nested_variables" >&6; } if test $am_cv_make_support_nested_variables = yes; then AM_V='$(V)' AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)' else AM_V=$AM_DEFAULT_VERBOSITY AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY fi AM_BACKSLASH='\' # Checks for programs. ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. set dummy ${ac_tool_prefix}gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_CC"; then ac_ct_CC=$CC # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 $as_echo "$ac_ct_CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi else CC="$ac_cv_prog_CC" fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. set dummy ${ac_tool_prefix}cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="${ac_tool_prefix}cc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi fi if test -z "$CC"; then # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else ac_prog_rejected=no as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then ac_prog_rejected=yes continue fi ac_cv_prog_CC="cc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS if test $ac_prog_rejected = yes; then # We found a bogon in the path, so make sure we never use it. set dummy $ac_cv_prog_CC shift if test $# != 0; then # We chose a different compiler from the bogus one. # However, it has the same basename, so the bogon will be chosen # first if we set CC to just the basename; use the full file name. shift ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" fi fi fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then for ac_prog in cl.exe do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$CC" && break done fi if test -z "$CC"; then ac_ct_CC=$CC for ac_prog in cl.exe do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CC="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 $as_echo "$ac_ct_CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$ac_ct_CC" && break done if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi fi fi test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "no acceptable C compiler found in \$PATH See \`config.log' for more details" "$LINENO" 5; } # Provide some information about the compiler. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 set X $ac_compile ac_compiler=$2 for ac_option in --version -v -V -qversion; do { { ac_try="$ac_compiler $ac_option >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compiler $ac_option >&5") 2>conftest.err ac_status=$? if test -s conftest.err; then sed '10a\ ... rest of stderr output deleted ... 10q' conftest.err >conftest.er1 cat conftest.er1 >&5 fi rm -f conftest.er1 conftest.err $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } done cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" # Try to create an executable without -o first, disregard a.out. # It will help us diagnose broken compilers, and finding out an intuition # of exeext. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 $as_echo_n "checking whether the C compiler works... " >&6; } ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` # The possible output files: ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" ac_rmfiles= for ac_file in $ac_files do case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; * ) ac_rmfiles="$ac_rmfiles $ac_file";; esac done rm -f $ac_rmfiles if { { ac_try="$ac_link_default" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link_default") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then : # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' # in a Makefile. We should not override ac_cv_exeext if it was cached, # so that the user can short-circuit this test for compilers unknown to # Autoconf. for ac_file in $ac_files '' do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; [ab].out ) # We found the default executable, but exeext='' is most # certainly right. break;; *.* ) if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; then :; else ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` fi # We set ac_cv_exeext here because the later test for it is not # safe: cross compilers may not add the suffix if given an `-o' # argument, so we may need to know it at that point already. # Even if this section looks crufty: it has the advantage of # actually working. break;; * ) break;; esac done test "$ac_cv_exeext" = no && ac_cv_exeext= else ac_file='' fi if test -z "$ac_file"; then : { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error 77 "C compiler cannot create executables See \`config.log' for more details" "$LINENO" 5; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 $as_echo_n "checking for C compiler default output file name... " >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 $as_echo "$ac_file" >&6; } ac_exeext=$ac_cv_exeext rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out ac_clean_files=$ac_clean_files_save { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 $as_echo_n "checking for suffix of executables... " >&6; } if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then : # If both `conftest.exe' and `conftest' are `present' (well, observable) # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will # work properly (i.e., refer to `conftest.exe'), while it won't with # `rm'. for ac_file in conftest.exe conftest conftest.*; do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` break;; * ) break;; esac done else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot compute suffix of executables: cannot compile and link See \`config.log' for more details" "$LINENO" 5; } fi rm -f conftest conftest$ac_cv_exeext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 $as_echo "$ac_cv_exeext" >&6; } rm -f conftest.$ac_ext EXEEXT=$ac_cv_exeext ac_exeext=$EXEEXT cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <stdio.h> int main () { FILE *f = fopen ("conftest.out", "w"); return ferror (f) || fclose (f) != 0; ; return 0; } _ACEOF ac_clean_files="$ac_clean_files conftest.out" # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 $as_echo_n "checking whether we are cross compiling... " >&6; } if test "$cross_compiling" != yes; then { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } if { ac_try='./conftest$ac_cv_exeext' { { case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_try") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; }; then cross_compiling=no else if test "$cross_compiling" = maybe; then cross_compiling=yes else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details" "$LINENO" 5; } fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 $as_echo "$cross_compiling" >&6; } rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out ac_clean_files=$ac_clean_files_save { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 $as_echo_n "checking for suffix of object files... " >&6; } if ${ac_cv_objext+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.o conftest.obj if { { ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then : for ac_file in conftest.o conftest.obj conftest.*; do test -f "$ac_file" || continue; case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` break;; esac done else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "cannot compute suffix of object files: cannot compile See \`config.log' for more details" "$LINENO" 5; } fi rm -f conftest.$ac_cv_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 $as_echo "$ac_cv_objext" >&6; } OBJEXT=$ac_cv_objext ac_objext=$OBJEXT { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } if ${ac_cv_c_compiler_gnu+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_compiler_gnu=yes else ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_c_compiler_gnu=$ac_compiler_gnu fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 $as_echo "$ac_cv_c_compiler_gnu" >&6; } if test $ac_compiler_gnu = yes; then GCC=yes else GCC= fi ac_test_CFLAGS=${CFLAGS+set} ac_save_CFLAGS=$CFLAGS { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 $as_echo_n "checking whether $CC accepts -g... " >&6; } if ${ac_cv_prog_cc_g+:} false; then : $as_echo_n "(cached) " >&6 else ac_save_c_werror_flag=$ac_c_werror_flag ac_c_werror_flag=yes ac_cv_prog_cc_g=no CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_g=yes else CFLAGS="" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : else ac_c_werror_flag=$ac_save_c_werror_flag CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_g=yes fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_c_werror_flag=$ac_save_c_werror_flag fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 $as_echo "$ac_cv_prog_cc_g" >&6; } if test "$ac_test_CFLAGS" = set; then CFLAGS=$ac_save_CFLAGS elif test $ac_cv_prog_cc_g = yes; then if test "$GCC" = yes; then CFLAGS="-g -O2" else CFLAGS="-g" fi else if test "$GCC" = yes; then CFLAGS="-O2" else CFLAGS= fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } if ${ac_cv_prog_cc_c89+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_prog_cc_c89=no ac_save_CC=$CC cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <stdarg.h> #include <stdio.h> struct stat; /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ struct buf { int x; }; FILE * (*rcsopen) (struct buf *, struct stat *, int); static char *e (p, i) char **p; int i; { return p[i]; } static char *f (char * (*g) (char **, int), char **p, ...) { char *s; va_list v; va_start (v,p); s = g (p, va_arg (v,int)); va_end (v); return s; } /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has function prototypes and stuff, but not '\xHH' hex character constants. These don't provoke an error unfortunately, instead are silently treated as 'x'. The following induces an error, until -std is added to get proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an array size at least. It's necessary to write '\x00'==0 to get something that's true only with -std. */ int osf4_cc_array ['\x00' == 0 ? 1 : -1]; /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters inside strings and character constants. */ #define FOO(x) 'x' int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; int test (int i, double x); struct s1 {int (*f) (int a);}; struct s2 {int (*f) (double a);}; int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); int argc; char **argv; int main () { return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; ; return 0; } _ACEOF for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" do CC="$ac_save_CC $ac_arg" if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_c89=$ac_arg fi rm -f core conftest.err conftest.$ac_objext test "x$ac_cv_prog_cc_c89" != "xno" && break done rm -f conftest.$ac_ext CC=$ac_save_CC fi # AC_CACHE_VAL case "x$ac_cv_prog_cc_c89" in x) { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 $as_echo "none needed" >&6; } ;; xno) { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 $as_echo "unsupported" >&6; } ;; *) CC="$CC $ac_cv_prog_cc_c89" { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; esac if test "x$ac_cv_prog_cc_c89" != xno; then : fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5 $as_echo_n "checking whether $CC understands -c and -o together... " >&6; } if ${am_cv_prog_cc_c_o+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF # Make sure it works both with $CC and with simple cc. # Following AC_PROG_CC_C_O, we do the test twice because some # compilers refuse to overwrite an existing .o file with -o, # though they will create one. am_cv_prog_cc_c_o=yes for am_i in 1 2; do if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5 ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } \ && test -f conftest2.$ac_objext; then : OK else am_cv_prog_cc_c_o=no break fi done rm -f core conftest* unset am_i fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5 $as_echo "$am_cv_prog_cc_c_o" >&6; } if test "$am_cv_prog_cc_c_o" != yes; then # Losing compiler, so override with the script. # FIXME: It is wrong to rewrite CC. # But if we don't then we get into trouble of one sort or another. # A longer-term fix would be to have automake use am__CC in this case, # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" CC="$am_aux_dir/compile $CC" fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu DEPDIR="${am__leading_dot}deps" ac_config_commands="$ac_config_commands depfiles" { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} supports the include directive" >&5 $as_echo_n "checking whether ${MAKE-make} supports the include directive... " >&6; } cat > confinc.mk << 'END' am__doit: @echo this is the am__doit target >confinc.out .PHONY: am__doit END am__include="#" am__quote= # BSD make does it like this. echo '.include "confinc.mk" # ignored' > confmf.BSD # Other make implementations (GNU, Solaris 10, AIX) do it like this. echo 'include confinc.mk # ignored' > confmf.GNU _am_result=no for s in GNU BSD; do { echo "$as_me:$LINENO: ${MAKE-make} -f confmf.$s && cat confinc.out" >&5 (${MAKE-make} -f confmf.$s && cat confinc.out) >&5 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } case $?:`cat confinc.out 2>/dev/null` in #( '0:this is the am__doit target') : case $s in #( BSD) : am__include='.include' am__quote='"' ;; #( *) : am__include='include' am__quote='' ;; esac ;; #( *) : ;; esac if test "$am__include" != "#"; then _am_result="yes ($s style)" break fi done rm -f confinc.* confmf.* { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${_am_result}" >&5 $as_echo "${_am_result}" >&6; } # Check whether --enable-dependency-tracking was given. if test "${enable_dependency_tracking+set}" = set; then : enableval=$enable_dependency_tracking; fi if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' am__nodep='_no' fi if test "x$enable_dependency_tracking" != xno; then AMDEP_TRUE= AMDEP_FALSE='#' else AMDEP_TRUE='#' AMDEP_FALSE= fi depcc="$CC" am_compiler_list= { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 $as_echo_n "checking dependency style of $depcc... " >&6; } if ${am_cv_CC_dependencies_compiler_type+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named 'D' -- because '-MD' means "put the output # in D". rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_CC_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` fi am__universal=false case " $depcc " in #( *\ -arch\ *\ -arch\ *) am__universal=true ;; esac for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with # Solaris 10 /bin/sh. echo '/* dummy */' > sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf # We check with '-c' and '-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle '-M -o', and we need to detect this. Also, some Intel # versions had trouble with output in subdirs. am__obj=sub/conftest.${OBJEXT-o} am__minus_obj="-o $am__obj" case $depmode in gcc) # This depmode causes a compiler race in universal mode. test "$am__universal" = false || continue ;; nosideeffect) # After this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested. if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; msvc7 | msvc7msys | msvisualcpp | msvcmsys) # This compiler won't grok '-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. am__obj=conftest.${OBJEXT-o} am__minus_obj= ;; none) break ;; esac if depmode=$depmode \ source=sub/conftest.c object=$am__obj \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep $am__obj sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_CC_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_CC_dependencies_compiler_type=none fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type if test "x$enable_dependency_tracking" != xno \ && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then am__fastdepCC_TRUE= am__fastdepCC_FALSE='#' else am__fastdepCC_TRUE='#' am__fastdepCC_FALSE= fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 $as_echo_n "checking how to run the C preprocessor... " >&6; } # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= fi if test -z "$CPP"; then if ${ac_cv_prog_CPP+:} false; then : $as_echo_n "(cached) " >&6 else # Double quotes because CPP needs to be expanded for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" do ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since # <limits.h> exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __STDC__ # include <limits.h> #else # include <assert.h> #endif Syntax error _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : else # Broken: fails on valid input. continue fi rm -f conftest.err conftest.i conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <ac_nonexistent.h> _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : # Broken: success on invalid input. continue else # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.i conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.i conftest.err conftest.$ac_ext if $ac_preproc_ok; then : break fi done ac_cv_prog_CPP=$CPP fi CPP=$ac_cv_prog_CPP else ac_cv_prog_CPP=$CPP fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 $as_echo "$CPP" >&6; } ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since # <limits.h> exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __STDC__ # include <limits.h> #else # include <assert.h> #endif Syntax error _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : else # Broken: fails on valid input. continue fi rm -f conftest.err conftest.i conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <ac_nonexistent.h> _ACEOF if ac_fn_c_try_cpp "$LINENO"; then : # Broken: success on invalid input. continue else # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.i conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.i conftest.err conftest.$ac_ext if $ac_preproc_ok; then : else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "C preprocessor \"$CPP\" fails sanity check See \`config.log' for more details" "$LINENO" 5; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu if test -z "$CXX"; then if test -n "$CCC"; then CXX=$CCC else if test -n "$ac_tool_prefix"; then for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_CXX+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CXX"; then ac_cv_prog_CXX="$CXX" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CXX=$ac_cv_prog_CXX if test -n "$CXX"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 $as_echo "$CXX" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$CXX" && break done fi if test -z "$CXX"; then ac_ct_CXX=$CXX for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_CXX+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CXX"; then ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_CXX="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CXX=$ac_cv_prog_ac_ct_CXX if test -n "$ac_ct_CXX"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 $as_echo "$ac_ct_CXX" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$ac_ct_CXX" && break done if test "x$ac_ct_CXX" = x; then CXX="g++" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CXX=$ac_ct_CXX fi fi fi fi # Provide some information about the compiler. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 set X $ac_compile ac_compiler=$2 for ac_option in --version -v -V -qversion; do { { ac_try="$ac_compiler $ac_option >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compiler $ac_option >&5") 2>conftest.err ac_status=$? if test -s conftest.err; then sed '10a\ ... rest of stderr output deleted ... 10q' conftest.err >conftest.er1 cat conftest.er1 >&5 fi rm -f conftest.er1 conftest.err $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } done { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } if ${ac_cv_cxx_compiler_gnu+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : ac_compiler_gnu=yes else ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_cxx_compiler_gnu=$ac_compiler_gnu fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; } if test $ac_compiler_gnu = yes; then GXX=yes else GXX= fi ac_test_CXXFLAGS=${CXXFLAGS+set} ac_save_CXXFLAGS=$CXXFLAGS { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 $as_echo_n "checking whether $CXX accepts -g... " >&6; } if ${ac_cv_prog_cxx_g+:} false; then : $as_echo_n "(cached) " >&6 else ac_save_cxx_werror_flag=$ac_cxx_werror_flag ac_cxx_werror_flag=yes ac_cv_prog_cxx_g=no CXXFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : ac_cv_prog_cxx_g=yes else CXXFLAGS="" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : else ac_cxx_werror_flag=$ac_save_cxx_werror_flag CXXFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : ac_cv_prog_cxx_g=yes fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cxx_werror_flag=$ac_save_cxx_werror_flag fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 $as_echo "$ac_cv_prog_cxx_g" >&6; } if test "$ac_test_CXXFLAGS" = set; then CXXFLAGS=$ac_save_CXXFLAGS elif test $ac_cv_prog_cxx_g = yes; then if test "$GXX" = yes; then CXXFLAGS="-g -O2" else CXXFLAGS="-g" fi else if test "$GXX" = yes; then CXXFLAGS="-O2" else CXXFLAGS= fi fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu depcc="$CXX" am_compiler_list= { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 $as_echo_n "checking dependency style of $depcc... " >&6; } if ${am_cv_CXX_dependencies_compiler_type+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named 'D' -- because '-MD' means "put the output # in D". rm -rf conftest.dir mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_CXX_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` fi am__universal=false case " $depcc " in #( *\ -arch\ *\ -arch\ *) am__universal=true ;; esac for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with # Solaris 10 /bin/sh. echo '/* dummy */' > sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf # We check with '-c' and '-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle '-M -o', and we need to detect this. Also, some Intel # versions had trouble with output in subdirs. am__obj=sub/conftest.${OBJEXT-o} am__minus_obj="-o $am__obj" case $depmode in gcc) # This depmode causes a compiler race in universal mode. test "$am__universal" = false || continue ;; nosideeffect) # After this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested. if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; msvc7 | msvc7msys | msvisualcpp | msvcmsys) # This compiler won't grok '-c -o', but also, the minuso test has # not run yet. These depmodes are late enough in the game, and # so weak that their functioning should not be impacted. am__obj=conftest.${OBJEXT-o} am__minus_obj= ;; none) break ;; esac if depmode=$depmode \ source=sub/conftest.c object=$am__obj \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep $am__obj sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_CXX_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_CXX_dependencies_compiler_type=none fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CXX_dependencies_compiler_type" >&5 $as_echo "$am_cv_CXX_dependencies_compiler_type" >&6; } CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type if test "x$enable_dependency_tracking" != xno \ && test "$am_cv_CXX_dependencies_compiler_type" = gcc3; then am__fastdepCXX_TRUE= am__fastdepCXX_FALSE='#' else am__fastdepCXX_TRUE='#' am__fastdepCXX_FALSE= fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 $as_echo_n "checking whether ln -s works... " >&6; } LN_S=$as_ln_s if test "$LN_S" = "ln -s"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 $as_echo "no, using $LN_S" >&6; } fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } set x ${MAKE-make} ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : $as_echo_n "(cached) " >&6 else cat >conftest.make <<\_ACEOF SHELL = /bin/sh all: @echo '@@@%%%=$(MAKE)=@@@%%%' _ACEOF # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. case `${MAKE-make} -f conftest.make 2>/dev/null` in *@@@%%%=?*=@@@%%%*) eval ac_cv_prog_make_${ac_make}_set=yes;; *) eval ac_cv_prog_make_${ac_make}_set=no;; esac rm -f conftest.make fi if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } SET_MAKE= else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } SET_MAKE="MAKE=${MAKE-make}" fi case `pwd` in *\ * | *\ *) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5 $as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;; esac macro_version='2.4.6' macro_revision='2.4.6' ltmain=$ac_aux_dir/ltmain.sh # Make sure we can run config.sub. $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 $as_echo_n "checking build system type... " >&6; } if ${ac_cv_build+:} false; then : $as_echo_n "(cached) " >&6 else ac_build_alias=$build_alias test "x$ac_build_alias" = x && ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` test "x$ac_build_alias" = x && as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 $as_echo "$ac_cv_build" >&6; } case $ac_cv_build in *-*-*) ;; *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; esac build=$ac_cv_build ac_save_IFS=$IFS; IFS='-' set x $ac_cv_build shift build_cpu=$1 build_vendor=$2 shift; shift # Remember, the first character of IFS is used to create $*, # except with old shells: build_os=$* IFS=$ac_save_IFS case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 $as_echo_n "checking host system type... " >&6; } if ${ac_cv_host+:} false; then : $as_echo_n "(cached) " >&6 else if test "x$host_alias" = x; then ac_cv_host=$ac_cv_build else ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 $as_echo "$ac_cv_host" >&6; } case $ac_cv_host in *-*-*) ;; *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; esac host=$ac_cv_host ac_save_IFS=$IFS; IFS='-' set x $ac_cv_host shift host_cpu=$1 host_vendor=$2 shift; shift # Remember, the first character of IFS is used to create $*, # except with old shells: host_os=$* IFS=$ac_save_IFS case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac # Backslashify metacharacters that are still active within # double-quoted strings. sed_quote_subst='s/\(["`$\\]\)/\\\1/g' # Same as above, but do not quote variable references. double_quote_subst='s/\(["`\\]\)/\\\1/g' # Sed substitution to delay expansion of an escaped shell variable in a # double_quote_subst'ed string. delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' # Sed substitution to delay expansion of an escaped single quote. delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' # Sed substitution to avoid accidental globbing in evaled expressions no_glob_subst='s/\*/\\\*/g' ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 $as_echo_n "checking how to print strings... " >&6; } # Test print first, because it will be a builtin if present. if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then ECHO='print -r --' elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then ECHO='printf %s\n' else # Use this function as a fallback that always works. func_fallback_echo () { eval 'cat <<_LTECHO_EOF $1 _LTECHO_EOF' } ECHO='func_fallback_echo' fi # func_echo_all arg... # Invoke $ECHO with all args, space-separated. func_echo_all () { $ECHO "" } case $ECHO in printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5 $as_echo "printf" >&6; } ;; print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5 $as_echo "print -r" >&6; } ;; *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5 $as_echo "cat" >&6; } ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 $as_echo_n "checking for a sed that does not truncate output... " >&6; } if ${ac_cv_path_SED+:} false; then : $as_echo_n "(cached) " >&6 else ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ for ac_i in 1 2 3 4 5 6 7; do ac_script="$ac_script$as_nl$ac_script" done echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed { ac_script=; unset ac_script;} if test -z "$SED"; then ac_path_SED_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in sed gsed; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_SED" || continue # Check for GNU ac_path_SED and select it if it is found. # Check for GNU $ac_path_SED case `"$ac_path_SED" --version 2>&1` in *GNU*) ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo '' >> "conftest.nl" "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_SED_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_SED="$ac_path_SED" ac_path_SED_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_SED_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_SED"; then as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 fi else ac_cv_path_SED=$SED fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 $as_echo "$ac_cv_path_SED" >&6; } SED="$ac_cv_path_SED" rm -f conftest.sed test -z "$SED" && SED=sed Xsed="$SED -e 1s/^X//" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } if ${ac_cv_path_GREP+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$GREP"; then ac_path_GREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in grep ggrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_GREP" || continue # Check for GNU ac_path_GREP and select it if it is found. # Check for GNU $ac_path_GREP case `"$ac_path_GREP" --version 2>&1` in *GNU*) ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo 'GREP' >> "conftest.nl" "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_GREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_GREP_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_GREP"; then as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_GREP=$GREP fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 $as_echo "$ac_cv_path_GREP" >&6; } GREP="$ac_cv_path_GREP" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 $as_echo_n "checking for egrep... " >&6; } if ${ac_cv_path_EGREP+:} false; then : $as_echo_n "(cached) " >&6 else if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 then ac_cv_path_EGREP="$GREP -E" else if test -z "$EGREP"; then ac_path_EGREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in egrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_EGREP" || continue # Check for GNU ac_path_EGREP and select it if it is found. # Check for GNU $ac_path_EGREP case `"$ac_path_EGREP" --version 2>&1` in *GNU*) ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo 'EGREP' >> "conftest.nl" "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_EGREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_EGREP_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_EGREP"; then as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_EGREP=$EGREP fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 $as_echo "$ac_cv_path_EGREP" >&6; } EGREP="$ac_cv_path_EGREP" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 $as_echo_n "checking for fgrep... " >&6; } if ${ac_cv_path_FGREP+:} false; then : $as_echo_n "(cached) " >&6 else if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 then ac_cv_path_FGREP="$GREP -F" else if test -z "$FGREP"; then ac_path_FGREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in fgrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_FGREP" || continue # Check for GNU ac_path_FGREP and select it if it is found. # Check for GNU $ac_path_FGREP case `"$ac_path_FGREP" --version 2>&1` in *GNU*) ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; *) ac_count=0 $as_echo_n 0123456789 >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" $as_echo 'FGREP' >> "conftest.nl" "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break as_fn_arith $ac_count + 1 && ac_count=$as_val if test $ac_count -gt ${ac_path_FGREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_FGREP_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_FGREP"; then as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 fi else ac_cv_path_FGREP=$FGREP fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 $as_echo "$ac_cv_path_FGREP" >&6; } FGREP="$ac_cv_path_FGREP" test -z "$GREP" && GREP=grep # Check whether --with-gnu-ld was given. if test "${with_gnu_ld+set}" = set; then : withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes else with_gnu_ld=no fi ac_prog=ld if test yes = "$GCC"; then # Check if gcc -print-prog-name=ld gives a path. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 $as_echo_n "checking for ld used by $CC... " >&6; } case $host in *-*-mingw*) # gcc leaves a trailing carriage return, which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; esac case $ac_prog in # Accept absolute paths. [\\/]* | ?:[\\/]*) re_direlt='/[^/][^/]*/\.\./' # Canonicalize the pathname of ld ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` done test -z "$LD" && LD=$ac_prog ;; "") # If it fails, then pretend we aren't using GCC. ac_prog=ld ;; *) # If it is relative, then search for the first ld in PATH. with_gnu_ld=unknown ;; esac elif test yes = "$with_gnu_ld"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 $as_echo_n "checking for GNU ld... " >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 $as_echo_n "checking for non-GNU ld... " >&6; } fi if ${lt_cv_path_LD+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$LD"; then lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then lt_cv_path_LD=$ac_dir/$ac_prog # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some variants of GNU ld only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in *GNU* | *'with BFD'*) test no != "$with_gnu_ld" && break ;; *) test yes != "$with_gnu_ld" && break ;; esac fi done IFS=$lt_save_ifs else lt_cv_path_LD=$LD # Let the user override the test with a path. fi fi LD=$lt_cv_path_LD if test -n "$LD"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 $as_echo "$LD" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } if ${lt_cv_prog_gnu_ld+:} false; then : $as_echo_n "(cached) " >&6 else # I'd rather use --version here, but apparently some GNU lds only accept -v. case `$LD -v 2>&1 </dev/null` in *GNU* | *'with BFD'*) lt_cv_prog_gnu_ld=yes ;; *) lt_cv_prog_gnu_ld=no ;; esac fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5 $as_echo "$lt_cv_prog_gnu_ld" >&6; } with_gnu_ld=$lt_cv_prog_gnu_ld { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5 $as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; } if ${lt_cv_path_NM+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$NM"; then # Let the user override the test. lt_cv_path_NM=$NM else lt_nm_to_check=${ac_tool_prefix}nm if test -n "$ac_tool_prefix" && test "$build" = "$host"; then lt_nm_to_check="$lt_nm_to_check nm" fi for lt_tmp_nm in $lt_nm_to_check; do lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. tmp_nm=$ac_dir/$lt_tmp_nm if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then # Check to see if the nm accepts a BSD-compat flag. # Adding the 'sed 1q' prevents false positives on HP-UX, which says: # nm: unknown option "B" ignored # Tru64's nm complains that /dev/null is an invalid object file # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty case $build_os in mingw*) lt_bad_file=conftest.nm/nofile ;; *) lt_bad_file=/dev/null ;; esac case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in *$lt_bad_file* | *'Invalid file or object type'*) lt_cv_path_NM="$tmp_nm -B" break 2 ;; *) case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in */dev/null*) lt_cv_path_NM="$tmp_nm -p" break 2 ;; *) lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but continue # so that we can try to find one that supports BSD flags ;; esac ;; esac fi done IFS=$lt_save_ifs done : ${lt_cv_path_NM=no} fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 $as_echo "$lt_cv_path_NM" >&6; } if test no != "$lt_cv_path_NM"; then NM=$lt_cv_path_NM else # Didn't find any BSD compatible name lister, look for dumpbin. if test -n "$DUMPBIN"; then : # Let the user override the test. else if test -n "$ac_tool_prefix"; then for ac_prog in dumpbin "link -dump" do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_DUMPBIN+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$DUMPBIN"; then ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi DUMPBIN=$ac_cv_prog_DUMPBIN if test -n "$DUMPBIN"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 $as_echo "$DUMPBIN" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$DUMPBIN" && break done fi if test -z "$DUMPBIN"; then ac_ct_DUMPBIN=$DUMPBIN for ac_prog in dumpbin "link -dump" do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_DUMPBIN"; then ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_DUMPBIN="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN if test -n "$ac_ct_DUMPBIN"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5 $as_echo "$ac_ct_DUMPBIN" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$ac_ct_DUMPBIN" && break done if test "x$ac_ct_DUMPBIN" = x; then DUMPBIN=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac DUMPBIN=$ac_ct_DUMPBIN fi fi case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in *COFF*) DUMPBIN="$DUMPBIN -symbols -headers" ;; *) DUMPBIN=: ;; esac fi if test : != "$DUMPBIN"; then NM=$DUMPBIN fi fi test -z "$NM" && NM=nm { $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5 $as_echo_n "checking the name lister ($NM) interface... " >&6; } if ${lt_cv_nm_interface+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_nm_interface="BSD nm" echo "int some_variable = 0;" > conftest.$ac_ext (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5) (eval "$ac_compile" 2>conftest.err) cat conftest.err >&5 (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5) (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) cat conftest.err >&5 (eval echo "\"\$as_me:$LINENO: output\"" >&5) cat conftest.out >&5 if $GREP 'External.*some_variable' conftest.out > /dev/null; then lt_cv_nm_interface="MS dumpbin" fi rm -f conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5 $as_echo "$lt_cv_nm_interface" >&6; } # find the maximum length of command line arguments { $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 $as_echo_n "checking the maximum length of command line arguments... " >&6; } if ${lt_cv_sys_max_cmd_len+:} false; then : $as_echo_n "(cached) " >&6 else i=0 teststring=ABCD case $build_os in msdosdjgpp*) # On DJGPP, this test can blow up pretty badly due to problems in libc # (any single argument exceeding 2000 bytes causes a buffer overrun # during glob expansion). Even if it were fixed, the result of this # check would be larger than it should be. lt_cv_sys_max_cmd_len=12288; # 12K is about right ;; gnu*) # Under GNU Hurd, this test is not required because there is # no limit to the length of command line arguments. # Libtool will interpret -1 as no limit whatsoever lt_cv_sys_max_cmd_len=-1; ;; cygwin* | mingw* | cegcc*) # On Win9x/ME, this test blows up -- it succeeds, but takes # about 5 minutes as the teststring grows exponentially. # Worse, since 9x/ME are not pre-emptively multitasking, # you end up with a "frozen" computer, even though with patience # the test eventually succeeds (with a max line length of 256k). # Instead, let's just punt: use the minimum linelength reported by # all of the supported platforms: 8192 (on NT/2K/XP). lt_cv_sys_max_cmd_len=8192; ;; mint*) # On MiNT this can take a long time and run out of memory. lt_cv_sys_max_cmd_len=8192; ;; amigaos*) # On AmigaOS with pdksh, this test takes hours, literally. # So we just punt and use a minimum line length of 8192. lt_cv_sys_max_cmd_len=8192; ;; bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*) # This has been around since 386BSD, at least. Likely further. if test -x /sbin/sysctl; then lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` elif test -x /usr/sbin/sysctl; then lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` else lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs fi # And add a safety zone lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` ;; interix*) # We know the value 262144 and hardcode it with a safety zone (like BSD) lt_cv_sys_max_cmd_len=196608 ;; os2*) # The test takes a long time on OS/2. lt_cv_sys_max_cmd_len=8192 ;; osf*) # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not # nice to cause kernel panics so lets avoid the loop below. # First set a reasonable default. lt_cv_sys_max_cmd_len=16384 # if test -x /sbin/sysconfig; then case `/sbin/sysconfig -q proc exec_disable_arg_limit` in *1*) lt_cv_sys_max_cmd_len=-1 ;; esac fi ;; sco3.2v5*) lt_cv_sys_max_cmd_len=102400 ;; sysv5* | sco5v6* | sysv4.2uw2*) kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` if test -n "$kargmax"; then lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'` else lt_cv_sys_max_cmd_len=32768 fi ;; *) lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` if test -n "$lt_cv_sys_max_cmd_len" && \ test undefined != "$lt_cv_sys_max_cmd_len"; then lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` else # Make teststring a little bigger before we do anything with it. # a 1K string should be a reasonable start. for i in 1 2 3 4 5 6 7 8; do teststring=$teststring$teststring done SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} # If test is not a shell built-in, we'll probably end up computing a # maximum length that is only half of the actual maximum length, but # we can't tell. while { test X`env echo "$teststring$teststring" 2>/dev/null` \ = "X$teststring$teststring"; } >/dev/null 2>&1 && test 17 != "$i" # 1/2 MB should be enough do i=`expr $i + 1` teststring=$teststring$teststring done # Only check the string length outside the loop. lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` teststring= # Add a significant safety factor because C++ compilers can tack on # massive amounts of additional arguments before passing them to the # linker. It appears as though 1/2 is a usable value. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` fi ;; esac fi if test -n "$lt_cv_sys_max_cmd_len"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 $as_echo "$lt_cv_sys_max_cmd_len" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 $as_echo "none" >&6; } fi max_cmd_len=$lt_cv_sys_max_cmd_len : ${CP="cp -f"} : ${MV="mv -f"} : ${RM="rm -f"} if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then lt_unset=unset else lt_unset=false fi # test EBCDIC or ASCII case `echo X|tr X '\101'` in A) # ASCII based system # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr lt_SP2NL='tr \040 \012' lt_NL2SP='tr \015\012 \040\040' ;; *) # EBCDIC based system lt_SP2NL='tr \100 \n' lt_NL2SP='tr \r\n \100\100' ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5 $as_echo_n "checking how to convert $build file names to $host format... " >&6; } if ${lt_cv_to_host_file_cmd+:} false; then : $as_echo_n "(cached) " >&6 else case $host in *-*-mingw* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 ;; *-*-cygwin* ) lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 ;; * ) # otherwise, assume *nix lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 ;; esac ;; *-*-cygwin* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin ;; *-*-cygwin* ) lt_cv_to_host_file_cmd=func_convert_file_noop ;; * ) # otherwise, assume *nix lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin ;; esac ;; * ) # unhandled hosts (and "normal" native builds) lt_cv_to_host_file_cmd=func_convert_file_noop ;; esac fi to_host_file_cmd=$lt_cv_to_host_file_cmd { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5 $as_echo "$lt_cv_to_host_file_cmd" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5 $as_echo_n "checking how to convert $build file names to toolchain format... " >&6; } if ${lt_cv_to_tool_file_cmd+:} false; then : $as_echo_n "(cached) " >&6 else #assume ordinary cross tools, or native build. lt_cv_to_tool_file_cmd=func_convert_file_noop case $host in *-*-mingw* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 ;; esac ;; esac fi to_tool_file_cmd=$lt_cv_to_tool_file_cmd { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5 $as_echo "$lt_cv_to_tool_file_cmd" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 $as_echo_n "checking for $LD option to reload object files... " >&6; } if ${lt_cv_ld_reload_flag+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_ld_reload_flag='-r' fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 $as_echo "$lt_cv_ld_reload_flag" >&6; } reload_flag=$lt_cv_ld_reload_flag case $reload_flag in "" | " "*) ;; *) reload_flag=" $reload_flag" ;; esac reload_cmds='$LD$reload_flag -o $output$reload_objs' case $host_os in cygwin* | mingw* | pw32* | cegcc*) if test yes != "$GCC"; then reload_cmds=false fi ;; darwin*) if test yes = "$GCC"; then reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs' else reload_cmds='$LD$reload_flag -o $output$reload_objs' fi ;; esac if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. set dummy ${ac_tool_prefix}objdump; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_OBJDUMP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OBJDUMP"; then ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi OBJDUMP=$ac_cv_prog_OBJDUMP if test -n "$OBJDUMP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 $as_echo "$OBJDUMP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_OBJDUMP"; then ac_ct_OBJDUMP=$OBJDUMP # Extract the first word of "objdump", so it can be a program name with args. set dummy objdump; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_OBJDUMP"; then ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_OBJDUMP="objdump" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP if test -n "$ac_ct_OBJDUMP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 $as_echo "$ac_ct_OBJDUMP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_OBJDUMP" = x; then OBJDUMP="false" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac OBJDUMP=$ac_ct_OBJDUMP fi else OBJDUMP="$ac_cv_prog_OBJDUMP" fi test -z "$OBJDUMP" && OBJDUMP=objdump { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5 $as_echo_n "checking how to recognize dependent libraries... " >&6; } if ${lt_cv_deplibs_check_method+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_file_magic_cmd='$MAGIC_CMD' lt_cv_file_magic_test_file= lt_cv_deplibs_check_method='unknown' # Need to set the preceding variable on all platforms that support # interlibrary dependencies. # 'none' -- dependencies not supported. # 'unknown' -- same as none, but documents that we really don't know. # 'pass_all' -- all dependencies passed with no checks. # 'test_compile' -- check by making test program. # 'file_magic [[regex]]' -- check by looking for files in library path # that responds to the $file_magic_cmd with a given extended regex. # If you have 'file' or equivalent on your system and you're not sure # whether 'pass_all' will *always* work, you probably want this one. case $host_os in aix[4-9]*) lt_cv_deplibs_check_method=pass_all ;; beos*) lt_cv_deplibs_check_method=pass_all ;; bsdi[45]*) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' lt_cv_file_magic_cmd='/usr/bin/file -L' lt_cv_file_magic_test_file=/shlib/libc.so ;; cygwin*) # func_win32_libid is a shell function defined in ltmain.sh lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' ;; mingw* | pw32*) # Base MSYS/MinGW do not provide the 'file' command needed by # func_win32_libid shell function, so use a weaker test based on 'objdump', # unless we find 'file', for example because we are cross-compiling. if ( file / ) >/dev/null 2>&1; then lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' else # Keep this pattern in sync with the one in func_win32_libid. lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' lt_cv_file_magic_cmd='$OBJDUMP -f' fi ;; cegcc*) # use the weaker test based on 'objdump'. See mingw*. lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' lt_cv_file_magic_cmd='$OBJDUMP -f' ;; darwin* | rhapsody*) lt_cv_deplibs_check_method=pass_all ;; freebsd* | dragonfly*) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then case $host_cpu in i*86 ) # Not sure whether the presence of OpenBSD here was a mistake. # Let's accept both of them until this is cleared up. lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' lt_cv_file_magic_cmd=/usr/bin/file lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` ;; esac else lt_cv_deplibs_check_method=pass_all fi ;; haiku*) lt_cv_deplibs_check_method=pass_all ;; hpux10.20* | hpux11*) lt_cv_file_magic_cmd=/usr/bin/file case $host_cpu in ia64*) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so ;; hppa*64*) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]' lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl ;; *) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library' lt_cv_file_magic_test_file=/usr/lib/libc.sl ;; esac ;; interix[3-9]*) # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' ;; irix5* | irix6* | nonstopux*) case $LD in *-32|*"-32 ") libmagic=32-bit;; *-n32|*"-n32 ") libmagic=N32;; *-64|*"-64 ") libmagic=64-bit;; *) libmagic=never-match;; esac lt_cv_deplibs_check_method=pass_all ;; # This must be glibc/ELF. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) lt_cv_deplibs_check_method=pass_all ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' fi ;; newos6*) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' lt_cv_file_magic_cmd=/usr/bin/file lt_cv_file_magic_test_file=/usr/lib/libnls.so ;; *nto* | *qnx*) lt_cv_deplibs_check_method=pass_all ;; openbsd* | bitrig*) if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' fi ;; osf3* | osf4* | osf5*) lt_cv_deplibs_check_method=pass_all ;; rdos*) lt_cv_deplibs_check_method=pass_all ;; solaris*) lt_cv_deplibs_check_method=pass_all ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) lt_cv_deplibs_check_method=pass_all ;; sysv4 | sysv4.3*) case $host_vendor in motorola) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]' lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` ;; ncr) lt_cv_deplibs_check_method=pass_all ;; sequent) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' ;; sni) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" lt_cv_file_magic_test_file=/lib/libc.so ;; siemens) lt_cv_deplibs_check_method=pass_all ;; pc) lt_cv_deplibs_check_method=pass_all ;; esac ;; tpf*) lt_cv_deplibs_check_method=pass_all ;; os2*) lt_cv_deplibs_check_method=pass_all ;; esac fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 $as_echo "$lt_cv_deplibs_check_method" >&6; } file_magic_glob= want_nocaseglob=no if test "$build" = "$host"; then case $host_os in mingw* | pw32*) if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then want_nocaseglob=yes else file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"` fi ;; esac fi file_magic_cmd=$lt_cv_file_magic_cmd deplibs_check_method=$lt_cv_deplibs_check_method test -z "$deplibs_check_method" && deplibs_check_method=unknown if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args. set dummy ${ac_tool_prefix}dlltool; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_DLLTOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$DLLTOOL"; then ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi DLLTOOL=$ac_cv_prog_DLLTOOL if test -n "$DLLTOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5 $as_echo "$DLLTOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_DLLTOOL"; then ac_ct_DLLTOOL=$DLLTOOL # Extract the first word of "dlltool", so it can be a program name with args. set dummy dlltool; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_DLLTOOL"; then ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_DLLTOOL="dlltool" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL if test -n "$ac_ct_DLLTOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5 $as_echo "$ac_ct_DLLTOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_DLLTOOL" = x; then DLLTOOL="false" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac DLLTOOL=$ac_ct_DLLTOOL fi else DLLTOOL="$ac_cv_prog_DLLTOOL" fi test -z "$DLLTOOL" && DLLTOOL=dlltool { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5 $as_echo_n "checking how to associate runtime and link libraries... " >&6; } if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_sharedlib_from_linklib_cmd='unknown' case $host_os in cygwin* | mingw* | pw32* | cegcc*) # two different shell functions defined in ltmain.sh; # decide which one to use based on capabilities of $DLLTOOL case `$DLLTOOL --help 2>&1` in *--identify-strict*) lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib ;; *) lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback ;; esac ;; *) # fallback: assume linklib IS sharedlib lt_cv_sharedlib_from_linklib_cmd=$ECHO ;; esac fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5 $as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; } sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO if test -n "$ac_tool_prefix"; then for ac_prog in ar do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_AR+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$AR"; then ac_cv_prog_AR="$AR" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_AR="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi AR=$ac_cv_prog_AR if test -n "$AR"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 $as_echo "$AR" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$AR" && break done fi if test -z "$AR"; then ac_ct_AR=$AR for ac_prog in ar do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_AR+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_AR"; then ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_AR="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_AR=$ac_cv_prog_ac_ct_AR if test -n "$ac_ct_AR"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 $as_echo "$ac_ct_AR" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$ac_ct_AR" && break done if test "x$ac_ct_AR" = x; then AR="false" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac AR=$ac_ct_AR fi fi : ${AR=ar} : ${AR_FLAGS=cru} { $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5 $as_echo_n "checking for archiver @FILE support... " >&6; } if ${lt_cv_ar_at_file+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_ar_at_file=no cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : echo conftest.$ac_objext > conftest.lst lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5' { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 (eval $lt_ar_try) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } if test 0 -eq "$ac_status"; then # Ensure the archiver fails upon bogus file names. rm -f conftest.$ac_objext libconftest.a { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5 (eval $lt_ar_try) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } if test 0 -ne "$ac_status"; then lt_cv_ar_at_file=@ fi fi rm -f conftest.* libconftest.a fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5 $as_echo "$lt_cv_ar_at_file" >&6; } if test no = "$lt_cv_ar_at_file"; then archiver_list_spec= else archiver_list_spec=$lt_cv_ar_at_file fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$STRIP"; then ac_cv_prog_STRIP="$STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 $as_echo "$STRIP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_STRIP"; then ac_ct_STRIP=$STRIP # Extract the first word of "strip", so it can be a program name with args. set dummy strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_STRIP+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_STRIP"; then ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_STRIP="strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 $as_echo "$ac_ct_STRIP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_STRIP" = x; then STRIP=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac STRIP=$ac_ct_STRIP fi else STRIP="$ac_cv_prog_STRIP" fi test -z "$STRIP" && STRIP=: if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. set dummy ${ac_tool_prefix}ranlib; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_RANLIB+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$RANLIB"; then ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi RANLIB=$ac_cv_prog_RANLIB if test -n "$RANLIB"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 $as_echo "$RANLIB" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_RANLIB"; then ac_ct_RANLIB=$RANLIB # Extract the first word of "ranlib", so it can be a program name with args. set dummy ranlib; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_RANLIB"; then ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_RANLIB="ranlib" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB if test -n "$ac_ct_RANLIB"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 $as_echo "$ac_ct_RANLIB" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_RANLIB" = x; then RANLIB=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac RANLIB=$ac_ct_RANLIB fi else RANLIB="$ac_cv_prog_RANLIB" fi test -z "$RANLIB" && RANLIB=: # Determine commands to create old-style static archives. old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' old_postinstall_cmds='chmod 644 $oldlib' old_postuninstall_cmds= if test -n "$RANLIB"; then case $host_os in bitrig* | openbsd*) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" ;; *) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" ;; esac old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" fi case $host_os in darwin*) lock_old_archive_extraction=yes ;; *) lock_old_archive_extraction=no ;; esac # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # Check for command to grab the raw symbol name followed by C symbol from nm. { $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 $as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } if ${lt_cv_sys_global_symbol_pipe+:} false; then : $as_echo_n "(cached) " >&6 else # These are sane defaults that work on at least a few old systems. # [They come from Ultrix. What could be older than Ultrix?!! ;)] # Character class describing NM global symbol codes. symcode='[BCDEGRST]' # Regexp to match symbols that can be accessed directly from C. sympat='\([_A-Za-z][_A-Za-z0-9]*\)' # Define system-specific variables. case $host_os in aix*) symcode='[BCDT]' ;; cygwin* | mingw* | pw32* | cegcc*) symcode='[ABCDGISTW]' ;; hpux*) if test ia64 = "$host_cpu"; then symcode='[ABCDEGRST]' fi ;; irix* | nonstopux*) symcode='[BCDEGRST]' ;; osf*) symcode='[BCDEGQRST]' ;; solaris*) symcode='[BDRT]' ;; sco3.2v5*) symcode='[DT]' ;; sysv4.2uw2*) symcode='[DT]' ;; sysv5* | sco5v6* | unixware* | OpenUNIX*) symcode='[ABDT]' ;; sysv4) symcode='[DFNSTU]' ;; esac # If we're using GNU nm, then use its standard symbol codes. case `$NM -V 2>&1` in *GNU* | *'with BFD'*) symcode='[ABCDGIRSTW]' ;; esac if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Gets list of data symbols to import. lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'" # Adjust the below global symbol transforms to fixup imported variables. lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" lt_c_name_lib_hook="\ -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\ -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'" else # Disable hooks by default. lt_cv_sys_global_symbol_to_import= lt_cdecl_hook= lt_c_name_hook= lt_c_name_lib_hook= fi # Transform an extracted symbol line into a proper C declaration. # Some systems (esp. on ia64) link data and code symbols differently, # so use this general approach. lt_cv_sys_global_symbol_to_cdecl="sed -n"\ $lt_cdecl_hook\ " -e 's/^T .* \(.*\)$/extern int \1();/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" # Transform an extracted symbol line into symbol name and symbol address lt_cv_sys_global_symbol_to_c_name_address="sed -n"\ $lt_c_name_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" # Transform an extracted symbol line into symbol name with lib prefix and # symbol address. lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\ $lt_c_name_lib_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'" # Handle CRLF in mingw tool chain opt_cr= case $build_os in mingw*) opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp ;; esac # Try without a prefix underscore, then with it. for ac_symprfx in "" "_"; do # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. symxfrm="\\1 $ac_symprfx\\2 \\2" # Write the raw and C identifiers. if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Fake it for dumpbin and say T for any non-static function, # D for any global variable and I for any imported variable. # Also find C++ and __fastcall symbols from MSVC++, # which start with @ or ?. lt_cv_sys_global_symbol_pipe="$AWK '"\ " {last_section=section; section=\$ 3};"\ " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ " /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\ " /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\ " /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\ " \$ 0!~/External *\|/{next};"\ " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ " {if(hide[section]) next};"\ " {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\ " {split(\$ 0,a,/\||\r/); split(a[2],s)};"\ " s[1]~/^[@?]/{print f,s[1],s[1]; next};"\ " s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ " ' prfx=^$ac_symprfx" else lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" fi lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" # Check to see that the pipe works correctly. pipe_works=no rm -f conftest* cat > conftest.$ac_ext <<_LT_EOF #ifdef __cplusplus extern "C" { #endif char nm_test_var; void nm_test_func(void); void nm_test_func(void){} #ifdef __cplusplus } #endif int main(){nm_test_var='a';nm_test_func();return(0);} _LT_EOF if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then # Now try to grab the symbols. nlist=conftest.nm if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5 (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && test -s "$nlist"; then # Try sorting and uniquifying the output. if sort "$nlist" | uniq > "$nlist"T; then mv -f "$nlist"T "$nlist" else rm -f "$nlist"T fi # Make sure that we snagged all the symbols we need. if $GREP ' nm_test_var$' "$nlist" >/dev/null; then if $GREP ' nm_test_func$' "$nlist" >/dev/null; then cat <<_LT_EOF > conftest.$ac_ext /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE /* DATA imports from DLLs on WIN32 can't be const, because runtime relocations are performed -- see ld's documentation on pseudo-relocs. */ # define LT_DLSYM_CONST #elif defined __osf__ /* This system does not cope well with relocations in const data. */ # define LT_DLSYM_CONST #else # define LT_DLSYM_CONST const #endif #ifdef __cplusplus extern "C" { #endif _LT_EOF # Now generate the symbol file. eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' cat <<_LT_EOF >> conftest.$ac_ext /* The mapping between symbol names and symbols. */ LT_DLSYM_CONST struct { const char *name; void *address; } lt__PROGRAM__LTX_preloaded_symbols[] = { { "@PROGRAM@", (void *) 0 }, _LT_EOF $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext cat <<\_LT_EOF >> conftest.$ac_ext {0, (void *) 0} }; /* This works around a problem in FreeBSD linker */ #ifdef FREEBSD_WORKAROUND static const void *lt_preloaded_setup() { return lt__PROGRAM__LTX_preloaded_symbols; } #endif #ifdef __cplusplus } #endif _LT_EOF # Now try linking the two files. mv conftest.$ac_objext conftstm.$ac_objext lt_globsym_save_LIBS=$LIBS lt_globsym_save_CFLAGS=$CFLAGS LIBS=conftstm.$ac_objext CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 (eval $ac_link) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && test -s conftest$ac_exeext; then pipe_works=yes fi LIBS=$lt_globsym_save_LIBS CFLAGS=$lt_globsym_save_CFLAGS else echo "cannot find nm_test_func in $nlist" >&5 fi else echo "cannot find nm_test_var in $nlist" >&5 fi else echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 fi else echo "$progname: failed program was:" >&5 cat conftest.$ac_ext >&5 fi rm -rf conftest* conftst* # Do not use the global_symbol_pipe unless it works. if test yes = "$pipe_works"; then break else lt_cv_sys_global_symbol_pipe= fi done fi if test -z "$lt_cv_sys_global_symbol_pipe"; then lt_cv_sys_global_symbol_to_cdecl= fi if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 $as_echo "failed" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 $as_echo "ok" >&6; } fi # Response file support. if test "$lt_cv_nm_interface" = "MS dumpbin"; then nm_file_list_spec='@' elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then nm_file_list_spec='@' fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 $as_echo_n "checking for sysroot... " >&6; } # Check whether --with-sysroot was given. if test "${with_sysroot+set}" = set; then : withval=$with_sysroot; else with_sysroot=no fi lt_sysroot= case $with_sysroot in #( yes) if test yes = "$GCC"; then lt_sysroot=`$CC --print-sysroot 2>/dev/null` fi ;; #( /*) lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` ;; #( no|'') ;; #( *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5 $as_echo "$with_sysroot" >&6; } as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5 ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5 $as_echo "${lt_sysroot:-no}" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5 $as_echo_n "checking for a working dd... " >&6; } if ${ac_cv_path_lt_DD+:} false; then : $as_echo_n "(cached) " >&6 else printf 0123456789abcdef0123456789abcdef >conftest.i cat conftest.i conftest.i >conftest2.i : ${lt_DD:=$DD} if test -z "$lt_DD"; then ac_path_lt_DD_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in dd; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_lt_DD="$as_dir/$ac_prog$ac_exec_ext" as_fn_executable_p "$ac_path_lt_DD" || continue if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then cmp -s conftest.i conftest.out \ && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=: fi $ac_path_lt_DD_found && break 3 done done done IFS=$as_save_IFS if test -z "$ac_cv_path_lt_DD"; then : fi else ac_cv_path_lt_DD=$lt_DD fi rm -f conftest.i conftest2.i conftest.out fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5 $as_echo "$ac_cv_path_lt_DD" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5 $as_echo_n "checking how to truncate binary pipes... " >&6; } if ${lt_cv_truncate_bin+:} false; then : $as_echo_n "(cached) " >&6 else printf 0123456789abcdef0123456789abcdef >conftest.i cat conftest.i conftest.i >conftest2.i lt_cv_truncate_bin= if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then cmp -s conftest.i conftest.out \ && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" fi rm -f conftest.i conftest2.i conftest.out test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q" fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5 $as_echo "$lt_cv_truncate_bin" >&6; } # Calculate cc_basename. Skip known compiler wrappers and cross-prefix. func_cc_basename () { for cc_temp in $*""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` } # Check whether --enable-libtool-lock was given. if test "${enable_libtool_lock+set}" = set; then : enableval=$enable_libtool_lock; fi test no = "$enable_libtool_lock" || enable_libtool_lock=yes # Some flags need to be propagated to the compiler or linker for good # libtool support. case $host in ia64-*-hpux*) # Find out what ABI is being produced by ac_compile, and set mode # options accordingly. echo 'int i;' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then case `/usr/bin/file conftest.$ac_objext` in *ELF-32*) HPUX_IA64_MODE=32 ;; *ELF-64*) HPUX_IA64_MODE=64 ;; esac fi rm -rf conftest* ;; *-*-irix6*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo '#line '$LINENO' "configure"' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then if test yes = "$lt_cv_prog_gnu_ld"; then case `/usr/bin/file conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -melf32bsmip" ;; *N32*) LD="${LD-ld} -melf32bmipn32" ;; *64-bit*) LD="${LD-ld} -melf64bmip" ;; esac else case `/usr/bin/file conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -32" ;; *N32*) LD="${LD-ld} -n32" ;; *64-bit*) LD="${LD-ld} -64" ;; esac fi fi rm -rf conftest* ;; mips64*-*linux*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo '#line '$LINENO' "configure"' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then emul=elf case `/usr/bin/file conftest.$ac_objext` in *32-bit*) emul="${emul}32" ;; *64-bit*) emul="${emul}64" ;; esac case `/usr/bin/file conftest.$ac_objext` in *MSB*) emul="${emul}btsmip" ;; *LSB*) emul="${emul}ltsmip" ;; esac case `/usr/bin/file conftest.$ac_objext` in *N32*) emul="${emul}n32" ;; esac LD="${LD-ld} -m $emul" fi rm -rf conftest* ;; x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. Note that the listed cases only cover the # situations where additional linker options are needed (such as when # doing 32-bit compilation for a host where ld defaults to 64-bit, or # vice versa); the common cases where no linker options are needed do # not appear in the list. echo 'int i;' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then case `/usr/bin/file conftest.o` in *32-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_i386_fbsd" ;; x86_64-*linux*) case `/usr/bin/file conftest.o` in *x86-64*) LD="${LD-ld} -m elf32_x86_64" ;; *) LD="${LD-ld} -m elf_i386" ;; esac ;; powerpc64le-*linux*) LD="${LD-ld} -m elf32lppclinux" ;; powerpc64-*linux*) LD="${LD-ld} -m elf32ppclinux" ;; s390x-*linux*) LD="${LD-ld} -m elf_s390" ;; sparc64-*linux*) LD="${LD-ld} -m elf32_sparc" ;; esac ;; *64-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_x86_64_fbsd" ;; x86_64-*linux*) LD="${LD-ld} -m elf_x86_64" ;; powerpcle-*linux*) LD="${LD-ld} -m elf64lppc" ;; powerpc-*linux*) LD="${LD-ld} -m elf64ppc" ;; s390*-*linux*|s390*-*tpf*) LD="${LD-ld} -m elf64_s390" ;; sparc*-*linux*) LD="${LD-ld} -m elf64_sparc" ;; esac ;; esac fi rm -rf conftest* ;; *-*-sco3.2v5*) # On SCO OpenServer 5, we need -belf to get full-featured binaries. SAVE_CFLAGS=$CFLAGS CFLAGS="$CFLAGS -belf" { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 $as_echo_n "checking whether the C compiler needs -belf... " >&6; } if ${lt_cv_cc_needs_belf+:} false; then : $as_echo_n "(cached) " >&6 else ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : lt_cv_cc_needs_belf=yes else lt_cv_cc_needs_belf=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 $as_echo "$lt_cv_cc_needs_belf" >&6; } if test yes != "$lt_cv_cc_needs_belf"; then # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf CFLAGS=$SAVE_CFLAGS fi ;; *-*solaris*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo 'int i;' > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then case `/usr/bin/file conftest.o` in *64-bit*) case $lt_cv_prog_gnu_ld in yes*) case $host in i?86-*-solaris*|x86_64-*-solaris*) LD="${LD-ld} -m elf_x86_64" ;; sparc*-*-solaris*) LD="${LD-ld} -m elf64_sparc" ;; esac # GNU ld 2.21 introduced _sol2 emulations. Use them if available. if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then LD=${LD-ld}_sol2 fi ;; *) if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then LD="${LD-ld} -64" fi ;; esac ;; esac fi rm -rf conftest* ;; esac need_locks=$enable_libtool_lock if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args. set dummy ${ac_tool_prefix}mt; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_MANIFEST_TOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$MANIFEST_TOOL"; then ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL if test -n "$MANIFEST_TOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5 $as_echo "$MANIFEST_TOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_MANIFEST_TOOL"; then ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL # Extract the first word of "mt", so it can be a program name with args. set dummy mt; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_MANIFEST_TOOL"; then ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_MANIFEST_TOOL="mt" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL if test -n "$ac_ct_MANIFEST_TOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5 $as_echo "$ac_ct_MANIFEST_TOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_MANIFEST_TOOL" = x; then MANIFEST_TOOL=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL fi else MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL" fi test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5 $as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; } if ${lt_cv_path_mainfest_tool+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_path_mainfest_tool=no echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5 $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out cat conftest.err >&5 if $GREP 'Manifest Tool' conftest.out > /dev/null; then lt_cv_path_mainfest_tool=yes fi rm -f conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5 $as_echo "$lt_cv_path_mainfest_tool" >&6; } if test yes != "$lt_cv_path_mainfest_tool"; then MANIFEST_TOOL=: fi case $host_os in rhapsody* | darwin*) if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_DSYMUTIL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$DSYMUTIL"; then ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi DSYMUTIL=$ac_cv_prog_DSYMUTIL if test -n "$DSYMUTIL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 $as_echo "$DSYMUTIL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_DSYMUTIL"; then ac_ct_DSYMUTIL=$DSYMUTIL # Extract the first word of "dsymutil", so it can be a program name with args. set dummy dsymutil; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_DSYMUTIL"; then ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL if test -n "$ac_ct_DSYMUTIL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5 $as_echo "$ac_ct_DSYMUTIL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_DSYMUTIL" = x; then DSYMUTIL=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac DSYMUTIL=$ac_ct_DSYMUTIL fi else DSYMUTIL="$ac_cv_prog_DSYMUTIL" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. set dummy ${ac_tool_prefix}nmedit; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_NMEDIT+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$NMEDIT"; then ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi NMEDIT=$ac_cv_prog_NMEDIT if test -n "$NMEDIT"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5 $as_echo "$NMEDIT" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_NMEDIT"; then ac_ct_NMEDIT=$NMEDIT # Extract the first word of "nmedit", so it can be a program name with args. set dummy nmedit; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_NMEDIT"; then ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_NMEDIT="nmedit" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT if test -n "$ac_ct_NMEDIT"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5 $as_echo "$ac_ct_NMEDIT" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_NMEDIT" = x; then NMEDIT=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac NMEDIT=$ac_ct_NMEDIT fi else NMEDIT="$ac_cv_prog_NMEDIT" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args. set dummy ${ac_tool_prefix}lipo; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_LIPO+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$LIPO"; then ac_cv_prog_LIPO="$LIPO" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_LIPO="${ac_tool_prefix}lipo" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi LIPO=$ac_cv_prog_LIPO if test -n "$LIPO"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 $as_echo "$LIPO" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_LIPO"; then ac_ct_LIPO=$LIPO # Extract the first word of "lipo", so it can be a program name with args. set dummy lipo; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_LIPO+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_LIPO"; then ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_LIPO="lipo" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO if test -n "$ac_ct_LIPO"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5 $as_echo "$ac_ct_LIPO" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_LIPO" = x; then LIPO=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac LIPO=$ac_ct_LIPO fi else LIPO="$ac_cv_prog_LIPO" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args. set dummy ${ac_tool_prefix}otool; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_OTOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OTOOL"; then ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_OTOOL="${ac_tool_prefix}otool" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi OTOOL=$ac_cv_prog_OTOOL if test -n "$OTOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 $as_echo "$OTOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_OTOOL"; then ac_ct_OTOOL=$OTOOL # Extract the first word of "otool", so it can be a program name with args. set dummy otool; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_OTOOL+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_OTOOL"; then ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_OTOOL="otool" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL if test -n "$ac_ct_OTOOL"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5 $as_echo "$ac_ct_OTOOL" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_OTOOL" = x; then OTOOL=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac OTOOL=$ac_ct_OTOOL fi else OTOOL="$ac_cv_prog_OTOOL" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args. set dummy ${ac_tool_prefix}otool64; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_OTOOL64+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$OTOOL64"; then ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi OTOOL64=$ac_cv_prog_OTOOL64 if test -n "$OTOOL64"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5 $as_echo "$OTOOL64" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_OTOOL64"; then ac_ct_OTOOL64=$OTOOL64 # Extract the first word of "otool64", so it can be a program name with args. set dummy otool64; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_OTOOL64"; then ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_ac_ct_OTOOL64="otool64" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64 if test -n "$ac_ct_OTOOL64"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5 $as_echo "$ac_ct_OTOOL64" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_OTOOL64" = x; then OTOOL64=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac OTOOL64=$ac_ct_OTOOL64 fi else OTOOL64="$ac_cv_prog_OTOOL64" fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5 $as_echo_n "checking for -single_module linker flag... " >&6; } if ${lt_cv_apple_cc_single_mod+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_apple_cc_single_mod=no if test -z "$LT_MULTI_MODULE"; then # By default we will add the -single_module flag. You can override # by either setting the environment variable LT_MULTI_MODULE # non-empty at configure time, or by adding -multi_module to the # link flags. rm -rf libconftest.dylib* echo "int foo(void){return 1;}" > conftest.c echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib -Wl,-single_module conftest.c" >&5 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib -Wl,-single_module conftest.c 2>conftest.err _lt_result=$? # If there is a non-empty error log, and "single_module" # appears in it, assume the flag caused a linker warning if test -s conftest.err && $GREP single_module conftest.err; then cat conftest.err >&5 # Otherwise, if the output was created with a 0 exit code from # the compiler, it worked. elif test -f libconftest.dylib && test 0 = "$_lt_result"; then lt_cv_apple_cc_single_mod=yes else cat conftest.err >&5 fi rm -rf libconftest.dylib* rm -f conftest.* fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5 $as_echo "$lt_cv_apple_cc_single_mod" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5 $as_echo_n "checking for -exported_symbols_list linker flag... " >&6; } if ${lt_cv_ld_exported_symbols_list+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_ld_exported_symbols_list=no save_LDFLAGS=$LDFLAGS echo "_main" > conftest.sym LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : lt_cv_ld_exported_symbols_list=yes else lt_cv_ld_exported_symbols_list=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$save_LDFLAGS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5 $as_echo "$lt_cv_ld_exported_symbols_list" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5 $as_echo_n "checking for -force_load linker flag... " >&6; } if ${lt_cv_ld_force_load+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_ld_force_load=no cat > conftest.c << _LT_EOF int forced_loaded() { return 2;} _LT_EOF echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5 echo "$AR cru libconftest.a conftest.o" >&5 $AR cru libconftest.a conftest.o 2>&5 echo "$RANLIB libconftest.a" >&5 $RANLIB libconftest.a 2>&5 cat > conftest.c << _LT_EOF int main() { return 0;} _LT_EOF echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err _lt_result=$? if test -s conftest.err && $GREP force_load conftest.err; then cat conftest.err >&5 elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then lt_cv_ld_force_load=yes else cat conftest.err >&5 fi rm -f conftest.err libconftest.a conftest conftest.c rm -rf conftest.dSYM fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5 $as_echo "$lt_cv_ld_force_load" >&6; } case $host_os in rhapsody* | darwin1.[012]) _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; darwin1.*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; darwin*) # darwin 5.x on # if running on 10.5 or later, the deployment target defaults # to the OS version, if on x86, and 10.4, the deployment # target defaults to 10.4. Don't you love it? case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in 10.0,*86*-darwin8*|10.0,*-darwin[91]*) _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; 10.[012][,.]*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; 10.*) _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; esac ;; esac if test yes = "$lt_cv_apple_cc_single_mod"; then _lt_dar_single_mod='$single_module' fi if test yes = "$lt_cv_ld_exported_symbols_list"; then _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' else _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib' fi if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then _lt_dsymutil='~$DSYMUTIL $lib || :' else _lt_dsymutil= fi ;; esac # func_munge_path_list VARIABLE PATH # ----------------------------------- # VARIABLE is name of variable containing _space_ separated list of # directories to be munged by the contents of PATH, which is string # having a format: # "DIR[:DIR]:" # string "DIR[ DIR]" will be prepended to VARIABLE # ":DIR[:DIR]" # string "DIR[ DIR]" will be appended to VARIABLE # "DIRP[:DIRP]::[DIRA:]DIRA" # string "DIRP[ DIRP]" will be prepended to VARIABLE and string # "DIRA[ DIRA]" will be appended to VARIABLE # "DIR[:DIR]" # VARIABLE will be replaced by "DIR[ DIR]" func_munge_path_list () { case x$2 in x) ;; *:) eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\" ;; x:*) eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\" ;; *::*) eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\" ;; *) eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\" ;; esac } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 $as_echo_n "checking for ANSI C header files... " >&6; } if ${ac_cv_header_stdc+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <stdlib.h> #include <stdarg.h> #include <string.h> #include <float.h> int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_header_stdc=yes else ac_cv_header_stdc=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <string.h> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "memchr" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <stdlib.h> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "free" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. if test "$cross_compiling" = yes; then : : else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <ctype.h> #include <stdlib.h> #if ((' ' & 0x0FF) == 0x020) # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) #else # define ISLOWER(c) \ (('a' <= (c) && (c) <= 'i') \ || ('j' <= (c) && (c) <= 'r') \ || ('s' <= (c) && (c) <= 'z')) # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) #endif #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) int main () { int i; for (i = 0; i < 256; i++) if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) return 2; return 0; } _ACEOF if ac_fn_c_try_run "$LINENO"; then : else ac_cv_header_stdc=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ conftest.$ac_objext conftest.beam conftest.$ac_ext fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 $as_echo "$ac_cv_header_stdc" >&6; } if test $ac_cv_header_stdc = yes; then $as_echo "#define STDC_HEADERS 1" >>confdefs.h fi # On IRIX 5.3, sys/types and inttypes.h are conflicting. for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ inttypes.h stdint.h unistd.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default " if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done for ac_header in dlfcn.h do : ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default " if test "x$ac_cv_header_dlfcn_h" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE_DLFCN_H 1 _ACEOF fi done func_stripname_cnf () { case $2 in .*) func_stripname_result=`$ECHO "$3" | $SED "s%^$1%%; s%\\\\$2\$%%"`;; *) func_stripname_result=`$ECHO "$3" | $SED "s%^$1%%; s%$2\$%%"`;; esac } # func_stripname_cnf # Set options enable_dlopen=no enable_win32_dll=no # Check whether --enable-shared was given. if test "${enable_shared+set}" = set; then : enableval=$enable_shared; p=${PACKAGE-default} case $enableval in yes) enable_shared=yes ;; no) enable_shared=no ;; *) enable_shared=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_shared=yes fi done IFS=$lt_save_ifs ;; esac else enable_shared=yes fi # Check whether --enable-static was given. if test "${enable_static+set}" = set; then : enableval=$enable_static; p=${PACKAGE-default} case $enableval in yes) enable_static=yes ;; no) enable_static=no ;; *) enable_static=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_static=yes fi done IFS=$lt_save_ifs ;; esac else enable_static=yes fi # Check whether --with-pic was given. if test "${with_pic+set}" = set; then : withval=$with_pic; lt_p=${PACKAGE-default} case $withval in yes|no) pic_mode=$withval ;; *) pic_mode=default # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for lt_pkg in $withval; do IFS=$lt_save_ifs if test "X$lt_pkg" = "X$lt_p"; then pic_mode=yes fi done IFS=$lt_save_ifs ;; esac else pic_mode=default fi # Check whether --enable-fast-install was given. if test "${enable_fast_install+set}" = set; then : enableval=$enable_fast_install; p=${PACKAGE-default} case $enableval in yes) enable_fast_install=yes ;; no) enable_fast_install=no ;; *) enable_fast_install=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_fast_install=yes fi done IFS=$lt_save_ifs ;; esac else enable_fast_install=yes fi shared_archive_member_spec= case $host,$enable_shared in power*-*-aix[5-9]*,yes) { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5 $as_echo_n "checking which variant of shared library versioning to provide... " >&6; } # Check whether --with-aix-soname was given. if test "${with_aix_soname+set}" = set; then : withval=$with_aix_soname; case $withval in aix|svr4|both) ;; *) as_fn_error $? "Unknown argument to --with-aix-soname" "$LINENO" 5 ;; esac lt_cv_with_aix_soname=$with_aix_soname else if ${lt_cv_with_aix_soname+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_with_aix_soname=aix fi with_aix_soname=$lt_cv_with_aix_soname fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5 $as_echo "$with_aix_soname" >&6; } if test aix != "$with_aix_soname"; then # For the AIX way of multilib, we name the shared archive member # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File. # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag, # the AIX toolchain works better with OBJECT_MODE set (default 32). if test 64 = "${OBJECT_MODE-32}"; then shared_archive_member_spec=shr_64 else shared_archive_member_spec=shr fi fi ;; *) with_aix_soname=aix ;; esac # This can be used to rebuild libtool when needed LIBTOOL_DEPS=$ltmain # Always use our own libtool. LIBTOOL='$(SHELL) $(top_builddir)/libtool' test -z "$LN_S" && LN_S="ln -s" if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 $as_echo_n "checking for objdir... " >&6; } if ${lt_cv_objdir+:} false; then : $as_echo_n "(cached) " >&6 else rm -f .libs 2>/dev/null mkdir .libs 2>/dev/null if test -d .libs; then lt_cv_objdir=.libs else # MS-DOS does not allow filenames that begin with a dot. lt_cv_objdir=_libs fi rmdir .libs 2>/dev/null fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 $as_echo "$lt_cv_objdir" >&6; } objdir=$lt_cv_objdir cat >>confdefs.h <<_ACEOF #define LT_OBJDIR "$lt_cv_objdir/" _ACEOF case $host_os in aix3*) # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi ;; esac # Global variables: ofile=libtool can_build_shared=yes # All known linkers require a '.a' archive for static linking (except MSVC, # which needs '.lib'). libext=a with_gnu_ld=$lt_cv_prog_gnu_ld old_CC=$CC old_CFLAGS=$CFLAGS # Set sane defaults for various variables test -z "$CC" && CC=cc test -z "$LTCC" && LTCC=$CC test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS test -z "$LD" && LD=ld test -z "$ac_objext" && ac_objext=o func_cc_basename $compiler cc_basename=$func_cc_basename_result # Only perform the check for file, if the check method requires it test -z "$MAGIC_CMD" && MAGIC_CMD=file case $deplibs_check_method in file_magic*) if test "$file_magic_cmd" = '$MAGIC_CMD'; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 $as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } if ${lt_cv_path_MAGIC_CMD+:} false; then : $as_echo_n "(cached) " >&6 else case $MAGIC_CMD in [\\/*] | ?:[\\/]*) lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. ;; *) lt_save_MAGIC_CMD=$MAGIC_CMD lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" for ac_dir in $ac_dummy; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/${ac_tool_prefix}file"; then lt_cv_path_MAGIC_CMD=$ac_dir/"${ac_tool_prefix}file" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` MAGIC_CMD=$lt_cv_path_MAGIC_CMD if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : else cat <<_LT_EOF 1>&2 *** Warning: the command libtool uses to detect shared libraries, *** $file_magic_cmd, produces output that libtool cannot recognize. *** The result is that libtool may fail to recognize shared libraries *** as such. This will affect the creation of libtool libraries that *** depend on shared libraries, but programs linked with such libtool *** libraries will work regardless of this problem. Nevertheless, you *** may want to report the problem to your system manager and/or to *** bug-libtool@gnu.org _LT_EOF fi ;; esac fi break fi done IFS=$lt_save_ifs MAGIC_CMD=$lt_save_MAGIC_CMD ;; esac fi MAGIC_CMD=$lt_cv_path_MAGIC_CMD if test -n "$MAGIC_CMD"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 $as_echo "$MAGIC_CMD" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test -z "$lt_cv_path_MAGIC_CMD"; then if test -n "$ac_tool_prefix"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5 $as_echo_n "checking for file... " >&6; } if ${lt_cv_path_MAGIC_CMD+:} false; then : $as_echo_n "(cached) " >&6 else case $MAGIC_CMD in [\\/*] | ?:[\\/]*) lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. ;; *) lt_save_MAGIC_CMD=$MAGIC_CMD lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" for ac_dir in $ac_dummy; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/file"; then lt_cv_path_MAGIC_CMD=$ac_dir/"file" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` MAGIC_CMD=$lt_cv_path_MAGIC_CMD if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : else cat <<_LT_EOF 1>&2 *** Warning: the command libtool uses to detect shared libraries, *** $file_magic_cmd, produces output that libtool cannot recognize. *** The result is that libtool may fail to recognize shared libraries *** as such. This will affect the creation of libtool libraries that *** depend on shared libraries, but programs linked with such libtool *** libraries will work regardless of this problem. Nevertheless, you *** may want to report the problem to your system manager and/or to *** bug-libtool@gnu.org _LT_EOF fi ;; esac fi break fi done IFS=$lt_save_ifs MAGIC_CMD=$lt_save_MAGIC_CMD ;; esac fi MAGIC_CMD=$lt_cv_path_MAGIC_CMD if test -n "$MAGIC_CMD"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 $as_echo "$MAGIC_CMD" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi else MAGIC_CMD=: fi fi fi ;; esac # Use C for the default configuration in the libtool script lt_save_CC=$CC ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu # Source file extension for C test sources. ac_ext=c # Object file extension for compiled C test sources. objext=o objext=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(){return(0);}' # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # Save the default compiler, since it gets overwritten when the other # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. compiler_DEFAULT=$CC # save warnings/boilerplate of simple test code ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $RM conftest* ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $RM -r conftest* ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... if test -n "$compiler"; then lt_prog_compiler_no_builtin_flag= if test yes = "$GCC"; then case $cc_basename in nvcc*) lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;; *) lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 $as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_rtti_exceptions=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-fno-rtti -fno-exceptions" ## exclude from sc_useless_quotes_in_assignment # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_rtti_exceptions=yes fi fi $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 $as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } if test yes = "$lt_cv_prog_compiler_rtti_exceptions"; then lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" else : fi fi lt_prog_compiler_wl= lt_prog_compiler_pic= lt_prog_compiler_static= if test yes = "$GCC"; then lt_prog_compiler_wl='-Wl,' lt_prog_compiler_static='-static' case $host_os in aix*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor lt_prog_compiler_static='-Bstatic' fi lt_prog_compiler_pic='-fPIC' ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support lt_prog_compiler_pic='-fPIC' ;; m68k) # FIXME: we need at least 68020 code to build shared libraries, but # adding the '-m68020' flag to GCC prevents building anything better, # like '-m68040'. lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' ;; esac ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries lt_prog_compiler_pic='-DDLL_EXPORT' case $host_os in os2*) lt_prog_compiler_static='$wl-static' ;; esac ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic='-fno-common' ;; haiku*) # PIC is the default for Haiku. # The "-static" flag exists, but is broken. lt_prog_compiler_static= ;; hpux*) # PIC is the default for 64-bit PA HP-UX, but not for 32-bit # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag # sets the default TLS model and affects inlining. case $host_cpu in hppa*64*) # +Z the default ;; *) lt_prog_compiler_pic='-fPIC' ;; esac ;; interix[3-9]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; msdosdjgpp*) # Just because we use GCC doesn't mean we suddenly get shared libraries # on systems that don't support them. lt_prog_compiler_can_build_shared=no enable_shared=no ;; *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. lt_prog_compiler_pic='-fPIC -shared' ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic=-Kconform_pic fi ;; *) lt_prog_compiler_pic='-fPIC' ;; esac case $cc_basename in nvcc*) # Cuda Compiler Driver 2.2 lt_prog_compiler_wl='-Xlinker ' if test -n "$lt_prog_compiler_pic"; then lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic" fi ;; esac else # PORTME Check for flag to pass linker flags through the system compiler. case $host_os in aix*) lt_prog_compiler_wl='-Wl,' if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor lt_prog_compiler_static='-Bstatic' else lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' fi ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic='-fno-common' case $cc_basename in nagfor*) # NAG Fortran compiler lt_prog_compiler_wl='-Wl,-Wl,,' lt_prog_compiler_pic='-PIC' lt_prog_compiler_static='-Bstatic' ;; esac ;; mingw* | cygwin* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). lt_prog_compiler_pic='-DDLL_EXPORT' case $host_os in os2*) lt_prog_compiler_static='$wl-static' ;; esac ;; hpux9* | hpux10* | hpux11*) lt_prog_compiler_wl='-Wl,' # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic='+Z' ;; esac # Is there a better lt_prog_compiler_static that works with the bundled CC? lt_prog_compiler_static='$wl-a ${wl}archive' ;; irix5* | irix6* | nonstopux*) lt_prog_compiler_wl='-Wl,' # PIC (with -KPIC) is the default. lt_prog_compiler_static='-non_shared' ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in # old Intel for x86_64, which still supported -KPIC. ecc*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-static' ;; # icc used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. icc* | ifort*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fPIC' lt_prog_compiler_static='-static' ;; # Lahey Fortran 8.1. lf95*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='--shared' lt_prog_compiler_static='--static' ;; nagfor*) # NAG Fortran compiler lt_prog_compiler_wl='-Wl,-Wl,,' lt_prog_compiler_pic='-PIC' lt_prog_compiler_static='-Bstatic' ;; tcc*) # Fabrice Bellard et al's Tiny C Compiler lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fPIC' lt_prog_compiler_static='-static' ;; pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fpic' lt_prog_compiler_static='-Bstatic' ;; ccc*) lt_prog_compiler_wl='-Wl,' # All Alpha code is PIC. lt_prog_compiler_static='-non_shared' ;; xl* | bgxl* | bgf* | mpixl*) # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-qpic' lt_prog_compiler_static='-qstaticlink' ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*) # Sun Fortran 8.3 passes all unrecognized flags to the linker lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' lt_prog_compiler_wl='' ;; *Sun\ F* | *Sun*Fortran*) lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' lt_prog_compiler_wl='-Qoption ld ' ;; *Sun\ C*) # Sun C 5.9 lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' lt_prog_compiler_wl='-Wl,' ;; *Intel*\ [CF]*Compiler*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fPIC' lt_prog_compiler_static='-static' ;; *Portland\ Group*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fpic' lt_prog_compiler_static='-Bstatic' ;; esac ;; esac ;; newsos6) lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. lt_prog_compiler_pic='-fPIC -shared' ;; osf3* | osf4* | osf5*) lt_prog_compiler_wl='-Wl,' # All OSF/1 code is PIC. lt_prog_compiler_static='-non_shared' ;; rdos*) lt_prog_compiler_static='-non_shared' ;; solaris*) lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' case $cc_basename in f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) lt_prog_compiler_wl='-Qoption ld ';; *) lt_prog_compiler_wl='-Wl,';; esac ;; sunos4*) lt_prog_compiler_wl='-Qoption ld ' lt_prog_compiler_pic='-PIC' lt_prog_compiler_static='-Bstatic' ;; sysv4 | sysv4.2uw2* | sysv4.3*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic='-Kconform_pic' lt_prog_compiler_static='-Bstatic' fi ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; unicos*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_can_build_shared=no ;; uts4*) lt_prog_compiler_pic='-pic' lt_prog_compiler_static='-Bstatic' ;; *) lt_prog_compiler_can_build_shared=no ;; esac fi case $host_os in # For platforms that do not support PIC, -DPIC is meaningless: *djgpp*) lt_prog_compiler_pic= ;; *) lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 $as_echo_n "checking for $compiler option to produce PIC... " >&6; } if ${lt_cv_prog_compiler_pic+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_pic=$lt_prog_compiler_pic fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5 $as_echo "$lt_cv_prog_compiler_pic" >&6; } lt_prog_compiler_pic=$lt_cv_prog_compiler_pic # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } if ${lt_cv_prog_compiler_pic_works+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_pic_works=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$lt_prog_compiler_pic -DPIC" ## exclude from sc_useless_quotes_in_assignment # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_pic_works=yes fi fi $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5 $as_echo "$lt_cv_prog_compiler_pic_works" >&6; } if test yes = "$lt_cv_prog_compiler_pic_works"; then case $lt_prog_compiler_pic in "" | " "*) ;; *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; esac else lt_prog_compiler_pic= lt_prog_compiler_can_build_shared=no fi fi # # Check to make sure the static flag actually works. # wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } if ${lt_cv_prog_compiler_static_works+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_static_works=no save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS $lt_tmp_static_flag" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&5 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_static_works=yes fi else lt_cv_prog_compiler_static_works=yes fi fi $RM -r conftest* LDFLAGS=$save_LDFLAGS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5 $as_echo "$lt_cv_prog_compiler_static_works" >&6; } if test yes = "$lt_cv_prog_compiler_static_works"; then : else lt_prog_compiler_static= fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } if ${lt_cv_prog_compiler_c_o+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_c_o=no $RM -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o=yes fi fi chmod u+w . 2>&5 $RM conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files $RM out/* && rmdir out cd .. $RM -r conftest $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 $as_echo "$lt_cv_prog_compiler_c_o" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } if ${lt_cv_prog_compiler_c_o+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_c_o=no $RM -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o=yes fi fi chmod u+w . 2>&5 $RM conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files $RM out/* && rmdir out cd .. $RM -r conftest $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 $as_echo "$lt_cv_prog_compiler_c_o" >&6; } hard_links=nottested if test no = "$lt_cv_prog_compiler_c_o" && test no != "$need_locks"; then # do not overwrite the value of need_locks provided by the user { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 $as_echo_n "checking if we can lock with hard links... " >&6; } hard_links=yes $RM conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 $as_echo "$hard_links" >&6; } if test no = "$hard_links"; then { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5 $as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;} need_locks=warn fi else need_locks=no fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } runpath_var= allow_undefined_flag= always_export_symbols=no archive_cmds= archive_expsym_cmds= compiler_needs_object=no enable_shared_with_static_runtimes=no export_dynamic_flag_spec= export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' hardcode_automatic=no hardcode_direct=no hardcode_direct_absolute=no hardcode_libdir_flag_spec= hardcode_libdir_separator= hardcode_minus_L=no hardcode_shlibpath_var=unsupported inherit_rpath=no link_all_deplibs=unknown module_cmds= module_expsym_cmds= old_archive_from_new_cmds= old_archive_from_expsyms_cmds= thread_safe_flag_spec= whole_archive_flag_spec= # include_expsyms should be a list of space-separated symbols to be *always* # included in the symbol list include_expsyms= # exclude_expsyms can be an extended regexp of symbols to exclude # it will be wrapped by ' (' and ')$', so one must not match beginning or # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc', # as well as any symbol that contains 'd'. exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out # platforms (ab)use it in PIC code, but their linkers get confused if # the symbol is explicitly referenced. Since portable code cannot # rely on this symbol name, it's probably fine to never include it in # preloaded symbol tables. # Exclude shared library initialization/finalization symbols. extract_expsyms_cmds= case $host_os in cygwin* | mingw* | pw32* | cegcc*) # FIXME: the MSVC++ port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using # Microsoft Visual C++. if test yes != "$GCC"; then with_gnu_ld=no fi ;; interix*) # we just hope/assume this is gcc and not c89 (= MSVC++) with_gnu_ld=yes ;; openbsd* | bitrig*) with_gnu_ld=no ;; esac ld_shlibs=yes # On some targets, GNU ld is compatible enough with the native linker # that we're better off using the native interface for both. lt_use_gnu_ld_interface=no if test yes = "$with_gnu_ld"; then case $host_os in aix*) # The AIX port of GNU ld has always aspired to compatibility # with the native linker. However, as the warning in the GNU ld # block says, versions before 2.19.5* couldn't really create working # shared libraries, regardless of the interface used. case `$LD -v 2>&1` in *\ \(GNU\ Binutils\)\ 2.19.5*) ;; *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;; *\ \(GNU\ Binutils\)\ [3-9]*) ;; *) lt_use_gnu_ld_interface=yes ;; esac ;; *) lt_use_gnu_ld_interface=yes ;; esac fi if test yes = "$lt_use_gnu_ld_interface"; then # If archive_cmds runs LD, not CC, wlarc should be empty wlarc='$wl' # Set some defaults for GNU ld with shared library support. These # are reset later if shared libraries are not supported. Putting them # here allows them to be overridden if necessary. runpath_var=LD_RUN_PATH hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' export_dynamic_flag_spec='$wl--export-dynamic' # ancient GNU ld didn't support --whole-archive et. al. if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then whole_archive_flag_spec=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else whole_archive_flag_spec= fi supports_anon_versioning=no case `$LD -v | $SED -e 's/(^)\+)\s\+//' 2>&1` in *GNU\ gold*) supports_anon_versioning=yes ;; *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... *\ 2.11.*) ;; # other 2.11 versions *) supports_anon_versioning=yes ;; esac # See if GNU ld supports shared libraries. case $host_os in aix[3-9]*) # On AIX/PPC, the GNU linker is very broken if test ia64 != "$host_cpu"; then ld_shlibs=no cat <<_LT_EOF 1>&2 *** Warning: the GNU linker, at least up to release 2.19, is reported *** to be unable to reliably create shared libraries on AIX. *** Therefore, libtool is disabling shared libraries support. If you *** really care for shared libraries, you may want to install binutils *** 2.20 or above, or modify your PATH so that a non-GNU linker is found. *** You will then need to restart the configuration process. _LT_EOF fi ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='' ;; m68k) archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes ;; esac ;; beos*) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then allow_undefined_flag=unsupported # Joseph Beckenbach <jrb3@best.com> says some releases of gcc # support --undefined. This deserves some investigation. FIXME archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' else ld_shlibs=no fi ;; cygwin* | mingw* | pw32* | cegcc*) # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, # as there is no search path for DLLs. hardcode_libdir_flag_spec='-L$libdir' export_dynamic_flag_spec='$wl--export-all-symbols' allow_undefined_flag=unsupported always_export_symbols=no enable_shared_with_static_runtimes=yes export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file, use it as # is; otherwise, prepend EXPORTS... archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else ld_shlibs=no fi ;; haiku*) archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' link_all_deplibs=yes ;; os2*) hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes allow_undefined_flag=unsupported shrext_cmds=.dll archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' enable_shared_with_static_runtimes=yes ;; interix[3-9]*) hardcode_direct=no hardcode_shlibpath_var=no hardcode_libdir_flag_spec='$wl-rpath,$libdir' export_dynamic_flag_spec='$wl-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' archive_expsym_cmds='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) tmp_diet=no if test linux-dietlibc = "$host_os"; then case $cc_basename in diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) esac fi if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ && test no = "$tmp_diet" then tmp_addflag=' $pic_flag' tmp_sharedflag='-shared' case $cc_basename,$host_cpu in pgcc*) # Portland Group C compiler whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag' ;; pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group f77 and f90 compilers whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 tmp_addflag=' -i_dynamic -nofor_main' ;; ifc* | ifort*) # Intel Fortran compiler tmp_addflag=' -nofor_main' ;; lf95*) # Lahey Fortran 8.1 whole_archive_flag_spec= tmp_sharedflag='--shared' ;; nagfor*) # NAGFOR 5.3 tmp_sharedflag='-Wl,-shared' ;; xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below) tmp_sharedflag='-qmkshrobj' tmp_addflag= ;; nvcc*) # Cuda Compiler Driver 2.2 whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' compiler_needs_object=yes ;; esac case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C 5.9 whole_archive_flag_spec='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' compiler_needs_object=yes tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 tmp_sharedflag='-G' ;; esac archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' if test yes = "$supports_anon_versioning"; then archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi case $cc_basename in tcc*) export_dynamic_flag_spec='-rdynamic' ;; xlf* | bgf* | bgxlf* | mpixlf*) # IBM XL Fortran 10.1 on PPC cannot create shared libs itself whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive' hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' if test yes = "$supports_anon_versioning"; then archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' fi ;; esac else ld_shlibs=no fi ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= else archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' fi ;; solaris*) if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then ld_shlibs=no cat <<_LT_EOF 1>&2 *** Warning: The releases 2.8.* of the GNU linker cannot reliably *** create shared libraries on Solaris systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.9.1 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs=no fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) case `$LD -v 2>&1` in *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) ld_shlibs=no cat <<_LT_EOF 1>&2 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot *** reliably create shared libraries on SCO systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.16.91.0.3 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF ;; *) # For security reasons, it is highly recommended that you always # use absolute paths for naming shared libraries, and exclude the # DT_RUNPATH tag from executables and libraries. But doing so # requires that you compile everything twice, which is a pain. if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs=no fi ;; esac ;; sunos4*) archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' wlarc= hardcode_direct=yes hardcode_shlibpath_var=no ;; *) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs=no fi ;; esac if test no = "$ld_shlibs"; then runpath_var= hardcode_libdir_flag_spec= export_dynamic_flag_spec= whole_archive_flag_spec= fi else # PORTME fill in a description of your system's linker (not GNU ld) case $host_os in aix3*) allow_undefined_flag=unsupported always_export_symbols=yes archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' # Note: this linker hardcodes the directories in LIBPATH if there # are no directories specified by -L. hardcode_minus_L=yes if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. hardcode_direct=unsupported fi ;; aix[4-9]*) if test ia64 = "$host_cpu"; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag= else # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to GNU nm, but means don't demangle to AIX nm. # Without the "-l" option, or with the "-B" option, AIX nm treats # weak defined symbols like other global defined symbols, whereas # GNU nm marks them as "W". # While the 'weak' keyword is ignored in the Export File, we need # it in the Import File for the 'aix-soname' feature, so we have # to replace the "-B" option with "-P" for AIX nm. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else export_symbols_cmds='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # have runtime linking enabled, and use it for executables. # For shared libraries, we enable/disable runtime linking # depending on the kind of the shared library created - # when "with_aix_soname,aix_use_runtimelinking" is: # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables # "aix,yes" lib.so shared, rtl:yes, for executables # lib.a static archive # "both,no" lib.so.V(shr.o) shared, rtl:yes # lib.a(lib.so.V) shared, rtl:no, for executables # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a(lib.so.V) shared, rtl:no # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a static archive case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) for ld_flag in $LDFLAGS; do if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then aix_use_runtimelinking=yes break fi done if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then # With aix-soname=svr4, we create the lib.so.V shared archives only, # so we don't have lib.a shared libs to link our executables. # We have to force runtime linking in this case. aix_use_runtimelinking=yes LDFLAGS="$LDFLAGS -Wl,-brtl" fi ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. archive_cmds='' hardcode_direct=yes hardcode_direct_absolute=yes hardcode_libdir_separator=':' link_all_deplibs=yes file_list_spec='$wl-f,' case $with_aix_soname,$aix_use_runtimelinking in aix,*) ;; # traditional, no import file svr4,* | *,yes) # use import file # The Import File defines what to hardcode. hardcode_direct=no hardcode_direct_absolute=no ;; esac if test yes = "$GCC"; then case $host_os in aix4.[012]|aix4.[012].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`$CC -print-prog-name=collect2` if test -f "$collect2name" && strings "$collect2name" | $GREP resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 hardcode_direct=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking hardcode_minus_L=yes hardcode_libdir_flag_spec='-L$libdir' hardcode_libdir_separator= fi ;; esac shared_flag='-shared' if test yes = "$aix_use_runtimelinking"; then shared_flag="$shared_flag "'$wl-G' fi # Need to ensure runtime linking is disabled for the traditional # shared library, or the linker may eventually find shared libraries # /with/ Import File - we do not want to mix them. shared_flag_aix='-shared' shared_flag_svr4='-shared $wl-G' else # not using gcc if test ia64 = "$host_cpu"; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test yes = "$aix_use_runtimelinking"; then shared_flag='$wl-G' else shared_flag='$wl-bM:SRE' fi shared_flag_aix='$wl-bM:SRE' shared_flag_svr4='$wl-G' fi fi export_dynamic_flag_spec='$wl-bexpall' # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. always_export_symbols=yes if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. allow_undefined_flag='-berok' # Determine the default libpath from the value encoded in an # empty executable. if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else if ${lt_cv_aix_libpath_+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\([^ ]*\) *$/\1/ p } }' lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$lt_cv_aix_libpath_"; then lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext if test -z "$lt_cv_aix_libpath_"; then lt_cv_aix_libpath_=/usr/lib:/lib fi fi aix_libpath=$lt_cv_aix_libpath_ fi hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath" archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag else if test ia64 = "$host_cpu"; then hardcode_libdir_flag_spec='$wl-R $libdir:/usr/lib:/lib' allow_undefined_flag="-z nodefs" archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an # empty executable. if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else if ${lt_cv_aix_libpath_+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\([^ ]*\) *$/\1/ p } }' lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$lt_cv_aix_libpath_"; then lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext if test -z "$lt_cv_aix_libpath_"; then lt_cv_aix_libpath_=/usr/lib:/lib fi fi aix_libpath=$lt_cv_aix_libpath_ fi hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. no_undefined_flag=' $wl-bernotok' allow_undefined_flag=' $wl-berok' if test yes = "$with_gnu_ld"; then # We only use this code for GNU lds that support --whole-archive. whole_archive_flag_spec='$wl--whole-archive$convenience $wl--no-whole-archive' else # Exported symbols can be pulled into shared objects from archives whole_archive_flag_spec='$convenience' fi archive_cmds_need_lc=yes archive_expsym_cmds='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' # -brtl affects multiple linker settings, -berok does not and is overridden later compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`' if test svr4 != "$with_aix_soname"; then # This is similar to how AIX traditionally builds its shared libraries. archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' fi if test aix != "$with_aix_soname"; then archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' else # used by -dlpreopen to get the symbols archive_expsym_cmds="$archive_expsym_cmds"'~$MV $output_objdir/$realname.d/$soname $output_objdir' fi archive_expsym_cmds="$archive_expsym_cmds"'~$RM -r $output_objdir/$realname.d' fi fi ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds='' ;; m68k) archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes ;; esac ;; bsdi[45]*) export_dynamic_flag_spec=-rdynamic ;; cygwin* | mingw* | pw32* | cegcc*) # When not using gcc, we currently assume that we are using # Microsoft Visual C++. # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. case $cc_basename in cl*) # Native MSVC hardcode_libdir_flag_spec=' ' allow_undefined_flag=unsupported always_export_symbols=yes file_list_spec='@' # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then cp "$export_symbols" "$output_objdir/$soname.def"; echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; else $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; fi~ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, )='true' enable_shared_with_static_runtimes=yes exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' # Don't use ranlib old_postinstall_cmds='chmod 644 $oldlib' postlink_cmds='lt_outputfile="@OUTPUT@"~ lt_tool_outputfile="@TOOL_OUTPUT@"~ case $lt_outputfile in *.exe|*.EXE) ;; *) lt_outputfile=$lt_outputfile.exe lt_tool_outputfile=$lt_tool_outputfile.exe ;; esac~ if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; $RM "$lt_outputfile.manifest"; fi' ;; *) # Assume MSVC wrapper hardcode_libdir_flag_spec=' ' allow_undefined_flag=unsupported # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' # The linker will automatically build a .lib file if we build a DLL. old_archive_from_new_cmds='true' # FIXME: Should let the user specify the lib program. old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' enable_shared_with_static_runtimes=yes ;; esac ;; darwin* | rhapsody*) archive_cmds_need_lc=no hardcode_direct=no hardcode_automatic=yes hardcode_shlibpath_var=unsupported if test yes = "$lt_cv_ld_force_load"; then whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' else whole_archive_flag_spec='' fi link_all_deplibs=yes allow_undefined_flag=$_lt_dar_allow_undefined case $cc_basename in ifort*|nagfor*) _lt_dar_can_shared=yes ;; *) _lt_dar_can_shared=$GCC ;; esac if test yes = "$_lt_dar_can_shared"; then output_verbose_link_cmd=func_echo_all archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" archive_expsym_cmds="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" module_expsym_cmds="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" else ld_shlibs=no fi ;; dgux*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec='-L$libdir' hardcode_shlibpath_var=no ;; # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor # support. Future versions do this automatically, but an explicit c++rt0.o # does not break anything, and helps significantly (at the cost of a little # extra space). freebsd2.2*) archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no ;; # Unfortunately, older versions of FreeBSD 2 do not have this feature. freebsd2.*) archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes hardcode_minus_L=yes hardcode_shlibpath_var=no ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. freebsd* | dragonfly*) archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no ;; hpux9*) if test yes = "$GCC"; then archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' else archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' fi hardcode_libdir_flag_spec='$wl+b $wl$libdir' hardcode_libdir_separator=: hardcode_direct=yes # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes export_dynamic_flag_spec='$wl-E' ;; hpux10*) if test yes,no = "$GCC,$with_gnu_ld"; then archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi if test no = "$with_gnu_ld"; then hardcode_libdir_flag_spec='$wl+b $wl$libdir' hardcode_libdir_separator=: hardcode_direct=yes hardcode_direct_absolute=yes export_dynamic_flag_spec='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes fi ;; hpux11*) if test yes,no = "$GCC,$with_gnu_ld"; then case $host_cpu in hppa*64*) archive_cmds='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else case $host_cpu in hppa*64*) archive_cmds='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) # Older versions of the 11.00 compiler do not understand -b yet # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5 $as_echo_n "checking if $CC understands -b... " >&6; } if ${lt_cv_prog_compiler__b+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler__b=no save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS -b" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&5 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler__b=yes fi else lt_cv_prog_compiler__b=yes fi fi $RM -r conftest* LDFLAGS=$save_LDFLAGS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5 $as_echo "$lt_cv_prog_compiler__b" >&6; } if test yes = "$lt_cv_prog_compiler__b"; then archive_cmds='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi ;; esac fi if test no = "$with_gnu_ld"; then hardcode_libdir_flag_spec='$wl+b $wl$libdir' hardcode_libdir_separator=: case $host_cpu in hppa*64*|ia64*) hardcode_direct=no hardcode_shlibpath_var=no ;; *) hardcode_direct=yes hardcode_direct_absolute=yes export_dynamic_flag_spec='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes ;; esac fi ;; irix5* | irix6* | nonstopux*) if test yes = "$GCC"; then archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' # Try to use the -exported_symbol ld option, if it does not # work, assume that -exports_file does not work either and # implicitly export all symbols. # This should be the same for all languages, so no per-tag cache variable. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5 $as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; } if ${lt_cv_irix_exported_symbol+:} false; then : $as_echo_n "(cached) " >&6 else save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int foo (void) { return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : lt_cv_irix_exported_symbol=yes else lt_cv_irix_exported_symbol=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$save_LDFLAGS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5 $as_echo "$lt_cv_irix_exported_symbol" >&6; } if test yes = "$lt_cv_irix_exported_symbol"; then archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' fi else archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' fi archive_cmds_need_lc='no' hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' hardcode_libdir_separator=: inherit_rpath=yes link_all_deplibs=yes ;; linux*) case $cc_basename in tcc*) # Fabrice Bellard et al's Tiny C Compiler ld_shlibs=yes archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF fi hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no ;; newsos6) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' hardcode_libdir_separator=: hardcode_shlibpath_var=no ;; *nto* | *qnx*) ;; openbsd* | bitrig*) if test -f /usr/libexec/ld.so; then hardcode_direct=yes hardcode_shlibpath_var=no hardcode_direct_absolute=yes if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' hardcode_libdir_flag_spec='$wl-rpath,$libdir' export_dynamic_flag_spec='$wl-E' else archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec='$wl-rpath,$libdir' fi else ld_shlibs=no fi ;; os2*) hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes allow_undefined_flag=unsupported shrext_cmds=.dll archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' enable_shared_with_static_runtimes=yes ;; osf3*) if test yes = "$GCC"; then allow_undefined_flag=' $wl-expect_unresolved $wl\*' archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' else allow_undefined_flag=' -expect_unresolved \*' archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' fi archive_cmds_need_lc='no' hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' hardcode_libdir_separator=: ;; osf4* | osf5*) # as osf3* with the addition of -msym flag if test yes = "$GCC"; then allow_undefined_flag=' $wl-expect_unresolved $wl\*' archive_cmds='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' else allow_undefined_flag=' -expect_unresolved \*' archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp' # Both c and cxx compiler support -rpath directly hardcode_libdir_flag_spec='-rpath $libdir' fi archive_cmds_need_lc='no' hardcode_libdir_separator=: ;; solaris*) no_undefined_flag=' -z defs' if test yes = "$GCC"; then wlarc='$wl' archive_cmds='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' else case `$CC -V 2>&1` in *"Compilers 5.0"*) wlarc='' archive_cmds='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags' archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' ;; *) wlarc='$wl' archive_cmds='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' ;; esac fi hardcode_libdir_flag_spec='-R$libdir' hardcode_shlibpath_var=no case $host_os in solaris2.[0-5] | solaris2.[0-5].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands '-z linker_flag'. GCC discards it without '$wl', # but is careful enough not to reorder. # Supported since Solaris 2.6 (maybe 2.5.1?) if test yes = "$GCC"; then whole_archive_flag_spec='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' else whole_archive_flag_spec='-z allextract$convenience -z defaultextract' fi ;; esac link_all_deplibs=yes ;; sunos4*) if test sequent = "$host_vendor"; then # Use $CC to link under sequent, because it throws in some extra .o # files that make .init and .fini sections work. archive_cmds='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' fi hardcode_libdir_flag_spec='-L$libdir' hardcode_direct=yes hardcode_minus_L=yes hardcode_shlibpath_var=no ;; sysv4) case $host_vendor in sni) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes # is this really true??? ;; siemens) ## LD is ld it makes a PLAMLIB ## CC just makes a GrossModule. archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' reload_cmds='$CC -r -o $output$reload_objs' hardcode_direct=no ;; motorola) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=no #Motorola manual says yes, but my tests say they lie ;; esac runpath_var='LD_RUN_PATH' hardcode_shlibpath_var=no ;; sysv4.3*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var=no export_dynamic_flag_spec='-Bexport' ;; sysv4*MP*) if test -d /usr/nec; then archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var=no runpath_var=LD_RUN_PATH hardcode_runpath_var=yes ld_shlibs=yes fi ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) no_undefined_flag='$wl-z,text' archive_cmds_need_lc=no hardcode_shlibpath_var=no runpath_var='LD_RUN_PATH' if test yes = "$GCC"; then archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We CANNOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. no_undefined_flag='$wl-z,text' allow_undefined_flag='$wl-z,nodefs' archive_cmds_need_lc=no hardcode_shlibpath_var=no hardcode_libdir_flag_spec='$wl-R,$libdir' hardcode_libdir_separator=':' link_all_deplibs=yes export_dynamic_flag_spec='$wl-Bexport' runpath_var='LD_RUN_PATH' if test yes = "$GCC"; then archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; uts4*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec='-L$libdir' hardcode_shlibpath_var=no ;; *) ld_shlibs=no ;; esac if test sni = "$host_vendor"; then case $host in sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) export_dynamic_flag_spec='$wl-Blargedynsym' ;; esac fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 $as_echo "$ld_shlibs" >&6; } test no = "$ld_shlibs" && can_build_shared=no with_gnu_ld=$with_gnu_ld # # Do we need to explicitly link libc? # case "x$archive_cmds_need_lc" in x|xyes) # Assume -lc should be added archive_cmds_need_lc=yes if test yes,yes = "$GCC,$enable_shared"; then case $archive_cmds in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } if ${lt_cv_archive_cmds_need_lc+:} false; then : $as_echo_n "(cached) " >&6 else $RM conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$lt_prog_compiler_wl pic_flag=$lt_prog_compiler_pic compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$allow_undefined_flag allow_undefined_flag= if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } then lt_cv_archive_cmds_need_lc=no else lt_cv_archive_cmds_need_lc=yes fi allow_undefined_flag=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5 $as_echo "$lt_cv_archive_cmds_need_lc" >&6; } archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc ;; esac fi ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 $as_echo_n "checking dynamic linker characteristics... " >&6; } if test yes = "$GCC"; then case $host_os in darwin*) lt_awk_arg='/^libraries:/,/LR/' ;; *) lt_awk_arg='/^libraries:/' ;; esac case $host_os in mingw* | cegcc*) lt_sed_strip_eq='s|=\([A-Za-z]:\)|\1|g' ;; *) lt_sed_strip_eq='s|=/|/|g' ;; esac lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` case $lt_search_path_spec in *\;*) # if the path contains ";" then we assume it to be the separator # otherwise default to the standard path separator (i.e. ":") - it is # assumed that no part of a normal pathname contains ";" but that should # okay in the real world where ";" in dirpaths is itself problematic. lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` ;; *) lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` ;; esac # Ok, now we have the path, separated by spaces, we can step through it # and add multilib dir if necessary... lt_tmp_lt_search_path_spec= lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` # ...but if some path component already ends with the multilib dir we assume # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer). case "$lt_multi_os_dir; $lt_search_path_spec " in "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*) lt_multi_os_dir= ;; esac for lt_sys_path in $lt_search_path_spec; do if test -d "$lt_sys_path$lt_multi_os_dir"; then lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir" elif test -n "$lt_multi_os_dir"; then test -d "$lt_sys_path" && \ lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" fi done lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' BEGIN {RS = " "; FS = "/|\n";} { lt_foo = ""; lt_count = 0; for (lt_i = NF; lt_i > 0; lt_i--) { if ($lt_i != "" && $lt_i != ".") { if ($lt_i == "..") { lt_count++; } else { if (lt_count == 0) { lt_foo = "/" $lt_i lt_foo; } else { lt_count--; } } } } if (lt_foo != "") { lt_freq[lt_foo]++; } if (lt_freq[lt_foo] == 1) { print lt_foo; } }'` # AWK program above erroneously prepends '/' to C:/dos/paths # for these hosts. case $host_os in mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ $SED 's|/\([A-Za-z]:\)|\1|g'` ;; esac sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` else sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" fi library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=.so postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown case $host_os in aix3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='$libname$release$shared_ext$major' ;; aix[4-9]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no hardcode_into_libs=yes if test ia64 = "$host_cpu"; then # AIX 5 supports IA64 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line '#! .'. This would cause the generated library to # depend on '.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[01] | aix4.[01].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then : else can_build_shared=no fi ;; esac # Using Import Files as archive members, it is possible to support # filename-based versioning of shared library archives on AIX. While # this would work for both with and without runtime linking, it will # prevent static linking of such archives. So we do filename-based # shared library versioning with .so extension only, which is used # when both runtime linking and shared linking is enabled. # Unfortunately, runtime linking may impact performance, so we do # not want this to be the default eventually. Also, we use the # versioned .so libs for executables only if there is the -brtl # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. # To allow for filename-based versioning support, we need to create # libNAME.so.V as an archive file, containing: # *) an Import File, referring to the versioned filename of the # archive as well as the shared archive member, telling the # bitwidth (32 or 64) of that shared object, and providing the # list of exported symbols of that shared object, eventually # decorated with the 'weak' keyword # *) the shared object with the F_LOADONLY flag set, to really avoid # it being seen by the linker. # At run time we better use the real file rather than another symlink, # but for link time we create the symlink libNAME.so -> libNAME.so.V case $with_aix_soname,$aix_use_runtimelinking in # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. aix,yes) # traditional libtool dynamic_linker='AIX unversionable lib.so' # If using run time linking (on AIX 4.2 or later) use lib<name>.so # instead of lib<name>.a to let people know that these are not # typical AIX shared libraries. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; aix,no) # traditional AIX only dynamic_linker='AIX lib.a(lib.so.V)' # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' ;; svr4,*) # full svr4 only dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,yes) # both, prefer svr4 dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # unpreferred sharedlib libNAME.a needs extra handling postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,no) # both, prefer aix dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)" library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' ;; esac shlibpath_var=LIBPATH fi ;; amigaos*) case $host_cpu in powerpc) # Since July 2007 AmigaOS4 officially supports .so libraries. # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; m68k) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; esac ;; beos*) library_names_spec='$libname$shared_ext' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[45]*) version_type=linux # correct to gnu/linux during the next big refactor need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | mingw* | pw32* | cegcc*) version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no case $GCC,$cc_basename in yes,*) # gcc library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api" ;; mingw* | cegcc*) # MinGW DLLs use traditional 'lib' prefix soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' ;; esac dynamic_linker='Win32 ld.exe' ;; *,cl*) # Native MSVC libname_spec='$name' soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' library_names_spec='$libname.dll.lib' case $build_os in mingw*) sys_lib_search_path_spec= lt_save_ifs=$IFS IFS=';' for lt_path in $LIB do IFS=$lt_save_ifs # Let DOS variable expansion print the short 8.3 style file name. lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" done IFS=$lt_save_ifs # Convert to MSYS style. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` ;; cygwin*) # Convert to unix form, then to dos form, then back to unix form # but this time dos style (no spaces!) so that the unix form looks # like /cygdrive/c/PROGRA~1:/cygdr... sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` ;; *) sys_lib_search_path_spec=$LIB if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then # It is most probably a Windows format PATH. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi # FIXME: find the short name or the path components, as spaces are # common. (e.g. "Program Files" -> "PROGRA~1") ;; esac # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes dynamic_linker='Win32 link.exe' ;; *) # Assume MSVC wrapper library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib' dynamic_linker='Win32 ld.exe' ;; esac # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' soname_spec='$libname$release$major$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd* | dragonfly*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[23].*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2.*) shlibpath_overrides_runpath=yes ;; freebsd3.[01]* | freebsdelf3.[01]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; haiku*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no dynamic_linker="$host_os runtime_loader" library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LIBRARY_PATH shlibpath_overrides_runpath=no sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' if test 32 = "$HPUX_IA64_MODE"; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" sys_lib_dlsearch_path_spec=/usr/lib/hpux32 else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" sys_lib_dlsearch_path_spec=/usr/lib/hpux64 fi ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555, ... postinstall_cmds='chmod 555 $lib' # or fails outright, so override atomically: install_override_mode=555 ;; interix[3-9]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test yes = "$lt_cv_prog_gnu_ld"; then version_type=linux # correct to gnu/linux during the next big refactor else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; linux*android*) version_type=none # Android doesn't support versioned libraries. need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext' soname_spec='$libname$release$shared_ext' finish_cmds= shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes dynamic_linker='Android linker' # Don't embed -rpath directories since the linker doesn't support them. hardcode_libdir_flag_spec='-L$libdir' ;; # This must be glibc/ELF. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # Some binutils ld are patched to set DT_RUNPATH if ${lt_cv_shlibpath_overrides_runpath+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_shlibpath_overrides_runpath=no save_LDFLAGS=$LDFLAGS save_libdir=$libdir eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \ LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\"" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : lt_cv_shlibpath_overrides_runpath=yes fi fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$save_LDFLAGS libdir=$save_libdir fi shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Add ABI-specific directories to the system library path. sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" # Ideally, we could use ldconfig to report *all* directores which are # searched for libraries, however this is still not possible. Aside from not # being certain /sbin/ldconfig is available, command # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, # even though it is searched at run-time. Try to do the best guess by # appending ld.so.conf contents (and includes) to the search path. if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; *nto* | *qnx*) version_type=qnx need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='ldqnx.so' ;; openbsd* | bitrig*) version_type=sunos sys_lib_dlsearch_path_spec=/usr/lib need_lib_prefix=no if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then need_version=no else need_version=yes fi library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; os2*) libname_spec='$name' version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no # OS/2 can only load a DLL with a base name of 8 characters or less. soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; v=$($ECHO $release$versuffix | tr -d .-); n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); $ECHO $n$v`$shared_ext' library_names_spec='${libname}_dll.$libext' dynamic_linker='OS/2 ld.exe' shlibpath_var=BEGINLIBPATH sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test yes = "$with_gnu_ld"; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec; then version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' soname_spec='$libname$shared_ext.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=sco need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes if test yes = "$with_gnu_ld"; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; tpf*) # TPF is a cross-target only. Preferred cross-host = GNU/Linux. version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; uts4*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 $as_echo "$dynamic_linker" >&6; } test no = "$dynamic_linker" && can_build_shared=no variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test yes = "$GCC"; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec fi if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec fi # remember unaugmented sys_lib_dlsearch_path content for libtool script decls... configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 $as_echo_n "checking how to hardcode library paths into programs... " >&6; } hardcode_action= if test -n "$hardcode_libdir_flag_spec" || test -n "$runpath_var" || test yes = "$hardcode_automatic"; then # We can hardcode non-existent directories. if test no != "$hardcode_direct" && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, )" && test no != "$hardcode_minus_L"; then # Linking always hardcodes the temporary library directory. hardcode_action=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. hardcode_action=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. hardcode_action=unsupported fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 $as_echo "$hardcode_action" >&6; } if test relink = "$hardcode_action" || test yes = "$inherit_rpath"; then # Fast installation is not supported enable_fast_install=no elif test yes = "$shlibpath_overrides_runpath" || test no = "$enable_shared"; then # Fast installation is not necessary enable_fast_install=needless fi if test yes != "$enable_dlopen"; then enable_dlopen=unknown enable_dlopen_self=unknown enable_dlopen_self_static=unknown else lt_cv_dlopen=no lt_cv_dlopen_libs= case $host_os in beos*) lt_cv_dlopen=load_add_on lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ;; mingw* | pw32* | cegcc*) lt_cv_dlopen=LoadLibrary lt_cv_dlopen_libs= ;; cygwin*) lt_cv_dlopen=dlopen lt_cv_dlopen_libs= ;; darwin*) # if libdl is installed we need to link against it { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 $as_echo_n "checking for dlopen in -ldl... " >&6; } if ${ac_cv_lib_dl_dlopen+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dlopen (); int main () { return dlopen (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_dl_dlopen=yes else ac_cv_lib_dl_dlopen=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 $as_echo "$ac_cv_lib_dl_dlopen" >&6; } if test "x$ac_cv_lib_dl_dlopen" = xyes; then : lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl else lt_cv_dlopen=dyld lt_cv_dlopen_libs= lt_cv_dlopen_self=yes fi ;; tpf*) # Don't try to run any link tests for TPF. We know it's impossible # because TPF is a cross-compiler, and we know how we open DSOs. lt_cv_dlopen=dlopen lt_cv_dlopen_libs= lt_cv_dlopen_self=no ;; *) ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" if test "x$ac_cv_func_shl_load" = xyes; then : lt_cv_dlopen=shl_load else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 $as_echo_n "checking for shl_load in -ldld... " >&6; } if ${ac_cv_lib_dld_shl_load+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldld $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char shl_load (); int main () { return shl_load (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_dld_shl_load=yes else ac_cv_lib_dld_shl_load=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 $as_echo "$ac_cv_lib_dld_shl_load" >&6; } if test "x$ac_cv_lib_dld_shl_load" = xyes; then : lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld else ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" if test "x$ac_cv_func_dlopen" = xyes; then : lt_cv_dlopen=dlopen else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 $as_echo_n "checking for dlopen in -ldl... " >&6; } if ${ac_cv_lib_dl_dlopen+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldl $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dlopen (); int main () { return dlopen (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_dl_dlopen=yes else ac_cv_lib_dl_dlopen=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 $as_echo "$ac_cv_lib_dl_dlopen" >&6; } if test "x$ac_cv_lib_dl_dlopen" = xyes; then : lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 $as_echo_n "checking for dlopen in -lsvld... " >&6; } if ${ac_cv_lib_svld_dlopen+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lsvld $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dlopen (); int main () { return dlopen (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_svld_dlopen=yes else ac_cv_lib_svld_dlopen=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 $as_echo "$ac_cv_lib_svld_dlopen" >&6; } if test "x$ac_cv_lib_svld_dlopen" = xyes; then : lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 $as_echo_n "checking for dld_link in -ldld... " >&6; } if ${ac_cv_lib_dld_dld_link+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldld $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dld_link (); int main () { return dld_link (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_dld_dld_link=yes else ac_cv_lib_dld_dld_link=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 $as_echo "$ac_cv_lib_dld_dld_link" >&6; } if test "x$ac_cv_lib_dld_dld_link" = xyes; then : lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld fi fi fi fi fi fi ;; esac if test no = "$lt_cv_dlopen"; then enable_dlopen=no else enable_dlopen=yes fi case $lt_cv_dlopen in dlopen) save_CPPFLAGS=$CPPFLAGS test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" save_LDFLAGS=$LDFLAGS wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" save_LIBS=$LIBS LIBS="$lt_cv_dlopen_libs $LIBS" { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 $as_echo_n "checking whether a program can dlopen itself... " >&6; } if ${lt_cv_dlopen_self+:} false; then : $as_echo_n "(cached) " >&6 else if test yes = "$cross_compiling"; then : lt_cv_dlopen_self=cross else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF #line $LINENO "configure" #include "confdefs.h" #if HAVE_DLFCN_H #include <dlfcn.h> #endif #include <stdio.h> #ifdef RTLD_GLOBAL # define LT_DLGLOBAL RTLD_GLOBAL #else # ifdef DL_GLOBAL # define LT_DLGLOBAL DL_GLOBAL # else # define LT_DLGLOBAL 0 # endif #endif /* We may have to define LT_DLLAZY_OR_NOW in the command line if we find out it does not work in some platform. */ #ifndef LT_DLLAZY_OR_NOW # ifdef RTLD_LAZY # define LT_DLLAZY_OR_NOW RTLD_LAZY # else # ifdef DL_LAZY # define LT_DLLAZY_OR_NOW DL_LAZY # else # ifdef RTLD_NOW # define LT_DLLAZY_OR_NOW RTLD_NOW # else # ifdef DL_NOW # define LT_DLLAZY_OR_NOW DL_NOW # else # define LT_DLLAZY_OR_NOW 0 # endif # endif # endif # endif #endif /* When -fvisibility=hidden is used, assume the code has been annotated correspondingly for the symbols needed. */ #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) int fnord () __attribute__((visibility("default"))); #endif int fnord () { return 42; } int main () { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; if (self) { if (dlsym (self,"fnord")) status = $lt_dlno_uscore; else { if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; else puts (dlerror ()); } /* dlclose (self); */ } else puts (dlerror ()); return status; } _LT_EOF if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 (eval $ac_link) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then (./conftest; exit; ) >&5 2>/dev/null lt_status=$? case x$lt_status in x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; esac else : # compilation failed lt_cv_dlopen_self=no fi fi rm -fr conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 $as_echo "$lt_cv_dlopen_self" >&6; } if test yes = "$lt_cv_dlopen_self"; then wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 $as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } if ${lt_cv_dlopen_self_static+:} false; then : $as_echo_n "(cached) " >&6 else if test yes = "$cross_compiling"; then : lt_cv_dlopen_self_static=cross else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF #line $LINENO "configure" #include "confdefs.h" #if HAVE_DLFCN_H #include <dlfcn.h> #endif #include <stdio.h> #ifdef RTLD_GLOBAL # define LT_DLGLOBAL RTLD_GLOBAL #else # ifdef DL_GLOBAL # define LT_DLGLOBAL DL_GLOBAL # else # define LT_DLGLOBAL 0 # endif #endif /* We may have to define LT_DLLAZY_OR_NOW in the command line if we find out it does not work in some platform. */ #ifndef LT_DLLAZY_OR_NOW # ifdef RTLD_LAZY # define LT_DLLAZY_OR_NOW RTLD_LAZY # else # ifdef DL_LAZY # define LT_DLLAZY_OR_NOW DL_LAZY # else # ifdef RTLD_NOW # define LT_DLLAZY_OR_NOW RTLD_NOW # else # ifdef DL_NOW # define LT_DLLAZY_OR_NOW DL_NOW # else # define LT_DLLAZY_OR_NOW 0 # endif # endif # endif # endif #endif /* When -fvisibility=hidden is used, assume the code has been annotated correspondingly for the symbols needed. */ #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) int fnord () __attribute__((visibility("default"))); #endif int fnord () { return 42; } int main () { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; if (self) { if (dlsym (self,"fnord")) status = $lt_dlno_uscore; else { if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; else puts (dlerror ()); } /* dlclose (self); */ } else puts (dlerror ()); return status; } _LT_EOF if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 (eval $ac_link) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then (./conftest; exit; ) >&5 2>/dev/null lt_status=$? case x$lt_status in x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; esac else : # compilation failed lt_cv_dlopen_self_static=no fi fi rm -fr conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 $as_echo "$lt_cv_dlopen_self_static" >&6; } fi CPPFLAGS=$save_CPPFLAGS LDFLAGS=$save_LDFLAGS LIBS=$save_LIBS ;; esac case $lt_cv_dlopen_self in yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; *) enable_dlopen_self=unknown ;; esac case $lt_cv_dlopen_self_static in yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; *) enable_dlopen_self_static=unknown ;; esac fi striplib= old_striplib= { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 $as_echo_n "checking whether stripping libraries is possible... " >&6; } if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" test -z "$striplib" && striplib="$STRIP --strip-unneeded" { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else # FIXME - insert some real tests, host_os isn't really good enough case $host_os in darwin*) if test -n "$STRIP"; then striplib="$STRIP -x" old_striplib="$STRIP -S" { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi ;; *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } ;; esac fi # Report what library types will actually be built { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 $as_echo_n "checking if libtool supports shared libraries... " >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 $as_echo "$can_build_shared" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 $as_echo_n "checking whether to build shared libraries... " >&6; } test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[4-9]*) if test ia64 != "$host_cpu"; then case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in yes,aix,yes) ;; # shared object as lib.so file only yes,svr4,*) ;; # shared object as lib.so archive member only yes,*) enable_static=no ;; # shared object in lib.a archive as well esac fi ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 $as_echo "$enable_shared" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 $as_echo_n "checking whether to build static libraries... " >&6; } # Make sure either enable_shared or enable_static is yes. test yes = "$enable_shared" || enable_static=yes { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 $as_echo "$enable_static" >&6; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu CC=$lt_save_CC if test -n "$CXX" && ( test no != "$CXX" && ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) || (test g++ != "$CXX"))); then ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 $as_echo_n "checking how to run the C++ preprocessor... " >&6; } if test -z "$CXXCPP"; then if ${ac_cv_prog_CXXCPP+:} false; then : $as_echo_n "(cached) " >&6 else # Double quotes because CXXCPP needs to be expanded for CXXCPP in "$CXX -E" "/lib/cpp" do ac_preproc_ok=false for ac_cxx_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since # <limits.h> exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __STDC__ # include <limits.h> #else # include <assert.h> #endif Syntax error _ACEOF if ac_fn_cxx_try_cpp "$LINENO"; then : else # Broken: fails on valid input. continue fi rm -f conftest.err conftest.i conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <ac_nonexistent.h> _ACEOF if ac_fn_cxx_try_cpp "$LINENO"; then : # Broken: success on invalid input. continue else # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.i conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.i conftest.err conftest.$ac_ext if $ac_preproc_ok; then : break fi done ac_cv_prog_CXXCPP=$CXXCPP fi CXXCPP=$ac_cv_prog_CXXCPP else ac_cv_prog_CXXCPP=$CXXCPP fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 $as_echo "$CXXCPP" >&6; } ac_preproc_ok=false for ac_cxx_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since # <limits.h> exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifdef __STDC__ # include <limits.h> #else # include <assert.h> #endif Syntax error _ACEOF if ac_fn_cxx_try_cpp "$LINENO"; then : else # Broken: fails on valid input. continue fi rm -f conftest.err conftest.i conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <ac_nonexistent.h> _ACEOF if ac_fn_cxx_try_cpp "$LINENO"; then : # Broken: success on invalid input. continue else # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.i conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.i conftest.err conftest.$ac_ext if $ac_preproc_ok; then : else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check See \`config.log' for more details" "$LINENO" 5; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu else _lt_caught_CXX_error=yes fi ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu archive_cmds_need_lc_CXX=no allow_undefined_flag_CXX= always_export_symbols_CXX=no archive_expsym_cmds_CXX= compiler_needs_object_CXX=no export_dynamic_flag_spec_CXX= hardcode_direct_CXX=no hardcode_direct_absolute_CXX=no hardcode_libdir_flag_spec_CXX= hardcode_libdir_separator_CXX= hardcode_minus_L_CXX=no hardcode_shlibpath_var_CXX=unsupported hardcode_automatic_CXX=no inherit_rpath_CXX=no module_cmds_CXX= module_expsym_cmds_CXX= link_all_deplibs_CXX=unknown old_archive_cmds_CXX=$old_archive_cmds reload_flag_CXX=$reload_flag reload_cmds_CXX=$reload_cmds no_undefined_flag_CXX= whole_archive_flag_spec_CXX= enable_shared_with_static_runtimes_CXX=no # Source file extension for C++ test sources. ac_ext=cpp # Object file extension for compiled C++ test sources. objext=o objext_CXX=$objext # No sense in running all these tests if we already determined that # the CXX compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. if test yes != "$_lt_caught_CXX_error"; then # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(int, char *[]) { return(0); }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # save warnings/boilerplate of simple test code ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $RM conftest* ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $RM -r conftest* # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_LD=$LD lt_save_GCC=$GCC GCC=$GXX lt_save_with_gnu_ld=$with_gnu_ld lt_save_path_LD=$lt_cv_path_LD if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx else $as_unset lt_cv_prog_gnu_ld fi if test -n "${lt_cv_path_LDCXX+set}"; then lt_cv_path_LD=$lt_cv_path_LDCXX else $as_unset lt_cv_path_LD fi test -z "${LDCXX+set}" || LD=$LDCXX CC=${CXX-"c++"} CFLAGS=$CXXFLAGS compiler=$CC compiler_CXX=$CC func_cc_basename $compiler cc_basename=$func_cc_basename_result if test -n "$compiler"; then # We don't want -fno-exception when compiling C++ code, so set the # no_builtin_flag separately if test yes = "$GXX"; then lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin' else lt_prog_compiler_no_builtin_flag_CXX= fi if test yes = "$GXX"; then # Set up default GNU C++ configuration # Check whether --with-gnu-ld was given. if test "${with_gnu_ld+set}" = set; then : withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes else with_gnu_ld=no fi ac_prog=ld if test yes = "$GCC"; then # Check if gcc -print-prog-name=ld gives a path. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 $as_echo_n "checking for ld used by $CC... " >&6; } case $host in *-*-mingw*) # gcc leaves a trailing carriage return, which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; esac case $ac_prog in # Accept absolute paths. [\\/]* | ?:[\\/]*) re_direlt='/[^/][^/]*/\.\./' # Canonicalize the pathname of ld ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` done test -z "$LD" && LD=$ac_prog ;; "") # If it fails, then pretend we aren't using GCC. ac_prog=ld ;; *) # If it is relative, then search for the first ld in PATH. with_gnu_ld=unknown ;; esac elif test yes = "$with_gnu_ld"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 $as_echo_n "checking for GNU ld... " >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 $as_echo_n "checking for non-GNU ld... " >&6; } fi if ${lt_cv_path_LD+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$LD"; then lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then lt_cv_path_LD=$ac_dir/$ac_prog # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some variants of GNU ld only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in *GNU* | *'with BFD'*) test no != "$with_gnu_ld" && break ;; *) test yes != "$with_gnu_ld" && break ;; esac fi done IFS=$lt_save_ifs else lt_cv_path_LD=$LD # Let the user override the test with a path. fi fi LD=$lt_cv_path_LD if test -n "$LD"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 $as_echo "$LD" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } if ${lt_cv_prog_gnu_ld+:} false; then : $as_echo_n "(cached) " >&6 else # I'd rather use --version here, but apparently some GNU lds only accept -v. case `$LD -v 2>&1 </dev/null` in *GNU* | *'with BFD'*) lt_cv_prog_gnu_ld=yes ;; *) lt_cv_prog_gnu_ld=no ;; esac fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5 $as_echo "$lt_cv_prog_gnu_ld" >&6; } with_gnu_ld=$lt_cv_prog_gnu_ld # Check if GNU C++ uses GNU ld as the underlying linker, since the # archiving commands below assume that GNU ld is being used. if test yes = "$with_gnu_ld"; then archive_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' export_dynamic_flag_spec_CXX='$wl--export-dynamic' # If archive_cmds runs LD, not CC, wlarc should be empty # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to # investigate it a little bit more. (MM) wlarc='$wl' # ancient GNU ld didn't support --whole-archive et. al. if eval "`$CC -print-prog-name=ld` --help 2>&1" | $GREP 'no-whole-archive' > /dev/null; then whole_archive_flag_spec_CXX=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else whole_archive_flag_spec_CXX= fi else with_gnu_ld=no wlarc= # A generic and very simple default shared library creation # command for GNU C++ for the case where it uses the native # linker, instead of GNU ld. If possible, this setting should # overridden to take advantage of the native linker features on # the platform it is being used on. archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' fi # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' else GXX=no with_gnu_ld=no wlarc= fi # PORTME: fill in a description of your system's C++ link characteristics { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } ld_shlibs_CXX=yes case $host_os in aix3*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; aix[4-9]*) if test ia64 = "$host_cpu"; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag= else aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # have runtime linking enabled, and use it for executables. # For shared libraries, we enable/disable runtime linking # depending on the kind of the shared library created - # when "with_aix_soname,aix_use_runtimelinking" is: # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables # "aix,yes" lib.so shared, rtl:yes, for executables # lib.a static archive # "both,no" lib.so.V(shr.o) shared, rtl:yes # lib.a(lib.so.V) shared, rtl:no, for executables # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a(lib.so.V) shared, rtl:no # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a static archive case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) for ld_flag in $LDFLAGS; do case $ld_flag in *-brtl*) aix_use_runtimelinking=yes break ;; esac done if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then # With aix-soname=svr4, we create the lib.so.V shared archives only, # so we don't have lib.a shared libs to link our executables. # We have to force runtime linking in this case. aix_use_runtimelinking=yes LDFLAGS="$LDFLAGS -Wl,-brtl" fi ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. archive_cmds_CXX='' hardcode_direct_CXX=yes hardcode_direct_absolute_CXX=yes hardcode_libdir_separator_CXX=':' link_all_deplibs_CXX=yes file_list_spec_CXX='$wl-f,' case $with_aix_soname,$aix_use_runtimelinking in aix,*) ;; # no import file svr4,* | *,yes) # use import file # The Import File defines what to hardcode. hardcode_direct_CXX=no hardcode_direct_absolute_CXX=no ;; esac if test yes = "$GXX"; then case $host_os in aix4.[012]|aix4.[012].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`$CC -print-prog-name=collect2` if test -f "$collect2name" && strings "$collect2name" | $GREP resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 hardcode_direct_CXX=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking hardcode_minus_L_CXX=yes hardcode_libdir_flag_spec_CXX='-L$libdir' hardcode_libdir_separator_CXX= fi esac shared_flag='-shared' if test yes = "$aix_use_runtimelinking"; then shared_flag=$shared_flag' $wl-G' fi # Need to ensure runtime linking is disabled for the traditional # shared library, or the linker may eventually find shared libraries # /with/ Import File - we do not want to mix them. shared_flag_aix='-shared' shared_flag_svr4='-shared $wl-G' else # not using gcc if test ia64 = "$host_cpu"; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test yes = "$aix_use_runtimelinking"; then shared_flag='$wl-G' else shared_flag='$wl-bM:SRE' fi shared_flag_aix='$wl-bM:SRE' shared_flag_svr4='$wl-G' fi fi export_dynamic_flag_spec_CXX='$wl-bexpall' # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to # export. always_export_symbols_CXX=yes if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. # The "-G" linker flag allows undefined symbols. no_undefined_flag_CXX='-bernotok' # Determine the default libpath from the value encoded in an empty # executable. if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else if ${lt_cv_aix_libpath__CXX+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_cxx_try_link "$LINENO"; then : lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\([^ ]*\) *$/\1/ p } }' lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$lt_cv_aix_libpath__CXX"; then lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext if test -z "$lt_cv_aix_libpath__CXX"; then lt_cv_aix_libpath__CXX=/usr/lib:/lib fi fi aix_libpath=$lt_cv_aix_libpath__CXX fi hardcode_libdir_flag_spec_CXX='$wl-blibpath:$libdir:'"$aix_libpath" archive_expsym_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag else if test ia64 = "$host_cpu"; then hardcode_libdir_flag_spec_CXX='$wl-R $libdir:/usr/lib:/lib' allow_undefined_flag_CXX="-z nodefs" archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an # empty executable. if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else if ${lt_cv_aix_libpath__CXX+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_cxx_try_link "$LINENO"; then : lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\([^ ]*\) *$/\1/ p } }' lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$lt_cv_aix_libpath__CXX"; then lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext if test -z "$lt_cv_aix_libpath__CXX"; then lt_cv_aix_libpath__CXX=/usr/lib:/lib fi fi aix_libpath=$lt_cv_aix_libpath__CXX fi hardcode_libdir_flag_spec_CXX='$wl-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. no_undefined_flag_CXX=' $wl-bernotok' allow_undefined_flag_CXX=' $wl-berok' if test yes = "$with_gnu_ld"; then # We only use this code for GNU lds that support --whole-archive. whole_archive_flag_spec_CXX='$wl--whole-archive$convenience $wl--no-whole-archive' else # Exported symbols can be pulled into shared objects from archives whole_archive_flag_spec_CXX='$convenience' fi archive_cmds_need_lc_CXX=yes archive_expsym_cmds_CXX='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' # -brtl affects multiple linker settings, -berok does not and is overridden later compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`' if test svr4 != "$with_aix_soname"; then # This is similar to how AIX traditionally builds its shared # libraries. Need -bnortl late, we may have -brtl in LDFLAGS. archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' fi if test aix != "$with_aix_soname"; then archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' else # used by -dlpreopen to get the symbols archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$MV $output_objdir/$realname.d/$soname $output_objdir' fi archive_expsym_cmds_CXX="$archive_expsym_cmds_CXX"'~$RM -r $output_objdir/$realname.d' fi fi ;; beos*) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then allow_undefined_flag_CXX=unsupported # Joseph Beckenbach <jrb3@best.com> says some releases of gcc # support --undefined. This deserves some investigation. FIXME archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' else ld_shlibs_CXX=no fi ;; chorus*) case $cc_basename in *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; cygwin* | mingw* | pw32* | cegcc*) case $GXX,$cc_basename in ,cl* | no,cl*) # Native MSVC # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. hardcode_libdir_flag_spec_CXX=' ' allow_undefined_flag_CXX=unsupported always_export_symbols_CXX=yes file_list_spec_CXX='@' # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. archive_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' archive_expsym_cmds_CXX='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then cp "$export_symbols" "$output_objdir/$soname.def"; echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; else $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; fi~ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, CXX)='true' enable_shared_with_static_runtimes_CXX=yes # Don't use ranlib old_postinstall_cmds_CXX='chmod 644 $oldlib' postlink_cmds_CXX='lt_outputfile="@OUTPUT@"~ lt_tool_outputfile="@TOOL_OUTPUT@"~ case $lt_outputfile in *.exe|*.EXE) ;; *) lt_outputfile=$lt_outputfile.exe lt_tool_outputfile=$lt_tool_outputfile.exe ;; esac~ func_to_tool_file "$lt_outputfile"~ if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; $RM "$lt_outputfile.manifest"; fi' ;; *) # g++ # _LT_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless, # as there is no search path for DLLs. hardcode_libdir_flag_spec_CXX='-L$libdir' export_dynamic_flag_spec_CXX='$wl--export-all-symbols' allow_undefined_flag_CXX=unsupported always_export_symbols_CXX=no enable_shared_with_static_runtimes_CXX=yes if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file, use it as # is; otherwise, prepend EXPORTS... archive_expsym_cmds_CXX='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else ld_shlibs_CXX=no fi ;; esac ;; darwin* | rhapsody*) archive_cmds_need_lc_CXX=no hardcode_direct_CXX=no hardcode_automatic_CXX=yes hardcode_shlibpath_var_CXX=unsupported if test yes = "$lt_cv_ld_force_load"; then whole_archive_flag_spec_CXX='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' else whole_archive_flag_spec_CXX='' fi link_all_deplibs_CXX=yes allow_undefined_flag_CXX=$_lt_dar_allow_undefined case $cc_basename in ifort*|nagfor*) _lt_dar_can_shared=yes ;; *) _lt_dar_can_shared=$GCC ;; esac if test yes = "$_lt_dar_can_shared"; then output_verbose_link_cmd=func_echo_all archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" archive_expsym_cmds_CXX="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" module_expsym_cmds_CXX="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" if test yes != "$lt_cv_apple_cc_single_mod"; then archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil" archive_expsym_cmds_CXX="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil" fi else ld_shlibs_CXX=no fi ;; os2*) hardcode_libdir_flag_spec_CXX='-L$libdir' hardcode_minus_L_CXX=yes allow_undefined_flag_CXX=unsupported shrext_cmds=.dll archive_cmds_CXX='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' archive_expsym_cmds_CXX='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' old_archive_From_new_cmds_CXX='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' enable_shared_with_static_runtimes_CXX=yes ;; dgux*) case $cc_basename in ec++*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; ghcx*) # Green Hills C++ Compiler # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; freebsd2.*) # C++ shared libraries reported to be fairly broken before # switch to ELF ld_shlibs_CXX=no ;; freebsd-elf*) archive_cmds_need_lc_CXX=no ;; freebsd* | dragonfly*) # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF # conventions ld_shlibs_CXX=yes ;; haiku*) archive_cmds_CXX='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' link_all_deplibs_CXX=yes ;; hpux9*) hardcode_libdir_flag_spec_CXX='$wl+b $wl$libdir' hardcode_libdir_separator_CXX=: export_dynamic_flag_spec_CXX='$wl-E' hardcode_direct_CXX=yes hardcode_minus_L_CXX=yes # Not in the search PATH, # but as the default # location of the library. case $cc_basename in CC*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; aCC*) archive_cmds_CXX='$RM $output_objdir/$soname~$CC -b $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes = "$GXX"; then archive_cmds_CXX='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' else # FIXME: insert proper C++ library support ld_shlibs_CXX=no fi ;; esac ;; hpux10*|hpux11*) if test no = "$with_gnu_ld"; then hardcode_libdir_flag_spec_CXX='$wl+b $wl$libdir' hardcode_libdir_separator_CXX=: case $host_cpu in hppa*64*|ia64*) ;; *) export_dynamic_flag_spec_CXX='$wl-E' ;; esac fi case $host_cpu in hppa*64*|ia64*) hardcode_direct_CXX=no hardcode_shlibpath_var_CXX=no ;; *) hardcode_direct_CXX=yes hardcode_direct_absolute_CXX=yes hardcode_minus_L_CXX=yes # Not in the search PATH, # but as the default # location of the library. ;; esac case $cc_basename in CC*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; aCC*) case $host_cpu in hppa*64*) archive_cmds_CXX='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) archive_cmds_CXX='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) archive_cmds_CXX='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes = "$GXX"; then if test no = "$with_gnu_ld"; then case $host_cpu in hppa*64*) archive_cmds_CXX='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) archive_cmds_CXX='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) archive_cmds_CXX='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac fi else # FIXME: insert proper C++ library support ld_shlibs_CXX=no fi ;; esac ;; interix[3-9]*) hardcode_direct_CXX=no hardcode_shlibpath_var_CXX=no hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' export_dynamic_flag_spec_CXX='$wl-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' archive_expsym_cmds_CXX='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; irix5* | irix6*) case $cc_basename in CC*) # SGI C++ archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' # Archives containing C++ object files must be created using # "CC -ar", where "CC" is the IRIX C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs' ;; *) if test yes = "$GXX"; then if test no = "$with_gnu_ld"; then archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' else archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib' fi fi link_all_deplibs_CXX=yes ;; esac hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' hardcode_libdir_separator_CXX=: inherit_rpath_CXX=yes ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib $wl-retain-symbols-file,$export_symbols; mv \$templib $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' export_dynamic_flag_spec_CXX='$wl--export-dynamic' # Archives containing C++ object files must be created using # "CC -Bstatic", where "CC" is the KAI C++ compiler. old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;; icpc* | ecpc* ) # Intel C++ with_gnu_ld=yes # version 8.0 and above of icpc choke on multiply defined symbols # if we add $predep_objects and $postdep_objects, however 7.1 and # earlier do not add the objects themselves. case `$CC -V 2>&1` in *"Version 7."*) archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 8.0 or newer tmp_idyn= case $host_cpu in ia64*) tmp_idyn=' -i_dynamic';; esac archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; esac archive_cmds_need_lc_CXX=no hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' export_dynamic_flag_spec_CXX='$wl--export-dynamic' whole_archive_flag_spec_CXX='$wl--whole-archive$convenience $wl--no-whole-archive' ;; pgCC* | pgcpp*) # Portland Group C++ compiler case `$CC -V` in *pgCC\ [1-5].* | *pgcpp\ [1-5].*) prelink_cmds_CXX='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' old_archive_cmds_CXX='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ $RANLIB $oldlib' archive_cmds_CXX='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 6 and above use weak symbols archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; esac hardcode_libdir_flag_spec_CXX='$wl--rpath $wl$libdir' export_dynamic_flag_spec_CXX='$wl--export-dynamic' whole_archive_flag_spec_CXX='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' ;; cxx*) # Compaq C++ archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib $wl-retain-symbols-file $wl$export_symbols' runpath_var=LD_RUN_PATH hardcode_libdir_flag_spec_CXX='-rpath $libdir' hardcode_libdir_separator_CXX=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' ;; xl* | mpixl* | bgxl*) # IBM XL 8.0 on PPC, with GNU ld hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' export_dynamic_flag_spec_CXX='$wl--export-dynamic' archive_cmds_CXX='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' if test yes = "$supports_anon_versioning"; then archive_expsym_cmds_CXX='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C++ 5.9 no_undefined_flag_CXX=' -zdefs' archive_cmds_CXX='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' archive_expsym_cmds_CXX='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file $wl$export_symbols' hardcode_libdir_flag_spec_CXX='-R$libdir' whole_archive_flag_spec_CXX='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' compiler_needs_object_CXX=yes # Not sure whether something based on # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 # would be better. output_verbose_link_cmd='func_echo_all' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' ;; esac ;; esac ;; lynxos*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; m88k*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; mvs*) case $cc_basename in cxx*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then archive_cmds_CXX='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' wlarc= hardcode_libdir_flag_spec_CXX='-R$libdir' hardcode_direct_CXX=yes hardcode_shlibpath_var_CXX=no fi # Workaround some broken pre-1.5 toolchains output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' ;; *nto* | *qnx*) ld_shlibs_CXX=yes ;; openbsd* | bitrig*) if test -f /usr/libexec/ld.so; then hardcode_direct_CXX=yes hardcode_shlibpath_var_CXX=no hardcode_direct_absolute_CXX=yes archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file,$export_symbols -o $lib' export_dynamic_flag_spec_CXX='$wl-E' whole_archive_flag_spec_CXX=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' fi output_verbose_link_cmd=func_echo_all else ld_shlibs_CXX=no fi ;; osf3* | osf4* | osf5*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' hardcode_libdir_flag_spec_CXX='$wl-rpath,$libdir' hardcode_libdir_separator_CXX=: # Archives containing C++ object files must be created using # the KAI C++ compiler. case $host in osf3*) old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;; *) old_archive_cmds_CXX='$CC -o $oldlib $oldobjs' ;; esac ;; RCC*) # Rational C++ 2.4.1 # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; cxx*) case $host in osf3*) allow_undefined_flag_CXX=' $wl-expect_unresolved $wl\*' archive_cmds_CXX='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' ;; *) allow_undefined_flag_CXX=' -expect_unresolved \*' archive_cmds_CXX='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ echo "-hidden">> $lib.exp~ $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~ $RM $lib.exp' hardcode_libdir_flag_spec_CXX='-rpath $libdir' ;; esac hardcode_libdir_separator_CXX=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes,no = "$GXX,$with_gnu_ld"; then allow_undefined_flag_CXX=' $wl-expect_unresolved $wl\*' case $host in osf3*) archive_cmds_CXX='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' ;; *) archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' ;; esac hardcode_libdir_flag_spec_CXX='$wl-rpath $wl$libdir' hardcode_libdir_separator_CXX=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' else # FIXME: insert proper C++ library support ld_shlibs_CXX=no fi ;; esac ;; psos*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; sunos4*) case $cc_basename in CC*) # Sun C++ 4.x # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; lcc*) # Lucid # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; solaris*) case $cc_basename in CC* | sunCC*) # Sun C++ 4.2, 5.x and Centerline C++ archive_cmds_need_lc_CXX=yes no_undefined_flag_CXX=' -zdefs' archive_cmds_CXX='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G$allow_undefined_flag $wl-M $wl$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' hardcode_libdir_flag_spec_CXX='-R$libdir' hardcode_shlibpath_var_CXX=no case $host_os in solaris2.[0-5] | solaris2.[0-5].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands '-z linker_flag'. # Supported since Solaris 2.6 (maybe 2.5.1?) whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract' ;; esac link_all_deplibs_CXX=yes output_verbose_link_cmd='func_echo_all' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' ;; gcx*) # Green Hills C++ Compiler archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' # The C++ compiler must be used to create the archive. old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs' ;; *) # GNU C++ compiler with Solaris linker if test yes,no = "$GXX,$with_gnu_ld"; then no_undefined_flag_CXX=' $wl-z ${wl}defs' if $CC --version | $GREP -v '^2\.7' > /dev/null; then archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' else # g++ 2.7 appears to require '-G' NOT '-shared' on this # platform. archive_cmds_CXX='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' fi hardcode_libdir_flag_spec_CXX='$wl-R $wl$libdir' case $host_os in solaris2.[0-5] | solaris2.[0-5].*) ;; *) whole_archive_flag_spec_CXX='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' ;; esac fi ;; esac ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) no_undefined_flag_CXX='$wl-z,text' archive_cmds_need_lc_CXX=no hardcode_shlibpath_var_CXX=no runpath_var='LD_RUN_PATH' case $cc_basename in CC*) archive_cmds_CXX='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_CXX='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds_CXX='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_CXX='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We CANNOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. no_undefined_flag_CXX='$wl-z,text' allow_undefined_flag_CXX='$wl-z,nodefs' archive_cmds_need_lc_CXX=no hardcode_shlibpath_var_CXX=no hardcode_libdir_flag_spec_CXX='$wl-R,$libdir' hardcode_libdir_separator_CXX=':' link_all_deplibs_CXX=yes export_dynamic_flag_spec_CXX='$wl-Bexport' runpath_var='LD_RUN_PATH' case $cc_basename in CC*) archive_cmds_CXX='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_CXX='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' old_archive_cmds_CXX='$CC -Tprelink_objects $oldobjs~ '"$old_archive_cmds_CXX" reload_cmds_CXX='$CC -Tprelink_objects $reload_objs~ '"$reload_cmds_CXX" ;; *) archive_cmds_CXX='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_CXX='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; vxworks*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 $as_echo "$ld_shlibs_CXX" >&6; } test no = "$ld_shlibs_CXX" && can_build_shared=no GCC_CXX=$GXX LD_CXX=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... # Dependencies to place before and after the object being linked: predep_objects_CXX= postdep_objects_CXX= predeps_CXX= postdeps_CXX= compiler_lib_search_path_CXX= cat > conftest.$ac_ext <<_LT_EOF class Foo { public: Foo (void) { a = 0; } private: int a; }; _LT_EOF _lt_libdeps_save_CFLAGS=$CFLAGS case "$CC $CFLAGS " in #( *\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; *\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; *\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; esac if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then # Parse the compiler output and extract the necessary # objects, libraries and library flags. # Sentinel used to keep track of whether or not we are before # the conftest object file. pre_test_object_deps_done=no for p in `eval "$output_verbose_link_cmd"`; do case $prev$p in -L* | -R* | -l*) # Some compilers place space between "-{L,R}" and the path. # Remove the space. if test x-L = "$p" || test x-R = "$p"; then prev=$p continue fi # Expand the sysroot to ease extracting the directories later. if test -z "$prev"; then case $p in -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; esac fi case $p in =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; esac if test no = "$pre_test_object_deps_done"; then case $prev in -L | -R) # Internal compiler library paths should come after those # provided the user. The postdeps already come after the # user supplied libs so there is no need to process them. if test -z "$compiler_lib_search_path_CXX"; then compiler_lib_search_path_CXX=$prev$p else compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} $prev$p" fi ;; # The "-l" case would never come before the object being # linked, so don't bother handling this case. esac else if test -z "$postdeps_CXX"; then postdeps_CXX=$prev$p else postdeps_CXX="${postdeps_CXX} $prev$p" fi fi prev= ;; *.lto.$objext) ;; # Ignore GCC LTO objects *.$objext) # This assumes that the test object file only shows up # once in the compiler output. if test "$p" = "conftest.$objext"; then pre_test_object_deps_done=yes continue fi if test no = "$pre_test_object_deps_done"; then if test -z "$predep_objects_CXX"; then predep_objects_CXX=$p else predep_objects_CXX="$predep_objects_CXX $p" fi else if test -z "$postdep_objects_CXX"; then postdep_objects_CXX=$p else postdep_objects_CXX="$postdep_objects_CXX $p" fi fi ;; *) ;; # Ignore the rest. esac done # Clean up. rm -f a.out a.exe else echo "libtool.m4: error: problem compiling CXX test program" fi $RM -f confest.$objext CFLAGS=$_lt_libdeps_save_CFLAGS # PORTME: override above test on systems where it is broken case $host_os in interix[3-9]*) # Interix 3.5 installs completely hosed .la files for C++, so rather than # hack all around it, let's just trust "g++" to DTRT. predep_objects_CXX= postdep_objects_CXX= postdeps_CXX= ;; esac case " $postdeps_CXX " in *" -lc "*) archive_cmds_need_lc_CXX=no ;; esac compiler_lib_search_dirs_CXX= if test -n "${compiler_lib_search_path_CXX}"; then compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | $SED -e 's! -L! !g' -e 's!^ !!'` fi lt_prog_compiler_wl_CXX= lt_prog_compiler_pic_CXX= lt_prog_compiler_static_CXX= # C++ specific cases for pic, static, wl, etc. if test yes = "$GXX"; then lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_static_CXX='-static' case $host_os in aix*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor lt_prog_compiler_static_CXX='-Bstatic' fi lt_prog_compiler_pic_CXX='-fPIC' ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support lt_prog_compiler_pic_CXX='-fPIC' ;; m68k) # FIXME: we need at least 68020 code to build shared libraries, but # adding the '-m68020' flag to GCC prevents building anything better, # like '-m68040'. lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4' ;; esac ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | os2* | pw32* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries lt_prog_compiler_pic_CXX='-DDLL_EXPORT' case $host_os in os2*) lt_prog_compiler_static_CXX='$wl-static' ;; esac ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic_CXX='-fno-common' ;; *djgpp*) # DJGPP does not support shared libraries at all lt_prog_compiler_pic_CXX= ;; haiku*) # PIC is the default for Haiku. # The "-static" flag exists, but is broken. lt_prog_compiler_static_CXX= ;; interix[3-9]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic_CXX=-Kconform_pic fi ;; hpux*) # PIC is the default for 64-bit PA HP-UX, but not for 32-bit # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag # sets the default TLS model and affects inlining. case $host_cpu in hppa*64*) ;; *) lt_prog_compiler_pic_CXX='-fPIC' ;; esac ;; *qnx* | *nto*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. lt_prog_compiler_pic_CXX='-fPIC -shared' ;; *) lt_prog_compiler_pic_CXX='-fPIC' ;; esac else case $host_os in aix[4-9]*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor lt_prog_compiler_static_CXX='-Bstatic' else lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp' fi ;; chorus*) case $cc_basename in cxch68*) # Green Hills C++ Compiler # _LT_TAGVAR(lt_prog_compiler_static, CXX)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" ;; esac ;; mingw* | cygwin* | os2* | pw32* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). lt_prog_compiler_pic_CXX='-DDLL_EXPORT' ;; dgux*) case $cc_basename in ec++*) lt_prog_compiler_pic_CXX='-KPIC' ;; ghcx*) # Green Hills C++ Compiler lt_prog_compiler_pic_CXX='-pic' ;; *) ;; esac ;; freebsd* | dragonfly*) # FreeBSD uses GNU C++ ;; hpux9* | hpux10* | hpux11*) case $cc_basename in CC*) lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_static_CXX='$wl-a ${wl}archive' if test ia64 != "$host_cpu"; then lt_prog_compiler_pic_CXX='+Z' fi ;; aCC*) lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_static_CXX='$wl-a ${wl}archive' case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic_CXX='+Z' ;; esac ;; *) ;; esac ;; interix*) # This is c89, which is MS Visual C++ (no shared libs) # Anyone wants to do a port? ;; irix5* | irix6* | nonstopux*) case $cc_basename in CC*) lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_static_CXX='-non_shared' # CC pic flag -KPIC is the default. ;; *) ;; esac ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in KCC*) # KAI C++ Compiler lt_prog_compiler_wl_CXX='--backend -Wl,' lt_prog_compiler_pic_CXX='-fPIC' ;; ecpc* ) # old Intel C++ for x86_64, which still supported -KPIC. lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_pic_CXX='-KPIC' lt_prog_compiler_static_CXX='-static' ;; icpc* ) # Intel C++, used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_pic_CXX='-fPIC' lt_prog_compiler_static_CXX='-static' ;; pgCC* | pgcpp*) # Portland Group C++ compiler lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_pic_CXX='-fpic' lt_prog_compiler_static_CXX='-Bstatic' ;; cxx*) # Compaq C++ # Make sure the PIC flag is empty. It appears that all Alpha # Linux and Compaq Tru64 Unix objects are PIC. lt_prog_compiler_pic_CXX= lt_prog_compiler_static_CXX='-non_shared' ;; xlc* | xlC* | bgxl[cC]* | mpixl[cC]*) # IBM XL 8.0, 9.0 on PPC and BlueGene lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_pic_CXX='-qpic' lt_prog_compiler_static_CXX='-qstaticlink' ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C++ 5.9 lt_prog_compiler_pic_CXX='-KPIC' lt_prog_compiler_static_CXX='-Bstatic' lt_prog_compiler_wl_CXX='-Qoption ld ' ;; esac ;; esac ;; lynxos*) ;; m88k*) ;; mvs*) case $cc_basename in cxx*) lt_prog_compiler_pic_CXX='-W c,exportall' ;; *) ;; esac ;; netbsd*) ;; *qnx* | *nto*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. lt_prog_compiler_pic_CXX='-fPIC -shared' ;; osf3* | osf4* | osf5*) case $cc_basename in KCC*) lt_prog_compiler_wl_CXX='--backend -Wl,' ;; RCC*) # Rational C++ 2.4.1 lt_prog_compiler_pic_CXX='-pic' ;; cxx*) # Digital/Compaq C++ lt_prog_compiler_wl_CXX='-Wl,' # Make sure the PIC flag is empty. It appears that all Alpha # Linux and Compaq Tru64 Unix objects are PIC. lt_prog_compiler_pic_CXX= lt_prog_compiler_static_CXX='-non_shared' ;; *) ;; esac ;; psos*) ;; solaris*) case $cc_basename in CC* | sunCC*) # Sun C++ 4.2, 5.x and Centerline C++ lt_prog_compiler_pic_CXX='-KPIC' lt_prog_compiler_static_CXX='-Bstatic' lt_prog_compiler_wl_CXX='-Qoption ld ' ;; gcx*) # Green Hills C++ Compiler lt_prog_compiler_pic_CXX='-PIC' ;; *) ;; esac ;; sunos4*) case $cc_basename in CC*) # Sun C++ 4.x lt_prog_compiler_pic_CXX='-pic' lt_prog_compiler_static_CXX='-Bstatic' ;; lcc*) # Lucid lt_prog_compiler_pic_CXX='-pic' ;; *) ;; esac ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) case $cc_basename in CC*) lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_pic_CXX='-KPIC' lt_prog_compiler_static_CXX='-Bstatic' ;; esac ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 lt_prog_compiler_pic_CXX='-KPIC' ;; *) ;; esac ;; vxworks*) ;; *) lt_prog_compiler_can_build_shared_CXX=no ;; esac fi case $host_os in # For platforms that do not support PIC, -DPIC is meaningless: *djgpp*) lt_prog_compiler_pic_CXX= ;; *) lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC" ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 $as_echo_n "checking for $compiler option to produce PIC... " >&6; } if ${lt_cv_prog_compiler_pic_CXX+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_pic_CXX=$lt_prog_compiler_pic_CXX fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_CXX" >&5 $as_echo "$lt_cv_prog_compiler_pic_CXX" >&6; } lt_prog_compiler_pic_CXX=$lt_cv_prog_compiler_pic_CXX # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic_CXX"; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... " >&6; } if ${lt_cv_prog_compiler_pic_works_CXX+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_pic_works_CXX=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC" ## exclude from sc_useless_quotes_in_assignment # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_pic_works_CXX=yes fi fi $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works_CXX" >&5 $as_echo "$lt_cv_prog_compiler_pic_works_CXX" >&6; } if test yes = "$lt_cv_prog_compiler_pic_works_CXX"; then case $lt_prog_compiler_pic_CXX in "" | " "*) ;; *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;; esac else lt_prog_compiler_pic_CXX= lt_prog_compiler_can_build_shared_CXX=no fi fi # # Check to make sure the static flag actually works. # wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\" { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } if ${lt_cv_prog_compiler_static_works_CXX+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_static_works_CXX=no save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS $lt_tmp_static_flag" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&5 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_static_works_CXX=yes fi else lt_cv_prog_compiler_static_works_CXX=yes fi fi $RM -r conftest* LDFLAGS=$save_LDFLAGS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works_CXX" >&5 $as_echo "$lt_cv_prog_compiler_static_works_CXX" >&6; } if test yes = "$lt_cv_prog_compiler_static_works_CXX"; then : else lt_prog_compiler_static_CXX= fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } if ${lt_cv_prog_compiler_c_o_CXX+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_c_o_CXX=no $RM -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o_CXX=yes fi fi chmod u+w . 2>&5 $RM conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files $RM out/* && rmdir out cd .. $RM -r conftest $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 $as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } if ${lt_cv_prog_compiler_c_o_CXX+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_prog_compiler_c_o_CXX=no $RM -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o_CXX=yes fi fi chmod u+w . 2>&5 $RM conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files $RM out/* && rmdir out cd .. $RM -r conftest $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 $as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } hard_links=nottested if test no = "$lt_cv_prog_compiler_c_o_CXX" && test no != "$need_locks"; then # do not overwrite the value of need_locks provided by the user { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 $as_echo_n "checking if we can lock with hard links... " >&6; } hard_links=yes $RM conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 $as_echo "$hard_links" >&6; } if test no = "$hard_links"; then { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5 $as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;} need_locks=warn fi else need_locks=no fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' case $host_os in aix[4-9]*) # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to GNU nm, but means don't demangle to AIX nm. # Without the "-l" option, or with the "-B" option, AIX nm treats # weak defined symbols like other global defined symbols, whereas # GNU nm marks them as "W". # While the 'weak' keyword is ignored in the Export File, we need # it in the Import File for the 'aix-soname' feature, so we have # to replace the "-B" option with "-P" for AIX nm. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else export_symbols_cmds_CXX='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi ;; pw32*) export_symbols_cmds_CXX=$ltdll_cmds ;; cygwin* | mingw* | cegcc*) case $cc_basename in cl*) exclude_expsyms_CXX='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' ;; *) export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' exclude_expsyms_CXX='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname' ;; esac ;; *) export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 $as_echo "$ld_shlibs_CXX" >&6; } test no = "$ld_shlibs_CXX" && can_build_shared=no with_gnu_ld_CXX=$with_gnu_ld # # Do we need to explicitly link libc? # case "x$archive_cmds_need_lc_CXX" in x|xyes) # Assume -lc should be added archive_cmds_need_lc_CXX=yes if test yes,yes = "$GCC,$enable_shared"; then case $archive_cmds_CXX in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } if ${lt_cv_archive_cmds_need_lc_CXX+:} false; then : $as_echo_n "(cached) " >&6 else $RM conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 (eval $ac_compile) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$lt_prog_compiler_wl_CXX pic_flag=$lt_prog_compiler_pic_CXX compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$allow_undefined_flag_CXX allow_undefined_flag_CXX= if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 (eval $archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } then lt_cv_archive_cmds_need_lc_CXX=no else lt_cv_archive_cmds_need_lc_CXX=yes fi allow_undefined_flag_CXX=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $RM conftest* fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc_CXX" >&5 $as_echo "$lt_cv_archive_cmds_need_lc_CXX" >&6; } archive_cmds_need_lc_CXX=$lt_cv_archive_cmds_need_lc_CXX ;; esac fi ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 $as_echo_n "checking dynamic linker characteristics... " >&6; } library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=.so postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown case $host_os in aix3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='$libname$release$shared_ext$major' ;; aix[4-9]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no hardcode_into_libs=yes if test ia64 = "$host_cpu"; then # AIX 5 supports IA64 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line '#! .'. This would cause the generated library to # depend on '.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[01] | aix4.[01].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then : else can_build_shared=no fi ;; esac # Using Import Files as archive members, it is possible to support # filename-based versioning of shared library archives on AIX. While # this would work for both with and without runtime linking, it will # prevent static linking of such archives. So we do filename-based # shared library versioning with .so extension only, which is used # when both runtime linking and shared linking is enabled. # Unfortunately, runtime linking may impact performance, so we do # not want this to be the default eventually. Also, we use the # versioned .so libs for executables only if there is the -brtl # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. # To allow for filename-based versioning support, we need to create # libNAME.so.V as an archive file, containing: # *) an Import File, referring to the versioned filename of the # archive as well as the shared archive member, telling the # bitwidth (32 or 64) of that shared object, and providing the # list of exported symbols of that shared object, eventually # decorated with the 'weak' keyword # *) the shared object with the F_LOADONLY flag set, to really avoid # it being seen by the linker. # At run time we better use the real file rather than another symlink, # but for link time we create the symlink libNAME.so -> libNAME.so.V case $with_aix_soname,$aix_use_runtimelinking in # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. aix,yes) # traditional libtool dynamic_linker='AIX unversionable lib.so' # If using run time linking (on AIX 4.2 or later) use lib<name>.so # instead of lib<name>.a to let people know that these are not # typical AIX shared libraries. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; aix,no) # traditional AIX only dynamic_linker='AIX lib.a(lib.so.V)' # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' ;; svr4,*) # full svr4 only dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,yes) # both, prefer svr4 dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # unpreferred sharedlib libNAME.a needs extra handling postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,no) # both, prefer aix dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)" library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' ;; esac shlibpath_var=LIBPATH fi ;; amigaos*) case $host_cpu in powerpc) # Since July 2007 AmigaOS4 officially supports .so libraries. # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; m68k) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; esac ;; beos*) library_names_spec='$libname$shared_ext' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[45]*) version_type=linux # correct to gnu/linux during the next big refactor need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | mingw* | pw32* | cegcc*) version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no case $GCC,$cc_basename in yes,*) # gcc library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' ;; mingw* | cegcc*) # MinGW DLLs use traditional 'lib' prefix soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' ;; esac dynamic_linker='Win32 ld.exe' ;; *,cl*) # Native MSVC libname_spec='$name' soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext' library_names_spec='$libname.dll.lib' case $build_os in mingw*) sys_lib_search_path_spec= lt_save_ifs=$IFS IFS=';' for lt_path in $LIB do IFS=$lt_save_ifs # Let DOS variable expansion print the short 8.3 style file name. lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" done IFS=$lt_save_ifs # Convert to MSYS style. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'` ;; cygwin*) # Convert to unix form, then to dos form, then back to unix form # but this time dos style (no spaces!) so that the unix form looks # like /cygdrive/c/PROGRA~1:/cygdr... sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` ;; *) sys_lib_search_path_spec=$LIB if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then # It is most probably a Windows format PATH. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi # FIXME: find the short name or the path components, as spaces are # common. (e.g. "Program Files" -> "PROGRA~1") ;; esac # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes dynamic_linker='Win32 link.exe' ;; *) # Assume MSVC wrapper library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib' dynamic_linker='Win32 ld.exe' ;; esac # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' soname_spec='$libname$release$major$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd* | dragonfly*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[23].*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2.*) shlibpath_overrides_runpath=yes ;; freebsd3.[01]* | freebsdelf3.[01]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; haiku*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no dynamic_linker="$host_os runtime_loader" library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LIBRARY_PATH shlibpath_overrides_runpath=no sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' if test 32 = "$HPUX_IA64_MODE"; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" sys_lib_dlsearch_path_spec=/usr/lib/hpux32 else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" sys_lib_dlsearch_path_spec=/usr/lib/hpux64 fi ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555, ... postinstall_cmds='chmod 555 $lib' # or fails outright, so override atomically: install_override_mode=555 ;; interix[3-9]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test yes = "$lt_cv_prog_gnu_ld"; then version_type=linux # correct to gnu/linux during the next big refactor else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; linux*android*) version_type=none # Android doesn't support versioned libraries. need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext' soname_spec='$libname$release$shared_ext' finish_cmds= shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes dynamic_linker='Android linker' # Don't embed -rpath directories since the linker doesn't support them. hardcode_libdir_flag_spec_CXX='-L$libdir' ;; # This must be glibc/ELF. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # Some binutils ld are patched to set DT_RUNPATH if ${lt_cv_shlibpath_overrides_runpath+:} false; then : $as_echo_n "(cached) " >&6 else lt_cv_shlibpath_overrides_runpath=no save_LDFLAGS=$LDFLAGS save_libdir=$libdir eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_CXX\"; \ LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_CXX\"" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_cxx_try_link "$LINENO"; then : if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : lt_cv_shlibpath_overrides_runpath=yes fi fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LDFLAGS=$save_LDFLAGS libdir=$save_libdir fi shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Add ABI-specific directories to the system library path. sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" # Ideally, we could use ldconfig to report *all* directores which are # searched for libraries, however this is still not possible. Aside from not # being certain /sbin/ldconfig is available, command # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, # even though it is searched at run-time. Try to do the best guess by # appending ld.so.conf contents (and includes) to the search path. if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; *nto* | *qnx*) version_type=qnx need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='ldqnx.so' ;; openbsd* | bitrig*) version_type=sunos sys_lib_dlsearch_path_spec=/usr/lib need_lib_prefix=no if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then need_version=no else need_version=yes fi library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; os2*) libname_spec='$name' version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no # OS/2 can only load a DLL with a base name of 8 characters or less. soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; v=$($ECHO $release$versuffix | tr -d .-); n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); $ECHO $n$v`$shared_ext' library_names_spec='${libname}_dll.$libext' dynamic_linker='OS/2 ld.exe' shlibpath_var=BEGINLIBPATH sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test yes = "$with_gnu_ld"; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec; then version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' soname_spec='$libname$shared_ext.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=sco need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes if test yes = "$with_gnu_ld"; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; tpf*) # TPF is a cross-target only. Preferred cross-host = GNU/Linux. version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; uts4*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 $as_echo "$dynamic_linker" >&6; } test no = "$dynamic_linker" && can_build_shared=no variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test yes = "$GCC"; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec fi if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec fi # remember unaugmented sys_lib_dlsearch_path content for libtool script decls... configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 $as_echo_n "checking how to hardcode library paths into programs... " >&6; } hardcode_action_CXX= if test -n "$hardcode_libdir_flag_spec_CXX" || test -n "$runpath_var_CXX" || test yes = "$hardcode_automatic_CXX"; then # We can hardcode non-existent directories. if test no != "$hardcode_direct_CXX" && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, CXX)" && test no != "$hardcode_minus_L_CXX"; then # Linking always hardcodes the temporary library directory. hardcode_action_CXX=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. hardcode_action_CXX=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. hardcode_action_CXX=unsupported fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_CXX" >&5 $as_echo "$hardcode_action_CXX" >&6; } if test relink = "$hardcode_action_CXX" || test yes = "$inherit_rpath_CXX"; then # Fast installation is not supported enable_fast_install=no elif test yes = "$shlibpath_overrides_runpath" || test no = "$enable_shared"; then # Fast installation is not necessary enable_fast_install=needless fi fi # test -n "$compiler" CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS LDCXX=$LD LD=$lt_save_LD GCC=$lt_save_GCC with_gnu_ld=$lt_save_with_gnu_ld lt_cv_path_LDCXX=$lt_cv_path_LD lt_cv_path_LD=$lt_save_path_LD lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld fi # test yes != "$_lt_caught_CXX_error" ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu ac_config_commands="$ac_config_commands libtool" # Only expand once: ax_cxx_compile_alternatives="11 0x" ax_cxx_compile_cxx11_required=true ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu ac_success=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features by default" >&5 $as_echo_n "checking whether $CXX supports C++11 features by default... " >&6; } if ${ax_cv_cxx_compile_cxx11+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ // If the compiler admits that it is not ready for C++11, why torture it? // Hopefully, this will speed up the test. #ifndef __cplusplus #error "This is not a C++ compiler" #elif __cplusplus < 201103L && !(defined _MSC_VER) #error "This is not a C++11 compiler" #else namespace cxx11 { namespace test_static_assert { template <typename T> struct check { static_assert(sizeof(int) <= sizeof(T), "not big enough"); }; } namespace test_final_override { struct Base { virtual void f() {} }; struct Derived : public Base { virtual void f() override {} }; } namespace test_double_right_angle_brackets { template < typename T > struct check {}; typedef check<void> single_type; typedef check<check<void>> double_type; typedef check<check<check<void>>> triple_type; typedef check<check<check<check<void>>>> quadruple_type; } namespace test_decltype { int f() { int a = 1; decltype(a) b = 2; return a + b; } } namespace test_type_deduction { template < typename T1, typename T2 > struct is_same { static const bool value = false; }; template < typename T > struct is_same<T, T> { static const bool value = true; }; template < typename T1, typename T2 > auto add(T1 a1, T2 a2) -> decltype(a1 + a2) { return a1 + a2; } int test(const int c, volatile int v) { static_assert(is_same<int, decltype(0)>::value == true, ""); static_assert(is_same<int, decltype(c)>::value == false, ""); static_assert(is_same<int, decltype(v)>::value == false, ""); auto ac = c; auto av = v; auto sumi = ac + av + 'x'; auto sumf = ac + av + 1.0; static_assert(is_same<int, decltype(ac)>::value == true, ""); static_assert(is_same<int, decltype(av)>::value == true, ""); static_assert(is_same<int, decltype(sumi)>::value == true, ""); static_assert(is_same<int, decltype(sumf)>::value == false, ""); static_assert(is_same<int, decltype(add(c, v))>::value == true, ""); return (sumf > 0.0) ? sumi : add(c, v); } } namespace test_noexcept { int f() { return 0; } int g() noexcept { return 0; } static_assert(noexcept(f()) == false, ""); static_assert(noexcept(g()) == true, ""); } namespace test_constexpr { template < typename CharT > unsigned long constexpr strlen_c_r(const CharT *const s, const unsigned long acc) noexcept { return *s ? strlen_c_r(s + 1, acc + 1) : acc; } template < typename CharT > unsigned long constexpr strlen_c(const CharT *const s) noexcept { return strlen_c_r(s, 0UL); } static_assert(strlen_c("") == 0UL, ""); static_assert(strlen_c("1") == 1UL, ""); static_assert(strlen_c("example") == 7UL, ""); static_assert(strlen_c("another\0example") == 7UL, ""); } namespace test_rvalue_references { template < int N > struct answer { static constexpr int value = N; }; answer<1> f(int&) { return answer<1>(); } answer<2> f(const int&) { return answer<2>(); } answer<3> f(int&&) { return answer<3>(); } void test() { int i = 0; const int c = 0; static_assert(decltype(f(i))::value == 1, ""); static_assert(decltype(f(c))::value == 2, ""); static_assert(decltype(f(0))::value == 3, ""); } } namespace test_uniform_initialization { struct test { static const int zero {}; static const int one {1}; }; static_assert(test::zero == 0, ""); static_assert(test::one == 1, ""); } namespace test_lambdas { void test1() { auto lambda1 = [](){}; auto lambda2 = lambda1; lambda1(); lambda2(); } int test2() { auto a = [](int i, int j){ return i + j; }(1, 2); auto b = []() -> int { return '0'; }(); auto c = [=](){ return a + b; }(); auto d = [&](){ return c; }(); auto e = [a, &b](int x) mutable { const auto identity = [](int y){ return y; }; for (auto i = 0; i < a; ++i) a += b--; return x + identity(a + b); }(0); return a + b + c + d + e; } int test3() { const auto nullary = [](){ return 0; }; const auto unary = [](int x){ return x; }; using nullary_t = decltype(nullary); using unary_t = decltype(unary); const auto higher1st = [](nullary_t f){ return f(); }; const auto higher2nd = [unary](nullary_t f1){ return [unary, f1](unary_t f2){ return f2(unary(f1())); }; }; return higher1st(nullary) + higher2nd(nullary)(unary); } } namespace test_variadic_templates { template <int...> struct sum; template <int N0, int... N1toN> struct sum<N0, N1toN...> { static constexpr auto value = N0 + sum<N1toN...>::value; }; template <> struct sum<> { static constexpr auto value = 0; }; static_assert(sum<>::value == 0, ""); static_assert(sum<1>::value == 1, ""); static_assert(sum<23>::value == 23, ""); static_assert(sum<1, 2>::value == 3, ""); static_assert(sum<5, 5, 11>::value == 21, ""); static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, ""); } // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function // because of this. namespace test_template_alias_sfinae { struct foo {}; template<typename T> using member = typename T::member_type; template<typename T> void func(...) {} template<typename T> void func(member<T>*) {} void test(); void test() { func<foo>(0); } } } // namespace cxx11 #endif // __cplusplus >= 201103L _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : ax_cv_cxx_compile_cxx11=yes else ax_cv_cxx_compile_cxx11=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cxx_compile_cxx11" >&5 $as_echo "$ax_cv_cxx_compile_cxx11" >&6; } if test x$ax_cv_cxx_compile_cxx11 = xyes; then ac_success=yes fi if test x$ac_success = xno; then for alternative in ${ax_cxx_compile_alternatives}; do switch="-std=gnu++${alternative}" cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh` { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5 $as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; } if eval \${$cachevar+:} false; then : $as_echo_n "(cached) " >&6 else ac_save_CXX="$CXX" CXX="$CXX $switch" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ // If the compiler admits that it is not ready for C++11, why torture it? // Hopefully, this will speed up the test. #ifndef __cplusplus #error "This is not a C++ compiler" #elif __cplusplus < 201103L && !(defined _MSC_VER) #error "This is not a C++11 compiler" #else namespace cxx11 { namespace test_static_assert { template <typename T> struct check { static_assert(sizeof(int) <= sizeof(T), "not big enough"); }; } namespace test_final_override { struct Base { virtual void f() {} }; struct Derived : public Base { virtual void f() override {} }; } namespace test_double_right_angle_brackets { template < typename T > struct check {}; typedef check<void> single_type; typedef check<check<void>> double_type; typedef check<check<check<void>>> triple_type; typedef check<check<check<check<void>>>> quadruple_type; } namespace test_decltype { int f() { int a = 1; decltype(a) b = 2; return a + b; } } namespace test_type_deduction { template < typename T1, typename T2 > struct is_same { static const bool value = false; }; template < typename T > struct is_same<T, T> { static const bool value = true; }; template < typename T1, typename T2 > auto add(T1 a1, T2 a2) -> decltype(a1 + a2) { return a1 + a2; } int test(const int c, volatile int v) { static_assert(is_same<int, decltype(0)>::value == true, ""); static_assert(is_same<int, decltype(c)>::value == false, ""); static_assert(is_same<int, decltype(v)>::value == false, ""); auto ac = c; auto av = v; auto sumi = ac + av + 'x'; auto sumf = ac + av + 1.0; static_assert(is_same<int, decltype(ac)>::value == true, ""); static_assert(is_same<int, decltype(av)>::value == true, ""); static_assert(is_same<int, decltype(sumi)>::value == true, ""); static_assert(is_same<int, decltype(sumf)>::value == false, ""); static_assert(is_same<int, decltype(add(c, v))>::value == true, ""); return (sumf > 0.0) ? sumi : add(c, v); } } namespace test_noexcept { int f() { return 0; } int g() noexcept { return 0; } static_assert(noexcept(f()) == false, ""); static_assert(noexcept(g()) == true, ""); } namespace test_constexpr { template < typename CharT > unsigned long constexpr strlen_c_r(const CharT *const s, const unsigned long acc) noexcept { return *s ? strlen_c_r(s + 1, acc + 1) : acc; } template < typename CharT > unsigned long constexpr strlen_c(const CharT *const s) noexcept { return strlen_c_r(s, 0UL); } static_assert(strlen_c("") == 0UL, ""); static_assert(strlen_c("1") == 1UL, ""); static_assert(strlen_c("example") == 7UL, ""); static_assert(strlen_c("another\0example") == 7UL, ""); } namespace test_rvalue_references { template < int N > struct answer { static constexpr int value = N; }; answer<1> f(int&) { return answer<1>(); } answer<2> f(const int&) { return answer<2>(); } answer<3> f(int&&) { return answer<3>(); } void test() { int i = 0; const int c = 0; static_assert(decltype(f(i))::value == 1, ""); static_assert(decltype(f(c))::value == 2, ""); static_assert(decltype(f(0))::value == 3, ""); } } namespace test_uniform_initialization { struct test { static const int zero {}; static const int one {1}; }; static_assert(test::zero == 0, ""); static_assert(test::one == 1, ""); } namespace test_lambdas { void test1() { auto lambda1 = [](){}; auto lambda2 = lambda1; lambda1(); lambda2(); } int test2() { auto a = [](int i, int j){ return i + j; }(1, 2); auto b = []() -> int { return '0'; }(); auto c = [=](){ return a + b; }(); auto d = [&](){ return c; }(); auto e = [a, &b](int x) mutable { const auto identity = [](int y){ return y; }; for (auto i = 0; i < a; ++i) a += b--; return x + identity(a + b); }(0); return a + b + c + d + e; } int test3() { const auto nullary = [](){ return 0; }; const auto unary = [](int x){ return x; }; using nullary_t = decltype(nullary); using unary_t = decltype(unary); const auto higher1st = [](nullary_t f){ return f(); }; const auto higher2nd = [unary](nullary_t f1){ return [unary, f1](unary_t f2){ return f2(unary(f1())); }; }; return higher1st(nullary) + higher2nd(nullary)(unary); } } namespace test_variadic_templates { template <int...> struct sum; template <int N0, int... N1toN> struct sum<N0, N1toN...> { static constexpr auto value = N0 + sum<N1toN...>::value; }; template <> struct sum<> { static constexpr auto value = 0; }; static_assert(sum<>::value == 0, ""); static_assert(sum<1>::value == 1, ""); static_assert(sum<23>::value == 23, ""); static_assert(sum<1, 2>::value == 3, ""); static_assert(sum<5, 5, 11>::value == 21, ""); static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, ""); } // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function // because of this. namespace test_template_alias_sfinae { struct foo {}; template<typename T> using member = typename T::member_type; template<typename T> void func(...) {} template<typename T> void func(member<T>*) {} void test(); void test() { func<foo>(0); } } } // namespace cxx11 #endif // __cplusplus >= 201103L _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : eval $cachevar=yes else eval $cachevar=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext CXX="$ac_save_CXX" fi eval ac_res=\$$cachevar { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } if eval test x\$$cachevar = xyes; then CXX="$CXX $switch" if test -n "$CXXCPP" ; then CXXCPP="$CXXCPP $switch" fi ac_success=yes break fi done fi if test x$ac_success = xno; then for alternative in ${ax_cxx_compile_alternatives}; do for switch in -std=c++${alternative} +std=c++${alternative} "-h std=c++${alternative}"; do cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh` { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5 $as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; } if eval \${$cachevar+:} false; then : $as_echo_n "(cached) " >&6 else ac_save_CXX="$CXX" CXX="$CXX $switch" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ // If the compiler admits that it is not ready for C++11, why torture it? // Hopefully, this will speed up the test. #ifndef __cplusplus #error "This is not a C++ compiler" #elif __cplusplus < 201103L && !(defined _MSC_VER) #error "This is not a C++11 compiler" #else namespace cxx11 { namespace test_static_assert { template <typename T> struct check { static_assert(sizeof(int) <= sizeof(T), "not big enough"); }; } namespace test_final_override { struct Base { virtual void f() {} }; struct Derived : public Base { virtual void f() override {} }; } namespace test_double_right_angle_brackets { template < typename T > struct check {}; typedef check<void> single_type; typedef check<check<void>> double_type; typedef check<check<check<void>>> triple_type; typedef check<check<check<check<void>>>> quadruple_type; } namespace test_decltype { int f() { int a = 1; decltype(a) b = 2; return a + b; } } namespace test_type_deduction { template < typename T1, typename T2 > struct is_same { static const bool value = false; }; template < typename T > struct is_same<T, T> { static const bool value = true; }; template < typename T1, typename T2 > auto add(T1 a1, T2 a2) -> decltype(a1 + a2) { return a1 + a2; } int test(const int c, volatile int v) { static_assert(is_same<int, decltype(0)>::value == true, ""); static_assert(is_same<int, decltype(c)>::value == false, ""); static_assert(is_same<int, decltype(v)>::value == false, ""); auto ac = c; auto av = v; auto sumi = ac + av + 'x'; auto sumf = ac + av + 1.0; static_assert(is_same<int, decltype(ac)>::value == true, ""); static_assert(is_same<int, decltype(av)>::value == true, ""); static_assert(is_same<int, decltype(sumi)>::value == true, ""); static_assert(is_same<int, decltype(sumf)>::value == false, ""); static_assert(is_same<int, decltype(add(c, v))>::value == true, ""); return (sumf > 0.0) ? sumi : add(c, v); } } namespace test_noexcept { int f() { return 0; } int g() noexcept { return 0; } static_assert(noexcept(f()) == false, ""); static_assert(noexcept(g()) == true, ""); } namespace test_constexpr { template < typename CharT > unsigned long constexpr strlen_c_r(const CharT *const s, const unsigned long acc) noexcept { return *s ? strlen_c_r(s + 1, acc + 1) : acc; } template < typename CharT > unsigned long constexpr strlen_c(const CharT *const s) noexcept { return strlen_c_r(s, 0UL); } static_assert(strlen_c("") == 0UL, ""); static_assert(strlen_c("1") == 1UL, ""); static_assert(strlen_c("example") == 7UL, ""); static_assert(strlen_c("another\0example") == 7UL, ""); } namespace test_rvalue_references { template < int N > struct answer { static constexpr int value = N; }; answer<1> f(int&) { return answer<1>(); } answer<2> f(const int&) { return answer<2>(); } answer<3> f(int&&) { return answer<3>(); } void test() { int i = 0; const int c = 0; static_assert(decltype(f(i))::value == 1, ""); static_assert(decltype(f(c))::value == 2, ""); static_assert(decltype(f(0))::value == 3, ""); } } namespace test_uniform_initialization { struct test { static const int zero {}; static const int one {1}; }; static_assert(test::zero == 0, ""); static_assert(test::one == 1, ""); } namespace test_lambdas { void test1() { auto lambda1 = [](){}; auto lambda2 = lambda1; lambda1(); lambda2(); } int test2() { auto a = [](int i, int j){ return i + j; }(1, 2); auto b = []() -> int { return '0'; }(); auto c = [=](){ return a + b; }(); auto d = [&](){ return c; }(); auto e = [a, &b](int x) mutable { const auto identity = [](int y){ return y; }; for (auto i = 0; i < a; ++i) a += b--; return x + identity(a + b); }(0); return a + b + c + d + e; } int test3() { const auto nullary = [](){ return 0; }; const auto unary = [](int x){ return x; }; using nullary_t = decltype(nullary); using unary_t = decltype(unary); const auto higher1st = [](nullary_t f){ return f(); }; const auto higher2nd = [unary](nullary_t f1){ return [unary, f1](unary_t f2){ return f2(unary(f1())); }; }; return higher1st(nullary) + higher2nd(nullary)(unary); } } namespace test_variadic_templates { template <int...> struct sum; template <int N0, int... N1toN> struct sum<N0, N1toN...> { static constexpr auto value = N0 + sum<N1toN...>::value; }; template <> struct sum<> { static constexpr auto value = 0; }; static_assert(sum<>::value == 0, ""); static_assert(sum<1>::value == 1, ""); static_assert(sum<23>::value == 23, ""); static_assert(sum<1, 2>::value == 3, ""); static_assert(sum<5, 5, 11>::value == 21, ""); static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, ""); } // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function // because of this. namespace test_template_alias_sfinae { struct foo {}; template<typename T> using member = typename T::member_type; template<typename T> void func(...) {} template<typename T> void func(member<T>*) {} void test(); void test() { func<foo>(0); } } } // namespace cxx11 #endif // __cplusplus >= 201103L _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : eval $cachevar=yes else eval $cachevar=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext CXX="$ac_save_CXX" fi eval ac_res=\$$cachevar { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } if eval test x\$$cachevar = xyes; then CXX="$CXX $switch" if test -n "$CXXCPP" ; then CXXCPP="$CXXCPP $switch" fi ac_success=yes break fi done if test x$ac_success = xyes; then break fi done fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu if test x$ax_cxx_compile_cxx11_required = xtrue; then if test x$ac_success = xno; then as_fn_error $? "*** A compiler with support for C++11 language features is required." "$LINENO" 5 fi fi if test x$ac_success = xno; then HAVE_CXX11=0 { $as_echo "$as_me:${as_lineno-$LINENO}: No compiler with C++11 support was found" >&5 $as_echo "$as_me: No compiler with C++11 support was found" >&6;} else HAVE_CXX11=1 $as_echo "#define HAVE_CXX11 1" >>confdefs.h fi # Check the options # Check whether --enable-client was given. if test "${enable_client+set}" = set; then : enableval=$enable_client; enable_client=$enableval else enable_client=yes fi if test "x$enable_client" != "xno"; then ENABLE_CLIENT_TRUE= ENABLE_CLIENT_FALSE='#' else ENABLE_CLIENT_TRUE='#' ENABLE_CLIENT_FALSE= fi # Check whether --enable-tests was given. if test "${enable_tests+set}" = set; then : enableval=$enable_tests; enable_tests="$enableval" else enable_tests=yes fi if test "x$enable_tests" != "xno"; then ENABLE_TESTS_TRUE= ENABLE_TESTS_FALSE='#' else ENABLE_TESTS_TRUE='#' ENABLE_TESTS_FALSE= fi # Check whether --enable-coverage was given. if test "${enable_coverage+set}" = set; then : enableval=$enable_coverage; enable_coverage="$enableval" else enable_coverage=no fi if test "x$enable_coverage" != "xno"; then ENABLE_COVERAGE_TRUE= ENABLE_COVERAGE_FALSE='#' else ENABLE_COVERAGE_TRUE='#' ENABLE_COVERAGE_FALSE= fi if test "x$enable_coverage" != "xno"; then : enable_tests=yes # Make sure we have gcc if test "x$GCC" != "xyes"; then as_fn_error $? "GCC is required for --enable-coverage" "$LINENO" 5 fi # Extract the first word of "lcov", so it can be a program name with args. set dummy lcov; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_LCOV+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$LCOV"; then ac_cv_prog_LCOV="$LCOV" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_LCOV="lcov" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi LCOV=$ac_cv_prog_LCOV if test -n "$LCOV"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LCOV" >&5 $as_echo "$LCOV" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi # Extract the first word of "genhtml", so it can be a program name with args. set dummy genhtml; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_prog_GENHTML+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$GENHTML"; then ac_cv_prog_GENHTML="$GENHTML" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_prog_GENHTML="genhtml" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi GENHTML=$ac_cv_prog_GENHTML if test -n "$GENHTML"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GENHTML" >&5 $as_echo "$GENHTML" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_cv_prog_LCOV" = "x"; then : as_fn_error $? "lcov is required for --enable-coverage" "$LINENO" 5 fi if test "x$ac_cv_prog_GENHTML" = "x"; then : as_fn_error $? "genhtml is required for --enable-coverage" "$LINENO" 5 fi CFLAGS="-g -O0 --coverage" CXXFLAGS="-g -O0 --coverage" LDFLAGS+="--coverage" fi LIBCMIS_API_VERSION=0.5 for top_builddir in . .. ../.. $ac_auxdir $ac_auxdir/..; do test -f $top_builddir/configure && break done SRCDIR=$srcdir ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu # ========================== # Platform check for windows # ========================== { $as_echo "$as_me:${as_lineno-$LINENO}: checking for native Win32" >&5 $as_echo_n "checking for native Win32... " >&6; } case $host in #( *-*-mingw*) : native_win32=yes ;; #( *) : native_win32=no ;; esac { $as_echo "$as_me:${as_lineno-$LINENO}: result: $native_win32" >&5 $as_echo "$native_win32" >&6; } if test "x$native_win32" = "xyes"; then OS_WIN32_TRUE= OS_WIN32_FALSE='#' else OS_WIN32_TRUE='#' OS_WIN32_FALSE= fi # ==================== # Check for visibility # ==================== { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -fvisibility=hidden compiler flag" >&5 $as_echo_n "checking for -fvisibility=hidden compiler flag... " >&6; } saved_CPPFLAGS="$CPPFLAGS" CPPFLAGS="$CPPFLAGS -fvisibility=hidden" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : have_visibility=yes else have_visibility=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_visibility" >&5 $as_echo "$have_visibility" >&6; } CPPFLAGS="$saved_CPPFLAGS" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __attribute__((visibility))" >&5 $as_echo_n "checking for __attribute__((visibility))... " >&6; } if ${ax_cv_have_func_attribute_visibility+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int foo_def( void ) __attribute__((visibility("default"))); int foo_hid( void ) __attribute__((visibility("hidden"))); int foo_int( void ) __attribute__((visibility("internal"))); int foo_pro( void ) __attribute__((visibility("protected"))); int main () { ; return 0; } _ACEOF if ac_fn_cxx_try_link "$LINENO"; then : if test -s conftest.err; then : ax_cv_have_func_attribute_visibility=no else ax_cv_have_func_attribute_visibility=yes fi else ax_cv_have_func_attribute_visibility=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_have_func_attribute_visibility" >&5 $as_echo "$ax_cv_have_func_attribute_visibility" >&6; } if test yes = $ax_cv_have_func_attribute_visibility; then : cat >>confdefs.h <<_ACEOF #define HAVE_FUNC_ATTRIBUTE_VISIBILITY 1 _ACEOF fi if test "x$have_visibility" = "xyes" && test "x$ax_cv_have_func_attribute_visibility" = "xyes"; then ENABLE_VISIBILITY_TRUE= ENABLE_VISIBILITY_FALSE='#' else ENABLE_VISIBILITY_TRUE='#' ENABLE_VISIBILITY_FALSE= fi # ============= # Documentation # ============= # Check whether --with-man was given. if test "${with_man+set}" = set; then : withval=$with_man; with_man="$withval" else with_man=yes fi if test "x$with_man" != "xno"; then : build_man=yes if test -z "$DOCBOOK2MAN"; then : for ac_prog in docbook2x-man docbook-to-man docbook2man.pl do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_DOCBOOK2MAN+:} false; then : $as_echo_n "(cached) " >&6 else case $DOCBOOK2MAN in [\\/]* | ?:[\\/]*) ac_cv_path_DOCBOOK2MAN="$DOCBOOK2MAN" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_path_DOCBOOK2MAN="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS ;; esac fi DOCBOOK2MAN=$ac_cv_path_DOCBOOK2MAN if test -n "$DOCBOOK2MAN"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DOCBOOK2MAN" >&5 $as_echo "$DOCBOOK2MAN" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$DOCBOOK2MAN" && break done if test -z "$DOCBOOK2MAN"; then : as_fn_error $? "docbook-to-man is missing. Install docbook2X package." "$LINENO" 5 fi fi else build_man=no fi if test "x$build_man" != "xno"; then ENABLE_MAN_TRUE= ENABLE_MAN_FALSE='#' else ENABLE_MAN_TRUE='#' ENABLE_MAN_FALSE= fi # ======== # Cppcheck # ======== # Extract the first word of "cppcheck", so it can be a program name with args. set dummy cppcheck; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_CPPCHECK+:} false; then : $as_echo_n "(cached) " >&6 else case $CPPCHECK in [\\/]* | ?:[\\/]*) ac_cv_path_CPPCHECK="$CPPCHECK" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_path_CPPCHECK="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS ;; esac fi CPPCHECK=$ac_cv_path_CPPCHECK if test -n "$CPPCHECK"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPPCHECK" >&5 $as_echo "$CPPCHECK" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_cv_path_CPPCHECK" != "x"; then : enable_cppcheck=yes else enable_cppcheck=no fi # Extract the first word of "nproc", so it can be a program name with args. set dummy nproc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_NPROC+:} false; then : $as_echo_n "(cached) " >&6 else case $NPROC in [\\/]* | ?:[\\/]*) ac_cv_path_NPROC="$NPROC" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_path_NPROC="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS ;; esac fi NPROC=$ac_cv_path_NPROC if test -n "$NPROC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NPROC" >&5 $as_echo "$NPROC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$NPROC" != "x"; then : CPPCHECK_PARALLELISM=`$NPROC` else CPPCHECK_PARALLELISM=1 fi # Check whether --enable-werror was given. if test "${enable_werror+set}" = set; then : enableval=$enable_werror; enable_werror="$enableval" else enable_werror=yes fi if test x"$enable_werror" != "xno"; then : CFLAGS="$CFLAGS -Werror" CXXFLAGS="$CXXFLAGS -Werror" fi if test x"$GCC" = xyes; then : # Be tough with warnings and produce less careless code CFLAGS="$CFLAGS -Wall -pedantic -Wshadow -Wendif-labels -Wextra" CXXFLAGS="$CXXFLAGS -Wall -pedantic -Weffc++ -Wshadow -Wendif-labels -Wextra -Wsign-promo -Woverloaded-virtual -Wnon-virtual-dtor -Wsign-promo" fi # Check for curl if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_PKG_CONFIG+:} false; then : $as_echo_n "(cached) " >&6 else case $PKG_CONFIG in [\\/]* | ?:[\\/]*) ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS ;; esac fi PKG_CONFIG=$ac_cv_path_PKG_CONFIG if test -n "$PKG_CONFIG"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 $as_echo "$PKG_CONFIG" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_path_PKG_CONFIG"; then ac_pt_PKG_CONFIG=$PKG_CONFIG # Extract the first word of "pkg-config", so it can be a program name with args. set dummy pkg-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : $as_echo_n "(cached) " >&6 else case $ac_pt_PKG_CONFIG in [\\/]* | ?:[\\/]*) ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS ;; esac fi ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG if test -n "$ac_pt_PKG_CONFIG"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 $as_echo "$ac_pt_PKG_CONFIG" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_pt_PKG_CONFIG" = x; then PKG_CONFIG="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac PKG_CONFIG=$ac_pt_PKG_CONFIG fi else PKG_CONFIG="$ac_cv_path_PKG_CONFIG" fi fi if test -n "$PKG_CONFIG"; then _pkg_min_version=0.9.0 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } PKG_CONFIG="" fi fi pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CURL" >&5 $as_echo_n "checking for CURL... " >&6; } if test -n "$CURL_CFLAGS"; then pkg_cv_CURL_CFLAGS="$CURL_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libcurl\""; } >&5 ($PKG_CONFIG --exists --print-errors "libcurl") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_CURL_CFLAGS=`$PKG_CONFIG --cflags "libcurl" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$CURL_LIBS"; then pkg_cv_CURL_LIBS="$CURL_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libcurl\""; } >&5 ($PKG_CONFIG --exists --print-errors "libcurl") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_CURL_LIBS=`$PKG_CONFIG --libs "libcurl" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then CURL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libcurl" 2>&1` else CURL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libcurl" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$CURL_PKG_ERRORS" >&5 as_fn_error $? "Package requirements (libcurl) were not met: $CURL_PKG_ERRORS Consider adjusting the PKG_CONFIG_PATH environment variable if you installed software in a non-standard prefix. Alternatively, you may set the environment variables CURL_CFLAGS and CURL_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it is in your PATH or set the PKG_CONFIG environment variable to the full path to pkg-config. Alternatively, you may set the environment variables CURL_CFLAGS and CURL_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details. To get pkg-config, see <http://pkg-config.freedesktop.org/>. See \`config.log' for more details" "$LINENO" 5; } else CURL_CFLAGS=$pkg_cv_CURL_CFLAGS CURL_LIBS=$pkg_cv_CURL_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } fi # Check for lixml2 pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XML2" >&5 $as_echo_n "checking for XML2... " >&6; } if test -n "$XML2_CFLAGS"; then pkg_cv_XML2_CFLAGS="$XML2_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0\""; } >&5 ($PKG_CONFIG --exists --print-errors "libxml-2.0") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_XML2_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$XML2_LIBS"; then pkg_cv_XML2_LIBS="$XML2_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0\""; } >&5 ($PKG_CONFIG --exists --print-errors "libxml-2.0") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_XML2_LIBS=`$PKG_CONFIG --libs "libxml-2.0" 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then XML2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libxml-2.0" 2>&1` else XML2_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libxml-2.0" 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$XML2_PKG_ERRORS" >&5 as_fn_error $? "Package requirements (libxml-2.0) were not met: $XML2_PKG_ERRORS Consider adjusting the PKG_CONFIG_PATH environment variable if you installed software in a non-standard prefix. Alternatively, you may set the environment variables XML2_CFLAGS and XML2_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it is in your PATH or set the PKG_CONFIG environment variable to the full path to pkg-config. Alternatively, you may set the environment variables XML2_CFLAGS and XML2_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details. To get pkg-config, see <http://pkg-config.freedesktop.org/>. See \`config.log' for more details" "$LINENO" 5; } else XML2_CFLAGS=$pkg_cv_XML2_CFLAGS XML2_LIBS=$pkg_cv_XML2_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } fi # Check for cppunit if test "x$enable_tests" != "xno"; then : pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPPUNIT" >&5 $as_echo_n "checking for CPPUNIT... " >&6; } if test -n "$CPPUNIT_CFLAGS"; then pkg_cv_CPPUNIT_CFLAGS="$CPPUNIT_CFLAGS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"cppunit >= 1.12 \""; } >&5 ($PKG_CONFIG --exists --print-errors "cppunit >= 1.12 ") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_CPPUNIT_CFLAGS=`$PKG_CONFIG --cflags "cppunit >= 1.12 " 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test -n "$CPPUNIT_LIBS"; then pkg_cv_CPPUNIT_LIBS="$CPPUNIT_LIBS" elif test -n "$PKG_CONFIG"; then if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"cppunit >= 1.12 \""; } >&5 ($PKG_CONFIG --exists --print-errors "cppunit >= 1.12 ") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_CPPUNIT_LIBS=`$PKG_CONFIG --libs "cppunit >= 1.12 " 2>/dev/null` test "x$?" != "x0" && pkg_failed=yes else pkg_failed=yes fi else pkg_failed=untried fi if test $pkg_failed = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then CPPUNIT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "cppunit >= 1.12 " 2>&1` else CPPUNIT_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "cppunit >= 1.12 " 2>&1` fi # Put the nasty error message in config.log where it belongs echo "$CPPUNIT_PKG_ERRORS" >&5 as_fn_error $? "Package requirements (cppunit >= 1.12 ) were not met: $CPPUNIT_PKG_ERRORS Consider adjusting the PKG_CONFIG_PATH environment variable if you installed software in a non-standard prefix. Alternatively, you may set the environment variables CPPUNIT_CFLAGS and CPPUNIT_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details." "$LINENO" 5 elif test $pkg_failed = untried; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it is in your PATH or set the PKG_CONFIG environment variable to the full path to pkg-config. Alternatively, you may set the environment variables CPPUNIT_CFLAGS and CPPUNIT_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details. To get pkg-config, see <http://pkg-config.freedesktop.org/>. See \`config.log' for more details" "$LINENO" 5; } else CPPUNIT_CFLAGS=$pkg_cv_CPPUNIT_CFLAGS CPPUNIT_LIBS=$pkg_cv_CPPUNIT_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } fi fi # Check for boost echo "$as_me: this is boost.m4 serial 26" >&5 boost_save_IFS=$IFS boost_version_req=1.36 IFS=. set x $boost_version_req 0 0 0 IFS=$boost_save_IFS shift boost_version_req=`expr "$1" '*' 100000 + "$2" '*' 100 + "$3"` boost_version_req_string=$1.$2.$3 # Check whether --with-boost was given. if test "${with_boost+set}" = set; then : withval=$with_boost; fi # If BOOST_ROOT is set and the user has not provided a value to # --with-boost, then treat BOOST_ROOT as if it the user supplied it. if test x"$BOOST_ROOT" != x; then if test x"$with_boost" = x; then { $as_echo "$as_me:${as_lineno-$LINENO}: Detected BOOST_ROOT; continuing with --with-boost=$BOOST_ROOT" >&5 $as_echo "$as_me: Detected BOOST_ROOT; continuing with --with-boost=$BOOST_ROOT" >&6;} with_boost=$BOOST_ROOT else { $as_echo "$as_me:${as_lineno-$LINENO}: Detected BOOST_ROOT=$BOOST_ROOT, but overridden by --with-boost=$with_boost" >&5 $as_echo "$as_me: Detected BOOST_ROOT=$BOOST_ROOT, but overridden by --with-boost=$with_boost" >&6;} fi fi DISTCHECK_CONFIGURE_FLAGS="$DISTCHECK_CONFIGURE_FLAGS '--with-boost=$with_boost'" boost_save_CPPFLAGS=$CPPFLAGS { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boost headers version >= $boost_version_req_string" >&5 $as_echo_n "checking for Boost headers version >= $boost_version_req_string... " >&6; } if ${boost_cv_inc_path+:} false; then : $as_echo_n "(cached) " >&6 else boost_cv_inc_path=no ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <boost/version.hpp> #if !defined BOOST_VERSION # error BOOST_VERSION is not defined #elif BOOST_VERSION < $boost_version_req # error Boost headers version < $boost_version_req #endif int main () { ; return 0; } _ACEOF # If the user provided a value to --with-boost, use it and only it. case $with_boost in #( ''|yes) set x '' /opt/local/include /usr/local/include /opt/include \ /usr/include C:/Boost/include;; #( *) set x "$with_boost/include" "$with_boost";; esac shift for boost_dir do # Without --layout=system, Boost (or at least some versions) installs # itself in <prefix>/include/boost-<version>. This inner loop helps to # find headers in such directories. # # Any ${boost_dir}/boost-x_xx directories are searched in reverse version # order followed by ${boost_dir}. The final '.' is a sentinel for # searching $boost_dir" itself. Entries are whitespace separated. # # I didn't indent this loop on purpose (to avoid over-indented code) boost_layout_system_search_list=`cd "$boost_dir" 2>/dev/null \ && ls -1 | "${GREP}" '^boost-' | sort -rn -t- -k2 \ && echo .` for boost_inc in $boost_layout_system_search_list do if test x"$boost_inc" != x.; then boost_inc="$boost_dir/$boost_inc" else boost_inc="$boost_dir" # Uses sentinel in boost_layout_system_search_list fi if test x"$boost_inc" != x; then # We are going to check whether the version of Boost installed # in $boost_inc is usable by running a compilation that # #includes it. But if we pass a -I/some/path in which Boost # is not installed, the compiler will just skip this -I and # use other locations (either from CPPFLAGS, or from its list # of system include directories). As a result we would use # header installed on the machine instead of the /some/path # specified by the user. So in that precise case (trying # $boost_inc), make sure the version.hpp exists. # # Use test -e as there can be symlinks. test -e "$boost_inc/boost/version.hpp" || continue CPPFLAGS="$CPPFLAGS -I$boost_inc" fi if ac_fn_cxx_try_compile "$LINENO"; then : boost_cv_inc_path=yes else boost_cv_version=no fi rm -f core conftest.err conftest.$ac_objext if test x"$boost_cv_inc_path" = xyes; then if test x"$boost_inc" != x; then boost_cv_inc_path=$boost_inc fi break 2 fi done done ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boost_cv_inc_path" >&5 $as_echo "$boost_cv_inc_path" >&6; } case $boost_cv_inc_path in #( no) boost_errmsg="cannot find Boost headers version >= $boost_version_req_string" as_fn_error $? "$boost_errmsg" "$LINENO" 5 ;;#( yes) BOOST_CPPFLAGS= ;;#( *) BOOST_CPPFLAGS="-I$boost_cv_inc_path" ;; esac if test x"$boost_cv_inc_path" != xno; then $as_echo "#define HAVE_BOOST 1" >>confdefs.h { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boost's header version" >&5 $as_echo_n "checking for Boost's header version... " >&6; } if ${boost_cv_lib_version+:} false; then : $as_echo_n "(cached) " >&6 else ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <boost/version.hpp> boost-lib-version = BOOST_LIB_VERSION _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | grep -v '#' | grep -v '^[[:space:]]*$' | tr -d '\r' | tr -s '\n' ' ' | $SED -n -e "/^boost-lib-version = /{s///;s/[\" ]//g;p;q;}" >conftest.i 2>&1; then : boost_cv_lib_version=`cat conftest.i` fi rm -rf conftest* ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boost_cv_lib_version" >&5 $as_echo "$boost_cv_lib_version" >&6; } # e.g. "134" for 1_34_1 or "135" for 1_35 boost_major_version=`echo "$boost_cv_lib_version" | sed 's/_//;s/_.*//'` case $boost_major_version in #( '' | *[!0-9]*) as_fn_error $? "invalid value: boost_major_version='$boost_major_version'" "$LINENO" 5 ;; esac fi CPPFLAGS=$boost_save_CPPFLAGS { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the toolset name used by Boost for $CXX" >&5 $as_echo_n "checking for the toolset name used by Boost for $CXX... " >&6; } if ${boost_cv_lib_tag+:} false; then : $as_echo_n "(cached) " >&6 else boost_cv_lib_tag=unknown if test x$boost_cv_inc_path != xno; then ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu # The following tests are mostly inspired by boost/config/auto_link.hpp # The list is sorted to most recent/common to oldest compiler (in order # to increase the likelihood of finding the right compiler with the # least number of compilation attempt). # Beware that some tests are sensible to the order (for instance, we must # look for MinGW before looking for GCC3). # I used one compilation test per compiler with a #error to recognize # each compiler so that it works even when cross-compiling (let me know # if you know a better approach). # Known missing tags (known from Boost's tools/build/v2/tools/common.jam): # como, edg, kcc, bck, mp, sw, tru, xlc # I'm not sure about my test for `il' (be careful: Intel's ICC pre-defines # the same defines as GCC's). for i in \ "defined __GNUC__ && __GNUC__ == 5 && __GNUC_MINOR__ == 3 && !defined __ICC && \ (defined WIN32 || defined WINNT || defined _WIN32 || defined __WIN32 \ || defined __WIN32__ || defined __WINNT || defined __WINNT__) @ mgw53" \ "defined __GNUC__ && __GNUC__ == 5 && __GNUC_MINOR__ == 3 && !defined __ICC @ gcc53" \ "defined __GNUC__ && __GNUC__ == 5 && __GNUC_MINOR__ == 2 && !defined __ICC && \ (defined WIN32 || defined WINNT || defined _WIN32 || defined __WIN32 \ || defined __WIN32__ || defined __WINNT || defined __WINNT__) @ mgw52" \ "defined __GNUC__ && __GNUC__ == 5 && __GNUC_MINOR__ == 2 && !defined __ICC @ gcc52" \ "defined __GNUC__ && __GNUC__ == 5 && __GNUC_MINOR__ == 1 && !defined __ICC && \ (defined WIN32 || defined WINNT || defined _WIN32 || defined __WIN32 \ || defined __WIN32__ || defined __WINNT || defined __WINNT__) @ mgw51" \ "defined __GNUC__ && __GNUC__ == 5 && __GNUC_MINOR__ == 1 && !defined __ICC @ gcc51" \ "defined __GNUC__ && __GNUC__ == 5 && __GNUC_MINOR__ == 0 && !defined __ICC && \ (defined WIN32 || defined WINNT || defined _WIN32 || defined __WIN32 \ || defined __WIN32__ || defined __WINNT || defined __WINNT__) @ mgw50" \ "defined __GNUC__ && __GNUC__ == 5 && __GNUC_MINOR__ == 0 && !defined __ICC @ gcc50" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 10 && !defined __ICC && \ (defined WIN32 || defined WINNT || defined _WIN32 || defined __WIN32 \ || defined __WIN32__ || defined __WINNT || defined __WINNT__) @ mgw410" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 10 && !defined __ICC @ gcc410" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 9 && !defined __ICC && \ (defined WIN32 || defined WINNT || defined _WIN32 || defined __WIN32 \ || defined __WIN32__ || defined __WINNT || defined __WINNT__) @ mgw49" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 9 && !defined __ICC @ gcc49" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 8 && !defined __ICC && \ (defined WIN32 || defined WINNT || defined _WIN32 || defined __WIN32 \ || defined __WIN32__ || defined __WINNT || defined __WINNT__) @ mgw48" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 8 && !defined __ICC @ gcc48" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 7 && !defined __ICC && \ (defined WIN32 || defined WINNT || defined _WIN32 || defined __WIN32 \ || defined __WIN32__ || defined __WINNT || defined __WINNT__) @ mgw47" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 7 && !defined __ICC @ gcc47" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 6 && !defined __ICC && \ (defined WIN32 || defined WINNT || defined _WIN32 || defined __WIN32 \ || defined __WIN32__ || defined __WINNT || defined __WINNT__) @ mgw46" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 6 && !defined __ICC @ gcc46" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 5 && !defined __ICC && \ (defined WIN32 || defined WINNT || defined _WIN32 || defined __WIN32 \ || defined __WIN32__ || defined __WINNT || defined __WINNT__) @ mgw45" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 5 && !defined __ICC @ gcc45" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 4 && !defined __ICC && \ (defined WIN32 || defined WINNT || defined _WIN32 || defined __WIN32 \ || defined __WIN32__ || defined __WINNT || defined __WINNT__) @ mgw44" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 4 && !defined __ICC @ gcc44" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 3 && !defined __ICC && \ (defined WIN32 || defined WINNT || defined _WIN32 || defined __WIN32 \ || defined __WIN32__ || defined __WINNT || defined __WINNT__) @ mgw43" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 3 && !defined __ICC @ gcc43" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 2 && !defined __ICC && \ (defined WIN32 || defined WINNT || defined _WIN32 || defined __WIN32 \ || defined __WIN32__ || defined __WINNT || defined __WINNT__) @ mgw42" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 2 && !defined __ICC @ gcc42" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 1 && !defined __ICC && \ (defined WIN32 || defined WINNT || defined _WIN32 || defined __WIN32 \ || defined __WIN32__ || defined __WINNT || defined __WINNT__) @ mgw41" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 1 && !defined __ICC @ gcc41" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 0 && !defined __ICC && \ (defined WIN32 || defined WINNT || defined _WIN32 || defined __WIN32 \ || defined __WIN32__ || defined __WINNT || defined __WINNT__) @ mgw40" \ "defined __GNUC__ && __GNUC__ == 4 && __GNUC_MINOR__ == 0 && !defined __ICC @ gcc40" \ "defined __GNUC__ && __GNUC__ == 3 && !defined __ICC \ && (defined WIN32 || defined WINNT || defined _WIN32 || defined __WIN32 \ || defined __WIN32__ || defined __WINNT || defined __WINNT__) @ mgw" \ "defined __GNUC__ && __GNUC__ == 3 && __GNUC_MINOR__ == 4 && !defined __ICC @ gcc34" \ "defined __GNUC__ && __GNUC__ == 3 && __GNUC_MINOR__ == 3 && !defined __ICC @ gcc33" \ "defined _MSC_VER && _MSC_VER >= 1500 @ vc90" \ "defined _MSC_VER && _MSC_VER == 1400 @ vc80" \ "defined __GNUC__ && __GNUC__ == 3 && __GNUC_MINOR__ == 2 && !defined __ICC @ gcc32" \ "defined _MSC_VER && _MSC_VER == 1310 @ vc71" \ "defined __GNUC__ && __GNUC__ == 3 && __GNUC_MINOR__ == 1 && !defined __ICC @ gcc31" \ "defined __GNUC__ && __GNUC__ == 3 && __GNUC_MINOR__ == 0 && !defined __ICC @ gcc30" \ "defined __BORLANDC__ @ bcb" \ "defined __ICC && (defined __unix || defined ) @ il" \ "defined __ICL @ iw" \ "defined _MSC_VER && _MSC_VER == 1300 @ vc7" \ "defined __GNUC__ && __GNUC__ == 2 && __GNUC_MINOR__ == 95 && !defined __ICC @ gcc295" \ "defined __MWERKS__ && __MWERKS__ <= 0x32FF @ cw9" \ "defined _MSC_VER && _MSC_VER < 1300 && !defined UNDER_CE @ vc6" \ "defined _MSC_VER && _MSC_VER < 1300 && defined UNDER_CE @ evc4" \ "defined __MWERKS__ && __MWERKS__ <= 0x31FF @ cw8" do boost_tag_test=`expr "X$i" : 'X\([^@]*\) @ '` boost_tag=`expr "X$i" : 'X[^@]* @ \(.*\)'` cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #if $boost_tag_test /* OK */ #else # error $boost_tag_test #endif int main () { ; return 0; } _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : boost_cv_lib_tag=$boost_tag; break fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext done ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu case $boost_cv_lib_tag in #( # Some newer (>= 1.35?) versions of Boost seem to only use "gcc" as opposed # to "gcc41" for instance. *-gcc | *'-gcc ') :;; #( Don't re-add -gcc: it's already in there. gcc*) boost_tag_x= case $host_os in #( darwin*) if test $boost_major_version -ge 136; then # The `x' added in r46793 of Boost. boost_tag_x=x fi;; esac # We can specify multiple tags in this variable because it's used by # BOOST_FIND_LIB that does a `for tag in -$boost_cv_lib_tag' ... boost_cv_lib_tag="$boost_tag_x$boost_cv_lib_tag -${boost_tag_x}gcc" ;; #( unknown) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: could not figure out which toolset name to use for $CXX" >&5 $as_echo "$as_me: WARNING: could not figure out which toolset name to use for $CXX" >&2;} boost_cv_lib_tag= ;; esac fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boost_cv_lib_tag" >&5 $as_echo "$boost_cv_lib_tag" >&6; } # Check whether --enable-static-boost was given. if test "${enable_static_boost+set}" = set; then : enableval=$enable_static_boost; enable_static_boost=yes else enable_static_boost=no fi # Check whether we do better use `mt' even though we weren't ask to. ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #if defined _REENTRANT || defined _MT || defined __MT__ /* use -mt */ #else # error MT not needed #endif int main () { ; return 0; } _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : boost_guess_use_mt=: else boost_guess_use_mt=false fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu if test x"$boost_cv_inc_path" = xno; then { $as_echo "$as_me:${as_lineno-$LINENO}: Boost not available, not searching for the Boost date_time library" >&5 $as_echo "$as_me: Boost not available, not searching for the Boost date_time library" >&6;} else ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu if test x"$boost_cv_inc_path" = xno; then { $as_echo "$as_me:${as_lineno-$LINENO}: Boost not available, not searching for boost/date_time/posix_time/posix_time.hpp" >&5 $as_echo "$as_me: Boost not available, not searching for boost/date_time/posix_time/posix_time.hpp" >&6;} else ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu boost_save_CPPFLAGS=$CPPFLAGS CPPFLAGS="$CPPFLAGS $BOOST_CPPFLAGS" ac_fn_cxx_check_header_mongrel "$LINENO" "boost/date_time/posix_time/posix_time.hpp" "ac_cv_header_boost_date_time_posix_time_posix_time_hpp" "$ac_includes_default" if test "x$ac_cv_header_boost_date_time_posix_time_posix_time_hpp" = xyes; then : $as_echo "#define HAVE_BOOST_DATE_TIME_POSIX_TIME_POSIX_TIME_HPP 1" >>confdefs.h else as_fn_error $? "cannot find boost/date_time/posix_time/posix_time.hpp" "$LINENO" 5 fi CPPFLAGS=$boost_save_CPPFLAGS ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu fi boost_save_CPPFLAGS=$CPPFLAGS CPPFLAGS="$CPPFLAGS $BOOST_CPPFLAGS" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the Boost date_time library" >&5 $as_echo_n "checking for the Boost date_time library... " >&6; } if ${boost_cv_lib_date_time+:} false; then : $as_echo_n "(cached) " >&6 else boost_cv_lib_date_time=no case "" in #( (mt | mt-) boost_mt=-mt; boost_rtopt=;; #( (mt* | mt-*) boost_mt=-mt; boost_rtopt=`expr "X" : 'Xmt-*\(.*\)'`;; #( (*) boost_mt=; boost_rtopt=;; esac if test $enable_static_boost = yes; then boost_rtopt="s$boost_rtopt" fi # Find the proper debug variant depending on what we've been asked to find. case $boost_rtopt in #( (*d*) boost_rt_d=$boost_rtopt;; #( (*[sgpn]*) # Insert the `d' at the right place (in between `sg' and `pn') boost_rt_d=`echo "$boost_rtopt" | sed 's/\(s*g*\)\(p*n*\)/\1\2/'`;; #( (*) boost_rt_d='-d';; esac # If the PREFERRED-RT-OPT are not empty, prepend a `-'. test -n "$boost_rtopt" && boost_rtopt="-$boost_rtopt" $boost_guess_use_mt && boost_mt=-mt # Look for the abs path the static archive. # $libext is computed by Libtool but let's make sure it's non empty. test -z "$libext" && as_fn_error $? "the libext variable is empty, did you invoke Libtool?" "$LINENO" 5 boost_save_ac_objext=$ac_objext # Generate the test file. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <boost/date_time/posix_time/posix_time.hpp> int main () { boost::posix_time::ptime t; ; return 0; } _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : ac_objext=do_not_rm_me_plz else as_fn_error $? "cannot compile a test that uses Boost date_time" "$LINENO" 5 fi rm -f core conftest.err conftest.$ac_objext ac_objext=$boost_save_ac_objext boost_failed_libs= # Don't bother to ident the following nested for loops, only the 2 # innermost ones matter. for boost_lib_ in date_time; do for boost_tag_ in -$boost_cv_lib_tag ''; do for boost_ver_ in -$boost_cv_lib_version ''; do for boost_mt_ in $boost_mt -mt ''; do for boost_rtopt_ in $boost_rtopt '' -d; do for boost_lib in \ boost_$boost_lib_$boost_tag_$boost_mt_$boost_rtopt_$boost_ver_ \ boost_$boost_lib_$boost_tag_$boost_rtopt_$boost_ver_ \ boost_$boost_lib_$boost_tag_$boost_mt_$boost_ver_ \ boost_$boost_lib_$boost_tag_$boost_ver_ do # Avoid testing twice the same lib case $boost_failed_libs in #( (*@$boost_lib@*) continue;; esac # If with_boost is empty, we'll search in /lib first, which is not quite # right so instead we'll try to a location based on where the headers are. boost_tmp_lib=$with_boost test x"$with_boost" = x && boost_tmp_lib=${boost_cv_inc_path%/include} for boost_ldpath in "$boost_tmp_lib/lib" '' \ /opt/local/lib* /usr/local/lib* /opt/lib* /usr/lib* \ "$with_boost" C:/Boost/lib /lib* do # Don't waste time with directories that don't exist. if test x"$boost_ldpath" != x && test ! -e "$boost_ldpath"; then continue fi boost_save_LDFLAGS=$LDFLAGS # Are we looking for a static library? case $boost_ldpath:$boost_rtopt_ in #( (*?*:*s*) # Yes (Non empty boost_ldpath + s in rt opt) boost_cv_lib_date_time_LIBS="$boost_ldpath/lib$boost_lib.$libext" test -e "$boost_cv_lib_date_time_LIBS" || continue;; #( (*) # No: use -lboost_foo to find the shared library. boost_cv_lib_date_time_LIBS="-l$boost_lib";; esac boost_save_LIBS=$LIBS LIBS="$boost_cv_lib_date_time_LIBS $LIBS" test x"$boost_ldpath" != x && LDFLAGS="$LDFLAGS -L$boost_ldpath" rm -f conftest$ac_exeext boost_save_ac_ext=$ac_ext boost_use_source=: # If we already have a .o, re-use it. We change $ac_ext so that $ac_link # tries to link the existing object file instead of compiling from source. test -f conftest.$ac_objext && ac_ext=$ac_objext && boost_use_source=false && $as_echo "$as_me:${as_lineno-$LINENO}: re-using the existing conftest.$ac_objext" >&5 if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && { test "$cross_compiling" = yes || $as_executable_p conftest$ac_exeext }; then : boost_cv_lib_date_time=yes else if $boost_use_source; then $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi boost_cv_lib_date_time=no fi ac_objext=$boost_save_ac_objext ac_ext=$boost_save_ac_ext rm -f core conftest.err conftest_ipa8_conftest.oo \ conftest$ac_exeext ac_objext=$boost_save_ac_objext LDFLAGS=$boost_save_LDFLAGS LIBS=$boost_save_LIBS if test x"$boost_cv_lib_date_time" = xyes; then # Check or used cached result of whether or not using -R or # -rpath makes sense. Some implementations of ld, such as for # Mac OSX, require -rpath but -R is the flag known to work on # other systems. https://github.com/tsuna/boost.m4/issues/19 if ${boost_cv_rpath_link_ldflag+:} false; then : $as_echo_n "(cached) " >&6 else case $boost_ldpath in '') # Nothing to do. boost_cv_rpath_link_ldflag= boost_rpath_link_ldflag_found=yes;; *) for boost_cv_rpath_link_ldflag in -Wl,-R, -Wl,-rpath,; do LDFLAGS="$boost_save_LDFLAGS -L$boost_ldpath $boost_cv_rpath_link_ldflag$boost_ldpath" LIBS="$boost_save_LIBS $boost_cv_lib_date_time_LIBS" rm -f conftest$ac_exeext boost_save_ac_ext=$ac_ext boost_use_source=: # If we already have a .o, re-use it. We change $ac_ext so that $ac_link # tries to link the existing object file instead of compiling from source. test -f conftest.$ac_objext && ac_ext=$ac_objext && boost_use_source=false && $as_echo "$as_me:${as_lineno-$LINENO}: re-using the existing conftest.$ac_objext" >&5 if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && { test "$cross_compiling" = yes || $as_executable_p conftest$ac_exeext }; then : boost_rpath_link_ldflag_found=yes break else if $boost_use_source; then $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi boost_rpath_link_ldflag_found=no fi ac_objext=$boost_save_ac_objext ac_ext=$boost_save_ac_ext rm -f core conftest.err conftest_ipa8_conftest.oo \ conftest$ac_exeext done ;; esac if test "x$boost_rpath_link_ldflag_found" != "xyes"; then : as_fn_error $? "Unable to determine whether to use -R or -rpath" "$LINENO" 5 fi LDFLAGS=$boost_save_LDFLAGS LIBS=$boost_save_LIBS fi test x"$boost_ldpath" != x && boost_cv_lib_date_time_LDFLAGS="-L$boost_ldpath $boost_cv_rpath_link_ldflag$boost_ldpath" boost_cv_lib_date_time_LDPATH="$boost_ldpath" break 7 else boost_failed_libs="$boost_failed_libs@$boost_lib@" fi done done done done done done done # boost_lib_ rm -f conftest.$ac_objext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boost_cv_lib_date_time" >&5 $as_echo "$boost_cv_lib_date_time" >&6; } case $boost_cv_lib_date_time in #( (no) $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 as_fn_error $? "cannot find the flags to link with Boost date_time" "$LINENO" 5 ;; esac BOOST_DATE_TIME_LDFLAGS=$boost_cv_lib_date_time_LDFLAGS BOOST_DATE_TIME_LDPATH=$boost_cv_lib_date_time_LDPATH BOOST_LDPATH=$boost_cv_lib_date_time_LDPATH BOOST_DATE_TIME_LIBS=$boost_cv_lib_date_time_LIBS CPPFLAGS=$boost_save_CPPFLAGS ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu fi if test x"$boost_cv_inc_path" = xno; then { $as_echo "$as_me:${as_lineno-$LINENO}: Boost not available, not searching for boost/scoped_ptr.hpp" >&5 $as_echo "$as_me: Boost not available, not searching for boost/scoped_ptr.hpp" >&6;} else ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu boost_save_CPPFLAGS=$CPPFLAGS CPPFLAGS="$CPPFLAGS $BOOST_CPPFLAGS" ac_fn_cxx_check_header_mongrel "$LINENO" "boost/scoped_ptr.hpp" "ac_cv_header_boost_scoped_ptr_hpp" "$ac_includes_default" if test "x$ac_cv_header_boost_scoped_ptr_hpp" = xyes; then : $as_echo "#define HAVE_BOOST_SCOPED_PTR_HPP 1" >>confdefs.h else as_fn_error $? "cannot find boost/scoped_ptr.hpp" "$LINENO" 5 fi CPPFLAGS=$boost_save_CPPFLAGS ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu fi if test x"$boost_cv_inc_path" = xno; then { $as_echo "$as_me:${as_lineno-$LINENO}: Boost not available, not searching for boost/shared_ptr.hpp" >&5 $as_echo "$as_me: Boost not available, not searching for boost/shared_ptr.hpp" >&6;} else ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu boost_save_CPPFLAGS=$CPPFLAGS CPPFLAGS="$CPPFLAGS $BOOST_CPPFLAGS" ac_fn_cxx_check_header_mongrel "$LINENO" "boost/shared_ptr.hpp" "ac_cv_header_boost_shared_ptr_hpp" "$ac_includes_default" if test "x$ac_cv_header_boost_shared_ptr_hpp" = xyes; then : $as_echo "#define HAVE_BOOST_SHARED_PTR_HPP 1" >>confdefs.h else as_fn_error $? "cannot find boost/shared_ptr.hpp" "$LINENO" 5 fi CPPFLAGS=$boost_save_CPPFLAGS ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu fi if test x"$boost_cv_inc_path" = xno; then { $as_echo "$as_me:${as_lineno-$LINENO}: Boost not available, not searching for boost/algorithm/string.hpp" >&5 $as_echo "$as_me: Boost not available, not searching for boost/algorithm/string.hpp" >&6;} else ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu boost_save_CPPFLAGS=$CPPFLAGS CPPFLAGS="$CPPFLAGS $BOOST_CPPFLAGS" ac_fn_cxx_check_header_mongrel "$LINENO" "boost/algorithm/string.hpp" "ac_cv_header_boost_algorithm_string_hpp" "$ac_includes_default" if test "x$ac_cv_header_boost_algorithm_string_hpp" = xyes; then : $as_echo "#define HAVE_BOOST_ALGORITHM_STRING_HPP 1" >>confdefs.h else as_fn_error $? "cannot find boost/algorithm/string.hpp" "$LINENO" 5 fi CPPFLAGS=$boost_save_CPPFLAGS ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu fi if test x"$boost_cv_inc_path" = xno; then { $as_echo "$as_me:${as_lineno-$LINENO}: Boost not available, not searching for boost/uuid/uuid.hpp" >&5 $as_echo "$as_me: Boost not available, not searching for boost/uuid/uuid.hpp" >&6;} else ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu boost_save_CPPFLAGS=$CPPFLAGS CPPFLAGS="$CPPFLAGS $BOOST_CPPFLAGS" ac_fn_cxx_check_header_mongrel "$LINENO" "boost/uuid/uuid.hpp" "ac_cv_header_boost_uuid_uuid_hpp" "$ac_includes_default" if test "x$ac_cv_header_boost_uuid_uuid_hpp" = xyes; then : $as_echo "#define HAVE_BOOST_UUID_UUID_HPP 1" >>confdefs.h else as_fn_error $? "cannot find boost/uuid/uuid.hpp" "$LINENO" 5 fi CPPFLAGS=$boost_save_CPPFLAGS ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu fi if test "x$enable_client" != "xno"; then : if test x"$boost_cv_inc_path" = xno; then { $as_echo "$as_me:${as_lineno-$LINENO}: Boost not available, not searching for the Boost program_options library" >&5 $as_echo "$as_me: Boost not available, not searching for the Boost program_options library" >&6;} else ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu if test x"$boost_cv_inc_path" = xno; then { $as_echo "$as_me:${as_lineno-$LINENO}: Boost not available, not searching for boost/program_options.hpp" >&5 $as_echo "$as_me: Boost not available, not searching for boost/program_options.hpp" >&6;} else ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu boost_save_CPPFLAGS=$CPPFLAGS CPPFLAGS="$CPPFLAGS $BOOST_CPPFLAGS" ac_fn_cxx_check_header_mongrel "$LINENO" "boost/program_options.hpp" "ac_cv_header_boost_program_options_hpp" "$ac_includes_default" if test "x$ac_cv_header_boost_program_options_hpp" = xyes; then : $as_echo "#define HAVE_BOOST_PROGRAM_OPTIONS_HPP 1" >>confdefs.h else as_fn_error $? "cannot find boost/program_options.hpp" "$LINENO" 5 fi CPPFLAGS=$boost_save_CPPFLAGS ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu fi boost_save_CPPFLAGS=$CPPFLAGS CPPFLAGS="$CPPFLAGS $BOOST_CPPFLAGS" { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the Boost program_options library" >&5 $as_echo_n "checking for the Boost program_options library... " >&6; } if ${boost_cv_lib_program_options+:} false; then : $as_echo_n "(cached) " >&6 else boost_cv_lib_program_options=no case "" in #( (mt | mt-) boost_mt=-mt; boost_rtopt=;; #( (mt* | mt-*) boost_mt=-mt; boost_rtopt=`expr "X" : 'Xmt-*\(.*\)'`;; #( (*) boost_mt=; boost_rtopt=;; esac if test $enable_static_boost = yes; then boost_rtopt="s$boost_rtopt" fi # Find the proper debug variant depending on what we've been asked to find. case $boost_rtopt in #( (*d*) boost_rt_d=$boost_rtopt;; #( (*[sgpn]*) # Insert the `d' at the right place (in between `sg' and `pn') boost_rt_d=`echo "$boost_rtopt" | sed 's/\(s*g*\)\(p*n*\)/\1\2/'`;; #( (*) boost_rt_d='-d';; esac # If the PREFERRED-RT-OPT are not empty, prepend a `-'. test -n "$boost_rtopt" && boost_rtopt="-$boost_rtopt" $boost_guess_use_mt && boost_mt=-mt # Look for the abs path the static archive. # $libext is computed by Libtool but let's make sure it's non empty. test -z "$libext" && as_fn_error $? "the libext variable is empty, did you invoke Libtool?" "$LINENO" 5 boost_save_ac_objext=$ac_objext # Generate the test file. cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <boost/program_options.hpp> int main () { boost::program_options::options_description d("test"); ; return 0; } _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : ac_objext=do_not_rm_me_plz else as_fn_error $? "cannot compile a test that uses Boost program_options" "$LINENO" 5 fi rm -f core conftest.err conftest.$ac_objext ac_objext=$boost_save_ac_objext boost_failed_libs= # Don't bother to ident the following nested for loops, only the 2 # innermost ones matter. for boost_lib_ in program_options; do for boost_tag_ in -$boost_cv_lib_tag ''; do for boost_ver_ in -$boost_cv_lib_version ''; do for boost_mt_ in $boost_mt -mt ''; do for boost_rtopt_ in $boost_rtopt '' -d; do for boost_lib in \ boost_$boost_lib_$boost_tag_$boost_mt_$boost_rtopt_$boost_ver_ \ boost_$boost_lib_$boost_tag_$boost_rtopt_$boost_ver_ \ boost_$boost_lib_$boost_tag_$boost_mt_$boost_ver_ \ boost_$boost_lib_$boost_tag_$boost_ver_ do # Avoid testing twice the same lib case $boost_failed_libs in #( (*@$boost_lib@*) continue;; esac # If with_boost is empty, we'll search in /lib first, which is not quite # right so instead we'll try to a location based on where the headers are. boost_tmp_lib=$with_boost test x"$with_boost" = x && boost_tmp_lib=${boost_cv_inc_path%/include} for boost_ldpath in "$boost_tmp_lib/lib" '' \ /opt/local/lib* /usr/local/lib* /opt/lib* /usr/lib* \ "$with_boost" C:/Boost/lib /lib* do # Don't waste time with directories that don't exist. if test x"$boost_ldpath" != x && test ! -e "$boost_ldpath"; then continue fi boost_save_LDFLAGS=$LDFLAGS # Are we looking for a static library? case $boost_ldpath:$boost_rtopt_ in #( (*?*:*s*) # Yes (Non empty boost_ldpath + s in rt opt) boost_cv_lib_program_options_LIBS="$boost_ldpath/lib$boost_lib.$libext" test -e "$boost_cv_lib_program_options_LIBS" || continue;; #( (*) # No: use -lboost_foo to find the shared library. boost_cv_lib_program_options_LIBS="-l$boost_lib";; esac boost_save_LIBS=$LIBS LIBS="$boost_cv_lib_program_options_LIBS $LIBS" test x"$boost_ldpath" != x && LDFLAGS="$LDFLAGS -L$boost_ldpath" rm -f conftest$ac_exeext boost_save_ac_ext=$ac_ext boost_use_source=: # If we already have a .o, re-use it. We change $ac_ext so that $ac_link # tries to link the existing object file instead of compiling from source. test -f conftest.$ac_objext && ac_ext=$ac_objext && boost_use_source=false && $as_echo "$as_me:${as_lineno-$LINENO}: re-using the existing conftest.$ac_objext" >&5 if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && { test "$cross_compiling" = yes || $as_executable_p conftest$ac_exeext }; then : boost_cv_lib_program_options=yes else if $boost_use_source; then $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi boost_cv_lib_program_options=no fi ac_objext=$boost_save_ac_objext ac_ext=$boost_save_ac_ext rm -f core conftest.err conftest_ipa8_conftest.oo \ conftest$ac_exeext ac_objext=$boost_save_ac_objext LDFLAGS=$boost_save_LDFLAGS LIBS=$boost_save_LIBS if test x"$boost_cv_lib_program_options" = xyes; then # Check or used cached result of whether or not using -R or # -rpath makes sense. Some implementations of ld, such as for # Mac OSX, require -rpath but -R is the flag known to work on # other systems. https://github.com/tsuna/boost.m4/issues/19 if ${boost_cv_rpath_link_ldflag+:} false; then : $as_echo_n "(cached) " >&6 else case $boost_ldpath in '') # Nothing to do. boost_cv_rpath_link_ldflag= boost_rpath_link_ldflag_found=yes;; *) for boost_cv_rpath_link_ldflag in -Wl,-R, -Wl,-rpath,; do LDFLAGS="$boost_save_LDFLAGS -L$boost_ldpath $boost_cv_rpath_link_ldflag$boost_ldpath" LIBS="$boost_save_LIBS $boost_cv_lib_program_options_LIBS" rm -f conftest$ac_exeext boost_save_ac_ext=$ac_ext boost_use_source=: # If we already have a .o, re-use it. We change $ac_ext so that $ac_link # tries to link the existing object file instead of compiling from source. test -f conftest.$ac_objext && ac_ext=$ac_objext && boost_use_source=false && $as_echo "$as_me:${as_lineno-$LINENO}: re-using the existing conftest.$ac_objext" >&5 if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && { test "$cross_compiling" = yes || $as_executable_p conftest$ac_exeext }; then : boost_rpath_link_ldflag_found=yes break else if $boost_use_source; then $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi boost_rpath_link_ldflag_found=no fi ac_objext=$boost_save_ac_objext ac_ext=$boost_save_ac_ext rm -f core conftest.err conftest_ipa8_conftest.oo \ conftest$ac_exeext done ;; esac if test "x$boost_rpath_link_ldflag_found" != "xyes"; then : as_fn_error $? "Unable to determine whether to use -R or -rpath" "$LINENO" 5 fi LDFLAGS=$boost_save_LDFLAGS LIBS=$boost_save_LIBS fi test x"$boost_ldpath" != x && boost_cv_lib_program_options_LDFLAGS="-L$boost_ldpath $boost_cv_rpath_link_ldflag$boost_ldpath" boost_cv_lib_program_options_LDPATH="$boost_ldpath" break 7 else boost_failed_libs="$boost_failed_libs@$boost_lib@" fi done done done done done done done # boost_lib_ rm -f conftest.$ac_objext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boost_cv_lib_program_options" >&5 $as_echo "$boost_cv_lib_program_options" >&6; } case $boost_cv_lib_program_options in #( (no) $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 as_fn_error $? "cannot find the flags to link with Boost program_options" "$LINENO" 5 ;; esac BOOST_PROGRAM_OPTIONS_LDFLAGS=$boost_cv_lib_program_options_LDFLAGS BOOST_PROGRAM_OPTIONS_LDPATH=$boost_cv_lib_program_options_LDPATH BOOST_LDPATH=$boost_cv_lib_program_options_LDPATH BOOST_PROGRAM_OPTIONS_LIBS=$boost_cv_lib_program_options_LIBS CPPFLAGS=$boost_save_CPPFLAGS ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu fi fi # Checks for header files. for ac_header in stdlib.h unistd.h do : as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : cat >>confdefs.h <<_ACEOF #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done # Checks for typedefs, structures, and compiler characteristics. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; } if ${ac_cv_header_stdbool_h+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include <stdbool.h> #ifndef bool "error: bool is not defined" #endif #ifndef false "error: false is not defined" #endif #if false "error: false is not 0" #endif #ifndef true "error: true is not defined" #endif #if true != 1 "error: true is not 1" #endif #ifndef __bool_true_false_are_defined "error: __bool_true_false_are_defined is not defined" #endif struct s { _Bool s: 1; _Bool t; } s; char a[true == 1 ? 1 : -1]; char b[false == 0 ? 1 : -1]; char c[__bool_true_false_are_defined == 1 ? 1 : -1]; char d[(bool) 0.5 == true ? 1 : -1]; /* See body of main program for 'e'. */ char f[(_Bool) 0.0 == false ? 1 : -1]; char g[true]; char h[sizeof (_Bool)]; char i[sizeof s.t]; enum { j = false, k = true, l = false * true, m = true * 256 }; /* The following fails for HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */ _Bool n[m]; char o[sizeof n == m * sizeof n[0] ? 1 : -1]; char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1]; /* Catch a bug in an HP-UX C compiler. See http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html */ _Bool q = true; _Bool *pq = &q; int main () { bool e = &s; *pq |= q; *pq |= ! q; /* Refer to every declared value, to avoid compiler optimizations. */ return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l + !m + !n + !o + !p + !q + !pq); ; return 0; } _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : ac_cv_header_stdbool_h=yes else ac_cv_header_stdbool_h=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5 $as_echo "$ac_cv_header_stdbool_h" >&6; } ac_fn_cxx_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default" if test "x$ac_cv_type__Bool" = xyes; then : cat >>confdefs.h <<_ACEOF #define HAVE__BOOL 1 _ACEOF fi if test $ac_cv_header_stdbool_h = yes; then $as_echo "#define HAVE_STDBOOL_H 1" >>confdefs.h fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 $as_echo_n "checking for inline... " >&6; } if ${ac_cv_c_inline+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_c_inline=no for ac_kw in inline __inline__ __inline; do cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #ifndef __cplusplus typedef int foo_t; static $ac_kw foo_t static_foo () {return 0; } $ac_kw foo_t foo () {return 0; } #endif _ACEOF if ac_fn_cxx_try_compile "$LINENO"; then : ac_cv_c_inline=$ac_kw fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext test "$ac_cv_c_inline" != no && break done fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 $as_echo "$ac_cv_c_inline" >&6; } case $ac_cv_c_inline in inline | yes) ;; *) case $ac_cv_c_inline in no) ac_val=;; *) ac_val=$ac_cv_c_inline;; esac cat >>confdefs.h <<_ACEOF #ifndef __cplusplus #define inline $ac_val #endif _ACEOF ;; esac ac_fn_cxx_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default" if test "x$ac_cv_type_mode_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define mode_t int _ACEOF fi ac_fn_cxx_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" if test "x$ac_cv_type_size_t" = xyes; then : else cat >>confdefs.h <<_ACEOF #define size_t unsigned int _ACEOF fi # Checks for library functions. ac_config_files="$ac_config_files Makefile doc/cmis-client.xml inc/Makefile inc/libcmis-c/Makefile inc/libcmis/Makefile libcmis-c-$LIBCMIS_API_VERSION.pc:libcmis-c.pc.in libcmis-$LIBCMIS_API_VERSION.pc:libcmis.pc.in qa/Makefile qa/libcmis-c/Makefile qa/libcmis/Makefile qa/mockup/Makefile src/Makefile src/libcmis-c/Makefile src/libcmis/Makefile" cat >confcache <<\_ACEOF # This file is a shell script that caches the results of configure # tests run on this system so they can be shared between configure # scripts and configure runs, see configure's option --config-cache. # It is not useful on other systems. If it contains results you don't # want to keep, you may remove or edit it. # # config.status only pays attention to the cache file if you give it # the --recheck option to rerun configure. # # `ac_cv_env_foo' variables (set or unset) will be overridden when # loading this file, other *unset* `ac_cv_foo' will be assigned the # following values. _ACEOF # The following way of writing the cache mishandles newlines in values, # but we know of no workaround that is simple, portable, and efficient. # So, we kill variables containing newlines. # Ultrix sh set writes to stderr and can't be redirected directly, # and sets the high bit in the cache file unless we assign to the vars. ( for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( *) { eval $ac_var=; unset $ac_var;} ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space=' '; set) 2>&1` in #( *${as_nl}ac_space=\ *) # `set' does not quote correctly, so add quotes: double-quote # substitution turns \\\\ into \\, and sed turns \\ into \. sed -n \ "s/'/'\\\\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" ;; #( *) # `set' quotes correctly as required by POSIX, so do not add quotes. sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) | sed ' /^ac_cv_env_/b end t clear :clear s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ t end s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ :end' >>confcache if diff "$cache_file" confcache >/dev/null 2>&1; then :; else if test -w "$cache_file"; then if test "x$cache_file" != "x/dev/null"; then { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 $as_echo "$as_me: updating cache $cache_file" >&6;} if test ! -f "$cache_file" || test -h "$cache_file"; then cat confcache >"$cache_file" else case $cache_file in #( */* | ?:*) mv -f confcache "$cache_file"$$ && mv -f "$cache_file"$$ "$cache_file" ;; #( *) mv -f confcache "$cache_file" ;; esac fi fi else { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} fi fi rm -f confcache test "x$prefix" = xNONE && prefix=$ac_default_prefix # Let make expand exec_prefix. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' # Transform confdefs.h into DEFS. # Protect against shell expansion while executing Makefile rules. # Protect against Makefile macro expansion. # # If the first sed substitution is executed (which looks for macros that # take arguments), then branch to the quote section. Otherwise, # look for a macro that doesn't take arguments. ac_script=' :mline /\\$/{ N s,\\\n,, b mline } t clear :clear s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g t quote s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g t quote b any :quote s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g s/\[/\\&/g s/\]/\\&/g s/\$/$$/g H :any ${ g s/^\n// s/\n/ /g p } ' DEFS=`sed -n "$ac_script" confdefs.h` ac_libobjs= ac_ltlibobjs= U= for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue # 1. Remove the extension, and $U if already installed. ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' ac_i=`$as_echo "$ac_i" | sed "$ac_script"` # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR # will be set to the directory where LIBOBJS objects are built. as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' done LIBOBJS=$ac_libobjs LTLIBOBJS=$ac_ltlibobjs { $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5 $as_echo_n "checking that generated files are newer than configure... " >&6; } if test -n "$am_sleep_pid"; then # Hide warnings about reused PIDs. wait $am_sleep_pid 2>/dev/null fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5 $as_echo "done" >&6; } if test -n "$EXEEXT"; then am__EXEEXT_TRUE= am__EXEEXT_FALSE='#' else am__EXEEXT_TRUE='#' am__EXEEXT_FALSE= fi if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then as_fn_error $? "conditional \"AMDEP\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then as_fn_error $? "conditional \"am__fastdepCC\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then as_fn_error $? "conditional \"am__fastdepCXX\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${ENABLE_CLIENT_TRUE}" && test -z "${ENABLE_CLIENT_FALSE}"; then as_fn_error $? "conditional \"ENABLE_CLIENT\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${ENABLE_TESTS_TRUE}" && test -z "${ENABLE_TESTS_FALSE}"; then as_fn_error $? "conditional \"ENABLE_TESTS\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${ENABLE_COVERAGE_TRUE}" && test -z "${ENABLE_COVERAGE_FALSE}"; then as_fn_error $? "conditional \"ENABLE_COVERAGE\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${OS_WIN32_TRUE}" && test -z "${OS_WIN32_FALSE}"; then as_fn_error $? "conditional \"OS_WIN32\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${ENABLE_VISIBILITY_TRUE}" && test -z "${ENABLE_VISIBILITY_FALSE}"; then as_fn_error $? "conditional \"ENABLE_VISIBILITY\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${ENABLE_MAN_TRUE}" && test -z "${ENABLE_MAN_FALSE}"; then as_fn_error $? "conditional \"ENABLE_MAN\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi : "${CONFIG_STATUS=./config.status}" ac_write_fail=0 ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files $CONFIG_STATUS" { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} as_write_fail=0 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 #! $SHELL # Generated by $as_me. # Run this file to recreate the current configuration. # Compiler output produced by configure, useful for debugging # configure, is in config.log if it exists. debug=false ac_cs_recheck=false ac_cs_silent=false SHELL=\${CONFIG_SHELL-$SHELL} export SHELL _ASEOF cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 ## -------------------- ## ## M4sh Initialization. ## ## -------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi as_nl=' ' export as_nl # Printing a long string crashes Solaris 7 /usr/bin/printf. as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo # Prefer a ksh shell builtin over an external printf program on Solaris, # but without wasting forks for bash or zsh. if test -z "$BASH_VERSION$ZSH_VERSION" \ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='print -r --' as_echo_n='print -rn --' elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='printf %s\n' as_echo_n='printf %s' else if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' as_echo_n='/usr/ucb/echo -n' else as_echo_body='eval expr "X$1" : "X\\(.*\\)"' as_echo_n_body='eval arg=$1; case $arg in #( *"$as_nl"*) expr "X$arg" : "X\\(.*\\)$as_nl"; arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; esac; expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" ' export as_echo_n_body as_echo_n='sh -c $as_echo_n_body as_echo' fi export as_echo_body as_echo='sh -c $as_echo_body as_echo' fi # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || PATH_SEPARATOR=';' } fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. as_myself= case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 exit 1 fi # Unset variables that we do not need and which cause bugs (e.g. in # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" # suppresses any "Segmentation fault" message there. '((' could # trigger a bug in pdksh 5.2.14. for as_var in BASH_ENV ENV MAIL MAILPATH do eval test x\${$as_var+set} = xset \ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. LC_ALL=C export LC_ALL LANGUAGE=C export LANGUAGE # CDPATH. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH # as_fn_error STATUS ERROR [LINENO LOG_FD] # ---------------------------------------- # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are # provided, also output the error to LOG_FD, referencing LINENO. Then exit the # script with STATUS, using 1 if that was 0. as_fn_error () { as_status=$1; test $as_status -eq 0 && as_status=1 if test "$4"; then as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 fi $as_echo "$as_me: error: $2" >&2 as_fn_exit $as_status } # as_fn_error # as_fn_set_status STATUS # ----------------------- # Set $? to STATUS, without forking. as_fn_set_status () { return $1 } # as_fn_set_status # as_fn_exit STATUS # ----------------- # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. as_fn_exit () { set +e as_fn_set_status $1 exit $1 } # as_fn_exit # as_fn_unset VAR # --------------- # Portably unset VAR. as_fn_unset () { { eval $1=; unset $1;} } as_unset=as_fn_unset # as_fn_append VAR VALUE # ---------------------- # Append the text in VALUE to the end of the definition contained in VAR. Take # advantage of any shell optimizations that allow amortized linear growth over # repeated appends, instead of the typical quadratic growth present in naive # implementations. if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : eval 'as_fn_append () { eval $1+=\$2 }' else as_fn_append () { eval $1=\$$1\$2 } fi # as_fn_append # as_fn_arith ARG... # ------------------ # Perform arithmetic evaluation on the ARGs, and store the result in the # global $as_val. Take advantage of shells that can avoid forks. The arguments # must be portable across $(()) and expr. if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : eval 'as_fn_arith () { as_val=$(( $* )) }' else as_fn_arith () { as_val=`expr "$@" || test $? -eq 1` } fi # as_fn_arith if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || $as_echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in #((((( -n*) case `echo 'xy\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. xy) ECHO_C='\c';; *) echo `echo ksh88 bug on AIX 6.1` > /dev/null ECHO_T=' ';; esac;; *) ECHO_N='-n';; esac rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir 2>/dev/null fi if (echo >conf$$.file) 2>/dev/null; then if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -pR'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -pR' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -pR' fi else as_ln_s='cp -pR' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null # as_fn_mkdir_p # ------------- # Create "$as_dir" as a directory, including parents if necessary. as_fn_mkdir_p () { case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || eval $as_mkdir_p || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" } # as_fn_mkdir_p if mkdir -p . 2>/dev/null; then as_mkdir_p='mkdir -p "$as_dir"' else test -d ./-p && rmdir ./-p as_mkdir_p=false fi # as_fn_executable_p FILE # ----------------------- # Test if FILE is an executable regular file. as_fn_executable_p () { test -f "$1" && test -x "$1" } # as_fn_executable_p as_test_x='test -x' as_executable_p=as_fn_executable_p # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" exec 6>&1 ## ----------------------------------- ## ## Main body of $CONFIG_STATUS script. ## ## ----------------------------------- ## _ASEOF test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # Save the log message, to keep $0 and so on meaningful, and to # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" This file was extended by libcmis $as_me 0.5.2, which was generated by GNU Autoconf 2.69. Invocation command line was CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS CONFIG_LINKS = $CONFIG_LINKS CONFIG_COMMANDS = $CONFIG_COMMANDS $ $0 $@ on `(hostname || uname -n) 2>/dev/null | sed 1q` " _ACEOF case $ac_config_files in *" "*) set x $ac_config_files; shift; ac_config_files=$*;; esac cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # Files that config.status was made for. config_files="$ac_config_files" config_commands="$ac_config_commands" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 ac_cs_usage="\ \`$as_me' instantiates files and other configuration actions from templates according to the current configuration. Unless the files and actions are specified as TAGs, all are instantiated by default. Usage: $0 [OPTION]... [TAG]... -h, --help print this help, then exit -V, --version print version number and configuration settings, then exit --config print configuration, then exit -q, --quiet, --silent do not print progress messages -d, --debug don't remove temporary files --recheck update $as_me by reconfiguring in the same conditions --file=FILE[:TEMPLATE] instantiate the configuration file FILE Configuration files: $config_files Configuration commands: $config_commands Report bugs to the package provider." _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ libcmis config.status 0.5.2 configured by $0, generated by GNU Autoconf 2.69, with options \\"\$ac_cs_config\\" Copyright (C) 2012 Free Software Foundation, Inc. This config.status script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it." ac_pwd='$ac_pwd' srcdir='$srcdir' INSTALL='$INSTALL' MKDIR_P='$MKDIR_P' AWK='$AWK' test -n "\$AWK" || AWK=awk _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # The default lists apply if the user does not specify any file. ac_need_defaults=: while test $# != 0 do case $1 in --*=?*) ac_option=`expr "X$1" : 'X\([^=]*\)='` ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` ac_shift=: ;; --*=) ac_option=`expr "X$1" : 'X\([^=]*\)='` ac_optarg= ac_shift=: ;; *) ac_option=$1 ac_optarg=$2 ac_shift=shift ;; esac case $ac_option in # Handling of the options. -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) ac_cs_recheck=: ;; --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) $as_echo "$ac_cs_version"; exit ;; --config | --confi | --conf | --con | --co | --c ) $as_echo "$ac_cs_config"; exit ;; --debug | --debu | --deb | --de | --d | -d ) debug=: ;; --file | --fil | --fi | --f ) $ac_shift case $ac_optarg in *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; '') as_fn_error $? "missing file argument" ;; esac as_fn_append CONFIG_FILES " '$ac_optarg'" ac_need_defaults=false;; --he | --h | --help | --hel | -h ) $as_echo "$ac_cs_usage"; exit ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil | --si | --s) ac_cs_silent=: ;; # This is an error. -*) as_fn_error $? "unrecognized option: \`$1' Try \`$0 --help' for more information." ;; *) as_fn_append ac_config_targets " $1" ac_need_defaults=false ;; esac shift done ac_configure_extra_args= if $ac_cs_silent; then exec 6>/dev/null ac_configure_extra_args="$ac_configure_extra_args --silent" fi _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 if \$ac_cs_recheck; then set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion shift \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 CONFIG_SHELL='$SHELL' export CONFIG_SHELL exec "\$@" fi _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 exec 5>>config.log { echo sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX ## Running $as_me. ## _ASBOX $as_echo "$ac_log" } >&5 _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # # INIT-COMMANDS # AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}" # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH sed_quote_subst='$sed_quote_subst' double_quote_subst='$double_quote_subst' delay_variable_subst='$delay_variable_subst' macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`' macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`' enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`' enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`' pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`' enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`' shared_archive_member_spec='`$ECHO "$shared_archive_member_spec" | $SED "$delay_single_quote_subst"`' SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`' ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`' PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`' host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`' host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`' host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`' build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`' build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`' build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`' SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`' Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`' GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`' EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`' FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`' LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`' NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`' LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`' max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`' ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`' exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`' lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`' lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`' lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`' lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`' lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`' reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`' reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`' OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`' deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`' file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`' file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`' want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`' DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`' sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`' AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`' AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`' archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`' STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`' RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`' old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`' old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`' old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`' lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`' CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`' CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`' compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`' GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_to_import='`$ECHO "$lt_cv_sys_global_symbol_to_import" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`' lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`' lt_cv_nm_interface='`$ECHO "$lt_cv_nm_interface" | $SED "$delay_single_quote_subst"`' nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`' lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`' lt_cv_truncate_bin='`$ECHO "$lt_cv_truncate_bin" | $SED "$delay_single_quote_subst"`' objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`' MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`' lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`' need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`' MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`' DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`' NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`' LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`' OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`' OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`' libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`' shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`' extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`' archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`' enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`' export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`' whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`' compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`' old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`' old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`' archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`' archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`' module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`' module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`' with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`' allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`' no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`' hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`' hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`' hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`' hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`' hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`' hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`' hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`' inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`' link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`' always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`' export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`' exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`' include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`' prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`' postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`' file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`' variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`' need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`' need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`' version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`' runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`' shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`' shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`' libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`' library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`' soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`' install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`' postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`' postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`' finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`' finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`' hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`' sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`' configure_time_dlsearch_path='`$ECHO "$configure_time_dlsearch_path" | $SED "$delay_single_quote_subst"`' configure_time_lt_sys_library_path='`$ECHO "$configure_time_lt_sys_library_path" | $SED "$delay_single_quote_subst"`' hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`' enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`' enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`' enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`' old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`' striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`' compiler_lib_search_dirs='`$ECHO "$compiler_lib_search_dirs" | $SED "$delay_single_quote_subst"`' predep_objects='`$ECHO "$predep_objects" | $SED "$delay_single_quote_subst"`' postdep_objects='`$ECHO "$postdep_objects" | $SED "$delay_single_quote_subst"`' predeps='`$ECHO "$predeps" | $SED "$delay_single_quote_subst"`' postdeps='`$ECHO "$postdeps" | $SED "$delay_single_quote_subst"`' compiler_lib_search_path='`$ECHO "$compiler_lib_search_path" | $SED "$delay_single_quote_subst"`' LD_CXX='`$ECHO "$LD_CXX" | $SED "$delay_single_quote_subst"`' reload_flag_CXX='`$ECHO "$reload_flag_CXX" | $SED "$delay_single_quote_subst"`' reload_cmds_CXX='`$ECHO "$reload_cmds_CXX" | $SED "$delay_single_quote_subst"`' old_archive_cmds_CXX='`$ECHO "$old_archive_cmds_CXX" | $SED "$delay_single_quote_subst"`' compiler_CXX='`$ECHO "$compiler_CXX" | $SED "$delay_single_quote_subst"`' GCC_CXX='`$ECHO "$GCC_CXX" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_no_builtin_flag_CXX='`$ECHO "$lt_prog_compiler_no_builtin_flag_CXX" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_pic_CXX='`$ECHO "$lt_prog_compiler_pic_CXX" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_wl_CXX='`$ECHO "$lt_prog_compiler_wl_CXX" | $SED "$delay_single_quote_subst"`' lt_prog_compiler_static_CXX='`$ECHO "$lt_prog_compiler_static_CXX" | $SED "$delay_single_quote_subst"`' lt_cv_prog_compiler_c_o_CXX='`$ECHO "$lt_cv_prog_compiler_c_o_CXX" | $SED "$delay_single_quote_subst"`' archive_cmds_need_lc_CXX='`$ECHO "$archive_cmds_need_lc_CXX" | $SED "$delay_single_quote_subst"`' enable_shared_with_static_runtimes_CXX='`$ECHO "$enable_shared_with_static_runtimes_CXX" | $SED "$delay_single_quote_subst"`' export_dynamic_flag_spec_CXX='`$ECHO "$export_dynamic_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' whole_archive_flag_spec_CXX='`$ECHO "$whole_archive_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' compiler_needs_object_CXX='`$ECHO "$compiler_needs_object_CXX" | $SED "$delay_single_quote_subst"`' old_archive_from_new_cmds_CXX='`$ECHO "$old_archive_from_new_cmds_CXX" | $SED "$delay_single_quote_subst"`' old_archive_from_expsyms_cmds_CXX='`$ECHO "$old_archive_from_expsyms_cmds_CXX" | $SED "$delay_single_quote_subst"`' archive_cmds_CXX='`$ECHO "$archive_cmds_CXX" | $SED "$delay_single_quote_subst"`' archive_expsym_cmds_CXX='`$ECHO "$archive_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`' module_cmds_CXX='`$ECHO "$module_cmds_CXX" | $SED "$delay_single_quote_subst"`' module_expsym_cmds_CXX='`$ECHO "$module_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`' with_gnu_ld_CXX='`$ECHO "$with_gnu_ld_CXX" | $SED "$delay_single_quote_subst"`' allow_undefined_flag_CXX='`$ECHO "$allow_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`' no_undefined_flag_CXX='`$ECHO "$no_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`' hardcode_libdir_flag_spec_CXX='`$ECHO "$hardcode_libdir_flag_spec_CXX" | $SED "$delay_single_quote_subst"`' hardcode_libdir_separator_CXX='`$ECHO "$hardcode_libdir_separator_CXX" | $SED "$delay_single_quote_subst"`' hardcode_direct_CXX='`$ECHO "$hardcode_direct_CXX" | $SED "$delay_single_quote_subst"`' hardcode_direct_absolute_CXX='`$ECHO "$hardcode_direct_absolute_CXX" | $SED "$delay_single_quote_subst"`' hardcode_minus_L_CXX='`$ECHO "$hardcode_minus_L_CXX" | $SED "$delay_single_quote_subst"`' hardcode_shlibpath_var_CXX='`$ECHO "$hardcode_shlibpath_var_CXX" | $SED "$delay_single_quote_subst"`' hardcode_automatic_CXX='`$ECHO "$hardcode_automatic_CXX" | $SED "$delay_single_quote_subst"`' inherit_rpath_CXX='`$ECHO "$inherit_rpath_CXX" | $SED "$delay_single_quote_subst"`' link_all_deplibs_CXX='`$ECHO "$link_all_deplibs_CXX" | $SED "$delay_single_quote_subst"`' always_export_symbols_CXX='`$ECHO "$always_export_symbols_CXX" | $SED "$delay_single_quote_subst"`' export_symbols_cmds_CXX='`$ECHO "$export_symbols_cmds_CXX" | $SED "$delay_single_quote_subst"`' exclude_expsyms_CXX='`$ECHO "$exclude_expsyms_CXX" | $SED "$delay_single_quote_subst"`' include_expsyms_CXX='`$ECHO "$include_expsyms_CXX" | $SED "$delay_single_quote_subst"`' prelink_cmds_CXX='`$ECHO "$prelink_cmds_CXX" | $SED "$delay_single_quote_subst"`' postlink_cmds_CXX='`$ECHO "$postlink_cmds_CXX" | $SED "$delay_single_quote_subst"`' file_list_spec_CXX='`$ECHO "$file_list_spec_CXX" | $SED "$delay_single_quote_subst"`' hardcode_action_CXX='`$ECHO "$hardcode_action_CXX" | $SED "$delay_single_quote_subst"`' compiler_lib_search_dirs_CXX='`$ECHO "$compiler_lib_search_dirs_CXX" | $SED "$delay_single_quote_subst"`' predep_objects_CXX='`$ECHO "$predep_objects_CXX" | $SED "$delay_single_quote_subst"`' postdep_objects_CXX='`$ECHO "$postdep_objects_CXX" | $SED "$delay_single_quote_subst"`' predeps_CXX='`$ECHO "$predeps_CXX" | $SED "$delay_single_quote_subst"`' postdeps_CXX='`$ECHO "$postdeps_CXX" | $SED "$delay_single_quote_subst"`' compiler_lib_search_path_CXX='`$ECHO "$compiler_lib_search_path_CXX" | $SED "$delay_single_quote_subst"`' LTCC='$LTCC' LTCFLAGS='$LTCFLAGS' compiler='$compiler_DEFAULT' # A function that is used when there is no print builtin or printf. func_fallback_echo () { eval 'cat <<_LTECHO_EOF \$1 _LTECHO_EOF' } # Quote evaled strings. for var in SHELL \ ECHO \ PATH_SEPARATOR \ SED \ GREP \ EGREP \ FGREP \ LD \ NM \ LN_S \ lt_SP2NL \ lt_NL2SP \ reload_flag \ OBJDUMP \ deplibs_check_method \ file_magic_cmd \ file_magic_glob \ want_nocaseglob \ DLLTOOL \ sharedlib_from_linklib_cmd \ AR \ AR_FLAGS \ archiver_list_spec \ STRIP \ RANLIB \ CC \ CFLAGS \ compiler \ lt_cv_sys_global_symbol_pipe \ lt_cv_sys_global_symbol_to_cdecl \ lt_cv_sys_global_symbol_to_import \ lt_cv_sys_global_symbol_to_c_name_address \ lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \ lt_cv_nm_interface \ nm_file_list_spec \ lt_cv_truncate_bin \ lt_prog_compiler_no_builtin_flag \ lt_prog_compiler_pic \ lt_prog_compiler_wl \ lt_prog_compiler_static \ lt_cv_prog_compiler_c_o \ need_locks \ MANIFEST_TOOL \ DSYMUTIL \ NMEDIT \ LIPO \ OTOOL \ OTOOL64 \ shrext_cmds \ export_dynamic_flag_spec \ whole_archive_flag_spec \ compiler_needs_object \ with_gnu_ld \ allow_undefined_flag \ no_undefined_flag \ hardcode_libdir_flag_spec \ hardcode_libdir_separator \ exclude_expsyms \ include_expsyms \ file_list_spec \ variables_saved_for_relink \ libname_spec \ library_names_spec \ soname_spec \ install_override_mode \ finish_eval \ old_striplib \ striplib \ compiler_lib_search_dirs \ predep_objects \ postdep_objects \ predeps \ postdeps \ compiler_lib_search_path \ LD_CXX \ reload_flag_CXX \ compiler_CXX \ lt_prog_compiler_no_builtin_flag_CXX \ lt_prog_compiler_pic_CXX \ lt_prog_compiler_wl_CXX \ lt_prog_compiler_static_CXX \ lt_cv_prog_compiler_c_o_CXX \ export_dynamic_flag_spec_CXX \ whole_archive_flag_spec_CXX \ compiler_needs_object_CXX \ with_gnu_ld_CXX \ allow_undefined_flag_CXX \ no_undefined_flag_CXX \ hardcode_libdir_flag_spec_CXX \ hardcode_libdir_separator_CXX \ exclude_expsyms_CXX \ include_expsyms_CXX \ file_list_spec_CXX \ compiler_lib_search_dirs_CXX \ predep_objects_CXX \ postdep_objects_CXX \ predeps_CXX \ postdeps_CXX \ compiler_lib_search_path_CXX; do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[\\\\\\\`\\"\\\$]*) eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" ;; esac done # Double-quote double-evaled strings. for var in reload_cmds \ old_postinstall_cmds \ old_postuninstall_cmds \ old_archive_cmds \ extract_expsyms_cmds \ old_archive_from_new_cmds \ old_archive_from_expsyms_cmds \ archive_cmds \ archive_expsym_cmds \ module_cmds \ module_expsym_cmds \ export_symbols_cmds \ prelink_cmds \ postlink_cmds \ postinstall_cmds \ postuninstall_cmds \ finish_cmds \ sys_lib_search_path_spec \ configure_time_dlsearch_path \ configure_time_lt_sys_library_path \ reload_cmds_CXX \ old_archive_cmds_CXX \ old_archive_from_new_cmds_CXX \ old_archive_from_expsyms_cmds_CXX \ archive_cmds_CXX \ archive_expsym_cmds_CXX \ module_cmds_CXX \ module_expsym_cmds_CXX \ export_symbols_cmds_CXX \ prelink_cmds_CXX \ postlink_cmds_CXX; do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[\\\\\\\`\\"\\\$]*) eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" ;; esac done ac_aux_dir='$ac_aux_dir' # See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes INIT. if test -n "\${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi PACKAGE='$PACKAGE' VERSION='$VERSION' RM='$RM' ofile='$ofile' _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # Handling of arguments. for ac_config_target in $ac_config_targets do case $ac_config_target in "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;; "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; "doc/cmis-client.xml") CONFIG_FILES="$CONFIG_FILES doc/cmis-client.xml" ;; "inc/Makefile") CONFIG_FILES="$CONFIG_FILES inc/Makefile" ;; "inc/libcmis-c/Makefile") CONFIG_FILES="$CONFIG_FILES inc/libcmis-c/Makefile" ;; "inc/libcmis/Makefile") CONFIG_FILES="$CONFIG_FILES inc/libcmis/Makefile" ;; "libcmis-c-$LIBCMIS_API_VERSION.pc") CONFIG_FILES="$CONFIG_FILES libcmis-c-$LIBCMIS_API_VERSION.pc:libcmis-c.pc.in" ;; "libcmis-$LIBCMIS_API_VERSION.pc") CONFIG_FILES="$CONFIG_FILES libcmis-$LIBCMIS_API_VERSION.pc:libcmis.pc.in" ;; "qa/Makefile") CONFIG_FILES="$CONFIG_FILES qa/Makefile" ;; "qa/libcmis-c/Makefile") CONFIG_FILES="$CONFIG_FILES qa/libcmis-c/Makefile" ;; "qa/libcmis/Makefile") CONFIG_FILES="$CONFIG_FILES qa/libcmis/Makefile" ;; "qa/mockup/Makefile") CONFIG_FILES="$CONFIG_FILES qa/mockup/Makefile" ;; "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;; "src/libcmis-c/Makefile") CONFIG_FILES="$CONFIG_FILES src/libcmis-c/Makefile" ;; "src/libcmis/Makefile") CONFIG_FILES="$CONFIG_FILES src/libcmis/Makefile" ;; *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; esac done # If the user did not use the arguments to specify the items to instantiate, # then the envvar interface is used. Set only those that are not. # We use the long form for the default assignment because of an extremely # bizarre bug on SunOS 4.1.3. if $ac_need_defaults; then test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands fi # Have a temporary directory for convenience. Make it in the build tree # simply because there is no reason against having it here, and in addition, # creating and moving files from /tmp can sometimes cause problems. # Hook for its removal unless debugging. # Note that there is a small window in which the directory will not be cleaned: # after its creation but before its name has been assigned to `$tmp'. $debug || { tmp= ac_tmp= trap 'exit_status=$? : "${ac_tmp:=$tmp}" { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status ' 0 trap 'as_fn_exit 1' 1 2 13 15 } # Create a (secure) tmp directory for tmp files. { tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && test -d "$tmp" } || { tmp=./conf$$-$RANDOM (umask 077 && mkdir "$tmp") } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 ac_tmp=$tmp # Set up the scripts for CONFIG_FILES section. # No need to generate them if there are no CONFIG_FILES. # This happens for instance with `./config.status config.h'. if test -n "$CONFIG_FILES"; then ac_cr=`echo X | tr X '\015'` # On cygwin, bash can eat \r inside `` if the user requested igncr. # But we know of no other shell where ac_cr would be empty at this # point, so we can use a bashism as a fallback. if test "x$ac_cr" = x; then eval ac_cr=\$\'\\r\' fi ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then ac_cs_awk_cr='\\r' else ac_cs_awk_cr=$ac_cr fi echo 'BEGIN {' >"$ac_tmp/subs1.awk" && _ACEOF { echo "cat >conf$$subs.awk <<_ACEOF" && echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && echo "_ACEOF" } >conf$$subs.sh || as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` ac_delim='%!_!# ' for ac_last_try in false false false false false :; do . ./conf$$subs.sh || as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` if test $ac_delim_n = $ac_delim_num; then break elif $ac_last_try; then as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi done rm -f conf$$subs.sh cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && _ACEOF sed -n ' h s/^/S["/; s/!.*/"]=/ p g s/^[^!]*!// :repl t repl s/'"$ac_delim"'$// t delim :nl h s/\(.\{148\}\)..*/\1/ t more1 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ p n b repl :more1 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ p g s/.\{148\}// t nl :delim h s/\(.\{148\}\)..*/\1/ t more2 s/["\\]/\\&/g; s/^/"/; s/$/"/ p b :more2 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ p g s/.\{148\}// t delim ' <conf$$subs.awk | sed ' /^[^""]/{ N s/\n// } ' >>$CONFIG_STATUS || ac_write_fail=1 rm -f conf$$subs.awk cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 _ACAWK cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && for (key in S) S_is_set[key] = 1 FS = "" } { line = $ 0 nfields = split(line, field, "@") substed = 0 len = length(field[1]) for (i = 2; i < nfields; i++) { key = field[i] keylen = length(key) if (S_is_set[key]) { value = S[key] line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) len += length(value) + length(field[++i]) substed = 1 } else len += 1 + keylen } print line } _ACAWK _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" else cat fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 _ACEOF # VPATH may cause trouble with some makes, so we remove sole $(srcdir), # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and # trailing colons and then remove the whole line if VPATH becomes empty # (actually we leave an empty line to preserve line numbers). if test "x$srcdir" = x.; then ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ h s/// s/^/:/ s/[ ]*$/:/ s/:\$(srcdir):/:/g s/:\${srcdir}:/:/g s/:@srcdir@:/:/g s/^:*// s/:*$// x s/\(=[ ]*\).*/\1/ G s/\n// s/^[^=]*=[ ]*$// }' fi cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 fi # test -n "$CONFIG_FILES" eval set X " :F $CONFIG_FILES :C $CONFIG_COMMANDS" shift for ac_tag do case $ac_tag in :[FHLC]) ac_mode=$ac_tag; continue;; esac case $ac_mode$ac_tag in :[FHL]*:*);; :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; :[FH]-) ac_tag=-:-;; :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; esac ac_save_IFS=$IFS IFS=: set x $ac_tag IFS=$ac_save_IFS shift ac_file=$1 shift case $ac_mode in :L) ac_source=$1;; :[FH]) ac_file_inputs= for ac_f do case $ac_f in -) ac_f="$ac_tmp/stdin";; *) # Look for the file first in the build tree, then in the source tree # (if the path is not absolute). The absolute path cannot be DOS-style, # because $ac_f cannot contain `:'. test -f "$ac_f" || case $ac_f in [\\/$]*) false;; *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; esac || as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; esac case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac as_fn_append ac_file_inputs " '$ac_f'" done # Let's still pretend it is `configure' which instantiates (i.e., don't # use $as_me), people would be surprised to read: # /* config.h. Generated by config.status. */ configure_input='Generated from '` $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' `' by configure.' if test x"$ac_file" != x-; then configure_input="$ac_file. $configure_input" { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 $as_echo "$as_me: creating $ac_file" >&6;} fi # Neutralize special characters interpreted by sed in replacement strings. case $configure_input in #( *\&* | *\|* | *\\* ) ac_sed_conf_input=`$as_echo "$configure_input" | sed 's/[\\\\&|]/\\\\&/g'`;; #( *) ac_sed_conf_input=$configure_input;; esac case $ac_tag in *:-:* | *:-) cat >"$ac_tmp/stdin" \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; esac ;; esac ac_dir=`$as_dirname -- "$ac_file" || $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$ac_file" : 'X\(//\)[^/]' \| \ X"$ac_file" : 'X\(//\)$' \| \ X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$ac_file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` as_dir="$ac_dir"; as_fn_mkdir_p ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix case $ac_mode in :F) # # CONFIG_FILE # case $INSTALL in [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; esac ac_MKDIR_P=$MKDIR_P case $MKDIR_P in [\\/$]* | ?:[\\/]* ) ;; */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; esac _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # If the template does not know about datarootdir, expand it. # FIXME: This hack should be removed a few years after 2.60. ac_datarootdir_hack=; ac_datarootdir_seen= ac_sed_dataroot=' /datarootdir/ { p q } /@datadir@/p /@docdir@/p /@infodir@/p /@localedir@/p /@mandir@/p' case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in *datarootdir*) ac_datarootdir_seen=yes;; *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_datarootdir_hack=' s&@datadir@&$datadir&g s&@docdir@&$docdir&g s&@infodir@&$infodir&g s&@localedir@&$localedir&g s&@mandir@&$mandir&g s&\\\${datarootdir}&$datarootdir&g' ;; esac _ACEOF # Neutralize VPATH when `$srcdir' = `.'. # Shell code in configure.ac might set extrasub. # FIXME: do we really want to maintain this feature? cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_sed_extra="$ac_vpsub $extrasub _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 :t /@[a-zA-Z_][a-zA-Z_0-9]*@/!b s|@configure_input@|$ac_sed_conf_input|;t t s&@top_builddir@&$ac_top_builddir_sub&;t t s&@top_build_prefix@&$ac_top_build_prefix&;t t s&@srcdir@&$ac_srcdir&;t t s&@abs_srcdir@&$ac_abs_srcdir&;t t s&@top_srcdir@&$ac_top_srcdir&;t t s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t s&@builddir@&$ac_builddir&;t t s&@abs_builddir@&$ac_abs_builddir&;t t s&@abs_top_builddir@&$ac_abs_top_builddir&;t t s&@INSTALL@&$ac_INSTALL&;t t s&@MKDIR_P@&$ac_MKDIR_P&;t t $ac_datarootdir_hack " eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ "$ac_tmp/out"`; test -z "$ac_out"; } && { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined" >&5 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined" >&2;} rm -f "$ac_tmp/stdin" case $ac_file in -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; esac \ || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 $as_echo "$as_me: executing $ac_file commands" >&6;} ;; esac case $ac_file$ac_mode in "depfiles":C) test x"$AMDEP_TRUE" != x"" || { # Older Autoconf quotes --file arguments for eval, but not when files # are listed without --file. Let's play safe and only enable the eval # if we detect the quoting. # TODO: see whether this extra hack can be removed once we start # requiring Autoconf 2.70 or later. case $CONFIG_FILES in #( *\'*) : eval set x "$CONFIG_FILES" ;; #( *) : set x $CONFIG_FILES ;; #( *) : ;; esac shift # Used to flag and report bootstrapping failures. am_rc=0 for am_mf do # Strip MF so we end up with the name of the file. am_mf=`$as_echo "$am_mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile which includes # dependency-tracking related rules and includes. # Grep'ing the whole file directly is not great: AIX grep has a line # limit of 2048, but all sed's we know have understand at least 4000. sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \ || continue am_dirpart=`$as_dirname -- "$am_mf" || $as_expr X"$am_mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$am_mf" : 'X\(//\)[^/]' \| \ X"$am_mf" : 'X\(//\)$' \| \ X"$am_mf" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$am_mf" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` am_filepart=`$as_basename -- "$am_mf" || $as_expr X/"$am_mf" : '.*/\([^/][^/]*\)/*$' \| \ X"$am_mf" : 'X\(//\)$' \| \ X"$am_mf" : 'X\(/\)' \| . 2>/dev/null || $as_echo X/"$am_mf" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` { echo "$as_me:$LINENO: cd "$am_dirpart" \ && sed -e '/# am--include-marker/d' "$am_filepart" \ | $MAKE -f - am--depfiles" >&5 (cd "$am_dirpart" \ && sed -e '/# am--include-marker/d' "$am_filepart" \ | $MAKE -f - am--depfiles) >&5 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } || am_rc=$? done if test $am_rc -ne 0; then { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error $? "Something went wrong bootstrapping makefile fragments for automatic dependency tracking. Try re-running configure with the '--disable-dependency-tracking' option to at least be able to build the package (albeit without support for automatic dependency tracking). See \`config.log' for more details" "$LINENO" 5; } fi { am_dirpart=; unset am_dirpart;} { am_filepart=; unset am_filepart;} { am_mf=; unset am_mf;} { am_rc=; unset am_rc;} rm -f conftest-deps.mk } ;; "libtool":C) # See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes. if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi cfgfile=${ofile}T trap "$RM \"$cfgfile\"; exit 1" 1 2 15 $RM "$cfgfile" cat <<_LT_EOF >> "$cfgfile" #! $SHELL # Generated automatically by $as_me ($PACKAGE) $VERSION # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # NOTE: Changes made to this file will be lost: look at ltmain.sh. # Provide generalized library-building support services. # Written by Gordon Matzigkeit, 1996 # Copyright (C) 2014 Free Software Foundation, Inc. # This is free software; see the source for copying conditions. There is NO # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # GNU Libtool is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of of the License, or # (at your option) any later version. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program or library that is built # using GNU Libtool, you may include this file under the same # distribution terms that you use for the rest of that program. # # GNU Libtool is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. # The names of the tagged configurations supported by this script. available_tags='CXX ' # Configured defaults for sys_lib_dlsearch_path munging. : \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"} # ### BEGIN LIBTOOL CONFIG # Which release of libtool.m4 was used? macro_version=$macro_version macro_revision=$macro_revision # Whether or not to build shared libraries. build_libtool_libs=$enable_shared # Whether or not to build static libraries. build_old_libs=$enable_static # What type of objects to build. pic_mode=$pic_mode # Whether or not to optimize for fast installation. fast_install=$enable_fast_install # Shared archive member basename,for filename based shared library versioning on AIX. shared_archive_member_spec=$shared_archive_member_spec # Shell to use when invoking shell scripts. SHELL=$lt_SHELL # An echo program that protects backslashes. ECHO=$lt_ECHO # The PATH separator for the build system. PATH_SEPARATOR=$lt_PATH_SEPARATOR # The host system. host_alias=$host_alias host=$host host_os=$host_os # The build system. build_alias=$build_alias build=$build build_os=$build_os # A sed program that does not truncate output. SED=$lt_SED # Sed that helps us avoid accidentally triggering echo(1) options like -n. Xsed="\$SED -e 1s/^X//" # A grep program that handles long lines. GREP=$lt_GREP # An ERE matcher. EGREP=$lt_EGREP # A literal string matcher. FGREP=$lt_FGREP # A BSD- or MS-compatible name lister. NM=$lt_NM # Whether we need soft or hard links. LN_S=$lt_LN_S # What is the maximum length of a command? max_cmd_len=$max_cmd_len # Object file suffix (normally "o"). objext=$ac_objext # Executable file suffix (normally ""). exeext=$exeext # whether the shell understands "unset". lt_unset=$lt_unset # turn spaces into newlines. SP2NL=$lt_lt_SP2NL # turn newlines into spaces. NL2SP=$lt_lt_NL2SP # convert \$build file names to \$host format. to_host_file_cmd=$lt_cv_to_host_file_cmd # convert \$build files to toolchain format. to_tool_file_cmd=$lt_cv_to_tool_file_cmd # An object symbol dumper. OBJDUMP=$lt_OBJDUMP # Method to check whether dependent libraries are shared objects. deplibs_check_method=$lt_deplibs_check_method # Command to use when deplibs_check_method = "file_magic". file_magic_cmd=$lt_file_magic_cmd # How to find potential files when deplibs_check_method = "file_magic". file_magic_glob=$lt_file_magic_glob # Find potential files using nocaseglob when deplibs_check_method = "file_magic". want_nocaseglob=$lt_want_nocaseglob # DLL creation program. DLLTOOL=$lt_DLLTOOL # Command to associate shared and link libraries. sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd # The archiver. AR=$lt_AR # Flags to create an archive. AR_FLAGS=$lt_AR_FLAGS # How to feed a file listing to the archiver. archiver_list_spec=$lt_archiver_list_spec # A symbol stripping program. STRIP=$lt_STRIP # Commands used to install an old-style archive. RANLIB=$lt_RANLIB old_postinstall_cmds=$lt_old_postinstall_cmds old_postuninstall_cmds=$lt_old_postuninstall_cmds # Whether to use a lock for old archive extraction. lock_old_archive_extraction=$lock_old_archive_extraction # A C compiler. LTCC=$lt_CC # LTCC compiler flags. LTCFLAGS=$lt_CFLAGS # Take the output of nm and produce a listing of raw symbols and C names. global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe # Transform the output of nm in a proper C declaration. global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl # Transform the output of nm into a list of symbols to manually relocate. global_symbol_to_import=$lt_lt_cv_sys_global_symbol_to_import # Transform the output of nm in a C name address pair. global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address # Transform the output of nm in a C name address pair when lib prefix is needed. global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix # The name lister interface. nm_interface=$lt_lt_cv_nm_interface # Specify filename containing input files for \$NM. nm_file_list_spec=$lt_nm_file_list_spec # The root where to search for dependent libraries,and where our libraries should be installed. lt_sysroot=$lt_sysroot # Command to truncate a binary pipe. lt_truncate_bin=$lt_lt_cv_truncate_bin # The name of the directory that contains temporary libtool files. objdir=$objdir # Used to examine libraries when file_magic_cmd begins with "file". MAGIC_CMD=$MAGIC_CMD # Must we lock files when doing compilation? need_locks=$lt_need_locks # Manifest tool. MANIFEST_TOOL=$lt_MANIFEST_TOOL # Tool to manipulate archived DWARF debug symbol files on Mac OS X. DSYMUTIL=$lt_DSYMUTIL # Tool to change global to local symbols on Mac OS X. NMEDIT=$lt_NMEDIT # Tool to manipulate fat objects and archives on Mac OS X. LIPO=$lt_LIPO # ldd/readelf like tool for Mach-O binaries on Mac OS X. OTOOL=$lt_OTOOL # ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4. OTOOL64=$lt_OTOOL64 # Old archive suffix (normally "a"). libext=$libext # Shared library suffix (normally ".so"). shrext_cmds=$lt_shrext_cmds # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds=$lt_extract_expsyms_cmds # Variables whose values should be saved in libtool wrapper scripts and # restored at link time. variables_saved_for_relink=$lt_variables_saved_for_relink # Do we need the "lib" prefix for modules? need_lib_prefix=$need_lib_prefix # Do we need a version for libraries? need_version=$need_version # Library versioning type. version_type=$version_type # Shared library runtime path variable. runpath_var=$runpath_var # Shared library path variable. shlibpath_var=$shlibpath_var # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=$shlibpath_overrides_runpath # Format of library name prefix. libname_spec=$lt_libname_spec # List of archive names. First name is the real one, the rest are links. # The last name is the one that the linker finds with -lNAME library_names_spec=$lt_library_names_spec # The coded name of the library, if different from the real name. soname_spec=$lt_soname_spec # Permission mode override for installation of shared libraries. install_override_mode=$lt_install_override_mode # Command to use after installation of a shared archive. postinstall_cmds=$lt_postinstall_cmds # Command to use after uninstallation of a shared archive. postuninstall_cmds=$lt_postuninstall_cmds # Commands used to finish a libtool library installation in a directory. finish_cmds=$lt_finish_cmds # As "finish_cmds", except a single script fragment to be evaled but # not shown. finish_eval=$lt_finish_eval # Whether we should hardcode library paths into libraries. hardcode_into_libs=$hardcode_into_libs # Compile-time system search path for libraries. sys_lib_search_path_spec=$lt_sys_lib_search_path_spec # Detected run-time system search path for libraries. sys_lib_dlsearch_path_spec=$lt_configure_time_dlsearch_path # Explicit LT_SYS_LIBRARY_PATH set during ./configure time. configure_time_lt_sys_library_path=$lt_configure_time_lt_sys_library_path # Whether dlopen is supported. dlopen_support=$enable_dlopen # Whether dlopen of programs is supported. dlopen_self=$enable_dlopen_self # Whether dlopen of statically linked programs is supported. dlopen_self_static=$enable_dlopen_self_static # Commands to strip libraries. old_striplib=$lt_old_striplib striplib=$lt_striplib # The linker used to build libraries. LD=$lt_LD # How to create reloadable object files. reload_flag=$lt_reload_flag reload_cmds=$lt_reload_cmds # Commands used to build an old-style archive. old_archive_cmds=$lt_old_archive_cmds # A language specific compiler. CC=$lt_compiler # Is the compiler the GNU compiler? with_gcc=$GCC # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag # Additional compiler flags for building library objects. pic_flag=$lt_lt_prog_compiler_pic # How to pass a linker flag through the compiler. wl=$lt_lt_prog_compiler_wl # Compiler flag to prevent dynamic linking. link_static_flag=$lt_lt_prog_compiler_static # Does compiler simultaneously support -c and -o options? compiler_c_o=$lt_lt_cv_prog_compiler_c_o # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=$archive_cmds_need_lc # Whether or not to disallow shared libs when runtime libs are static. allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_export_dynamic_flag_spec # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_whole_archive_flag_spec # Whether the compiler copes with passing no objects directly. compiler_needs_object=$lt_compiler_needs_object # Create an old-style archive from a shared archive. old_archive_from_new_cmds=$lt_old_archive_from_new_cmds # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds # Commands used to build a shared archive. archive_cmds=$lt_archive_cmds archive_expsym_cmds=$lt_archive_expsym_cmds # Commands used to build a loadable module if different from building # a shared archive. module_cmds=$lt_module_cmds module_expsym_cmds=$lt_module_expsym_cmds # Whether we are building with GNU ld or not. with_gnu_ld=$lt_with_gnu_ld # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag=$lt_allow_undefined_flag # Flag that enforces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag # Flag to hardcode \$libdir into a binary during linking. # This must work even if \$libdir does not exist hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec # Whether we need a single "-rpath" flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes # DIR into the resulting binary. hardcode_direct=$hardcode_direct # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes # DIR into the resulting binary and the resulting library dependency is # "absolute",i.e impossible to change by setting \$shlibpath_var if the # library is relocated. hardcode_direct_absolute=$hardcode_direct_absolute # Set to "yes" if using the -LDIR flag during linking hardcodes DIR # into the resulting binary. hardcode_minus_L=$hardcode_minus_L # Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR # into the resulting binary. hardcode_shlibpath_var=$hardcode_shlibpath_var # Set to "yes" if building a shared library automatically hardcodes DIR # into the library and all subsequent libraries and executables linked # against it. hardcode_automatic=$hardcode_automatic # Set to yes if linker adds runtime paths of dependent libraries # to runtime path list. inherit_rpath=$inherit_rpath # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$link_all_deplibs # Set to "yes" if exported symbols are required. always_export_symbols=$always_export_symbols # The commands to list exported symbols. export_symbols_cmds=$lt_export_symbols_cmds # Symbols that should not be listed in the preloaded symbols. exclude_expsyms=$lt_exclude_expsyms # Symbols that must always be exported. include_expsyms=$lt_include_expsyms # Commands necessary for linking programs (against libraries) with templates. prelink_cmds=$lt_prelink_cmds # Commands necessary for finishing linking programs. postlink_cmds=$lt_postlink_cmds # Specify filename containing input files. file_list_spec=$lt_file_list_spec # How to hardcode a shared library path into an executable. hardcode_action=$hardcode_action # The directories searched by this compiler when creating a shared library. compiler_lib_search_dirs=$lt_compiler_lib_search_dirs # Dependencies to place before and after the objects being linked to # create a shared library. predep_objects=$lt_predep_objects postdep_objects=$lt_postdep_objects predeps=$lt_predeps postdeps=$lt_postdeps # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path=$lt_compiler_lib_search_path # ### END LIBTOOL CONFIG _LT_EOF cat <<'_LT_EOF' >> "$cfgfile" # ### BEGIN FUNCTIONS SHARED WITH CONFIGURE # func_munge_path_list VARIABLE PATH # ----------------------------------- # VARIABLE is name of variable containing _space_ separated list of # directories to be munged by the contents of PATH, which is string # having a format: # "DIR[:DIR]:" # string "DIR[ DIR]" will be prepended to VARIABLE # ":DIR[:DIR]" # string "DIR[ DIR]" will be appended to VARIABLE # "DIRP[:DIRP]::[DIRA:]DIRA" # string "DIRP[ DIRP]" will be prepended to VARIABLE and string # "DIRA[ DIRA]" will be appended to VARIABLE # "DIR[:DIR]" # VARIABLE will be replaced by "DIR[ DIR]" func_munge_path_list () { case x$2 in x) ;; *:) eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\" ;; x:*) eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\" ;; *::*) eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\" ;; *) eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\" ;; esac } # Calculate cc_basename. Skip known compiler wrappers and cross-prefix. func_cc_basename () { for cc_temp in $*""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` } # ### END FUNCTIONS SHARED WITH CONFIGURE _LT_EOF case $host_os in aix3*) cat <<\_LT_EOF >> "$cfgfile" # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi _LT_EOF ;; esac ltmain=$ac_aux_dir/ltmain.sh # We use sed instead of cat because bash on DJGPP gets confused if # if finds mixed CR/LF and LF-only lines. Since sed operates in # text mode, it properly converts lines to CR/LF. This bash problem # is reportedly fixed, but why not run on old versions too? sed '$q' "$ltmain" >> "$cfgfile" \ || (rm -f "$cfgfile"; exit 1) mv -f "$cfgfile" "$ofile" || (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") chmod +x "$ofile" cat <<_LT_EOF >> "$ofile" # ### BEGIN LIBTOOL TAG CONFIG: CXX # The linker used to build libraries. LD=$lt_LD_CXX # How to create reloadable object files. reload_flag=$lt_reload_flag_CXX reload_cmds=$lt_reload_cmds_CXX # Commands used to build an old-style archive. old_archive_cmds=$lt_old_archive_cmds_CXX # A language specific compiler. CC=$lt_compiler_CXX # Is the compiler the GNU compiler? with_gcc=$GCC_CXX # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX # Additional compiler flags for building library objects. pic_flag=$lt_lt_prog_compiler_pic_CXX # How to pass a linker flag through the compiler. wl=$lt_lt_prog_compiler_wl_CXX # Compiler flag to prevent dynamic linking. link_static_flag=$lt_lt_prog_compiler_static_CXX # Does compiler simultaneously support -c and -o options? compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=$archive_cmds_need_lc_CXX # Whether or not to disallow shared libs when runtime libs are static. allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX # Whether the compiler copes with passing no objects directly. compiler_needs_object=$lt_compiler_needs_object_CXX # Create an old-style archive from a shared archive. old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX # Commands used to build a shared archive. archive_cmds=$lt_archive_cmds_CXX archive_expsym_cmds=$lt_archive_expsym_cmds_CXX # Commands used to build a loadable module if different from building # a shared archive. module_cmds=$lt_module_cmds_CXX module_expsym_cmds=$lt_module_expsym_cmds_CXX # Whether we are building with GNU ld or not. with_gnu_ld=$lt_with_gnu_ld_CXX # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag=$lt_allow_undefined_flag_CXX # Flag that enforces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag_CXX # Flag to hardcode \$libdir into a binary during linking. # This must work even if \$libdir does not exist hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX # Whether we need a single "-rpath" flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes # DIR into the resulting binary. hardcode_direct=$hardcode_direct_CXX # Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes # DIR into the resulting binary and the resulting library dependency is # "absolute",i.e impossible to change by setting \$shlibpath_var if the # library is relocated. hardcode_direct_absolute=$hardcode_direct_absolute_CXX # Set to "yes" if using the -LDIR flag during linking hardcodes DIR # into the resulting binary. hardcode_minus_L=$hardcode_minus_L_CXX # Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR # into the resulting binary. hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX # Set to "yes" if building a shared library automatically hardcodes DIR # into the library and all subsequent libraries and executables linked # against it. hardcode_automatic=$hardcode_automatic_CXX # Set to yes if linker adds runtime paths of dependent libraries # to runtime path list. inherit_rpath=$inherit_rpath_CXX # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$link_all_deplibs_CXX # Set to "yes" if exported symbols are required. always_export_symbols=$always_export_symbols_CXX # The commands to list exported symbols. export_symbols_cmds=$lt_export_symbols_cmds_CXX # Symbols that should not be listed in the preloaded symbols. exclude_expsyms=$lt_exclude_expsyms_CXX # Symbols that must always be exported. include_expsyms=$lt_include_expsyms_CXX # Commands necessary for linking programs (against libraries) with templates. prelink_cmds=$lt_prelink_cmds_CXX # Commands necessary for finishing linking programs. postlink_cmds=$lt_postlink_cmds_CXX # Specify filename containing input files. file_list_spec=$lt_file_list_spec_CXX # How to hardcode a shared library path into an executable. hardcode_action=$hardcode_action_CXX # The directories searched by this compiler when creating a shared library. compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX # Dependencies to place before and after the objects being linked to # create a shared library. predep_objects=$lt_predep_objects_CXX postdep_objects=$lt_postdep_objects_CXX predeps=$lt_predeps_CXX postdeps=$lt_postdeps_CXX # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path=$lt_compiler_lib_search_path_CXX # ### END LIBTOOL TAG CONFIG: CXX _LT_EOF ;; esac done # for ac_tag as_fn_exit 0 _ACEOF ac_clean_files=$ac_clean_files_save test $ac_write_fail = 0 || as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 # configure is writing to config.log, and then calls config.status. # config.status does its own redirection, appending to config.log. # Unfortunately, on DOS this fails, as config.log is still kept open # by configure, so config.status won't be able to write to it; its # output is simply discarded. So we exec the FD to /dev/null, # effectively closing config.log, so it can be properly (re)opened and # appended to by config.status. When coming back to configure, we # need to make the FD available again. if test "$no_create" != yes; then ac_cs_success=: ac_config_status_args= test "$silent" = yes && ac_config_status_args="$ac_config_status_args --quiet" exec 5>/dev/null $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false exec 5>>config.log # Use ||, not &&, to avoid exiting from the if with $? = 1, which # would make configure fail if this is the last instruction. $ac_cs_success || as_fn_exit 1 fi if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} fi { $as_echo "$as_me:${as_lineno-$LINENO}: libcmis $VERSION: Prefix: ${prefix} Compiler: ${CXX} Compiler flags: ${CXXFLAGS} client: ${enable_client} werror: ${enable_werror} tests: ${enable_tests} test coverage: ${enable_coverage} mans: ${build_man} " >&5 $as_echo "$as_me: libcmis $VERSION: Prefix: ${prefix} Compiler: ${CXX} Compiler flags: ${CXXFLAGS} client: ${enable_client} werror: ${enable_werror} tests: ${enable_tests} test coverage: ${enable_coverage} mans: ${build_man} " >&6;} ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/COPYING.MPL���������������������������������������������������������������������������0000664�0001750�0001750�00000062223�13407173247�011562� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������ MOZILLA PUBLIC LICENSE Version 1.1 --------------- 1. Definitions. 1.0.1. "Commercial Use" means distribution or otherwise making the Covered Code available to a third party. 1.1. "Contributor" means each entity that creates or contributes to the creation of Modifications. 1.2. "Contributor Version" means the combination of the Original Code, prior Modifications used by a Contributor, and the Modifications made by that particular Contributor. 1.3. "Covered Code" means the Original Code or Modifications or the combination of the Original Code and Modifications, in each case including portions thereof. 1.4. "Electronic Distribution Mechanism" means a mechanism generally accepted in the software development community for the electronic transfer of data. 1.5. "Executable" means Covered Code in any form other than Source Code. 1.6. "Initial Developer" means the individual or entity identified as the Initial Developer in the Source Code notice required by Exhibit A. 1.7. "Larger Work" means a work which combines Covered Code or portions thereof with code not governed by the terms of this License. 1.8. "License" means this document. 1.8.1. "Licensable" means having the right to grant, to the maximum extent possible, whether at the time of the initial grant or subsequently acquired, any and all of the rights conveyed herein. 1.9. "Modifications" means any addition to or deletion from the substance or structure of either the Original Code or any previous Modifications. When Covered Code is released as a series of files, a Modification is: A. Any addition to or deletion from the contents of a file containing Original Code or previous Modifications. B. Any new file that contains any part of the Original Code or previous Modifications. 1.10. "Original Code" means Source Code of computer software code which is described in the Source Code notice required by Exhibit A as Original Code, and which, at the time of its release under this License is not already Covered Code governed by this License. 1.10.1. "Patent Claims" means any patent claim(s), now owned or hereafter acquired, including without limitation, method, process, and apparatus claims, in any patent Licensable by grantor. 1.11. "Source Code" means the preferred form of the Covered Code for making modifications to it, including all modules it contains, plus any associated interface definition files, scripts used to control compilation and installation of an Executable, or source code differential comparisons against either the Original Code or another well known, available Covered Code of the Contributor's choice. The Source Code can be in a compressed or archival form, provided the appropriate decompression or de-archiving software is widely available for no charge. 1.12. "You" (or "Your") means an individual or a legal entity exercising rights under, and complying with all of the terms of, this License or a future version of this License issued under Section 6.1. For legal entities, "You" includes any entity which controls, is controlled by, or is under common control with You. For purposes of this definition, "control" means (a) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (b) ownership of more than fifty percent (50%) of the outstanding shares or beneficial ownership of such entity. 2. Source Code License. 2.1. The Initial Developer Grant. The Initial Developer hereby grants You a world-wide, royalty-free, non-exclusive license, subject to third party intellectual property claims: (a) under intellectual property rights (other than patent or trademark) Licensable by Initial Developer to use, reproduce, modify, display, perform, sublicense and distribute the Original Code (or portions thereof) with or without Modifications, and/or as part of a Larger Work; and (b) under Patents Claims infringed by the making, using or selling of Original Code, to make, have made, use, practice, sell, and offer for sale, and/or otherwise dispose of the Original Code (or portions thereof). (c) the licenses granted in this Section 2.1(a) and (b) are effective on the date Initial Developer first distributes Original Code under the terms of this License. (d) Notwithstanding Section 2.1(b) above, no patent license is granted: 1) for code that You delete from the Original Code; 2) separate from the Original Code; or 3) for infringements caused by: i) the modification of the Original Code or ii) the combination of the Original Code with other software or devices. 2.2. Contributor Grant. Subject to third party intellectual property claims, each Contributor hereby grants You a world-wide, royalty-free, non-exclusive license (a) under intellectual property rights (other than patent or trademark) Licensable by Contributor, to use, reproduce, modify, display, perform, sublicense and distribute the Modifications created by such Contributor (or portions thereof) either on an unmodified basis, with other Modifications, as Covered Code and/or as part of a Larger Work; and (b) under Patent Claims infringed by the making, using, or selling of Modifications made by that Contributor either alone and/or in combination with its Contributor Version (or portions of such combination), to make, use, sell, offer for sale, have made, and/or otherwise dispose of: 1) Modifications made by that Contributor (or portions thereof); and 2) the combination of Modifications made by that Contributor with its Contributor Version (or portions of such combination). (c) the licenses granted in Sections 2.2(a) and 2.2(b) are effective on the date Contributor first makes Commercial Use of the Covered Code. (d) Notwithstanding Section 2.2(b) above, no patent license is granted: 1) for any code that Contributor has deleted from the Contributor Version; 2) separate from the Contributor Version; 3) for infringements caused by: i) third party modifications of Contributor Version or ii) the combination of Modifications made by that Contributor with other software (except as part of the Contributor Version) or other devices; or 4) under Patent Claims infringed by Covered Code in the absence of Modifications made by that Contributor. 3. Distribution Obligations. 3.1. Application of License. The Modifications which You create or to which You contribute are governed by the terms of this License, including without limitation Section 2.2. The Source Code version of Covered Code may be distributed only under the terms of this License or a future version of this License released under Section 6.1, and You must include a copy of this License with every copy of the Source Code You distribute. You may not offer or impose any terms on any Source Code version that alters or restricts the applicable version of this License or the recipients' rights hereunder. However, You may include an additional document offering the additional rights described in Section 3.5. 3.2. Availability of Source Code. Any Modification which You create or to which You contribute must be made available in Source Code form under the terms of this License either on the same media as an Executable version or via an accepted Electronic Distribution Mechanism to anyone to whom you made an Executable version available; and if made available via Electronic Distribution Mechanism, must remain available for at least twelve (12) months after the date it initially became available, or at least six (6) months after a subsequent version of that particular Modification has been made available to such recipients. You are responsible for ensuring that the Source Code version remains available even if the Electronic Distribution Mechanism is maintained by a third party. 3.3. Description of Modifications. You must cause all Covered Code to which You contribute to contain a file documenting the changes You made to create that Covered Code and the date of any change. You must include a prominent statement that the Modification is derived, directly or indirectly, from Original Code provided by the Initial Developer and including the name of the Initial Developer in (a) the Source Code, and (b) in any notice in an Executable version or related documentation in which You describe the origin or ownership of the Covered Code. 3.4. Intellectual Property Matters (a) Third Party Claims. If Contributor has knowledge that a license under a third party's intellectual property rights is required to exercise the rights granted by such Contributor under Sections 2.1 or 2.2, Contributor must include a text file with the Source Code distribution titled "LEGAL" which describes the claim and the party making the claim in sufficient detail that a recipient will know whom to contact. If Contributor obtains such knowledge after the Modification is made available as described in Section 3.2, Contributor shall promptly modify the LEGAL file in all copies Contributor makes available thereafter and shall take other steps (such as notifying appropriate mailing lists or newsgroups) reasonably calculated to inform those who received the Covered Code that new knowledge has been obtained. (b) Contributor APIs. If Contributor's Modifications include an application programming interface and Contributor has knowledge of patent licenses which are reasonably necessary to implement that API, Contributor must also include this information in the LEGAL file. (c) Representations. Contributor represents that, except as disclosed pursuant to Section 3.4(a) above, Contributor believes that Contributor's Modifications are Contributor's original creation(s) and/or Contributor has sufficient rights to grant the rights conveyed by this License. 3.5. Required Notices. You must duplicate the notice in Exhibit A in each file of the Source Code. If it is not possible to put such notice in a particular Source Code file due to its structure, then You must include such notice in a location (such as a relevant directory) where a user would be likely to look for such a notice. If You created one or more Modification(s) You may add your name as a Contributor to the notice described in Exhibit A. You must also duplicate this License in any documentation for the Source Code where You describe recipients' rights or ownership rights relating to Covered Code. You may choose to offer, and to charge a fee for, warranty, support, indemnity or liability obligations to one or more recipients of Covered Code. However, You may do so only on Your own behalf, and not on behalf of the Initial Developer or any Contributor. You must make it absolutely clear than any such warranty, support, indemnity or liability obligation is offered by You alone, and You hereby agree to indemnify the Initial Developer and every Contributor for any liability incurred by the Initial Developer or such Contributor as a result of warranty, support, indemnity or liability terms You offer. 3.6. Distribution of Executable Versions. You may distribute Covered Code in Executable form only if the requirements of Section 3.1-3.5 have been met for that Covered Code, and if You include a notice stating that the Source Code version of the Covered Code is available under the terms of this License, including a description of how and where You have fulfilled the obligations of Section 3.2. The notice must be conspicuously included in any notice in an Executable version, related documentation or collateral in which You describe recipients' rights relating to the Covered Code. You may distribute the Executable version of Covered Code or ownership rights under a license of Your choice, which may contain terms different from this License, provided that You are in compliance with the terms of this License and that the license for the Executable version does not attempt to limit or alter the recipient's rights in the Source Code version from the rights set forth in this License. If You distribute the Executable version under a different license You must make it absolutely clear that any terms which differ from this License are offered by You alone, not by the Initial Developer or any Contributor. You hereby agree to indemnify the Initial Developer and every Contributor for any liability incurred by the Initial Developer or such Contributor as a result of any such terms You offer. 3.7. Larger Works. You may create a Larger Work by combining Covered Code with other code not governed by the terms of this License and distribute the Larger Work as a single product. In such a case, You must make sure the requirements of this License are fulfilled for the Covered Code. 4. Inability to Comply Due to Statute or Regulation. If it is impossible for You to comply with any of the terms of this License with respect to some or all of the Covered Code due to statute, judicial order, or regulation then You must: (a) comply with the terms of this License to the maximum extent possible; and (b) describe the limitations and the code they affect. Such description must be included in the LEGAL file described in Section 3.4 and must be included with all distributions of the Source Code. Except to the extent prohibited by statute or regulation, such description must be sufficiently detailed for a recipient of ordinary skill to be able to understand it. 5. Application of this License. This License applies to code to which the Initial Developer has attached the notice in Exhibit A and to related Covered Code. 6. Versions of the License. 6.1. New Versions. BBC Communications Corporation ("Netscape") may publish revised and/or new versions of the License from time to time. Each version will be given a distinguishing version number. 6.2. Effect of New Versions. Once Covered Code has been published under a particular version of the License, You may always continue to use it under the terms of that version. You may also choose to use such Covered Code under the terms of any subsequent version of the License published by BBC. No one other than BBC has the right to modify the terms applicable to Covered Code created under this License. 6.3. Derivative Works. If You create or use a modified version of this License (which you may only do in order to apply it to code which is not already Covered Code governed by this License), You must (a) rename Your license so that the phrases "Mozilla", "MOZILLAPL", "MOZPL", "BBC", "MPL", "NPL" or any confusingly similar phrase do not appear in your license (except to note that your license differs from this License) and (b) otherwise make it clear that Your version of the license contains terms which differ from the Mozilla Public License and BBC Public License. (Filling in the name of the Initial Developer, Original Code or Contributor in the notice described in Exhibit A shall not of themselves be deemed to be modifications of this License.) 7. DISCLAIMER OF WARRANTY. COVERED CODE IS PROVIDED UNDER THIS LICENSE ON AN "AS IS" BASIS, WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, WITHOUT LIMITATION, WARRANTIES THAT THE COVERED CODE IS FREE OF DEFECTS, MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE OR NON-INFRINGING. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE COVERED CODE IS WITH YOU. SHOULD ANY COVERED CODE PROVE DEFECTIVE IN ANY RESPECT, YOU (NOT THE INITIAL DEVELOPER OR ANY OTHER CONTRIBUTOR) ASSUME THE COST OF ANY NECESSARY SERVICING, REPAIR OR CORRECTION. THIS DISCLAIMER OF WARRANTY CONSTITUTES AN ESSENTIAL PART OF THIS LICENSE. NO USE OF ANY COVERED CODE IS AUTHORIZED HEREUNDER EXCEPT UNDER THIS DISCLAIMER. 8. TERMINATION. 8.1. This License and the rights granted hereunder will terminate automatically if You fail to comply with terms herein and fail to cure such breach within 30 days of becoming aware of the breach. All sublicenses to the Covered Code which are properly granted shall survive any termination of this License. Provisions which, by their nature, must remain in effect beyond the termination of this License shall survive. 8.2. If You initiate litigation by asserting a patent infringement claim (excluding declatory judgment actions) against Initial Developer or a Contributor (the Initial Developer or Contributor against whom You file such action is referred to as "Participant") alleging that: (a) such Participant's Contributor Version directly or indirectly infringes any patent, then any and all rights granted by such Participant to You under Sections 2.1 and/or 2.2 of this License shall, upon 60 days notice from Participant terminate prospectively, unless if within 60 days after receipt of notice You either: (i) agree in writing to pay Participant a mutually agreeable reasonable royalty for Your past and future use of Modifications made by such Participant, or (ii) withdraw Your litigation claim with respect to the Contributor Version against such Participant. If within 60 days of notice, a reasonable royalty and payment arrangement are not mutually agreed upon in writing by the parties or the litigation claim is not withdrawn, the rights granted by Participant to You under Sections 2.1 and/or 2.2 automatically terminate at the expiration of the 60 day notice period specified above. (b) any software, hardware, or device, other than such Participant's Contributor Version, directly or indirectly infringes any patent, then any rights granted to You by such Participant under Sections 2.1(b) and 2.2(b) are revoked effective as of the date You first made, used, sold, distributed, or had made, Modifications made by that Participant. 8.3. If You assert a patent infringement claim against Participant alleging that such Participant's Contributor Version directly or indirectly infringes any patent where such claim is resolved (such as by license or settlement) prior to the initiation of patent infringement litigation, then the reasonable value of the licenses granted by such Participant under Sections 2.1 or 2.2 shall be taken into account in determining the amount or value of any payment or license. 8.4. In the event of termination under Sections 8.1 or 8.2 above, all end user license agreements (excluding distributors and resellers) which have been validly granted by You or any distributor hereunder prior to termination shall survive termination. 9. LIMITATION OF LIABILITY. UNDER NO CIRCUMSTANCES AND UNDER NO LEGAL THEORY, WHETHER TORT (INCLUDING NEGLIGENCE), CONTRACT, OR OTHERWISE, SHALL YOU, THE INITIAL DEVELOPER, ANY OTHER CONTRIBUTOR, OR ANY DISTRIBUTOR OF COVERED CODE, OR ANY SUPPLIER OF ANY OF SUCH PARTIES, BE LIABLE TO ANY PERSON FOR ANY INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES OF ANY CHARACTER INCLUDING, WITHOUT LIMITATION, DAMAGES FOR LOSS OF GOODWILL, WORK STOPPAGE, COMPUTER FAILURE OR MALFUNCTION, OR ANY AND ALL OTHER COMMERCIAL DAMAGES OR LOSSES, EVEN IF SUCH PARTY SHALL HAVE BEEN INFORMED OF THE POSSIBILITY OF SUCH DAMAGES. THIS LIMITATION OF LIABILITY SHALL NOT APPLY TO LIABILITY FOR DEATH OR PERSONAL INJURY RESULTING FROM SUCH PARTY'S NEGLIGENCE TO THE EXTENT APPLICABLE LAW PROHIBITS SUCH LIMITATION. SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OR LIMITATION OF INCIDENTAL OR CONSEQUENTIAL DAMAGES, SO THIS EXCLUSION AND LIMITATION MAY NOT APPLY TO YOU. 10. U.S. GOVERNMENT END USERS. The Covered Code is a "commercial item," as that term is defined in 48 C.F.R. 2.101 (Oct. 1995), consisting of "commercial computer software" and "commercial computer software documentation," as such terms are used in 48 C.F.R. 12.212 (Sept. 1995). Consistent with 48 C.F.R. 12.212 and 48 C.F.R. 227.7202-1 through 227.7202-4 (June 1995), all U.S. Government End Users acquire Covered Code with only those rights set forth herein. 11. MISCELLANEOUS. This License represents the complete agreement concerning subject matter hereof. If any provision of this License is held to be unenforceable, such provision shall be reformed only to the extent necessary to make it enforceable. This License shall be governed by California law provisions (except to the extent applicable law, if any, provides otherwise), excluding its conflict-of-law provisions. With respect to disputes in which at least one party is a citizen of, or an entity chartered or registered to do business in the United States of America, any litigation relating to this License shall be subject to the jurisdiction of the Federal Courts of the Northern District of California, with venue lying in Santa Clara County, California, with the losing party responsible for costs, including without limitation, court costs and reasonable attorneys' fees and expenses. The application of the United Nations Convention on Contracts for the International Sale of Goods is expressly excluded. Any law or regulation which provides that the language of a contract shall be construed against the drafter shall not apply to this License. 12. RESPONSIBILITY FOR CLAIMS. As between Initial Developer and the Contributors, each party is responsible for claims and damages arising, directly or indirectly, out of its utilization of rights under this License and You agree to work with Initial Developer and Contributors to distribute such responsibility on an equitable basis. Nothing herein is intended or shall be deemed to constitute any admission of liability. 13. MULTIPLE-LICENSED CODE. Initial Developer may designate portions of the Covered Code as "Multiple-Licensed". "Multiple-Licensed" means that the Initial Developer permits you to utilize portions of the Covered Code under Your choice of the GPL, LGPL, MIT or the alternative licenses, if any, specified by the Initial Developer in the file described in Exhibit A. EXHIBIT A -Mozilla Public License. ``The contents of this file are subject to the Mozilla Public License Version 1.1 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.mozilla.org/MPL/ Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License. The Original Code is ______________________________________. The Initial Developer of the Original Code is ________________________. Portions created by ______________________ are Copyright (C) ______ _______________________. All Rights Reserved. Contributor(s): ______________________________________. Alternatively, the contents of this file may be used under the terms of the _____ license (the "[___] License"), in which case the provisions of [______] License are applicable instead of those above. If you wish to allow use of your version of this file only under the terms of the [____] License and not to allow others to use your version of this file under the MPL, indicate your decision by deleting the provisions above and replace them with the notice and other provisions required by the [___] License. If you do not delete the provisions above, a recipient may use your version of this file under either the MPL or the [___] License." [NOTE: The text of this Exhibit A may differ slightly from the text of the notices in the Source Code files of the Original Code. You should use the text of this Exhibit A rather than the text found in the Original Code Source Code for Your Modifications.] �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/coverage.mk���������������������������������������������������������������������������0000664�0001750�0001750�00000001342�13407173247�012217� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������.PHONY: coverage genlcov coverage-clean coverage: -$(MAKE) $(AM_MAKEFLAGS) -k check $(MAKE) $(AM_MAKEFLAGS) genlcov infos = libcmis-lcov.info libcmis-c-lcov.info $(infos): %-lcov.info: $(LCOV) --directory $(top_builddir)/src/$* \ --base-directory $(top_builddir)/src/$* \ --capture \ --output-file $@ \ --no-external \ --compat-libtool genlcov: $(infos) LANG=C $(GENHTML) --output-directory libcmis-lcov --title "Libcmis Code Coverage" --legend --show-details $^ @echo "file://$(abs_top_builddir)/libcmis-lcov/index.html" coverage-clean: -$(LCOV) --directory $(top_builddir) -z -rm -rf $(infos) libcmis-lcov -find $(top_builddir) -type f -name "*.gcda" -o -name "*.gcno" -o -name "*.gcov" -exec rm "{}" \; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/ltmain.sh�����������������������������������������������������������������������������0000644�0001750�0001750�00001171067�13341246640�011721� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������#! /bin/sh ## DO NOT EDIT - This file generated from ./build-aux/ltmain.in ## by inline-source v2014-01-03.01 # libtool (GNU libtool) 2.4.6 # Provide generalized library-building support services. # Written by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996 # Copyright (C) 1996-2015 Free Software Foundation, Inc. # This is free software; see the source for copying conditions. There is NO # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # GNU Libtool is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # As a special exception to the GNU General Public License, # if you distribute this file as part of a program or library that # is built using GNU Libtool, you may include this file under the # same distribution terms that you use for the rest of that program. # # GNU Libtool is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. PROGRAM=libtool PACKAGE=libtool VERSION=2.4.6 package_revision=2.4.6 ## ------ ## ## Usage. ## ## ------ ## # Run './libtool --help' for help with using this script from the # command line. ## ------------------------------- ## ## User overridable command paths. ## ## ------------------------------- ## # After configure completes, it has a better idea of some of the # shell tools we need than the defaults used by the functions shared # with bootstrap, so set those here where they can still be over- # ridden by the user, but otherwise take precedence. : ${AUTOCONF="autoconf"} : ${AUTOMAKE="automake"} ## -------------------------- ## ## Source external libraries. ## ## -------------------------- ## # Much of our low-level functionality needs to be sourced from external # libraries, which are installed to $pkgauxdir. # Set a version string for this script. scriptversion=2015-01-20.17; # UTC # General shell script boiler plate, and helper functions. # Written by Gary V. Vaughan, 2004 # Copyright (C) 2004-2015 Free Software Foundation, Inc. # This is free software; see the source for copying conditions. There is NO # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # As a special exception to the GNU General Public License, if you distribute # this file as part of a program or library that is built using GNU Libtool, # you may include this file under the same distribution terms that you use # for the rest of that program. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNES FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. # Please report bugs or propose patches to gary@gnu.org. ## ------ ## ## Usage. ## ## ------ ## # Evaluate this file near the top of your script to gain access to # the functions and variables defined here: # # . `echo "$0" | ${SED-sed} 's|[^/]*$||'`/build-aux/funclib.sh # # If you need to override any of the default environment variable # settings, do that before evaluating this file. ## -------------------- ## ## Shell normalisation. ## ## -------------------- ## # Some shells need a little help to be as Bourne compatible as possible. # Before doing anything else, make sure all that help has been provided! DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac fi # NLS nuisances: We save the old values in case they are required later. _G_user_locale= _G_safe_locale= for _G_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES do eval "if test set = \"\${$_G_var+set}\"; then save_$_G_var=\$$_G_var $_G_var=C export $_G_var _G_user_locale=\"$_G_var=\\\$save_\$_G_var; \$_G_user_locale\" _G_safe_locale=\"$_G_var=C; \$_G_safe_locale\" fi" done # CDPATH. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH # Make sure IFS has a sensible default sp=' ' nl=' ' IFS="$sp $nl" # There are apparently some retarded systems that use ';' as a PATH separator! if test "${PATH_SEPARATOR+set}" != set; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || PATH_SEPARATOR=';' } fi ## ------------------------- ## ## Locate command utilities. ## ## ------------------------- ## # func_executable_p FILE # ---------------------- # Check that FILE is an executable regular file. func_executable_p () { test -f "$1" && test -x "$1" } # func_path_progs PROGS_LIST CHECK_FUNC [PATH] # -------------------------------------------- # Search for either a program that responds to --version with output # containing "GNU", or else returned by CHECK_FUNC otherwise, by # trying all the directories in PATH with each of the elements of # PROGS_LIST. # # CHECK_FUNC should accept the path to a candidate program, and # set $func_check_prog_result if it truncates its output less than # $_G_path_prog_max characters. func_path_progs () { _G_progs_list=$1 _G_check_func=$2 _G_PATH=${3-"$PATH"} _G_path_prog_max=0 _G_path_prog_found=false _G_save_IFS=$IFS; IFS=${PATH_SEPARATOR-:} for _G_dir in $_G_PATH; do IFS=$_G_save_IFS test -z "$_G_dir" && _G_dir=. for _G_prog_name in $_G_progs_list; do for _exeext in '' .EXE; do _G_path_prog=$_G_dir/$_G_prog_name$_exeext func_executable_p "$_G_path_prog" || continue case `"$_G_path_prog" --version 2>&1` in *GNU*) func_path_progs_result=$_G_path_prog _G_path_prog_found=: ;; *) $_G_check_func $_G_path_prog func_path_progs_result=$func_check_prog_result ;; esac $_G_path_prog_found && break 3 done done done IFS=$_G_save_IFS test -z "$func_path_progs_result" && { echo "no acceptable sed could be found in \$PATH" >&2 exit 1 } } # We want to be able to use the functions in this file before configure # has figured out where the best binaries are kept, which means we have # to search for them ourselves - except when the results are already set # where we skip the searches. # Unless the user overrides by setting SED, search the path for either GNU # sed, or the sed that truncates its output the least. test -z "$SED" && { _G_sed_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ for _G_i in 1 2 3 4 5 6 7; do _G_sed_script=$_G_sed_script$nl$_G_sed_script done echo "$_G_sed_script" 2>/dev/null | sed 99q >conftest.sed _G_sed_script= func_check_prog_sed () { _G_path_prog=$1 _G_count=0 printf 0123456789 >conftest.in while : do cat conftest.in conftest.in >conftest.tmp mv conftest.tmp conftest.in cp conftest.in conftest.nl echo '' >> conftest.nl "$_G_path_prog" -f conftest.sed <conftest.nl >conftest.out 2>/dev/null || break diff conftest.out conftest.nl >/dev/null 2>&1 || break _G_count=`expr $_G_count + 1` if test "$_G_count" -gt "$_G_path_prog_max"; then # Best one so far, save it but keep looking for a better one func_check_prog_result=$_G_path_prog _G_path_prog_max=$_G_count fi # 10*(2^10) chars as input seems more than enough test 10 -lt "$_G_count" && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out } func_path_progs "sed gsed" func_check_prog_sed $PATH:/usr/xpg4/bin rm -f conftest.sed SED=$func_path_progs_result } # Unless the user overrides by setting GREP, search the path for either GNU # grep, or the grep that truncates its output the least. test -z "$GREP" && { func_check_prog_grep () { _G_path_prog=$1 _G_count=0 _G_path_prog_max=0 printf 0123456789 >conftest.in while : do cat conftest.in conftest.in >conftest.tmp mv conftest.tmp conftest.in cp conftest.in conftest.nl echo 'GREP' >> conftest.nl "$_G_path_prog" -e 'GREP$' -e '-(cannot match)-' <conftest.nl >conftest.out 2>/dev/null || break diff conftest.out conftest.nl >/dev/null 2>&1 || break _G_count=`expr $_G_count + 1` if test "$_G_count" -gt "$_G_path_prog_max"; then # Best one so far, save it but keep looking for a better one func_check_prog_result=$_G_path_prog _G_path_prog_max=$_G_count fi # 10*(2^10) chars as input seems more than enough test 10 -lt "$_G_count" && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out } func_path_progs "grep ggrep" func_check_prog_grep $PATH:/usr/xpg4/bin GREP=$func_path_progs_result } ## ------------------------------- ## ## User overridable command paths. ## ## ------------------------------- ## # All uppercase variable names are used for environment variables. These # variables can be overridden by the user before calling a script that # uses them if a suitable command of that name is not already available # in the command search PATH. : ${CP="cp -f"} : ${ECHO="printf %s\n"} : ${EGREP="$GREP -E"} : ${FGREP="$GREP -F"} : ${LN_S="ln -s"} : ${MAKE="make"} : ${MKDIR="mkdir"} : ${MV="mv -f"} : ${RM="rm -f"} : ${SHELL="${CONFIG_SHELL-/bin/sh}"} ## -------------------- ## ## Useful sed snippets. ## ## -------------------- ## sed_dirname='s|/[^/]*$||' sed_basename='s|^.*/||' # Sed substitution that helps us do robust quoting. It backslashifies # metacharacters that are still active within double-quoted strings. sed_quote_subst='s|\([`"$\\]\)|\\\1|g' # Same as above, but do not quote variable references. sed_double_quote_subst='s/\(["`\\]\)/\\\1/g' # Sed substitution that turns a string into a regex matching for the # string literally. sed_make_literal_regex='s|[].[^$\\*\/]|\\&|g' # Sed substitution that converts a w32 file name or path # that contains forward slashes, into one that contains # (escaped) backslashes. A very naive implementation. sed_naive_backslashify='s|\\\\*|\\|g;s|/|\\|g;s|\\|\\\\|g' # Re-'\' parameter expansions in output of sed_double_quote_subst that # were '\'-ed in input to the same. If an odd number of '\' preceded a # '$' in input to sed_double_quote_subst, that '$' was protected from # expansion. Since each input '\' is now two '\'s, look for any number # of runs of four '\'s followed by two '\'s and then a '$'. '\' that '$'. _G_bs='\\' _G_bs2='\\\\' _G_bs4='\\\\\\\\' _G_dollar='\$' sed_double_backslash="\ s/$_G_bs4/&\\ /g s/^$_G_bs2$_G_dollar/$_G_bs&/ s/\\([^$_G_bs]\\)$_G_bs2$_G_dollar/\\1$_G_bs2$_G_bs$_G_dollar/g s/\n//g" ## ----------------- ## ## Global variables. ## ## ----------------- ## # Except for the global variables explicitly listed below, the following # functions in the '^func_' namespace, and the '^require_' namespace # variables initialised in the 'Resource management' section, sourcing # this file will not pollute your global namespace with anything # else. There's no portable way to scope variables in Bourne shell # though, so actually running these functions will sometimes place # results into a variable named after the function, and often use # temporary variables in the '^_G_' namespace. If you are careful to # avoid using those namespaces casually in your sourcing script, things # should continue to work as you expect. And, of course, you can freely # overwrite any of the functions or variables defined here before # calling anything to customize them. EXIT_SUCCESS=0 EXIT_FAILURE=1 EXIT_MISMATCH=63 # $? = 63 is used to indicate version mismatch to missing. EXIT_SKIP=77 # $? = 77 is used to indicate a skipped test to automake. # Allow overriding, eg assuming that you follow the convention of # putting '$debug_cmd' at the start of all your functions, you can get # bash to show function call trace with: # # debug_cmd='eval echo "${FUNCNAME[0]} $*" >&2' bash your-script-name debug_cmd=${debug_cmd-":"} exit_cmd=: # By convention, finish your script with: # # exit $exit_status # # so that you can set exit_status to non-zero if you want to indicate # something went wrong during execution without actually bailing out at # the point of failure. exit_status=$EXIT_SUCCESS # Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh # is ksh but when the shell is invoked as "sh" and the current value of # the _XPG environment variable is not equal to 1 (one), the special # positional parameter $0, within a function call, is the name of the # function. progpath=$0 # The name of this program. progname=`$ECHO "$progpath" |$SED "$sed_basename"` # Make sure we have an absolute progpath for reexecution: case $progpath in [\\/]*|[A-Za-z]:\\*) ;; *[\\/]*) progdir=`$ECHO "$progpath" |$SED "$sed_dirname"` progdir=`cd "$progdir" && pwd` progpath=$progdir/$progname ;; *) _G_IFS=$IFS IFS=${PATH_SEPARATOR-:} for progdir in $PATH; do IFS=$_G_IFS test -x "$progdir/$progname" && break done IFS=$_G_IFS test -n "$progdir" || progdir=`pwd` progpath=$progdir/$progname ;; esac ## ----------------- ## ## Standard options. ## ## ----------------- ## # The following options affect the operation of the functions defined # below, and should be set appropriately depending on run-time para- # meters passed on the command line. opt_dry_run=false opt_quiet=false opt_verbose=false # Categories 'all' and 'none' are always available. Append any others # you will pass as the first argument to func_warning from your own # code. warning_categories= # By default, display warnings according to 'opt_warning_types'. Set # 'warning_func' to ':' to elide all warnings, or func_fatal_error to # treat the next displayed warning as a fatal error. warning_func=func_warn_and_continue # Set to 'all' to display all warnings, 'none' to suppress all # warnings, or a space delimited list of some subset of # 'warning_categories' to display only the listed warnings. opt_warning_types=all ## -------------------- ## ## Resource management. ## ## -------------------- ## # This section contains definitions for functions that each ensure a # particular resource (a file, or a non-empty configuration variable for # example) is available, and if appropriate to extract default values # from pertinent package files. Call them using their associated # 'require_*' variable to ensure that they are executed, at most, once. # # It's entirely deliberate that calling these functions can set # variables that don't obey the namespace limitations obeyed by the rest # of this file, in order that that they be as useful as possible to # callers. # require_term_colors # ------------------- # Allow display of bold text on terminals that support it. require_term_colors=func_require_term_colors func_require_term_colors () { $debug_cmd test -t 1 && { # COLORTERM and USE_ANSI_COLORS environment variables take # precedence, because most terminfo databases neglect to describe # whether color sequences are supported. test -n "${COLORTERM+set}" && : ${USE_ANSI_COLORS="1"} if test 1 = "$USE_ANSI_COLORS"; then # Standard ANSI escape sequences tc_reset='' tc_bold=''; tc_standout='' tc_red=''; tc_green='' tc_blue=''; tc_cyan='' else # Otherwise trust the terminfo database after all. test -n "`tput sgr0 2>/dev/null`" && { tc_reset=`tput sgr0` test -n "`tput bold 2>/dev/null`" && tc_bold=`tput bold` tc_standout=$tc_bold test -n "`tput smso 2>/dev/null`" && tc_standout=`tput smso` test -n "`tput setaf 1 2>/dev/null`" && tc_red=`tput setaf 1` test -n "`tput setaf 2 2>/dev/null`" && tc_green=`tput setaf 2` test -n "`tput setaf 4 2>/dev/null`" && tc_blue=`tput setaf 4` test -n "`tput setaf 5 2>/dev/null`" && tc_cyan=`tput setaf 5` } fi } require_term_colors=: } ## ----------------- ## ## Function library. ## ## ----------------- ## # This section contains a variety of useful functions to call in your # scripts. Take note of the portable wrappers for features provided by # some modern shells, which will fall back to slower equivalents on # less featureful shells. # func_append VAR VALUE # --------------------- # Append VALUE onto the existing contents of VAR. # We should try to minimise forks, especially on Windows where they are # unreasonably slow, so skip the feature probes when bash or zsh are # being used: if test set = "${BASH_VERSION+set}${ZSH_VERSION+set}"; then : ${_G_HAVE_ARITH_OP="yes"} : ${_G_HAVE_XSI_OPS="yes"} # The += operator was introduced in bash 3.1 case $BASH_VERSION in [12].* | 3.0 | 3.0*) ;; *) : ${_G_HAVE_PLUSEQ_OP="yes"} ;; esac fi # _G_HAVE_PLUSEQ_OP # Can be empty, in which case the shell is probed, "yes" if += is # useable or anything else if it does not work. test -z "$_G_HAVE_PLUSEQ_OP" \ && (eval 'x=a; x+=" b"; test "a b" = "$x"') 2>/dev/null \ && _G_HAVE_PLUSEQ_OP=yes if test yes = "$_G_HAVE_PLUSEQ_OP" then # This is an XSI compatible shell, allowing a faster implementation... eval 'func_append () { $debug_cmd eval "$1+=\$2" }' else # ...otherwise fall back to using expr, which is often a shell builtin. func_append () { $debug_cmd eval "$1=\$$1\$2" } fi # func_append_quoted VAR VALUE # ---------------------------- # Quote VALUE and append to the end of shell variable VAR, separated # by a space. if test yes = "$_G_HAVE_PLUSEQ_OP"; then eval 'func_append_quoted () { $debug_cmd func_quote_for_eval "$2" eval "$1+=\\ \$func_quote_for_eval_result" }' else func_append_quoted () { $debug_cmd func_quote_for_eval "$2" eval "$1=\$$1\\ \$func_quote_for_eval_result" } fi # func_append_uniq VAR VALUE # -------------------------- # Append unique VALUE onto the existing contents of VAR, assuming # entries are delimited by the first character of VALUE. For example: # # func_append_uniq options " --another-option option-argument" # # will only append to $options if " --another-option option-argument " # is not already present somewhere in $options already (note spaces at # each end implied by leading space in second argument). func_append_uniq () { $debug_cmd eval _G_current_value='`$ECHO $'$1'`' _G_delim=`expr "$2" : '\(.\)'` case $_G_delim$_G_current_value$_G_delim in *"$2$_G_delim"*) ;; *) func_append "$@" ;; esac } # func_arith TERM... # ------------------ # Set func_arith_result to the result of evaluating TERMs. test -z "$_G_HAVE_ARITH_OP" \ && (eval 'test 2 = $(( 1 + 1 ))') 2>/dev/null \ && _G_HAVE_ARITH_OP=yes if test yes = "$_G_HAVE_ARITH_OP"; then eval 'func_arith () { $debug_cmd func_arith_result=$(( $* )) }' else func_arith () { $debug_cmd func_arith_result=`expr "$@"` } fi # func_basename FILE # ------------------ # Set func_basename_result to FILE with everything up to and including # the last / stripped. if test yes = "$_G_HAVE_XSI_OPS"; then # If this shell supports suffix pattern removal, then use it to avoid # forking. Hide the definitions single quotes in case the shell chokes # on unsupported syntax... _b='func_basename_result=${1##*/}' _d='case $1 in */*) func_dirname_result=${1%/*}$2 ;; * ) func_dirname_result=$3 ;; esac' else # ...otherwise fall back to using sed. _b='func_basename_result=`$ECHO "$1" |$SED "$sed_basename"`' _d='func_dirname_result=`$ECHO "$1" |$SED "$sed_dirname"` if test "X$func_dirname_result" = "X$1"; then func_dirname_result=$3 else func_append func_dirname_result "$2" fi' fi eval 'func_basename () { $debug_cmd '"$_b"' }' # func_dirname FILE APPEND NONDIR_REPLACEMENT # ------------------------------------------- # Compute the dirname of FILE. If nonempty, add APPEND to the result, # otherwise set result to NONDIR_REPLACEMENT. eval 'func_dirname () { $debug_cmd '"$_d"' }' # func_dirname_and_basename FILE APPEND NONDIR_REPLACEMENT # -------------------------------------------------------- # Perform func_basename and func_dirname in a single function # call: # dirname: Compute the dirname of FILE. If nonempty, # add APPEND to the result, otherwise set result # to NONDIR_REPLACEMENT. # value returned in "$func_dirname_result" # basename: Compute filename of FILE. # value retuned in "$func_basename_result" # For efficiency, we do not delegate to the functions above but instead # duplicate the functionality here. eval 'func_dirname_and_basename () { $debug_cmd '"$_b"' '"$_d"' }' # func_echo ARG... # ---------------- # Echo program name prefixed message. func_echo () { $debug_cmd _G_message=$* func_echo_IFS=$IFS IFS=$nl for _G_line in $_G_message; do IFS=$func_echo_IFS $ECHO "$progname: $_G_line" done IFS=$func_echo_IFS } # func_echo_all ARG... # -------------------- # Invoke $ECHO with all args, space-separated. func_echo_all () { $ECHO "$*" } # func_echo_infix_1 INFIX ARG... # ------------------------------ # Echo program name, followed by INFIX on the first line, with any # additional lines not showing INFIX. func_echo_infix_1 () { $debug_cmd $require_term_colors _G_infix=$1; shift _G_indent=$_G_infix _G_prefix="$progname: $_G_infix: " _G_message=$* # Strip color escape sequences before counting printable length for _G_tc in "$tc_reset" "$tc_bold" "$tc_standout" "$tc_red" "$tc_green" "$tc_blue" "$tc_cyan" do test -n "$_G_tc" && { _G_esc_tc=`$ECHO "$_G_tc" | $SED "$sed_make_literal_regex"` _G_indent=`$ECHO "$_G_indent" | $SED "s|$_G_esc_tc||g"` } done _G_indent="$progname: "`echo "$_G_indent" | $SED 's|.| |g'`" " ## exclude from sc_prohibit_nested_quotes func_echo_infix_1_IFS=$IFS IFS=$nl for _G_line in $_G_message; do IFS=$func_echo_infix_1_IFS $ECHO "$_G_prefix$tc_bold$_G_line$tc_reset" >&2 _G_prefix=$_G_indent done IFS=$func_echo_infix_1_IFS } # func_error ARG... # ----------------- # Echo program name prefixed message to standard error. func_error () { $debug_cmd $require_term_colors func_echo_infix_1 " $tc_standout${tc_red}error$tc_reset" "$*" >&2 } # func_fatal_error ARG... # ----------------------- # Echo program name prefixed message to standard error, and exit. func_fatal_error () { $debug_cmd func_error "$*" exit $EXIT_FAILURE } # func_grep EXPRESSION FILENAME # ----------------------------- # Check whether EXPRESSION matches any line of FILENAME, without output. func_grep () { $debug_cmd $GREP "$1" "$2" >/dev/null 2>&1 } # func_len STRING # --------------- # Set func_len_result to the length of STRING. STRING may not # start with a hyphen. test -z "$_G_HAVE_XSI_OPS" \ && (eval 'x=a/b/c; test 5aa/bb/cc = "${#x}${x%%/*}${x%/*}${x#*/}${x##*/}"') 2>/dev/null \ && _G_HAVE_XSI_OPS=yes if test yes = "$_G_HAVE_XSI_OPS"; then eval 'func_len () { $debug_cmd func_len_result=${#1} }' else func_len () { $debug_cmd func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len` } fi # func_mkdir_p DIRECTORY-PATH # --------------------------- # Make sure the entire path to DIRECTORY-PATH is available. func_mkdir_p () { $debug_cmd _G_directory_path=$1 _G_dir_list= if test -n "$_G_directory_path" && test : != "$opt_dry_run"; then # Protect directory names starting with '-' case $_G_directory_path in -*) _G_directory_path=./$_G_directory_path ;; esac # While some portion of DIR does not yet exist... while test ! -d "$_G_directory_path"; do # ...make a list in topmost first order. Use a colon delimited # list incase some portion of path contains whitespace. _G_dir_list=$_G_directory_path:$_G_dir_list # If the last portion added has no slash in it, the list is done case $_G_directory_path in */*) ;; *) break ;; esac # ...otherwise throw away the child directory and loop _G_directory_path=`$ECHO "$_G_directory_path" | $SED -e "$sed_dirname"` done _G_dir_list=`$ECHO "$_G_dir_list" | $SED 's|:*$||'` func_mkdir_p_IFS=$IFS; IFS=: for _G_dir in $_G_dir_list; do IFS=$func_mkdir_p_IFS # mkdir can fail with a 'File exist' error if two processes # try to create one of the directories concurrently. Don't # stop in that case! $MKDIR "$_G_dir" 2>/dev/null || : done IFS=$func_mkdir_p_IFS # Bail out if we (or some other process) failed to create a directory. test -d "$_G_directory_path" || \ func_fatal_error "Failed to create '$1'" fi } # func_mktempdir [BASENAME] # ------------------------- # Make a temporary directory that won't clash with other running # libtool processes, and avoids race conditions if possible. If # given, BASENAME is the basename for that directory. func_mktempdir () { $debug_cmd _G_template=${TMPDIR-/tmp}/${1-$progname} if test : = "$opt_dry_run"; then # Return a directory name, but don't create it in dry-run mode _G_tmpdir=$_G_template-$$ else # If mktemp works, use that first and foremost _G_tmpdir=`mktemp -d "$_G_template-XXXXXXXX" 2>/dev/null` if test ! -d "$_G_tmpdir"; then # Failing that, at least try and use $RANDOM to avoid a race _G_tmpdir=$_G_template-${RANDOM-0}$$ func_mktempdir_umask=`umask` umask 0077 $MKDIR "$_G_tmpdir" umask $func_mktempdir_umask fi # If we're not in dry-run mode, bomb out on failure test -d "$_G_tmpdir" || \ func_fatal_error "cannot create temporary directory '$_G_tmpdir'" fi $ECHO "$_G_tmpdir" } # func_normal_abspath PATH # ------------------------ # Remove doubled-up and trailing slashes, "." path components, # and cancel out any ".." path components in PATH after making # it an absolute path. func_normal_abspath () { $debug_cmd # These SED scripts presuppose an absolute path with a trailing slash. _G_pathcar='s|^/\([^/]*\).*$|\1|' _G_pathcdr='s|^/[^/]*||' _G_removedotparts=':dotsl s|/\./|/|g t dotsl s|/\.$|/|' _G_collapseslashes='s|/\{1,\}|/|g' _G_finalslash='s|/*$|/|' # Start from root dir and reassemble the path. func_normal_abspath_result= func_normal_abspath_tpath=$1 func_normal_abspath_altnamespace= case $func_normal_abspath_tpath in "") # Empty path, that just means $cwd. func_stripname '' '/' "`pwd`" func_normal_abspath_result=$func_stripname_result return ;; # The next three entries are used to spot a run of precisely # two leading slashes without using negated character classes; # we take advantage of case's first-match behaviour. ///*) # Unusual form of absolute path, do nothing. ;; //*) # Not necessarily an ordinary path; POSIX reserves leading '//' # and for example Cygwin uses it to access remote file shares # over CIFS/SMB, so we conserve a leading double slash if found. func_normal_abspath_altnamespace=/ ;; /*) # Absolute path, do nothing. ;; *) # Relative path, prepend $cwd. func_normal_abspath_tpath=`pwd`/$func_normal_abspath_tpath ;; esac # Cancel out all the simple stuff to save iterations. We also want # the path to end with a slash for ease of parsing, so make sure # there is one (and only one) here. func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ -e "$_G_removedotparts" -e "$_G_collapseslashes" -e "$_G_finalslash"` while :; do # Processed it all yet? if test / = "$func_normal_abspath_tpath"; then # If we ascended to the root using ".." the result may be empty now. if test -z "$func_normal_abspath_result"; then func_normal_abspath_result=/ fi break fi func_normal_abspath_tcomponent=`$ECHO "$func_normal_abspath_tpath" | $SED \ -e "$_G_pathcar"` func_normal_abspath_tpath=`$ECHO "$func_normal_abspath_tpath" | $SED \ -e "$_G_pathcdr"` # Figure out what to do with it case $func_normal_abspath_tcomponent in "") # Trailing empty path component, ignore it. ;; ..) # Parent dir; strip last assembled component from result. func_dirname "$func_normal_abspath_result" func_normal_abspath_result=$func_dirname_result ;; *) # Actual path component, append it. func_append func_normal_abspath_result "/$func_normal_abspath_tcomponent" ;; esac done # Restore leading double-slash if one was found on entry. func_normal_abspath_result=$func_normal_abspath_altnamespace$func_normal_abspath_result } # func_notquiet ARG... # -------------------- # Echo program name prefixed message only when not in quiet mode. func_notquiet () { $debug_cmd $opt_quiet || func_echo ${1+"$@"} # A bug in bash halts the script if the last line of a function # fails when set -e is in force, so we need another command to # work around that: : } # func_relative_path SRCDIR DSTDIR # -------------------------------- # Set func_relative_path_result to the relative path from SRCDIR to DSTDIR. func_relative_path () { $debug_cmd func_relative_path_result= func_normal_abspath "$1" func_relative_path_tlibdir=$func_normal_abspath_result func_normal_abspath "$2" func_relative_path_tbindir=$func_normal_abspath_result # Ascend the tree starting from libdir while :; do # check if we have found a prefix of bindir case $func_relative_path_tbindir in $func_relative_path_tlibdir) # found an exact match func_relative_path_tcancelled= break ;; $func_relative_path_tlibdir*) # found a matching prefix func_stripname "$func_relative_path_tlibdir" '' "$func_relative_path_tbindir" func_relative_path_tcancelled=$func_stripname_result if test -z "$func_relative_path_result"; then func_relative_path_result=. fi break ;; *) func_dirname $func_relative_path_tlibdir func_relative_path_tlibdir=$func_dirname_result if test -z "$func_relative_path_tlibdir"; then # Have to descend all the way to the root! func_relative_path_result=../$func_relative_path_result func_relative_path_tcancelled=$func_relative_path_tbindir break fi func_relative_path_result=../$func_relative_path_result ;; esac done # Now calculate path; take care to avoid doubling-up slashes. func_stripname '' '/' "$func_relative_path_result" func_relative_path_result=$func_stripname_result func_stripname '/' '/' "$func_relative_path_tcancelled" if test -n "$func_stripname_result"; then func_append func_relative_path_result "/$func_stripname_result" fi # Normalisation. If bindir is libdir, return '.' else relative path. if test -n "$func_relative_path_result"; then func_stripname './' '' "$func_relative_path_result" func_relative_path_result=$func_stripname_result fi test -n "$func_relative_path_result" || func_relative_path_result=. : } # func_quote_for_eval ARG... # -------------------------- # Aesthetically quote ARGs to be evaled later. # This function returns two values: # i) func_quote_for_eval_result # double-quoted, suitable for a subsequent eval # ii) func_quote_for_eval_unquoted_result # has all characters that are still active within double # quotes backslashified. func_quote_for_eval () { $debug_cmd func_quote_for_eval_unquoted_result= func_quote_for_eval_result= while test 0 -lt $#; do case $1 in *[\\\`\"\$]*) _G_unquoted_arg=`printf '%s\n' "$1" |$SED "$sed_quote_subst"` ;; *) _G_unquoted_arg=$1 ;; esac if test -n "$func_quote_for_eval_unquoted_result"; then func_append func_quote_for_eval_unquoted_result " $_G_unquoted_arg" else func_append func_quote_for_eval_unquoted_result "$_G_unquoted_arg" fi case $_G_unquoted_arg in # Double-quote args containing shell metacharacters to delay # word splitting, command substitution and variable expansion # for a subsequent eval. # Many Bourne shells cannot handle close brackets correctly # in scan sets, so we specify it separately. *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") _G_quoted_arg=\"$_G_unquoted_arg\" ;; *) _G_quoted_arg=$_G_unquoted_arg ;; esac if test -n "$func_quote_for_eval_result"; then func_append func_quote_for_eval_result " $_G_quoted_arg" else func_append func_quote_for_eval_result "$_G_quoted_arg" fi shift done } # func_quote_for_expand ARG # ------------------------- # Aesthetically quote ARG to be evaled later; same as above, # but do not quote variable references. func_quote_for_expand () { $debug_cmd case $1 in *[\\\`\"]*) _G_arg=`$ECHO "$1" | $SED \ -e "$sed_double_quote_subst" -e "$sed_double_backslash"` ;; *) _G_arg=$1 ;; esac case $_G_arg in # Double-quote args containing shell metacharacters to delay # word splitting and command substitution for a subsequent eval. # Many Bourne shells cannot handle close brackets correctly # in scan sets, so we specify it separately. *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") _G_arg=\"$_G_arg\" ;; esac func_quote_for_expand_result=$_G_arg } # func_stripname PREFIX SUFFIX NAME # --------------------------------- # strip PREFIX and SUFFIX from NAME, and store in func_stripname_result. # PREFIX and SUFFIX must not contain globbing or regex special # characters, hashes, percent signs, but SUFFIX may contain a leading # dot (in which case that matches only a dot). if test yes = "$_G_HAVE_XSI_OPS"; then eval 'func_stripname () { $debug_cmd # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are # positional parameters, so assign one to ordinary variable first. func_stripname_result=$3 func_stripname_result=${func_stripname_result#"$1"} func_stripname_result=${func_stripname_result%"$2"} }' else func_stripname () { $debug_cmd case $2 in .*) func_stripname_result=`$ECHO "$3" | $SED -e "s%^$1%%" -e "s%\\\\$2\$%%"`;; *) func_stripname_result=`$ECHO "$3" | $SED -e "s%^$1%%" -e "s%$2\$%%"`;; esac } fi # func_show_eval CMD [FAIL_EXP] # ----------------------------- # Unless opt_quiet is true, then output CMD. Then, if opt_dryrun is # not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP # is given, then evaluate it. func_show_eval () { $debug_cmd _G_cmd=$1 _G_fail_exp=${2-':'} func_quote_for_expand "$_G_cmd" eval "func_notquiet $func_quote_for_expand_result" $opt_dry_run || { eval "$_G_cmd" _G_status=$? if test 0 -ne "$_G_status"; then eval "(exit $_G_status); $_G_fail_exp" fi } } # func_show_eval_locale CMD [FAIL_EXP] # ------------------------------------ # Unless opt_quiet is true, then output CMD. Then, if opt_dryrun is # not true, evaluate CMD. If the evaluation of CMD fails, and FAIL_EXP # is given, then evaluate it. Use the saved locale for evaluation. func_show_eval_locale () { $debug_cmd _G_cmd=$1 _G_fail_exp=${2-':'} $opt_quiet || { func_quote_for_expand "$_G_cmd" eval "func_echo $func_quote_for_expand_result" } $opt_dry_run || { eval "$_G_user_locale $_G_cmd" _G_status=$? eval "$_G_safe_locale" if test 0 -ne "$_G_status"; then eval "(exit $_G_status); $_G_fail_exp" fi } } # func_tr_sh # ---------- # Turn $1 into a string suitable for a shell variable name. # Result is stored in $func_tr_sh_result. All characters # not in the set a-zA-Z0-9_ are replaced with '_'. Further, # if $1 begins with a digit, a '_' is prepended as well. func_tr_sh () { $debug_cmd case $1 in [0-9]* | *[!a-zA-Z0-9_]*) func_tr_sh_result=`$ECHO "$1" | $SED -e 's/^\([0-9]\)/_\1/' -e 's/[^a-zA-Z0-9_]/_/g'` ;; * ) func_tr_sh_result=$1 ;; esac } # func_verbose ARG... # ------------------- # Echo program name prefixed message in verbose mode only. func_verbose () { $debug_cmd $opt_verbose && func_echo "$*" : } # func_warn_and_continue ARG... # ----------------------------- # Echo program name prefixed warning message to standard error. func_warn_and_continue () { $debug_cmd $require_term_colors func_echo_infix_1 "${tc_red}warning$tc_reset" "$*" >&2 } # func_warning CATEGORY ARG... # ---------------------------- # Echo program name prefixed warning message to standard error. Warning # messages can be filtered according to CATEGORY, where this function # elides messages where CATEGORY is not listed in the global variable # 'opt_warning_types'. func_warning () { $debug_cmd # CATEGORY must be in the warning_categories list! case " $warning_categories " in *" $1 "*) ;; *) func_internal_error "invalid warning category '$1'" ;; esac _G_category=$1 shift case " $opt_warning_types " in *" $_G_category "*) $warning_func ${1+"$@"} ;; esac } # func_sort_ver VER1 VER2 # ----------------------- # 'sort -V' is not generally available. # Note this deviates from the version comparison in automake # in that it treats 1.5 < 1.5.0, and treats 1.4.4a < 1.4-p3a # but this should suffice as we won't be specifying old # version formats or redundant trailing .0 in bootstrap.conf. # If we did want full compatibility then we should probably # use m4_version_compare from autoconf. func_sort_ver () { $debug_cmd printf '%s\n%s\n' "$1" "$2" \ | sort -t. -k 1,1n -k 2,2n -k 3,3n -k 4,4n -k 5,5n -k 6,6n -k 7,7n -k 8,8n -k 9,9n } # func_lt_ver PREV CURR # --------------------- # Return true if PREV and CURR are in the correct order according to # func_sort_ver, otherwise false. Use it like this: # # func_lt_ver "$prev_ver" "$proposed_ver" || func_fatal_error "..." func_lt_ver () { $debug_cmd test "x$1" = x`func_sort_ver "$1" "$2" | $SED 1q` } # Local variables: # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-pattern: "10/scriptversion=%:y-%02m-%02d.%02H; # UTC" # time-stamp-time-zone: "UTC" # End: #! /bin/sh # Set a version string for this script. scriptversion=2014-01-07.03; # UTC # A portable, pluggable option parser for Bourne shell. # Written by Gary V. Vaughan, 2010 # Copyright (C) 2010-2015 Free Software Foundation, Inc. # This is free software; see the source for copying conditions. There is NO # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. # Please report bugs or propose patches to gary@gnu.org. ## ------ ## ## Usage. ## ## ------ ## # This file is a library for parsing options in your shell scripts along # with assorted other useful supporting features that you can make use # of too. # # For the simplest scripts you might need only: # # #!/bin/sh # . relative/path/to/funclib.sh # . relative/path/to/options-parser # scriptversion=1.0 # func_options ${1+"$@"} # eval set dummy "$func_options_result"; shift # ...rest of your script... # # In order for the '--version' option to work, you will need to have a # suitably formatted comment like the one at the top of this file # starting with '# Written by ' and ending with '# warranty; '. # # For '-h' and '--help' to work, you will also need a one line # description of your script's purpose in a comment directly above the # '# Written by ' line, like the one at the top of this file. # # The default options also support '--debug', which will turn on shell # execution tracing (see the comment above debug_cmd below for another # use), and '--verbose' and the func_verbose function to allow your script # to display verbose messages only when your user has specified # '--verbose'. # # After sourcing this file, you can plug processing for additional # options by amending the variables from the 'Configuration' section # below, and following the instructions in the 'Option parsing' # section further down. ## -------------- ## ## Configuration. ## ## -------------- ## # You should override these variables in your script after sourcing this # file so that they reflect the customisations you have added to the # option parser. # The usage line for option parsing errors and the start of '-h' and # '--help' output messages. You can embed shell variables for delayed # expansion at the time the message is displayed, but you will need to # quote other shell meta-characters carefully to prevent them being # expanded when the contents are evaled. usage='$progpath [OPTION]...' # Short help message in response to '-h' and '--help'. Add to this or # override it after sourcing this library to reflect the full set of # options your script accepts. usage_message="\ --debug enable verbose shell tracing -W, --warnings=CATEGORY report the warnings falling in CATEGORY [all] -v, --verbose verbosely report processing --version print version information and exit -h, --help print short or long help message and exit " # Additional text appended to 'usage_message' in response to '--help'. long_help_message=" Warning categories include: 'all' show all warnings 'none' turn off all the warnings 'error' warnings are treated as fatal errors" # Help message printed before fatal option parsing errors. fatal_help="Try '\$progname --help' for more information." ## ------------------------- ## ## Hook function management. ## ## ------------------------- ## # This section contains functions for adding, removing, and running hooks # to the main code. A hook is just a named list of of function, that can # be run in order later on. # func_hookable FUNC_NAME # ----------------------- # Declare that FUNC_NAME will run hooks added with # 'func_add_hook FUNC_NAME ...'. func_hookable () { $debug_cmd func_append hookable_fns " $1" } # func_add_hook FUNC_NAME HOOK_FUNC # --------------------------------- # Request that FUNC_NAME call HOOK_FUNC before it returns. FUNC_NAME must # first have been declared "hookable" by a call to 'func_hookable'. func_add_hook () { $debug_cmd case " $hookable_fns " in *" $1 "*) ;; *) func_fatal_error "'$1' does not accept hook functions." ;; esac eval func_append ${1}_hooks '" $2"' } # func_remove_hook FUNC_NAME HOOK_FUNC # ------------------------------------ # Remove HOOK_FUNC from the list of functions called by FUNC_NAME. func_remove_hook () { $debug_cmd eval ${1}_hooks='`$ECHO "\$'$1'_hooks" |$SED "s| '$2'||"`' } # func_run_hooks FUNC_NAME [ARG]... # --------------------------------- # Run all hook functions registered to FUNC_NAME. # It is assumed that the list of hook functions contains nothing more # than a whitespace-delimited list of legal shell function names, and # no effort is wasted trying to catch shell meta-characters or preserve # whitespace. func_run_hooks () { $debug_cmd case " $hookable_fns " in *" $1 "*) ;; *) func_fatal_error "'$1' does not support hook funcions.n" ;; esac eval _G_hook_fns=\$$1_hooks; shift for _G_hook in $_G_hook_fns; do eval $_G_hook '"$@"' # store returned options list back into positional # parameters for next 'cmd' execution. eval _G_hook_result=\$${_G_hook}_result eval set dummy "$_G_hook_result"; shift done func_quote_for_eval ${1+"$@"} func_run_hooks_result=$func_quote_for_eval_result } ## --------------- ## ## Option parsing. ## ## --------------- ## # In order to add your own option parsing hooks, you must accept the # full positional parameter list in your hook function, remove any # options that you action, and then pass back the remaining unprocessed # options in '<hooked_function_name>_result', escaped suitably for # 'eval'. Like this: # # my_options_prep () # { # $debug_cmd # # # Extend the existing usage message. # usage_message=$usage_message' # -s, --silent don'\''t print informational messages # ' # # func_quote_for_eval ${1+"$@"} # my_options_prep_result=$func_quote_for_eval_result # } # func_add_hook func_options_prep my_options_prep # # # my_silent_option () # { # $debug_cmd # # # Note that for efficiency, we parse as many options as we can # # recognise in a loop before passing the remainder back to the # # caller on the first unrecognised argument we encounter. # while test $# -gt 0; do # opt=$1; shift # case $opt in # --silent|-s) opt_silent=: ;; # # Separate non-argument short options: # -s*) func_split_short_opt "$_G_opt" # set dummy "$func_split_short_opt_name" \ # "-$func_split_short_opt_arg" ${1+"$@"} # shift # ;; # *) set dummy "$_G_opt" "$*"; shift; break ;; # esac # done # # func_quote_for_eval ${1+"$@"} # my_silent_option_result=$func_quote_for_eval_result # } # func_add_hook func_parse_options my_silent_option # # # my_option_validation () # { # $debug_cmd # # $opt_silent && $opt_verbose && func_fatal_help "\ # '--silent' and '--verbose' options are mutually exclusive." # # func_quote_for_eval ${1+"$@"} # my_option_validation_result=$func_quote_for_eval_result # } # func_add_hook func_validate_options my_option_validation # # You'll alse need to manually amend $usage_message to reflect the extra # options you parse. It's preferable to append if you can, so that # multiple option parsing hooks can be added safely. # func_options [ARG]... # --------------------- # All the functions called inside func_options are hookable. See the # individual implementations for details. func_hookable func_options func_options () { $debug_cmd func_options_prep ${1+"$@"} eval func_parse_options \ ${func_options_prep_result+"$func_options_prep_result"} eval func_validate_options \ ${func_parse_options_result+"$func_parse_options_result"} eval func_run_hooks func_options \ ${func_validate_options_result+"$func_validate_options_result"} # save modified positional parameters for caller func_options_result=$func_run_hooks_result } # func_options_prep [ARG]... # -------------------------- # All initialisations required before starting the option parse loop. # Note that when calling hook functions, we pass through the list of # positional parameters. If a hook function modifies that list, and # needs to propogate that back to rest of this script, then the complete # modified list must be put in 'func_run_hooks_result' before # returning. func_hookable func_options_prep func_options_prep () { $debug_cmd # Option defaults: opt_verbose=false opt_warning_types= func_run_hooks func_options_prep ${1+"$@"} # save modified positional parameters for caller func_options_prep_result=$func_run_hooks_result } # func_parse_options [ARG]... # --------------------------- # The main option parsing loop. func_hookable func_parse_options func_parse_options () { $debug_cmd func_parse_options_result= # this just eases exit handling while test $# -gt 0; do # Defer to hook functions for initial option parsing, so they # get priority in the event of reusing an option name. func_run_hooks func_parse_options ${1+"$@"} # Adjust func_parse_options positional parameters to match eval set dummy "$func_run_hooks_result"; shift # Break out of the loop if we already parsed every option. test $# -gt 0 || break _G_opt=$1 shift case $_G_opt in --debug|-x) debug_cmd='set -x' func_echo "enabling shell trace mode" $debug_cmd ;; --no-warnings|--no-warning|--no-warn) set dummy --warnings none ${1+"$@"} shift ;; --warnings|--warning|-W) test $# = 0 && func_missing_arg $_G_opt && break case " $warning_categories $1" in *" $1 "*) # trailing space prevents matching last $1 above func_append_uniq opt_warning_types " $1" ;; *all) opt_warning_types=$warning_categories ;; *none) opt_warning_types=none warning_func=: ;; *error) opt_warning_types=$warning_categories warning_func=func_fatal_error ;; *) func_fatal_error \ "unsupported warning category: '$1'" ;; esac shift ;; --verbose|-v) opt_verbose=: ;; --version) func_version ;; -\?|-h) func_usage ;; --help) func_help ;; # Separate optargs to long options (plugins may need this): --*=*) func_split_equals "$_G_opt" set dummy "$func_split_equals_lhs" \ "$func_split_equals_rhs" ${1+"$@"} shift ;; # Separate optargs to short options: -W*) func_split_short_opt "$_G_opt" set dummy "$func_split_short_opt_name" \ "$func_split_short_opt_arg" ${1+"$@"} shift ;; # Separate non-argument short options: -\?*|-h*|-v*|-x*) func_split_short_opt "$_G_opt" set dummy "$func_split_short_opt_name" \ "-$func_split_short_opt_arg" ${1+"$@"} shift ;; --) break ;; -*) func_fatal_help "unrecognised option: '$_G_opt'" ;; *) set dummy "$_G_opt" ${1+"$@"}; shift; break ;; esac done # save modified positional parameters for caller func_quote_for_eval ${1+"$@"} func_parse_options_result=$func_quote_for_eval_result } # func_validate_options [ARG]... # ------------------------------ # Perform any sanity checks on option settings and/or unconsumed # arguments. func_hookable func_validate_options func_validate_options () { $debug_cmd # Display all warnings if -W was not given. test -n "$opt_warning_types" || opt_warning_types=" $warning_categories" func_run_hooks func_validate_options ${1+"$@"} # Bail if the options were screwed! $exit_cmd $EXIT_FAILURE # save modified positional parameters for caller func_validate_options_result=$func_run_hooks_result } ## ----------------- ## ## Helper functions. ## ## ----------------- ## # This section contains the helper functions used by the rest of the # hookable option parser framework in ascii-betical order. # func_fatal_help ARG... # ---------------------- # Echo program name prefixed message to standard error, followed by # a help hint, and exit. func_fatal_help () { $debug_cmd eval \$ECHO \""Usage: $usage"\" eval \$ECHO \""$fatal_help"\" func_error ${1+"$@"} exit $EXIT_FAILURE } # func_help # --------- # Echo long help message to standard output and exit. func_help () { $debug_cmd func_usage_message $ECHO "$long_help_message" exit 0 } # func_missing_arg ARGNAME # ------------------------ # Echo program name prefixed message to standard error and set global # exit_cmd. func_missing_arg () { $debug_cmd func_error "Missing argument for '$1'." exit_cmd=exit } # func_split_equals STRING # ------------------------ # Set func_split_equals_lhs and func_split_equals_rhs shell variables after # splitting STRING at the '=' sign. test -z "$_G_HAVE_XSI_OPS" \ && (eval 'x=a/b/c; test 5aa/bb/cc = "${#x}${x%%/*}${x%/*}${x#*/}${x##*/}"') 2>/dev/null \ && _G_HAVE_XSI_OPS=yes if test yes = "$_G_HAVE_XSI_OPS" then # This is an XSI compatible shell, allowing a faster implementation... eval 'func_split_equals () { $debug_cmd func_split_equals_lhs=${1%%=*} func_split_equals_rhs=${1#*=} test "x$func_split_equals_lhs" = "x$1" \ && func_split_equals_rhs= }' else # ...otherwise fall back to using expr, which is often a shell builtin. func_split_equals () { $debug_cmd func_split_equals_lhs=`expr "x$1" : 'x\([^=]*\)'` func_split_equals_rhs= test "x$func_split_equals_lhs" = "x$1" \ || func_split_equals_rhs=`expr "x$1" : 'x[^=]*=\(.*\)$'` } fi #func_split_equals # func_split_short_opt SHORTOPT # ----------------------------- # Set func_split_short_opt_name and func_split_short_opt_arg shell # variables after splitting SHORTOPT after the 2nd character. if test yes = "$_G_HAVE_XSI_OPS" then # This is an XSI compatible shell, allowing a faster implementation... eval 'func_split_short_opt () { $debug_cmd func_split_short_opt_arg=${1#??} func_split_short_opt_name=${1%"$func_split_short_opt_arg"} }' else # ...otherwise fall back to using expr, which is often a shell builtin. func_split_short_opt () { $debug_cmd func_split_short_opt_name=`expr "x$1" : 'x-\(.\)'` func_split_short_opt_arg=`expr "x$1" : 'x-.\(.*\)$'` } fi #func_split_short_opt # func_usage # ---------- # Echo short help message to standard output and exit. func_usage () { $debug_cmd func_usage_message $ECHO "Run '$progname --help |${PAGER-more}' for full usage" exit 0 } # func_usage_message # ------------------ # Echo short help message to standard output. func_usage_message () { $debug_cmd eval \$ECHO \""Usage: $usage"\" echo $SED -n 's|^# || /^Written by/{ x;p;x } h /^Written by/q' < "$progpath" echo eval \$ECHO \""$usage_message"\" } # func_version # ------------ # Echo version message to standard output and exit. func_version () { $debug_cmd printf '%s\n' "$progname $scriptversion" $SED -n ' /(C)/!b go :more /\./!{ N s|\n# | | b more } :go /^# Written by /,/# warranty; / { s|^# || s|^# *$|| s|\((C)\)[ 0-9,-]*[ ,-]\([1-9][0-9]* \)|\1 \2| p } /^# Written by / { s|^# || p } /^warranty; /q' < "$progpath" exit $? } # Local variables: # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-pattern: "10/scriptversion=%:y-%02m-%02d.%02H; # UTC" # time-stamp-time-zone: "UTC" # End: # Set a version string. scriptversion='(GNU libtool) 2.4.6' # func_echo ARG... # ---------------- # Libtool also displays the current mode in messages, so override # funclib.sh func_echo with this custom definition. func_echo () { $debug_cmd _G_message=$* func_echo_IFS=$IFS IFS=$nl for _G_line in $_G_message; do IFS=$func_echo_IFS $ECHO "$progname${opt_mode+: $opt_mode}: $_G_line" done IFS=$func_echo_IFS } # func_warning ARG... # ------------------- # Libtool warnings are not categorized, so override funclib.sh # func_warning with this simpler definition. func_warning () { $debug_cmd $warning_func ${1+"$@"} } ## ---------------- ## ## Options parsing. ## ## ---------------- ## # Hook in the functions to make sure our own options are parsed during # the option parsing loop. usage='$progpath [OPTION]... [MODE-ARG]...' # Short help message in response to '-h'. usage_message="Options: --config show all configuration variables --debug enable verbose shell tracing -n, --dry-run display commands without modifying any files --features display basic configuration information and exit --mode=MODE use operation mode MODE --no-warnings equivalent to '-Wnone' --preserve-dup-deps don't remove duplicate dependency libraries --quiet, --silent don't print informational messages --tag=TAG use configuration variables from tag TAG -v, --verbose print more informational messages than default --version print version information -W, --warnings=CATEGORY report the warnings falling in CATEGORY [all] -h, --help, --help-all print short, long, or detailed help message " # Additional text appended to 'usage_message' in response to '--help'. func_help () { $debug_cmd func_usage_message $ECHO "$long_help_message MODE must be one of the following: clean remove files from the build directory compile compile a source file into a libtool object execute automatically set library path, then run a program finish complete the installation of libtool libraries install install libraries or executables link create a library or an executable uninstall remove libraries from an installed directory MODE-ARGS vary depending on the MODE. When passed as first option, '--mode=MODE' may be abbreviated as 'MODE' or a unique abbreviation of that. Try '$progname --help --mode=MODE' for a more detailed description of MODE. When reporting a bug, please describe a test case to reproduce it and include the following information: host-triplet: $host shell: $SHELL compiler: $LTCC compiler flags: $LTCFLAGS linker: $LD (gnu? $with_gnu_ld) version: $progname (GNU libtool) 2.4.6 automake: `($AUTOMAKE --version) 2>/dev/null |$SED 1q` autoconf: `($AUTOCONF --version) 2>/dev/null |$SED 1q` Report bugs to <bug-libtool@gnu.org>. GNU libtool home page: <http://www.gnu.org/software/libtool/>. General help using GNU software: <http://www.gnu.org/gethelp/>." exit 0 } # func_lo2o OBJECT-NAME # --------------------- # Transform OBJECT-NAME from a '.lo' suffix to the platform specific # object suffix. lo2o=s/\\.lo\$/.$objext/ o2lo=s/\\.$objext\$/.lo/ if test yes = "$_G_HAVE_XSI_OPS"; then eval 'func_lo2o () { case $1 in *.lo) func_lo2o_result=${1%.lo}.$objext ;; * ) func_lo2o_result=$1 ;; esac }' # func_xform LIBOBJ-OR-SOURCE # --------------------------- # Transform LIBOBJ-OR-SOURCE from a '.o' or '.c' (or otherwise) # suffix to a '.lo' libtool-object suffix. eval 'func_xform () { func_xform_result=${1%.*}.lo }' else # ...otherwise fall back to using sed. func_lo2o () { func_lo2o_result=`$ECHO "$1" | $SED "$lo2o"` } func_xform () { func_xform_result=`$ECHO "$1" | $SED 's|\.[^.]*$|.lo|'` } fi # func_fatal_configuration ARG... # ------------------------------- # Echo program name prefixed message to standard error, followed by # a configuration failure hint, and exit. func_fatal_configuration () { func_fatal_error ${1+"$@"} \ "See the $PACKAGE documentation for more information." \ "Fatal configuration error." } # func_config # ----------- # Display the configuration for all the tags in this script. func_config () { re_begincf='^# ### BEGIN LIBTOOL' re_endcf='^# ### END LIBTOOL' # Default configuration. $SED "1,/$re_begincf CONFIG/d;/$re_endcf CONFIG/,\$d" < "$progpath" # Now print the configurations for the tags. for tagname in $taglist; do $SED -n "/$re_begincf TAG CONFIG: $tagname\$/,/$re_endcf TAG CONFIG: $tagname\$/p" < "$progpath" done exit $? } # func_features # ------------- # Display the features supported by this script. func_features () { echo "host: $host" if test yes = "$build_libtool_libs"; then echo "enable shared libraries" else echo "disable shared libraries" fi if test yes = "$build_old_libs"; then echo "enable static libraries" else echo "disable static libraries" fi exit $? } # func_enable_tag TAGNAME # ----------------------- # Verify that TAGNAME is valid, and either flag an error and exit, or # enable the TAGNAME tag. We also add TAGNAME to the global $taglist # variable here. func_enable_tag () { # Global variable: tagname=$1 re_begincf="^# ### BEGIN LIBTOOL TAG CONFIG: $tagname\$" re_endcf="^# ### END LIBTOOL TAG CONFIG: $tagname\$" sed_extractcf=/$re_begincf/,/$re_endcf/p # Validate tagname. case $tagname in *[!-_A-Za-z0-9,/]*) func_fatal_error "invalid tag name: $tagname" ;; esac # Don't test for the "default" C tag, as we know it's # there but not specially marked. case $tagname in CC) ;; *) if $GREP "$re_begincf" "$progpath" >/dev/null 2>&1; then taglist="$taglist $tagname" # Evaluate the configuration. Be careful to quote the path # and the sed script, to avoid splitting on whitespace, but # also don't use non-portable quotes within backquotes within # quotes we have to do it in 2 steps: extractedcf=`$SED -n -e "$sed_extractcf" < "$progpath"` eval "$extractedcf" else func_error "ignoring unknown tag $tagname" fi ;; esac } # func_check_version_match # ------------------------ # Ensure that we are using m4 macros, and libtool script from the same # release of libtool. func_check_version_match () { if test "$package_revision" != "$macro_revision"; then if test "$VERSION" != "$macro_version"; then if test -z "$macro_version"; then cat >&2 <<_LT_EOF $progname: Version mismatch error. This is $PACKAGE $VERSION, but the $progname: definition of this LT_INIT comes from an older release. $progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION $progname: and run autoconf again. _LT_EOF else cat >&2 <<_LT_EOF $progname: Version mismatch error. This is $PACKAGE $VERSION, but the $progname: definition of this LT_INIT comes from $PACKAGE $macro_version. $progname: You should recreate aclocal.m4 with macros from $PACKAGE $VERSION $progname: and run autoconf again. _LT_EOF fi else cat >&2 <<_LT_EOF $progname: Version mismatch error. This is $PACKAGE $VERSION, revision $package_revision, $progname: but the definition of this LT_INIT comes from revision $macro_revision. $progname: You should recreate aclocal.m4 with macros from revision $package_revision $progname: of $PACKAGE $VERSION and run autoconf again. _LT_EOF fi exit $EXIT_MISMATCH fi } # libtool_options_prep [ARG]... # ----------------------------- # Preparation for options parsed by libtool. libtool_options_prep () { $debug_mode # Option defaults: opt_config=false opt_dlopen= opt_dry_run=false opt_help=false opt_mode= opt_preserve_dup_deps=false opt_quiet=false nonopt= preserve_args= # Shorthand for --mode=foo, only valid as the first argument case $1 in clean|clea|cle|cl) shift; set dummy --mode clean ${1+"$@"}; shift ;; compile|compil|compi|comp|com|co|c) shift; set dummy --mode compile ${1+"$@"}; shift ;; execute|execut|execu|exec|exe|ex|e) shift; set dummy --mode execute ${1+"$@"}; shift ;; finish|finis|fini|fin|fi|f) shift; set dummy --mode finish ${1+"$@"}; shift ;; install|instal|insta|inst|ins|in|i) shift; set dummy --mode install ${1+"$@"}; shift ;; link|lin|li|l) shift; set dummy --mode link ${1+"$@"}; shift ;; uninstall|uninstal|uninsta|uninst|unins|unin|uni|un|u) shift; set dummy --mode uninstall ${1+"$@"}; shift ;; esac # Pass back the list of options. func_quote_for_eval ${1+"$@"} libtool_options_prep_result=$func_quote_for_eval_result } func_add_hook func_options_prep libtool_options_prep # libtool_parse_options [ARG]... # --------------------------------- # Provide handling for libtool specific options. libtool_parse_options () { $debug_cmd # Perform our own loop to consume as many options as possible in # each iteration. while test $# -gt 0; do _G_opt=$1 shift case $_G_opt in --dry-run|--dryrun|-n) opt_dry_run=: ;; --config) func_config ;; --dlopen|-dlopen) opt_dlopen="${opt_dlopen+$opt_dlopen }$1" shift ;; --preserve-dup-deps) opt_preserve_dup_deps=: ;; --features) func_features ;; --finish) set dummy --mode finish ${1+"$@"}; shift ;; --help) opt_help=: ;; --help-all) opt_help=': help-all' ;; --mode) test $# = 0 && func_missing_arg $_G_opt && break opt_mode=$1 case $1 in # Valid mode arguments: clean|compile|execute|finish|install|link|relink|uninstall) ;; # Catch anything else as an error *) func_error "invalid argument for $_G_opt" exit_cmd=exit break ;; esac shift ;; --no-silent|--no-quiet) opt_quiet=false func_append preserve_args " $_G_opt" ;; --no-warnings|--no-warning|--no-warn) opt_warning=false func_append preserve_args " $_G_opt" ;; --no-verbose) opt_verbose=false func_append preserve_args " $_G_opt" ;; --silent|--quiet) opt_quiet=: opt_verbose=false func_append preserve_args " $_G_opt" ;; --tag) test $# = 0 && func_missing_arg $_G_opt && break opt_tag=$1 func_append preserve_args " $_G_opt $1" func_enable_tag "$1" shift ;; --verbose|-v) opt_quiet=false opt_verbose=: func_append preserve_args " $_G_opt" ;; # An option not handled by this hook function: *) set dummy "$_G_opt" ${1+"$@"}; shift; break ;; esac done # save modified positional parameters for caller func_quote_for_eval ${1+"$@"} libtool_parse_options_result=$func_quote_for_eval_result } func_add_hook func_parse_options libtool_parse_options # libtool_validate_options [ARG]... # --------------------------------- # Perform any sanity checks on option settings and/or unconsumed # arguments. libtool_validate_options () { # save first non-option argument if test 0 -lt $#; then nonopt=$1 shift fi # preserve --debug test : = "$debug_cmd" || func_append preserve_args " --debug" case $host in # Solaris2 added to fix http://debbugs.gnu.org/cgi/bugreport.cgi?bug=16452 # see also: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59788 *cygwin* | *mingw* | *pw32* | *cegcc* | *solaris2* | *os2*) # don't eliminate duplications in $postdeps and $predeps opt_duplicate_compiler_generated_deps=: ;; *) opt_duplicate_compiler_generated_deps=$opt_preserve_dup_deps ;; esac $opt_help || { # Sanity checks first: func_check_version_match test yes != "$build_libtool_libs" \ && test yes != "$build_old_libs" \ && func_fatal_configuration "not configured to build any kind of library" # Darwin sucks eval std_shrext=\"$shrext_cmds\" # Only execute mode is allowed to have -dlopen flags. if test -n "$opt_dlopen" && test execute != "$opt_mode"; then func_error "unrecognized option '-dlopen'" $ECHO "$help" 1>&2 exit $EXIT_FAILURE fi # Change the help message to a mode-specific one. generic_help=$help help="Try '$progname --help --mode=$opt_mode' for more information." } # Pass back the unparsed argument list func_quote_for_eval ${1+"$@"} libtool_validate_options_result=$func_quote_for_eval_result } func_add_hook func_validate_options libtool_validate_options # Process options as early as possible so that --help and --version # can return quickly. func_options ${1+"$@"} eval set dummy "$func_options_result"; shift ## ----------- ## ## Main. ## ## ----------- ## magic='%%%MAGIC variable%%%' magic_exe='%%%MAGIC EXE variable%%%' # Global variables. extracted_archives= extracted_serial=0 # If this variable is set in any of the actions, the command in it # will be execed at the end. This prevents here-documents from being # left over by shells. exec_cmd= # A function that is used when there is no print builtin or printf. func_fallback_echo () { eval 'cat <<_LTECHO_EOF $1 _LTECHO_EOF' } # func_generated_by_libtool # True iff stdin has been generated by Libtool. This function is only # a basic sanity check; it will hardly flush out determined imposters. func_generated_by_libtool_p () { $GREP "^# Generated by .*$PACKAGE" > /dev/null 2>&1 } # func_lalib_p file # True iff FILE is a libtool '.la' library or '.lo' object file. # This function is only a basic sanity check; it will hardly flush out # determined imposters. func_lalib_p () { test -f "$1" && $SED -e 4q "$1" 2>/dev/null | func_generated_by_libtool_p } # func_lalib_unsafe_p file # True iff FILE is a libtool '.la' library or '.lo' object file. # This function implements the same check as func_lalib_p without # resorting to external programs. To this end, it redirects stdin and # closes it afterwards, without saving the original file descriptor. # As a safety measure, use it only where a negative result would be # fatal anyway. Works if 'file' does not exist. func_lalib_unsafe_p () { lalib_p=no if test -f "$1" && test -r "$1" && exec 5<&0 <"$1"; then for lalib_p_l in 1 2 3 4 do read lalib_p_line case $lalib_p_line in \#\ Generated\ by\ *$PACKAGE* ) lalib_p=yes; break;; esac done exec 0<&5 5<&- fi test yes = "$lalib_p" } # func_ltwrapper_script_p file # True iff FILE is a libtool wrapper script # This function is only a basic sanity check; it will hardly flush out # determined imposters. func_ltwrapper_script_p () { test -f "$1" && $lt_truncate_bin < "$1" 2>/dev/null | func_generated_by_libtool_p } # func_ltwrapper_executable_p file # True iff FILE is a libtool wrapper executable # This function is only a basic sanity check; it will hardly flush out # determined imposters. func_ltwrapper_executable_p () { func_ltwrapper_exec_suffix= case $1 in *.exe) ;; *) func_ltwrapper_exec_suffix=.exe ;; esac $GREP "$magic_exe" "$1$func_ltwrapper_exec_suffix" >/dev/null 2>&1 } # func_ltwrapper_scriptname file # Assumes file is an ltwrapper_executable # uses $file to determine the appropriate filename for a # temporary ltwrapper_script. func_ltwrapper_scriptname () { func_dirname_and_basename "$1" "" "." func_stripname '' '.exe' "$func_basename_result" func_ltwrapper_scriptname_result=$func_dirname_result/$objdir/${func_stripname_result}_ltshwrapper } # func_ltwrapper_p file # True iff FILE is a libtool wrapper script or wrapper executable # This function is only a basic sanity check; it will hardly flush out # determined imposters. func_ltwrapper_p () { func_ltwrapper_script_p "$1" || func_ltwrapper_executable_p "$1" } # func_execute_cmds commands fail_cmd # Execute tilde-delimited COMMANDS. # If FAIL_CMD is given, eval that upon failure. # FAIL_CMD may read-access the current command in variable CMD! func_execute_cmds () { $debug_cmd save_ifs=$IFS; IFS='~' for cmd in $1; do IFS=$sp$nl eval cmd=\"$cmd\" IFS=$save_ifs func_show_eval "$cmd" "${2-:}" done IFS=$save_ifs } # func_source file # Source FILE, adding directory component if necessary. # Note that it is not necessary on cygwin/mingw to append a dot to # FILE even if both FILE and FILE.exe exist: automatic-append-.exe # behavior happens only for exec(3), not for open(2)! Also, sourcing # 'FILE.' does not work on cygwin managed mounts. func_source () { $debug_cmd case $1 in */* | *\\*) . "$1" ;; *) . "./$1" ;; esac } # func_resolve_sysroot PATH # Replace a leading = in PATH with a sysroot. Store the result into # func_resolve_sysroot_result func_resolve_sysroot () { func_resolve_sysroot_result=$1 case $func_resolve_sysroot_result in =*) func_stripname '=' '' "$func_resolve_sysroot_result" func_resolve_sysroot_result=$lt_sysroot$func_stripname_result ;; esac } # func_replace_sysroot PATH # If PATH begins with the sysroot, replace it with = and # store the result into func_replace_sysroot_result. func_replace_sysroot () { case $lt_sysroot:$1 in ?*:"$lt_sysroot"*) func_stripname "$lt_sysroot" '' "$1" func_replace_sysroot_result='='$func_stripname_result ;; *) # Including no sysroot. func_replace_sysroot_result=$1 ;; esac } # func_infer_tag arg # Infer tagged configuration to use if any are available and # if one wasn't chosen via the "--tag" command line option. # Only attempt this if the compiler in the base compile # command doesn't match the default compiler. # arg is usually of the form 'gcc ...' func_infer_tag () { $debug_cmd if test -n "$available_tags" && test -z "$tagname"; then CC_quoted= for arg in $CC; do func_append_quoted CC_quoted "$arg" done CC_expanded=`func_echo_all $CC` CC_quoted_expanded=`func_echo_all $CC_quoted` case $@ in # Blanks in the command may have been stripped by the calling shell, # but not from the CC environment variable when configure was run. " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) ;; # Blanks at the start of $base_compile will cause this to fail # if we don't check for them as well. *) for z in $available_tags; do if $GREP "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then # Evaluate the configuration. eval "`$SED -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`" CC_quoted= for arg in $CC; do # Double-quote args containing other shell metacharacters. func_append_quoted CC_quoted "$arg" done CC_expanded=`func_echo_all $CC` CC_quoted_expanded=`func_echo_all $CC_quoted` case "$@ " in " $CC "* | "$CC "* | " $CC_expanded "* | "$CC_expanded "* | \ " $CC_quoted"* | "$CC_quoted "* | " $CC_quoted_expanded "* | "$CC_quoted_expanded "*) # The compiler in the base compile command matches # the one in the tagged configuration. # Assume this is the tagged configuration we want. tagname=$z break ;; esac fi done # If $tagname still isn't set, then no tagged configuration # was found and let the user know that the "--tag" command # line option must be used. if test -z "$tagname"; then func_echo "unable to infer tagged configuration" func_fatal_error "specify a tag with '--tag'" # else # func_verbose "using $tagname tagged configuration" fi ;; esac fi } # func_write_libtool_object output_name pic_name nonpic_name # Create a libtool object file (analogous to a ".la" file), # but don't create it if we're doing a dry run. func_write_libtool_object () { write_libobj=$1 if test yes = "$build_libtool_libs"; then write_lobj=\'$2\' else write_lobj=none fi if test yes = "$build_old_libs"; then write_oldobj=\'$3\' else write_oldobj=none fi $opt_dry_run || { cat >${write_libobj}T <<EOF # $write_libobj - a libtool object file # Generated by $PROGRAM (GNU $PACKAGE) $VERSION # # Please DO NOT delete this file! # It is necessary for linking the library. # Name of the PIC object. pic_object=$write_lobj # Name of the non-PIC object non_pic_object=$write_oldobj EOF $MV "${write_libobj}T" "$write_libobj" } } ################################################## # FILE NAME AND PATH CONVERSION HELPER FUNCTIONS # ################################################## # func_convert_core_file_wine_to_w32 ARG # Helper function used by file name conversion functions when $build is *nix, # and $host is mingw, cygwin, or some other w32 environment. Relies on a # correctly configured wine environment available, with the winepath program # in $build's $PATH. # # ARG is the $build file name to be converted to w32 format. # Result is available in $func_convert_core_file_wine_to_w32_result, and will # be empty on error (or when ARG is empty) func_convert_core_file_wine_to_w32 () { $debug_cmd func_convert_core_file_wine_to_w32_result=$1 if test -n "$1"; then # Unfortunately, winepath does not exit with a non-zero error code, so we # are forced to check the contents of stdout. On the other hand, if the # command is not found, the shell will set an exit code of 127 and print # *an error message* to stdout. So we must check for both error code of # zero AND non-empty stdout, which explains the odd construction: func_convert_core_file_wine_to_w32_tmp=`winepath -w "$1" 2>/dev/null` if test "$?" -eq 0 && test -n "$func_convert_core_file_wine_to_w32_tmp"; then func_convert_core_file_wine_to_w32_result=`$ECHO "$func_convert_core_file_wine_to_w32_tmp" | $SED -e "$sed_naive_backslashify"` else func_convert_core_file_wine_to_w32_result= fi fi } # end: func_convert_core_file_wine_to_w32 # func_convert_core_path_wine_to_w32 ARG # Helper function used by path conversion functions when $build is *nix, and # $host is mingw, cygwin, or some other w32 environment. Relies on a correctly # configured wine environment available, with the winepath program in $build's # $PATH. Assumes ARG has no leading or trailing path separator characters. # # ARG is path to be converted from $build format to win32. # Result is available in $func_convert_core_path_wine_to_w32_result. # Unconvertible file (directory) names in ARG are skipped; if no directory names # are convertible, then the result may be empty. func_convert_core_path_wine_to_w32 () { $debug_cmd # unfortunately, winepath doesn't convert paths, only file names func_convert_core_path_wine_to_w32_result= if test -n "$1"; then oldIFS=$IFS IFS=: for func_convert_core_path_wine_to_w32_f in $1; do IFS=$oldIFS func_convert_core_file_wine_to_w32 "$func_convert_core_path_wine_to_w32_f" if test -n "$func_convert_core_file_wine_to_w32_result"; then if test -z "$func_convert_core_path_wine_to_w32_result"; then func_convert_core_path_wine_to_w32_result=$func_convert_core_file_wine_to_w32_result else func_append func_convert_core_path_wine_to_w32_result ";$func_convert_core_file_wine_to_w32_result" fi fi done IFS=$oldIFS fi } # end: func_convert_core_path_wine_to_w32 # func_cygpath ARGS... # Wrapper around calling the cygpath program via LT_CYGPATH. This is used when # when (1) $build is *nix and Cygwin is hosted via a wine environment; or (2) # $build is MSYS and $host is Cygwin, or (3) $build is Cygwin. In case (1) or # (2), returns the Cygwin file name or path in func_cygpath_result (input # file name or path is assumed to be in w32 format, as previously converted # from $build's *nix or MSYS format). In case (3), returns the w32 file name # or path in func_cygpath_result (input file name or path is assumed to be in # Cygwin format). Returns an empty string on error. # # ARGS are passed to cygpath, with the last one being the file name or path to # be converted. # # Specify the absolute *nix (or w32) name to cygpath in the LT_CYGPATH # environment variable; do not put it in $PATH. func_cygpath () { $debug_cmd if test -n "$LT_CYGPATH" && test -f "$LT_CYGPATH"; then func_cygpath_result=`$LT_CYGPATH "$@" 2>/dev/null` if test "$?" -ne 0; then # on failure, ensure result is empty func_cygpath_result= fi else func_cygpath_result= func_error "LT_CYGPATH is empty or specifies non-existent file: '$LT_CYGPATH'" fi } #end: func_cygpath # func_convert_core_msys_to_w32 ARG # Convert file name or path ARG from MSYS format to w32 format. Return # result in func_convert_core_msys_to_w32_result. func_convert_core_msys_to_w32 () { $debug_cmd # awkward: cmd appends spaces to result func_convert_core_msys_to_w32_result=`( cmd //c echo "$1" ) 2>/dev/null | $SED -e 's/[ ]*$//' -e "$sed_naive_backslashify"` } #end: func_convert_core_msys_to_w32 # func_convert_file_check ARG1 ARG2 # Verify that ARG1 (a file name in $build format) was converted to $host # format in ARG2. Otherwise, emit an error message, but continue (resetting # func_to_host_file_result to ARG1). func_convert_file_check () { $debug_cmd if test -z "$2" && test -n "$1"; then func_error "Could not determine host file name corresponding to" func_error " '$1'" func_error "Continuing, but uninstalled executables may not work." # Fallback: func_to_host_file_result=$1 fi } # end func_convert_file_check # func_convert_path_check FROM_PATHSEP TO_PATHSEP FROM_PATH TO_PATH # Verify that FROM_PATH (a path in $build format) was converted to $host # format in TO_PATH. Otherwise, emit an error message, but continue, resetting # func_to_host_file_result to a simplistic fallback value (see below). func_convert_path_check () { $debug_cmd if test -z "$4" && test -n "$3"; then func_error "Could not determine the host path corresponding to" func_error " '$3'" func_error "Continuing, but uninstalled executables may not work." # Fallback. This is a deliberately simplistic "conversion" and # should not be "improved". See libtool.info. if test "x$1" != "x$2"; then lt_replace_pathsep_chars="s|$1|$2|g" func_to_host_path_result=`echo "$3" | $SED -e "$lt_replace_pathsep_chars"` else func_to_host_path_result=$3 fi fi } # end func_convert_path_check # func_convert_path_front_back_pathsep FRONTPAT BACKPAT REPL ORIG # Modifies func_to_host_path_result by prepending REPL if ORIG matches FRONTPAT # and appending REPL if ORIG matches BACKPAT. func_convert_path_front_back_pathsep () { $debug_cmd case $4 in $1 ) func_to_host_path_result=$3$func_to_host_path_result ;; esac case $4 in $2 ) func_append func_to_host_path_result "$3" ;; esac } # end func_convert_path_front_back_pathsep ################################################## # $build to $host FILE NAME CONVERSION FUNCTIONS # ################################################## # invoked via '$to_host_file_cmd ARG' # # In each case, ARG is the path to be converted from $build to $host format. # Result will be available in $func_to_host_file_result. # func_to_host_file ARG # Converts the file name ARG from $build format to $host format. Return result # in func_to_host_file_result. func_to_host_file () { $debug_cmd $to_host_file_cmd "$1" } # end func_to_host_file # func_to_tool_file ARG LAZY # converts the file name ARG from $build format to toolchain format. Return # result in func_to_tool_file_result. If the conversion in use is listed # in (the comma separated) LAZY, no conversion takes place. func_to_tool_file () { $debug_cmd case ,$2, in *,"$to_tool_file_cmd",*) func_to_tool_file_result=$1 ;; *) $to_tool_file_cmd "$1" func_to_tool_file_result=$func_to_host_file_result ;; esac } # end func_to_tool_file # func_convert_file_noop ARG # Copy ARG to func_to_host_file_result. func_convert_file_noop () { func_to_host_file_result=$1 } # end func_convert_file_noop # func_convert_file_msys_to_w32 ARG # Convert file name ARG from (mingw) MSYS to (mingw) w32 format; automatic # conversion to w32 is not available inside the cwrapper. Returns result in # func_to_host_file_result. func_convert_file_msys_to_w32 () { $debug_cmd func_to_host_file_result=$1 if test -n "$1"; then func_convert_core_msys_to_w32 "$1" func_to_host_file_result=$func_convert_core_msys_to_w32_result fi func_convert_file_check "$1" "$func_to_host_file_result" } # end func_convert_file_msys_to_w32 # func_convert_file_cygwin_to_w32 ARG # Convert file name ARG from Cygwin to w32 format. Returns result in # func_to_host_file_result. func_convert_file_cygwin_to_w32 () { $debug_cmd func_to_host_file_result=$1 if test -n "$1"; then # because $build is cygwin, we call "the" cygpath in $PATH; no need to use # LT_CYGPATH in this case. func_to_host_file_result=`cygpath -m "$1"` fi func_convert_file_check "$1" "$func_to_host_file_result" } # end func_convert_file_cygwin_to_w32 # func_convert_file_nix_to_w32 ARG # Convert file name ARG from *nix to w32 format. Requires a wine environment # and a working winepath. Returns result in func_to_host_file_result. func_convert_file_nix_to_w32 () { $debug_cmd func_to_host_file_result=$1 if test -n "$1"; then func_convert_core_file_wine_to_w32 "$1" func_to_host_file_result=$func_convert_core_file_wine_to_w32_result fi func_convert_file_check "$1" "$func_to_host_file_result" } # end func_convert_file_nix_to_w32 # func_convert_file_msys_to_cygwin ARG # Convert file name ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. # Returns result in func_to_host_file_result. func_convert_file_msys_to_cygwin () { $debug_cmd func_to_host_file_result=$1 if test -n "$1"; then func_convert_core_msys_to_w32 "$1" func_cygpath -u "$func_convert_core_msys_to_w32_result" func_to_host_file_result=$func_cygpath_result fi func_convert_file_check "$1" "$func_to_host_file_result" } # end func_convert_file_msys_to_cygwin # func_convert_file_nix_to_cygwin ARG # Convert file name ARG from *nix to Cygwin format. Requires Cygwin installed # in a wine environment, working winepath, and LT_CYGPATH set. Returns result # in func_to_host_file_result. func_convert_file_nix_to_cygwin () { $debug_cmd func_to_host_file_result=$1 if test -n "$1"; then # convert from *nix to w32, then use cygpath to convert from w32 to cygwin. func_convert_core_file_wine_to_w32 "$1" func_cygpath -u "$func_convert_core_file_wine_to_w32_result" func_to_host_file_result=$func_cygpath_result fi func_convert_file_check "$1" "$func_to_host_file_result" } # end func_convert_file_nix_to_cygwin ############################################# # $build to $host PATH CONVERSION FUNCTIONS # ############################################# # invoked via '$to_host_path_cmd ARG' # # In each case, ARG is the path to be converted from $build to $host format. # The result will be available in $func_to_host_path_result. # # Path separators are also converted from $build format to $host format. If # ARG begins or ends with a path separator character, it is preserved (but # converted to $host format) on output. # # All path conversion functions are named using the following convention: # file name conversion function : func_convert_file_X_to_Y () # path conversion function : func_convert_path_X_to_Y () # where, for any given $build/$host combination the 'X_to_Y' value is the # same. If conversion functions are added for new $build/$host combinations, # the two new functions must follow this pattern, or func_init_to_host_path_cmd # will break. # func_init_to_host_path_cmd # Ensures that function "pointer" variable $to_host_path_cmd is set to the # appropriate value, based on the value of $to_host_file_cmd. to_host_path_cmd= func_init_to_host_path_cmd () { $debug_cmd if test -z "$to_host_path_cmd"; then func_stripname 'func_convert_file_' '' "$to_host_file_cmd" to_host_path_cmd=func_convert_path_$func_stripname_result fi } # func_to_host_path ARG # Converts the path ARG from $build format to $host format. Return result # in func_to_host_path_result. func_to_host_path () { $debug_cmd func_init_to_host_path_cmd $to_host_path_cmd "$1" } # end func_to_host_path # func_convert_path_noop ARG # Copy ARG to func_to_host_path_result. func_convert_path_noop () { func_to_host_path_result=$1 } # end func_convert_path_noop # func_convert_path_msys_to_w32 ARG # Convert path ARG from (mingw) MSYS to (mingw) w32 format; automatic # conversion to w32 is not available inside the cwrapper. Returns result in # func_to_host_path_result. func_convert_path_msys_to_w32 () { $debug_cmd func_to_host_path_result=$1 if test -n "$1"; then # Remove leading and trailing path separator characters from ARG. MSYS # behavior is inconsistent here; cygpath turns them into '.;' and ';.'; # and winepath ignores them completely. func_stripname : : "$1" func_to_host_path_tmp1=$func_stripname_result func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" func_to_host_path_result=$func_convert_core_msys_to_w32_result func_convert_path_check : ";" \ "$func_to_host_path_tmp1" "$func_to_host_path_result" func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" fi } # end func_convert_path_msys_to_w32 # func_convert_path_cygwin_to_w32 ARG # Convert path ARG from Cygwin to w32 format. Returns result in # func_to_host_file_result. func_convert_path_cygwin_to_w32 () { $debug_cmd func_to_host_path_result=$1 if test -n "$1"; then # See func_convert_path_msys_to_w32: func_stripname : : "$1" func_to_host_path_tmp1=$func_stripname_result func_to_host_path_result=`cygpath -m -p "$func_to_host_path_tmp1"` func_convert_path_check : ";" \ "$func_to_host_path_tmp1" "$func_to_host_path_result" func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" fi } # end func_convert_path_cygwin_to_w32 # func_convert_path_nix_to_w32 ARG # Convert path ARG from *nix to w32 format. Requires a wine environment and # a working winepath. Returns result in func_to_host_file_result. func_convert_path_nix_to_w32 () { $debug_cmd func_to_host_path_result=$1 if test -n "$1"; then # See func_convert_path_msys_to_w32: func_stripname : : "$1" func_to_host_path_tmp1=$func_stripname_result func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" func_to_host_path_result=$func_convert_core_path_wine_to_w32_result func_convert_path_check : ";" \ "$func_to_host_path_tmp1" "$func_to_host_path_result" func_convert_path_front_back_pathsep ":*" "*:" ";" "$1" fi } # end func_convert_path_nix_to_w32 # func_convert_path_msys_to_cygwin ARG # Convert path ARG from MSYS to Cygwin format. Requires LT_CYGPATH set. # Returns result in func_to_host_file_result. func_convert_path_msys_to_cygwin () { $debug_cmd func_to_host_path_result=$1 if test -n "$1"; then # See func_convert_path_msys_to_w32: func_stripname : : "$1" func_to_host_path_tmp1=$func_stripname_result func_convert_core_msys_to_w32 "$func_to_host_path_tmp1" func_cygpath -u -p "$func_convert_core_msys_to_w32_result" func_to_host_path_result=$func_cygpath_result func_convert_path_check : : \ "$func_to_host_path_tmp1" "$func_to_host_path_result" func_convert_path_front_back_pathsep ":*" "*:" : "$1" fi } # end func_convert_path_msys_to_cygwin # func_convert_path_nix_to_cygwin ARG # Convert path ARG from *nix to Cygwin format. Requires Cygwin installed in a # a wine environment, working winepath, and LT_CYGPATH set. Returns result in # func_to_host_file_result. func_convert_path_nix_to_cygwin () { $debug_cmd func_to_host_path_result=$1 if test -n "$1"; then # Remove leading and trailing path separator characters from # ARG. msys behavior is inconsistent here, cygpath turns them # into '.;' and ';.', and winepath ignores them completely. func_stripname : : "$1" func_to_host_path_tmp1=$func_stripname_result func_convert_core_path_wine_to_w32 "$func_to_host_path_tmp1" func_cygpath -u -p "$func_convert_core_path_wine_to_w32_result" func_to_host_path_result=$func_cygpath_result func_convert_path_check : : \ "$func_to_host_path_tmp1" "$func_to_host_path_result" func_convert_path_front_back_pathsep ":*" "*:" : "$1" fi } # end func_convert_path_nix_to_cygwin # func_dll_def_p FILE # True iff FILE is a Windows DLL '.def' file. # Keep in sync with _LT_DLL_DEF_P in libtool.m4 func_dll_def_p () { $debug_cmd func_dll_def_p_tmp=`$SED -n \ -e 's/^[ ]*//' \ -e '/^\(;.*\)*$/d' \ -e 's/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p' \ -e q \ "$1"` test DEF = "$func_dll_def_p_tmp" } # func_mode_compile arg... func_mode_compile () { $debug_cmd # Get the compilation command and the source file. base_compile= srcfile=$nonopt # always keep a non-empty value in "srcfile" suppress_opt=yes suppress_output= arg_mode=normal libobj= later= pie_flag= for arg do case $arg_mode in arg ) # do not "continue". Instead, add this to base_compile lastarg=$arg arg_mode=normal ;; target ) libobj=$arg arg_mode=normal continue ;; normal ) # Accept any command-line options. case $arg in -o) test -n "$libobj" && \ func_fatal_error "you cannot specify '-o' more than once" arg_mode=target continue ;; -pie | -fpie | -fPIE) func_append pie_flag " $arg" continue ;; -shared | -static | -prefer-pic | -prefer-non-pic) func_append later " $arg" continue ;; -no-suppress) suppress_opt=no continue ;; -Xcompiler) arg_mode=arg # the next one goes into the "base_compile" arg list continue # The current "srcfile" will either be retained or ;; # replaced later. I would guess that would be a bug. -Wc,*) func_stripname '-Wc,' '' "$arg" args=$func_stripname_result lastarg= save_ifs=$IFS; IFS=, for arg in $args; do IFS=$save_ifs func_append_quoted lastarg "$arg" done IFS=$save_ifs func_stripname ' ' '' "$lastarg" lastarg=$func_stripname_result # Add the arguments to base_compile. func_append base_compile " $lastarg" continue ;; *) # Accept the current argument as the source file. # The previous "srcfile" becomes the current argument. # lastarg=$srcfile srcfile=$arg ;; esac # case $arg ;; esac # case $arg_mode # Aesthetically quote the previous argument. func_append_quoted base_compile "$lastarg" done # for arg case $arg_mode in arg) func_fatal_error "you must specify an argument for -Xcompile" ;; target) func_fatal_error "you must specify a target with '-o'" ;; *) # Get the name of the library object. test -z "$libobj" && { func_basename "$srcfile" libobj=$func_basename_result } ;; esac # Recognize several different file suffixes. # If the user specifies -o file.o, it is replaced with file.lo case $libobj in *.[cCFSifmso] | \ *.ada | *.adb | *.ads | *.asm | \ *.c++ | *.cc | *.ii | *.class | *.cpp | *.cxx | \ *.[fF][09]? | *.for | *.java | *.go | *.obj | *.sx | *.cu | *.cup) func_xform "$libobj" libobj=$func_xform_result ;; esac case $libobj in *.lo) func_lo2o "$libobj"; obj=$func_lo2o_result ;; *) func_fatal_error "cannot determine name of library object from '$libobj'" ;; esac func_infer_tag $base_compile for arg in $later; do case $arg in -shared) test yes = "$build_libtool_libs" \ || func_fatal_configuration "cannot build a shared library" build_old_libs=no continue ;; -static) build_libtool_libs=no build_old_libs=yes continue ;; -prefer-pic) pic_mode=yes continue ;; -prefer-non-pic) pic_mode=no continue ;; esac done func_quote_for_eval "$libobj" test "X$libobj" != "X$func_quote_for_eval_result" \ && $ECHO "X$libobj" | $GREP '[]~#^*{};<>?"'"'"' &()|`$[]' \ && func_warning "libobj name '$libobj' may not contain shell special characters." func_dirname_and_basename "$obj" "/" "" objname=$func_basename_result xdir=$func_dirname_result lobj=$xdir$objdir/$objname test -z "$base_compile" && \ func_fatal_help "you must specify a compilation command" # Delete any leftover library objects. if test yes = "$build_old_libs"; then removelist="$obj $lobj $libobj ${libobj}T" else removelist="$lobj $libobj ${libobj}T" fi # On Cygwin there's no "real" PIC flag so we must build both object types case $host_os in cygwin* | mingw* | pw32* | os2* | cegcc*) pic_mode=default ;; esac if test no = "$pic_mode" && test pass_all != "$deplibs_check_method"; then # non-PIC code in shared libraries is not supported pic_mode=default fi # Calculate the filename of the output object if compiler does # not support -o with -c if test no = "$compiler_c_o"; then output_obj=`$ECHO "$srcfile" | $SED 's%^.*/%%; s%\.[^.]*$%%'`.$objext lockfile=$output_obj.lock else output_obj= need_locks=no lockfile= fi # Lock this critical section if it is needed # We use this script file to make the link, it avoids creating a new file if test yes = "$need_locks"; then until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do func_echo "Waiting for $lockfile to be removed" sleep 2 done elif test warn = "$need_locks"; then if test -f "$lockfile"; then $ECHO "\ *** ERROR, $lockfile exists and contains: `cat $lockfile 2>/dev/null` This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support '-c' and '-o' together. If you repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." $opt_dry_run || $RM $removelist exit $EXIT_FAILURE fi func_append removelist " $output_obj" $ECHO "$srcfile" > "$lockfile" fi $opt_dry_run || $RM $removelist func_append removelist " $lockfile" trap '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' 1 2 15 func_to_tool_file "$srcfile" func_convert_file_msys_to_w32 srcfile=$func_to_tool_file_result func_quote_for_eval "$srcfile" qsrcfile=$func_quote_for_eval_result # Only build a PIC object if we are building libtool libraries. if test yes = "$build_libtool_libs"; then # Without this assignment, base_compile gets emptied. fbsd_hideous_sh_bug=$base_compile if test no != "$pic_mode"; then command="$base_compile $qsrcfile $pic_flag" else # Don't build PIC code command="$base_compile $qsrcfile" fi func_mkdir_p "$xdir$objdir" if test -z "$output_obj"; then # Place PIC objects in $objdir func_append command " -o $lobj" fi func_show_eval_locale "$command" \ 'test -n "$output_obj" && $RM $removelist; exit $EXIT_FAILURE' if test warn = "$need_locks" && test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then $ECHO "\ *** ERROR, $lockfile contains: `cat $lockfile 2>/dev/null` but it should contain: $srcfile This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support '-c' and '-o' together. If you repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." $opt_dry_run || $RM $removelist exit $EXIT_FAILURE fi # Just move the object if needed, then go on to compile the next one if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then func_show_eval '$MV "$output_obj" "$lobj"' \ 'error=$?; $opt_dry_run || $RM $removelist; exit $error' fi # Allow error messages only from the first compilation. if test yes = "$suppress_opt"; then suppress_output=' >/dev/null 2>&1' fi fi # Only build a position-dependent object if we build old libraries. if test yes = "$build_old_libs"; then if test yes != "$pic_mode"; then # Don't build PIC code command="$base_compile $qsrcfile$pie_flag" else command="$base_compile $qsrcfile $pic_flag" fi if test yes = "$compiler_c_o"; then func_append command " -o $obj" fi # Suppress compiler output if we already did a PIC compilation. func_append command "$suppress_output" func_show_eval_locale "$command" \ '$opt_dry_run || $RM $removelist; exit $EXIT_FAILURE' if test warn = "$need_locks" && test "X`cat $lockfile 2>/dev/null`" != "X$srcfile"; then $ECHO "\ *** ERROR, $lockfile contains: `cat $lockfile 2>/dev/null` but it should contain: $srcfile This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support '-c' and '-o' together. If you repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." $opt_dry_run || $RM $removelist exit $EXIT_FAILURE fi # Just move the object if needed if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then func_show_eval '$MV "$output_obj" "$obj"' \ 'error=$?; $opt_dry_run || $RM $removelist; exit $error' fi fi $opt_dry_run || { func_write_libtool_object "$libobj" "$objdir/$objname" "$objname" # Unlock the critical section if it was locked if test no != "$need_locks"; then removelist=$lockfile $RM "$lockfile" fi } exit $EXIT_SUCCESS } $opt_help || { test compile = "$opt_mode" && func_mode_compile ${1+"$@"} } func_mode_help () { # We need to display help for each of the modes. case $opt_mode in "") # Generic help is extracted from the usage comments # at the start of this file. func_help ;; clean) $ECHO \ "Usage: $progname [OPTION]... --mode=clean RM [RM-OPTION]... FILE... Remove files from the build directory. RM is the name of the program to use to delete files associated with each FILE (typically '/bin/rm'). RM-OPTIONS are options (such as '-f') to be passed to RM. If FILE is a libtool library, object or program, all the files associated with it are deleted. Otherwise, only FILE itself is deleted using RM." ;; compile) $ECHO \ "Usage: $progname [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE Compile a source file into a libtool library object. This mode accepts the following additional options: -o OUTPUT-FILE set the output file name to OUTPUT-FILE -no-suppress do not suppress compiler output for multiple passes -prefer-pic try to build PIC objects only -prefer-non-pic try to build non-PIC objects only -shared do not build a '.o' file suitable for static linking -static only build a '.o' file suitable for static linking -Wc,FLAG pass FLAG directly to the compiler COMPILE-COMMAND is a command to be used in creating a 'standard' object file from the given SOURCEFILE. The output file name is determined by removing the directory component from SOURCEFILE, then substituting the C source code suffix '.c' with the library object suffix, '.lo'." ;; execute) $ECHO \ "Usage: $progname [OPTION]... --mode=execute COMMAND [ARGS]... Automatically set library path, then run a program. This mode accepts the following additional options: -dlopen FILE add the directory containing FILE to the library path This mode sets the library path environment variable according to '-dlopen' flags. If any of the ARGS are libtool executable wrappers, then they are translated into their corresponding uninstalled binary, and any of their required library directories are added to the library path. Then, COMMAND is executed, with ARGS as arguments." ;; finish) $ECHO \ "Usage: $progname [OPTION]... --mode=finish [LIBDIR]... Complete the installation of libtool libraries. Each LIBDIR is a directory that contains libtool libraries. The commands that this mode executes may require superuser privileges. Use the '--dry-run' option if you just want to see what would be executed." ;; install) $ECHO \ "Usage: $progname [OPTION]... --mode=install INSTALL-COMMAND... Install executables or libraries. INSTALL-COMMAND is the installation command. The first component should be either the 'install' or 'cp' program. The following components of INSTALL-COMMAND are treated specially: -inst-prefix-dir PREFIX-DIR Use PREFIX-DIR as a staging area for installation The rest of the components are interpreted as arguments to that command (only BSD-compatible install options are recognized)." ;; link) $ECHO \ "Usage: $progname [OPTION]... --mode=link LINK-COMMAND... Link object files or libraries together to form another library, or to create an executable program. LINK-COMMAND is a command using the C compiler that you would use to create a program from several object files. The following components of LINK-COMMAND are treated specially: -all-static do not do any dynamic linking at all -avoid-version do not add a version suffix if possible -bindir BINDIR specify path to binaries directory (for systems where libraries must be found in the PATH setting at runtime) -dlopen FILE '-dlpreopen' FILE if it cannot be dlopened at runtime -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3) -export-symbols SYMFILE try to export only the symbols listed in SYMFILE -export-symbols-regex REGEX try to export only the symbols matching REGEX -LLIBDIR search LIBDIR for required installed libraries -lNAME OUTPUT-FILE requires the installed library libNAME -module build a library that can dlopened -no-fast-install disable the fast-install mode -no-install link a not-installable executable -no-undefined declare that a library does not refer to external symbols -o OUTPUT-FILE create OUTPUT-FILE from the specified objects -objectlist FILE use a list of object files found in FILE to specify objects -os2dllname NAME force a short DLL name on OS/2 (no effect on other OSes) -precious-files-regex REGEX don't remove output files matching REGEX -release RELEASE specify package release information -rpath LIBDIR the created library will eventually be installed in LIBDIR -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries -shared only do dynamic linking of libtool libraries -shrext SUFFIX override the standard shared library file extension -static do not do any dynamic linking of uninstalled libtool libraries -static-libtool-libs do not do any dynamic linking of libtool libraries -version-info CURRENT[:REVISION[:AGE]] specify library version info [each variable defaults to 0] -weak LIBNAME declare that the target provides the LIBNAME interface -Wc,FLAG -Xcompiler FLAG pass linker-specific FLAG directly to the compiler -Wl,FLAG -Xlinker FLAG pass linker-specific FLAG directly to the linker -XCClinker FLAG pass link-specific FLAG to the compiler driver (CC) All other options (arguments beginning with '-') are ignored. Every other argument is treated as a filename. Files ending in '.la' are treated as uninstalled libtool libraries, other files are standard or library object files. If the OUTPUT-FILE ends in '.la', then a libtool library is created, only library objects ('.lo' files) may be specified, and '-rpath' is required, except when creating a convenience library. If OUTPUT-FILE ends in '.a' or '.lib', then a standard library is created using 'ar' and 'ranlib', or on Windows using 'lib'. If OUTPUT-FILE ends in '.lo' or '.$objext', then a reloadable object file is created, otherwise an executable program is created." ;; uninstall) $ECHO \ "Usage: $progname [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE... Remove libraries from an installation directory. RM is the name of the program to use to delete files associated with each FILE (typically '/bin/rm'). RM-OPTIONS are options (such as '-f') to be passed to RM. If FILE is a libtool library, all the files associated with it are deleted. Otherwise, only FILE itself is deleted using RM." ;; *) func_fatal_help "invalid operation mode '$opt_mode'" ;; esac echo $ECHO "Try '$progname --help' for more information about other modes." } # Now that we've collected a possible --mode arg, show help if necessary if $opt_help; then if test : = "$opt_help"; then func_mode_help else { func_help noexit for opt_mode in compile link execute install finish uninstall clean; do func_mode_help done } | $SED -n '1p; 2,$s/^Usage:/ or: /p' { func_help noexit for opt_mode in compile link execute install finish uninstall clean; do echo func_mode_help done } | $SED '1d /^When reporting/,/^Report/{ H d } $x /information about other modes/d /more detailed .*MODE/d s/^Usage:.*--mode=\([^ ]*\) .*/Description of \1 mode:/' fi exit $? fi # func_mode_execute arg... func_mode_execute () { $debug_cmd # The first argument is the command name. cmd=$nonopt test -z "$cmd" && \ func_fatal_help "you must specify a COMMAND" # Handle -dlopen flags immediately. for file in $opt_dlopen; do test -f "$file" \ || func_fatal_help "'$file' is not a file" dir= case $file in *.la) func_resolve_sysroot "$file" file=$func_resolve_sysroot_result # Check to see that this really is a libtool archive. func_lalib_unsafe_p "$file" \ || func_fatal_help "'$lib' is not a valid libtool archive" # Read the libtool library. dlname= library_names= func_source "$file" # Skip this library if it cannot be dlopened. if test -z "$dlname"; then # Warn if it was a shared library. test -n "$library_names" && \ func_warning "'$file' was not linked with '-export-dynamic'" continue fi func_dirname "$file" "" "." dir=$func_dirname_result if test -f "$dir/$objdir/$dlname"; then func_append dir "/$objdir" else if test ! -f "$dir/$dlname"; then func_fatal_error "cannot find '$dlname' in '$dir' or '$dir/$objdir'" fi fi ;; *.lo) # Just add the directory containing the .lo file. func_dirname "$file" "" "." dir=$func_dirname_result ;; *) func_warning "'-dlopen' is ignored for non-libtool libraries and objects" continue ;; esac # Get the absolute pathname. absdir=`cd "$dir" && pwd` test -n "$absdir" && dir=$absdir # Now add the directory to shlibpath_var. if eval "test -z \"\$$shlibpath_var\""; then eval "$shlibpath_var=\"\$dir\"" else eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\"" fi done # This variable tells wrapper scripts just to set shlibpath_var # rather than running their programs. libtool_execute_magic=$magic # Check if any of the arguments is a wrapper script. args= for file do case $file in -* | *.la | *.lo ) ;; *) # Do a test to see if this is really a libtool program. if func_ltwrapper_script_p "$file"; then func_source "$file" # Transform arg to wrapped name. file=$progdir/$program elif func_ltwrapper_executable_p "$file"; then func_ltwrapper_scriptname "$file" func_source "$func_ltwrapper_scriptname_result" # Transform arg to wrapped name. file=$progdir/$program fi ;; esac # Quote arguments (to preserve shell metacharacters). func_append_quoted args "$file" done if $opt_dry_run; then # Display what would be done. if test -n "$shlibpath_var"; then eval "\$ECHO \"\$shlibpath_var=\$$shlibpath_var\"" echo "export $shlibpath_var" fi $ECHO "$cmd$args" exit $EXIT_SUCCESS else if test -n "$shlibpath_var"; then # Export the shlibpath_var. eval "export $shlibpath_var" fi # Restore saved environment variables for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES do eval "if test \"\${save_$lt_var+set}\" = set; then $lt_var=\$save_$lt_var; export $lt_var else $lt_unset $lt_var fi" done # Now prepare to actually exec the command. exec_cmd=\$cmd$args fi } test execute = "$opt_mode" && func_mode_execute ${1+"$@"} # func_mode_finish arg... func_mode_finish () { $debug_cmd libs= libdirs= admincmds= for opt in "$nonopt" ${1+"$@"} do if test -d "$opt"; then func_append libdirs " $opt" elif test -f "$opt"; then if func_lalib_unsafe_p "$opt"; then func_append libs " $opt" else func_warning "'$opt' is not a valid libtool archive" fi else func_fatal_error "invalid argument '$opt'" fi done if test -n "$libs"; then if test -n "$lt_sysroot"; then sysroot_regex=`$ECHO "$lt_sysroot" | $SED "$sed_make_literal_regex"` sysroot_cmd="s/\([ ']\)$sysroot_regex/\1/g;" else sysroot_cmd= fi # Remove sysroot references if $opt_dry_run; then for lib in $libs; do echo "removing references to $lt_sysroot and '=' prefixes from $lib" done else tmpdir=`func_mktempdir` for lib in $libs; do $SED -e "$sysroot_cmd s/\([ ']-[LR]\)=/\1/g; s/\([ ']\)=/\1/g" $lib \ > $tmpdir/tmp-la mv -f $tmpdir/tmp-la $lib done ${RM}r "$tmpdir" fi fi if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then for libdir in $libdirs; do if test -n "$finish_cmds"; then # Do each command in the finish commands. func_execute_cmds "$finish_cmds" 'admincmds="$admincmds '"$cmd"'"' fi if test -n "$finish_eval"; then # Do the single finish_eval. eval cmds=\"$finish_eval\" $opt_dry_run || eval "$cmds" || func_append admincmds " $cmds" fi done fi # Exit here if they wanted silent mode. $opt_quiet && exit $EXIT_SUCCESS if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then echo "----------------------------------------------------------------------" echo "Libraries have been installed in:" for libdir in $libdirs; do $ECHO " $libdir" done echo echo "If you ever happen to want to link against installed libraries" echo "in a given directory, LIBDIR, you must either use libtool, and" echo "specify the full pathname of the library, or use the '-LLIBDIR'" echo "flag during linking and do at least one of the following:" if test -n "$shlibpath_var"; then echo " - add LIBDIR to the '$shlibpath_var' environment variable" echo " during execution" fi if test -n "$runpath_var"; then echo " - add LIBDIR to the '$runpath_var' environment variable" echo " during linking" fi if test -n "$hardcode_libdir_flag_spec"; then libdir=LIBDIR eval flag=\"$hardcode_libdir_flag_spec\" $ECHO " - use the '$flag' linker flag" fi if test -n "$admincmds"; then $ECHO " - have your system administrator run these commands:$admincmds" fi if test -f /etc/ld.so.conf; then echo " - have your system administrator add LIBDIR to '/etc/ld.so.conf'" fi echo echo "See any operating system documentation about shared libraries for" case $host in solaris2.[6789]|solaris2.1[0-9]) echo "more information, such as the ld(1), crle(1) and ld.so(8) manual" echo "pages." ;; *) echo "more information, such as the ld(1) and ld.so(8) manual pages." ;; esac echo "----------------------------------------------------------------------" fi exit $EXIT_SUCCESS } test finish = "$opt_mode" && func_mode_finish ${1+"$@"} # func_mode_install arg... func_mode_install () { $debug_cmd # There may be an optional sh(1) argument at the beginning of # install_prog (especially on Windows NT). if test "$SHELL" = "$nonopt" || test /bin/sh = "$nonopt" || # Allow the use of GNU shtool's install command. case $nonopt in *shtool*) :;; *) false;; esac then # Aesthetically quote it. func_quote_for_eval "$nonopt" install_prog="$func_quote_for_eval_result " arg=$1 shift else install_prog= arg=$nonopt fi # The real first argument should be the name of the installation program. # Aesthetically quote it. func_quote_for_eval "$arg" func_append install_prog "$func_quote_for_eval_result" install_shared_prog=$install_prog case " $install_prog " in *[\\\ /]cp\ *) install_cp=: ;; *) install_cp=false ;; esac # We need to accept at least all the BSD install flags. dest= files= opts= prev= install_type= isdir=false stripme= no_mode=: for arg do arg2= if test -n "$dest"; then func_append files " $dest" dest=$arg continue fi case $arg in -d) isdir=: ;; -f) if $install_cp; then :; else prev=$arg fi ;; -g | -m | -o) prev=$arg ;; -s) stripme=" -s" continue ;; -*) ;; *) # If the previous option needed an argument, then skip it. if test -n "$prev"; then if test X-m = "X$prev" && test -n "$install_override_mode"; then arg2=$install_override_mode no_mode=false fi prev= else dest=$arg continue fi ;; esac # Aesthetically quote the argument. func_quote_for_eval "$arg" func_append install_prog " $func_quote_for_eval_result" if test -n "$arg2"; then func_quote_for_eval "$arg2" fi func_append install_shared_prog " $func_quote_for_eval_result" done test -z "$install_prog" && \ func_fatal_help "you must specify an install program" test -n "$prev" && \ func_fatal_help "the '$prev' option requires an argument" if test -n "$install_override_mode" && $no_mode; then if $install_cp; then :; else func_quote_for_eval "$install_override_mode" func_append install_shared_prog " -m $func_quote_for_eval_result" fi fi if test -z "$files"; then if test -z "$dest"; then func_fatal_help "no file or destination specified" else func_fatal_help "you must specify a destination" fi fi # Strip any trailing slash from the destination. func_stripname '' '/' "$dest" dest=$func_stripname_result # Check to see that the destination is a directory. test -d "$dest" && isdir=: if $isdir; then destdir=$dest destname= else func_dirname_and_basename "$dest" "" "." destdir=$func_dirname_result destname=$func_basename_result # Not a directory, so check to see that there is only one file specified. set dummy $files; shift test "$#" -gt 1 && \ func_fatal_help "'$dest' is not a directory" fi case $destdir in [\\/]* | [A-Za-z]:[\\/]*) ;; *) for file in $files; do case $file in *.lo) ;; *) func_fatal_help "'$destdir' must be an absolute directory name" ;; esac done ;; esac # This variable tells wrapper scripts just to set variables rather # than running their programs. libtool_install_magic=$magic staticlibs= future_libdirs= current_libdirs= for file in $files; do # Do each installation. case $file in *.$libext) # Do the static libraries later. func_append staticlibs " $file" ;; *.la) func_resolve_sysroot "$file" file=$func_resolve_sysroot_result # Check to see that this really is a libtool archive. func_lalib_unsafe_p "$file" \ || func_fatal_help "'$file' is not a valid libtool archive" library_names= old_library= relink_command= func_source "$file" # Add the libdir to current_libdirs if it is the destination. if test "X$destdir" = "X$libdir"; then case "$current_libdirs " in *" $libdir "*) ;; *) func_append current_libdirs " $libdir" ;; esac else # Note the libdir as a future libdir. case "$future_libdirs " in *" $libdir "*) ;; *) func_append future_libdirs " $libdir" ;; esac fi func_dirname "$file" "/" "" dir=$func_dirname_result func_append dir "$objdir" if test -n "$relink_command"; then # Determine the prefix the user has applied to our future dir. inst_prefix_dir=`$ECHO "$destdir" | $SED -e "s%$libdir\$%%"` # Don't allow the user to place us outside of our expected # location b/c this prevents finding dependent libraries that # are installed to the same prefix. # At present, this check doesn't affect windows .dll's that # are installed into $libdir/../bin (currently, that works fine) # but it's something to keep an eye on. test "$inst_prefix_dir" = "$destdir" && \ func_fatal_error "error: cannot install '$file' to a directory not ending in $libdir" if test -n "$inst_prefix_dir"; then # Stick the inst_prefix_dir data into the link command. relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"` else relink_command=`$ECHO "$relink_command" | $SED "s%@inst_prefix_dir@%%"` fi func_warning "relinking '$file'" func_show_eval "$relink_command" \ 'func_fatal_error "error: relink '\''$file'\'' with the above command before installing it"' fi # See the names of the shared library. set dummy $library_names; shift if test -n "$1"; then realname=$1 shift srcname=$realname test -n "$relink_command" && srcname=${realname}T # Install the shared library and build the symlinks. func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \ 'exit $?' tstripme=$stripme case $host_os in cygwin* | mingw* | pw32* | cegcc*) case $realname in *.dll.a) tstripme= ;; esac ;; os2*) case $realname in *_dll.a) tstripme= ;; esac ;; esac if test -n "$tstripme" && test -n "$striplib"; then func_show_eval "$striplib $destdir/$realname" 'exit $?' fi if test "$#" -gt 0; then # Delete the old symlinks, and create new ones. # Try 'ln -sf' first, because the 'ln' binary might depend on # the symlink we replace! Solaris /bin/ln does not understand -f, # so we also need to try rm && ln -s. for linkname do test "$linkname" != "$realname" \ && func_show_eval "(cd $destdir && { $LN_S -f $realname $linkname || { $RM $linkname && $LN_S $realname $linkname; }; })" done fi # Do each command in the postinstall commands. lib=$destdir/$realname func_execute_cmds "$postinstall_cmds" 'exit $?' fi # Install the pseudo-library for information purposes. func_basename "$file" name=$func_basename_result instname=$dir/${name}i func_show_eval "$install_prog $instname $destdir/$name" 'exit $?' # Maybe install the static library, too. test -n "$old_library" && func_append staticlibs " $dir/$old_library" ;; *.lo) # Install (i.e. copy) a libtool object. # Figure out destination file name, if it wasn't already specified. if test -n "$destname"; then destfile=$destdir/$destname else func_basename "$file" destfile=$func_basename_result destfile=$destdir/$destfile fi # Deduce the name of the destination old-style object file. case $destfile in *.lo) func_lo2o "$destfile" staticdest=$func_lo2o_result ;; *.$objext) staticdest=$destfile destfile= ;; *) func_fatal_help "cannot copy a libtool object to '$destfile'" ;; esac # Install the libtool object if requested. test -n "$destfile" && \ func_show_eval "$install_prog $file $destfile" 'exit $?' # Install the old object if enabled. if test yes = "$build_old_libs"; then # Deduce the name of the old-style object file. func_lo2o "$file" staticobj=$func_lo2o_result func_show_eval "$install_prog \$staticobj \$staticdest" 'exit $?' fi exit $EXIT_SUCCESS ;; *) # Figure out destination file name, if it wasn't already specified. if test -n "$destname"; then destfile=$destdir/$destname else func_basename "$file" destfile=$func_basename_result destfile=$destdir/$destfile fi # If the file is missing, and there is a .exe on the end, strip it # because it is most likely a libtool script we actually want to # install stripped_ext= case $file in *.exe) if test ! -f "$file"; then func_stripname '' '.exe' "$file" file=$func_stripname_result stripped_ext=.exe fi ;; esac # Do a test to see if this is really a libtool program. case $host in *cygwin* | *mingw*) if func_ltwrapper_executable_p "$file"; then func_ltwrapper_scriptname "$file" wrapper=$func_ltwrapper_scriptname_result else func_stripname '' '.exe' "$file" wrapper=$func_stripname_result fi ;; *) wrapper=$file ;; esac if func_ltwrapper_script_p "$wrapper"; then notinst_deplibs= relink_command= func_source "$wrapper" # Check the variables that should have been set. test -z "$generated_by_libtool_version" && \ func_fatal_error "invalid libtool wrapper script '$wrapper'" finalize=: for lib in $notinst_deplibs; do # Check to see that each library is installed. libdir= if test -f "$lib"; then func_source "$lib" fi libfile=$libdir/`$ECHO "$lib" | $SED 's%^.*/%%g'` if test -n "$libdir" && test ! -f "$libfile"; then func_warning "'$lib' has not been installed in '$libdir'" finalize=false fi done relink_command= func_source "$wrapper" outputname= if test no = "$fast_install" && test -n "$relink_command"; then $opt_dry_run || { if $finalize; then tmpdir=`func_mktempdir` func_basename "$file$stripped_ext" file=$func_basename_result outputname=$tmpdir/$file # Replace the output file specification. relink_command=`$ECHO "$relink_command" | $SED 's%@OUTPUT@%'"$outputname"'%g'` $opt_quiet || { func_quote_for_expand "$relink_command" eval "func_echo $func_quote_for_expand_result" } if eval "$relink_command"; then : else func_error "error: relink '$file' with the above command before installing it" $opt_dry_run || ${RM}r "$tmpdir" continue fi file=$outputname else func_warning "cannot relink '$file'" fi } else # Install the binary that we compiled earlier. file=`$ECHO "$file$stripped_ext" | $SED "s%\([^/]*\)$%$objdir/\1%"` fi fi # remove .exe since cygwin /usr/bin/install will append another # one anyway case $install_prog,$host in */usr/bin/install*,*cygwin*) case $file:$destfile in *.exe:*.exe) # this is ok ;; *.exe:*) destfile=$destfile.exe ;; *:*.exe) func_stripname '' '.exe' "$destfile" destfile=$func_stripname_result ;; esac ;; esac func_show_eval "$install_prog\$stripme \$file \$destfile" 'exit $?' $opt_dry_run || if test -n "$outputname"; then ${RM}r "$tmpdir" fi ;; esac done for file in $staticlibs; do func_basename "$file" name=$func_basename_result # Set up the ranlib parameters. oldlib=$destdir/$name func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 tool_oldlib=$func_to_tool_file_result func_show_eval "$install_prog \$file \$oldlib" 'exit $?' if test -n "$stripme" && test -n "$old_striplib"; then func_show_eval "$old_striplib $tool_oldlib" 'exit $?' fi # Do each command in the postinstall commands. func_execute_cmds "$old_postinstall_cmds" 'exit $?' done test -n "$future_libdirs" && \ func_warning "remember to run '$progname --finish$future_libdirs'" if test -n "$current_libdirs"; then # Maybe just do a dry run. $opt_dry_run && current_libdirs=" -n$current_libdirs" exec_cmd='$SHELL "$progpath" $preserve_args --finish$current_libdirs' else exit $EXIT_SUCCESS fi } test install = "$opt_mode" && func_mode_install ${1+"$@"} # func_generate_dlsyms outputname originator pic_p # Extract symbols from dlprefiles and create ${outputname}S.o with # a dlpreopen symbol table. func_generate_dlsyms () { $debug_cmd my_outputname=$1 my_originator=$2 my_pic_p=${3-false} my_prefix=`$ECHO "$my_originator" | $SED 's%[^a-zA-Z0-9]%_%g'` my_dlsyms= if test -n "$dlfiles$dlprefiles" || test no != "$dlself"; then if test -n "$NM" && test -n "$global_symbol_pipe"; then my_dlsyms=${my_outputname}S.c else func_error "not configured to extract global symbols from dlpreopened files" fi fi if test -n "$my_dlsyms"; then case $my_dlsyms in "") ;; *.c) # Discover the nlist of each of the dlfiles. nlist=$output_objdir/$my_outputname.nm func_show_eval "$RM $nlist ${nlist}S ${nlist}T" # Parse the name list into a source file. func_verbose "creating $output_objdir/$my_dlsyms" $opt_dry_run || $ECHO > "$output_objdir/$my_dlsyms" "\ /* $my_dlsyms - symbol resolution table for '$my_outputname' dlsym emulation. */ /* Generated by $PROGRAM (GNU $PACKAGE) $VERSION */ #ifdef __cplusplus extern \"C\" { #endif #if defined __GNUC__ && (((__GNUC__ == 4) && (__GNUC_MINOR__ >= 4)) || (__GNUC__ > 4)) #pragma GCC diagnostic ignored \"-Wstrict-prototypes\" #endif /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE /* DATA imports from DLLs on WIN32 can't be const, because runtime relocations are performed -- see ld's documentation on pseudo-relocs. */ # define LT_DLSYM_CONST #elif defined __osf__ /* This system does not cope well with relocations in const data. */ # define LT_DLSYM_CONST #else # define LT_DLSYM_CONST const #endif #define STREQ(s1, s2) (strcmp ((s1), (s2)) == 0) /* External symbol declarations for the compiler. */\ " if test yes = "$dlself"; then func_verbose "generating symbol list for '$output'" $opt_dry_run || echo ': @PROGRAM@ ' > "$nlist" # Add our own program objects to the symbol list. progfiles=`$ECHO "$objs$old_deplibs" | $SP2NL | $SED "$lo2o" | $NL2SP` for progfile in $progfiles; do func_to_tool_file "$progfile" func_convert_file_msys_to_w32 func_verbose "extracting global C symbols from '$func_to_tool_file_result'" $opt_dry_run || eval "$NM $func_to_tool_file_result | $global_symbol_pipe >> '$nlist'" done if test -n "$exclude_expsyms"; then $opt_dry_run || { eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T' eval '$MV "$nlist"T "$nlist"' } fi if test -n "$export_symbols_regex"; then $opt_dry_run || { eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T' eval '$MV "$nlist"T "$nlist"' } fi # Prepare the list of exported symbols if test -z "$export_symbols"; then export_symbols=$output_objdir/$outputname.exp $opt_dry_run || { $RM $export_symbols eval "$SED -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' case $host in *cygwin* | *mingw* | *cegcc* ) eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' ;; esac } else $opt_dry_run || { eval "$SED -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' eval '$GREP -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' eval '$MV "$nlist"T "$nlist"' case $host in *cygwin* | *mingw* | *cegcc* ) eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' ;; esac } fi fi for dlprefile in $dlprefiles; do func_verbose "extracting global C symbols from '$dlprefile'" func_basename "$dlprefile" name=$func_basename_result case $host in *cygwin* | *mingw* | *cegcc* ) # if an import library, we need to obtain dlname if func_win32_import_lib_p "$dlprefile"; then func_tr_sh "$dlprefile" eval "curr_lafile=\$libfile_$func_tr_sh_result" dlprefile_dlbasename= if test -n "$curr_lafile" && func_lalib_p "$curr_lafile"; then # Use subshell, to avoid clobbering current variable values dlprefile_dlname=`source "$curr_lafile" && echo "$dlname"` if test -n "$dlprefile_dlname"; then func_basename "$dlprefile_dlname" dlprefile_dlbasename=$func_basename_result else # no lafile. user explicitly requested -dlpreopen <import library>. $sharedlib_from_linklib_cmd "$dlprefile" dlprefile_dlbasename=$sharedlib_from_linklib_result fi fi $opt_dry_run || { if test -n "$dlprefile_dlbasename"; then eval '$ECHO ": $dlprefile_dlbasename" >> "$nlist"' else func_warning "Could not compute DLL name from $name" eval '$ECHO ": $name " >> "$nlist"' fi func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe | $SED -e '/I __imp/d' -e 's/I __nm_/D /;s/_nm__//' >> '$nlist'" } else # not an import lib $opt_dry_run || { eval '$ECHO ": $name " >> "$nlist"' func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" } fi ;; *) $opt_dry_run || { eval '$ECHO ": $name " >> "$nlist"' func_to_tool_file "$dlprefile" func_convert_file_msys_to_w32 eval "$NM \"$func_to_tool_file_result\" 2>/dev/null | $global_symbol_pipe >> '$nlist'" } ;; esac done $opt_dry_run || { # Make sure we have at least an empty file. test -f "$nlist" || : > "$nlist" if test -n "$exclude_expsyms"; then $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T $MV "$nlist"T "$nlist" fi # Try sorting and uniquifying the output. if $GREP -v "^: " < "$nlist" | if sort -k 3 </dev/null >/dev/null 2>&1; then sort -k 3 else sort +2 fi | uniq > "$nlist"S; then : else $GREP -v "^: " < "$nlist" > "$nlist"S fi if test -f "$nlist"S; then eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$my_dlsyms"' else echo '/* NONE */' >> "$output_objdir/$my_dlsyms" fi func_show_eval '$RM "${nlist}I"' if test -n "$global_symbol_to_import"; then eval "$global_symbol_to_import"' < "$nlist"S > "$nlist"I' fi echo >> "$output_objdir/$my_dlsyms" "\ /* The mapping between symbol names and symbols. */ typedef struct { const char *name; void *address; } lt_dlsymlist; extern LT_DLSYM_CONST lt_dlsymlist lt_${my_prefix}_LTX_preloaded_symbols[];\ " if test -s "$nlist"I; then echo >> "$output_objdir/$my_dlsyms" "\ static void lt_syminit(void) { LT_DLSYM_CONST lt_dlsymlist *symbol = lt_${my_prefix}_LTX_preloaded_symbols; for (; symbol->name; ++symbol) {" $SED 's/.*/ if (STREQ (symbol->name, \"&\")) symbol->address = (void *) \&&;/' < "$nlist"I >> "$output_objdir/$my_dlsyms" echo >> "$output_objdir/$my_dlsyms" "\ } }" fi echo >> "$output_objdir/$my_dlsyms" "\ LT_DLSYM_CONST lt_dlsymlist lt_${my_prefix}_LTX_preloaded_symbols[] = { {\"$my_originator\", (void *) 0}," if test -s "$nlist"I; then echo >> "$output_objdir/$my_dlsyms" "\ {\"@INIT@\", (void *) <_syminit}," fi case $need_lib_prefix in no) eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$my_dlsyms" ;; *) eval "$global_symbol_to_c_name_address_lib_prefix" < "$nlist" >> "$output_objdir/$my_dlsyms" ;; esac echo >> "$output_objdir/$my_dlsyms" "\ {0, (void *) 0} }; /* This works around a problem in FreeBSD linker */ #ifdef FREEBSD_WORKAROUND static const void *lt_preloaded_setup() { return lt_${my_prefix}_LTX_preloaded_symbols; } #endif #ifdef __cplusplus } #endif\ " } # !$opt_dry_run pic_flag_for_symtable= case "$compile_command " in *" -static "*) ;; *) case $host in # compiling the symbol table file with pic_flag works around # a FreeBSD bug that causes programs to crash when -lm is # linked before any other PIC object. But we must not use # pic_flag when linking with -static. The problem exists in # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1. *-*-freebsd2.*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND" ;; *-*-hpux*) pic_flag_for_symtable=" $pic_flag" ;; *) $my_pic_p && pic_flag_for_symtable=" $pic_flag" ;; esac ;; esac symtab_cflags= for arg in $LTCFLAGS; do case $arg in -pie | -fpie | -fPIE) ;; *) func_append symtab_cflags " $arg" ;; esac done # Now compile the dynamic symbol file. func_show_eval '(cd $output_objdir && $LTCC$symtab_cflags -c$no_builtin_flag$pic_flag_for_symtable "$my_dlsyms")' 'exit $?' # Clean up the generated files. func_show_eval '$RM "$output_objdir/$my_dlsyms" "$nlist" "${nlist}S" "${nlist}T" "${nlist}I"' # Transform the symbol file into the correct name. symfileobj=$output_objdir/${my_outputname}S.$objext case $host in *cygwin* | *mingw* | *cegcc* ) if test -f "$output_objdir/$my_outputname.def"; then compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$output_objdir/$my_outputname.def $symfileobj%"` else compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` fi ;; *) compile_command=`$ECHO "$compile_command" | $SED "s%@SYMFILE@%$symfileobj%"` finalize_command=`$ECHO "$finalize_command" | $SED "s%@SYMFILE@%$symfileobj%"` ;; esac ;; *) func_fatal_error "unknown suffix for '$my_dlsyms'" ;; esac else # We keep going just in case the user didn't refer to # lt_preloaded_symbols. The linker will fail if global_symbol_pipe # really was required. # Nullify the symbol file. compile_command=`$ECHO "$compile_command" | $SED "s% @SYMFILE@%%"` finalize_command=`$ECHO "$finalize_command" | $SED "s% @SYMFILE@%%"` fi } # func_cygming_gnu_implib_p ARG # This predicate returns with zero status (TRUE) if # ARG is a GNU/binutils-style import library. Returns # with nonzero status (FALSE) otherwise. func_cygming_gnu_implib_p () { $debug_cmd func_to_tool_file "$1" func_convert_file_msys_to_w32 func_cygming_gnu_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $EGREP ' (_head_[A-Za-z0-9_]+_[ad]l*|[A-Za-z0-9_]+_[ad]l*_iname)$'` test -n "$func_cygming_gnu_implib_tmp" } # func_cygming_ms_implib_p ARG # This predicate returns with zero status (TRUE) if # ARG is an MS-style import library. Returns # with nonzero status (FALSE) otherwise. func_cygming_ms_implib_p () { $debug_cmd func_to_tool_file "$1" func_convert_file_msys_to_w32 func_cygming_ms_implib_tmp=`$NM "$func_to_tool_file_result" | eval "$global_symbol_pipe" | $GREP '_NULL_IMPORT_DESCRIPTOR'` test -n "$func_cygming_ms_implib_tmp" } # func_win32_libid arg # return the library type of file 'arg' # # Need a lot of goo to handle *both* DLLs and import libs # Has to be a shell function in order to 'eat' the argument # that is supplied when $file_magic_command is called. # Despite the name, also deal with 64 bit binaries. func_win32_libid () { $debug_cmd win32_libid_type=unknown win32_fileres=`file -L $1 2>/dev/null` case $win32_fileres in *ar\ archive\ import\ library*) # definitely import win32_libid_type="x86 archive import" ;; *ar\ archive*) # could be an import, or static # Keep the egrep pattern in sync with the one in _LT_CHECK_MAGIC_METHOD. if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | $EGREP 'file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' >/dev/null; then case $nm_interface in "MS dumpbin") if func_cygming_ms_implib_p "$1" || func_cygming_gnu_implib_p "$1" then win32_nmres=import else win32_nmres= fi ;; *) func_to_tool_file "$1" func_convert_file_msys_to_w32 win32_nmres=`eval $NM -f posix -A \"$func_to_tool_file_result\" | $SED -n -e ' 1,100{ / I /{ s|.*|import| p q } }'` ;; esac case $win32_nmres in import*) win32_libid_type="x86 archive import";; *) win32_libid_type="x86 archive static";; esac fi ;; *DLL*) win32_libid_type="x86 DLL" ;; *executable*) # but shell scripts are "executable" too... case $win32_fileres in *MS\ Windows\ PE\ Intel*) win32_libid_type="x86 DLL" ;; esac ;; esac $ECHO "$win32_libid_type" } # func_cygming_dll_for_implib ARG # # Platform-specific function to extract the # name of the DLL associated with the specified # import library ARG. # Invoked by eval'ing the libtool variable # $sharedlib_from_linklib_cmd # Result is available in the variable # $sharedlib_from_linklib_result func_cygming_dll_for_implib () { $debug_cmd sharedlib_from_linklib_result=`$DLLTOOL --identify-strict --identify "$1"` } # func_cygming_dll_for_implib_fallback_core SECTION_NAME LIBNAMEs # # The is the core of a fallback implementation of a # platform-specific function to extract the name of the # DLL associated with the specified import library LIBNAME. # # SECTION_NAME is either .idata$6 or .idata$7, depending # on the platform and compiler that created the implib. # # Echos the name of the DLL associated with the # specified import library. func_cygming_dll_for_implib_fallback_core () { $debug_cmd match_literal=`$ECHO "$1" | $SED "$sed_make_literal_regex"` $OBJDUMP -s --section "$1" "$2" 2>/dev/null | $SED '/^Contents of section '"$match_literal"':/{ # Place marker at beginning of archive member dllname section s/.*/====MARK====/ p d } # These lines can sometimes be longer than 43 characters, but # are always uninteresting /:[ ]*file format pe[i]\{,1\}-/d /^In archive [^:]*:/d # Ensure marker is printed /^====MARK====/p # Remove all lines with less than 43 characters /^.\{43\}/!d # From remaining lines, remove first 43 characters s/^.\{43\}//' | $SED -n ' # Join marker and all lines until next marker into a single line /^====MARK====/ b para H $ b para b :para x s/\n//g # Remove the marker s/^====MARK====// # Remove trailing dots and whitespace s/[\. \t]*$// # Print /./p' | # we now have a list, one entry per line, of the stringified # contents of the appropriate section of all members of the # archive that possess that section. Heuristic: eliminate # all those that have a first or second character that is # a '.' (that is, objdump's representation of an unprintable # character.) This should work for all archives with less than # 0x302f exports -- but will fail for DLLs whose name actually # begins with a literal '.' or a single character followed by # a '.'. # # Of those that remain, print the first one. $SED -e '/^\./d;/^.\./d;q' } # func_cygming_dll_for_implib_fallback ARG # Platform-specific function to extract the # name of the DLL associated with the specified # import library ARG. # # This fallback implementation is for use when $DLLTOOL # does not support the --identify-strict option. # Invoked by eval'ing the libtool variable # $sharedlib_from_linklib_cmd # Result is available in the variable # $sharedlib_from_linklib_result func_cygming_dll_for_implib_fallback () { $debug_cmd if func_cygming_gnu_implib_p "$1"; then # binutils import library sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$7' "$1"` elif func_cygming_ms_implib_p "$1"; then # ms-generated import library sharedlib_from_linklib_result=`func_cygming_dll_for_implib_fallback_core '.idata$6' "$1"` else # unknown sharedlib_from_linklib_result= fi } # func_extract_an_archive dir oldlib func_extract_an_archive () { $debug_cmd f_ex_an_ar_dir=$1; shift f_ex_an_ar_oldlib=$1 if test yes = "$lock_old_archive_extraction"; then lockfile=$f_ex_an_ar_oldlib.lock until $opt_dry_run || ln "$progpath" "$lockfile" 2>/dev/null; do func_echo "Waiting for $lockfile to be removed" sleep 2 done fi func_show_eval "(cd \$f_ex_an_ar_dir && $AR x \"\$f_ex_an_ar_oldlib\")" \ 'stat=$?; rm -f "$lockfile"; exit $stat' if test yes = "$lock_old_archive_extraction"; then $opt_dry_run || rm -f "$lockfile" fi if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then : else func_fatal_error "object name conflicts in archive: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib" fi } # func_extract_archives gentop oldlib ... func_extract_archives () { $debug_cmd my_gentop=$1; shift my_oldlibs=${1+"$@"} my_oldobjs= my_xlib= my_xabs= my_xdir= for my_xlib in $my_oldlibs; do # Extract the objects. case $my_xlib in [\\/]* | [A-Za-z]:[\\/]*) my_xabs=$my_xlib ;; *) my_xabs=`pwd`"/$my_xlib" ;; esac func_basename "$my_xlib" my_xlib=$func_basename_result my_xlib_u=$my_xlib while :; do case " $extracted_archives " in *" $my_xlib_u "*) func_arith $extracted_serial + 1 extracted_serial=$func_arith_result my_xlib_u=lt$extracted_serial-$my_xlib ;; *) break ;; esac done extracted_archives="$extracted_archives $my_xlib_u" my_xdir=$my_gentop/$my_xlib_u func_mkdir_p "$my_xdir" case $host in *-darwin*) func_verbose "Extracting $my_xabs" # Do not bother doing anything if just a dry run $opt_dry_run || { darwin_orig_dir=`pwd` cd $my_xdir || exit $? darwin_archive=$my_xabs darwin_curdir=`pwd` func_basename "$darwin_archive" darwin_base_archive=$func_basename_result darwin_arches=`$LIPO -info "$darwin_archive" 2>/dev/null | $GREP Architectures 2>/dev/null || true` if test -n "$darwin_arches"; then darwin_arches=`$ECHO "$darwin_arches" | $SED -e 's/.*are://'` darwin_arch= func_verbose "$darwin_base_archive has multiple architectures $darwin_arches" for darwin_arch in $darwin_arches; do func_mkdir_p "unfat-$$/$darwin_base_archive-$darwin_arch" $LIPO -thin $darwin_arch -output "unfat-$$/$darwin_base_archive-$darwin_arch/$darwin_base_archive" "$darwin_archive" cd "unfat-$$/$darwin_base_archive-$darwin_arch" func_extract_an_archive "`pwd`" "$darwin_base_archive" cd "$darwin_curdir" $RM "unfat-$$/$darwin_base_archive-$darwin_arch/$darwin_base_archive" done # $darwin_arches ## Okay now we've a bunch of thin objects, gotta fatten them up :) darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print | $SED -e "$sed_basename" | sort -u` darwin_file= darwin_files= for darwin_file in $darwin_filelist; do darwin_files=`find unfat-$$ -name $darwin_file -print | sort | $NL2SP` $LIPO -create -output "$darwin_file" $darwin_files done # $darwin_filelist $RM -rf unfat-$$ cd "$darwin_orig_dir" else cd $darwin_orig_dir func_extract_an_archive "$my_xdir" "$my_xabs" fi # $darwin_arches } # !$opt_dry_run ;; *) func_extract_an_archive "$my_xdir" "$my_xabs" ;; esac my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | sort | $NL2SP` done func_extract_archives_result=$my_oldobjs } # func_emit_wrapper [arg=no] # # Emit a libtool wrapper script on stdout. # Don't directly open a file because we may want to # incorporate the script contents within a cygwin/mingw # wrapper executable. Must ONLY be called from within # func_mode_link because it depends on a number of variables # set therein. # # ARG is the value that the WRAPPER_SCRIPT_BELONGS_IN_OBJDIR # variable will take. If 'yes', then the emitted script # will assume that the directory where it is stored is # the $objdir directory. This is a cygwin/mingw-specific # behavior. func_emit_wrapper () { func_emit_wrapper_arg1=${1-no} $ECHO "\ #! $SHELL # $output - temporary wrapper script for $objdir/$outputname # Generated by $PROGRAM (GNU $PACKAGE) $VERSION # # The $output program cannot be directly executed until all the libtool # libraries that it depends on are installed. # # This wrapper script should never be moved out of the build directory. # If it is, it will not operate correctly. # Sed substitution that helps us do robust quoting. It backslashifies # metacharacters that are still active within double-quoted strings. sed_quote_subst='$sed_quote_subst' # Be Bourne compatible if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which # is contrary to our usage. Disable this feature. alias -g '\${1+\"\$@\"}'='\"\$@\"' setopt NO_GLOB_SUBST else case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac fi BIN_SH=xpg4; export BIN_SH # for Tru64 DUALCASE=1; export DUALCASE # for MKS sh # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH relink_command=\"$relink_command\" # This environment variable determines our operation mode. if test \"\$libtool_install_magic\" = \"$magic\"; then # install mode needs the following variables: generated_by_libtool_version='$macro_version' notinst_deplibs='$notinst_deplibs' else # When we are sourced in execute mode, \$file and \$ECHO are already set. if test \"\$libtool_execute_magic\" != \"$magic\"; then file=\"\$0\"" qECHO=`$ECHO "$ECHO" | $SED "$sed_quote_subst"` $ECHO "\ # A function that is used when there is no print builtin or printf. func_fallback_echo () { eval 'cat <<_LTECHO_EOF \$1 _LTECHO_EOF' } ECHO=\"$qECHO\" fi # Very basic option parsing. These options are (a) specific to # the libtool wrapper, (b) are identical between the wrapper # /script/ and the wrapper /executable/ that is used only on # windows platforms, and (c) all begin with the string "--lt-" # (application programs are unlikely to have options that match # this pattern). # # There are only two supported options: --lt-debug and # --lt-dump-script. There is, deliberately, no --lt-help. # # The first argument to this parsing function should be the # script's $0 value, followed by "$@". lt_option_debug= func_parse_lt_options () { lt_script_arg0=\$0 shift for lt_opt do case \"\$lt_opt\" in --lt-debug) lt_option_debug=1 ;; --lt-dump-script) lt_dump_D=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%/[^/]*$%%'\` test \"X\$lt_dump_D\" = \"X\$lt_script_arg0\" && lt_dump_D=. lt_dump_F=\`\$ECHO \"X\$lt_script_arg0\" | $SED -e 's/^X//' -e 's%^.*/%%'\` cat \"\$lt_dump_D/\$lt_dump_F\" exit 0 ;; --lt-*) \$ECHO \"Unrecognized --lt- option: '\$lt_opt'\" 1>&2 exit 1 ;; esac done # Print the debug banner immediately: if test -n \"\$lt_option_debug\"; then echo \"$outputname:$output:\$LINENO: libtool wrapper (GNU $PACKAGE) $VERSION\" 1>&2 fi } # Used when --lt-debug. Prints its arguments to stdout # (redirection is the responsibility of the caller) func_lt_dump_args () { lt_dump_args_N=1; for lt_arg do \$ECHO \"$outputname:$output:\$LINENO: newargv[\$lt_dump_args_N]: \$lt_arg\" lt_dump_args_N=\`expr \$lt_dump_args_N + 1\` done } # Core function for launching the target application func_exec_program_core () { " case $host in # Backslashes separate directories on plain windows *-*-mingw | *-*-os2* | *-cegcc*) $ECHO "\ if test -n \"\$lt_option_debug\"; then \$ECHO \"$outputname:$output:\$LINENO: newargv[0]: \$progdir\\\\\$program\" 1>&2 func_lt_dump_args \${1+\"\$@\"} 1>&2 fi exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} " ;; *) $ECHO "\ if test -n \"\$lt_option_debug\"; then \$ECHO \"$outputname:$output:\$LINENO: newargv[0]: \$progdir/\$program\" 1>&2 func_lt_dump_args \${1+\"\$@\"} 1>&2 fi exec \"\$progdir/\$program\" \${1+\"\$@\"} " ;; esac $ECHO "\ \$ECHO \"\$0: cannot exec \$program \$*\" 1>&2 exit 1 } # A function to encapsulate launching the target application # Strips options in the --lt-* namespace from \$@ and # launches target application with the remaining arguments. func_exec_program () { case \" \$* \" in *\\ --lt-*) for lt_wr_arg do case \$lt_wr_arg in --lt-*) ;; *) set x \"\$@\" \"\$lt_wr_arg\"; shift;; esac shift done ;; esac func_exec_program_core \${1+\"\$@\"} } # Parse options func_parse_lt_options \"\$0\" \${1+\"\$@\"} # Find the directory that this script lives in. thisdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*$%%'\` test \"x\$thisdir\" = \"x\$file\" && thisdir=. # Follow symbolic links until we get to the real thisdir. file=\`ls -ld \"\$file\" | $SED -n 's/.*-> //p'\` while test -n \"\$file\"; do destdir=\`\$ECHO \"\$file\" | $SED 's%/[^/]*\$%%'\` # If there was a directory component, then change thisdir. if test \"x\$destdir\" != \"x\$file\"; then case \"\$destdir\" in [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;; *) thisdir=\"\$thisdir/\$destdir\" ;; esac fi file=\`\$ECHO \"\$file\" | $SED 's%^.*/%%'\` file=\`ls -ld \"\$thisdir/\$file\" | $SED -n 's/.*-> //p'\` done # Usually 'no', except on cygwin/mingw when embedded into # the cwrapper. WRAPPER_SCRIPT_BELONGS_IN_OBJDIR=$func_emit_wrapper_arg1 if test \"\$WRAPPER_SCRIPT_BELONGS_IN_OBJDIR\" = \"yes\"; then # special case for '.' if test \"\$thisdir\" = \".\"; then thisdir=\`pwd\` fi # remove .libs from thisdir case \"\$thisdir\" in *[\\\\/]$objdir ) thisdir=\`\$ECHO \"\$thisdir\" | $SED 's%[\\\\/][^\\\\/]*$%%'\` ;; $objdir ) thisdir=. ;; esac fi # Try to get the absolute directory name. absdir=\`cd \"\$thisdir\" && pwd\` test -n \"\$absdir\" && thisdir=\"\$absdir\" " if test yes = "$fast_install"; then $ECHO "\ program=lt-'$outputname'$exeext progdir=\"\$thisdir/$objdir\" if test ! -f \"\$progdir/\$program\" || { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | $SED 1q\`; \\ test \"X\$file\" != \"X\$progdir/\$program\"; }; then file=\"\$\$-\$program\" if test ! -d \"\$progdir\"; then $MKDIR \"\$progdir\" else $RM \"\$progdir/\$file\" fi" $ECHO "\ # relink executable if necessary if test -n \"\$relink_command\"; then if relink_command_output=\`eval \$relink_command 2>&1\`; then : else \$ECHO \"\$relink_command_output\" >&2 $RM \"\$progdir/\$file\" exit 1 fi fi $MV \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null || { $RM \"\$progdir/\$program\"; $MV \"\$progdir/\$file\" \"\$progdir/\$program\"; } $RM \"\$progdir/\$file\" fi" else $ECHO "\ program='$outputname' progdir=\"\$thisdir/$objdir\" " fi $ECHO "\ if test -f \"\$progdir/\$program\"; then" # fixup the dll searchpath if we need to. # # Fix the DLL searchpath if we need to. Do this before prepending # to shlibpath, because on Windows, both are PATH and uninstalled # libraries must come first. if test -n "$dllsearchpath"; then $ECHO "\ # Add the dll search path components to the executable PATH PATH=$dllsearchpath:\$PATH " fi # Export our shlibpath_var if we have one. if test yes = "$shlibpath_overrides_runpath" && test -n "$shlibpath_var" && test -n "$temp_rpath"; then $ECHO "\ # Add our own library path to $shlibpath_var $shlibpath_var=\"$temp_rpath\$$shlibpath_var\" # Some systems cannot cope with colon-terminated $shlibpath_var # The second colon is a workaround for a bug in BeOS R4 sed $shlibpath_var=\`\$ECHO \"\$$shlibpath_var\" | $SED 's/::*\$//'\` export $shlibpath_var " fi $ECHO "\ if test \"\$libtool_execute_magic\" != \"$magic\"; then # Run the actual program with our arguments. func_exec_program \${1+\"\$@\"} fi else # The program doesn't exist. \$ECHO \"\$0: error: '\$progdir/\$program' does not exist\" 1>&2 \$ECHO \"This script is just a wrapper for \$program.\" 1>&2 \$ECHO \"See the $PACKAGE documentation for more information.\" 1>&2 exit 1 fi fi\ " } # func_emit_cwrapperexe_src # emit the source code for a wrapper executable on stdout # Must ONLY be called from within func_mode_link because # it depends on a number of variable set therein. func_emit_cwrapperexe_src () { cat <<EOF /* $cwrappersource - temporary wrapper executable for $objdir/$outputname Generated by $PROGRAM (GNU $PACKAGE) $VERSION The $output program cannot be directly executed until all the libtool libraries that it depends on are installed. This wrapper executable should never be moved out of the build directory. If it is, it will not operate correctly. */ EOF cat <<"EOF" #ifdef _MSC_VER # define _CRT_SECURE_NO_DEPRECATE 1 #endif #include <stdio.h> #include <stdlib.h> #ifdef _MSC_VER # include <direct.h> # include <process.h> # include <io.h> #else # include <unistd.h> # include <stdint.h> # ifdef __CYGWIN__ # include <io.h> # endif #endif #include <malloc.h> #include <stdarg.h> #include <assert.h> #include <string.h> #include <ctype.h> #include <errno.h> #include <fcntl.h> #include <sys/stat.h> #define STREQ(s1, s2) (strcmp ((s1), (s2)) == 0) /* declarations of non-ANSI functions */ #if defined __MINGW32__ # ifdef __STRICT_ANSI__ int _putenv (const char *); # endif #elif defined __CYGWIN__ # ifdef __STRICT_ANSI__ char *realpath (const char *, char *); int putenv (char *); int setenv (const char *, const char *, int); # endif /* #elif defined other_platform || defined ... */ #endif /* portability defines, excluding path handling macros */ #if defined _MSC_VER # define setmode _setmode # define stat _stat # define chmod _chmod # define getcwd _getcwd # define putenv _putenv # define S_IXUSR _S_IEXEC #elif defined __MINGW32__ # define setmode _setmode # define stat _stat # define chmod _chmod # define getcwd _getcwd # define putenv _putenv #elif defined __CYGWIN__ # define HAVE_SETENV # define FOPEN_WB "wb" /* #elif defined other platforms ... */ #endif #if defined PATH_MAX # define LT_PATHMAX PATH_MAX #elif defined MAXPATHLEN # define LT_PATHMAX MAXPATHLEN #else # define LT_PATHMAX 1024 #endif #ifndef S_IXOTH # define S_IXOTH 0 #endif #ifndef S_IXGRP # define S_IXGRP 0 #endif /* path handling portability macros */ #ifndef DIR_SEPARATOR # define DIR_SEPARATOR '/' # define PATH_SEPARATOR ':' #endif #if defined _WIN32 || defined __MSDOS__ || defined __DJGPP__ || \ defined __OS2__ # define HAVE_DOS_BASED_FILE_SYSTEM # define FOPEN_WB "wb" # ifndef DIR_SEPARATOR_2 # define DIR_SEPARATOR_2 '\\' # endif # ifndef PATH_SEPARATOR_2 # define PATH_SEPARATOR_2 ';' # endif #endif #ifndef DIR_SEPARATOR_2 # define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR) #else /* DIR_SEPARATOR_2 */ # define IS_DIR_SEPARATOR(ch) \ (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) #endif /* DIR_SEPARATOR_2 */ #ifndef PATH_SEPARATOR_2 # define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR) #else /* PATH_SEPARATOR_2 */ # define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2) #endif /* PATH_SEPARATOR_2 */ #ifndef FOPEN_WB # define FOPEN_WB "w" #endif #ifndef _O_BINARY # define _O_BINARY 0 #endif #define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) #define XFREE(stale) do { \ if (stale) { free (stale); stale = 0; } \ } while (0) #if defined LT_DEBUGWRAPPER static int lt_debug = 1; #else static int lt_debug = 0; #endif const char *program_name = "libtool-wrapper"; /* in case xstrdup fails */ void *xmalloc (size_t num); char *xstrdup (const char *string); const char *base_name (const char *name); char *find_executable (const char *wrapper); char *chase_symlinks (const char *pathspec); int make_executable (const char *path); int check_executable (const char *path); char *strendzap (char *str, const char *pat); void lt_debugprintf (const char *file, int line, const char *fmt, ...); void lt_fatal (const char *file, int line, const char *message, ...); static const char *nonnull (const char *s); static const char *nonempty (const char *s); void lt_setenv (const char *name, const char *value); char *lt_extend_str (const char *orig_value, const char *add, int to_end); void lt_update_exe_path (const char *name, const char *value); void lt_update_lib_path (const char *name, const char *value); char **prepare_spawn (char **argv); void lt_dump_script (FILE *f); EOF cat <<EOF #if __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 5) # define externally_visible volatile #else # define externally_visible __attribute__((externally_visible)) volatile #endif externally_visible const char * MAGIC_EXE = "$magic_exe"; const char * LIB_PATH_VARNAME = "$shlibpath_var"; EOF if test yes = "$shlibpath_overrides_runpath" && test -n "$shlibpath_var" && test -n "$temp_rpath"; then func_to_host_path "$temp_rpath" cat <<EOF const char * LIB_PATH_VALUE = "$func_to_host_path_result"; EOF else cat <<"EOF" const char * LIB_PATH_VALUE = ""; EOF fi if test -n "$dllsearchpath"; then func_to_host_path "$dllsearchpath:" cat <<EOF const char * EXE_PATH_VARNAME = "PATH"; const char * EXE_PATH_VALUE = "$func_to_host_path_result"; EOF else cat <<"EOF" const char * EXE_PATH_VARNAME = ""; const char * EXE_PATH_VALUE = ""; EOF fi if test yes = "$fast_install"; then cat <<EOF const char * TARGET_PROGRAM_NAME = "lt-$outputname"; /* hopefully, no .exe */ EOF else cat <<EOF const char * TARGET_PROGRAM_NAME = "$outputname"; /* hopefully, no .exe */ EOF fi cat <<"EOF" #define LTWRAPPER_OPTION_PREFIX "--lt-" static const char *ltwrapper_option_prefix = LTWRAPPER_OPTION_PREFIX; static const char *dumpscript_opt = LTWRAPPER_OPTION_PREFIX "dump-script"; static const char *debug_opt = LTWRAPPER_OPTION_PREFIX "debug"; int main (int argc, char *argv[]) { char **newargz; int newargc; char *tmp_pathspec; char *actual_cwrapper_path; char *actual_cwrapper_name; char *target_name; char *lt_argv_zero; int rval = 127; int i; program_name = (char *) xstrdup (base_name (argv[0])); newargz = XMALLOC (char *, (size_t) argc + 1); /* very simple arg parsing; don't want to rely on getopt * also, copy all non cwrapper options to newargz, except * argz[0], which is handled differently */ newargc=0; for (i = 1; i < argc; i++) { if (STREQ (argv[i], dumpscript_opt)) { EOF case $host in *mingw* | *cygwin* ) # make stdout use "unix" line endings echo " setmode(1,_O_BINARY);" ;; esac cat <<"EOF" lt_dump_script (stdout); return 0; } if (STREQ (argv[i], debug_opt)) { lt_debug = 1; continue; } if (STREQ (argv[i], ltwrapper_option_prefix)) { /* however, if there is an option in the LTWRAPPER_OPTION_PREFIX namespace, but it is not one of the ones we know about and have already dealt with, above (inluding dump-script), then report an error. Otherwise, targets might begin to believe they are allowed to use options in the LTWRAPPER_OPTION_PREFIX namespace. The first time any user complains about this, we'll need to make LTWRAPPER_OPTION_PREFIX a configure-time option or a configure.ac-settable value. */ lt_fatal (__FILE__, __LINE__, "unrecognized %s option: '%s'", ltwrapper_option_prefix, argv[i]); } /* otherwise ... */ newargz[++newargc] = xstrdup (argv[i]); } newargz[++newargc] = NULL; EOF cat <<EOF /* The GNU banner must be the first non-error debug message */ lt_debugprintf (__FILE__, __LINE__, "libtool wrapper (GNU $PACKAGE) $VERSION\n"); EOF cat <<"EOF" lt_debugprintf (__FILE__, __LINE__, "(main) argv[0]: %s\n", argv[0]); lt_debugprintf (__FILE__, __LINE__, "(main) program_name: %s\n", program_name); tmp_pathspec = find_executable (argv[0]); if (tmp_pathspec == NULL) lt_fatal (__FILE__, __LINE__, "couldn't find %s", argv[0]); lt_debugprintf (__FILE__, __LINE__, "(main) found exe (before symlink chase) at: %s\n", tmp_pathspec); actual_cwrapper_path = chase_symlinks (tmp_pathspec); lt_debugprintf (__FILE__, __LINE__, "(main) found exe (after symlink chase) at: %s\n", actual_cwrapper_path); XFREE (tmp_pathspec); actual_cwrapper_name = xstrdup (base_name (actual_cwrapper_path)); strendzap (actual_cwrapper_path, actual_cwrapper_name); /* wrapper name transforms */ strendzap (actual_cwrapper_name, ".exe"); tmp_pathspec = lt_extend_str (actual_cwrapper_name, ".exe", 1); XFREE (actual_cwrapper_name); actual_cwrapper_name = tmp_pathspec; tmp_pathspec = 0; /* target_name transforms -- use actual target program name; might have lt- prefix */ target_name = xstrdup (base_name (TARGET_PROGRAM_NAME)); strendzap (target_name, ".exe"); tmp_pathspec = lt_extend_str (target_name, ".exe", 1); XFREE (target_name); target_name = tmp_pathspec; tmp_pathspec = 0; lt_debugprintf (__FILE__, __LINE__, "(main) libtool target name: %s\n", target_name); EOF cat <<EOF newargz[0] = XMALLOC (char, (strlen (actual_cwrapper_path) + strlen ("$objdir") + 1 + strlen (actual_cwrapper_name) + 1)); strcpy (newargz[0], actual_cwrapper_path); strcat (newargz[0], "$objdir"); strcat (newargz[0], "/"); EOF cat <<"EOF" /* stop here, and copy so we don't have to do this twice */ tmp_pathspec = xstrdup (newargz[0]); /* do NOT want the lt- prefix here, so use actual_cwrapper_name */ strcat (newargz[0], actual_cwrapper_name); /* DO want the lt- prefix here if it exists, so use target_name */ lt_argv_zero = lt_extend_str (tmp_pathspec, target_name, 1); XFREE (tmp_pathspec); tmp_pathspec = NULL; EOF case $host_os in mingw*) cat <<"EOF" { char* p; while ((p = strchr (newargz[0], '\\')) != NULL) { *p = '/'; } while ((p = strchr (lt_argv_zero, '\\')) != NULL) { *p = '/'; } } EOF ;; esac cat <<"EOF" XFREE (target_name); XFREE (actual_cwrapper_path); XFREE (actual_cwrapper_name); lt_setenv ("BIN_SH", "xpg4"); /* for Tru64 */ lt_setenv ("DUALCASE", "1"); /* for MSK sh */ /* Update the DLL searchpath. EXE_PATH_VALUE ($dllsearchpath) must be prepended before (that is, appear after) LIB_PATH_VALUE ($temp_rpath) because on Windows, both *_VARNAMEs are PATH but uninstalled libraries must come first. */ lt_update_exe_path (EXE_PATH_VARNAME, EXE_PATH_VALUE); lt_update_lib_path (LIB_PATH_VARNAME, LIB_PATH_VALUE); lt_debugprintf (__FILE__, __LINE__, "(main) lt_argv_zero: %s\n", nonnull (lt_argv_zero)); for (i = 0; i < newargc; i++) { lt_debugprintf (__FILE__, __LINE__, "(main) newargz[%d]: %s\n", i, nonnull (newargz[i])); } EOF case $host_os in mingw*) cat <<"EOF" /* execv doesn't actually work on mingw as expected on unix */ newargz = prepare_spawn (newargz); rval = (int) _spawnv (_P_WAIT, lt_argv_zero, (const char * const *) newargz); if (rval == -1) { /* failed to start process */ lt_debugprintf (__FILE__, __LINE__, "(main) failed to launch target \"%s\": %s\n", lt_argv_zero, nonnull (strerror (errno))); return 127; } return rval; EOF ;; *) cat <<"EOF" execv (lt_argv_zero, newargz); return rval; /* =127, but avoids unused variable warning */ EOF ;; esac cat <<"EOF" } void * xmalloc (size_t num) { void *p = (void *) malloc (num); if (!p) lt_fatal (__FILE__, __LINE__, "memory exhausted"); return p; } char * xstrdup (const char *string) { return string ? strcpy ((char *) xmalloc (strlen (string) + 1), string) : NULL; } const char * base_name (const char *name) { const char *base; #if defined HAVE_DOS_BASED_FILE_SYSTEM /* Skip over the disk name in MSDOS pathnames. */ if (isalpha ((unsigned char) name[0]) && name[1] == ':') name += 2; #endif for (base = name; *name; name++) if (IS_DIR_SEPARATOR (*name)) base = name + 1; return base; } int check_executable (const char *path) { struct stat st; lt_debugprintf (__FILE__, __LINE__, "(check_executable): %s\n", nonempty (path)); if ((!path) || (!*path)) return 0; if ((stat (path, &st) >= 0) && (st.st_mode & (S_IXUSR | S_IXGRP | S_IXOTH))) return 1; else return 0; } int make_executable (const char *path) { int rval = 0; struct stat st; lt_debugprintf (__FILE__, __LINE__, "(make_executable): %s\n", nonempty (path)); if ((!path) || (!*path)) return 0; if (stat (path, &st) >= 0) { rval = chmod (path, st.st_mode | S_IXOTH | S_IXGRP | S_IXUSR); } return rval; } /* Searches for the full path of the wrapper. Returns newly allocated full path name if found, NULL otherwise Does not chase symlinks, even on platforms that support them. */ char * find_executable (const char *wrapper) { int has_slash = 0; const char *p; const char *p_next; /* static buffer for getcwd */ char tmp[LT_PATHMAX + 1]; size_t tmp_len; char *concat_name; lt_debugprintf (__FILE__, __LINE__, "(find_executable): %s\n", nonempty (wrapper)); if ((wrapper == NULL) || (*wrapper == '\0')) return NULL; /* Absolute path? */ #if defined HAVE_DOS_BASED_FILE_SYSTEM if (isalpha ((unsigned char) wrapper[0]) && wrapper[1] == ':') { concat_name = xstrdup (wrapper); if (check_executable (concat_name)) return concat_name; XFREE (concat_name); } else { #endif if (IS_DIR_SEPARATOR (wrapper[0])) { concat_name = xstrdup (wrapper); if (check_executable (concat_name)) return concat_name; XFREE (concat_name); } #if defined HAVE_DOS_BASED_FILE_SYSTEM } #endif for (p = wrapper; *p; p++) if (*p == '/') { has_slash = 1; break; } if (!has_slash) { /* no slashes; search PATH */ const char *path = getenv ("PATH"); if (path != NULL) { for (p = path; *p; p = p_next) { const char *q; size_t p_len; for (q = p; *q; q++) if (IS_PATH_SEPARATOR (*q)) break; p_len = (size_t) (q - p); p_next = (*q == '\0' ? q : q + 1); if (p_len == 0) { /* empty path: current directory */ if (getcwd (tmp, LT_PATHMAX) == NULL) lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", nonnull (strerror (errno))); tmp_len = strlen (tmp); concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); memcpy (concat_name, tmp, tmp_len); concat_name[tmp_len] = '/'; strcpy (concat_name + tmp_len + 1, wrapper); } else { concat_name = XMALLOC (char, p_len + 1 + strlen (wrapper) + 1); memcpy (concat_name, p, p_len); concat_name[p_len] = '/'; strcpy (concat_name + p_len + 1, wrapper); } if (check_executable (concat_name)) return concat_name; XFREE (concat_name); } } /* not found in PATH; assume curdir */ } /* Relative path | not found in path: prepend cwd */ if (getcwd (tmp, LT_PATHMAX) == NULL) lt_fatal (__FILE__, __LINE__, "getcwd failed: %s", nonnull (strerror (errno))); tmp_len = strlen (tmp); concat_name = XMALLOC (char, tmp_len + 1 + strlen (wrapper) + 1); memcpy (concat_name, tmp, tmp_len); concat_name[tmp_len] = '/'; strcpy (concat_name + tmp_len + 1, wrapper); if (check_executable (concat_name)) return concat_name; XFREE (concat_name); return NULL; } char * chase_symlinks (const char *pathspec) { #ifndef S_ISLNK return xstrdup (pathspec); #else char buf[LT_PATHMAX]; struct stat s; char *tmp_pathspec = xstrdup (pathspec); char *p; int has_symlinks = 0; while (strlen (tmp_pathspec) && !has_symlinks) { lt_debugprintf (__FILE__, __LINE__, "checking path component for symlinks: %s\n", tmp_pathspec); if (lstat (tmp_pathspec, &s) == 0) { if (S_ISLNK (s.st_mode) != 0) { has_symlinks = 1; break; } /* search backwards for last DIR_SEPARATOR */ p = tmp_pathspec + strlen (tmp_pathspec) - 1; while ((p > tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) p--; if ((p == tmp_pathspec) && (!IS_DIR_SEPARATOR (*p))) { /* no more DIR_SEPARATORS left */ break; } *p = '\0'; } else { lt_fatal (__FILE__, __LINE__, "error accessing file \"%s\": %s", tmp_pathspec, nonnull (strerror (errno))); } } XFREE (tmp_pathspec); if (!has_symlinks) { return xstrdup (pathspec); } tmp_pathspec = realpath (pathspec, buf); if (tmp_pathspec == 0) { lt_fatal (__FILE__, __LINE__, "could not follow symlinks for %s", pathspec); } return xstrdup (tmp_pathspec); #endif } char * strendzap (char *str, const char *pat) { size_t len, patlen; assert (str != NULL); assert (pat != NULL); len = strlen (str); patlen = strlen (pat); if (patlen <= len) { str += len - patlen; if (STREQ (str, pat)) *str = '\0'; } return str; } void lt_debugprintf (const char *file, int line, const char *fmt, ...) { va_list args; if (lt_debug) { (void) fprintf (stderr, "%s:%s:%d: ", program_name, file, line); va_start (args, fmt); (void) vfprintf (stderr, fmt, args); va_end (args); } } static void lt_error_core (int exit_status, const char *file, int line, const char *mode, const char *message, va_list ap) { fprintf (stderr, "%s:%s:%d: %s: ", program_name, file, line, mode); vfprintf (stderr, message, ap); fprintf (stderr, ".\n"); if (exit_status >= 0) exit (exit_status); } void lt_fatal (const char *file, int line, const char *message, ...) { va_list ap; va_start (ap, message); lt_error_core (EXIT_FAILURE, file, line, "FATAL", message, ap); va_end (ap); } static const char * nonnull (const char *s) { return s ? s : "(null)"; } static const char * nonempty (const char *s) { return (s && !*s) ? "(empty)" : nonnull (s); } void lt_setenv (const char *name, const char *value) { lt_debugprintf (__FILE__, __LINE__, "(lt_setenv) setting '%s' to '%s'\n", nonnull (name), nonnull (value)); { #ifdef HAVE_SETENV /* always make a copy, for consistency with !HAVE_SETENV */ char *str = xstrdup (value); setenv (name, str, 1); #else size_t len = strlen (name) + 1 + strlen (value) + 1; char *str = XMALLOC (char, len); sprintf (str, "%s=%s", name, value); if (putenv (str) != EXIT_SUCCESS) { XFREE (str); } #endif } } char * lt_extend_str (const char *orig_value, const char *add, int to_end) { char *new_value; if (orig_value && *orig_value) { size_t orig_value_len = strlen (orig_value); size_t add_len = strlen (add); new_value = XMALLOC (char, add_len + orig_value_len + 1); if (to_end) { strcpy (new_value, orig_value); strcpy (new_value + orig_value_len, add); } else { strcpy (new_value, add); strcpy (new_value + add_len, orig_value); } } else { new_value = xstrdup (add); } return new_value; } void lt_update_exe_path (const char *name, const char *value) { lt_debugprintf (__FILE__, __LINE__, "(lt_update_exe_path) modifying '%s' by prepending '%s'\n", nonnull (name), nonnull (value)); if (name && *name && value && *value) { char *new_value = lt_extend_str (getenv (name), value, 0); /* some systems can't cope with a ':'-terminated path #' */ size_t len = strlen (new_value); while ((len > 0) && IS_PATH_SEPARATOR (new_value[len-1])) { new_value[--len] = '\0'; } lt_setenv (name, new_value); XFREE (new_value); } } void lt_update_lib_path (const char *name, const char *value) { lt_debugprintf (__FILE__, __LINE__, "(lt_update_lib_path) modifying '%s' by prepending '%s'\n", nonnull (name), nonnull (value)); if (name && *name && value && *value) { char *new_value = lt_extend_str (getenv (name), value, 0); lt_setenv (name, new_value); XFREE (new_value); } } EOF case $host_os in mingw*) cat <<"EOF" /* Prepares an argument vector before calling spawn(). Note that spawn() does not by itself call the command interpreter (getenv ("COMSPEC") != NULL ? getenv ("COMSPEC") : ({ OSVERSIONINFO v; v.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); GetVersionEx(&v); v.dwPlatformId == VER_PLATFORM_WIN32_NT; }) ? "cmd.exe" : "command.com"). Instead it simply concatenates the arguments, separated by ' ', and calls CreateProcess(). We must quote the arguments since Win32 CreateProcess() interprets characters like ' ', '\t', '\\', '"' (but not '<' and '>') in a special way: - Space and tab are interpreted as delimiters. They are not treated as delimiters if they are surrounded by double quotes: "...". - Unescaped double quotes are removed from the input. Their only effect is that within double quotes, space and tab are treated like normal characters. - Backslashes not followed by double quotes are not special. - But 2*n+1 backslashes followed by a double quote become n backslashes followed by a double quote (n >= 0): \" -> " \\\" -> \" \\\\\" -> \\" */ #define SHELL_SPECIAL_CHARS "\"\\ \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037" #define SHELL_SPACE_CHARS " \001\002\003\004\005\006\007\010\011\012\013\014\015\016\017\020\021\022\023\024\025\026\027\030\031\032\033\034\035\036\037" char ** prepare_spawn (char **argv) { size_t argc; char **new_argv; size_t i; /* Count number of arguments. */ for (argc = 0; argv[argc] != NULL; argc++) ; /* Allocate new argument vector. */ new_argv = XMALLOC (char *, argc + 1); /* Put quoted arguments into the new argument vector. */ for (i = 0; i < argc; i++) { const char *string = argv[i]; if (string[0] == '\0') new_argv[i] = xstrdup ("\"\""); else if (strpbrk (string, SHELL_SPECIAL_CHARS) != NULL) { int quote_around = (strpbrk (string, SHELL_SPACE_CHARS) != NULL); size_t length; unsigned int backslashes; const char *s; char *quoted_string; char *p; length = 0; backslashes = 0; if (quote_around) length++; for (s = string; *s != '\0'; s++) { char c = *s; if (c == '"') length += backslashes + 1; length++; if (c == '\\') backslashes++; else backslashes = 0; } if (quote_around) length += backslashes + 1; quoted_string = XMALLOC (char, length + 1); p = quoted_string; backslashes = 0; if (quote_around) *p++ = '"'; for (s = string; *s != '\0'; s++) { char c = *s; if (c == '"') { unsigned int j; for (j = backslashes + 1; j > 0; j--) *p++ = '\\'; } *p++ = c; if (c == '\\') backslashes++; else backslashes = 0; } if (quote_around) { unsigned int j; for (j = backslashes; j > 0; j--) *p++ = '\\'; *p++ = '"'; } *p = '\0'; new_argv[i] = quoted_string; } else new_argv[i] = (char *) string; } new_argv[argc] = NULL; return new_argv; } EOF ;; esac cat <<"EOF" void lt_dump_script (FILE* f) { EOF func_emit_wrapper yes | $SED -n -e ' s/^\(.\{79\}\)\(..*\)/\1\ \2/ h s/\([\\"]\)/\\\1/g s/$/\\n/ s/\([^\n]*\).*/ fputs ("\1", f);/p g D' cat <<"EOF" } EOF } # end: func_emit_cwrapperexe_src # func_win32_import_lib_p ARG # True if ARG is an import lib, as indicated by $file_magic_cmd func_win32_import_lib_p () { $debug_cmd case `eval $file_magic_cmd \"\$1\" 2>/dev/null | $SED -e 10q` in *import*) : ;; *) false ;; esac } # func_suncc_cstd_abi # !!ONLY CALL THIS FOR SUN CC AFTER $compile_command IS FULLY EXPANDED!! # Several compiler flags select an ABI that is incompatible with the # Cstd library. Avoid specifying it if any are in CXXFLAGS. func_suncc_cstd_abi () { $debug_cmd case " $compile_command " in *" -compat=g "*|*\ -std=c++[0-9][0-9]\ *|*" -library=stdcxx4 "*|*" -library=stlport4 "*) suncc_use_cstd_abi=no ;; *) suncc_use_cstd_abi=yes ;; esac } # func_mode_link arg... func_mode_link () { $debug_cmd case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) # It is impossible to link a dll without this setting, and # we shouldn't force the makefile maintainer to figure out # what system we are compiling for in order to pass an extra # flag for every libtool invocation. # allow_undefined=no # FIXME: Unfortunately, there are problems with the above when trying # to make a dll that has undefined symbols, in which case not # even a static library is built. For now, we need to specify # -no-undefined on the libtool link line when we can be certain # that all symbols are satisfied, otherwise we get a static library. allow_undefined=yes ;; *) allow_undefined=yes ;; esac libtool_args=$nonopt base_compile="$nonopt $@" compile_command=$nonopt finalize_command=$nonopt compile_rpath= finalize_rpath= compile_shlibpath= finalize_shlibpath= convenience= old_convenience= deplibs= old_deplibs= compiler_flags= linker_flags= dllsearchpath= lib_search_path=`pwd` inst_prefix_dir= new_inherited_linker_flags= avoid_version=no bindir= dlfiles= dlprefiles= dlself=no export_dynamic=no export_symbols= export_symbols_regex= generated= libobjs= ltlibs= module=no no_install=no objs= os2dllname= non_pic_objects= precious_files_regex= prefer_static_libs=no preload=false prev= prevarg= release= rpath= xrpath= perm_rpath= temp_rpath= thread_safe=no vinfo= vinfo_number=no weak_libs= single_module=$wl-single_module func_infer_tag $base_compile # We need to know -static, to get the right output filenames. for arg do case $arg in -shared) test yes != "$build_libtool_libs" \ && func_fatal_configuration "cannot build a shared library" build_old_libs=no break ;; -all-static | -static | -static-libtool-libs) case $arg in -all-static) if test yes = "$build_libtool_libs" && test -z "$link_static_flag"; then func_warning "complete static linking is impossible in this configuration" fi if test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi prefer_static_libs=yes ;; -static) if test -z "$pic_flag" && test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi prefer_static_libs=built ;; -static-libtool-libs) if test -z "$pic_flag" && test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi prefer_static_libs=yes ;; esac build_libtool_libs=no build_old_libs=yes break ;; esac done # See if our shared archives depend on static archives. test -n "$old_archive_from_new_cmds" && build_old_libs=yes # Go through the arguments, transforming them on the way. while test "$#" -gt 0; do arg=$1 shift func_quote_for_eval "$arg" qarg=$func_quote_for_eval_unquoted_result func_append libtool_args " $func_quote_for_eval_result" # If the previous option needs an argument, assign it. if test -n "$prev"; then case $prev in output) func_append compile_command " @OUTPUT@" func_append finalize_command " @OUTPUT@" ;; esac case $prev in bindir) bindir=$arg prev= continue ;; dlfiles|dlprefiles) $preload || { # Add the symbol object into the linking commands. func_append compile_command " @SYMFILE@" func_append finalize_command " @SYMFILE@" preload=: } case $arg in *.la | *.lo) ;; # We handle these cases below. force) if test no = "$dlself"; then dlself=needless export_dynamic=yes fi prev= continue ;; self) if test dlprefiles = "$prev"; then dlself=yes elif test dlfiles = "$prev" && test yes != "$dlopen_self"; then dlself=yes else dlself=needless export_dynamic=yes fi prev= continue ;; *) if test dlfiles = "$prev"; then func_append dlfiles " $arg" else func_append dlprefiles " $arg" fi prev= continue ;; esac ;; expsyms) export_symbols=$arg test -f "$arg" \ || func_fatal_error "symbol file '$arg' does not exist" prev= continue ;; expsyms_regex) export_symbols_regex=$arg prev= continue ;; framework) case $host in *-*-darwin*) case "$deplibs " in *" $qarg.ltframework "*) ;; *) func_append deplibs " $qarg.ltframework" # this is fixed later ;; esac ;; esac prev= continue ;; inst_prefix) inst_prefix_dir=$arg prev= continue ;; mllvm) # Clang does not use LLVM to link, so we can simply discard any # '-mllvm $arg' options when doing the link step. prev= continue ;; objectlist) if test -f "$arg"; then save_arg=$arg moreargs= for fil in `cat "$save_arg"` do # func_append moreargs " $fil" arg=$fil # A libtool-controlled object. # Check to see that this really is a libtool object. if func_lalib_unsafe_p "$arg"; then pic_object= non_pic_object= # Read the .lo file func_source "$arg" if test -z "$pic_object" || test -z "$non_pic_object" || test none = "$pic_object" && test none = "$non_pic_object"; then func_fatal_error "cannot find name of object for '$arg'" fi # Extract subdirectory from the argument. func_dirname "$arg" "/" "" xdir=$func_dirname_result if test none != "$pic_object"; then # Prepend the subdirectory the object is found in. pic_object=$xdir$pic_object if test dlfiles = "$prev"; then if test yes = "$build_libtool_libs" && test yes = "$dlopen_support"; then func_append dlfiles " $pic_object" prev= continue else # If libtool objects are unsupported, then we need to preload. prev=dlprefiles fi fi # CHECK ME: I think I busted this. -Ossama if test dlprefiles = "$prev"; then # Preload the old-style object. func_append dlprefiles " $pic_object" prev= fi # A PIC object. func_append libobjs " $pic_object" arg=$pic_object fi # Non-PIC object. if test none != "$non_pic_object"; then # Prepend the subdirectory the object is found in. non_pic_object=$xdir$non_pic_object # A standard non-PIC object func_append non_pic_objects " $non_pic_object" if test -z "$pic_object" || test none = "$pic_object"; then arg=$non_pic_object fi else # If the PIC object exists, use it instead. # $xdir was prepended to $pic_object above. non_pic_object=$pic_object func_append non_pic_objects " $non_pic_object" fi else # Only an error if not doing a dry-run. if $opt_dry_run; then # Extract subdirectory from the argument. func_dirname "$arg" "/" "" xdir=$func_dirname_result func_lo2o "$arg" pic_object=$xdir$objdir/$func_lo2o_result non_pic_object=$xdir$func_lo2o_result func_append libobjs " $pic_object" func_append non_pic_objects " $non_pic_object" else func_fatal_error "'$arg' is not a valid libtool object" fi fi done else func_fatal_error "link input file '$arg' does not exist" fi arg=$save_arg prev= continue ;; os2dllname) os2dllname=$arg prev= continue ;; precious_regex) precious_files_regex=$arg prev= continue ;; release) release=-$arg prev= continue ;; rpath | xrpath) # We need an absolute path. case $arg in [\\/]* | [A-Za-z]:[\\/]*) ;; *) func_fatal_error "only absolute run-paths are allowed" ;; esac if test rpath = "$prev"; then case "$rpath " in *" $arg "*) ;; *) func_append rpath " $arg" ;; esac else case "$xrpath " in *" $arg "*) ;; *) func_append xrpath " $arg" ;; esac fi prev= continue ;; shrext) shrext_cmds=$arg prev= continue ;; weak) func_append weak_libs " $arg" prev= continue ;; xcclinker) func_append linker_flags " $qarg" func_append compiler_flags " $qarg" prev= func_append compile_command " $qarg" func_append finalize_command " $qarg" continue ;; xcompiler) func_append compiler_flags " $qarg" prev= func_append compile_command " $qarg" func_append finalize_command " $qarg" continue ;; xlinker) func_append linker_flags " $qarg" func_append compiler_flags " $wl$qarg" prev= func_append compile_command " $wl$qarg" func_append finalize_command " $wl$qarg" continue ;; *) eval "$prev=\"\$arg\"" prev= continue ;; esac fi # test -n "$prev" prevarg=$arg case $arg in -all-static) if test -n "$link_static_flag"; then # See comment for -static flag below, for more details. func_append compile_command " $link_static_flag" func_append finalize_command " $link_static_flag" fi continue ;; -allow-undefined) # FIXME: remove this flag sometime in the future. func_fatal_error "'-allow-undefined' must not be used because it is the default" ;; -avoid-version) avoid_version=yes continue ;; -bindir) prev=bindir continue ;; -dlopen) prev=dlfiles continue ;; -dlpreopen) prev=dlprefiles continue ;; -export-dynamic) export_dynamic=yes continue ;; -export-symbols | -export-symbols-regex) if test -n "$export_symbols" || test -n "$export_symbols_regex"; then func_fatal_error "more than one -exported-symbols argument is not allowed" fi if test X-export-symbols = "X$arg"; then prev=expsyms else prev=expsyms_regex fi continue ;; -framework) prev=framework continue ;; -inst-prefix-dir) prev=inst_prefix continue ;; # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:* # so, if we see these flags be careful not to treat them like -L -L[A-Z][A-Z]*:*) case $with_gcc/$host in no/*-*-irix* | /*-*-irix*) func_append compile_command " $arg" func_append finalize_command " $arg" ;; esac continue ;; -L*) func_stripname "-L" '' "$arg" if test -z "$func_stripname_result"; then if test "$#" -gt 0; then func_fatal_error "require no space between '-L' and '$1'" else func_fatal_error "need path for '-L' option" fi fi func_resolve_sysroot "$func_stripname_result" dir=$func_resolve_sysroot_result # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) ;; *) absdir=`cd "$dir" && pwd` test -z "$absdir" && \ func_fatal_error "cannot determine absolute directory name of '$dir'" dir=$absdir ;; esac case "$deplibs " in *" -L$dir "* | *" $arg "*) # Will only happen for absolute or sysroot arguments ;; *) # Preserve sysroot, but never include relative directories case $dir in [\\/]* | [A-Za-z]:[\\/]* | =*) func_append deplibs " $arg" ;; *) func_append deplibs " -L$dir" ;; esac func_append lib_search_path " $dir" ;; esac case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) testbindir=`$ECHO "$dir" | $SED 's*/lib$*/bin*'` case :$dllsearchpath: in *":$dir:"*) ;; ::) dllsearchpath=$dir;; *) func_append dllsearchpath ":$dir";; esac case :$dllsearchpath: in *":$testbindir:"*) ;; ::) dllsearchpath=$testbindir;; *) func_append dllsearchpath ":$testbindir";; esac ;; esac continue ;; -l*) if test X-lc = "X$arg" || test X-lm = "X$arg"; then case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos* | *-cegcc* | *-*-haiku*) # These systems don't actually have a C or math library (as such) continue ;; *-*-os2*) # These systems don't actually have a C library (as such) test X-lc = "X$arg" && continue ;; *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-bitrig*) # Do not include libc due to us having libc/libc_r. test X-lc = "X$arg" && continue ;; *-*-rhapsody* | *-*-darwin1.[012]) # Rhapsody C and math libraries are in the System framework func_append deplibs " System.ltframework" continue ;; *-*-sco3.2v5* | *-*-sco5v6*) # Causes problems with __ctype test X-lc = "X$arg" && continue ;; *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) # Compiler inserts libc in the correct place for threads to work test X-lc = "X$arg" && continue ;; esac elif test X-lc_r = "X$arg"; then case $host in *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* | *-*-bitrig*) # Do not include libc_r directly, use -pthread flag. continue ;; esac fi func_append deplibs " $arg" continue ;; -mllvm) prev=mllvm continue ;; -module) module=yes continue ;; # Tru64 UNIX uses -model [arg] to determine the layout of C++ # classes, name mangling, and exception handling. # Darwin uses the -arch flag to determine output architecture. -model|-arch|-isysroot|--sysroot) func_append compiler_flags " $arg" func_append compile_command " $arg" func_append finalize_command " $arg" prev=xcompiler continue ;; -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) func_append compiler_flags " $arg" func_append compile_command " $arg" func_append finalize_command " $arg" case "$new_inherited_linker_flags " in *" $arg "*) ;; * ) func_append new_inherited_linker_flags " $arg" ;; esac continue ;; -multi_module) single_module=$wl-multi_module continue ;; -no-fast-install) fast_install=no continue ;; -no-install) case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin* | *-cegcc*) # The PATH hackery in wrapper scripts is required on Windows # and Darwin in order for the loader to find any dlls it needs. func_warning "'-no-install' is ignored for $host" func_warning "assuming '-no-fast-install' instead" fast_install=no ;; *) no_install=yes ;; esac continue ;; -no-undefined) allow_undefined=no continue ;; -objectlist) prev=objectlist continue ;; -os2dllname) prev=os2dllname continue ;; -o) prev=output ;; -precious-files-regex) prev=precious_regex continue ;; -release) prev=release continue ;; -rpath) prev=rpath continue ;; -R) prev=xrpath continue ;; -R*) func_stripname '-R' '' "$arg" dir=$func_stripname_result # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) ;; =*) func_stripname '=' '' "$dir" dir=$lt_sysroot$func_stripname_result ;; *) func_fatal_error "only absolute run-paths are allowed" ;; esac case "$xrpath " in *" $dir "*) ;; *) func_append xrpath " $dir" ;; esac continue ;; -shared) # The effects of -shared are defined in a previous loop. continue ;; -shrext) prev=shrext continue ;; -static | -static-libtool-libs) # The effects of -static are defined in a previous loop. # We used to do the same as -all-static on platforms that # didn't have a PIC flag, but the assumption that the effects # would be equivalent was wrong. It would break on at least # Digital Unix and AIX. continue ;; -thread-safe) thread_safe=yes continue ;; -version-info) prev=vinfo continue ;; -version-number) prev=vinfo vinfo_number=yes continue ;; -weak) prev=weak continue ;; -Wc,*) func_stripname '-Wc,' '' "$arg" args=$func_stripname_result arg= save_ifs=$IFS; IFS=, for flag in $args; do IFS=$save_ifs func_quote_for_eval "$flag" func_append arg " $func_quote_for_eval_result" func_append compiler_flags " $func_quote_for_eval_result" done IFS=$save_ifs func_stripname ' ' '' "$arg" arg=$func_stripname_result ;; -Wl,*) func_stripname '-Wl,' '' "$arg" args=$func_stripname_result arg= save_ifs=$IFS; IFS=, for flag in $args; do IFS=$save_ifs func_quote_for_eval "$flag" func_append arg " $wl$func_quote_for_eval_result" func_append compiler_flags " $wl$func_quote_for_eval_result" func_append linker_flags " $func_quote_for_eval_result" done IFS=$save_ifs func_stripname ' ' '' "$arg" arg=$func_stripname_result ;; -Xcompiler) prev=xcompiler continue ;; -Xlinker) prev=xlinker continue ;; -XCClinker) prev=xcclinker continue ;; # -msg_* for osf cc -msg_*) func_quote_for_eval "$arg" arg=$func_quote_for_eval_result ;; # Flags to be passed through unchanged, with rationale: # -64, -mips[0-9] enable 64-bit mode for the SGI compiler # -r[0-9][0-9]* specify processor for the SGI compiler # -xarch=*, -xtarget=* enable 64-bit mode for the Sun compiler # +DA*, +DD* enable 64-bit mode for the HP compiler # -q* compiler args for the IBM compiler # -m*, -t[45]*, -txscale* architecture-specific flags for GCC # -F/path path to uninstalled frameworks, gcc on darwin # -p, -pg, --coverage, -fprofile-* profiling flags for GCC # -fstack-protector* stack protector flags for GCC # @file GCC response files # -tp=* Portland pgcc target processor selection # --sysroot=* for sysroot support # -O*, -g*, -flto*, -fwhopr*, -fuse-linker-plugin GCC link-time optimization # -specs=* GCC specs files # -stdlib=* select c++ std lib with clang -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*|-tp=*|--sysroot=*| \ -O*|-g*|-flto*|-fwhopr*|-fuse-linker-plugin|-fstack-protector*|-stdlib=*| \ -specs=*) func_quote_for_eval "$arg" arg=$func_quote_for_eval_result func_append compile_command " $arg" func_append finalize_command " $arg" func_append compiler_flags " $arg" continue ;; -Z*) if test os2 = "`expr $host : '.*\(os2\)'`"; then # OS/2 uses -Zxxx to specify OS/2-specific options compiler_flags="$compiler_flags $arg" func_append compile_command " $arg" func_append finalize_command " $arg" case $arg in -Zlinker | -Zstack) prev=xcompiler ;; esac continue else # Otherwise treat like 'Some other compiler flag' below func_quote_for_eval "$arg" arg=$func_quote_for_eval_result fi ;; # Some other compiler flag. -* | +*) func_quote_for_eval "$arg" arg=$func_quote_for_eval_result ;; *.$objext) # A standard object. func_append objs " $arg" ;; *.lo) # A libtool-controlled object. # Check to see that this really is a libtool object. if func_lalib_unsafe_p "$arg"; then pic_object= non_pic_object= # Read the .lo file func_source "$arg" if test -z "$pic_object" || test -z "$non_pic_object" || test none = "$pic_object" && test none = "$non_pic_object"; then func_fatal_error "cannot find name of object for '$arg'" fi # Extract subdirectory from the argument. func_dirname "$arg" "/" "" xdir=$func_dirname_result test none = "$pic_object" || { # Prepend the subdirectory the object is found in. pic_object=$xdir$pic_object if test dlfiles = "$prev"; then if test yes = "$build_libtool_libs" && test yes = "$dlopen_support"; then func_append dlfiles " $pic_object" prev= continue else # If libtool objects are unsupported, then we need to preload. prev=dlprefiles fi fi # CHECK ME: I think I busted this. -Ossama if test dlprefiles = "$prev"; then # Preload the old-style object. func_append dlprefiles " $pic_object" prev= fi # A PIC object. func_append libobjs " $pic_object" arg=$pic_object } # Non-PIC object. if test none != "$non_pic_object"; then # Prepend the subdirectory the object is found in. non_pic_object=$xdir$non_pic_object # A standard non-PIC object func_append non_pic_objects " $non_pic_object" if test -z "$pic_object" || test none = "$pic_object"; then arg=$non_pic_object fi else # If the PIC object exists, use it instead. # $xdir was prepended to $pic_object above. non_pic_object=$pic_object func_append non_pic_objects " $non_pic_object" fi else # Only an error if not doing a dry-run. if $opt_dry_run; then # Extract subdirectory from the argument. func_dirname "$arg" "/" "" xdir=$func_dirname_result func_lo2o "$arg" pic_object=$xdir$objdir/$func_lo2o_result non_pic_object=$xdir$func_lo2o_result func_append libobjs " $pic_object" func_append non_pic_objects " $non_pic_object" else func_fatal_error "'$arg' is not a valid libtool object" fi fi ;; *.$libext) # An archive. func_append deplibs " $arg" func_append old_deplibs " $arg" continue ;; *.la) # A libtool-controlled library. func_resolve_sysroot "$arg" if test dlfiles = "$prev"; then # This library was specified with -dlopen. func_append dlfiles " $func_resolve_sysroot_result" prev= elif test dlprefiles = "$prev"; then # The library was specified with -dlpreopen. func_append dlprefiles " $func_resolve_sysroot_result" prev= else func_append deplibs " $func_resolve_sysroot_result" fi continue ;; # Some other compiler argument. *) # Unknown arguments in both finalize_command and compile_command need # to be aesthetically quoted because they are evaled later. func_quote_for_eval "$arg" arg=$func_quote_for_eval_result ;; esac # arg # Now actually substitute the argument into the commands. if test -n "$arg"; then func_append compile_command " $arg" func_append finalize_command " $arg" fi done # argument parsing loop test -n "$prev" && \ func_fatal_help "the '$prevarg' option requires an argument" if test yes = "$export_dynamic" && test -n "$export_dynamic_flag_spec"; then eval arg=\"$export_dynamic_flag_spec\" func_append compile_command " $arg" func_append finalize_command " $arg" fi oldlibs= # calculate the name of the file, without its directory func_basename "$output" outputname=$func_basename_result libobjs_save=$libobjs if test -n "$shlibpath_var"; then # get the directories listed in $shlibpath_var eval shlib_search_path=\`\$ECHO \"\$$shlibpath_var\" \| \$SED \'s/:/ /g\'\` else shlib_search_path= fi eval sys_lib_search_path=\"$sys_lib_search_path_spec\" eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\" # Definition is injected by LT_CONFIG during libtool generation. func_munge_path_list sys_lib_dlsearch_path "$LT_SYS_LIBRARY_PATH" func_dirname "$output" "/" "" output_objdir=$func_dirname_result$objdir func_to_tool_file "$output_objdir/" tool_output_objdir=$func_to_tool_file_result # Create the object directory. func_mkdir_p "$output_objdir" # Determine the type of output case $output in "") func_fatal_help "you must specify an output file" ;; *.$libext) linkmode=oldlib ;; *.lo | *.$objext) linkmode=obj ;; *.la) linkmode=lib ;; *) linkmode=prog ;; # Anything else should be a program. esac specialdeplibs= libs= # Find all interdependent deplibs by searching for libraries # that are linked more than once (e.g. -la -lb -la) for deplib in $deplibs; do if $opt_preserve_dup_deps; then case "$libs " in *" $deplib "*) func_append specialdeplibs " $deplib" ;; esac fi func_append libs " $deplib" done if test lib = "$linkmode"; then libs="$predeps $libs $compiler_lib_search_path $postdeps" # Compute libraries that are listed more than once in $predeps # $postdeps and mark them as special (i.e., whose duplicates are # not to be eliminated). pre_post_deps= if $opt_duplicate_compiler_generated_deps; then for pre_post_dep in $predeps $postdeps; do case "$pre_post_deps " in *" $pre_post_dep "*) func_append specialdeplibs " $pre_post_deps" ;; esac func_append pre_post_deps " $pre_post_dep" done fi pre_post_deps= fi deplibs= newdependency_libs= newlib_search_path= need_relink=no # whether we're linking any uninstalled libtool libraries notinst_deplibs= # not-installed libtool libraries notinst_path= # paths that contain not-installed libtool libraries case $linkmode in lib) passes="conv dlpreopen link" for file in $dlfiles $dlprefiles; do case $file in *.la) ;; *) func_fatal_help "libraries can '-dlopen' only libtool libraries: $file" ;; esac done ;; prog) compile_deplibs= finalize_deplibs= alldeplibs=false newdlfiles= newdlprefiles= passes="conv scan dlopen dlpreopen link" ;; *) passes="conv" ;; esac for pass in $passes; do # The preopen pass in lib mode reverses $deplibs; put it back here # so that -L comes before libs that need it for instance... if test lib,link = "$linkmode,$pass"; then ## FIXME: Find the place where the list is rebuilt in the wrong ## order, and fix it there properly tmp_deplibs= for deplib in $deplibs; do tmp_deplibs="$deplib $tmp_deplibs" done deplibs=$tmp_deplibs fi if test lib,link = "$linkmode,$pass" || test prog,scan = "$linkmode,$pass"; then libs=$deplibs deplibs= fi if test prog = "$linkmode"; then case $pass in dlopen) libs=$dlfiles ;; dlpreopen) libs=$dlprefiles ;; link) libs="$deplibs %DEPLIBS% $dependency_libs" ;; esac fi if test lib,dlpreopen = "$linkmode,$pass"; then # Collect and forward deplibs of preopened libtool libs for lib in $dlprefiles; do # Ignore non-libtool-libs dependency_libs= func_resolve_sysroot "$lib" case $lib in *.la) func_source "$func_resolve_sysroot_result" ;; esac # Collect preopened libtool deplibs, except any this library # has declared as weak libs for deplib in $dependency_libs; do func_basename "$deplib" deplib_base=$func_basename_result case " $weak_libs " in *" $deplib_base "*) ;; *) func_append deplibs " $deplib" ;; esac done done libs=$dlprefiles fi if test dlopen = "$pass"; then # Collect dlpreopened libraries save_deplibs=$deplibs deplibs= fi for deplib in $libs; do lib= found=false case $deplib in -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \ |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*) if test prog,link = "$linkmode,$pass"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else func_append compiler_flags " $deplib" if test lib = "$linkmode"; then case "$new_inherited_linker_flags " in *" $deplib "*) ;; * ) func_append new_inherited_linker_flags " $deplib" ;; esac fi fi continue ;; -l*) if test lib != "$linkmode" && test prog != "$linkmode"; then func_warning "'-l' is ignored for archives/objects" continue fi func_stripname '-l' '' "$deplib" name=$func_stripname_result if test lib = "$linkmode"; then searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path" else searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path" fi for searchdir in $searchdirs; do for search_ext in .la $std_shrext .so .a; do # Search the libtool library lib=$searchdir/lib$name$search_ext if test -f "$lib"; then if test .la = "$search_ext"; then found=: else found=false fi break 2 fi done done if $found; then # deplib is a libtool library # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib, # We need to do some special things here, and not later. if test yes = "$allow_libtool_libs_with_static_runtimes"; then case " $predeps $postdeps " in *" $deplib "*) if func_lalib_p "$lib"; then library_names= old_library= func_source "$lib" for l in $old_library $library_names; do ll=$l done if test "X$ll" = "X$old_library"; then # only static version available found=false func_dirname "$lib" "" "." ladir=$func_dirname_result lib=$ladir/$old_library if test prog,link = "$linkmode,$pass"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else deplibs="$deplib $deplibs" test lib = "$linkmode" && newdependency_libs="$deplib $newdependency_libs" fi continue fi fi ;; *) ;; esac fi else # deplib doesn't seem to be a libtool library if test prog,link = "$linkmode,$pass"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else deplibs="$deplib $deplibs" test lib = "$linkmode" && newdependency_libs="$deplib $newdependency_libs" fi continue fi ;; # -l *.ltframework) if test prog,link = "$linkmode,$pass"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else deplibs="$deplib $deplibs" if test lib = "$linkmode"; then case "$new_inherited_linker_flags " in *" $deplib "*) ;; * ) func_append new_inherited_linker_flags " $deplib" ;; esac fi fi continue ;; -L*) case $linkmode in lib) deplibs="$deplib $deplibs" test conv = "$pass" && continue newdependency_libs="$deplib $newdependency_libs" func_stripname '-L' '' "$deplib" func_resolve_sysroot "$func_stripname_result" func_append newlib_search_path " $func_resolve_sysroot_result" ;; prog) if test conv = "$pass"; then deplibs="$deplib $deplibs" continue fi if test scan = "$pass"; then deplibs="$deplib $deplibs" else compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" fi func_stripname '-L' '' "$deplib" func_resolve_sysroot "$func_stripname_result" func_append newlib_search_path " $func_resolve_sysroot_result" ;; *) func_warning "'-L' is ignored for archives/objects" ;; esac # linkmode continue ;; # -L -R*) if test link = "$pass"; then func_stripname '-R' '' "$deplib" func_resolve_sysroot "$func_stripname_result" dir=$func_resolve_sysroot_result # Make sure the xrpath contains only unique directories. case "$xrpath " in *" $dir "*) ;; *) func_append xrpath " $dir" ;; esac fi deplibs="$deplib $deplibs" continue ;; *.la) func_resolve_sysroot "$deplib" lib=$func_resolve_sysroot_result ;; *.$libext) if test conv = "$pass"; then deplibs="$deplib $deplibs" continue fi case $linkmode in lib) # Linking convenience modules into shared libraries is allowed, # but linking other static libraries is non-portable. case " $dlpreconveniencelibs " in *" $deplib "*) ;; *) valid_a_lib=false case $deplibs_check_method in match_pattern*) set dummy $deplibs_check_method; shift match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` if eval "\$ECHO \"$deplib\"" 2>/dev/null | $SED 10q \ | $EGREP "$match_pattern_regex" > /dev/null; then valid_a_lib=: fi ;; pass_all) valid_a_lib=: ;; esac if $valid_a_lib; then echo $ECHO "*** Warning: Linking the shared library $output against the" $ECHO "*** static library $deplib is not portable!" deplibs="$deplib $deplibs" else echo $ECHO "*** Warning: Trying to link with static lib archive $deplib." echo "*** I have the capability to make that library automatically link in when" echo "*** you link to this library. But I can only do this if you have a" echo "*** shared version of the library, which you do not appear to have" echo "*** because the file extensions .$libext of this argument makes me believe" echo "*** that it is just a static archive that I should not use here." fi ;; esac continue ;; prog) if test link != "$pass"; then deplibs="$deplib $deplibs" else compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" fi continue ;; esac # linkmode ;; # *.$libext *.lo | *.$objext) if test conv = "$pass"; then deplibs="$deplib $deplibs" elif test prog = "$linkmode"; then if test dlpreopen = "$pass" || test yes != "$dlopen_support" || test no = "$build_libtool_libs"; then # If there is no dlopen support or we're linking statically, # we need to preload. func_append newdlprefiles " $deplib" compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else func_append newdlfiles " $deplib" fi fi continue ;; %DEPLIBS%) alldeplibs=: continue ;; esac # case $deplib $found || test -f "$lib" \ || func_fatal_error "cannot find the library '$lib' or unhandled argument '$deplib'" # Check to see that this really is a libtool archive. func_lalib_unsafe_p "$lib" \ || func_fatal_error "'$lib' is not a valid libtool archive" func_dirname "$lib" "" "." ladir=$func_dirname_result dlname= dlopen= dlpreopen= libdir= library_names= old_library= inherited_linker_flags= # If the library was installed with an old release of libtool, # it will not redefine variables installed, or shouldnotlink installed=yes shouldnotlink=no avoidtemprpath= # Read the .la file func_source "$lib" # Convert "-framework foo" to "foo.ltframework" if test -n "$inherited_linker_flags"; then tmp_inherited_linker_flags=`$ECHO "$inherited_linker_flags" | $SED 's/-framework \([^ $]*\)/\1.ltframework/g'` for tmp_inherited_linker_flag in $tmp_inherited_linker_flags; do case " $new_inherited_linker_flags " in *" $tmp_inherited_linker_flag "*) ;; *) func_append new_inherited_linker_flags " $tmp_inherited_linker_flag";; esac done fi dependency_libs=`$ECHO " $dependency_libs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` if test lib,link = "$linkmode,$pass" || test prog,scan = "$linkmode,$pass" || { test prog != "$linkmode" && test lib != "$linkmode"; }; then test -n "$dlopen" && func_append dlfiles " $dlopen" test -n "$dlpreopen" && func_append dlprefiles " $dlpreopen" fi if test conv = "$pass"; then # Only check for convenience libraries deplibs="$lib $deplibs" if test -z "$libdir"; then if test -z "$old_library"; then func_fatal_error "cannot find name of link library for '$lib'" fi # It is a libtool convenience library, so add in its objects. func_append convenience " $ladir/$objdir/$old_library" func_append old_convenience " $ladir/$objdir/$old_library" elif test prog != "$linkmode" && test lib != "$linkmode"; then func_fatal_error "'$lib' is not a convenience library" fi tmp_libs= for deplib in $dependency_libs; do deplibs="$deplib $deplibs" if $opt_preserve_dup_deps; then case "$tmp_libs " in *" $deplib "*) func_append specialdeplibs " $deplib" ;; esac fi func_append tmp_libs " $deplib" done continue fi # $pass = conv # Get the name of the library we link against. linklib= if test -n "$old_library" && { test yes = "$prefer_static_libs" || test built,no = "$prefer_static_libs,$installed"; }; then linklib=$old_library else for l in $old_library $library_names; do linklib=$l done fi if test -z "$linklib"; then func_fatal_error "cannot find name of link library for '$lib'" fi # This library was specified with -dlopen. if test dlopen = "$pass"; then test -z "$libdir" \ && func_fatal_error "cannot -dlopen a convenience library: '$lib'" if test -z "$dlname" || test yes != "$dlopen_support" || test no = "$build_libtool_libs" then # If there is no dlname, no dlopen support or we're linking # statically, we need to preload. We also need to preload any # dependent libraries so libltdl's deplib preloader doesn't # bomb out in the load deplibs phase. func_append dlprefiles " $lib $dependency_libs" else func_append newdlfiles " $lib" fi continue fi # $pass = dlopen # We need an absolute path. case $ladir in [\\/]* | [A-Za-z]:[\\/]*) abs_ladir=$ladir ;; *) abs_ladir=`cd "$ladir" && pwd` if test -z "$abs_ladir"; then func_warning "cannot determine absolute directory name of '$ladir'" func_warning "passing it literally to the linker, although it might fail" abs_ladir=$ladir fi ;; esac func_basename "$lib" laname=$func_basename_result # Find the relevant object directory and library name. if test yes = "$installed"; then if test ! -f "$lt_sysroot$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then func_warning "library '$lib' was moved." dir=$ladir absdir=$abs_ladir libdir=$abs_ladir else dir=$lt_sysroot$libdir absdir=$lt_sysroot$libdir fi test yes = "$hardcode_automatic" && avoidtemprpath=yes else if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then dir=$ladir absdir=$abs_ladir # Remove this search path later func_append notinst_path " $abs_ladir" else dir=$ladir/$objdir absdir=$abs_ladir/$objdir # Remove this search path later func_append notinst_path " $abs_ladir" fi fi # $installed = yes func_stripname 'lib' '.la' "$laname" name=$func_stripname_result # This library was specified with -dlpreopen. if test dlpreopen = "$pass"; then if test -z "$libdir" && test prog = "$linkmode"; then func_fatal_error "only libraries may -dlpreopen a convenience library: '$lib'" fi case $host in # special handling for platforms with PE-DLLs. *cygwin* | *mingw* | *cegcc* ) # Linker will automatically link against shared library if both # static and shared are present. Therefore, ensure we extract # symbols from the import library if a shared library is present # (otherwise, the dlopen module name will be incorrect). We do # this by putting the import library name into $newdlprefiles. # We recover the dlopen module name by 'saving' the la file # name in a special purpose variable, and (later) extracting the # dlname from the la file. if test -n "$dlname"; then func_tr_sh "$dir/$linklib" eval "libfile_$func_tr_sh_result=\$abs_ladir/\$laname" func_append newdlprefiles " $dir/$linklib" else func_append newdlprefiles " $dir/$old_library" # Keep a list of preopened convenience libraries to check # that they are being used correctly in the link pass. test -z "$libdir" && \ func_append dlpreconveniencelibs " $dir/$old_library" fi ;; * ) # Prefer using a static library (so that no silly _DYNAMIC symbols # are required to link). if test -n "$old_library"; then func_append newdlprefiles " $dir/$old_library" # Keep a list of preopened convenience libraries to check # that they are being used correctly in the link pass. test -z "$libdir" && \ func_append dlpreconveniencelibs " $dir/$old_library" # Otherwise, use the dlname, so that lt_dlopen finds it. elif test -n "$dlname"; then func_append newdlprefiles " $dir/$dlname" else func_append newdlprefiles " $dir/$linklib" fi ;; esac fi # $pass = dlpreopen if test -z "$libdir"; then # Link the convenience library if test lib = "$linkmode"; then deplibs="$dir/$old_library $deplibs" elif test prog,link = "$linkmode,$pass"; then compile_deplibs="$dir/$old_library $compile_deplibs" finalize_deplibs="$dir/$old_library $finalize_deplibs" else deplibs="$lib $deplibs" # used for prog,scan pass fi continue fi if test prog = "$linkmode" && test link != "$pass"; then func_append newlib_search_path " $ladir" deplibs="$lib $deplibs" linkalldeplibs=false if test no != "$link_all_deplibs" || test -z "$library_names" || test no = "$build_libtool_libs"; then linkalldeplibs=: fi tmp_libs= for deplib in $dependency_libs; do case $deplib in -L*) func_stripname '-L' '' "$deplib" func_resolve_sysroot "$func_stripname_result" func_append newlib_search_path " $func_resolve_sysroot_result" ;; esac # Need to link against all dependency_libs? if $linkalldeplibs; then deplibs="$deplib $deplibs" else # Need to hardcode shared library paths # or/and link against static libraries newdependency_libs="$deplib $newdependency_libs" fi if $opt_preserve_dup_deps; then case "$tmp_libs " in *" $deplib "*) func_append specialdeplibs " $deplib" ;; esac fi func_append tmp_libs " $deplib" done # for deplib continue fi # $linkmode = prog... if test prog,link = "$linkmode,$pass"; then if test -n "$library_names" && { { test no = "$prefer_static_libs" || test built,yes = "$prefer_static_libs,$installed"; } || test -z "$old_library"; }; then # We need to hardcode the library path if test -n "$shlibpath_var" && test -z "$avoidtemprpath"; then # Make sure the rpath contains only unique directories. case $temp_rpath: in *"$absdir:"*) ;; *) func_append temp_rpath "$absdir:" ;; esac fi # Hardcode the library path. # Skip directories that are in the system default run-time # search path. case " $sys_lib_dlsearch_path " in *" $absdir "*) ;; *) case "$compile_rpath " in *" $absdir "*) ;; *) func_append compile_rpath " $absdir" ;; esac ;; esac case " $sys_lib_dlsearch_path " in *" $libdir "*) ;; *) case "$finalize_rpath " in *" $libdir "*) ;; *) func_append finalize_rpath " $libdir" ;; esac ;; esac fi # $linkmode,$pass = prog,link... if $alldeplibs && { test pass_all = "$deplibs_check_method" || { test yes = "$build_libtool_libs" && test -n "$library_names"; }; }; then # We only need to search for static libraries continue fi fi link_static=no # Whether the deplib will be linked statically use_static_libs=$prefer_static_libs if test built = "$use_static_libs" && test yes = "$installed"; then use_static_libs=no fi if test -n "$library_names" && { test no = "$use_static_libs" || test -z "$old_library"; }; then case $host in *cygwin* | *mingw* | *cegcc* | *os2*) # No point in relinking DLLs because paths are not encoded func_append notinst_deplibs " $lib" need_relink=no ;; *) if test no = "$installed"; then func_append notinst_deplibs " $lib" need_relink=yes fi ;; esac # This is a shared library # Warn about portability, can't link against -module's on some # systems (darwin). Don't bleat about dlopened modules though! dlopenmodule= for dlpremoduletest in $dlprefiles; do if test "X$dlpremoduletest" = "X$lib"; then dlopenmodule=$dlpremoduletest break fi done if test -z "$dlopenmodule" && test yes = "$shouldnotlink" && test link = "$pass"; then echo if test prog = "$linkmode"; then $ECHO "*** Warning: Linking the executable $output against the loadable module" else $ECHO "*** Warning: Linking the shared library $output against the loadable module" fi $ECHO "*** $linklib is not portable!" fi if test lib = "$linkmode" && test yes = "$hardcode_into_libs"; then # Hardcode the library path. # Skip directories that are in the system default run-time # search path. case " $sys_lib_dlsearch_path " in *" $absdir "*) ;; *) case "$compile_rpath " in *" $absdir "*) ;; *) func_append compile_rpath " $absdir" ;; esac ;; esac case " $sys_lib_dlsearch_path " in *" $libdir "*) ;; *) case "$finalize_rpath " in *" $libdir "*) ;; *) func_append finalize_rpath " $libdir" ;; esac ;; esac fi if test -n "$old_archive_from_expsyms_cmds"; then # figure out the soname set dummy $library_names shift realname=$1 shift libname=`eval "\\$ECHO \"$libname_spec\""` # use dlname if we got it. it's perfectly good, no? if test -n "$dlname"; then soname=$dlname elif test -n "$soname_spec"; then # bleh windows case $host in *cygwin* | mingw* | *cegcc* | *os2*) func_arith $current - $age major=$func_arith_result versuffix=-$major ;; esac eval soname=\"$soname_spec\" else soname=$realname fi # Make a new name for the extract_expsyms_cmds to use soroot=$soname func_basename "$soroot" soname=$func_basename_result func_stripname 'lib' '.dll' "$soname" newlib=libimp-$func_stripname_result.a # If the library has no export list, then create one now if test -f "$output_objdir/$soname-def"; then : else func_verbose "extracting exported symbol list from '$soname'" func_execute_cmds "$extract_expsyms_cmds" 'exit $?' fi # Create $newlib if test -f "$output_objdir/$newlib"; then :; else func_verbose "generating import library for '$soname'" func_execute_cmds "$old_archive_from_expsyms_cmds" 'exit $?' fi # make sure the library variables are pointing to the new library dir=$output_objdir linklib=$newlib fi # test -n "$old_archive_from_expsyms_cmds" if test prog = "$linkmode" || test relink != "$opt_mode"; then add_shlibpath= add_dir= add= lib_linked=yes case $hardcode_action in immediate | unsupported) if test no = "$hardcode_direct"; then add=$dir/$linklib case $host in *-*-sco3.2v5.0.[024]*) add_dir=-L$dir ;; *-*-sysv4*uw2*) add_dir=-L$dir ;; *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ *-*-unixware7*) add_dir=-L$dir ;; *-*-darwin* ) # if the lib is a (non-dlopened) module then we cannot # link against it, someone is ignoring the earlier warnings if /usr/bin/file -L $add 2> /dev/null | $GREP ": [^:]* bundle" >/dev/null; then if test "X$dlopenmodule" != "X$lib"; then $ECHO "*** Warning: lib $linklib is a module, not a shared library" if test -z "$old_library"; then echo echo "*** And there doesn't seem to be a static archive available" echo "*** The link will probably fail, sorry" else add=$dir/$old_library fi elif test -n "$old_library"; then add=$dir/$old_library fi fi esac elif test no = "$hardcode_minus_L"; then case $host in *-*-sunos*) add_shlibpath=$dir ;; esac add_dir=-L$dir add=-l$name elif test no = "$hardcode_shlibpath_var"; then add_shlibpath=$dir add=-l$name else lib_linked=no fi ;; relink) if test yes = "$hardcode_direct" && test no = "$hardcode_direct_absolute"; then add=$dir/$linklib elif test yes = "$hardcode_minus_L"; then add_dir=-L$absdir # Try looking first in the location we're being installed to. if test -n "$inst_prefix_dir"; then case $libdir in [\\/]*) func_append add_dir " -L$inst_prefix_dir$libdir" ;; esac fi add=-l$name elif test yes = "$hardcode_shlibpath_var"; then add_shlibpath=$dir add=-l$name else lib_linked=no fi ;; *) lib_linked=no ;; esac if test yes != "$lib_linked"; then func_fatal_configuration "unsupported hardcode properties" fi if test -n "$add_shlibpath"; then case :$compile_shlibpath: in *":$add_shlibpath:"*) ;; *) func_append compile_shlibpath "$add_shlibpath:" ;; esac fi if test prog = "$linkmode"; then test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" test -n "$add" && compile_deplibs="$add $compile_deplibs" else test -n "$add_dir" && deplibs="$add_dir $deplibs" test -n "$add" && deplibs="$add $deplibs" if test yes != "$hardcode_direct" && test yes != "$hardcode_minus_L" && test yes = "$hardcode_shlibpath_var"; then case :$finalize_shlibpath: in *":$libdir:"*) ;; *) func_append finalize_shlibpath "$libdir:" ;; esac fi fi fi if test prog = "$linkmode" || test relink = "$opt_mode"; then add_shlibpath= add_dir= add= # Finalize command for both is simple: just hardcode it. if test yes = "$hardcode_direct" && test no = "$hardcode_direct_absolute"; then add=$libdir/$linklib elif test yes = "$hardcode_minus_L"; then add_dir=-L$libdir add=-l$name elif test yes = "$hardcode_shlibpath_var"; then case :$finalize_shlibpath: in *":$libdir:"*) ;; *) func_append finalize_shlibpath "$libdir:" ;; esac add=-l$name elif test yes = "$hardcode_automatic"; then if test -n "$inst_prefix_dir" && test -f "$inst_prefix_dir$libdir/$linklib"; then add=$inst_prefix_dir$libdir/$linklib else add=$libdir/$linklib fi else # We cannot seem to hardcode it, guess we'll fake it. add_dir=-L$libdir # Try looking first in the location we're being installed to. if test -n "$inst_prefix_dir"; then case $libdir in [\\/]*) func_append add_dir " -L$inst_prefix_dir$libdir" ;; esac fi add=-l$name fi if test prog = "$linkmode"; then test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" test -n "$add" && finalize_deplibs="$add $finalize_deplibs" else test -n "$add_dir" && deplibs="$add_dir $deplibs" test -n "$add" && deplibs="$add $deplibs" fi fi elif test prog = "$linkmode"; then # Here we assume that one of hardcode_direct or hardcode_minus_L # is not unsupported. This is valid on all known static and # shared platforms. if test unsupported != "$hardcode_direct"; then test -n "$old_library" && linklib=$old_library compile_deplibs="$dir/$linklib $compile_deplibs" finalize_deplibs="$dir/$linklib $finalize_deplibs" else compile_deplibs="-l$name -L$dir $compile_deplibs" finalize_deplibs="-l$name -L$dir $finalize_deplibs" fi elif test yes = "$build_libtool_libs"; then # Not a shared library if test pass_all != "$deplibs_check_method"; then # We're trying link a shared library against a static one # but the system doesn't support it. # Just print a warning and add the library to dependency_libs so # that the program can be linked against the static library. echo $ECHO "*** Warning: This system cannot link to static lib archive $lib." echo "*** I have the capability to make that library automatically link in when" echo "*** you link to this library. But I can only do this if you have a" echo "*** shared version of the library, which you do not appear to have." if test yes = "$module"; then echo "*** But as you try to build a module library, libtool will still create " echo "*** a static module, that should work as long as the dlopening application" echo "*** is linked with the -dlopen flag to resolve symbols at runtime." if test -z "$global_symbol_pipe"; then echo echo "*** However, this would only work if libtool was able to extract symbol" echo "*** lists from a program, using 'nm' or equivalent, but libtool could" echo "*** not find such a program. So, this module is probably useless." echo "*** 'nm' from GNU binutils and a full rebuild may help." fi if test no = "$build_old_libs"; then build_libtool_libs=module build_old_libs=yes else build_libtool_libs=no fi fi else deplibs="$dir/$old_library $deplibs" link_static=yes fi fi # link shared/static library? if test lib = "$linkmode"; then if test -n "$dependency_libs" && { test yes != "$hardcode_into_libs" || test yes = "$build_old_libs" || test yes = "$link_static"; }; then # Extract -R from dependency_libs temp_deplibs= for libdir in $dependency_libs; do case $libdir in -R*) func_stripname '-R' '' "$libdir" temp_xrpath=$func_stripname_result case " $xrpath " in *" $temp_xrpath "*) ;; *) func_append xrpath " $temp_xrpath";; esac;; *) func_append temp_deplibs " $libdir";; esac done dependency_libs=$temp_deplibs fi func_append newlib_search_path " $absdir" # Link against this library test no = "$link_static" && newdependency_libs="$abs_ladir/$laname $newdependency_libs" # ... and its dependency_libs tmp_libs= for deplib in $dependency_libs; do newdependency_libs="$deplib $newdependency_libs" case $deplib in -L*) func_stripname '-L' '' "$deplib" func_resolve_sysroot "$func_stripname_result";; *) func_resolve_sysroot "$deplib" ;; esac if $opt_preserve_dup_deps; then case "$tmp_libs " in *" $func_resolve_sysroot_result "*) func_append specialdeplibs " $func_resolve_sysroot_result" ;; esac fi func_append tmp_libs " $func_resolve_sysroot_result" done if test no != "$link_all_deplibs"; then # Add the search paths of all dependency libraries for deplib in $dependency_libs; do path= case $deplib in -L*) path=$deplib ;; *.la) func_resolve_sysroot "$deplib" deplib=$func_resolve_sysroot_result func_dirname "$deplib" "" "." dir=$func_dirname_result # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) absdir=$dir ;; *) absdir=`cd "$dir" && pwd` if test -z "$absdir"; then func_warning "cannot determine absolute directory name of '$dir'" absdir=$dir fi ;; esac if $GREP "^installed=no" $deplib > /dev/null; then case $host in *-*-darwin*) depdepl= eval deplibrary_names=`$SED -n -e 's/^library_names=\(.*\)$/\1/p' $deplib` if test -n "$deplibrary_names"; then for tmp in $deplibrary_names; do depdepl=$tmp done if test -f "$absdir/$objdir/$depdepl"; then depdepl=$absdir/$objdir/$depdepl darwin_install_name=`$OTOOL -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` if test -z "$darwin_install_name"; then darwin_install_name=`$OTOOL64 -L $depdepl | awk '{if (NR == 2) {print $1;exit}}'` fi func_append compiler_flags " $wl-dylib_file $wl$darwin_install_name:$depdepl" func_append linker_flags " -dylib_file $darwin_install_name:$depdepl" path= fi fi ;; *) path=-L$absdir/$objdir ;; esac else eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` test -z "$libdir" && \ func_fatal_error "'$deplib' is not a valid libtool archive" test "$absdir" != "$libdir" && \ func_warning "'$deplib' seems to be moved" path=-L$absdir fi ;; esac case " $deplibs " in *" $path "*) ;; *) deplibs="$path $deplibs" ;; esac done fi # link_all_deplibs != no fi # linkmode = lib done # for deplib in $libs if test link = "$pass"; then if test prog = "$linkmode"; then compile_deplibs="$new_inherited_linker_flags $compile_deplibs" finalize_deplibs="$new_inherited_linker_flags $finalize_deplibs" else compiler_flags="$compiler_flags "`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` fi fi dependency_libs=$newdependency_libs if test dlpreopen = "$pass"; then # Link the dlpreopened libraries before other libraries for deplib in $save_deplibs; do deplibs="$deplib $deplibs" done fi if test dlopen != "$pass"; then test conv = "$pass" || { # Make sure lib_search_path contains only unique directories. lib_search_path= for dir in $newlib_search_path; do case "$lib_search_path " in *" $dir "*) ;; *) func_append lib_search_path " $dir" ;; esac done newlib_search_path= } if test prog,link = "$linkmode,$pass"; then vars="compile_deplibs finalize_deplibs" else vars=deplibs fi for var in $vars dependency_libs; do # Add libraries to $var in reverse order eval tmp_libs=\"\$$var\" new_libs= for deplib in $tmp_libs; do # FIXME: Pedantically, this is the right thing to do, so # that some nasty dependency loop isn't accidentally # broken: #new_libs="$deplib $new_libs" # Pragmatically, this seems to cause very few problems in # practice: case $deplib in -L*) new_libs="$deplib $new_libs" ;; -R*) ;; *) # And here is the reason: when a library appears more # than once as an explicit dependence of a library, or # is implicitly linked in more than once by the # compiler, it is considered special, and multiple # occurrences thereof are not removed. Compare this # with having the same library being listed as a # dependency of multiple other libraries: in this case, # we know (pedantically, we assume) the library does not # need to be listed more than once, so we keep only the # last copy. This is not always right, but it is rare # enough that we require users that really mean to play # such unportable linking tricks to link the library # using -Wl,-lname, so that libtool does not consider it # for duplicate removal. case " $specialdeplibs " in *" $deplib "*) new_libs="$deplib $new_libs" ;; *) case " $new_libs " in *" $deplib "*) ;; *) new_libs="$deplib $new_libs" ;; esac ;; esac ;; esac done tmp_libs= for deplib in $new_libs; do case $deplib in -L*) case " $tmp_libs " in *" $deplib "*) ;; *) func_append tmp_libs " $deplib" ;; esac ;; *) func_append tmp_libs " $deplib" ;; esac done eval $var=\"$tmp_libs\" done # for var fi # Add Sun CC postdeps if required: test CXX = "$tagname" && { case $host_os in linux*) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C++ 5.9 func_suncc_cstd_abi if test no != "$suncc_use_cstd_abi"; then func_append postdeps ' -library=Cstd -library=Crun' fi ;; esac ;; solaris*) func_cc_basename "$CC" case $func_cc_basename_result in CC* | sunCC*) func_suncc_cstd_abi if test no != "$suncc_use_cstd_abi"; then func_append postdeps ' -library=Cstd -library=Crun' fi ;; esac ;; esac } # Last step: remove runtime libs from dependency_libs # (they stay in deplibs) tmp_libs= for i in $dependency_libs; do case " $predeps $postdeps $compiler_lib_search_path " in *" $i "*) i= ;; esac if test -n "$i"; then func_append tmp_libs " $i" fi done dependency_libs=$tmp_libs done # for pass if test prog = "$linkmode"; then dlfiles=$newdlfiles fi if test prog = "$linkmode" || test lib = "$linkmode"; then dlprefiles=$newdlprefiles fi case $linkmode in oldlib) if test -n "$dlfiles$dlprefiles" || test no != "$dlself"; then func_warning "'-dlopen' is ignored for archives" fi case " $deplibs" in *\ -l* | *\ -L*) func_warning "'-l' and '-L' are ignored for archives" ;; esac test -n "$rpath" && \ func_warning "'-rpath' is ignored for archives" test -n "$xrpath" && \ func_warning "'-R' is ignored for archives" test -n "$vinfo" && \ func_warning "'-version-info/-version-number' is ignored for archives" test -n "$release" && \ func_warning "'-release' is ignored for archives" test -n "$export_symbols$export_symbols_regex" && \ func_warning "'-export-symbols' is ignored for archives" # Now set the variables for building old libraries. build_libtool_libs=no oldlibs=$output func_append objs "$old_deplibs" ;; lib) # Make sure we only generate libraries of the form 'libNAME.la'. case $outputname in lib*) func_stripname 'lib' '.la' "$outputname" name=$func_stripname_result eval shared_ext=\"$shrext_cmds\" eval libname=\"$libname_spec\" ;; *) test no = "$module" \ && func_fatal_help "libtool library '$output' must begin with 'lib'" if test no != "$need_lib_prefix"; then # Add the "lib" prefix for modules if required func_stripname '' '.la' "$outputname" name=$func_stripname_result eval shared_ext=\"$shrext_cmds\" eval libname=\"$libname_spec\" else func_stripname '' '.la' "$outputname" libname=$func_stripname_result fi ;; esac if test -n "$objs"; then if test pass_all != "$deplibs_check_method"; then func_fatal_error "cannot build libtool library '$output' from non-libtool objects on this host:$objs" else echo $ECHO "*** Warning: Linking the shared library $output against the non-libtool" $ECHO "*** objects $objs is not portable!" func_append libobjs " $objs" fi fi test no = "$dlself" \ || func_warning "'-dlopen self' is ignored for libtool libraries" set dummy $rpath shift test 1 -lt "$#" \ && func_warning "ignoring multiple '-rpath's for a libtool library" install_libdir=$1 oldlibs= if test -z "$rpath"; then if test yes = "$build_libtool_libs"; then # Building a libtool convenience library. # Some compilers have problems with a '.al' extension so # convenience libraries should have the same extension an # archive normally would. oldlibs="$output_objdir/$libname.$libext $oldlibs" build_libtool_libs=convenience build_old_libs=yes fi test -n "$vinfo" && \ func_warning "'-version-info/-version-number' is ignored for convenience libraries" test -n "$release" && \ func_warning "'-release' is ignored for convenience libraries" else # Parse the version information argument. save_ifs=$IFS; IFS=: set dummy $vinfo 0 0 0 shift IFS=$save_ifs test -n "$7" && \ func_fatal_help "too many parameters to '-version-info'" # convert absolute version numbers to libtool ages # this retains compatibility with .la files and attempts # to make the code below a bit more comprehensible case $vinfo_number in yes) number_major=$1 number_minor=$2 number_revision=$3 # # There are really only two kinds -- those that # use the current revision as the major version # and those that subtract age and use age as # a minor version. But, then there is irix # that has an extra 1 added just for fun # case $version_type in # correct linux to gnu/linux during the next big refactor darwin|freebsd-elf|linux|osf|windows|none) func_arith $number_major + $number_minor current=$func_arith_result age=$number_minor revision=$number_revision ;; freebsd-aout|qnx|sunos) current=$number_major revision=$number_minor age=0 ;; irix|nonstopux) func_arith $number_major + $number_minor current=$func_arith_result age=$number_minor revision=$number_minor lt_irix_increment=no ;; esac ;; no) current=$1 revision=$2 age=$3 ;; esac # Check that each of the things are valid numbers. case $current in 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) func_error "CURRENT '$current' must be a nonnegative integer" func_fatal_error "'$vinfo' is not valid version information" ;; esac case $revision in 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) func_error "REVISION '$revision' must be a nonnegative integer" func_fatal_error "'$vinfo' is not valid version information" ;; esac case $age in 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) func_error "AGE '$age' must be a nonnegative integer" func_fatal_error "'$vinfo' is not valid version information" ;; esac if test "$age" -gt "$current"; then func_error "AGE '$age' is greater than the current interface number '$current'" func_fatal_error "'$vinfo' is not valid version information" fi # Calculate the version variables. major= versuffix= verstring= case $version_type in none) ;; darwin) # Like Linux, but with the current version available in # verstring for coding it into the library header func_arith $current - $age major=.$func_arith_result versuffix=$major.$age.$revision # Darwin ld doesn't like 0 for these options... func_arith $current + 1 minor_current=$func_arith_result xlcverstring="$wl-compatibility_version $wl$minor_current $wl-current_version $wl$minor_current.$revision" verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" # On Darwin other compilers case $CC in nagfor*) verstring="$wl-compatibility_version $wl$minor_current $wl-current_version $wl$minor_current.$revision" ;; *) verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" ;; esac ;; freebsd-aout) major=.$current versuffix=.$current.$revision ;; freebsd-elf) func_arith $current - $age major=.$func_arith_result versuffix=$major.$age.$revision ;; irix | nonstopux) if test no = "$lt_irix_increment"; then func_arith $current - $age else func_arith $current - $age + 1 fi major=$func_arith_result case $version_type in nonstopux) verstring_prefix=nonstopux ;; *) verstring_prefix=sgi ;; esac verstring=$verstring_prefix$major.$revision # Add in all the interfaces that we are compatible with. loop=$revision while test 0 -ne "$loop"; do func_arith $revision - $loop iface=$func_arith_result func_arith $loop - 1 loop=$func_arith_result verstring=$verstring_prefix$major.$iface:$verstring done # Before this point, $major must not contain '.'. major=.$major versuffix=$major.$revision ;; linux) # correct to gnu/linux during the next big refactor func_arith $current - $age major=.$func_arith_result versuffix=$major.$age.$revision ;; osf) func_arith $current - $age major=.$func_arith_result versuffix=.$current.$age.$revision verstring=$current.$age.$revision # Add in all the interfaces that we are compatible with. loop=$age while test 0 -ne "$loop"; do func_arith $current - $loop iface=$func_arith_result func_arith $loop - 1 loop=$func_arith_result verstring=$verstring:$iface.0 done # Make executables depend on our current version. func_append verstring ":$current.0" ;; qnx) major=.$current versuffix=.$current ;; sco) major=.$current versuffix=.$current ;; sunos) major=.$current versuffix=.$current.$revision ;; windows) # Use '-' rather than '.', since we only want one # extension on DOS 8.3 file systems. func_arith $current - $age major=$func_arith_result versuffix=-$major ;; *) func_fatal_configuration "unknown library version type '$version_type'" ;; esac # Clear the version info if we defaulted, and they specified a release. if test -z "$vinfo" && test -n "$release"; then major= case $version_type in darwin) # we can't check for "0.0" in archive_cmds due to quoting # problems, so we reset it completely verstring= ;; *) verstring=0.0 ;; esac if test no = "$need_version"; then versuffix= else versuffix=.0.0 fi fi # Remove version info from name if versioning should be avoided if test yes,no = "$avoid_version,$need_version"; then major= versuffix= verstring= fi # Check to see if the archive will have undefined symbols. if test yes = "$allow_undefined"; then if test unsupported = "$allow_undefined_flag"; then if test yes = "$build_old_libs"; then func_warning "undefined symbols not allowed in $host shared libraries; building static only" build_libtool_libs=no else func_fatal_error "can't build $host shared library unless -no-undefined is specified" fi fi else # Don't allow undefined symbols. allow_undefined_flag=$no_undefined_flag fi fi func_generate_dlsyms "$libname" "$libname" : func_append libobjs " $symfileobj" test " " = "$libobjs" && libobjs= if test relink != "$opt_mode"; then # Remove our outputs, but don't remove object files since they # may have been created when compiling PIC objects. removelist= tempremovelist=`$ECHO "$output_objdir/*"` for p in $tempremovelist; do case $p in *.$objext | *.gcno) ;; $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/$libname$release.*) if test -n "$precious_files_regex"; then if $ECHO "$p" | $EGREP -e "$precious_files_regex" >/dev/null 2>&1 then continue fi fi func_append removelist " $p" ;; *) ;; esac done test -n "$removelist" && \ func_show_eval "${RM}r \$removelist" fi # Now set the variables for building old libraries. if test yes = "$build_old_libs" && test convenience != "$build_libtool_libs"; then func_append oldlibs " $output_objdir/$libname.$libext" # Transform .lo files to .o files. oldobjs="$objs "`$ECHO "$libobjs" | $SP2NL | $SED "/\.$libext$/d; $lo2o" | $NL2SP` fi # Eliminate all temporary directories. #for path in $notinst_path; do # lib_search_path=`$ECHO "$lib_search_path " | $SED "s% $path % %g"` # deplibs=`$ECHO "$deplibs " | $SED "s% -L$path % %g"` # dependency_libs=`$ECHO "$dependency_libs " | $SED "s% -L$path % %g"` #done if test -n "$xrpath"; then # If the user specified any rpath flags, then add them. temp_xrpath= for libdir in $xrpath; do func_replace_sysroot "$libdir" func_append temp_xrpath " -R$func_replace_sysroot_result" case "$finalize_rpath " in *" $libdir "*) ;; *) func_append finalize_rpath " $libdir" ;; esac done if test yes != "$hardcode_into_libs" || test yes = "$build_old_libs"; then dependency_libs="$temp_xrpath $dependency_libs" fi fi # Make sure dlfiles contains only unique files that won't be dlpreopened old_dlfiles=$dlfiles dlfiles= for lib in $old_dlfiles; do case " $dlprefiles $dlfiles " in *" $lib "*) ;; *) func_append dlfiles " $lib" ;; esac done # Make sure dlprefiles contains only unique files old_dlprefiles=$dlprefiles dlprefiles= for lib in $old_dlprefiles; do case "$dlprefiles " in *" $lib "*) ;; *) func_append dlprefiles " $lib" ;; esac done if test yes = "$build_libtool_libs"; then if test -n "$rpath"; then case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos* | *-cegcc* | *-*-haiku*) # these systems don't actually have a c library (as such)! ;; *-*-rhapsody* | *-*-darwin1.[012]) # Rhapsody C library is in the System framework func_append deplibs " System.ltframework" ;; *-*-netbsd*) # Don't link with libc until the a.out ld.so is fixed. ;; *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) # Do not include libc due to us having libc/libc_r. ;; *-*-sco3.2v5* | *-*-sco5v6*) # Causes problems with __ctype ;; *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) # Compiler inserts libc in the correct place for threads to work ;; *) # Add libc to deplibs on all other systems if necessary. if test yes = "$build_libtool_need_lc"; then func_append deplibs " -lc" fi ;; esac fi # Transform deplibs into only deplibs that can be linked in shared. name_save=$name libname_save=$libname release_save=$release versuffix_save=$versuffix major_save=$major # I'm not sure if I'm treating the release correctly. I think # release should show up in the -l (ie -lgmp5) so we don't want to # add it in twice. Is that correct? release= versuffix= major= newdeplibs= droppeddeps=no case $deplibs_check_method in pass_all) # Don't check for shared/static. Everything works. # This might be a little naive. We might want to check # whether the library exists or not. But this is on # osf3 & osf4 and I'm not really sure... Just # implementing what was already the behavior. newdeplibs=$deplibs ;; test_compile) # This code stresses the "libraries are programs" paradigm to its # limits. Maybe even breaks it. We compile a program, linking it # against the deplibs as a proxy for the library. Then we can check # whether they linked in statically or dynamically with ldd. $opt_dry_run || $RM conftest.c cat > conftest.c <<EOF int main() { return 0; } EOF $opt_dry_run || $RM conftest if $LTCC $LTCFLAGS -o conftest conftest.c $deplibs; then ldd_output=`ldd conftest` for i in $deplibs; do case $i in -l*) func_stripname -l '' "$i" name=$func_stripname_result if test yes = "$allow_libtool_libs_with_static_runtimes"; then case " $predeps $postdeps " in *" $i "*) func_append newdeplibs " $i" i= ;; esac fi if test -n "$i"; then libname=`eval "\\$ECHO \"$libname_spec\""` deplib_matches=`eval "\\$ECHO \"$library_names_spec\""` set dummy $deplib_matches; shift deplib_match=$1 if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0; then func_append newdeplibs " $i" else droppeddeps=yes echo $ECHO "*** Warning: dynamic linker does not accept needed library $i." echo "*** I have the capability to make that library automatically link in when" echo "*** you link to this library. But I can only do this if you have a" echo "*** shared version of the library, which I believe you do not have" echo "*** because a test_compile did reveal that the linker did not use it for" echo "*** its dynamic dependency list that programs get resolved with at runtime." fi fi ;; *) func_append newdeplibs " $i" ;; esac done else # Error occurred in the first compile. Let's try to salvage # the situation: Compile a separate program for each library. for i in $deplibs; do case $i in -l*) func_stripname -l '' "$i" name=$func_stripname_result $opt_dry_run || $RM conftest if $LTCC $LTCFLAGS -o conftest conftest.c $i; then ldd_output=`ldd conftest` if test yes = "$allow_libtool_libs_with_static_runtimes"; then case " $predeps $postdeps " in *" $i "*) func_append newdeplibs " $i" i= ;; esac fi if test -n "$i"; then libname=`eval "\\$ECHO \"$libname_spec\""` deplib_matches=`eval "\\$ECHO \"$library_names_spec\""` set dummy $deplib_matches; shift deplib_match=$1 if test `expr "$ldd_output" : ".*$deplib_match"` -ne 0; then func_append newdeplibs " $i" else droppeddeps=yes echo $ECHO "*** Warning: dynamic linker does not accept needed library $i." echo "*** I have the capability to make that library automatically link in when" echo "*** you link to this library. But I can only do this if you have a" echo "*** shared version of the library, which you do not appear to have" echo "*** because a test_compile did reveal that the linker did not use this one" echo "*** as a dynamic dependency that programs can get resolved with at runtime." fi fi else droppeddeps=yes echo $ECHO "*** Warning! Library $i is needed by this library but I was not able to" echo "*** make it link in! You will probably need to install it or some" echo "*** library that it depends on before this library will be fully" echo "*** functional. Installing it before continuing would be even better." fi ;; *) func_append newdeplibs " $i" ;; esac done fi ;; file_magic*) set dummy $deplibs_check_method; shift file_magic_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` for a_deplib in $deplibs; do case $a_deplib in -l*) func_stripname -l '' "$a_deplib" name=$func_stripname_result if test yes = "$allow_libtool_libs_with_static_runtimes"; then case " $predeps $postdeps " in *" $a_deplib "*) func_append newdeplibs " $a_deplib" a_deplib= ;; esac fi if test -n "$a_deplib"; then libname=`eval "\\$ECHO \"$libname_spec\""` if test -n "$file_magic_glob"; then libnameglob=`func_echo_all "$libname" | $SED -e $file_magic_glob` else libnameglob=$libname fi test yes = "$want_nocaseglob" && nocaseglob=`shopt -p nocaseglob` for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do if test yes = "$want_nocaseglob"; then shopt -s nocaseglob potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null` $nocaseglob else potential_libs=`ls $i/$libnameglob[.-]* 2>/dev/null` fi for potent_lib in $potential_libs; do # Follow soft links. if ls -lLd "$potent_lib" 2>/dev/null | $GREP " -> " >/dev/null; then continue fi # The statement above tries to avoid entering an # endless loop below, in case of cyclic links. # We might still enter an endless loop, since a link # loop can be closed while we follow links, # but so what? potlib=$potent_lib while test -h "$potlib" 2>/dev/null; do potliblink=`ls -ld $potlib | $SED 's/.* -> //'` case $potliblink in [\\/]* | [A-Za-z]:[\\/]*) potlib=$potliblink;; *) potlib=`$ECHO "$potlib" | $SED 's|[^/]*$||'`"$potliblink";; esac done if eval $file_magic_cmd \"\$potlib\" 2>/dev/null | $SED -e 10q | $EGREP "$file_magic_regex" > /dev/null; then func_append newdeplibs " $a_deplib" a_deplib= break 2 fi done done fi if test -n "$a_deplib"; then droppeddeps=yes echo $ECHO "*** Warning: linker path does not have real file for library $a_deplib." echo "*** I have the capability to make that library automatically link in when" echo "*** you link to this library. But I can only do this if you have a" echo "*** shared version of the library, which you do not appear to have" echo "*** because I did check the linker path looking for a file starting" if test -z "$potlib"; then $ECHO "*** with $libname but no candidates were found. (...for file magic test)" else $ECHO "*** with $libname and none of the candidates passed a file format test" $ECHO "*** using a file magic. Last file checked: $potlib" fi fi ;; *) # Add a -L argument. func_append newdeplibs " $a_deplib" ;; esac done # Gone through all deplibs. ;; match_pattern*) set dummy $deplibs_check_method; shift match_pattern_regex=`expr "$deplibs_check_method" : "$1 \(.*\)"` for a_deplib in $deplibs; do case $a_deplib in -l*) func_stripname -l '' "$a_deplib" name=$func_stripname_result if test yes = "$allow_libtool_libs_with_static_runtimes"; then case " $predeps $postdeps " in *" $a_deplib "*) func_append newdeplibs " $a_deplib" a_deplib= ;; esac fi if test -n "$a_deplib"; then libname=`eval "\\$ECHO \"$libname_spec\""` for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do potential_libs=`ls $i/$libname[.-]* 2>/dev/null` for potent_lib in $potential_libs; do potlib=$potent_lib # see symlink-check above in file_magic test if eval "\$ECHO \"$potent_lib\"" 2>/dev/null | $SED 10q | \ $EGREP "$match_pattern_regex" > /dev/null; then func_append newdeplibs " $a_deplib" a_deplib= break 2 fi done done fi if test -n "$a_deplib"; then droppeddeps=yes echo $ECHO "*** Warning: linker path does not have real file for library $a_deplib." echo "*** I have the capability to make that library automatically link in when" echo "*** you link to this library. But I can only do this if you have a" echo "*** shared version of the library, which you do not appear to have" echo "*** because I did check the linker path looking for a file starting" if test -z "$potlib"; then $ECHO "*** with $libname but no candidates were found. (...for regex pattern test)" else $ECHO "*** with $libname and none of the candidates passed a file format test" $ECHO "*** using a regex pattern. Last file checked: $potlib" fi fi ;; *) # Add a -L argument. func_append newdeplibs " $a_deplib" ;; esac done # Gone through all deplibs. ;; none | unknown | *) newdeplibs= tmp_deplibs=`$ECHO " $deplibs" | $SED 's/ -lc$//; s/ -[LR][^ ]*//g'` if test yes = "$allow_libtool_libs_with_static_runtimes"; then for i in $predeps $postdeps; do # can't use Xsed below, because $i might contain '/' tmp_deplibs=`$ECHO " $tmp_deplibs" | $SED "s|$i||"` done fi case $tmp_deplibs in *[!\ \ ]*) echo if test none = "$deplibs_check_method"; then echo "*** Warning: inter-library dependencies are not supported in this platform." else echo "*** Warning: inter-library dependencies are not known to be supported." fi echo "*** All declared inter-library dependencies are being dropped." droppeddeps=yes ;; esac ;; esac versuffix=$versuffix_save major=$major_save release=$release_save libname=$libname_save name=$name_save case $host in *-*-rhapsody* | *-*-darwin1.[012]) # On Rhapsody replace the C library with the System framework newdeplibs=`$ECHO " $newdeplibs" | $SED 's/ -lc / System.ltframework /'` ;; esac if test yes = "$droppeddeps"; then if test yes = "$module"; then echo echo "*** Warning: libtool could not satisfy all declared inter-library" $ECHO "*** dependencies of module $libname. Therefore, libtool will create" echo "*** a static module, that should work as long as the dlopening" echo "*** application is linked with the -dlopen flag." if test -z "$global_symbol_pipe"; then echo echo "*** However, this would only work if libtool was able to extract symbol" echo "*** lists from a program, using 'nm' or equivalent, but libtool could" echo "*** not find such a program. So, this module is probably useless." echo "*** 'nm' from GNU binutils and a full rebuild may help." fi if test no = "$build_old_libs"; then oldlibs=$output_objdir/$libname.$libext build_libtool_libs=module build_old_libs=yes else build_libtool_libs=no fi else echo "*** The inter-library dependencies that have been dropped here will be" echo "*** automatically added whenever a program is linked with this library" echo "*** or is declared to -dlopen it." if test no = "$allow_undefined"; then echo echo "*** Since this library must not contain undefined symbols," echo "*** because either the platform does not support them or" echo "*** it was explicitly requested with -no-undefined," echo "*** libtool will only create a static version of it." if test no = "$build_old_libs"; then oldlibs=$output_objdir/$libname.$libext build_libtool_libs=module build_old_libs=yes else build_libtool_libs=no fi fi fi fi # Done checking deplibs! deplibs=$newdeplibs fi # Time to change all our "foo.ltframework" stuff back to "-framework foo" case $host in *-*-darwin*) newdeplibs=`$ECHO " $newdeplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` new_inherited_linker_flags=`$ECHO " $new_inherited_linker_flags" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` deplibs=`$ECHO " $deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` ;; esac # move library search paths that coincide with paths to not yet # installed libraries to the beginning of the library search list new_libs= for path in $notinst_path; do case " $new_libs " in *" -L$path/$objdir "*) ;; *) case " $deplibs " in *" -L$path/$objdir "*) func_append new_libs " -L$path/$objdir" ;; esac ;; esac done for deplib in $deplibs; do case $deplib in -L*) case " $new_libs " in *" $deplib "*) ;; *) func_append new_libs " $deplib" ;; esac ;; *) func_append new_libs " $deplib" ;; esac done deplibs=$new_libs # All the library-specific variables (install_libdir is set above). library_names= old_library= dlname= # Test again, we may have decided not to build it any more if test yes = "$build_libtool_libs"; then # Remove $wl instances when linking with ld. # FIXME: should test the right _cmds variable. case $archive_cmds in *\$LD\ *) wl= ;; esac if test yes = "$hardcode_into_libs"; then # Hardcode the library paths hardcode_libdirs= dep_rpath= rpath=$finalize_rpath test relink = "$opt_mode" || rpath=$compile_rpath$rpath for libdir in $rpath; do if test -n "$hardcode_libdir_flag_spec"; then if test -n "$hardcode_libdir_separator"; then func_replace_sysroot "$libdir" libdir=$func_replace_sysroot_result if test -z "$hardcode_libdirs"; then hardcode_libdirs=$libdir else # Just accumulate the unique libdirs. case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" func_append dep_rpath " $flag" fi elif test -n "$runpath_var"; then case "$perm_rpath " in *" $libdir "*) ;; *) func_append perm_rpath " $libdir" ;; esac fi done # Substitute the hardcoded libdirs into the rpath. if test -n "$hardcode_libdir_separator" && test -n "$hardcode_libdirs"; then libdir=$hardcode_libdirs eval "dep_rpath=\"$hardcode_libdir_flag_spec\"" fi if test -n "$runpath_var" && test -n "$perm_rpath"; then # We should set the runpath_var. rpath= for dir in $perm_rpath; do func_append rpath "$dir:" done eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" fi test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs" fi shlibpath=$finalize_shlibpath test relink = "$opt_mode" || shlibpath=$compile_shlibpath$shlibpath if test -n "$shlibpath"; then eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" fi # Get the real and link names of the library. eval shared_ext=\"$shrext_cmds\" eval library_names=\"$library_names_spec\" set dummy $library_names shift realname=$1 shift if test -n "$soname_spec"; then eval soname=\"$soname_spec\" else soname=$realname fi if test -z "$dlname"; then dlname=$soname fi lib=$output_objdir/$realname linknames= for link do func_append linknames " $link" done # Use standard objects if they are pic test -z "$pic_flag" && libobjs=`$ECHO "$libobjs" | $SP2NL | $SED "$lo2o" | $NL2SP` test "X$libobjs" = "X " && libobjs= delfiles= if test -n "$export_symbols" && test -n "$include_expsyms"; then $opt_dry_run || cp "$export_symbols" "$output_objdir/$libname.uexp" export_symbols=$output_objdir/$libname.uexp func_append delfiles " $export_symbols" fi orig_export_symbols= case $host_os in cygwin* | mingw* | cegcc*) if test -n "$export_symbols" && test -z "$export_symbols_regex"; then # exporting using user supplied symfile func_dll_def_p "$export_symbols" || { # and it's NOT already a .def file. Must figure out # which of the given symbols are data symbols and tag # them as such. So, trigger use of export_symbols_cmds. # export_symbols gets reassigned inside the "prepare # the list of exported symbols" if statement, so the # include_expsyms logic still works. orig_export_symbols=$export_symbols export_symbols= always_export_symbols=yes } fi ;; esac # Prepare the list of exported symbols if test -z "$export_symbols"; then if test yes = "$always_export_symbols" || test -n "$export_symbols_regex"; then func_verbose "generating symbol list for '$libname.la'" export_symbols=$output_objdir/$libname.exp $opt_dry_run || $RM $export_symbols cmds=$export_symbols_cmds save_ifs=$IFS; IFS='~' for cmd1 in $cmds; do IFS=$save_ifs # Take the normal branch if the nm_file_list_spec branch # doesn't work or if tool conversion is not needed. case $nm_file_list_spec~$to_tool_file_cmd in *~func_convert_file_noop | *~func_convert_file_msys_to_w32 | ~*) try_normal_branch=yes eval cmd=\"$cmd1\" func_len " $cmd" len=$func_len_result ;; *) try_normal_branch=no ;; esac if test yes = "$try_normal_branch" \ && { test "$len" -lt "$max_cmd_len" \ || test "$max_cmd_len" -le -1; } then func_show_eval "$cmd" 'exit $?' skipped_export=false elif test -n "$nm_file_list_spec"; then func_basename "$output" output_la=$func_basename_result save_libobjs=$libobjs save_output=$output output=$output_objdir/$output_la.nm func_to_tool_file "$output" libobjs=$nm_file_list_spec$func_to_tool_file_result func_append delfiles " $output" func_verbose "creating $NM input file list: $output" for obj in $save_libobjs; do func_to_tool_file "$obj" $ECHO "$func_to_tool_file_result" done > "$output" eval cmd=\"$cmd1\" func_show_eval "$cmd" 'exit $?' output=$save_output libobjs=$save_libobjs skipped_export=false else # The command line is too long to execute in one step. func_verbose "using reloadable object file for export list..." skipped_export=: # Break out early, otherwise skipped_export may be # set to false by a later but shorter cmd. break fi done IFS=$save_ifs if test -n "$export_symbols_regex" && test : != "$skipped_export"; then func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' func_show_eval '$MV "${export_symbols}T" "$export_symbols"' fi fi fi if test -n "$export_symbols" && test -n "$include_expsyms"; then tmp_export_symbols=$export_symbols test -n "$orig_export_symbols" && tmp_export_symbols=$orig_export_symbols $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' fi if test : != "$skipped_export" && test -n "$orig_export_symbols"; then # The given exports_symbols file has to be filtered, so filter it. func_verbose "filter symbol list for '$libname.la' to tag DATA exports" # FIXME: $output_objdir/$libname.filter potentially contains lots of # 's' commands, which not all seds can handle. GNU sed should be fine # though. Also, the filter scales superlinearly with the number of # global variables. join(1) would be nice here, but unfortunately # isn't a blessed tool. $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter func_append delfiles " $export_symbols $output_objdir/$libname.filter" export_symbols=$output_objdir/$libname.def $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols fi tmp_deplibs= for test_deplib in $deplibs; do case " $convenience " in *" $test_deplib "*) ;; *) func_append tmp_deplibs " $test_deplib" ;; esac done deplibs=$tmp_deplibs if test -n "$convenience"; then if test -n "$whole_archive_flag_spec" && test yes = "$compiler_needs_object" && test -z "$libobjs"; then # extract the archives, so we have objects to list. # TODO: could optimize this to just extract one archive. whole_archive_flag_spec= fi if test -n "$whole_archive_flag_spec"; then save_libobjs=$libobjs eval libobjs=\"\$libobjs $whole_archive_flag_spec\" test "X$libobjs" = "X " && libobjs= else gentop=$output_objdir/${outputname}x func_append generated " $gentop" func_extract_archives $gentop $convenience func_append libobjs " $func_extract_archives_result" test "X$libobjs" = "X " && libobjs= fi fi if test yes = "$thread_safe" && test -n "$thread_safe_flag_spec"; then eval flag=\"$thread_safe_flag_spec\" func_append linker_flags " $flag" fi # Make a backup of the uninstalled library when relinking if test relink = "$opt_mode"; then $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}U && $MV $realname ${realname}U)' || exit $? fi # Do each of the archive commands. if test yes = "$module" && test -n "$module_cmds"; then if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then eval test_cmds=\"$module_expsym_cmds\" cmds=$module_expsym_cmds else eval test_cmds=\"$module_cmds\" cmds=$module_cmds fi else if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then eval test_cmds=\"$archive_expsym_cmds\" cmds=$archive_expsym_cmds else eval test_cmds=\"$archive_cmds\" cmds=$archive_cmds fi fi if test : != "$skipped_export" && func_len " $test_cmds" && len=$func_len_result && test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then : else # The command line is too long to link in one step, link piecewise # or, if using GNU ld and skipped_export is not :, use a linker # script. # Save the value of $output and $libobjs because we want to # use them later. If we have whole_archive_flag_spec, we # want to use save_libobjs as it was before # whole_archive_flag_spec was expanded, because we can't # assume the linker understands whole_archive_flag_spec. # This may have to be revisited, in case too many # convenience libraries get linked in and end up exceeding # the spec. if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then save_libobjs=$libobjs fi save_output=$output func_basename "$output" output_la=$func_basename_result # Clear the reloadable object creation command queue and # initialize k to one. test_cmds= concat_cmds= objlist= last_robj= k=1 if test -n "$save_libobjs" && test : != "$skipped_export" && test yes = "$with_gnu_ld"; then output=$output_objdir/$output_la.lnkscript func_verbose "creating GNU ld script: $output" echo 'INPUT (' > $output for obj in $save_libobjs do func_to_tool_file "$obj" $ECHO "$func_to_tool_file_result" >> $output done echo ')' >> $output func_append delfiles " $output" func_to_tool_file "$output" output=$func_to_tool_file_result elif test -n "$save_libobjs" && test : != "$skipped_export" && test -n "$file_list_spec"; then output=$output_objdir/$output_la.lnk func_verbose "creating linker input file list: $output" : > $output set x $save_libobjs shift firstobj= if test yes = "$compiler_needs_object"; then firstobj="$1 " shift fi for obj do func_to_tool_file "$obj" $ECHO "$func_to_tool_file_result" >> $output done func_append delfiles " $output" func_to_tool_file "$output" output=$firstobj\"$file_list_spec$func_to_tool_file_result\" else if test -n "$save_libobjs"; then func_verbose "creating reloadable object files..." output=$output_objdir/$output_la-$k.$objext eval test_cmds=\"$reload_cmds\" func_len " $test_cmds" len0=$func_len_result len=$len0 # Loop over the list of objects to be linked. for obj in $save_libobjs do func_len " $obj" func_arith $len + $func_len_result len=$func_arith_result if test -z "$objlist" || test "$len" -lt "$max_cmd_len"; then func_append objlist " $obj" else # The command $test_cmds is almost too long, add a # command to the queue. if test 1 -eq "$k"; then # The first file doesn't have a previous command to add. reload_objs=$objlist eval concat_cmds=\"$reload_cmds\" else # All subsequent reloadable object files will link in # the last one created. reload_objs="$objlist $last_robj" eval concat_cmds=\"\$concat_cmds~$reload_cmds~\$RM $last_robj\" fi last_robj=$output_objdir/$output_la-$k.$objext func_arith $k + 1 k=$func_arith_result output=$output_objdir/$output_la-$k.$objext objlist=" $obj" func_len " $last_robj" func_arith $len0 + $func_len_result len=$func_arith_result fi done # Handle the remaining objects by creating one last # reloadable object file. All subsequent reloadable object # files will link in the last one created. test -z "$concat_cmds" || concat_cmds=$concat_cmds~ reload_objs="$objlist $last_robj" eval concat_cmds=\"\$concat_cmds$reload_cmds\" if test -n "$last_robj"; then eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\" fi func_append delfiles " $output" else output= fi ${skipped_export-false} && { func_verbose "generating symbol list for '$libname.la'" export_symbols=$output_objdir/$libname.exp $opt_dry_run || $RM $export_symbols libobjs=$output # Append the command to create the export file. test -z "$concat_cmds" || concat_cmds=$concat_cmds~ eval concat_cmds=\"\$concat_cmds$export_symbols_cmds\" if test -n "$last_robj"; then eval concat_cmds=\"\$concat_cmds~\$RM $last_robj\" fi } test -n "$save_libobjs" && func_verbose "creating a temporary reloadable object file: $output" # Loop through the commands generated above and execute them. save_ifs=$IFS; IFS='~' for cmd in $concat_cmds; do IFS=$save_ifs $opt_quiet || { func_quote_for_expand "$cmd" eval "func_echo $func_quote_for_expand_result" } $opt_dry_run || eval "$cmd" || { lt_exit=$? # Restore the uninstalled library and exit if test relink = "$opt_mode"; then ( cd "$output_objdir" && \ $RM "${realname}T" && \ $MV "${realname}U" "$realname" ) fi exit $lt_exit } done IFS=$save_ifs if test -n "$export_symbols_regex" && ${skipped_export-false}; then func_show_eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' func_show_eval '$MV "${export_symbols}T" "$export_symbols"' fi fi ${skipped_export-false} && { if test -n "$export_symbols" && test -n "$include_expsyms"; then tmp_export_symbols=$export_symbols test -n "$orig_export_symbols" && tmp_export_symbols=$orig_export_symbols $opt_dry_run || eval '$ECHO "$include_expsyms" | $SP2NL >> "$tmp_export_symbols"' fi if test -n "$orig_export_symbols"; then # The given exports_symbols file has to be filtered, so filter it. func_verbose "filter symbol list for '$libname.la' to tag DATA exports" # FIXME: $output_objdir/$libname.filter potentially contains lots of # 's' commands, which not all seds can handle. GNU sed should be fine # though. Also, the filter scales superlinearly with the number of # global variables. join(1) would be nice here, but unfortunately # isn't a blessed tool. $opt_dry_run || $SED -e '/[ ,]DATA/!d;s,\(.*\)\([ \,].*\),s|^\1$|\1\2|,' < $export_symbols > $output_objdir/$libname.filter func_append delfiles " $export_symbols $output_objdir/$libname.filter" export_symbols=$output_objdir/$libname.def $opt_dry_run || $SED -f $output_objdir/$libname.filter < $orig_export_symbols > $export_symbols fi } libobjs=$output # Restore the value of output. output=$save_output if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then eval libobjs=\"\$libobjs $whole_archive_flag_spec\" test "X$libobjs" = "X " && libobjs= fi # Expand the library linking commands again to reset the # value of $libobjs for piecewise linking. # Do each of the archive commands. if test yes = "$module" && test -n "$module_cmds"; then if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then cmds=$module_expsym_cmds else cmds=$module_cmds fi else if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then cmds=$archive_expsym_cmds else cmds=$archive_cmds fi fi fi if test -n "$delfiles"; then # Append the command to remove temporary files to $cmds. eval cmds=\"\$cmds~\$RM $delfiles\" fi # Add any objects from preloaded convenience libraries if test -n "$dlprefiles"; then gentop=$output_objdir/${outputname}x func_append generated " $gentop" func_extract_archives $gentop $dlprefiles func_append libobjs " $func_extract_archives_result" test "X$libobjs" = "X " && libobjs= fi save_ifs=$IFS; IFS='~' for cmd in $cmds; do IFS=$sp$nl eval cmd=\"$cmd\" IFS=$save_ifs $opt_quiet || { func_quote_for_expand "$cmd" eval "func_echo $func_quote_for_expand_result" } $opt_dry_run || eval "$cmd" || { lt_exit=$? # Restore the uninstalled library and exit if test relink = "$opt_mode"; then ( cd "$output_objdir" && \ $RM "${realname}T" && \ $MV "${realname}U" "$realname" ) fi exit $lt_exit } done IFS=$save_ifs # Restore the uninstalled library and exit if test relink = "$opt_mode"; then $opt_dry_run || eval '(cd $output_objdir && $RM ${realname}T && $MV $realname ${realname}T && $MV ${realname}U $realname)' || exit $? if test -n "$convenience"; then if test -z "$whole_archive_flag_spec"; then func_show_eval '${RM}r "$gentop"' fi fi exit $EXIT_SUCCESS fi # Create links to the real library. for linkname in $linknames; do if test "$realname" != "$linkname"; then func_show_eval '(cd "$output_objdir" && $RM "$linkname" && $LN_S "$realname" "$linkname")' 'exit $?' fi done # If -module or -export-dynamic was specified, set the dlname. if test yes = "$module" || test yes = "$export_dynamic"; then # On all known operating systems, these are identical. dlname=$soname fi fi ;; obj) if test -n "$dlfiles$dlprefiles" || test no != "$dlself"; then func_warning "'-dlopen' is ignored for objects" fi case " $deplibs" in *\ -l* | *\ -L*) func_warning "'-l' and '-L' are ignored for objects" ;; esac test -n "$rpath" && \ func_warning "'-rpath' is ignored for objects" test -n "$xrpath" && \ func_warning "'-R' is ignored for objects" test -n "$vinfo" && \ func_warning "'-version-info' is ignored for objects" test -n "$release" && \ func_warning "'-release' is ignored for objects" case $output in *.lo) test -n "$objs$old_deplibs" && \ func_fatal_error "cannot build library object '$output' from non-libtool objects" libobj=$output func_lo2o "$libobj" obj=$func_lo2o_result ;; *) libobj= obj=$output ;; esac # Delete the old objects. $opt_dry_run || $RM $obj $libobj # Objects from convenience libraries. This assumes # single-version convenience libraries. Whenever we create # different ones for PIC/non-PIC, this we'll have to duplicate # the extraction. reload_conv_objs= gentop= # if reload_cmds runs $LD directly, get rid of -Wl from # whole_archive_flag_spec and hope we can get by with turning comma # into space. case $reload_cmds in *\$LD[\ \$]*) wl= ;; esac if test -n "$convenience"; then if test -n "$whole_archive_flag_spec"; then eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\" test -n "$wl" || tmp_whole_archive_flags=`$ECHO "$tmp_whole_archive_flags" | $SED 's|,| |g'` reload_conv_objs=$reload_objs\ $tmp_whole_archive_flags else gentop=$output_objdir/${obj}x func_append generated " $gentop" func_extract_archives $gentop $convenience reload_conv_objs="$reload_objs $func_extract_archives_result" fi fi # If we're not building shared, we need to use non_pic_objs test yes = "$build_libtool_libs" || libobjs=$non_pic_objects # Create the old-style object. reload_objs=$objs$old_deplibs' '`$ECHO "$libobjs" | $SP2NL | $SED "/\.$libext$/d; /\.lib$/d; $lo2o" | $NL2SP`' '$reload_conv_objs output=$obj func_execute_cmds "$reload_cmds" 'exit $?' # Exit if we aren't doing a library object file. if test -z "$libobj"; then if test -n "$gentop"; then func_show_eval '${RM}r "$gentop"' fi exit $EXIT_SUCCESS fi test yes = "$build_libtool_libs" || { if test -n "$gentop"; then func_show_eval '${RM}r "$gentop"' fi # Create an invalid libtool object if no PIC, so that we don't # accidentally link it into a program. # $show "echo timestamp > $libobj" # $opt_dry_run || eval "echo timestamp > $libobj" || exit $? exit $EXIT_SUCCESS } if test -n "$pic_flag" || test default != "$pic_mode"; then # Only do commands if we really have different PIC objects. reload_objs="$libobjs $reload_conv_objs" output=$libobj func_execute_cmds "$reload_cmds" 'exit $?' fi if test -n "$gentop"; then func_show_eval '${RM}r "$gentop"' fi exit $EXIT_SUCCESS ;; prog) case $host in *cygwin*) func_stripname '' '.exe' "$output" output=$func_stripname_result.exe;; esac test -n "$vinfo" && \ func_warning "'-version-info' is ignored for programs" test -n "$release" && \ func_warning "'-release' is ignored for programs" $preload \ && test unknown,unknown,unknown = "$dlopen_support,$dlopen_self,$dlopen_self_static" \ && func_warning "'LT_INIT([dlopen])' not used. Assuming no dlopen support." case $host in *-*-rhapsody* | *-*-darwin1.[012]) # On Rhapsody replace the C library is the System framework compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's/ -lc / System.ltframework /'` finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's/ -lc / System.ltframework /'` ;; esac case $host in *-*-darwin*) # Don't allow lazy linking, it breaks C++ global constructors # But is supposedly fixed on 10.4 or later (yay!). if test CXX = "$tagname"; then case ${MACOSX_DEPLOYMENT_TARGET-10.0} in 10.[0123]) func_append compile_command " $wl-bind_at_load" func_append finalize_command " $wl-bind_at_load" ;; esac fi # Time to change all our "foo.ltframework" stuff back to "-framework foo" compile_deplibs=`$ECHO " $compile_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` finalize_deplibs=`$ECHO " $finalize_deplibs" | $SED 's% \([^ $]*\).ltframework% -framework \1%g'` ;; esac # move library search paths that coincide with paths to not yet # installed libraries to the beginning of the library search list new_libs= for path in $notinst_path; do case " $new_libs " in *" -L$path/$objdir "*) ;; *) case " $compile_deplibs " in *" -L$path/$objdir "*) func_append new_libs " -L$path/$objdir" ;; esac ;; esac done for deplib in $compile_deplibs; do case $deplib in -L*) case " $new_libs " in *" $deplib "*) ;; *) func_append new_libs " $deplib" ;; esac ;; *) func_append new_libs " $deplib" ;; esac done compile_deplibs=$new_libs func_append compile_command " $compile_deplibs" func_append finalize_command " $finalize_deplibs" if test -n "$rpath$xrpath"; then # If the user specified any rpath flags, then add them. for libdir in $rpath $xrpath; do # This is the magic to use -rpath. case "$finalize_rpath " in *" $libdir "*) ;; *) func_append finalize_rpath " $libdir" ;; esac done fi # Now hardcode the library paths rpath= hardcode_libdirs= for libdir in $compile_rpath $finalize_rpath; do if test -n "$hardcode_libdir_flag_spec"; then if test -n "$hardcode_libdir_separator"; then if test -z "$hardcode_libdirs"; then hardcode_libdirs=$libdir else # Just accumulate the unique libdirs. case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" func_append rpath " $flag" fi elif test -n "$runpath_var"; then case "$perm_rpath " in *" $libdir "*) ;; *) func_append perm_rpath " $libdir" ;; esac fi case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-cegcc*) testbindir=`$ECHO "$libdir" | $SED -e 's*/lib$*/bin*'` case :$dllsearchpath: in *":$libdir:"*) ;; ::) dllsearchpath=$libdir;; *) func_append dllsearchpath ":$libdir";; esac case :$dllsearchpath: in *":$testbindir:"*) ;; ::) dllsearchpath=$testbindir;; *) func_append dllsearchpath ":$testbindir";; esac ;; esac done # Substitute the hardcoded libdirs into the rpath. if test -n "$hardcode_libdir_separator" && test -n "$hardcode_libdirs"; then libdir=$hardcode_libdirs eval rpath=\" $hardcode_libdir_flag_spec\" fi compile_rpath=$rpath rpath= hardcode_libdirs= for libdir in $finalize_rpath; do if test -n "$hardcode_libdir_flag_spec"; then if test -n "$hardcode_libdir_separator"; then if test -z "$hardcode_libdirs"; then hardcode_libdirs=$libdir else # Just accumulate the unique libdirs. case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) func_append hardcode_libdirs "$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" func_append rpath " $flag" fi elif test -n "$runpath_var"; then case "$finalize_perm_rpath " in *" $libdir "*) ;; *) func_append finalize_perm_rpath " $libdir" ;; esac fi done # Substitute the hardcoded libdirs into the rpath. if test -n "$hardcode_libdir_separator" && test -n "$hardcode_libdirs"; then libdir=$hardcode_libdirs eval rpath=\" $hardcode_libdir_flag_spec\" fi finalize_rpath=$rpath if test -n "$libobjs" && test yes = "$build_old_libs"; then # Transform all the library objects into standard objects. compile_command=`$ECHO "$compile_command" | $SP2NL | $SED "$lo2o" | $NL2SP` finalize_command=`$ECHO "$finalize_command" | $SP2NL | $SED "$lo2o" | $NL2SP` fi func_generate_dlsyms "$outputname" "@PROGRAM@" false # template prelinking step if test -n "$prelink_cmds"; then func_execute_cmds "$prelink_cmds" 'exit $?' fi wrappers_required=: case $host in *cegcc* | *mingw32ce*) # Disable wrappers for cegcc and mingw32ce hosts, we are cross compiling anyway. wrappers_required=false ;; *cygwin* | *mingw* ) test yes = "$build_libtool_libs" || wrappers_required=false ;; *) if test no = "$need_relink" || test yes != "$build_libtool_libs"; then wrappers_required=false fi ;; esac $wrappers_required || { # Replace the output file specification. compile_command=`$ECHO "$compile_command" | $SED 's%@OUTPUT@%'"$output"'%g'` link_command=$compile_command$compile_rpath # We have no uninstalled library dependencies, so finalize right now. exit_status=0 func_show_eval "$link_command" 'exit_status=$?' if test -n "$postlink_cmds"; then func_to_tool_file "$output" postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` func_execute_cmds "$postlink_cmds" 'exit $?' fi # Delete the generated files. if test -f "$output_objdir/${outputname}S.$objext"; then func_show_eval '$RM "$output_objdir/${outputname}S.$objext"' fi exit $exit_status } if test -n "$compile_shlibpath$finalize_shlibpath"; then compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command" fi if test -n "$finalize_shlibpath"; then finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command" fi compile_var= finalize_var= if test -n "$runpath_var"; then if test -n "$perm_rpath"; then # We should set the runpath_var. rpath= for dir in $perm_rpath; do func_append rpath "$dir:" done compile_var="$runpath_var=\"$rpath\$$runpath_var\" " fi if test -n "$finalize_perm_rpath"; then # We should set the runpath_var. rpath= for dir in $finalize_perm_rpath; do func_append rpath "$dir:" done finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " fi fi if test yes = "$no_install"; then # We don't need to create a wrapper script. link_command=$compile_var$compile_command$compile_rpath # Replace the output file specification. link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output"'%g'` # Delete the old output file. $opt_dry_run || $RM $output # Link the executable and exit func_show_eval "$link_command" 'exit $?' if test -n "$postlink_cmds"; then func_to_tool_file "$output" postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` func_execute_cmds "$postlink_cmds" 'exit $?' fi exit $EXIT_SUCCESS fi case $hardcode_action,$fast_install in relink,*) # Fast installation is not supported link_command=$compile_var$compile_command$compile_rpath relink_command=$finalize_var$finalize_command$finalize_rpath func_warning "this platform does not like uninstalled shared libraries" func_warning "'$output' will be relinked during installation" ;; *,yes) link_command=$finalize_var$compile_command$finalize_rpath relink_command=`$ECHO "$compile_var$compile_command$compile_rpath" | $SED 's%@OUTPUT@%\$progdir/\$file%g'` ;; *,no) link_command=$compile_var$compile_command$compile_rpath relink_command=$finalize_var$finalize_command$finalize_rpath ;; *,needless) link_command=$finalize_var$compile_command$finalize_rpath relink_command= ;; esac # Replace the output file specification. link_command=`$ECHO "$link_command" | $SED 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` # Delete the old output files. $opt_dry_run || $RM $output $output_objdir/$outputname $output_objdir/lt-$outputname func_show_eval "$link_command" 'exit $?' if test -n "$postlink_cmds"; then func_to_tool_file "$output_objdir/$outputname" postlink_cmds=`func_echo_all "$postlink_cmds" | $SED -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g' -e 's%@TOOL_OUTPUT@%'"$func_to_tool_file_result"'%g'` func_execute_cmds "$postlink_cmds" 'exit $?' fi # Now create the wrapper script. func_verbose "creating $output" # Quote the relink command for shipping. if test -n "$relink_command"; then # Preserve any variables that may affect compiler behavior for var in $variables_saved_for_relink; do if eval test -z \"\${$var+set}\"; then relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" elif eval var_value=\$$var; test -z "$var_value"; then relink_command="$var=; export $var; $relink_command" else func_quote_for_eval "$var_value" relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" fi done relink_command="(cd `pwd`; $relink_command)" relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` fi # Only actually do things if not in dry run mode. $opt_dry_run || { # win32 will think the script is a binary if it has # a .exe suffix, so we strip it off here. case $output in *.exe) func_stripname '' '.exe' "$output" output=$func_stripname_result ;; esac # test for cygwin because mv fails w/o .exe extensions case $host in *cygwin*) exeext=.exe func_stripname '' '.exe' "$outputname" outputname=$func_stripname_result ;; *) exeext= ;; esac case $host in *cygwin* | *mingw* ) func_dirname_and_basename "$output" "" "." output_name=$func_basename_result output_path=$func_dirname_result cwrappersource=$output_path/$objdir/lt-$output_name.c cwrapper=$output_path/$output_name.exe $RM $cwrappersource $cwrapper trap "$RM $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 func_emit_cwrapperexe_src > $cwrappersource # The wrapper executable is built using the $host compiler, # because it contains $host paths and files. If cross- # compiling, it, like the target executable, must be # executed on the $host or under an emulation environment. $opt_dry_run || { $LTCC $LTCFLAGS -o $cwrapper $cwrappersource $STRIP $cwrapper } # Now, create the wrapper script for func_source use: func_ltwrapper_scriptname $cwrapper $RM $func_ltwrapper_scriptname_result trap "$RM $func_ltwrapper_scriptname_result; exit $EXIT_FAILURE" 1 2 15 $opt_dry_run || { # note: this script will not be executed, so do not chmod. if test "x$build" = "x$host"; then $cwrapper --lt-dump-script > $func_ltwrapper_scriptname_result else func_emit_wrapper no > $func_ltwrapper_scriptname_result fi } ;; * ) $RM $output trap "$RM $output; exit $EXIT_FAILURE" 1 2 15 func_emit_wrapper no > $output chmod +x $output ;; esac } exit $EXIT_SUCCESS ;; esac # See if we need to build an old-fashioned archive. for oldlib in $oldlibs; do case $build_libtool_libs in convenience) oldobjs="$libobjs_save $symfileobj" addlibs=$convenience build_libtool_libs=no ;; module) oldobjs=$libobjs_save addlibs=$old_convenience build_libtool_libs=no ;; *) oldobjs="$old_deplibs $non_pic_objects" $preload && test -f "$symfileobj" \ && func_append oldobjs " $symfileobj" addlibs=$old_convenience ;; esac if test -n "$addlibs"; then gentop=$output_objdir/${outputname}x func_append generated " $gentop" func_extract_archives $gentop $addlibs func_append oldobjs " $func_extract_archives_result" fi # Do each command in the archive commands. if test -n "$old_archive_from_new_cmds" && test yes = "$build_libtool_libs"; then cmds=$old_archive_from_new_cmds else # Add any objects from preloaded convenience libraries if test -n "$dlprefiles"; then gentop=$output_objdir/${outputname}x func_append generated " $gentop" func_extract_archives $gentop $dlprefiles func_append oldobjs " $func_extract_archives_result" fi # POSIX demands no paths to be encoded in archives. We have # to avoid creating archives with duplicate basenames if we # might have to extract them afterwards, e.g., when creating a # static archive out of a convenience library, or when linking # the entirety of a libtool archive into another (currently # not supported by libtool). if (for obj in $oldobjs do func_basename "$obj" $ECHO "$func_basename_result" done | sort | sort -uc >/dev/null 2>&1); then : else echo "copying selected object files to avoid basename conflicts..." gentop=$output_objdir/${outputname}x func_append generated " $gentop" func_mkdir_p "$gentop" save_oldobjs=$oldobjs oldobjs= counter=1 for obj in $save_oldobjs do func_basename "$obj" objbase=$func_basename_result case " $oldobjs " in " ") oldobjs=$obj ;; *[\ /]"$objbase "*) while :; do # Make sure we don't pick an alternate name that also # overlaps. newobj=lt$counter-$objbase func_arith $counter + 1 counter=$func_arith_result case " $oldobjs " in *[\ /]"$newobj "*) ;; *) if test ! -f "$gentop/$newobj"; then break; fi ;; esac done func_show_eval "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" func_append oldobjs " $gentop/$newobj" ;; *) func_append oldobjs " $obj" ;; esac done fi func_to_tool_file "$oldlib" func_convert_file_msys_to_w32 tool_oldlib=$func_to_tool_file_result eval cmds=\"$old_archive_cmds\" func_len " $cmds" len=$func_len_result if test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then cmds=$old_archive_cmds elif test -n "$archiver_list_spec"; then func_verbose "using command file archive linking..." for obj in $oldobjs do func_to_tool_file "$obj" $ECHO "$func_to_tool_file_result" done > $output_objdir/$libname.libcmd func_to_tool_file "$output_objdir/$libname.libcmd" oldobjs=" $archiver_list_spec$func_to_tool_file_result" cmds=$old_archive_cmds else # the command line is too long to link in one step, link in parts func_verbose "using piecewise archive linking..." save_RANLIB=$RANLIB RANLIB=: objlist= concat_cmds= save_oldobjs=$oldobjs oldobjs= # Is there a better way of finding the last object in the list? for obj in $save_oldobjs do last_oldobj=$obj done eval test_cmds=\"$old_archive_cmds\" func_len " $test_cmds" len0=$func_len_result len=$len0 for obj in $save_oldobjs do func_len " $obj" func_arith $len + $func_len_result len=$func_arith_result func_append objlist " $obj" if test "$len" -lt "$max_cmd_len"; then : else # the above command should be used before it gets too long oldobjs=$objlist if test "$obj" = "$last_oldobj"; then RANLIB=$save_RANLIB fi test -z "$concat_cmds" || concat_cmds=$concat_cmds~ eval concat_cmds=\"\$concat_cmds$old_archive_cmds\" objlist= len=$len0 fi done RANLIB=$save_RANLIB oldobjs=$objlist if test -z "$oldobjs"; then eval cmds=\"\$concat_cmds\" else eval cmds=\"\$concat_cmds~\$old_archive_cmds\" fi fi fi func_execute_cmds "$cmds" 'exit $?' done test -n "$generated" && \ func_show_eval "${RM}r$generated" # Now create the libtool archive. case $output in *.la) old_library= test yes = "$build_old_libs" && old_library=$libname.$libext func_verbose "creating $output" # Preserve any variables that may affect compiler behavior for var in $variables_saved_for_relink; do if eval test -z \"\${$var+set}\"; then relink_command="{ test -z \"\${$var+set}\" || $lt_unset $var || { $var=; export $var; }; }; $relink_command" elif eval var_value=\$$var; test -z "$var_value"; then relink_command="$var=; export $var; $relink_command" else func_quote_for_eval "$var_value" relink_command="$var=$func_quote_for_eval_result; export $var; $relink_command" fi done # Quote the link command for shipping. relink_command="(cd `pwd`; $SHELL \"$progpath\" $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" relink_command=`$ECHO "$relink_command" | $SED "$sed_quote_subst"` if test yes = "$hardcode_automatic"; then relink_command= fi # Only create the output if not a dry run. $opt_dry_run || { for installed in no yes; do if test yes = "$installed"; then if test -z "$install_libdir"; then break fi output=$output_objdir/${outputname}i # Replace all uninstalled libtool libraries with the installed ones newdependency_libs= for deplib in $dependency_libs; do case $deplib in *.la) func_basename "$deplib" name=$func_basename_result func_resolve_sysroot "$deplib" eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $func_resolve_sysroot_result` test -z "$libdir" && \ func_fatal_error "'$deplib' is not a valid libtool archive" func_append newdependency_libs " ${lt_sysroot:+=}$libdir/$name" ;; -L*) func_stripname -L '' "$deplib" func_replace_sysroot "$func_stripname_result" func_append newdependency_libs " -L$func_replace_sysroot_result" ;; -R*) func_stripname -R '' "$deplib" func_replace_sysroot "$func_stripname_result" func_append newdependency_libs " -R$func_replace_sysroot_result" ;; *) func_append newdependency_libs " $deplib" ;; esac done dependency_libs=$newdependency_libs newdlfiles= for lib in $dlfiles; do case $lib in *.la) func_basename "$lib" name=$func_basename_result eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $lib` test -z "$libdir" && \ func_fatal_error "'$lib' is not a valid libtool archive" func_append newdlfiles " ${lt_sysroot:+=}$libdir/$name" ;; *) func_append newdlfiles " $lib" ;; esac done dlfiles=$newdlfiles newdlprefiles= for lib in $dlprefiles; do case $lib in *.la) # Only pass preopened files to the pseudo-archive (for # eventual linking with the app. that links it) if we # didn't already link the preopened objects directly into # the library: func_basename "$lib" name=$func_basename_result eval libdir=`$SED -n -e 's/^libdir=\(.*\)$/\1/p' $lib` test -z "$libdir" && \ func_fatal_error "'$lib' is not a valid libtool archive" func_append newdlprefiles " ${lt_sysroot:+=}$libdir/$name" ;; esac done dlprefiles=$newdlprefiles else newdlfiles= for lib in $dlfiles; do case $lib in [\\/]* | [A-Za-z]:[\\/]*) abs=$lib ;; *) abs=`pwd`"/$lib" ;; esac func_append newdlfiles " $abs" done dlfiles=$newdlfiles newdlprefiles= for lib in $dlprefiles; do case $lib in [\\/]* | [A-Za-z]:[\\/]*) abs=$lib ;; *) abs=`pwd`"/$lib" ;; esac func_append newdlprefiles " $abs" done dlprefiles=$newdlprefiles fi $RM $output # place dlname in correct position for cygwin # In fact, it would be nice if we could use this code for all target # systems that can't hard-code library paths into their executables # and that have no shared library path variable independent of PATH, # but it turns out we can't easily determine that from inspecting # libtool variables, so we have to hard-code the OSs to which it # applies here; at the moment, that means platforms that use the PE # object format with DLL files. See the long comment at the top of # tests/bindir.at for full details. tdlname=$dlname case $host,$output,$installed,$module,$dlname in *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll | *cegcc*,*lai,yes,no,*.dll) # If a -bindir argument was supplied, place the dll there. if test -n "$bindir"; then func_relative_path "$install_libdir" "$bindir" tdlname=$func_relative_path_result/$dlname else # Otherwise fall back on heuristic. tdlname=../bin/$dlname fi ;; esac $ECHO > $output "\ # $outputname - a libtool library file # Generated by $PROGRAM (GNU $PACKAGE) $VERSION # # Please DO NOT delete this file! # It is necessary for linking the library. # The name that we can dlopen(3). dlname='$tdlname' # Names of this library. library_names='$library_names' # The name of the static archive. old_library='$old_library' # Linker flags that cannot go in dependency_libs. inherited_linker_flags='$new_inherited_linker_flags' # Libraries that this one depends upon. dependency_libs='$dependency_libs' # Names of additional weak libraries provided by this library weak_library_names='$weak_libs' # Version information for $libname. current=$current age=$age revision=$revision # Is this an already installed library? installed=$installed # Should we warn about portability when linking against -modules? shouldnotlink=$module # Files to dlopen/dlpreopen dlopen='$dlfiles' dlpreopen='$dlprefiles' # Directory that this library needs to be installed in: libdir='$install_libdir'" if test no,yes = "$installed,$need_relink"; then $ECHO >> $output "\ relink_command=\"$relink_command\"" fi done } # Do a symbolic link so that the libtool archive can be found in # LD_LIBRARY_PATH before the program is installed. func_show_eval '( cd "$output_objdir" && $RM "$outputname" && $LN_S "../$outputname" "$outputname" )' 'exit $?' ;; esac exit $EXIT_SUCCESS } if test link = "$opt_mode" || test relink = "$opt_mode"; then func_mode_link ${1+"$@"} fi # func_mode_uninstall arg... func_mode_uninstall () { $debug_cmd RM=$nonopt files= rmforce=false exit_status=0 # This variable tells wrapper scripts just to set variables rather # than running their programs. libtool_install_magic=$magic for arg do case $arg in -f) func_append RM " $arg"; rmforce=: ;; -*) func_append RM " $arg" ;; *) func_append files " $arg" ;; esac done test -z "$RM" && \ func_fatal_help "you must specify an RM program" rmdirs= for file in $files; do func_dirname "$file" "" "." dir=$func_dirname_result if test . = "$dir"; then odir=$objdir else odir=$dir/$objdir fi func_basename "$file" name=$func_basename_result test uninstall = "$opt_mode" && odir=$dir # Remember odir for removal later, being careful to avoid duplicates if test clean = "$opt_mode"; then case " $rmdirs " in *" $odir "*) ;; *) func_append rmdirs " $odir" ;; esac fi # Don't error if the file doesn't exist and rm -f was used. if { test -L "$file"; } >/dev/null 2>&1 || { test -h "$file"; } >/dev/null 2>&1 || test -f "$file"; then : elif test -d "$file"; then exit_status=1 continue elif $rmforce; then continue fi rmfiles=$file case $name in *.la) # Possibly a libtool archive, so verify it. if func_lalib_p "$file"; then func_source $dir/$name # Delete the libtool libraries and symlinks. for n in $library_names; do func_append rmfiles " $odir/$n" done test -n "$old_library" && func_append rmfiles " $odir/$old_library" case $opt_mode in clean) case " $library_names " in *" $dlname "*) ;; *) test -n "$dlname" && func_append rmfiles " $odir/$dlname" ;; esac test -n "$libdir" && func_append rmfiles " $odir/$name $odir/${name}i" ;; uninstall) if test -n "$library_names"; then # Do each command in the postuninstall commands. func_execute_cmds "$postuninstall_cmds" '$rmforce || exit_status=1' fi if test -n "$old_library"; then # Do each command in the old_postuninstall commands. func_execute_cmds "$old_postuninstall_cmds" '$rmforce || exit_status=1' fi # FIXME: should reinstall the best remaining shared library. ;; esac fi ;; *.lo) # Possibly a libtool object, so verify it. if func_lalib_p "$file"; then # Read the .lo file func_source $dir/$name # Add PIC object to the list of files to remove. if test -n "$pic_object" && test none != "$pic_object"; then func_append rmfiles " $dir/$pic_object" fi # Add non-PIC object to the list of files to remove. if test -n "$non_pic_object" && test none != "$non_pic_object"; then func_append rmfiles " $dir/$non_pic_object" fi fi ;; *) if test clean = "$opt_mode"; then noexename=$name case $file in *.exe) func_stripname '' '.exe' "$file" file=$func_stripname_result func_stripname '' '.exe' "$name" noexename=$func_stripname_result # $file with .exe has already been added to rmfiles, # add $file without .exe func_append rmfiles " $file" ;; esac # Do a test to see if this is a libtool program. if func_ltwrapper_p "$file"; then if func_ltwrapper_executable_p "$file"; then func_ltwrapper_scriptname "$file" relink_command= func_source $func_ltwrapper_scriptname_result func_append rmfiles " $func_ltwrapper_scriptname_result" else relink_command= func_source $dir/$noexename fi # note $name still contains .exe if it was in $file originally # as does the version of $file that was added into $rmfiles func_append rmfiles " $odir/$name $odir/${name}S.$objext" if test yes = "$fast_install" && test -n "$relink_command"; then func_append rmfiles " $odir/lt-$name" fi if test "X$noexename" != "X$name"; then func_append rmfiles " $odir/lt-$noexename.c" fi fi fi ;; esac func_show_eval "$RM $rmfiles" 'exit_status=1' done # Try to remove the $objdir's in the directories where we deleted files for dir in $rmdirs; do if test -d "$dir"; then func_show_eval "rmdir $dir >/dev/null 2>&1" fi done exit $exit_status } if test uninstall = "$opt_mode" || test clean = "$opt_mode"; then func_mode_uninstall ${1+"$@"} fi test -z "$opt_mode" && { help=$generic_help func_fatal_help "you must specify a MODE" } test -z "$exec_cmd" && \ func_fatal_help "invalid operation mode '$opt_mode'" if test -n "$exec_cmd"; then eval exec "$exec_cmd" exit $EXIT_FAILURE fi exit $exit_status # The TAGs below are defined such that we never get into a situation # where we disable both kinds of libraries. Given conflicting # choices, we go for a static library, that is the most portable, # since we can't tell whether shared libraries were disabled because # the user asked for that or because the platform doesn't support # them. This is particularly important on AIX, because we don't # support having both static and shared libraries enabled at the same # time on that platform, so we default to a shared-only configuration. # If a disable-shared tag is given, we'll fallback to a static-only # configuration. But we'll never go from static-only to shared-only. # ### BEGIN LIBTOOL TAG CONFIG: disable-shared build_libtool_libs=no build_old_libs=yes # ### END LIBTOOL TAG CONFIG: disable-shared # ### BEGIN LIBTOOL TAG CONFIG: disable-static build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` # ### END LIBTOOL TAG CONFIG: disable-static # Local Variables: # mode:shell-script # sh-indentation:2 # End: �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/m4/�����������������������������������������������������������������������������������0000775�0001750�0001750�00000000000�13411152374�010464� 5����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/m4/boost.m4���������������������������������������������������������������������������0000664�0001750�0001750�00000154665�13407173247�012024� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������# boost.m4: Locate Boost headers and libraries for autoconf-based projects. # Copyright (C) 2007-2011, 2014 Benoit Sigoure <tsuna@lrde.epita.fr> # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # Additional permission under section 7 of the GNU General Public # License, version 3 ("GPLv3"): # # If you convey this file as part of a work that contains a # configuration script generated by Autoconf, you may do so under # terms of your choice. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. m4_define([_BOOST_SERIAL], [m4_translit([ # serial 26 ], [# ], [])]) # Original sources can be found at http://github.com/tsuna/boost.m4 # You can fetch the latest version of the script by doing: # wget http://github.com/tsuna/boost.m4/raw/master/build-aux/boost.m4 # ------ # # README # # ------ # # This file provides several macros to use the various Boost libraries. # The first macro is BOOST_REQUIRE. It will simply check if it's possible to # find the Boost headers of a given (optional) minimum version and it will # define BOOST_CPPFLAGS accordingly. It will add an option --with-boost to # your configure so that users can specify non standard locations. # If the user's environment contains BOOST_ROOT and --with-boost was not # specified, --with-boost=$BOOST_ROOT is implicitly used. # For more README and documentation, go to http://github.com/tsuna/boost.m4 # Note: THESE MACROS ASSUME THAT YOU USE LIBTOOL. If you don't, don't worry, # simply read the README, it will show you what to do step by step. m4_pattern_forbid([^_?(BOOST|Boost)_]) # _BOOST_SED_CPP(SED-PROGRAM, PROGRAM, # [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) # -------------------------------------------------------- # Same as AC_EGREP_CPP, but leave the result in conftest.i. # # SED-PROGRAM is *not* overquoted, as in AC_EGREP_CPP. It is expanded # in double-quotes, so escape your double quotes. # # It could be useful to turn this into a macro which extracts the # value of any macro. m4_define([_BOOST_SED_CPP], [AC_LANG_PUSH([C++])dnl AC_LANG_PREPROC_REQUIRE()dnl AC_REQUIRE([AC_PROG_SED])dnl AC_LANG_CONFTEST([AC_LANG_SOURCE([[$2]])]) AS_IF([dnl eval is necessary to expand ac_cpp. dnl Ultrix and Pyramid sh refuse to redirect output of eval, so use subshell. dnl Beware of Windows end-of-lines, for instance if we are running dnl some Windows programs under Wine. In that case, boost/version.hpp dnl is certainly using "\r\n", but the regular Unix shell will only dnl strip `\n' with backquotes, not the `\r'. This results in dnl boost_cv_lib_version='1_37\r' for instance, which breaks dnl everything else. dnl Cannot use 'dnl' after [$4] because a trailing dnl may break AC_CACHE_CHECK dnl dnl Beware that GCC 5, when expanding macros, may embed # line directives dnl a within single line: dnl dnl # 1 "conftest.cc" dnl # 1 "<built-in>" dnl # 1 "<command-line>" dnl # 1 "conftest.cc" dnl # 1 "/opt/local/include/boost/version.hpp" 1 3 dnl # 2 "conftest.cc" 2 dnl boost-lib-version = dnl # 2 "conftest.cc" 3 dnl "1_56" dnl dnl So get rid of the # and empty lines, and glue the remaining ones together. (eval "$ac_cpp conftest.$ac_ext") 2>&AS_MESSAGE_LOG_FD | grep -v '#' | grep -v '^[[[:space:]]]*$' | tr -d '\r' | tr -s '\n' ' ' | $SED -n -e "$1" >conftest.i 2>&1], [$3], [$4]) rm -rf conftest* AC_LANG_POP([C++])dnl ])# _BOOST_SED_CPP # BOOST_REQUIRE([VERSION], [ACTION-IF-NOT-FOUND]) # ----------------------------------------------- # Look for Boost. If version is given, it must either be a literal of the form # "X.Y.Z" where X, Y and Z are integers (the ".Z" part being optional) or a # variable "$var". # Defines the value BOOST_CPPFLAGS. This macro only checks for headers with # the required version, it does not check for any of the Boost libraries. # On # success, defines HAVE_BOOST. On failure, calls the optional # ACTION-IF-NOT-FOUND action if one was supplied. # Otherwise aborts with an error message. AC_DEFUN_ONCE([BOOST_REQUIRE], [AC_REQUIRE([AC_PROG_CXX])dnl AC_REQUIRE([AC_PROG_GREP])dnl echo "$as_me: this is boost.m4[]_BOOST_SERIAL" >&AS_MESSAGE_LOG_FD boost_save_IFS=$IFS boost_version_req=$1 IFS=. set x $boost_version_req 0 0 0 IFS=$boost_save_IFS shift boost_version_req=`expr "$[1]" '*' 100000 + "$[2]" '*' 100 + "$[3]"` boost_version_req_string=$[1].$[2].$[3] AC_ARG_WITH([boost], [AS_HELP_STRING([--with-boost=DIR], [prefix of Boost $1 @<:@guess@:>@])])dnl AC_ARG_VAR([BOOST_ROOT],[Location of Boost installation])dnl # If BOOST_ROOT is set and the user has not provided a value to # --with-boost, then treat BOOST_ROOT as if it the user supplied it. if test x"$BOOST_ROOT" != x; then if test x"$with_boost" = x; then AC_MSG_NOTICE([Detected BOOST_ROOT; continuing with --with-boost=$BOOST_ROOT]) with_boost=$BOOST_ROOT else AC_MSG_NOTICE([Detected BOOST_ROOT=$BOOST_ROOT, but overridden by --with-boost=$with_boost]) fi fi AC_SUBST([DISTCHECK_CONFIGURE_FLAGS], ["$DISTCHECK_CONFIGURE_FLAGS '--with-boost=$with_boost'"])dnl boost_save_CPPFLAGS=$CPPFLAGS AC_CACHE_CHECK([for Boost headers version >= $boost_version_req_string], [boost_cv_inc_path], [boost_cv_inc_path=no AC_LANG_PUSH([C++])dnl m4_pattern_allow([^BOOST_VERSION$])dnl AC_LANG_CONFTEST([AC_LANG_PROGRAM([[#include <boost/version.hpp> #if !defined BOOST_VERSION # error BOOST_VERSION is not defined #elif BOOST_VERSION < $boost_version_req # error Boost headers version < $boost_version_req #endif ]])]) # If the user provided a value to --with-boost, use it and only it. case $with_boost in #( ''|yes) set x '' /opt/local/include /usr/local/include /opt/include \ /usr/include C:/Boost/include;; #( *) set x "$with_boost/include" "$with_boost";; esac shift for boost_dir do # Without --layout=system, Boost (or at least some versions) installs # itself in <prefix>/include/boost-<version>. This inner loop helps to # find headers in such directories. # # Any ${boost_dir}/boost-x_xx directories are searched in reverse version # order followed by ${boost_dir}. The final '.' is a sentinel for # searching $boost_dir" itself. Entries are whitespace separated. # # I didn't indent this loop on purpose (to avoid over-indented code) boost_layout_system_search_list=`cd "$boost_dir" 2>/dev/null \ && ls -1 | "${GREP}" '^boost-' | sort -rn -t- -k2 \ && echo .` for boost_inc in $boost_layout_system_search_list do if test x"$boost_inc" != x.; then boost_inc="$boost_dir/$boost_inc" else boost_inc="$boost_dir" # Uses sentinel in boost_layout_system_search_list fi if test x"$boost_inc" != x; then # We are going to check whether the version of Boost installed # in $boost_inc is usable by running a compilation that # #includes it. But if we pass a -I/some/path in which Boost # is not installed, the compiler will just skip this -I and # use other locations (either from CPPFLAGS, or from its list # of system include directories). As a result we would use # header installed on the machine instead of the /some/path # specified by the user. So in that precise case (trying # $boost_inc), make sure the version.hpp exists. # # Use test -e as there can be symlinks. test -e "$boost_inc/boost/version.hpp" || continue CPPFLAGS="$CPPFLAGS -I$boost_inc" fi AC_COMPILE_IFELSE([], [boost_cv_inc_path=yes], [boost_cv_version=no]) if test x"$boost_cv_inc_path" = xyes; then if test x"$boost_inc" != x; then boost_cv_inc_path=$boost_inc fi break 2 fi done done AC_LANG_POP([C++])dnl ]) case $boost_cv_inc_path in #( no) boost_errmsg="cannot find Boost headers version >= $boost_version_req_string" m4_if([$2], [], [AC_MSG_ERROR([$boost_errmsg])], [AC_MSG_NOTICE([$boost_errmsg])]) $2 ;;#( yes) BOOST_CPPFLAGS= ;;#( *) AC_SUBST([BOOST_CPPFLAGS], ["-I$boost_cv_inc_path"])dnl ;; esac if test x"$boost_cv_inc_path" != xno; then AC_DEFINE([HAVE_BOOST], [1], [Defined if the requested minimum BOOST version is satisfied]) AC_CACHE_CHECK([for Boost's header version], [boost_cv_lib_version], [m4_pattern_allow([^BOOST_LIB_VERSION$])dnl _BOOST_SED_CPP([[/^boost-lib-version = /{s///;s/[\" ]//g;p;q;}]], [#include <boost/version.hpp> boost-lib-version = BOOST_LIB_VERSION], [boost_cv_lib_version=`cat conftest.i`])]) # e.g. "134" for 1_34_1 or "135" for 1_35 boost_major_version=`echo "$boost_cv_lib_version" | sed 's/_//;s/_.*//'` case $boost_major_version in #( '' | *[[!0-9]]*) AC_MSG_ERROR([invalid value: boost_major_version='$boost_major_version']) ;; esac fi CPPFLAGS=$boost_save_CPPFLAGS ])# BOOST_REQUIRE # BOOST_STATIC() # -------------- # Add the "--enable-static-boost" configure argument. If this argument is given # on the command line, static versions of the libraries will be looked up. AC_DEFUN([BOOST_STATIC], [AC_ARG_ENABLE([static-boost], [AS_HELP_STRING([--enable-static-boost], [Prefer the static boost libraries over the shared ones [no]])], [enable_static_boost=yes], [enable_static_boost=no])])# BOOST_STATIC # BOOST_FIND_HEADER([HEADER-NAME], [ACTION-IF-NOT-FOUND], [ACTION-IF-FOUND]) # -------------------------------------------------------------------------- # Wrapper around AC_CHECK_HEADER for Boost headers. Useful to check for # some parts of the Boost library which are only made of headers and don't # require linking (such as Boost.Foreach). # # Default ACTION-IF-NOT-FOUND: Fail with a fatal error unless Boost couldn't be # found in the first place, in which case by default a notice is issued to the # user. Presumably if we haven't died already it's because it's OK to not have # Boost, which is why only a notice is issued instead of a hard error. # # Default ACTION-IF-FOUND: define the preprocessor symbol HAVE_<HEADER-NAME> in # case of success # (where HEADER-NAME is written LIKE_THIS, e.g., # HAVE_BOOST_FOREACH_HPP). AC_DEFUN([BOOST_FIND_HEADER], [AC_REQUIRE([BOOST_REQUIRE])dnl if test x"$boost_cv_inc_path" = xno; then m4_default([$2], [AC_MSG_NOTICE([Boost not available, not searching for $1])]) else AC_LANG_PUSH([C++])dnl boost_save_CPPFLAGS=$CPPFLAGS CPPFLAGS="$CPPFLAGS $BOOST_CPPFLAGS" AC_CHECK_HEADER([$1], [m4_default([$3], [AC_DEFINE(AS_TR_CPP([HAVE_$1]), [1], [Define to 1 if you have <$1>])])], [m4_default([$2], [AC_MSG_ERROR([cannot find $1])])]) CPPFLAGS=$boost_save_CPPFLAGS AC_LANG_POP([C++])dnl fi ])# BOOST_FIND_HEADER # BOOST_FIND_LIBS([COMPONENT-NAME], [CANDIDATE-LIB-NAMES], # [PREFERRED-RT-OPT], [HEADER-NAME], [CXX-TEST], # [CXX-PROLOGUE]) # -------------------------------------------------------------- # Look for the Boost library COMPONENT-NAME (e.g., `thread', for # libboost_thread) under the possible CANDIDATE-LIB-NAMES (e.g., # "thread_win32 thread"). Check that HEADER-NAME works and check that # libboost_LIB-NAME can link with the code CXX-TEST. The optional # argument CXX-PROLOGUE can be used to include some C++ code before # the `main' function. # # Invokes BOOST_FIND_HEADER([HEADER-NAME]) (see above). # # Boost libraries typically come compiled with several flavors (with different # runtime options) so PREFERRED-RT-OPT is the preferred suffix. A suffix is one # or more of the following letters: sgdpn (in that order). s = static # runtime, d = debug build, g = debug/diagnostic runtime, p = STLPort build, # n = (unsure) STLPort build without iostreams from STLPort (it looks like `n' # must always be used along with `p'). Additionally, PREFERRED-RT-OPT can # start with `mt-' to indicate that there is a preference for multi-thread # builds. Some sample values for PREFERRED-RT-OPT: (nothing), mt, d, mt-d, gdp # ... If you want to make sure you have a specific version of Boost # (eg, >= 1.33) you *must* invoke BOOST_REQUIRE before this macro. AC_DEFUN([BOOST_FIND_LIBS], [AC_REQUIRE([BOOST_REQUIRE])dnl AC_REQUIRE([_BOOST_FIND_COMPILER_TAG])dnl AC_REQUIRE([BOOST_STATIC])dnl AC_REQUIRE([_BOOST_GUESS_WHETHER_TO_USE_MT])dnl if test x"$boost_cv_inc_path" = xno; then AC_MSG_NOTICE([Boost not available, not searching for the Boost $1 library]) else dnl The else branch is huge and wasn't intended on purpose. AC_LANG_PUSH([C++])dnl AS_VAR_PUSHDEF([Boost_lib], [boost_cv_lib_$1])dnl AS_VAR_PUSHDEF([Boost_lib_LDFLAGS], [boost_cv_lib_$1_LDFLAGS])dnl AS_VAR_PUSHDEF([Boost_lib_LDPATH], [boost_cv_lib_$1_LDPATH])dnl AS_VAR_PUSHDEF([Boost_lib_LIBS], [boost_cv_lib_$1_LIBS])dnl BOOST_FIND_HEADER([$4]) boost_save_CPPFLAGS=$CPPFLAGS CPPFLAGS="$CPPFLAGS $BOOST_CPPFLAGS" AC_CACHE_CHECK([for the Boost $1 library], [Boost_lib], [_BOOST_FIND_LIBS($@)]) case $Boost_lib in #( (no) _AC_MSG_LOG_CONFTEST AC_MSG_ERROR([cannot find the flags to link with Boost $1]) ;; esac AC_SUBST(AS_TR_CPP([BOOST_$1_LDFLAGS]), [$Boost_lib_LDFLAGS])dnl AC_SUBST(AS_TR_CPP([BOOST_$1_LDPATH]), [$Boost_lib_LDPATH])dnl AC_SUBST([BOOST_LDPATH], [$Boost_lib_LDPATH])dnl AC_SUBST(AS_TR_CPP([BOOST_$1_LIBS]), [$Boost_lib_LIBS])dnl CPPFLAGS=$boost_save_CPPFLAGS AS_VAR_POPDEF([Boost_lib])dnl AS_VAR_POPDEF([Boost_lib_LDFLAGS])dnl AS_VAR_POPDEF([Boost_lib_LDPATH])dnl AS_VAR_POPDEF([Boost_lib_LIBS])dnl AC_LANG_POP([C++])dnl fi ]) # BOOST_FIND_LIB([LIB-NAME], # [PREFERRED-RT-OPT], [HEADER-NAME], [CXX-TEST], # [CXX-PROLOGUE]) # -------------------------------------------------------------- # Backward compatibility wrapper for BOOST_FIND_LIBS. AC_DEFUN([BOOST_FIND_LIB], [BOOST_FIND_LIBS([$1], $@)]) # _BOOST_FIND_LIBS([LIB-NAME], [CANDIDATE-LIB-NAMES], # [PREFERRED-RT-OPT], [HEADER-NAME], [CXX-TEST], # [CXX-PROLOGUE]) # -------------------------------------------------------------- # Real implementation of BOOST_FIND_LIBS: rely on these local macros: # Boost_lib, Boost_lib_LDFLAGS, Boost_lib_LDPATH, Boost_lib_LIBS # # The algorithm is as follows: first look for a given library name # according to the user's PREFERRED-RT-OPT. For each library name, we # prefer to use the ones that carry the tag (toolset name). Each # library is searched through the various standard paths were Boost is # usually installed. If we can't find the standard variants, we try # to enforce -mt (for instance on MacOSX, libboost_thread.dylib # doesn't exist but there's -obviously- libboost_thread-mt.dylib). AC_DEFUN([_BOOST_FIND_LIBS], [Boost_lib=no case "$3" in #( (mt | mt-) boost_mt=-mt; boost_rtopt=;; #( (mt* | mt-*) boost_mt=-mt; boost_rtopt=`expr "X$3" : 'Xmt-*\(.*\)'`;; #( (*) boost_mt=; boost_rtopt=$3;; esac if test $enable_static_boost = yes; then boost_rtopt="s$boost_rtopt" fi # Find the proper debug variant depending on what we've been asked to find. case $boost_rtopt in #( (*d*) boost_rt_d=$boost_rtopt;; #( (*[[sgpn]]*) # Insert the `d' at the right place (in between `sg' and `pn') boost_rt_d=`echo "$boost_rtopt" | sed 's/\(s*g*\)\(p*n*\)/\1\2/'`;; #( (*) boost_rt_d='-d';; esac # If the PREFERRED-RT-OPT are not empty, prepend a `-'. test -n "$boost_rtopt" && boost_rtopt="-$boost_rtopt" $boost_guess_use_mt && boost_mt=-mt # Look for the abs path the static archive. # $libext is computed by Libtool but let's make sure it's non empty. test -z "$libext" && AC_MSG_ERROR([the libext variable is empty, did you invoke Libtool?]) boost_save_ac_objext=$ac_objext # Generate the test file. AC_LANG_CONFTEST([AC_LANG_PROGRAM([#include <$4> $6], [$5])]) dnl Optimization hacks: compiling C++ is slow, especially with Boost. What dnl we're trying to do here is guess the right combination of link flags dnl (LIBS / LDFLAGS) to use a given library. This can take several dnl iterations before it succeeds and is thus *very* slow. So what we do dnl instead is that we compile the code first (and thus get an object file, dnl typically conftest.o). Then we try various combinations of link flags dnl until we succeed to link conftest.o in an executable. The problem is dnl that the various TRY_LINK / COMPILE_IFELSE macros of Autoconf always dnl remove all the temporary files including conftest.o. So the trick here dnl is to temporarily change the value of ac_objext so that conftest.o is dnl preserved accross tests. This is obviously fragile and I will burn in dnl hell for not respecting Autoconf's documented interfaces, but in the dnl mean time, it optimizes the macro by a factor of 5 to 30. dnl Another small optimization: the first argument of AC_COMPILE_IFELSE left dnl empty because the test file is generated only once above (before we dnl start the for loops). AC_COMPILE_IFELSE([], [ac_objext=do_not_rm_me_plz], [AC_MSG_ERROR([cannot compile a test that uses Boost $1])]) ac_objext=$boost_save_ac_objext boost_failed_libs= # Don't bother to ident the following nested for loops, only the 2 # innermost ones matter. for boost_lib_ in $2; do for boost_tag_ in -$boost_cv_lib_tag ''; do for boost_ver_ in -$boost_cv_lib_version ''; do for boost_mt_ in $boost_mt -mt ''; do for boost_rtopt_ in $boost_rtopt '' -d; do for boost_lib in \ boost_$boost_lib_$boost_tag_$boost_mt_$boost_rtopt_$boost_ver_ \ boost_$boost_lib_$boost_tag_$boost_rtopt_$boost_ver_ \ boost_$boost_lib_$boost_tag_$boost_mt_$boost_ver_ \ boost_$boost_lib_$boost_tag_$boost_ver_ do # Avoid testing twice the same lib case $boost_failed_libs in #( (*@$boost_lib@*) continue;; esac # If with_boost is empty, we'll search in /lib first, which is not quite # right so instead we'll try to a location based on where the headers are. boost_tmp_lib=$with_boost test x"$with_boost" = x && boost_tmp_lib=${boost_cv_inc_path%/include} for boost_ldpath in "$boost_tmp_lib/lib" '' \ /opt/local/lib* /usr/local/lib* /opt/lib* /usr/lib* \ "$with_boost" C:/Boost/lib /lib* do # Don't waste time with directories that don't exist. if test x"$boost_ldpath" != x && test ! -e "$boost_ldpath"; then continue fi boost_save_LDFLAGS=$LDFLAGS # Are we looking for a static library? case $boost_ldpath:$boost_rtopt_ in #( (*?*:*s*) # Yes (Non empty boost_ldpath + s in rt opt) Boost_lib_LIBS="$boost_ldpath/lib$boost_lib.$libext" test -e "$Boost_lib_LIBS" || continue;; #( (*) # No: use -lboost_foo to find the shared library. Boost_lib_LIBS="-l$boost_lib";; esac boost_save_LIBS=$LIBS LIBS="$Boost_lib_LIBS $LIBS" test x"$boost_ldpath" != x && LDFLAGS="$LDFLAGS -L$boost_ldpath" dnl First argument of AC_LINK_IFELSE left empty because the test file is dnl generated only once above (before we start the for loops). _BOOST_AC_LINK_IFELSE([], [Boost_lib=yes], [Boost_lib=no]) ac_objext=$boost_save_ac_objext LDFLAGS=$boost_save_LDFLAGS LIBS=$boost_save_LIBS if test x"$Boost_lib" = xyes; then # Check or used cached result of whether or not using -R or # -rpath makes sense. Some implementations of ld, such as for # Mac OSX, require -rpath but -R is the flag known to work on # other systems. https://github.com/tsuna/boost.m4/issues/19 AC_CACHE_VAL([boost_cv_rpath_link_ldflag], [case $boost_ldpath in '') # Nothing to do. boost_cv_rpath_link_ldflag= boost_rpath_link_ldflag_found=yes;; *) for boost_cv_rpath_link_ldflag in -Wl,-R, -Wl,-rpath,; do LDFLAGS="$boost_save_LDFLAGS -L$boost_ldpath $boost_cv_rpath_link_ldflag$boost_ldpath" LIBS="$boost_save_LIBS $Boost_lib_LIBS" _BOOST_AC_LINK_IFELSE([], [boost_rpath_link_ldflag_found=yes break], [boost_rpath_link_ldflag_found=no]) done ;; esac AS_IF([test "x$boost_rpath_link_ldflag_found" != "xyes"], [AC_MSG_ERROR([Unable to determine whether to use -R or -rpath])]) LDFLAGS=$boost_save_LDFLAGS LIBS=$boost_save_LIBS ]) test x"$boost_ldpath" != x && Boost_lib_LDFLAGS="-L$boost_ldpath $boost_cv_rpath_link_ldflag$boost_ldpath" Boost_lib_LDPATH="$boost_ldpath" break 7 else boost_failed_libs="$boost_failed_libs@$boost_lib@" fi done done done done done done done # boost_lib_ rm -f conftest.$ac_objext ]) # --------------------------------------- # # Checks for the various Boost libraries. # # --------------------------------------- # # List of boost libraries: http://www.boost.org/libs/libraries.htm # The page http://beta.boost.org/doc/libs is useful: it gives the first release # version of each library (among other things). # BOOST_DEFUN(LIBRARY, CODE) # -------------------------- # Define BOOST_<LIBRARY-UPPERCASE> as a macro that runs CODE. # # Use indir to avoid the warning on underquoted macro name given to AC_DEFUN. m4_define([BOOST_DEFUN], [m4_indir([AC_DEFUN], m4_toupper([BOOST_$1]), [m4_pushdef([BOOST_Library], [$1])dnl $2 m4_popdef([BOOST_Library])dnl ]) ]) # BOOST_ARRAY() # ------------- # Look for Boost.Array BOOST_DEFUN([Array], [BOOST_FIND_HEADER([boost/array.hpp])]) # BOOST_ASIO() # ------------ # Look for Boost.Asio (new in Boost 1.35). BOOST_DEFUN([Asio], [AC_REQUIRE([BOOST_SYSTEM])dnl BOOST_FIND_HEADER([boost/asio.hpp])]) # BOOST_ASSIGN() # ------------- # Look for Boost.Assign BOOST_DEFUN([Assign], [BOOST_FIND_HEADER([boost/assign.hpp])]) # BOOST_BIND() # ------------ # Look for Boost.Bind. BOOST_DEFUN([Bind], [BOOST_FIND_HEADER([boost/bind.hpp])]) # BOOST_CHRONO() # -------------- # Look for Boost.Chrono. BOOST_DEFUN([Chrono], [# Do we have to check for Boost.System? This link-time dependency was # added as of 1.35.0. If we have a version <1.35, we must not attempt to # find Boost.System as it didn't exist by then. if test $boost_major_version -ge 135; then BOOST_SYSTEM([$1]) fi # end of the Boost.System check. boost_filesystem_save_LIBS=$LIBS boost_filesystem_save_LDFLAGS=$LDFLAGS m4_pattern_allow([^BOOST_SYSTEM_(LIBS|LDFLAGS)$])dnl LIBS="$LIBS $BOOST_SYSTEM_LIBS" LDFLAGS="$LDFLAGS $BOOST_SYSTEM_LDFLAGS" BOOST_FIND_LIB([chrono], [$1], [boost/chrono.hpp], [boost::chrono::thread_clock d;]) if test $enable_static_boost = yes && test $boost_major_version -ge 135; then BOOST_CHRONO_LIBS="$BOOST_CHRONO_LIBS $BOOST_SYSTEM_LIBS" fi LIBS=$boost_filesystem_save_LIBS LDFLAGS=$boost_filesystem_save_LDFLAGS ])# BOOST_CHRONO # BOOST_CONTEXT([PREFERRED-RT-OPT]) # ----------------------------------- # Look for Boost.Context. For the documentation of PREFERRED-RT-OPT, see the # documentation of BOOST_FIND_LIB above. # # * This library was introduced in Boost 1.51.0 # * The signatures of make_fcontext() and jump_fcontext were changed in 1.56.0 # * A dependency on boost_thread appears in 1.57.0 BOOST_DEFUN([Context], [boost_context_save_LIBS=$LIBS boost_context_save_LDFLAGS=$LDFLAGS if test $boost_major_version -ge 157; then BOOST_THREAD([$1]) m4_pattern_allow([^BOOST_THREAD_(LIBS|LDFLAGS)$])dnl LIBS="$LIBS $BOOST_THREAD_LIBS" LDFLAGS="$LDFLAGS $BOOST_THREAD_LDFLAGS" fi BOOST_FIND_LIB([context], [$1], [boost/context/all.hpp],[[ // creates a stack void * stack_pointer = new void*[4096]; std::size_t const size = sizeof(void*[4096]); #if BOOST_VERSION <= 105100 ctx::make_fcontext(&fc, f); return ctx::jump_fcontext(&fcm, &fc, 3) == 6; #else fc = ctx::make_fcontext(stack_pointer, size, f); return ctx::jump_fcontext(&fcm, fc, 3) == 6; #endif ]],[dnl #include <boost/version.hpp> #if BOOST_VERSION <= 105100 namespace ctx = boost::ctx; static ctx::fcontext_t fcm, fc; static void f(intptr_t i) { ctx::jump_fcontext(&fc, &fcm, i * 2); } #elif BOOST_VERSION <= 105500 namespace ctx = boost::context; // context static ctx::fcontext_t fcm, *fc; // context-function static void f(intptr_t i) { ctx::jump_fcontext(fc, &fcm, i * 2); } #else namespace ctx = boost::context; // context static ctx::fcontext_t fcm, fc; // context-function static void f(intptr_t i) { ctx::jump_fcontext(&fc, fcm, i * 2); } #endif ]) LIBS=$boost_context_save_LIBS LDFLAGS=$boost_context_save_LDFLAGS ])# BOOST_CONTEXT # BOOST_CONVERSION() # ------------------ # Look for Boost.Conversion (cast / lexical_cast) BOOST_DEFUN([Conversion], [BOOST_FIND_HEADER([boost/cast.hpp]) BOOST_FIND_HEADER([boost/lexical_cast.hpp]) ])# BOOST_CONVERSION # BOOST_COROUTINE([PREFERRED-RT-OPT]) # ----------------------------------- # Look for Boost.Coroutine. For the documentation of PREFERRED-RT-OPT, see the # documentation of BOOST_FIND_LIB above. This library was introduced in Boost # 1.53.0 BOOST_DEFUN([Coroutine], [ boost_coroutine_save_LIBS=$LIBS boost_coroutine_save_LDFLAGS=$LDFLAGS # Link-time dependency from coroutine to context BOOST_CONTEXT([$1]) # Starting from Boost 1.55 a dependency on Boost.System is added if test $boost_major_version -ge 155; then BOOST_SYSTEM([$1]) fi m4_pattern_allow([^BOOST_(CONTEXT|SYSTEM)_(LIBS|LDFLAGS)]) LIBS="$LIBS $BOOST_CONTEXT_LIBS $BOOST_SYSTEM_LIBS" LDFLAGS="$LDFLAGS $BOOST_CONTEXT_LDFLAGS" # in 1.53 coroutine was a header only library if test $boost_major_version -eq 153; then BOOST_FIND_HEADER([boost/coroutine/coroutine.hpp]) else BOOST_FIND_LIB([coroutine], [$1], [boost/coroutine/coroutine.hpp], [ #include <boost/version.hpp> #if BOOST_VERSION <= 105500 boost::coroutines::coroutine<int(int)> coro; coro.get(); #else boost::coroutines::asymmetric_coroutine<int>::pull_type coro; coro.get(); #endif ]) fi # Link-time dependency from coroutine to context, existed only in 1.53, in 1.54 # coroutine doesn't use context from its headers but from its library. if test $boost_major_version -eq 153 || test $enable_static_boost = yes && test $boost_major_version -ge 154; then BOOST_COROUTINE_LIBS="$BOOST_COROUTINE_LIBS $BOOST_CONTEXT_LIBS" BOOST_COROUTINE_LDFLAGS="$BOOST_COROUTINE_LDFLAGS $BOOST_CONTEXT_LDFLAGS" fi if test $enable_static_boost = yes && test $boost_major_version -ge 155; then BOOST_COROUTINE_LIBS="$BOOST_COROUTINE_LIBS $BOOST_SYSTEM_LIBS" BOOST_COROUTINE_LDFLAGS="$BOOST_COROUTINE_LDFLAGS $BOOST_SYSTEM_LDFLAGS" fi LIBS=$boost_coroutine_save_LIBS LDFLAGS=$boost_coroutine_save_LDFLAGS ])# BOOST_COROUTINE # BOOST_CRC() # ----------- # Look for Boost.CRC BOOST_DEFUN([CRC], [BOOST_FIND_HEADER([boost/crc.hpp]) ])# BOOST_CRC # BOOST_DATE_TIME([PREFERRED-RT-OPT]) # ----------------------------------- # Look for Boost.Date_Time. For the documentation of PREFERRED-RT-OPT, see the # documentation of BOOST_FIND_LIB above. BOOST_DEFUN([Date_Time], [BOOST_FIND_LIB([date_time], [$1], [boost/date_time/posix_time/posix_time.hpp], [boost::posix_time::ptime t;]) ])# BOOST_DATE_TIME # BOOST_FILESYSTEM([PREFERRED-RT-OPT]) # ------------------------------------ # Look for Boost.Filesystem. For the documentation of PREFERRED-RT-OPT, see # the documentation of BOOST_FIND_LIB above. # Do not check for boost/filesystem.hpp because this file was introduced in # 1.34. BOOST_DEFUN([Filesystem], [# Do we have to check for Boost.System? This link-time dependency was # added as of 1.35.0. If we have a version <1.35, we must not attempt to # find Boost.System as it didn't exist by then. if test $boost_major_version -ge 135; then BOOST_SYSTEM([$1]) fi # end of the Boost.System check. boost_filesystem_save_LIBS=$LIBS boost_filesystem_save_LDFLAGS=$LDFLAGS m4_pattern_allow([^BOOST_SYSTEM_(LIBS|LDFLAGS)$])dnl LIBS="$LIBS $BOOST_SYSTEM_LIBS" LDFLAGS="$LDFLAGS $BOOST_SYSTEM_LDFLAGS" BOOST_FIND_LIB([filesystem], [$1], [boost/filesystem/path.hpp], [boost::filesystem::path p;]) if test $enable_static_boost = yes && test $boost_major_version -ge 135; then BOOST_FILESYSTEM_LIBS="$BOOST_FILESYSTEM_LIBS $BOOST_SYSTEM_LIBS" fi LIBS=$boost_filesystem_save_LIBS LDFLAGS=$boost_filesystem_save_LDFLAGS ])# BOOST_FILESYSTEM # BOOST_FLYWEIGHT() # ----------------- # Look for Boost.Flyweight. BOOST_DEFUN([Flyweight], [dnl There's a hidden dependency on pthreads. AC_REQUIRE([_BOOST_PTHREAD_FLAG])dnl BOOST_FIND_HEADER([boost/flyweight.hpp]) AC_SUBST([BOOST_FLYWEIGHT_LIBS], [$boost_cv_pthread_flag]) ]) # BOOST_FOREACH() # --------------- # Look for Boost.Foreach. BOOST_DEFUN([Foreach], [BOOST_FIND_HEADER([boost/foreach.hpp])]) # BOOST_FORMAT() # -------------- # Look for Boost.Format. # Note: we can't check for boost/format/format_fwd.hpp because the header isn't # standalone. It can't be compiled because it triggers the following error: # boost/format/detail/config_macros.hpp:88: error: 'locale' in namespace 'std' # does not name a type BOOST_DEFUN([Format], [BOOST_FIND_HEADER([boost/format.hpp])]) # BOOST_FUNCTION() # ---------------- # Look for Boost.Function BOOST_DEFUN([Function], [BOOST_FIND_HEADER([boost/function.hpp])]) # BOOST_GEOMETRY() # ---------------- # Look for Boost.Geometry (new since 1.47.0). BOOST_DEFUN([Geometry], [BOOST_FIND_HEADER([boost/geometry.hpp]) ])# BOOST_GEOMETRY # BOOST_GRAPH([PREFERRED-RT-OPT]) # ------------------------------- # Look for Boost.Graphs. For the documentation of PREFERRED-RT-OPT, see the # documentation of BOOST_FIND_LIB above. BOOST_DEFUN([Graph], [boost_graph_save_LIBS=$LIBS boost_graph_save_LDFLAGS=$LDFLAGS # Link-time dependency from graph to regex was added as of 1.40.0. if test $boost_major_version -ge 140; then BOOST_REGEX([$1]) m4_pattern_allow([^BOOST_REGEX_(LIBS|LDFLAGS)$])dnl LIBS="$LIBS $BOOST_REGEX_LIBS" LDFLAGS="$LDFLAGS $BOOST_REGEX_LDFLAGS" fi BOOST_FIND_LIB([graph], [$1], [boost/graph/adjacency_list.hpp], [boost::adjacency_list<> g;]) LIBS=$boost_graph_save_LIBS LDFLAGS=$boost_graph_save_LDFLAGS ])# BOOST_GRAPH # BOOST_IOSTREAMS([PREFERRED-RT-OPT]) # ----------------------------------- # Look for Boost.IOStreams. For the documentation of PREFERRED-RT-OPT, see the # documentation of BOOST_FIND_LIB above. BOOST_DEFUN([IOStreams], [BOOST_FIND_LIB([iostreams], [$1], [boost/iostreams/device/file_descriptor.hpp], [boost::iostreams::file_descriptor fd; fd.close();]) ])# BOOST_IOSTREAMS # BOOST_HASH() # ------------ # Look for Boost.Functional/Hash BOOST_DEFUN([Hash], [BOOST_FIND_HEADER([boost/functional/hash.hpp])]) # BOOST_LAMBDA() # -------------- # Look for Boost.Lambda BOOST_DEFUN([Lambda], [BOOST_FIND_HEADER([boost/lambda/lambda.hpp])]) # BOOST_LOCALE() # -------------- # Look for Boost.Locale BOOST_DEFUN([Locale], [ boost_locale_save_LIBS=$LIBS boost_locale_save_LDFLAGS=$LDFLAGS # require SYSTEM for boost-1.50.0 and up if test $boost_major_version -ge 150; then BOOST_SYSTEM([$1]) m4_pattern_allow([^BOOST_SYSTEM_(LIBS|LDFLAGS)$])dnl LIBS="$LIBS $BOOST_SYSTEM_LIBS" LDFLAGS="$LDFLAGS $BOOST_SYSTEM_LDFLAGS" fi # end of the Boost.System check. BOOST_FIND_LIB([locale], [$1], [boost/locale.hpp], [[boost::locale::generator gen; std::locale::global(gen(""));]]) LIBS=$boost_locale_save_LIBS LDFLAGS=$boost_locale_save_LDFLAGS ])# BOOST_LOCALE # BOOST_LOG([PREFERRED-RT-OPT]) # ----------------------------- # Look for Boost.Log. For the documentation of PREFERRED-RT-OPT, see the # documentation of BOOST_FIND_LIB above. BOOST_DEFUN([Log], [boost_log_save_LIBS=$LIBS boost_log_save_LDFLAGS=$LDFLAGS BOOST_SYSTEM([$1]) BOOST_FILESYSTEM([$1]) BOOST_DATE_TIME([$1]) m4_pattern_allow([^BOOST_(SYSTEM|FILESYSTEM|DATE_TIME)_(LIBS|LDFLAGS)$])dnl LIBS="$LIBS $BOOST_DATE_TIME_LIBS $BOOST_FILESYSTEM_LIBS $BOOST_SYSTEM_LIBS" LDFLAGS="$LDFLAGS $BOOST_DATE_TIME_LDFLAGS $BOOST_FILESYSTEM_LDFLAGS $BOOST_SYSTEM_LDFLAGS" BOOST_FIND_LIB([log], [$1], [boost/log/core/core.hpp], [boost::log::attribute a; a.get_value();]) LIBS=$boost_log_save_LIBS LDFLAGS=$boost_log_save_LDFLAGS ])# BOOST_LOG # BOOST_LOG_SETUP([PREFERRED-RT-OPT]) # ----------------------------------- # Look for Boost.Log. For the documentation of PREFERRED-RT-OPT, see the # documentation of BOOST_FIND_LIB above. BOOST_DEFUN([Log_Setup], [boost_log_setup_save_LIBS=$LIBS boost_log_setup_save_LDFLAGS=$LDFLAGS BOOST_LOG([$1]) m4_pattern_allow([^BOOST_LOG_(LIBS|LDFLAGS)$])dnl LIBS="$LIBS $BOOST_LOG_LIBS" LDFLAGS="$LDFLAGS $BOOST_LOG_LDFLAGS" BOOST_FIND_LIB([log_setup], [$1], [boost/log/utility/setup/from_settings.hpp], [boost::log::basic_settings<char> bs; bs.empty();]) LIBS=$boost_log_setup_save_LIBS LDFLAGS=$boost_log_setup_save_LDFLAGS ])# BOOST_LOG_SETUP # BOOST_MATH() # ------------ # Look for Boost.Math # TODO: This library isn't header-only but it comes in multiple different # flavors that don't play well with BOOST_FIND_LIB (e.g, libboost_math_c99, # libboost_math_c99f, libboost_math_c99l, libboost_math_tr1, # libboost_math_tr1f, libboost_math_tr1l). This macro must be fixed to do the # right thing anyway. BOOST_DEFUN([Math], [BOOST_FIND_HEADER([boost/math/special_functions.hpp])]) # BOOST_MPI([PREFERRED-RT-OPT]) # ------------------------------- # Look for Boost MPI. For the documentation of PREFERRED-RT-OPT, see the # documentation of BOOST_FIND_LIB above. Uses MPICXX variable if it is # set, otherwise tries CXX # BOOST_DEFUN([MPI], [boost_save_CXX=${CXX} boost_save_CXXCPP=${CXXCPP} if test x"${MPICXX}" != x; then CXX=${MPICXX} CXXCPP="${MPICXX} -E" fi BOOST_FIND_LIB([mpi], [$1], [boost/mpi.hpp], [int argc = 0; char **argv = 0; boost::mpi::environment env(argc,argv);]) CXX=${boost_save_CXX} CXXCPP=${boost_save_CXXCPP} ])# BOOST_MPI # BOOST_MULTIARRAY() # ------------------ # Look for Boost.MultiArray BOOST_DEFUN([MultiArray], [BOOST_FIND_HEADER([boost/multi_array.hpp])]) # BOOST_NUMERIC_UBLAS() # -------------------------- # Look for Boost.NumericUblas (Basic Linear Algebra) BOOST_DEFUN([Numeric_Ublas], [BOOST_FIND_HEADER([boost/numeric/ublas/vector.hpp]) ])# BOOST_NUMERIC_UBLAS # BOOST_NUMERIC_CONVERSION() # -------------------------- # Look for Boost.NumericConversion (policy-based numeric conversion) BOOST_DEFUN([Numeric_Conversion], [BOOST_FIND_HEADER([boost/numeric/conversion/converter.hpp]) ])# BOOST_NUMERIC_CONVERSION # BOOST_OPTIONAL() # ---------------- # Look for Boost.Optional BOOST_DEFUN([Optional], [BOOST_FIND_HEADER([boost/optional.hpp])]) # BOOST_PREPROCESSOR() # -------------------- # Look for Boost.Preprocessor BOOST_DEFUN([Preprocessor], [BOOST_FIND_HEADER([boost/preprocessor/repeat.hpp])]) # BOOST_RANGE() # -------------------- # Look for Boost.Range BOOST_DEFUN([Range], [BOOST_FIND_HEADER([boost/range/adaptors.hpp])]) # BOOST_UNORDERED() # ----------------- # Look for Boost.Unordered BOOST_DEFUN([Unordered], [BOOST_FIND_HEADER([boost/unordered_map.hpp])]) # BOOST_UUID() # ------------ # Look for Boost.Uuid BOOST_DEFUN([Uuid], [BOOST_FIND_HEADER([boost/uuid/uuid.hpp])]) # BOOST_PROGRAM_OPTIONS([PREFERRED-RT-OPT]) # ----------------------------------------- # Look for Boost.Program_options. For the documentation of PREFERRED-RT-OPT, # see the documentation of BOOST_FIND_LIB above. BOOST_DEFUN([Program_Options], [BOOST_FIND_LIB([program_options], [$1], [boost/program_options.hpp], [boost::program_options::options_description d("test");]) ])# BOOST_PROGRAM_OPTIONS # _BOOST_PYTHON_CONFIG(VARIABLE, FLAG) # ------------------------------------ # Save VARIABLE, and define it via `python-config --FLAG`. # Substitute BOOST_PYTHON_VARIABLE. m4_define([_BOOST_PYTHON_CONFIG], [AC_SUBST([BOOST_PYTHON_$1], [`python-config --$2 2>/dev/null`])dnl boost_python_save_$1=$$1 $1="$$1 $BOOST_PYTHON_$1"]) # BOOST_PYTHON([PREFERRED-RT-OPT]) # -------------------------------- # Look for Boost.Python. For the documentation of PREFERRED-RT-OPT, # see the documentation of BOOST_FIND_LIB above. BOOST_DEFUN([Python], [_BOOST_PYTHON_CONFIG([CPPFLAGS], [includes]) _BOOST_PYTHON_CONFIG([LDFLAGS], [ldflags]) _BOOST_PYTHON_CONFIG([LIBS], [libs]) m4_pattern_allow([^BOOST_PYTHON_MODULE$])dnl BOOST_FIND_LIBS([python], [python python3], [$1], [boost/python.hpp], [], [BOOST_PYTHON_MODULE(empty) {}]) CPPFLAGS=$boost_python_save_CPPFLAGS LDFLAGS=$boost_python_save_LDFLAGS LIBS=$boost_python_save_LIBS ])# BOOST_PYTHON # BOOST_REF() # ----------- # Look for Boost.Ref BOOST_DEFUN([Ref], [BOOST_FIND_HEADER([boost/ref.hpp])]) # BOOST_REGEX([PREFERRED-RT-OPT]) # ------------------------------- # Look for Boost.Regex. For the documentation of PREFERRED-RT-OPT, see the # documentation of BOOST_FIND_LIB above. BOOST_DEFUN([Regex], [BOOST_FIND_LIB([regex], [$1], [boost/regex.hpp], [boost::regex exp("*"); boost::regex_match("foo", exp);]) ])# BOOST_REGEX # BOOST_SERIALIZATION([PREFERRED-RT-OPT]) # --------------------------------------- # Look for Boost.Serialization. For the documentation of PREFERRED-RT-OPT, see # the documentation of BOOST_FIND_LIB above. BOOST_DEFUN([Serialization], [BOOST_FIND_LIB([serialization], [$1], [boost/archive/text_oarchive.hpp], [std::ostream* o = 0; // Cheap way to get an ostream... boost::archive::text_oarchive t(*o);]) ])# BOOST_SERIALIZATION # BOOST_SIGNALS([PREFERRED-RT-OPT]) # --------------------------------- # Look for Boost.Signals. For the documentation of PREFERRED-RT-OPT, see the # documentation of BOOST_FIND_LIB above. BOOST_DEFUN([Signals], [BOOST_FIND_LIB([signals], [$1], [boost/signal.hpp], [boost::signal<void ()> s;]) ])# BOOST_SIGNALS # BOOST_SIGNALS2() # ---------------- # Look for Boost.Signals2 (new since 1.39.0). BOOST_DEFUN([Signals2], [BOOST_FIND_HEADER([boost/signals2.hpp]) ])# BOOST_SIGNALS2 # BOOST_SMART_PTR() # ----------------- # Look for Boost.SmartPtr BOOST_DEFUN([Smart_Ptr], [BOOST_FIND_HEADER([boost/scoped_ptr.hpp]) BOOST_FIND_HEADER([boost/shared_ptr.hpp]) ]) # BOOST_STATICASSERT() # -------------------- # Look for Boost.StaticAssert BOOST_DEFUN([StaticAssert], [BOOST_FIND_HEADER([boost/static_assert.hpp])]) # BOOST_STRING_ALGO() # ------------------- # Look for Boost.StringAlgo BOOST_DEFUN([String_Algo], [BOOST_FIND_HEADER([boost/algorithm/string.hpp]) ]) # BOOST_SYSTEM([PREFERRED-RT-OPT]) # -------------------------------- # Look for Boost.System. For the documentation of PREFERRED-RT-OPT, see the # documentation of BOOST_FIND_LIB above. This library was introduced in Boost # 1.35.0. BOOST_DEFUN([System], [BOOST_FIND_LIB([system], [$1], [boost/system/error_code.hpp], [boost::system::error_code e; e.clear();]) ])# BOOST_SYSTEM # BOOST_TEST([PREFERRED-RT-OPT]) # ------------------------------ # Look for Boost.Test. For the documentation of PREFERRED-RT-OPT, see the # documentation of BOOST_FIND_LIB above. BOOST_DEFUN([Test], [m4_pattern_allow([^BOOST_CHECK$])dnl BOOST_FIND_LIB([unit_test_framework], [$1], [boost/test/unit_test.hpp], [BOOST_CHECK(2 == 2);], [using boost::unit_test::test_suite; test_suite* init_unit_test_suite(int argc, char ** argv) { return NULL; }]) ])# BOOST_TEST # BOOST_THREAD([PREFERRED-RT-OPT]) # --------------------------------- # Look for Boost.Thread. For the documentation of PREFERRED-RT-OPT, see the # documentation of BOOST_FIND_LIB above. BOOST_DEFUN([Thread], [dnl Having the pthread flag is required at least on GCC3 where dnl boost/thread.hpp would complain if we try to compile without dnl -pthread on GNU/Linux. AC_REQUIRE([_BOOST_PTHREAD_FLAG])dnl boost_thread_save_LIBS=$LIBS boost_thread_save_LDFLAGS=$LDFLAGS boost_thread_save_CPPFLAGS=$CPPFLAGS # Link-time dependency from thread to system was added as of 1.49.0. if test $boost_major_version -ge 149; then BOOST_SYSTEM([$1]) fi # end of the Boost.System check. m4_pattern_allow([^BOOST_SYSTEM_(LIBS|LDFLAGS)$])dnl LIBS="$LIBS $BOOST_SYSTEM_LIBS $boost_cv_pthread_flag" LDFLAGS="$LDFLAGS $BOOST_SYSTEM_LDFLAGS" CPPFLAGS="$CPPFLAGS $boost_cv_pthread_flag" # When compiling for the Windows platform, the threads library is named # differently. This suffix doesn't exist in new versions of Boost, or # possibly new versions of GCC on mingw I am assuming it's Boost's change for # now and I am setting version to 1.48, for lack of knowledge as to when this # change occurred. if test $boost_major_version -lt 148; then case $host_os in (*mingw*) boost_thread_lib_ext=_win32;; esac fi BOOST_FIND_LIBS([thread], [thread$boost_thread_lib_ext], [$1], [boost/thread.hpp], [boost::thread t; boost::mutex m;]) case $host_os in (*mingw*) boost_thread_w32_socket_link=-lws2_32;; esac BOOST_THREAD_LIBS="$BOOST_THREAD_LIBS $BOOST_SYSTEM_LIBS $boost_cv_pthread_flag $boost_thread_w32_socket_link" BOOST_THREAD_LDFLAGS="$BOOST_SYSTEM_LDFLAGS" BOOST_CPPFLAGS="$BOOST_CPPFLAGS $boost_cv_pthread_flag" LIBS=$boost_thread_save_LIBS LDFLAGS=$boost_thread_save_LDFLAGS CPPFLAGS=$boost_thread_save_CPPFLAGS ])# BOOST_THREAD AU_ALIAS([BOOST_THREADS], [BOOST_THREAD]) # BOOST_TOKENIZER() # ----------------- # Look for Boost.Tokenizer BOOST_DEFUN([Tokenizer], [BOOST_FIND_HEADER([boost/tokenizer.hpp])]) # BOOST_TRIBOOL() # --------------- # Look for Boost.Tribool BOOST_DEFUN([Tribool], [BOOST_FIND_HEADER([boost/logic/tribool_fwd.hpp]) BOOST_FIND_HEADER([boost/logic/tribool.hpp]) ]) # BOOST_TUPLE() # ------------- # Look for Boost.Tuple BOOST_DEFUN([Tuple], [BOOST_FIND_HEADER([boost/tuple/tuple.hpp])]) # BOOST_TYPETRAITS() # -------------------- # Look for Boost.TypeTraits BOOST_DEFUN([TypeTraits], [BOOST_FIND_HEADER([boost/type_traits.hpp])]) # BOOST_UTILITY() # --------------- # Look for Boost.Utility (noncopyable, result_of, base-from-member idiom, # etc.) BOOST_DEFUN([Utility], [BOOST_FIND_HEADER([boost/utility.hpp])]) # BOOST_VARIANT() # --------------- # Look for Boost.Variant. BOOST_DEFUN([Variant], [BOOST_FIND_HEADER([boost/variant/variant_fwd.hpp]) BOOST_FIND_HEADER([boost/variant.hpp])]) # BOOST_POINTER_CONTAINER() # ------------------------ # Look for Boost.PointerContainer BOOST_DEFUN([Pointer_Container], [BOOST_FIND_HEADER([boost/ptr_container/ptr_deque.hpp]) BOOST_FIND_HEADER([boost/ptr_container/ptr_list.hpp]) BOOST_FIND_HEADER([boost/ptr_container/ptr_vector.hpp]) BOOST_FIND_HEADER([boost/ptr_container/ptr_array.hpp]) BOOST_FIND_HEADER([boost/ptr_container/ptr_set.hpp]) BOOST_FIND_HEADER([boost/ptr_container/ptr_map.hpp]) ])# BOOST_POINTER_CONTAINER # BOOST_WAVE([PREFERRED-RT-OPT]) # ------------------------------ # NOTE: If you intend to use Wave/Spirit with thread support, make sure you # call BOOST_THREAD first. # Look for Boost.Wave. For the documentation of PREFERRED-RT-OPT, see the # documentation of BOOST_FIND_LIB above. BOOST_DEFUN([Wave], [AC_REQUIRE([BOOST_FILESYSTEM])dnl AC_REQUIRE([BOOST_DATE_TIME])dnl boost_wave_save_LIBS=$LIBS boost_wave_save_LDFLAGS=$LDFLAGS m4_pattern_allow([^BOOST_((FILE)?SYSTEM|DATE_TIME|THREAD)_(LIBS|LDFLAGS)$])dnl LIBS="$LIBS $BOOST_SYSTEM_LIBS $BOOST_FILESYSTEM_LIBS $BOOST_DATE_TIME_LIBS \ $BOOST_THREAD_LIBS" LDFLAGS="$LDFLAGS $BOOST_SYSTEM_LDFLAGS $BOOST_FILESYSTEM_LDFLAGS \ $BOOST_DATE_TIME_LDFLAGS $BOOST_THREAD_LDFLAGS" BOOST_FIND_LIB([wave], [$1], [boost/wave.hpp], [boost::wave::token_id id; get_token_name(id);]) LIBS=$boost_wave_save_LIBS LDFLAGS=$boost_wave_save_LDFLAGS ])# BOOST_WAVE # BOOST_XPRESSIVE() # ----------------- # Look for Boost.Xpressive (new since 1.36.0). BOOST_DEFUN([Xpressive], [BOOST_FIND_HEADER([boost/xpressive/xpressive.hpp])]) # ----------------- # # Internal helpers. # # ----------------- # # _BOOST_PTHREAD_FLAG() # --------------------- # Internal helper for BOOST_THREAD. Computes boost_cv_pthread_flag # which must be used in CPPFLAGS and LIBS. # # Yes, we *need* to put the -pthread thing in CPPFLAGS because with GCC3, # boost/thread.hpp will trigger a #error if -pthread isn't used: # boost/config/requires_threads.hpp:47:5: #error "Compiler threading support # is not turned on. Please set the correct command line options for # threading: -pthread (Linux), -pthreads (Solaris) or -mthreads (Mingw32)" # # Based on ACX_PTHREAD: http://autoconf-archive.cryp.to/acx_pthread.html AC_DEFUN([_BOOST_PTHREAD_FLAG], [AC_REQUIRE([AC_PROG_CXX])dnl AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_LANG_PUSH([C++])dnl AC_CACHE_CHECK([for the flags needed to use pthreads], [boost_cv_pthread_flag], [ boost_cv_pthread_flag= # The ordering *is* (sometimes) important. Some notes on the # individual items follow: # (none): in case threads are in libc; should be tried before -Kthread and # other compiler flags to prevent continual compiler warnings # -lpthreads: AIX (must check this before -lpthread) # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h) # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able) # -llthread: LinuxThreads port on FreeBSD (also preferred to -pthread) # -pthread: GNU Linux/GCC (kernel threads), BSD/GCC (userland threads) # -pthreads: Solaris/GCC # -mthreads: MinGW32/GCC, Lynx/GCC # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it # doesn't hurt to check since this sometimes defines pthreads too; # also defines -D_REENTRANT) # ... -mt is also the pthreads flag for HP/aCC # -lpthread: GNU Linux, etc. # --thread-safe: KAI C++ case $host_os in #( *solaris*) # On Solaris (at least, for some versions), libc contains stubbed # (non-functional) versions of the pthreads routines, so link-based # tests will erroneously succeed. (We need to link with -pthreads/-mt/ # -lpthread.) (The stubs are missing pthread_cleanup_push, or rather # a function called by this macro, so we could check for that, but # who knows whether they'll stub that too in a future libc.) So, # we'll just look for -pthreads and -lpthread first: boost_pthread_flags="-pthreads -lpthread -mt -pthread";; #( *) boost_pthread_flags="-lpthreads -Kthread -kthread -llthread -pthread \ -pthreads -mthreads -lpthread --thread-safe -mt";; esac # Generate the test file. AC_LANG_CONFTEST([AC_LANG_PROGRAM([#include <pthread.h>], [pthread_t th; pthread_join(th, 0); pthread_attr_init(0); pthread_cleanup_push(0, 0); pthread_create(0,0,0,0); pthread_cleanup_pop(0);])]) for boost_pthread_flag in '' $boost_pthread_flags; do boost_pthread_ok=false dnl Re-use the test file already generated. boost_pthreads__save_LIBS=$LIBS LIBS="$LIBS $boost_pthread_flag" AC_LINK_IFELSE([], [if grep ".*$boost_pthread_flag" conftest.err; then echo "This flag seems to have triggered warnings" >&AS_MESSAGE_LOG_FD else boost_pthread_ok=:; boost_cv_pthread_flag=$boost_pthread_flag fi]) LIBS=$boost_pthreads__save_LIBS $boost_pthread_ok && break done ]) AC_LANG_POP([C++])dnl ])# _BOOST_PTHREAD_FLAG # _BOOST_gcc_test(MAJOR, MINOR) # ----------------------------- # Internal helper for _BOOST_FIND_COMPILER_TAG. m4_define([_BOOST_gcc_test], ["defined __GNUC__ && __GNUC__ == $1 && __GNUC_MINOR__ == $2 && !defined __ICC @ gcc$1$2"])dnl # _BOOST_mingw_test(MAJOR, MINOR) # ----------------------------- # Internal helper for _BOOST_FIND_COMPILER_TAG. m4_define([_BOOST_mingw_test], ["defined __GNUC__ && __GNUC__ == $1 && __GNUC_MINOR__ == $2 && !defined __ICC && \ (defined WIN32 || defined WINNT || defined _WIN32 || defined __WIN32 \ || defined __WIN32__ || defined __WINNT || defined __WINNT__) @ mgw$1$2"])dnl # _BOOST_FIND_COMPILER_TAG() # -------------------------- # Internal. When Boost is installed without --layout=system, each library # filename will hold a suffix that encodes the compiler used during the # build. The Boost build system seems to call this a `tag'. AC_DEFUN([_BOOST_FIND_COMPILER_TAG], [AC_REQUIRE([AC_PROG_CXX])dnl AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_CACHE_CHECK([for the toolset name used by Boost for $CXX], [boost_cv_lib_tag], [boost_cv_lib_tag=unknown if test x$boost_cv_inc_path != xno; then AC_LANG_PUSH([C++])dnl # The following tests are mostly inspired by boost/config/auto_link.hpp # The list is sorted to most recent/common to oldest compiler (in order # to increase the likelihood of finding the right compiler with the # least number of compilation attempt). # Beware that some tests are sensible to the order (for instance, we must # look for MinGW before looking for GCC3). # I used one compilation test per compiler with a #error to recognize # each compiler so that it works even when cross-compiling (let me know # if you know a better approach). # Known missing tags (known from Boost's tools/build/v2/tools/common.jam): # como, edg, kcc, bck, mp, sw, tru, xlc # I'm not sure about my test for `il' (be careful: Intel's ICC pre-defines # the same defines as GCC's). for i in \ _BOOST_mingw_test(5, 3) \ _BOOST_gcc_test(5, 3) \ _BOOST_mingw_test(5, 2) \ _BOOST_gcc_test(5, 2) \ _BOOST_mingw_test(5, 1) \ _BOOST_gcc_test(5, 1) \ _BOOST_mingw_test(5, 0) \ _BOOST_gcc_test(5, 0) \ _BOOST_mingw_test(4, 10) \ _BOOST_gcc_test(4, 10) \ _BOOST_mingw_test(4, 9) \ _BOOST_gcc_test(4, 9) \ _BOOST_mingw_test(4, 8) \ _BOOST_gcc_test(4, 8) \ _BOOST_mingw_test(4, 7) \ _BOOST_gcc_test(4, 7) \ _BOOST_mingw_test(4, 6) \ _BOOST_gcc_test(4, 6) \ _BOOST_mingw_test(4, 5) \ _BOOST_gcc_test(4, 5) \ _BOOST_mingw_test(4, 4) \ _BOOST_gcc_test(4, 4) \ _BOOST_mingw_test(4, 3) \ _BOOST_gcc_test(4, 3) \ _BOOST_mingw_test(4, 2) \ _BOOST_gcc_test(4, 2) \ _BOOST_mingw_test(4, 1) \ _BOOST_gcc_test(4, 1) \ _BOOST_mingw_test(4, 0) \ _BOOST_gcc_test(4, 0) \ "defined __GNUC__ && __GNUC__ == 3 && !defined __ICC \ && (defined WIN32 || defined WINNT || defined _WIN32 || defined __WIN32 \ || defined __WIN32__ || defined __WINNT || defined __WINNT__) @ mgw" \ _BOOST_gcc_test(3, 4) \ _BOOST_gcc_test(3, 3) \ "defined _MSC_VER && _MSC_VER >= 1500 @ vc90" \ "defined _MSC_VER && _MSC_VER == 1400 @ vc80" \ _BOOST_gcc_test(3, 2) \ "defined _MSC_VER && _MSC_VER == 1310 @ vc71" \ _BOOST_gcc_test(3, 1) \ _BOOST_gcc_test(3, 0) \ "defined __BORLANDC__ @ bcb" \ "defined __ICC && (defined __unix || defined __unix__) @ il" \ "defined __ICL @ iw" \ "defined _MSC_VER && _MSC_VER == 1300 @ vc7" \ _BOOST_gcc_test(2, 95) \ "defined __MWERKS__ && __MWERKS__ <= 0x32FF @ cw9" \ "defined _MSC_VER && _MSC_VER < 1300 && !defined UNDER_CE @ vc6" \ "defined _MSC_VER && _MSC_VER < 1300 && defined UNDER_CE @ evc4" \ "defined __MWERKS__ && __MWERKS__ <= 0x31FF @ cw8" do boost_tag_test=`expr "X$i" : 'X\([[^@]]*\) @ '` boost_tag=`expr "X$i" : 'X[[^@]]* @ \(.*\)'` AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ #if $boost_tag_test /* OK */ #else # error $boost_tag_test #endif ]])], [boost_cv_lib_tag=$boost_tag; break], []) done AC_LANG_POP([C++])dnl case $boost_cv_lib_tag in #( # Some newer (>= 1.35?) versions of Boost seem to only use "gcc" as opposed # to "gcc41" for instance. *-gcc | *'-gcc ') :;; #( Don't re-add -gcc: it's already in there. gcc*) boost_tag_x= case $host_os in #( darwin*) if test $boost_major_version -ge 136; then # The `x' added in r46793 of Boost. boost_tag_x=x fi;; esac # We can specify multiple tags in this variable because it's used by # BOOST_FIND_LIB that does a `for tag in -$boost_cv_lib_tag' ... boost_cv_lib_tag="$boost_tag_x$boost_cv_lib_tag -${boost_tag_x}gcc" ;; #( unknown) AC_MSG_WARN([[could not figure out which toolset name to use for $CXX]]) boost_cv_lib_tag= ;; esac fi])dnl end of AC_CACHE_CHECK ])# _BOOST_FIND_COMPILER_TAG # _BOOST_GUESS_WHETHER_TO_USE_MT() # -------------------------------- # Compile a small test to try to guess whether we should favor MT (Multi # Thread) flavors of Boost. Sets boost_guess_use_mt accordingly. AC_DEFUN([_BOOST_GUESS_WHETHER_TO_USE_MT], [# Check whether we do better use `mt' even though we weren't ask to. AC_LANG_PUSH([C++])dnl AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ #if defined _REENTRANT || defined _MT || defined __MT__ /* use -mt */ #else # error MT not needed #endif ]])], [boost_guess_use_mt=:], [boost_guess_use_mt=false]) AC_LANG_POP([C++])dnl ]) # _BOOST_AC_LINK_IFELSE(PROGRAM, [ACTION-IF-TRUE], [ACTION-IF-FALSE]) # ------------------------------------------------------------------- # Fork of _AC_LINK_IFELSE that preserves conftest.o across calls. Fragile, # will break when Autoconf changes its internals. Requires that you manually # rm -f conftest.$ac_objext in between to really different tests, otherwise # you will try to link a conftest.o left behind by a previous test. # Used to aggressively optimize BOOST_FIND_LIB (see the big comment in this # macro). # # Don't use "break" in the actions, as it would short-circuit some code # this macro runs after the actions. m4_define([_BOOST_AC_LINK_IFELSE], [m4_ifvaln([$1], [AC_LANG_CONFTEST([$1])])dnl rm -f conftest$ac_exeext boost_save_ac_ext=$ac_ext boost_use_source=: # If we already have a .o, re-use it. We change $ac_ext so that $ac_link # tries to link the existing object file instead of compiling from source. test -f conftest.$ac_objext && ac_ext=$ac_objext && boost_use_source=false && _AS_ECHO_LOG([re-using the existing conftest.$ac_objext]) AS_IF([_AC_DO_STDERR($ac_link) && { test -z "$ac_[]_AC_LANG_ABBREV[]_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && { test "$cross_compiling" = yes || $as_executable_p conftest$ac_exeext dnl FIXME: use AS_TEST_X instead when 2.61 is widespread enough. }], [$2], [if $boost_use_source; then _AC_MSG_LOG_CONFTEST fi $3]) ac_objext=$boost_save_ac_objext ac_ext=$boost_save_ac_ext dnl Delete also the IPA/IPO (Inter Procedural Analysis/Optimization) dnl information created by the PGI compiler (conftest_ipa8_conftest.oo), dnl as it would interfere with the next link command. rm -f core conftest.err conftest_ipa8_conftest.oo \ conftest$ac_exeext m4_ifval([$1], [conftest.$ac_ext])[]dnl ])# _BOOST_AC_LINK_IFELSE # Local Variables: # mode: autoconf # End: ���������������������������������������������������������������������������libcmis-0.5.2/m4/ltversion.m4�����������������������������������������������������������������������0000644�0001750�0001750�00000001273�13341246640�012676� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������# ltversion.m4 -- version numbers -*- Autoconf -*- # # Copyright (C) 2004, 2011-2015 Free Software Foundation, Inc. # Written by Scott James Remnant, 2004 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. # @configure_input@ # serial 4179 ltversion.m4 # This file is part of GNU Libtool m4_define([LT_PACKAGE_VERSION], [2.4.6]) m4_define([LT_PACKAGE_REVISION], [2.4.6]) AC_DEFUN([LTVERSION_VERSION], [macro_version='2.4.6' macro_revision='2.4.6' _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) _LT_DECL(, macro_revision, 0) ]) �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/m4/libtool.m4�������������������������������������������������������������������������0000644�0001750�0001750�00001125306�13341246640�012322� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������# libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- # # Copyright (C) 1996-2001, 2003-2015 Free Software Foundation, Inc. # Written by Gordon Matzigkeit, 1996 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. m4_define([_LT_COPYING], [dnl # Copyright (C) 2014 Free Software Foundation, Inc. # This is free software; see the source for copying conditions. There is NO # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # GNU Libtool is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of of the License, or # (at your option) any later version. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program or library that is built # using GNU Libtool, you may include this file under the same # distribution terms that you use for the rest of that program. # # GNU Libtool is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. ]) # serial 58 LT_INIT # LT_PREREQ(VERSION) # ------------------ # Complain and exit if this libtool version is less that VERSION. m4_defun([LT_PREREQ], [m4_if(m4_version_compare(m4_defn([LT_PACKAGE_VERSION]), [$1]), -1, [m4_default([$3], [m4_fatal([Libtool version $1 or higher is required], 63)])], [$2])]) # _LT_CHECK_BUILDDIR # ------------------ # Complain if the absolute build directory name contains unusual characters m4_defun([_LT_CHECK_BUILDDIR], [case `pwd` in *\ * | *\ *) AC_MSG_WARN([Libtool does not cope well with whitespace in `pwd`]) ;; esac ]) # LT_INIT([OPTIONS]) # ------------------ AC_DEFUN([LT_INIT], [AC_PREREQ([2.62])dnl We use AC_PATH_PROGS_FEATURE_CHECK AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl AC_BEFORE([$0], [LT_LANG])dnl AC_BEFORE([$0], [LT_OUTPUT])dnl AC_BEFORE([$0], [LTDL_INIT])dnl m4_require([_LT_CHECK_BUILDDIR])dnl dnl Autoconf doesn't catch unexpanded LT_ macros by default: m4_pattern_forbid([^_?LT_[A-Z_]+$])dnl m4_pattern_allow([^(_LT_EOF|LT_DLGLOBAL|LT_DLLAZY_OR_NOW|LT_MULTI_MODULE)$])dnl dnl aclocal doesn't pull ltoptions.m4, ltsugar.m4, or ltversion.m4 dnl unless we require an AC_DEFUNed macro: AC_REQUIRE([LTOPTIONS_VERSION])dnl AC_REQUIRE([LTSUGAR_VERSION])dnl AC_REQUIRE([LTVERSION_VERSION])dnl AC_REQUIRE([LTOBSOLETE_VERSION])dnl m4_require([_LT_PROG_LTMAIN])dnl _LT_SHELL_INIT([SHELL=${CONFIG_SHELL-/bin/sh}]) dnl Parse OPTIONS _LT_SET_OPTIONS([$0], [$1]) # This can be used to rebuild libtool when needed LIBTOOL_DEPS=$ltmain # Always use our own libtool. LIBTOOL='$(SHELL) $(top_builddir)/libtool' AC_SUBST(LIBTOOL)dnl _LT_SETUP # Only expand once: m4_define([LT_INIT]) ])# LT_INIT # Old names: AU_ALIAS([AC_PROG_LIBTOOL], [LT_INIT]) AU_ALIAS([AM_PROG_LIBTOOL], [LT_INIT]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_PROG_LIBTOOL], []) dnl AC_DEFUN([AM_PROG_LIBTOOL], []) # _LT_PREPARE_CC_BASENAME # ----------------------- m4_defun([_LT_PREPARE_CC_BASENAME], [ # Calculate cc_basename. Skip known compiler wrappers and cross-prefix. func_cc_basename () { for cc_temp in @S|@*""; do case $cc_temp in compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; \-*) ;; *) break;; esac done func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` } ])# _LT_PREPARE_CC_BASENAME # _LT_CC_BASENAME(CC) # ------------------- # It would be clearer to call AC_REQUIREs from _LT_PREPARE_CC_BASENAME, # but that macro is also expanded into generated libtool script, which # arranges for $SED and $ECHO to be set by different means. m4_defun([_LT_CC_BASENAME], [m4_require([_LT_PREPARE_CC_BASENAME])dnl AC_REQUIRE([_LT_DECL_SED])dnl AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl func_cc_basename $1 cc_basename=$func_cc_basename_result ]) # _LT_FILEUTILS_DEFAULTS # ---------------------- # It is okay to use these file commands and assume they have been set # sensibly after 'm4_require([_LT_FILEUTILS_DEFAULTS])'. m4_defun([_LT_FILEUTILS_DEFAULTS], [: ${CP="cp -f"} : ${MV="mv -f"} : ${RM="rm -f"} ])# _LT_FILEUTILS_DEFAULTS # _LT_SETUP # --------- m4_defun([_LT_SETUP], [AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_CANONICAL_BUILD])dnl AC_REQUIRE([_LT_PREPARE_SED_QUOTE_VARS])dnl AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl _LT_DECL([], [PATH_SEPARATOR], [1], [The PATH separator for the build system])dnl dnl _LT_DECL([], [host_alias], [0], [The host system])dnl _LT_DECL([], [host], [0])dnl _LT_DECL([], [host_os], [0])dnl dnl _LT_DECL([], [build_alias], [0], [The build system])dnl _LT_DECL([], [build], [0])dnl _LT_DECL([], [build_os], [0])dnl dnl AC_REQUIRE([AC_PROG_CC])dnl AC_REQUIRE([LT_PATH_LD])dnl AC_REQUIRE([LT_PATH_NM])dnl dnl AC_REQUIRE([AC_PROG_LN_S])dnl test -z "$LN_S" && LN_S="ln -s" _LT_DECL([], [LN_S], [1], [Whether we need soft or hard links])dnl dnl AC_REQUIRE([LT_CMD_MAX_LEN])dnl _LT_DECL([objext], [ac_objext], [0], [Object file suffix (normally "o")])dnl _LT_DECL([], [exeext], [0], [Executable file suffix (normally "")])dnl dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_CHECK_SHELL_FEATURES])dnl m4_require([_LT_PATH_CONVERSION_FUNCTIONS])dnl m4_require([_LT_CMD_RELOAD])dnl m4_require([_LT_CHECK_MAGIC_METHOD])dnl m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl m4_require([_LT_CMD_OLD_ARCHIVE])dnl m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl m4_require([_LT_WITH_SYSROOT])dnl m4_require([_LT_CMD_TRUNCATE])dnl _LT_CONFIG_LIBTOOL_INIT([ # See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes INIT. if test -n "\${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi ]) if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi _LT_CHECK_OBJDIR m4_require([_LT_TAG_COMPILER])dnl case $host_os in aix3*) # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi ;; esac # Global variables: ofile=libtool can_build_shared=yes # All known linkers require a '.a' archive for static linking (except MSVC, # which needs '.lib'). libext=a with_gnu_ld=$lt_cv_prog_gnu_ld old_CC=$CC old_CFLAGS=$CFLAGS # Set sane defaults for various variables test -z "$CC" && CC=cc test -z "$LTCC" && LTCC=$CC test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS test -z "$LD" && LD=ld test -z "$ac_objext" && ac_objext=o _LT_CC_BASENAME([$compiler]) # Only perform the check for file, if the check method requires it test -z "$MAGIC_CMD" && MAGIC_CMD=file case $deplibs_check_method in file_magic*) if test "$file_magic_cmd" = '$MAGIC_CMD'; then _LT_PATH_MAGIC fi ;; esac # Use C for the default configuration in the libtool script LT_SUPPORTED_TAG([CC]) _LT_LANG_C_CONFIG _LT_LANG_DEFAULT_CONFIG _LT_CONFIG_COMMANDS ])# _LT_SETUP # _LT_PREPARE_SED_QUOTE_VARS # -------------------------- # Define a few sed substitution that help us do robust quoting. m4_defun([_LT_PREPARE_SED_QUOTE_VARS], [# Backslashify metacharacters that are still active within # double-quoted strings. sed_quote_subst='s/\([["`$\\]]\)/\\\1/g' # Same as above, but do not quote variable references. double_quote_subst='s/\([["`\\]]\)/\\\1/g' # Sed substitution to delay expansion of an escaped shell variable in a # double_quote_subst'ed string. delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' # Sed substitution to delay expansion of an escaped single quote. delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' # Sed substitution to avoid accidental globbing in evaled expressions no_glob_subst='s/\*/\\\*/g' ]) # _LT_PROG_LTMAIN # --------------- # Note that this code is called both from 'configure', and 'config.status' # now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, # 'config.status' has no value for ac_aux_dir unless we are using Automake, # so we pass a copy along to make sure it has a sensible value anyway. m4_defun([_LT_PROG_LTMAIN], [m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl _LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) ltmain=$ac_aux_dir/ltmain.sh ])# _LT_PROG_LTMAIN ## ------------------------------------- ## ## Accumulate code for creating libtool. ## ## ------------------------------------- ## # So that we can recreate a full libtool script including additional # tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS # in macros and then make a single call at the end using the 'libtool' # label. # _LT_CONFIG_LIBTOOL_INIT([INIT-COMMANDS]) # ---------------------------------------- # Register INIT-COMMANDS to be passed to AC_CONFIG_COMMANDS later. m4_define([_LT_CONFIG_LIBTOOL_INIT], [m4_ifval([$1], [m4_append([_LT_OUTPUT_LIBTOOL_INIT], [$1 ])])]) # Initialize. m4_define([_LT_OUTPUT_LIBTOOL_INIT]) # _LT_CONFIG_LIBTOOL([COMMANDS]) # ------------------------------ # Register COMMANDS to be passed to AC_CONFIG_COMMANDS later. m4_define([_LT_CONFIG_LIBTOOL], [m4_ifval([$1], [m4_append([_LT_OUTPUT_LIBTOOL_COMMANDS], [$1 ])])]) # Initialize. m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS]) # _LT_CONFIG_SAVE_COMMANDS([COMMANDS], [INIT_COMMANDS]) # ----------------------------------------------------- m4_defun([_LT_CONFIG_SAVE_COMMANDS], [_LT_CONFIG_LIBTOOL([$1]) _LT_CONFIG_LIBTOOL_INIT([$2]) ]) # _LT_FORMAT_COMMENT([COMMENT]) # ----------------------------- # Add leading comment marks to the start of each line, and a trailing # full-stop to the whole comment if one is not present already. m4_define([_LT_FORMAT_COMMENT], [m4_ifval([$1], [ m4_bpatsubst([m4_bpatsubst([$1], [^ *], [# ])], [['`$\]], [\\\&])]m4_bmatch([$1], [[!?.]$], [], [.]) )]) ## ------------------------ ## ## FIXME: Eliminate VARNAME ## ## ------------------------ ## # _LT_DECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION], [IS-TAGGED?]) # ------------------------------------------------------------------- # CONFIGNAME is the name given to the value in the libtool script. # VARNAME is the (base) name used in the configure script. # VALUE may be 0, 1 or 2 for a computed quote escaped value based on # VARNAME. Any other value will be used directly. m4_define([_LT_DECL], [lt_if_append_uniq([lt_decl_varnames], [$2], [, ], [lt_dict_add_subkey([lt_decl_dict], [$2], [libtool_name], [m4_ifval([$1], [$1], [$2])]) lt_dict_add_subkey([lt_decl_dict], [$2], [value], [$3]) m4_ifval([$4], [lt_dict_add_subkey([lt_decl_dict], [$2], [description], [$4])]) lt_dict_add_subkey([lt_decl_dict], [$2], [tagged?], [m4_ifval([$5], [yes], [no])])]) ]) # _LT_TAGDECL([CONFIGNAME], VARNAME, VALUE, [DESCRIPTION]) # -------------------------------------------------------- m4_define([_LT_TAGDECL], [_LT_DECL([$1], [$2], [$3], [$4], [yes])]) # lt_decl_tag_varnames([SEPARATOR], [VARNAME1...]) # ------------------------------------------------ m4_define([lt_decl_tag_varnames], [_lt_decl_filter([tagged?], [yes], $@)]) # _lt_decl_filter(SUBKEY, VALUE, [SEPARATOR], [VARNAME1..]) # --------------------------------------------------------- m4_define([_lt_decl_filter], [m4_case([$#], [0], [m4_fatal([$0: too few arguments: $#])], [1], [m4_fatal([$0: too few arguments: $#: $1])], [2], [lt_dict_filter([lt_decl_dict], [$1], [$2], [], lt_decl_varnames)], [3], [lt_dict_filter([lt_decl_dict], [$1], [$2], [$3], lt_decl_varnames)], [lt_dict_filter([lt_decl_dict], $@)])[]dnl ]) # lt_decl_quote_varnames([SEPARATOR], [VARNAME1...]) # -------------------------------------------------- m4_define([lt_decl_quote_varnames], [_lt_decl_filter([value], [1], $@)]) # lt_decl_dquote_varnames([SEPARATOR], [VARNAME1...]) # --------------------------------------------------- m4_define([lt_decl_dquote_varnames], [_lt_decl_filter([value], [2], $@)]) # lt_decl_varnames_tagged([SEPARATOR], [VARNAME1...]) # --------------------------------------------------- m4_define([lt_decl_varnames_tagged], [m4_assert([$# <= 2])dnl _$0(m4_quote(m4_default([$1], [[, ]])), m4_ifval([$2], [[$2]], [m4_dquote(lt_decl_tag_varnames)]), m4_split(m4_normalize(m4_quote(_LT_TAGS)), [ ]))]) m4_define([_lt_decl_varnames_tagged], [m4_ifval([$3], [lt_combine([$1], [$2], [_], $3)])]) # lt_decl_all_varnames([SEPARATOR], [VARNAME1...]) # ------------------------------------------------ m4_define([lt_decl_all_varnames], [_$0(m4_quote(m4_default([$1], [[, ]])), m4_if([$2], [], m4_quote(lt_decl_varnames), m4_quote(m4_shift($@))))[]dnl ]) m4_define([_lt_decl_all_varnames], [lt_join($@, lt_decl_varnames_tagged([$1], lt_decl_tag_varnames([[, ]], m4_shift($@))))dnl ]) # _LT_CONFIG_STATUS_DECLARE([VARNAME]) # ------------------------------------ # Quote a variable value, and forward it to 'config.status' so that its # declaration there will have the same value as in 'configure'. VARNAME # must have a single quote delimited value for this to work. m4_define([_LT_CONFIG_STATUS_DECLARE], [$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) # _LT_CONFIG_STATUS_DECLARATIONS # ------------------------------ # We delimit libtool config variables with single quotes, so when # we write them to config.status, we have to be sure to quote all # embedded single quotes properly. In configure, this macro expands # each variable declared with _LT_DECL (and _LT_TAGDECL) into: # # <var>='`$ECHO "$<var>" | $SED "$delay_single_quote_subst"`' m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], [m4_foreach([_lt_var], m4_quote(lt_decl_all_varnames), [m4_n([_LT_CONFIG_STATUS_DECLARE(_lt_var)])])]) # _LT_LIBTOOL_TAGS # ---------------- # Output comment and list of tags supported by the script m4_defun([_LT_LIBTOOL_TAGS], [_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl available_tags='_LT_TAGS'dnl ]) # _LT_LIBTOOL_DECLARE(VARNAME, [TAG]) # ----------------------------------- # Extract the dictionary values for VARNAME (optionally with TAG) and # expand to a commented shell variable setting: # # # Some comment about what VAR is for. # visible_name=$lt_internal_name m4_define([_LT_LIBTOOL_DECLARE], [_LT_FORMAT_COMMENT(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [description])))[]dnl m4_pushdef([_libtool_name], m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [libtool_name])))[]dnl m4_case(m4_quote(lt_dict_fetch([lt_decl_dict], [$1], [value])), [0], [_libtool_name=[$]$1], [1], [_libtool_name=$lt_[]$1], [2], [_libtool_name=$lt_[]$1], [_libtool_name=lt_dict_fetch([lt_decl_dict], [$1], [value])])[]dnl m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl ]) # _LT_LIBTOOL_CONFIG_VARS # ----------------------- # Produce commented declarations of non-tagged libtool config variables # suitable for insertion in the LIBTOOL CONFIG section of the 'libtool' # script. Tagged libtool config variables (even for the LIBTOOL CONFIG # section) are produced by _LT_LIBTOOL_TAG_VARS. m4_defun([_LT_LIBTOOL_CONFIG_VARS], [m4_foreach([_lt_var], m4_quote(_lt_decl_filter([tagged?], [no], [], lt_decl_varnames)), [m4_n([_LT_LIBTOOL_DECLARE(_lt_var)])])]) # _LT_LIBTOOL_TAG_VARS(TAG) # ------------------------- m4_define([_LT_LIBTOOL_TAG_VARS], [m4_foreach([_lt_var], m4_quote(lt_decl_tag_varnames), [m4_n([_LT_LIBTOOL_DECLARE(_lt_var, [$1])])])]) # _LT_TAGVAR(VARNAME, [TAGNAME]) # ------------------------------ m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) # _LT_CONFIG_COMMANDS # ------------------- # Send accumulated output to $CONFIG_STATUS. Thanks to the lists of # variables for single and double quote escaping we saved from calls # to _LT_DECL, we can put quote escaped variables declarations # into 'config.status', and then the shell code to quote escape them in # for loops in 'config.status'. Finally, any additional code accumulated # from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. m4_defun([_LT_CONFIG_COMMANDS], [AC_PROVIDE_IFELSE([LT_OUTPUT], dnl If the libtool generation code has been placed in $CONFIG_LT, dnl instead of duplicating it all over again into config.status, dnl then we will have config.status run $CONFIG_LT later, so it dnl needs to know what name is stored there: [AC_CONFIG_COMMANDS([libtool], [$SHELL $CONFIG_LT || AS_EXIT(1)], [CONFIG_LT='$CONFIG_LT'])], dnl If the libtool generation code is destined for config.status, dnl expand the accumulated commands and init code now: [AC_CONFIG_COMMANDS([libtool], [_LT_OUTPUT_LIBTOOL_COMMANDS], [_LT_OUTPUT_LIBTOOL_COMMANDS_INIT])]) ])#_LT_CONFIG_COMMANDS # Initialize. m4_define([_LT_OUTPUT_LIBTOOL_COMMANDS_INIT], [ # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH sed_quote_subst='$sed_quote_subst' double_quote_subst='$double_quote_subst' delay_variable_subst='$delay_variable_subst' _LT_CONFIG_STATUS_DECLARATIONS LTCC='$LTCC' LTCFLAGS='$LTCFLAGS' compiler='$compiler_DEFAULT' # A function that is used when there is no print builtin or printf. func_fallback_echo () { eval 'cat <<_LTECHO_EOF \$[]1 _LTECHO_EOF' } # Quote evaled strings. for var in lt_decl_all_varnames([[ \ ]], lt_decl_quote_varnames); do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[[\\\\\\\`\\"\\\$]]*) eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" ;; esac done # Double-quote double-evaled strings. for var in lt_decl_all_varnames([[ \ ]], lt_decl_dquote_varnames); do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[[\\\\\\\`\\"\\\$]]*) eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" ;; esac done _LT_OUTPUT_LIBTOOL_INIT ]) # _LT_GENERATED_FILE_INIT(FILE, [COMMENT]) # ------------------------------------ # Generate a child script FILE with all initialization necessary to # reuse the environment learned by the parent script, and make the # file executable. If COMMENT is supplied, it is inserted after the # '#!' sequence but before initialization text begins. After this # macro, additional text can be appended to FILE to form the body of # the child script. The macro ends with non-zero status if the # file could not be fully written (such as if the disk is full). m4_ifdef([AS_INIT_GENERATED], [m4_defun([_LT_GENERATED_FILE_INIT],[AS_INIT_GENERATED($@)])], [m4_defun([_LT_GENERATED_FILE_INIT], [m4_require([AS_PREPARE])]dnl [m4_pushdef([AS_MESSAGE_LOG_FD])]dnl [lt_write_fail=0 cat >$1 <<_ASEOF || lt_write_fail=1 #! $SHELL # Generated by $as_me. $2 SHELL=\${CONFIG_SHELL-$SHELL} export SHELL _ASEOF cat >>$1 <<\_ASEOF || lt_write_fail=1 AS_SHELL_SANITIZE _AS_PREPARE exec AS_MESSAGE_FD>&1 _ASEOF test 0 = "$lt_write_fail" && chmod +x $1[]dnl m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT # LT_OUTPUT # --------- # This macro allows early generation of the libtool script (before # AC_OUTPUT is called), incase it is used in configure for compilation # tests. AC_DEFUN([LT_OUTPUT], [: ${CONFIG_LT=./config.lt} AC_MSG_NOTICE([creating $CONFIG_LT]) _LT_GENERATED_FILE_INIT(["$CONFIG_LT"], [# Run this file to recreate a libtool stub with the current configuration.]) cat >>"$CONFIG_LT" <<\_LTEOF lt_cl_silent=false exec AS_MESSAGE_LOG_FD>>config.log { echo AS_BOX([Running $as_me.]) } >&AS_MESSAGE_LOG_FD lt_cl_help="\ '$as_me' creates a local libtool stub from the current configuration, for use in further configure time tests before the real libtool is generated. Usage: $[0] [[OPTIONS]] -h, --help print this help, then exit -V, --version print version number, then exit -q, --quiet do not print progress messages -d, --debug don't remove temporary files Report bugs to <bug-libtool@gnu.org>." lt_cl_version="\ m4_ifset([AC_PACKAGE_NAME], [AC_PACKAGE_NAME ])config.lt[]dnl m4_ifset([AC_PACKAGE_VERSION], [ AC_PACKAGE_VERSION]) configured by $[0], generated by m4_PACKAGE_STRING. Copyright (C) 2011 Free Software Foundation, Inc. This config.lt script is free software; the Free Software Foundation gives unlimited permision to copy, distribute and modify it." while test 0 != $[#] do case $[1] in --version | --v* | -V ) echo "$lt_cl_version"; exit 0 ;; --help | --h* | -h ) echo "$lt_cl_help"; exit 0 ;; --debug | --d* | -d ) debug=: ;; --quiet | --q* | --silent | --s* | -q ) lt_cl_silent=: ;; -*) AC_MSG_ERROR([unrecognized option: $[1] Try '$[0] --help' for more information.]) ;; *) AC_MSG_ERROR([unrecognized argument: $[1] Try '$[0] --help' for more information.]) ;; esac shift done if $lt_cl_silent; then exec AS_MESSAGE_FD>/dev/null fi _LTEOF cat >>"$CONFIG_LT" <<_LTEOF _LT_OUTPUT_LIBTOOL_COMMANDS_INIT _LTEOF cat >>"$CONFIG_LT" <<\_LTEOF AC_MSG_NOTICE([creating $ofile]) _LT_OUTPUT_LIBTOOL_COMMANDS AS_EXIT(0) _LTEOF chmod +x "$CONFIG_LT" # configure is writing to config.log, but config.lt does its own redirection, # appending to config.log, which fails on DOS, as config.log is still kept # open by configure. Here we exec the FD to /dev/null, effectively closing # config.log, so it can be properly (re)opened and appended to by config.lt. lt_cl_success=: test yes = "$silent" && lt_config_lt_args="$lt_config_lt_args --quiet" exec AS_MESSAGE_LOG_FD>/dev/null $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false exec AS_MESSAGE_LOG_FD>>config.log $lt_cl_success || AS_EXIT(1) ])# LT_OUTPUT # _LT_CONFIG(TAG) # --------------- # If TAG is the built-in tag, create an initial libtool script with a # default configuration from the untagged config vars. Otherwise add code # to config.status for appending the configuration named by TAG from the # matching tagged config vars. m4_defun([_LT_CONFIG], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl _LT_CONFIG_SAVE_COMMANDS([ m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl m4_if(_LT_TAG, [C], [ # See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes. if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi cfgfile=${ofile}T trap "$RM \"$cfgfile\"; exit 1" 1 2 15 $RM "$cfgfile" cat <<_LT_EOF >> "$cfgfile" #! $SHELL # Generated automatically by $as_me ($PACKAGE) $VERSION # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # NOTE: Changes made to this file will be lost: look at ltmain.sh. # Provide generalized library-building support services. # Written by Gordon Matzigkeit, 1996 _LT_COPYING _LT_LIBTOOL_TAGS # Configured defaults for sys_lib_dlsearch_path munging. : \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"} # ### BEGIN LIBTOOL CONFIG _LT_LIBTOOL_CONFIG_VARS _LT_LIBTOOL_TAG_VARS # ### END LIBTOOL CONFIG _LT_EOF cat <<'_LT_EOF' >> "$cfgfile" # ### BEGIN FUNCTIONS SHARED WITH CONFIGURE _LT_PREPARE_MUNGE_PATH_LIST _LT_PREPARE_CC_BASENAME # ### END FUNCTIONS SHARED WITH CONFIGURE _LT_EOF case $host_os in aix3*) cat <<\_LT_EOF >> "$cfgfile" # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi _LT_EOF ;; esac _LT_PROG_LTMAIN # We use sed instead of cat because bash on DJGPP gets confused if # if finds mixed CR/LF and LF-only lines. Since sed operates in # text mode, it properly converts lines to CR/LF. This bash problem # is reportedly fixed, but why not run on old versions too? sed '$q' "$ltmain" >> "$cfgfile" \ || (rm -f "$cfgfile"; exit 1) mv -f "$cfgfile" "$ofile" || (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") chmod +x "$ofile" ], [cat <<_LT_EOF >> "$ofile" dnl Unfortunately we have to use $1 here, since _LT_TAG is not expanded dnl in a comment (ie after a #). # ### BEGIN LIBTOOL TAG CONFIG: $1 _LT_LIBTOOL_TAG_VARS(_LT_TAG) # ### END LIBTOOL TAG CONFIG: $1 _LT_EOF ])dnl /m4_if ], [m4_if([$1], [], [ PACKAGE='$PACKAGE' VERSION='$VERSION' RM='$RM' ofile='$ofile'], []) ])dnl /_LT_CONFIG_SAVE_COMMANDS ])# _LT_CONFIG # LT_SUPPORTED_TAG(TAG) # --------------------- # Trace this macro to discover what tags are supported by the libtool # --tag option, using: # autoconf --trace 'LT_SUPPORTED_TAG:$1' AC_DEFUN([LT_SUPPORTED_TAG], []) # C support is built-in for now m4_define([_LT_LANG_C_enabled], []) m4_define([_LT_TAGS], []) # LT_LANG(LANG) # ------------- # Enable libtool support for the given language if not already enabled. AC_DEFUN([LT_LANG], [AC_BEFORE([$0], [LT_OUTPUT])dnl m4_case([$1], [C], [_LT_LANG(C)], [C++], [_LT_LANG(CXX)], [Go], [_LT_LANG(GO)], [Java], [_LT_LANG(GCJ)], [Fortran 77], [_LT_LANG(F77)], [Fortran], [_LT_LANG(FC)], [Windows Resource], [_LT_LANG(RC)], [m4_ifdef([_LT_LANG_]$1[_CONFIG], [_LT_LANG($1)], [m4_fatal([$0: unsupported language: "$1"])])])dnl ])# LT_LANG # _LT_LANG(LANGNAME) # ------------------ m4_defun([_LT_LANG], [m4_ifdef([_LT_LANG_]$1[_enabled], [], [LT_SUPPORTED_TAG([$1])dnl m4_append([_LT_TAGS], [$1 ])dnl m4_define([_LT_LANG_]$1[_enabled], [])dnl _LT_LANG_$1_CONFIG($1)])dnl ])# _LT_LANG m4_ifndef([AC_PROG_GO], [ ############################################################ # NOTE: This macro has been submitted for inclusion into # # GNU Autoconf as AC_PROG_GO. When it is available in # # a released version of Autoconf we should remove this # # macro and use it instead. # ############################################################ m4_defun([AC_PROG_GO], [AC_LANG_PUSH(Go)dnl AC_ARG_VAR([GOC], [Go compiler command])dnl AC_ARG_VAR([GOFLAGS], [Go compiler flags])dnl _AC_ARG_VAR_LDFLAGS()dnl AC_CHECK_TOOL(GOC, gccgo) if test -z "$GOC"; then if test -n "$ac_tool_prefix"; then AC_CHECK_PROG(GOC, [${ac_tool_prefix}gccgo], [${ac_tool_prefix}gccgo]) fi fi if test -z "$GOC"; then AC_CHECK_PROG(GOC, gccgo, gccgo, false) fi ])#m4_defun ])#m4_ifndef # _LT_LANG_DEFAULT_CONFIG # ----------------------- m4_defun([_LT_LANG_DEFAULT_CONFIG], [AC_PROVIDE_IFELSE([AC_PROG_CXX], [LT_LANG(CXX)], [m4_define([AC_PROG_CXX], defn([AC_PROG_CXX])[LT_LANG(CXX)])]) AC_PROVIDE_IFELSE([AC_PROG_F77], [LT_LANG(F77)], [m4_define([AC_PROG_F77], defn([AC_PROG_F77])[LT_LANG(F77)])]) AC_PROVIDE_IFELSE([AC_PROG_FC], [LT_LANG(FC)], [m4_define([AC_PROG_FC], defn([AC_PROG_FC])[LT_LANG(FC)])]) dnl The call to [A][M_PROG_GCJ] is quoted like that to stop aclocal dnl pulling things in needlessly. AC_PROVIDE_IFELSE([AC_PROG_GCJ], [LT_LANG(GCJ)], [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], [LT_LANG(GCJ)], [AC_PROVIDE_IFELSE([LT_PROG_GCJ], [LT_LANG(GCJ)], [m4_ifdef([AC_PROG_GCJ], [m4_define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[LT_LANG(GCJ)])]) m4_ifdef([A][M_PROG_GCJ], [m4_define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[LT_LANG(GCJ)])]) m4_ifdef([LT_PROG_GCJ], [m4_define([LT_PROG_GCJ], defn([LT_PROG_GCJ])[LT_LANG(GCJ)])])])])]) AC_PROVIDE_IFELSE([AC_PROG_GO], [LT_LANG(GO)], [m4_define([AC_PROG_GO], defn([AC_PROG_GO])[LT_LANG(GO)])]) AC_PROVIDE_IFELSE([LT_PROG_RC], [LT_LANG(RC)], [m4_define([LT_PROG_RC], defn([LT_PROG_RC])[LT_LANG(RC)])]) ])# _LT_LANG_DEFAULT_CONFIG # Obsolete macros: AU_DEFUN([AC_LIBTOOL_CXX], [LT_LANG(C++)]) AU_DEFUN([AC_LIBTOOL_F77], [LT_LANG(Fortran 77)]) AU_DEFUN([AC_LIBTOOL_FC], [LT_LANG(Fortran)]) AU_DEFUN([AC_LIBTOOL_GCJ], [LT_LANG(Java)]) AU_DEFUN([AC_LIBTOOL_RC], [LT_LANG(Windows Resource)]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_CXX], []) dnl AC_DEFUN([AC_LIBTOOL_F77], []) dnl AC_DEFUN([AC_LIBTOOL_FC], []) dnl AC_DEFUN([AC_LIBTOOL_GCJ], []) dnl AC_DEFUN([AC_LIBTOOL_RC], []) # _LT_TAG_COMPILER # ---------------- m4_defun([_LT_TAG_COMPILER], [AC_REQUIRE([AC_PROG_CC])dnl _LT_DECL([LTCC], [CC], [1], [A C compiler])dnl _LT_DECL([LTCFLAGS], [CFLAGS], [1], [LTCC compiler flags])dnl _LT_TAGDECL([CC], [compiler], [1], [A language specific compiler])dnl _LT_TAGDECL([with_gcc], [GCC], [0], [Is the compiler the GNU compiler?])dnl # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC ])# _LT_TAG_COMPILER # _LT_COMPILER_BOILERPLATE # ------------------------ # Check for compiler boilerplate output or warnings with # the simple compiler test code. m4_defun([_LT_COMPILER_BOILERPLATE], [m4_require([_LT_DECL_SED])dnl ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $RM conftest* ])# _LT_COMPILER_BOILERPLATE # _LT_LINKER_BOILERPLATE # ---------------------- # Check for linker boilerplate output or warnings with # the simple link test code. m4_defun([_LT_LINKER_BOILERPLATE], [m4_require([_LT_DECL_SED])dnl ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $RM -r conftest* ])# _LT_LINKER_BOILERPLATE # _LT_REQUIRED_DARWIN_CHECKS # ------------------------- m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ case $host_os in rhapsody* | darwin*) AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) AC_CHECK_TOOL([LIPO], [lipo], [:]) AC_CHECK_TOOL([OTOOL], [otool], [:]) AC_CHECK_TOOL([OTOOL64], [otool64], [:]) _LT_DECL([], [DSYMUTIL], [1], [Tool to manipulate archived DWARF debug symbol files on Mac OS X]) _LT_DECL([], [NMEDIT], [1], [Tool to change global to local symbols on Mac OS X]) _LT_DECL([], [LIPO], [1], [Tool to manipulate fat objects and archives on Mac OS X]) _LT_DECL([], [OTOOL], [1], [ldd/readelf like tool for Mach-O binaries on Mac OS X]) _LT_DECL([], [OTOOL64], [1], [ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4]) AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], [lt_cv_apple_cc_single_mod=no if test -z "$LT_MULTI_MODULE"; then # By default we will add the -single_module flag. You can override # by either setting the environment variable LT_MULTI_MODULE # non-empty at configure time, or by adding -multi_module to the # link flags. rm -rf libconftest.dylib* echo "int foo(void){return 1;}" > conftest.c echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib -Wl,-single_module conftest.c 2>conftest.err _lt_result=$? # If there is a non-empty error log, and "single_module" # appears in it, assume the flag caused a linker warning if test -s conftest.err && $GREP single_module conftest.err; then cat conftest.err >&AS_MESSAGE_LOG_FD # Otherwise, if the output was created with a 0 exit code from # the compiler, it worked. elif test -f libconftest.dylib && test 0 = "$_lt_result"; then lt_cv_apple_cc_single_mod=yes else cat conftest.err >&AS_MESSAGE_LOG_FD fi rm -rf libconftest.dylib* rm -f conftest.* fi]) AC_CACHE_CHECK([for -exported_symbols_list linker flag], [lt_cv_ld_exported_symbols_list], [lt_cv_ld_exported_symbols_list=no save_LDFLAGS=$LDFLAGS echo "_main" > conftest.sym LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], [lt_cv_ld_exported_symbols_list=yes], [lt_cv_ld_exported_symbols_list=no]) LDFLAGS=$save_LDFLAGS ]) AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], [lt_cv_ld_force_load=no cat > conftest.c << _LT_EOF int forced_loaded() { return 2;} _LT_EOF echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD cat > conftest.c << _LT_EOF int main() { return 0;} _LT_EOF echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&AS_MESSAGE_LOG_FD $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err _lt_result=$? if test -s conftest.err && $GREP force_load conftest.err; then cat conftest.err >&AS_MESSAGE_LOG_FD elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then lt_cv_ld_force_load=yes else cat conftest.err >&AS_MESSAGE_LOG_FD fi rm -f conftest.err libconftest.a conftest conftest.c rm -rf conftest.dSYM ]) case $host_os in rhapsody* | darwin1.[[012]]) _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; darwin1.*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; darwin*) # darwin 5.x on # if running on 10.5 or later, the deployment target defaults # to the OS version, if on x86, and 10.4, the deployment # target defaults to 10.4. Don't you love it? case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; 10.[[012]][[,.]]*) _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; 10.*) _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; esac ;; esac if test yes = "$lt_cv_apple_cc_single_mod"; then _lt_dar_single_mod='$single_module' fi if test yes = "$lt_cv_ld_exported_symbols_list"; then _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' else _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib' fi if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then _lt_dsymutil='~$DSYMUTIL $lib || :' else _lt_dsymutil= fi ;; esac ]) # _LT_DARWIN_LINKER_FEATURES([TAG]) # --------------------------------- # Checks for linker and compiler features on darwin m4_defun([_LT_DARWIN_LINKER_FEATURES], [ m4_require([_LT_REQUIRED_DARWIN_CHECKS]) _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_automatic, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported if test yes = "$lt_cv_ld_force_load"; then _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes], [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes]) else _LT_TAGVAR(whole_archive_flag_spec, $1)='' fi _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)=$_lt_dar_allow_undefined case $cc_basename in ifort*|nagfor*) _lt_dar_can_shared=yes ;; *) _lt_dar_can_shared=$GCC ;; esac if test yes = "$_lt_dar_can_shared"; then output_verbose_link_cmd=func_echo_all _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" m4_if([$1], [CXX], [ if test yes != "$lt_cv_apple_cc_single_mod"; then _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil" _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil" fi ],[]) else _LT_TAGVAR(ld_shlibs, $1)=no fi ]) # _LT_SYS_MODULE_PATH_AIX([TAGNAME]) # ---------------------------------- # Links a minimal program and checks the executable # for the system default hardcoded library path. In most cases, # this is /usr/lib:/lib, but when the MPI compilers are used # the location of the communication and MPI libs are included too. # If we don't find anything, use the default library path according # to the aix ld manual. # Store the results from the different compilers for each TAGNAME. # Allow to override them for all tags through lt_cv_aix_libpath. m4_defun([_LT_SYS_MODULE_PATH_AIX], [m4_require([_LT_DECL_SED])dnl if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], [AC_LINK_IFELSE([AC_LANG_PROGRAM],[ lt_aix_libpath_sed='[ /Import File Strings/,/^$/ { /^0/ { s/^0 *\([^ ]*\) *$/\1/ p } }]' _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi],[]) if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=/usr/lib:/lib fi ]) aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) fi ])# _LT_SYS_MODULE_PATH_AIX # _LT_SHELL_INIT(ARG) # ------------------- m4_define([_LT_SHELL_INIT], [m4_divert_text([M4SH-INIT], [$1 ])])# _LT_SHELL_INIT # _LT_PROG_ECHO_BACKSLASH # ----------------------- # Find how we can fake an echo command that does not interpret backslash. # In particular, with Autoconf 2.60 or later we add some code to the start # of the generated configure script that will find a shell with a builtin # printf (that we can use as an echo command). m4_defun([_LT_PROG_ECHO_BACKSLASH], [ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO AC_MSG_CHECKING([how to print strings]) # Test print first, because it will be a builtin if present. if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \ test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then ECHO='print -r --' elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then ECHO='printf %s\n' else # Use this function as a fallback that always works. func_fallback_echo () { eval 'cat <<_LTECHO_EOF $[]1 _LTECHO_EOF' } ECHO='func_fallback_echo' fi # func_echo_all arg... # Invoke $ECHO with all args, space-separated. func_echo_all () { $ECHO "$*" } case $ECHO in printf*) AC_MSG_RESULT([printf]) ;; print*) AC_MSG_RESULT([print -r]) ;; *) AC_MSG_RESULT([cat]) ;; esac m4_ifdef([_AS_DETECT_SUGGESTED], [_AS_DETECT_SUGGESTED([ test -n "${ZSH_VERSION+set}${BASH_VERSION+set}" || ( ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO PATH=/empty FPATH=/empty; export PATH FPATH test "X`printf %s $ECHO`" = "X$ECHO" \ || test "X`print -r -- $ECHO`" = "X$ECHO" )])]) _LT_DECL([], [SHELL], [1], [Shell to use when invoking shell scripts]) _LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) ])# _LT_PROG_ECHO_BACKSLASH # _LT_WITH_SYSROOT # ---------------- AC_DEFUN([_LT_WITH_SYSROOT], [AC_MSG_CHECKING([for sysroot]) AC_ARG_WITH([sysroot], [AS_HELP_STRING([--with-sysroot@<:@=DIR@:>@], [Search for dependent libraries within DIR (or the compiler's sysroot if not specified).])], [], [with_sysroot=no]) dnl lt_sysroot will always be passed unquoted. We quote it here dnl in case the user passed a directory name. lt_sysroot= case $with_sysroot in #( yes) if test yes = "$GCC"; then lt_sysroot=`$CC --print-sysroot 2>/dev/null` fi ;; #( /*) lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"` ;; #( no|'') ;; #( *) AC_MSG_RESULT([$with_sysroot]) AC_MSG_ERROR([The sysroot must be an absolute path.]) ;; esac AC_MSG_RESULT([${lt_sysroot:-no}]) _LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl [dependent libraries, and where our libraries should be installed.])]) # _LT_ENABLE_LOCK # --------------- m4_defun([_LT_ENABLE_LOCK], [AC_ARG_ENABLE([libtool-lock], [AS_HELP_STRING([--disable-libtool-lock], [avoid locking (might break parallel builds)])]) test no = "$enable_libtool_lock" || enable_libtool_lock=yes # Some flags need to be propagated to the compiler or linker for good # libtool support. case $host in ia64-*-hpux*) # Find out what ABI is being produced by ac_compile, and set mode # options accordingly. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `/usr/bin/file conftest.$ac_objext` in *ELF-32*) HPUX_IA64_MODE=32 ;; *ELF-64*) HPUX_IA64_MODE=64 ;; esac fi rm -rf conftest* ;; *-*-irix6*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then if test yes = "$lt_cv_prog_gnu_ld"; then case `/usr/bin/file conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -melf32bsmip" ;; *N32*) LD="${LD-ld} -melf32bmipn32" ;; *64-bit*) LD="${LD-ld} -melf64bmip" ;; esac else case `/usr/bin/file conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -32" ;; *N32*) LD="${LD-ld} -n32" ;; *64-bit*) LD="${LD-ld} -64" ;; esac fi fi rm -rf conftest* ;; mips64*-*linux*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then emul=elf case `/usr/bin/file conftest.$ac_objext` in *32-bit*) emul="${emul}32" ;; *64-bit*) emul="${emul}64" ;; esac case `/usr/bin/file conftest.$ac_objext` in *MSB*) emul="${emul}btsmip" ;; *LSB*) emul="${emul}ltsmip" ;; esac case `/usr/bin/file conftest.$ac_objext` in *N32*) emul="${emul}n32" ;; esac LD="${LD-ld} -m $emul" fi rm -rf conftest* ;; x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. Note that the listed cases only cover the # situations where additional linker options are needed (such as when # doing 32-bit compilation for a host where ld defaults to 64-bit, or # vice versa); the common cases where no linker options are needed do # not appear in the list. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `/usr/bin/file conftest.o` in *32-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_i386_fbsd" ;; x86_64-*linux*) case `/usr/bin/file conftest.o` in *x86-64*) LD="${LD-ld} -m elf32_x86_64" ;; *) LD="${LD-ld} -m elf_i386" ;; esac ;; powerpc64le-*linux*) LD="${LD-ld} -m elf32lppclinux" ;; powerpc64-*linux*) LD="${LD-ld} -m elf32ppclinux" ;; s390x-*linux*) LD="${LD-ld} -m elf_s390" ;; sparc64-*linux*) LD="${LD-ld} -m elf32_sparc" ;; esac ;; *64-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_x86_64_fbsd" ;; x86_64-*linux*) LD="${LD-ld} -m elf_x86_64" ;; powerpcle-*linux*) LD="${LD-ld} -m elf64lppc" ;; powerpc-*linux*) LD="${LD-ld} -m elf64ppc" ;; s390*-*linux*|s390*-*tpf*) LD="${LD-ld} -m elf64_s390" ;; sparc*-*linux*) LD="${LD-ld} -m elf64_sparc" ;; esac ;; esac fi rm -rf conftest* ;; *-*-sco3.2v5*) # On SCO OpenServer 5, we need -belf to get full-featured binaries. SAVE_CFLAGS=$CFLAGS CFLAGS="$CFLAGS -belf" AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, [AC_LANG_PUSH(C) AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) AC_LANG_POP]) if test yes != "$lt_cv_cc_needs_belf"; then # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf CFLAGS=$SAVE_CFLAGS fi ;; *-*solaris*) # Find out what ABI is being produced by ac_compile, and set linker # options accordingly. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `/usr/bin/file conftest.o` in *64-bit*) case $lt_cv_prog_gnu_ld in yes*) case $host in i?86-*-solaris*|x86_64-*-solaris*) LD="${LD-ld} -m elf_x86_64" ;; sparc*-*-solaris*) LD="${LD-ld} -m elf64_sparc" ;; esac # GNU ld 2.21 introduced _sol2 emulations. Use them if available. if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then LD=${LD-ld}_sol2 fi ;; *) if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then LD="${LD-ld} -64" fi ;; esac ;; esac fi rm -rf conftest* ;; esac need_locks=$enable_libtool_lock ])# _LT_ENABLE_LOCK # _LT_PROG_AR # ----------- m4_defun([_LT_PROG_AR], [AC_CHECK_TOOLS(AR, [ar], false) : ${AR=ar} : ${AR_FLAGS=cru} _LT_DECL([], [AR], [1], [The archiver]) _LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive]) AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], [lt_cv_ar_at_file=no AC_COMPILE_IFELSE([AC_LANG_PROGRAM], [echo conftest.$ac_objext > conftest.lst lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' AC_TRY_EVAL([lt_ar_try]) if test 0 -eq "$ac_status"; then # Ensure the archiver fails upon bogus file names. rm -f conftest.$ac_objext libconftest.a AC_TRY_EVAL([lt_ar_try]) if test 0 -ne "$ac_status"; then lt_cv_ar_at_file=@ fi fi rm -f conftest.* libconftest.a ]) ]) if test no = "$lt_cv_ar_at_file"; then archiver_list_spec= else archiver_list_spec=$lt_cv_ar_at_file fi _LT_DECL([], [archiver_list_spec], [1], [How to feed a file listing to the archiver]) ])# _LT_PROG_AR # _LT_CMD_OLD_ARCHIVE # ------------------- m4_defun([_LT_CMD_OLD_ARCHIVE], [_LT_PROG_AR AC_CHECK_TOOL(STRIP, strip, :) test -z "$STRIP" && STRIP=: _LT_DECL([], [STRIP], [1], [A symbol stripping program]) AC_CHECK_TOOL(RANLIB, ranlib, :) test -z "$RANLIB" && RANLIB=: _LT_DECL([], [RANLIB], [1], [Commands used to install an old-style archive]) # Determine commands to create old-style static archives. old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' old_postinstall_cmds='chmod 644 $oldlib' old_postuninstall_cmds= if test -n "$RANLIB"; then case $host_os in bitrig* | openbsd*) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" ;; *) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib" ;; esac old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib" fi case $host_os in darwin*) lock_old_archive_extraction=yes ;; *) lock_old_archive_extraction=no ;; esac _LT_DECL([], [old_postinstall_cmds], [2]) _LT_DECL([], [old_postuninstall_cmds], [2]) _LT_TAGDECL([], [old_archive_cmds], [2], [Commands used to build an old-style archive]) _LT_DECL([], [lock_old_archive_extraction], [0], [Whether to use a lock for old archive extraction]) ])# _LT_CMD_OLD_ARCHIVE # _LT_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) # ---------------------------------------------------------------- # Check whether the given compiler option works AC_DEFUN([_LT_COMPILER_OPTION], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_SED])dnl AC_CACHE_CHECK([$1], [$2], [$2=no m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$3" ## exclude from sc_useless_quotes_in_assignment # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&AS_MESSAGE_LOG_FD echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then $2=yes fi fi $RM conftest* ]) if test yes = "[$]$2"; then m4_if([$5], , :, [$5]) else m4_if([$6], , :, [$6]) fi ])# _LT_COMPILER_OPTION # Old name: AU_ALIAS([AC_LIBTOOL_COMPILER_OPTION], [_LT_COMPILER_OPTION]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], []) # _LT_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, # [ACTION-SUCCESS], [ACTION-FAILURE]) # ---------------------------------------------------- # Check whether the given linker option works AC_DEFUN([_LT_LINKER_OPTION], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_SED])dnl AC_CACHE_CHECK([$1], [$2], [$2=no save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS $3" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&AS_MESSAGE_LOG_FD $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then $2=yes fi else $2=yes fi fi $RM -r conftest* LDFLAGS=$save_LDFLAGS ]) if test yes = "[$]$2"; then m4_if([$4], , :, [$4]) else m4_if([$5], , :, [$5]) fi ])# _LT_LINKER_OPTION # Old name: AU_ALIAS([AC_LIBTOOL_LINKER_OPTION], [_LT_LINKER_OPTION]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], []) # LT_CMD_MAX_LEN #--------------- AC_DEFUN([LT_CMD_MAX_LEN], [AC_REQUIRE([AC_CANONICAL_HOST])dnl # find the maximum length of command line arguments AC_MSG_CHECKING([the maximum length of command line arguments]) AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl i=0 teststring=ABCD case $build_os in msdosdjgpp*) # On DJGPP, this test can blow up pretty badly due to problems in libc # (any single argument exceeding 2000 bytes causes a buffer overrun # during glob expansion). Even if it were fixed, the result of this # check would be larger than it should be. lt_cv_sys_max_cmd_len=12288; # 12K is about right ;; gnu*) # Under GNU Hurd, this test is not required because there is # no limit to the length of command line arguments. # Libtool will interpret -1 as no limit whatsoever lt_cv_sys_max_cmd_len=-1; ;; cygwin* | mingw* | cegcc*) # On Win9x/ME, this test blows up -- it succeeds, but takes # about 5 minutes as the teststring grows exponentially. # Worse, since 9x/ME are not pre-emptively multitasking, # you end up with a "frozen" computer, even though with patience # the test eventually succeeds (with a max line length of 256k). # Instead, let's just punt: use the minimum linelength reported by # all of the supported platforms: 8192 (on NT/2K/XP). lt_cv_sys_max_cmd_len=8192; ;; mint*) # On MiNT this can take a long time and run out of memory. lt_cv_sys_max_cmd_len=8192; ;; amigaos*) # On AmigaOS with pdksh, this test takes hours, literally. # So we just punt and use a minimum line length of 8192. lt_cv_sys_max_cmd_len=8192; ;; bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*) # This has been around since 386BSD, at least. Likely further. if test -x /sbin/sysctl; then lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` elif test -x /usr/sbin/sysctl; then lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` else lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs fi # And add a safety zone lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` ;; interix*) # We know the value 262144 and hardcode it with a safety zone (like BSD) lt_cv_sys_max_cmd_len=196608 ;; os2*) # The test takes a long time on OS/2. lt_cv_sys_max_cmd_len=8192 ;; osf*) # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not # nice to cause kernel panics so lets avoid the loop below. # First set a reasonable default. lt_cv_sys_max_cmd_len=16384 # if test -x /sbin/sysconfig; then case `/sbin/sysconfig -q proc exec_disable_arg_limit` in *1*) lt_cv_sys_max_cmd_len=-1 ;; esac fi ;; sco3.2v5*) lt_cv_sys_max_cmd_len=102400 ;; sysv5* | sco5v6* | sysv4.2uw2*) kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` if test -n "$kargmax"; then lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` else lt_cv_sys_max_cmd_len=32768 fi ;; *) lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` if test -n "$lt_cv_sys_max_cmd_len" && \ test undefined != "$lt_cv_sys_max_cmd_len"; then lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` else # Make teststring a little bigger before we do anything with it. # a 1K string should be a reasonable start. for i in 1 2 3 4 5 6 7 8; do teststring=$teststring$teststring done SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} # If test is not a shell built-in, we'll probably end up computing a # maximum length that is only half of the actual maximum length, but # we can't tell. while { test X`env echo "$teststring$teststring" 2>/dev/null` \ = "X$teststring$teststring"; } >/dev/null 2>&1 && test 17 != "$i" # 1/2 MB should be enough do i=`expr $i + 1` teststring=$teststring$teststring done # Only check the string length outside the loop. lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` teststring= # Add a significant safety factor because C++ compilers can tack on # massive amounts of additional arguments before passing them to the # linker. It appears as though 1/2 is a usable value. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` fi ;; esac ]) if test -n "$lt_cv_sys_max_cmd_len"; then AC_MSG_RESULT($lt_cv_sys_max_cmd_len) else AC_MSG_RESULT(none) fi max_cmd_len=$lt_cv_sys_max_cmd_len _LT_DECL([], [max_cmd_len], [0], [What is the maximum length of a command?]) ])# LT_CMD_MAX_LEN # Old name: AU_ALIAS([AC_LIBTOOL_SYS_MAX_CMD_LEN], [LT_CMD_MAX_LEN]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], []) # _LT_HEADER_DLFCN # ---------------- m4_defun([_LT_HEADER_DLFCN], [AC_CHECK_HEADERS([dlfcn.h], [], [], [AC_INCLUDES_DEFAULT])dnl ])# _LT_HEADER_DLFCN # _LT_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) # ---------------------------------------------------------------- m4_defun([_LT_TRY_DLOPEN_SELF], [m4_require([_LT_HEADER_DLFCN])dnl if test yes = "$cross_compiling"; then : [$4] else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF [#line $LINENO "configure" #include "confdefs.h" #if HAVE_DLFCN_H #include <dlfcn.h> #endif #include <stdio.h> #ifdef RTLD_GLOBAL # define LT_DLGLOBAL RTLD_GLOBAL #else # ifdef DL_GLOBAL # define LT_DLGLOBAL DL_GLOBAL # else # define LT_DLGLOBAL 0 # endif #endif /* We may have to define LT_DLLAZY_OR_NOW in the command line if we find out it does not work in some platform. */ #ifndef LT_DLLAZY_OR_NOW # ifdef RTLD_LAZY # define LT_DLLAZY_OR_NOW RTLD_LAZY # else # ifdef DL_LAZY # define LT_DLLAZY_OR_NOW DL_LAZY # else # ifdef RTLD_NOW # define LT_DLLAZY_OR_NOW RTLD_NOW # else # ifdef DL_NOW # define LT_DLLAZY_OR_NOW DL_NOW # else # define LT_DLLAZY_OR_NOW 0 # endif # endif # endif # endif #endif /* When -fvisibility=hidden is used, assume the code has been annotated correspondingly for the symbols needed. */ #if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) int fnord () __attribute__((visibility("default"))); #endif int fnord () { return 42; } int main () { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; if (self) { if (dlsym (self,"fnord")) status = $lt_dlno_uscore; else { if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; else puts (dlerror ()); } /* dlclose (self); */ } else puts (dlerror ()); return status; }] _LT_EOF if AC_TRY_EVAL(ac_link) && test -s "conftest$ac_exeext" 2>/dev/null; then (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null lt_status=$? case x$lt_status in x$lt_dlno_uscore) $1 ;; x$lt_dlneed_uscore) $2 ;; x$lt_dlunknown|x*) $3 ;; esac else : # compilation failed $3 fi fi rm -fr conftest* ])# _LT_TRY_DLOPEN_SELF # LT_SYS_DLOPEN_SELF # ------------------ AC_DEFUN([LT_SYS_DLOPEN_SELF], [m4_require([_LT_HEADER_DLFCN])dnl if test yes != "$enable_dlopen"; then enable_dlopen=unknown enable_dlopen_self=unknown enable_dlopen_self_static=unknown else lt_cv_dlopen=no lt_cv_dlopen_libs= case $host_os in beos*) lt_cv_dlopen=load_add_on lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ;; mingw* | pw32* | cegcc*) lt_cv_dlopen=LoadLibrary lt_cv_dlopen_libs= ;; cygwin*) lt_cv_dlopen=dlopen lt_cv_dlopen_libs= ;; darwin*) # if libdl is installed we need to link against it AC_CHECK_LIB([dl], [dlopen], [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],[ lt_cv_dlopen=dyld lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ]) ;; tpf*) # Don't try to run any link tests for TPF. We know it's impossible # because TPF is a cross-compiler, and we know how we open DSOs. lt_cv_dlopen=dlopen lt_cv_dlopen_libs= lt_cv_dlopen_self=no ;; *) AC_CHECK_FUNC([shl_load], [lt_cv_dlopen=shl_load], [AC_CHECK_LIB([dld], [shl_load], [lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld], [AC_CHECK_FUNC([dlopen], [lt_cv_dlopen=dlopen], [AC_CHECK_LIB([dl], [dlopen], [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl], [AC_CHECK_LIB([svld], [dlopen], [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld], [AC_CHECK_LIB([dld], [dld_link], [lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld]) ]) ]) ]) ]) ]) ;; esac if test no = "$lt_cv_dlopen"; then enable_dlopen=no else enable_dlopen=yes fi case $lt_cv_dlopen in dlopen) save_CPPFLAGS=$CPPFLAGS test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" save_LDFLAGS=$LDFLAGS wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" save_LIBS=$LIBS LIBS="$lt_cv_dlopen_libs $LIBS" AC_CACHE_CHECK([whether a program can dlopen itself], lt_cv_dlopen_self, [dnl _LT_TRY_DLOPEN_SELF( lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) ]) if test yes = "$lt_cv_dlopen_self"; then wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" AC_CACHE_CHECK([whether a statically linked program can dlopen itself], lt_cv_dlopen_self_static, [dnl _LT_TRY_DLOPEN_SELF( lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) ]) fi CPPFLAGS=$save_CPPFLAGS LDFLAGS=$save_LDFLAGS LIBS=$save_LIBS ;; esac case $lt_cv_dlopen_self in yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; *) enable_dlopen_self=unknown ;; esac case $lt_cv_dlopen_self_static in yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; *) enable_dlopen_self_static=unknown ;; esac fi _LT_DECL([dlopen_support], [enable_dlopen], [0], [Whether dlopen is supported]) _LT_DECL([dlopen_self], [enable_dlopen_self], [0], [Whether dlopen of programs is supported]) _LT_DECL([dlopen_self_static], [enable_dlopen_self_static], [0], [Whether dlopen of statically linked programs is supported]) ])# LT_SYS_DLOPEN_SELF # Old name: AU_ALIAS([AC_LIBTOOL_DLOPEN_SELF], [LT_SYS_DLOPEN_SELF]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], []) # _LT_COMPILER_C_O([TAGNAME]) # --------------------------- # Check to see if options -c and -o are simultaneously supported by compiler. # This macro does not hard code the compiler like AC_PROG_CC_C_O. m4_defun([_LT_COMPILER_C_O], [m4_require([_LT_DECL_SED])dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_TAG_COMPILER])dnl AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)], [_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no $RM -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&AS_MESSAGE_LOG_FD) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&AS_MESSAGE_LOG_FD echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes fi fi chmod u+w . 2>&AS_MESSAGE_LOG_FD $RM conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files $RM out/* && rmdir out cd .. $RM -r conftest $RM conftest* ]) _LT_TAGDECL([compiler_c_o], [lt_cv_prog_compiler_c_o], [1], [Does compiler simultaneously support -c and -o options?]) ])# _LT_COMPILER_C_O # _LT_COMPILER_FILE_LOCKS([TAGNAME]) # ---------------------------------- # Check to see if we can do hard links to lock some files if needed m4_defun([_LT_COMPILER_FILE_LOCKS], [m4_require([_LT_ENABLE_LOCK])dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl _LT_COMPILER_C_O([$1]) hard_links=nottested if test no = "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" && test no != "$need_locks"; then # do not overwrite the value of need_locks provided by the user AC_MSG_CHECKING([if we can lock with hard links]) hard_links=yes $RM conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no AC_MSG_RESULT([$hard_links]) if test no = "$hard_links"; then AC_MSG_WARN(['$CC' does not support '-c -o', so 'make -j' may be unsafe]) need_locks=warn fi else need_locks=no fi _LT_DECL([], [need_locks], [1], [Must we lock files when doing compilation?]) ])# _LT_COMPILER_FILE_LOCKS # _LT_CHECK_OBJDIR # ---------------- m4_defun([_LT_CHECK_OBJDIR], [AC_CACHE_CHECK([for objdir], [lt_cv_objdir], [rm -f .libs 2>/dev/null mkdir .libs 2>/dev/null if test -d .libs; then lt_cv_objdir=.libs else # MS-DOS does not allow filenames that begin with a dot. lt_cv_objdir=_libs fi rmdir .libs 2>/dev/null]) objdir=$lt_cv_objdir _LT_DECL([], [objdir], [0], [The name of the directory that contains temporary libtool files])dnl m4_pattern_allow([LT_OBJDIR])dnl AC_DEFINE_UNQUOTED([LT_OBJDIR], "$lt_cv_objdir/", [Define to the sub-directory where libtool stores uninstalled libraries.]) ])# _LT_CHECK_OBJDIR # _LT_LINKER_HARDCODE_LIBPATH([TAGNAME]) # -------------------------------------- # Check hardcoding attributes. m4_defun([_LT_LINKER_HARDCODE_LIBPATH], [AC_MSG_CHECKING([how to hardcode library paths into programs]) _LT_TAGVAR(hardcode_action, $1)= if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || test -n "$_LT_TAGVAR(runpath_var, $1)" || test yes = "$_LT_TAGVAR(hardcode_automatic, $1)"; then # We can hardcode non-existent directories. if test no != "$_LT_TAGVAR(hardcode_direct, $1)" && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" && test no != "$_LT_TAGVAR(hardcode_minus_L, $1)"; then # Linking always hardcodes the temporary library directory. _LT_TAGVAR(hardcode_action, $1)=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. _LT_TAGVAR(hardcode_action, $1)=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. _LT_TAGVAR(hardcode_action, $1)=unsupported fi AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) if test relink = "$_LT_TAGVAR(hardcode_action, $1)" || test yes = "$_LT_TAGVAR(inherit_rpath, $1)"; then # Fast installation is not supported enable_fast_install=no elif test yes = "$shlibpath_overrides_runpath" || test no = "$enable_shared"; then # Fast installation is not necessary enable_fast_install=needless fi _LT_TAGDECL([], [hardcode_action], [0], [How to hardcode a shared library path into an executable]) ])# _LT_LINKER_HARDCODE_LIBPATH # _LT_CMD_STRIPLIB # ---------------- m4_defun([_LT_CMD_STRIPLIB], [m4_require([_LT_DECL_EGREP]) striplib= old_striplib= AC_MSG_CHECKING([whether stripping libraries is possible]) if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" test -z "$striplib" && striplib="$STRIP --strip-unneeded" AC_MSG_RESULT([yes]) else # FIXME - insert some real tests, host_os isn't really good enough case $host_os in darwin*) if test -n "$STRIP"; then striplib="$STRIP -x" old_striplib="$STRIP -S" AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) fi ;; *) AC_MSG_RESULT([no]) ;; esac fi _LT_DECL([], [old_striplib], [1], [Commands to strip libraries]) _LT_DECL([], [striplib], [1]) ])# _LT_CMD_STRIPLIB # _LT_PREPARE_MUNGE_PATH_LIST # --------------------------- # Make sure func_munge_path_list() is defined correctly. m4_defun([_LT_PREPARE_MUNGE_PATH_LIST], [[# func_munge_path_list VARIABLE PATH # ----------------------------------- # VARIABLE is name of variable containing _space_ separated list of # directories to be munged by the contents of PATH, which is string # having a format: # "DIR[:DIR]:" # string "DIR[ DIR]" will be prepended to VARIABLE # ":DIR[:DIR]" # string "DIR[ DIR]" will be appended to VARIABLE # "DIRP[:DIRP]::[DIRA:]DIRA" # string "DIRP[ DIRP]" will be prepended to VARIABLE and string # "DIRA[ DIRA]" will be appended to VARIABLE # "DIR[:DIR]" # VARIABLE will be replaced by "DIR[ DIR]" func_munge_path_list () { case x@S|@2 in x) ;; *:) eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'` \@S|@@S|@1\" ;; x:*) eval @S|@1=\"\@S|@@S|@1 `$ECHO @S|@2 | $SED 's/:/ /g'`\" ;; *::*) eval @S|@1=\"\@S|@@S|@1\ `$ECHO @S|@2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" eval @S|@1=\"`$ECHO @S|@2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \@S|@@S|@1\" ;; *) eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'`\" ;; esac } ]])# _LT_PREPARE_PATH_LIST # _LT_SYS_DYNAMIC_LINKER([TAG]) # ----------------------------- # PORTME Fill in your ld.so characteristics m4_defun([_LT_SYS_DYNAMIC_LINKER], [AC_REQUIRE([AC_CANONICAL_HOST])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_OBJDUMP])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_CHECK_SHELL_FEATURES])dnl m4_require([_LT_PREPARE_MUNGE_PATH_LIST])dnl AC_MSG_CHECKING([dynamic linker characteristics]) m4_if([$1], [], [ if test yes = "$GCC"; then case $host_os in darwin*) lt_awk_arg='/^libraries:/,/LR/' ;; *) lt_awk_arg='/^libraries:/' ;; esac case $host_os in mingw* | cegcc*) lt_sed_strip_eq='s|=\([[A-Za-z]]:\)|\1|g' ;; *) lt_sed_strip_eq='s|=/|/|g' ;; esac lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` case $lt_search_path_spec in *\;*) # if the path contains ";" then we assume it to be the separator # otherwise default to the standard path separator (i.e. ":") - it is # assumed that no part of a normal pathname contains ";" but that should # okay in the real world where ";" in dirpaths is itself problematic. lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` ;; *) lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` ;; esac # Ok, now we have the path, separated by spaces, we can step through it # and add multilib dir if necessary... lt_tmp_lt_search_path_spec= lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` # ...but if some path component already ends with the multilib dir we assume # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer). case "$lt_multi_os_dir; $lt_search_path_spec " in "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*) lt_multi_os_dir= ;; esac for lt_sys_path in $lt_search_path_spec; do if test -d "$lt_sys_path$lt_multi_os_dir"; then lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir" elif test -n "$lt_multi_os_dir"; then test -d "$lt_sys_path" && \ lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" fi done lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' BEGIN {RS = " "; FS = "/|\n";} { lt_foo = ""; lt_count = 0; for (lt_i = NF; lt_i > 0; lt_i--) { if ($lt_i != "" && $lt_i != ".") { if ($lt_i == "..") { lt_count++; } else { if (lt_count == 0) { lt_foo = "/" $lt_i lt_foo; } else { lt_count--; } } } } if (lt_foo != "") { lt_freq[[lt_foo]]++; } if (lt_freq[[lt_foo]] == 1) { print lt_foo; } }'` # AWK program above erroneously prepends '/' to C:/dos/paths # for these hosts. case $host_os in mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ $SED 's|/\([[A-Za-z]]:\)|\1|g'` ;; esac sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` else sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" fi]) library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=.so postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown AC_ARG_VAR([LT_SYS_LIBRARY_PATH], [User-defined run-time library search path.]) case $host_os in aix3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='$libname$release$shared_ext$major' ;; aix[[4-9]]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no hardcode_into_libs=yes if test ia64 = "$host_cpu"; then # AIX 5 supports IA64 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line '#! .'. This would cause the generated library to # depend on '.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[[01]] | aix4.[[01]].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then : else can_build_shared=no fi ;; esac # Using Import Files as archive members, it is possible to support # filename-based versioning of shared library archives on AIX. While # this would work for both with and without runtime linking, it will # prevent static linking of such archives. So we do filename-based # shared library versioning with .so extension only, which is used # when both runtime linking and shared linking is enabled. # Unfortunately, runtime linking may impact performance, so we do # not want this to be the default eventually. Also, we use the # versioned .so libs for executables only if there is the -brtl # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. # To allow for filename-based versioning support, we need to create # libNAME.so.V as an archive file, containing: # *) an Import File, referring to the versioned filename of the # archive as well as the shared archive member, telling the # bitwidth (32 or 64) of that shared object, and providing the # list of exported symbols of that shared object, eventually # decorated with the 'weak' keyword # *) the shared object with the F_LOADONLY flag set, to really avoid # it being seen by the linker. # At run time we better use the real file rather than another symlink, # but for link time we create the symlink libNAME.so -> libNAME.so.V case $with_aix_soname,$aix_use_runtimelinking in # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. aix,yes) # traditional libtool dynamic_linker='AIX unversionable lib.so' # If using run time linking (on AIX 4.2 or later) use lib<name>.so # instead of lib<name>.a to let people know that these are not # typical AIX shared libraries. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; aix,no) # traditional AIX only dynamic_linker='AIX lib.a[(]lib.so.V[)]' # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' ;; svr4,*) # full svr4 only dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)]" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,yes) # both, prefer svr4 dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)], lib.a[(]lib.so.V[)]" library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' # unpreferred sharedlib libNAME.a needs extra handling postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' # We do not specify a path in Import Files, so LIBPATH fires. shlibpath_overrides_runpath=yes ;; *,no) # both, prefer aix dynamic_linker="AIX lib.a[(]lib.so.V[)], lib.so.V[(]$shared_archive_member_spec.o[)]" library_names_spec='$libname$release.a $libname.a' soname_spec='$libname$release$shared_ext$major' # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' ;; esac shlibpath_var=LIBPATH fi ;; amigaos*) case $host_cpu in powerpc) # Since July 2007 AmigaOS4 officially supports .so libraries. # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; m68k) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; esac ;; beos*) library_names_spec='$libname$shared_ext' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[[45]]*) version_type=linux # correct to gnu/linux during the next big refactor need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | mingw* | pw32* | cegcc*) version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no case $GCC,$cc_basename in yes,*) # gcc library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' m4_if([$1], [],[ sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) ;; mingw* | cegcc*) # MinGW DLLs use traditional 'lib' prefix soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' ;; esac dynamic_linker='Win32 ld.exe' ;; *,cl*) # Native MSVC libname_spec='$name' soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' library_names_spec='$libname.dll.lib' case $build_os in mingw*) sys_lib_search_path_spec= lt_save_ifs=$IFS IFS=';' for lt_path in $LIB do IFS=$lt_save_ifs # Let DOS variable expansion print the short 8.3 style file name. lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"` sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path" done IFS=$lt_save_ifs # Convert to MSYS style. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([[a-zA-Z]]\\):| /\\1|g' -e 's|^ ||'` ;; cygwin*) # Convert to unix form, then to dos form, then back to unix form # but this time dos style (no spaces!) so that the unix form looks # like /cygdrive/c/PROGRA~1:/cygdr... sys_lib_search_path_spec=`cygpath --path --unix "$LIB"` sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null` sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` ;; *) sys_lib_search_path_spec=$LIB if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then # It is most probably a Windows format PATH. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi # FIXME: find the short name or the path components, as spaces are # common. (e.g. "Program Files" -> "PROGRA~1") ;; esac # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' shlibpath_overrides_runpath=yes dynamic_linker='Win32 link.exe' ;; *) # Assume MSVC wrapper library_names_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext $libname.lib' dynamic_linker='Win32 ld.exe' ;; esac # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' soname_spec='$libname$release$major$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' m4_if([$1], [],[ sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd* | dragonfly*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[[23]].*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2.*) shlibpath_overrides_runpath=yes ;; freebsd3.[[01]]* | freebsdelf3.[[01]]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; haiku*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no dynamic_linker="$host_os runtime_loader" library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LIBRARY_PATH shlibpath_overrides_runpath=no sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' if test 32 = "$HPUX_IA64_MODE"; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" sys_lib_dlsearch_path_spec=/usr/lib/hpux32 else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" sys_lib_dlsearch_path_spec=/usr/lib/hpux64 fi ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555, ... postinstall_cmds='chmod 555 $lib' # or fails outright, so override atomically: install_override_mode=555 ;; interix[[3-9]]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test yes = "$lt_cv_prog_gnu_ld"; then version_type=linux # correct to gnu/linux during the next big refactor else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; linux*android*) version_type=none # Android doesn't support versioned libraries. need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext' soname_spec='$libname$release$shared_ext' finish_cmds= shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes dynamic_linker='Android linker' # Don't embed -rpath directories since the linker doesn't support them. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' ;; # This must be glibc/ELF. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # Some binutils ld are patched to set DT_RUNPATH AC_CACHE_VAL([lt_cv_shlibpath_overrides_runpath], [lt_cv_shlibpath_overrides_runpath=no save_LDFLAGS=$LDFLAGS save_libdir=$libdir eval "libdir=/foo; wl=\"$_LT_TAGVAR(lt_prog_compiler_wl, $1)\"; \ LDFLAGS=\"\$LDFLAGS $_LT_TAGVAR(hardcode_libdir_flag_spec, $1)\"" AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], [AS_IF([ ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null], [lt_cv_shlibpath_overrides_runpath=yes])]) LDFLAGS=$save_LDFLAGS libdir=$save_libdir ]) shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Add ABI-specific directories to the system library path. sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" # Ideally, we could use ldconfig to report *all* directores which are # searched for libraries, however this is still not possible. Aside from not # being certain /sbin/ldconfig is available, command # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, # even though it is searched at run-time. Try to do the best guess by # appending ld.so.conf contents (and includes) to the search path. if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; *nto* | *qnx*) version_type=qnx need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='ldqnx.so' ;; openbsd* | bitrig*) version_type=sunos sys_lib_dlsearch_path_spec=/usr/lib need_lib_prefix=no if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then need_version=no else need_version=yes fi library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; os2*) libname_spec='$name' version_type=windows shrext_cmds=.dll need_version=no need_lib_prefix=no # OS/2 can only load a DLL with a base name of 8 characters or less. soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; v=$($ECHO $release$versuffix | tr -d .-); n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); $ECHO $n$v`$shared_ext' library_names_spec='${libname}_dll.$libext' dynamic_linker='OS/2 ld.exe' shlibpath_var=BEGINLIBPATH sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec postinstall_cmds='base_file=`basename \$file`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname~ if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; fi' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ dlpath=$dir/\$dldll~ $RM \$dlpath' ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='$libname$release$shared_ext$major' library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test yes = "$with_gnu_ld"; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec; then version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' soname_spec='$libname$shared_ext.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=sco need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes if test yes = "$with_gnu_ld"; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; tpf*) # TPF is a cross-target only. Preferred cross-host = GNU/Linux. version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; uts4*) version_type=linux # correct to gnu/linux during the next big refactor library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac AC_MSG_RESULT([$dynamic_linker]) test no = "$dynamic_linker" && can_build_shared=no variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test yes = "$GCC"; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec fi if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec fi # remember unaugmented sys_lib_dlsearch_path content for libtool script decls... configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec # ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" # to be used as default LT_SYS_LIBRARY_PATH value in generated libtool configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH _LT_DECL([], [variables_saved_for_relink], [1], [Variables whose values should be saved in libtool wrapper scripts and restored at link time]) _LT_DECL([], [need_lib_prefix], [0], [Do we need the "lib" prefix for modules?]) _LT_DECL([], [need_version], [0], [Do we need a version for libraries?]) _LT_DECL([], [version_type], [0], [Library versioning type]) _LT_DECL([], [runpath_var], [0], [Shared library runtime path variable]) _LT_DECL([], [shlibpath_var], [0],[Shared library path variable]) _LT_DECL([], [shlibpath_overrides_runpath], [0], [Is shlibpath searched before the hard-coded library search path?]) _LT_DECL([], [libname_spec], [1], [Format of library name prefix]) _LT_DECL([], [library_names_spec], [1], [[List of archive names. First name is the real one, the rest are links. The last name is the one that the linker finds with -lNAME]]) _LT_DECL([], [soname_spec], [1], [[The coded name of the library, if different from the real name]]) _LT_DECL([], [install_override_mode], [1], [Permission mode override for installation of shared libraries]) _LT_DECL([], [postinstall_cmds], [2], [Command to use after installation of a shared archive]) _LT_DECL([], [postuninstall_cmds], [2], [Command to use after uninstallation of a shared archive]) _LT_DECL([], [finish_cmds], [2], [Commands used to finish a libtool library installation in a directory]) _LT_DECL([], [finish_eval], [1], [[As "finish_cmds", except a single script fragment to be evaled but not shown]]) _LT_DECL([], [hardcode_into_libs], [0], [Whether we should hardcode library paths into libraries]) _LT_DECL([], [sys_lib_search_path_spec], [2], [Compile-time system search path for libraries]) _LT_DECL([sys_lib_dlsearch_path_spec], [configure_time_dlsearch_path], [2], [Detected run-time system search path for libraries]) _LT_DECL([], [configure_time_lt_sys_library_path], [2], [Explicit LT_SYS_LIBRARY_PATH set during ./configure time]) ])# _LT_SYS_DYNAMIC_LINKER # _LT_PATH_TOOL_PREFIX(TOOL) # -------------------------- # find a file program that can recognize shared library AC_DEFUN([_LT_PATH_TOOL_PREFIX], [m4_require([_LT_DECL_EGREP])dnl AC_MSG_CHECKING([for $1]) AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, [case $MAGIC_CMD in [[\\/*] | ?:[\\/]*]) lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. ;; *) lt_save_MAGIC_CMD=$MAGIC_CMD lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR dnl $ac_dummy forces splitting on constant user-supplied paths. dnl POSIX.2 word splitting is done only on the output of word expansions, dnl not every word. This closes a longstanding sh security hole. ac_dummy="m4_if([$2], , $PATH, [$2])" for ac_dir in $ac_dummy; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$1"; then lt_cv_path_MAGIC_CMD=$ac_dir/"$1" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` MAGIC_CMD=$lt_cv_path_MAGIC_CMD if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : else cat <<_LT_EOF 1>&2 *** Warning: the command libtool uses to detect shared libraries, *** $file_magic_cmd, produces output that libtool cannot recognize. *** The result is that libtool may fail to recognize shared libraries *** as such. This will affect the creation of libtool libraries that *** depend on shared libraries, but programs linked with such libtool *** libraries will work regardless of this problem. Nevertheless, you *** may want to report the problem to your system manager and/or to *** bug-libtool@gnu.org _LT_EOF fi ;; esac fi break fi done IFS=$lt_save_ifs MAGIC_CMD=$lt_save_MAGIC_CMD ;; esac]) MAGIC_CMD=$lt_cv_path_MAGIC_CMD if test -n "$MAGIC_CMD"; then AC_MSG_RESULT($MAGIC_CMD) else AC_MSG_RESULT(no) fi _LT_DECL([], [MAGIC_CMD], [0], [Used to examine libraries when file_magic_cmd begins with "file"])dnl ])# _LT_PATH_TOOL_PREFIX # Old name: AU_ALIAS([AC_PATH_TOOL_PREFIX], [_LT_PATH_TOOL_PREFIX]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) # _LT_PATH_MAGIC # -------------- # find a file program that can recognize a shared library m4_defun([_LT_PATH_MAGIC], [_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) if test -z "$lt_cv_path_MAGIC_CMD"; then if test -n "$ac_tool_prefix"; then _LT_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) else MAGIC_CMD=: fi fi ])# _LT_PATH_MAGIC # LT_PATH_LD # ---------- # find the pathname to the GNU or non-GNU linker AC_DEFUN([LT_PATH_LD], [AC_REQUIRE([AC_PROG_CC])dnl AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_CANONICAL_BUILD])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_PROG_ECHO_BACKSLASH])dnl AC_ARG_WITH([gnu-ld], [AS_HELP_STRING([--with-gnu-ld], [assume the C compiler uses GNU ld @<:@default=no@:>@])], [test no = "$withval" || with_gnu_ld=yes], [with_gnu_ld=no])dnl ac_prog=ld if test yes = "$GCC"; then # Check if gcc -print-prog-name=ld gives a path. AC_MSG_CHECKING([for ld used by $CC]) case $host in *-*-mingw*) # gcc leaves a trailing carriage return, which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; esac case $ac_prog in # Accept absolute paths. [[\\/]]* | ?:[[\\/]]*) re_direlt='/[[^/]][[^/]]*/\.\./' # Canonicalize the pathname of ld ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` done test -z "$LD" && LD=$ac_prog ;; "") # If it fails, then pretend we aren't using GCC. ac_prog=ld ;; *) # If it is relative, then search for the first ld in PATH. with_gnu_ld=unknown ;; esac elif test yes = "$with_gnu_ld"; then AC_MSG_CHECKING([for GNU ld]) else AC_MSG_CHECKING([for non-GNU ld]) fi AC_CACHE_VAL(lt_cv_path_LD, [if test -z "$LD"; then lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then lt_cv_path_LD=$ac_dir/$ac_prog # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some variants of GNU ld only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in *GNU* | *'with BFD'*) test no != "$with_gnu_ld" && break ;; *) test yes != "$with_gnu_ld" && break ;; esac fi done IFS=$lt_save_ifs else lt_cv_path_LD=$LD # Let the user override the test with a path. fi]) LD=$lt_cv_path_LD if test -n "$LD"; then AC_MSG_RESULT($LD) else AC_MSG_RESULT(no) fi test -z "$LD" && AC_MSG_ERROR([no acceptable ld found in \$PATH]) _LT_PATH_LD_GNU AC_SUBST([LD]) _LT_TAGDECL([], [LD], [1], [The linker used to build libraries]) ])# LT_PATH_LD # Old names: AU_ALIAS([AM_PROG_LD], [LT_PATH_LD]) AU_ALIAS([AC_PROG_LD], [LT_PATH_LD]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AM_PROG_LD], []) dnl AC_DEFUN([AC_PROG_LD], []) # _LT_PATH_LD_GNU #- -------------- m4_defun([_LT_PATH_LD_GNU], [AC_CACHE_CHECK([if the linker ($LD) is GNU ld], lt_cv_prog_gnu_ld, [# I'd rather use --version here, but apparently some GNU lds only accept -v. case `$LD -v 2>&1 </dev/null` in *GNU* | *'with BFD'*) lt_cv_prog_gnu_ld=yes ;; *) lt_cv_prog_gnu_ld=no ;; esac]) with_gnu_ld=$lt_cv_prog_gnu_ld ])# _LT_PATH_LD_GNU # _LT_CMD_RELOAD # -------------- # find reload flag for linker # -- PORTME Some linkers may need a different reload flag. m4_defun([_LT_CMD_RELOAD], [AC_CACHE_CHECK([for $LD option to reload object files], lt_cv_ld_reload_flag, [lt_cv_ld_reload_flag='-r']) reload_flag=$lt_cv_ld_reload_flag case $reload_flag in "" | " "*) ;; *) reload_flag=" $reload_flag" ;; esac reload_cmds='$LD$reload_flag -o $output$reload_objs' case $host_os in cygwin* | mingw* | pw32* | cegcc*) if test yes != "$GCC"; then reload_cmds=false fi ;; darwin*) if test yes = "$GCC"; then reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs' else reload_cmds='$LD$reload_flag -o $output$reload_objs' fi ;; esac _LT_TAGDECL([], [reload_flag], [1], [How to create reloadable object files])dnl _LT_TAGDECL([], [reload_cmds], [2])dnl ])# _LT_CMD_RELOAD # _LT_PATH_DD # ----------- # find a working dd m4_defun([_LT_PATH_DD], [AC_CACHE_CHECK([for a working dd], [ac_cv_path_lt_DD], [printf 0123456789abcdef0123456789abcdef >conftest.i cat conftest.i conftest.i >conftest2.i : ${lt_DD:=$DD} AC_PATH_PROGS_FEATURE_CHECK([lt_DD], [dd], [if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then cmp -s conftest.i conftest.out \ && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=: fi]) rm -f conftest.i conftest2.i conftest.out]) ])# _LT_PATH_DD # _LT_CMD_TRUNCATE # ---------------- # find command to truncate a binary pipe m4_defun([_LT_CMD_TRUNCATE], [m4_require([_LT_PATH_DD]) AC_CACHE_CHECK([how to truncate binary pipes], [lt_cv_truncate_bin], [printf 0123456789abcdef0123456789abcdef >conftest.i cat conftest.i conftest.i >conftest2.i lt_cv_truncate_bin= if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then cmp -s conftest.i conftest.out \ && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" fi rm -f conftest.i conftest2.i conftest.out test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"]) _LT_DECL([lt_truncate_bin], [lt_cv_truncate_bin], [1], [Command to truncate a binary pipe]) ])# _LT_CMD_TRUNCATE # _LT_CHECK_MAGIC_METHOD # ---------------------- # how to check for library dependencies # -- PORTME fill in with the dynamic library characteristics m4_defun([_LT_CHECK_MAGIC_METHOD], [m4_require([_LT_DECL_EGREP]) m4_require([_LT_DECL_OBJDUMP]) AC_CACHE_CHECK([how to recognize dependent libraries], lt_cv_deplibs_check_method, [lt_cv_file_magic_cmd='$MAGIC_CMD' lt_cv_file_magic_test_file= lt_cv_deplibs_check_method='unknown' # Need to set the preceding variable on all platforms that support # interlibrary dependencies. # 'none' -- dependencies not supported. # 'unknown' -- same as none, but documents that we really don't know. # 'pass_all' -- all dependencies passed with no checks. # 'test_compile' -- check by making test program. # 'file_magic [[regex]]' -- check by looking for files in library path # that responds to the $file_magic_cmd with a given extended regex. # If you have 'file' or equivalent on your system and you're not sure # whether 'pass_all' will *always* work, you probably want this one. case $host_os in aix[[4-9]]*) lt_cv_deplibs_check_method=pass_all ;; beos*) lt_cv_deplibs_check_method=pass_all ;; bsdi[[45]]*) lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib)' lt_cv_file_magic_cmd='/usr/bin/file -L' lt_cv_file_magic_test_file=/shlib/libc.so ;; cygwin*) # func_win32_libid is a shell function defined in ltmain.sh lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' ;; mingw* | pw32*) # Base MSYS/MinGW do not provide the 'file' command needed by # func_win32_libid shell function, so use a weaker test based on 'objdump', # unless we find 'file', for example because we are cross-compiling. if ( file / ) >/dev/null 2>&1; then lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' else # Keep this pattern in sync with the one in func_win32_libid. lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)' lt_cv_file_magic_cmd='$OBJDUMP -f' fi ;; cegcc*) # use the weaker test based on 'objdump'. See mingw*. lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' lt_cv_file_magic_cmd='$OBJDUMP -f' ;; darwin* | rhapsody*) lt_cv_deplibs_check_method=pass_all ;; freebsd* | dragonfly*) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then case $host_cpu in i*86 ) # Not sure whether the presence of OpenBSD here was a mistake. # Let's accept both of them until this is cleared up. lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' lt_cv_file_magic_cmd=/usr/bin/file lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` ;; esac else lt_cv_deplibs_check_method=pass_all fi ;; haiku*) lt_cv_deplibs_check_method=pass_all ;; hpux10.20* | hpux11*) lt_cv_file_magic_cmd=/usr/bin/file case $host_cpu in ia64*) lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so ;; hppa*64*) [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'] lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl ;; *) lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]]\.[[0-9]]) shared library' lt_cv_file_magic_test_file=/usr/lib/libc.sl ;; esac ;; interix[[3-9]]*) # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' ;; irix5* | irix6* | nonstopux*) case $LD in *-32|*"-32 ") libmagic=32-bit;; *-n32|*"-n32 ") libmagic=N32;; *-64|*"-64 ") libmagic=64-bit;; *) libmagic=never-match;; esac lt_cv_deplibs_check_method=pass_all ;; # This must be glibc/ELF. linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) lt_cv_deplibs_check_method=pass_all ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' fi ;; newos6*) lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' lt_cv_file_magic_cmd=/usr/bin/file lt_cv_file_magic_test_file=/usr/lib/libnls.so ;; *nto* | *qnx*) lt_cv_deplibs_check_method=pass_all ;; openbsd* | bitrig*) if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' fi ;; osf3* | osf4* | osf5*) lt_cv_deplibs_check_method=pass_all ;; rdos*) lt_cv_deplibs_check_method=pass_all ;; solaris*) lt_cv_deplibs_check_method=pass_all ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) lt_cv_deplibs_check_method=pass_all ;; sysv4 | sysv4.3*) case $host_vendor in motorola) lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]' lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` ;; ncr) lt_cv_deplibs_check_method=pass_all ;; sequent) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' ;; sni) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" lt_cv_file_magic_test_file=/lib/libc.so ;; siemens) lt_cv_deplibs_check_method=pass_all ;; pc) lt_cv_deplibs_check_method=pass_all ;; esac ;; tpf*) lt_cv_deplibs_check_method=pass_all ;; os2*) lt_cv_deplibs_check_method=pass_all ;; esac ]) file_magic_glob= want_nocaseglob=no if test "$build" = "$host"; then case $host_os in mingw* | pw32*) if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then want_nocaseglob=yes else file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[[\1]]\/[[\1]]\/g;/g"` fi ;; esac fi file_magic_cmd=$lt_cv_file_magic_cmd deplibs_check_method=$lt_cv_deplibs_check_method test -z "$deplibs_check_method" && deplibs_check_method=unknown _LT_DECL([], [deplibs_check_method], [1], [Method to check whether dependent libraries are shared objects]) _LT_DECL([], [file_magic_cmd], [1], [Command to use when deplibs_check_method = "file_magic"]) _LT_DECL([], [file_magic_glob], [1], [How to find potential files when deplibs_check_method = "file_magic"]) _LT_DECL([], [want_nocaseglob], [1], [Find potential files using nocaseglob when deplibs_check_method = "file_magic"]) ])# _LT_CHECK_MAGIC_METHOD # LT_PATH_NM # ---------- # find the pathname to a BSD- or MS-compatible name lister AC_DEFUN([LT_PATH_NM], [AC_REQUIRE([AC_PROG_CC])dnl AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, [if test -n "$NM"; then # Let the user override the test. lt_cv_path_NM=$NM else lt_nm_to_check=${ac_tool_prefix}nm if test -n "$ac_tool_prefix" && test "$build" = "$host"; then lt_nm_to_check="$lt_nm_to_check nm" fi for lt_tmp_nm in $lt_nm_to_check; do lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. tmp_nm=$ac_dir/$lt_tmp_nm if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then # Check to see if the nm accepts a BSD-compat flag. # Adding the 'sed 1q' prevents false positives on HP-UX, which says: # nm: unknown option "B" ignored # Tru64's nm complains that /dev/null is an invalid object file # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty case $build_os in mingw*) lt_bad_file=conftest.nm/nofile ;; *) lt_bad_file=/dev/null ;; esac case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in *$lt_bad_file* | *'Invalid file or object type'*) lt_cv_path_NM="$tmp_nm -B" break 2 ;; *) case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in */dev/null*) lt_cv_path_NM="$tmp_nm -p" break 2 ;; *) lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but continue # so that we can try to find one that supports BSD flags ;; esac ;; esac fi done IFS=$lt_save_ifs done : ${lt_cv_path_NM=no} fi]) if test no != "$lt_cv_path_NM"; then NM=$lt_cv_path_NM else # Didn't find any BSD compatible name lister, look for dumpbin. if test -n "$DUMPBIN"; then : # Let the user override the test. else AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in *COFF*) DUMPBIN="$DUMPBIN -symbols -headers" ;; *) DUMPBIN=: ;; esac fi AC_SUBST([DUMPBIN]) if test : != "$DUMPBIN"; then NM=$DUMPBIN fi fi test -z "$NM" && NM=nm AC_SUBST([NM]) _LT_DECL([], [NM], [1], [A BSD- or MS-compatible name lister])dnl AC_CACHE_CHECK([the name lister ($NM) interface], [lt_cv_nm_interface], [lt_cv_nm_interface="BSD nm" echo "int some_variable = 0;" > conftest.$ac_ext (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&AS_MESSAGE_LOG_FD) (eval "$ac_compile" 2>conftest.err) cat conftest.err >&AS_MESSAGE_LOG_FD (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&AS_MESSAGE_LOG_FD) (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) cat conftest.err >&AS_MESSAGE_LOG_FD (eval echo "\"\$as_me:$LINENO: output\"" >&AS_MESSAGE_LOG_FD) cat conftest.out >&AS_MESSAGE_LOG_FD if $GREP 'External.*some_variable' conftest.out > /dev/null; then lt_cv_nm_interface="MS dumpbin" fi rm -f conftest*]) ])# LT_PATH_NM # Old names: AU_ALIAS([AM_PROG_NM], [LT_PATH_NM]) AU_ALIAS([AC_PROG_NM], [LT_PATH_NM]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AM_PROG_NM], []) dnl AC_DEFUN([AC_PROG_NM], []) # _LT_CHECK_SHAREDLIB_FROM_LINKLIB # -------------------------------- # how to determine the name of the shared library # associated with a specific link library. # -- PORTME fill in with the dynamic library characteristics m4_defun([_LT_CHECK_SHAREDLIB_FROM_LINKLIB], [m4_require([_LT_DECL_EGREP]) m4_require([_LT_DECL_OBJDUMP]) m4_require([_LT_DECL_DLLTOOL]) AC_CACHE_CHECK([how to associate runtime and link libraries], lt_cv_sharedlib_from_linklib_cmd, [lt_cv_sharedlib_from_linklib_cmd='unknown' case $host_os in cygwin* | mingw* | pw32* | cegcc*) # two different shell functions defined in ltmain.sh; # decide which one to use based on capabilities of $DLLTOOL case `$DLLTOOL --help 2>&1` in *--identify-strict*) lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib ;; *) lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback ;; esac ;; *) # fallback: assume linklib IS sharedlib lt_cv_sharedlib_from_linklib_cmd=$ECHO ;; esac ]) sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO _LT_DECL([], [sharedlib_from_linklib_cmd], [1], [Command to associate shared and link libraries]) ])# _LT_CHECK_SHAREDLIB_FROM_LINKLIB # _LT_PATH_MANIFEST_TOOL # ---------------------- # locate the manifest tool m4_defun([_LT_PATH_MANIFEST_TOOL], [AC_CHECK_TOOL(MANIFEST_TOOL, mt, :) test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool], [lt_cv_path_mainfest_tool=no echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&AS_MESSAGE_LOG_FD $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out cat conftest.err >&AS_MESSAGE_LOG_FD if $GREP 'Manifest Tool' conftest.out > /dev/null; then lt_cv_path_mainfest_tool=yes fi rm -f conftest*]) if test yes != "$lt_cv_path_mainfest_tool"; then MANIFEST_TOOL=: fi _LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl ])# _LT_PATH_MANIFEST_TOOL # _LT_DLL_DEF_P([FILE]) # --------------------- # True iff FILE is a Windows DLL '.def' file. # Keep in sync with func_dll_def_p in the libtool script AC_DEFUN([_LT_DLL_DEF_P], [dnl test DEF = "`$SED -n dnl -e '\''s/^[[ ]]*//'\'' dnl Strip leading whitespace -e '\''/^\(;.*\)*$/d'\'' dnl Delete empty lines and comments -e '\''s/^\(EXPORTS\|LIBRARY\)\([[ ]].*\)*$/DEF/p'\'' dnl -e q dnl Only consider the first "real" line $1`" dnl ])# _LT_DLL_DEF_P # LT_LIB_M # -------- # check for math library AC_DEFUN([LT_LIB_M], [AC_REQUIRE([AC_CANONICAL_HOST])dnl LIBM= case $host in *-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*) # These system don't have libm, or don't need it ;; *-ncr-sysv4.3*) AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM=-lmw) AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") ;; *) AC_CHECK_LIB(m, cos, LIBM=-lm) ;; esac AC_SUBST([LIBM]) ])# LT_LIB_M # Old name: AU_ALIAS([AC_CHECK_LIBM], [LT_LIB_M]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_CHECK_LIBM], []) # _LT_COMPILER_NO_RTTI([TAGNAME]) # ------------------------------- m4_defun([_LT_COMPILER_NO_RTTI], [m4_require([_LT_TAG_COMPILER])dnl _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= if test yes = "$GCC"; then case $cc_basename in nvcc*) _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; *) _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' ;; esac _LT_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], lt_cv_prog_compiler_rtti_exceptions, [-fno-rtti -fno-exceptions], [], [_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) fi _LT_TAGDECL([no_builtin_flag], [lt_prog_compiler_no_builtin_flag], [1], [Compiler flag to turn off builtin functions]) ])# _LT_COMPILER_NO_RTTI # _LT_CMD_GLOBAL_SYMBOLS # ---------------------- m4_defun([_LT_CMD_GLOBAL_SYMBOLS], [AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_PROG_CC])dnl AC_REQUIRE([AC_PROG_AWK])dnl AC_REQUIRE([LT_PATH_NM])dnl AC_REQUIRE([LT_PATH_LD])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_TAG_COMPILER])dnl # Check for command to grab the raw symbol name followed by C symbol from nm. AC_MSG_CHECKING([command to parse $NM output from $compiler object]) AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], [ # These are sane defaults that work on at least a few old systems. # [They come from Ultrix. What could be older than Ultrix?!! ;)] # Character class describing NM global symbol codes. symcode='[[BCDEGRST]]' # Regexp to match symbols that can be accessed directly from C. sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' # Define system-specific variables. case $host_os in aix*) symcode='[[BCDT]]' ;; cygwin* | mingw* | pw32* | cegcc*) symcode='[[ABCDGISTW]]' ;; hpux*) if test ia64 = "$host_cpu"; then symcode='[[ABCDEGRST]]' fi ;; irix* | nonstopux*) symcode='[[BCDEGRST]]' ;; osf*) symcode='[[BCDEGQRST]]' ;; solaris*) symcode='[[BDRT]]' ;; sco3.2v5*) symcode='[[DT]]' ;; sysv4.2uw2*) symcode='[[DT]]' ;; sysv5* | sco5v6* | unixware* | OpenUNIX*) symcode='[[ABDT]]' ;; sysv4) symcode='[[DFNSTU]]' ;; esac # If we're using GNU nm, then use its standard symbol codes. case `$NM -V 2>&1` in *GNU* | *'with BFD'*) symcode='[[ABCDGIRSTW]]' ;; esac if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Gets list of data symbols to import. lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'" # Adjust the below global symbol transforms to fixup imported variables. lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" lt_c_name_lib_hook="\ -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\ -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'" else # Disable hooks by default. lt_cv_sys_global_symbol_to_import= lt_cdecl_hook= lt_c_name_hook= lt_c_name_lib_hook= fi # Transform an extracted symbol line into a proper C declaration. # Some systems (esp. on ia64) link data and code symbols differently, # so use this general approach. lt_cv_sys_global_symbol_to_cdecl="sed -n"\ $lt_cdecl_hook\ " -e 's/^T .* \(.*\)$/extern int \1();/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" # Transform an extracted symbol line into symbol name and symbol address lt_cv_sys_global_symbol_to_c_name_address="sed -n"\ $lt_c_name_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" # Transform an extracted symbol line into symbol name with lib prefix and # symbol address. lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\ $lt_c_name_lib_hook\ " -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ " -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ " -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'" # Handle CRLF in mingw tool chain opt_cr= case $build_os in mingw*) opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp ;; esac # Try without a prefix underscore, then with it. for ac_symprfx in "" "_"; do # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. symxfrm="\\1 $ac_symprfx\\2 \\2" # Write the raw and C identifiers. if test "$lt_cv_nm_interface" = "MS dumpbin"; then # Fake it for dumpbin and say T for any non-static function, # D for any global variable and I for any imported variable. # Also find C++ and __fastcall symbols from MSVC++, # which start with @ or ?. lt_cv_sys_global_symbol_pipe="$AWK ['"\ " {last_section=section; section=\$ 3};"\ " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ " /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\ " /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\ " /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\ " \$ 0!~/External *\|/{next};"\ " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ " {if(hide[section]) next};"\ " {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\ " {split(\$ 0,a,/\||\r/); split(a[2],s)};"\ " s[1]~/^[@?]/{print f,s[1],s[1]; next};"\ " s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ " ' prfx=^$ac_symprfx]" else lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" fi lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'" # Check to see that the pipe works correctly. pipe_works=no rm -f conftest* cat > conftest.$ac_ext <<_LT_EOF #ifdef __cplusplus extern "C" { #endif char nm_test_var; void nm_test_func(void); void nm_test_func(void){} #ifdef __cplusplus } #endif int main(){nm_test_var='a';nm_test_func();return(0);} _LT_EOF if AC_TRY_EVAL(ac_compile); then # Now try to grab the symbols. nlist=conftest.nm if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then # Try sorting and uniquifying the output. if sort "$nlist" | uniq > "$nlist"T; then mv -f "$nlist"T "$nlist" else rm -f "$nlist"T fi # Make sure that we snagged all the symbols we need. if $GREP ' nm_test_var$' "$nlist" >/dev/null; then if $GREP ' nm_test_func$' "$nlist" >/dev/null; then cat <<_LT_EOF > conftest.$ac_ext /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ #if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE /* DATA imports from DLLs on WIN32 can't be const, because runtime relocations are performed -- see ld's documentation on pseudo-relocs. */ # define LT@&t@_DLSYM_CONST #elif defined __osf__ /* This system does not cope well with relocations in const data. */ # define LT@&t@_DLSYM_CONST #else # define LT@&t@_DLSYM_CONST const #endif #ifdef __cplusplus extern "C" { #endif _LT_EOF # Now generate the symbol file. eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' cat <<_LT_EOF >> conftest.$ac_ext /* The mapping between symbol names and symbols. */ LT@&t@_DLSYM_CONST struct { const char *name; void *address; } lt__PROGRAM__LTX_preloaded_symbols[[]] = { { "@PROGRAM@", (void *) 0 }, _LT_EOF $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext cat <<\_LT_EOF >> conftest.$ac_ext {0, (void *) 0} }; /* This works around a problem in FreeBSD linker */ #ifdef FREEBSD_WORKAROUND static const void *lt_preloaded_setup() { return lt__PROGRAM__LTX_preloaded_symbols; } #endif #ifdef __cplusplus } #endif _LT_EOF # Now try linking the two files. mv conftest.$ac_objext conftstm.$ac_objext lt_globsym_save_LIBS=$LIBS lt_globsym_save_CFLAGS=$CFLAGS LIBS=conftstm.$ac_objext CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" if AC_TRY_EVAL(ac_link) && test -s conftest$ac_exeext; then pipe_works=yes fi LIBS=$lt_globsym_save_LIBS CFLAGS=$lt_globsym_save_CFLAGS else echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD fi else echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD fi else echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD fi else echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD cat conftest.$ac_ext >&5 fi rm -rf conftest* conftst* # Do not use the global_symbol_pipe unless it works. if test yes = "$pipe_works"; then break else lt_cv_sys_global_symbol_pipe= fi done ]) if test -z "$lt_cv_sys_global_symbol_pipe"; then lt_cv_sys_global_symbol_to_cdecl= fi if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then AC_MSG_RESULT(failed) else AC_MSG_RESULT(ok) fi # Response file support. if test "$lt_cv_nm_interface" = "MS dumpbin"; then nm_file_list_spec='@' elif $NM --help 2>/dev/null | grep '[[@]]FILE' >/dev/null; then nm_file_list_spec='@' fi _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], [Take the output of nm and produce a listing of raw symbols and C names]) _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], [Transform the output of nm in a proper C declaration]) _LT_DECL([global_symbol_to_import], [lt_cv_sys_global_symbol_to_import], [1], [Transform the output of nm into a list of symbols to manually relocate]) _LT_DECL([global_symbol_to_c_name_address], [lt_cv_sys_global_symbol_to_c_name_address], [1], [Transform the output of nm in a C name address pair]) _LT_DECL([global_symbol_to_c_name_address_lib_prefix], [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], [Transform the output of nm in a C name address pair when lib prefix is needed]) _LT_DECL([nm_interface], [lt_cv_nm_interface], [1], [The name lister interface]) _LT_DECL([], [nm_file_list_spec], [1], [Specify filename containing input files for $NM]) ]) # _LT_CMD_GLOBAL_SYMBOLS # _LT_COMPILER_PIC([TAGNAME]) # --------------------------- m4_defun([_LT_COMPILER_PIC], [m4_require([_LT_TAG_COMPILER])dnl _LT_TAGVAR(lt_prog_compiler_wl, $1)= _LT_TAGVAR(lt_prog_compiler_pic, $1)= _LT_TAGVAR(lt_prog_compiler_static, $1)= m4_if([$1], [CXX], [ # C++ specific cases for pic, static, wl, etc. if test yes = "$GXX"; then _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' case $host_os in aix*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; m68k) # FIXME: we need at least 68020 code to build shared libraries, but # adding the '-m68020' flag to GCC prevents building anything better, # like '-m68040'. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' ;; esac ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | os2* | pw32* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) case $host_os in os2*) _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' ;; esac ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' ;; *djgpp*) # DJGPP does not support shared libraries at all _LT_TAGVAR(lt_prog_compiler_pic, $1)= ;; haiku*) # PIC is the default for Haiku. # The "-static" flag exists, but is broken. _LT_TAGVAR(lt_prog_compiler_static, $1)= ;; interix[[3-9]]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; sysv4*MP*) if test -d /usr/nec; then _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic fi ;; hpux*) # PIC is the default for 64-bit PA HP-UX, but not for 32-bit # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag # sets the default TLS model and affects inlining. case $host_cpu in hppa*64*) ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac ;; *qnx* | *nto*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac else case $host_os in aix[[4-9]]*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' else _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' fi ;; chorus*) case $cc_basename in cxch68*) # Green Hills C++ Compiler # _LT_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" ;; esac ;; mingw* | cygwin* | os2* | pw32* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) ;; dgux*) case $cc_basename in ec++*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' ;; ghcx*) # Green Hills C++ Compiler _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' ;; *) ;; esac ;; freebsd* | dragonfly*) # FreeBSD uses GNU C++ ;; hpux9* | hpux10* | hpux11*) case $cc_basename in CC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' if test ia64 != "$host_cpu"; then _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' fi ;; aCC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' ;; esac ;; *) ;; esac ;; interix*) # This is c89, which is MS Visual C++ (no shared libs) # Anyone wants to do a port? ;; irix5* | irix6* | nonstopux*) case $cc_basename in CC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' # CC pic flag -KPIC is the default. ;; *) ;; esac ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in KCC*) # KAI C++ Compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; ecpc* ) # old Intel C++ for x86_64, which still supported -KPIC. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; icpc* ) # Intel C++, used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; pgCC* | pgcpp*) # Portland Group C++ compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; cxx*) # Compaq C++ # Make sure the PIC flag is empty. It appears that all Alpha # Linux and Compaq Tru64 Unix objects are PIC. _LT_TAGVAR(lt_prog_compiler_pic, $1)= _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; xlc* | xlC* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL 8.0, 9.0 on PPC and BlueGene _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C++ 5.9 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' ;; esac ;; esac ;; lynxos*) ;; m88k*) ;; mvs*) case $cc_basename in cxx*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' ;; *) ;; esac ;; netbsd*) ;; *qnx* | *nto*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' ;; osf3* | osf4* | osf5*) case $cc_basename in KCC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' ;; RCC*) # Rational C++ 2.4.1 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' ;; cxx*) # Digital/Compaq C++ _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # Make sure the PIC flag is empty. It appears that all Alpha # Linux and Compaq Tru64 Unix objects are PIC. _LT_TAGVAR(lt_prog_compiler_pic, $1)= _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; *) ;; esac ;; psos*) ;; solaris*) case $cc_basename in CC* | sunCC*) # Sun C++ 4.2, 5.x and Centerline C++ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' ;; gcx*) # Green Hills C++ Compiler _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' ;; *) ;; esac ;; sunos4*) case $cc_basename in CC*) # Sun C++ 4.x _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; lcc*) # Lucid _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' ;; *) ;; esac ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) case $cc_basename in CC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; esac ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' ;; *) ;; esac ;; vxworks*) ;; *) _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; esac fi ], [ if test yes = "$GCC"; then _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' case $host_os in aix*) # All AIX code is PIC. if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; m68k) # FIXME: we need at least 68020 code to build shared libraries, but # adding the '-m68020' flag to GCC prevents building anything better, # like '-m68040'. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' ;; esac ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) case $host_os in os2*) _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' ;; esac ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' ;; haiku*) # PIC is the default for Haiku. # The "-static" flag exists, but is broken. _LT_TAGVAR(lt_prog_compiler_static, $1)= ;; hpux*) # PIC is the default for 64-bit PA HP-UX, but not for 32-bit # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag # sets the default TLS model and affects inlining. case $host_cpu in hppa*64*) # +Z the default ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac ;; interix[[3-9]]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; msdosdjgpp*) # Just because we use GCC doesn't mean we suddenly get shared libraries # on systems that don't support them. _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no enable_shared=no ;; *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' ;; sysv4*MP*) if test -d /usr/nec; then _LT_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic fi ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac case $cc_basename in nvcc*) # Cuda Compiler Driver 2.2 _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Xlinker ' if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then _LT_TAGVAR(lt_prog_compiler_pic, $1)="-Xcompiler $_LT_TAGVAR(lt_prog_compiler_pic, $1)" fi ;; esac else # PORTME Check for flag to pass linker flags through the system compiler. case $host_os in aix*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' else _LT_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' fi ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' case $cc_basename in nagfor*) # NAG Fortran compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; esac ;; mingw* | cygwin* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) case $host_os in os2*) _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' ;; esac ;; hpux9* | hpux10* | hpux11*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' ;; esac # Is there a better lt_prog_compiler_static that works with the bundled CC? _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' ;; irix5* | irix6* | nonstopux*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # PIC (with -KPIC) is the default. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in # old Intel for x86_64, which still supported -KPIC. ecc*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; # icc used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. icc* | ifort*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; # Lahey Fortran 8.1. lf95*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='--shared' _LT_TAGVAR(lt_prog_compiler_static, $1)='--static' ;; nagfor*) # NAG Fortran compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; tcc*) # Fabrice Bellard et al's Tiny C Compiler _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; ccc*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # All Alpha code is PIC. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; xl* | bgxl* | bgf* | mpixl*) # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-qpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-qstaticlink' ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [[1-7]].* | *Sun*Fortran*\ 8.[[0-3]]*) # Sun Fortran 8.3 passes all unrecognized flags to the linker _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='' ;; *Sun\ F* | *Sun*Fortran*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' ;; *Sun\ C*) # Sun C 5.9 _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' ;; *Intel*\ [[CF]]*Compiler*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; *Portland\ Group*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; esac ;; esac ;; newsos6) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; *nto* | *qnx*) # QNX uses GNU C++, but need to define -shared option too, otherwise # it will coredump. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC -shared' ;; osf3* | osf4* | osf5*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # All OSF/1 code is PIC. _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; rdos*) _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; solaris*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' case $cc_basename in f77* | f90* | f95* | sunf77* | sunf90* | sunf95*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; *) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; esac ;; sunos4*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; sysv4 | sysv4.2uw2* | sysv4.3*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; sysv4*MP*) if test -d /usr/nec; then _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; unicos*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; uts4*) _LT_TAGVAR(lt_prog_compiler_pic, $1)='-pic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; *) _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; esac fi ]) case $host_os in # For platforms that do not support PIC, -DPIC is meaningless: *djgpp*) _LT_TAGVAR(lt_prog_compiler_pic, $1)= ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])" ;; esac AC_CACHE_CHECK([for $compiler option to produce PIC], [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)], [_LT_TAGVAR(lt_cv_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_prog_compiler_pic, $1)]) _LT_TAGVAR(lt_prog_compiler_pic, $1)=$_LT_TAGVAR(lt_cv_prog_compiler_pic, $1) # # Check to make sure the PIC flag actually works. # if test -n "$_LT_TAGVAR(lt_prog_compiler_pic, $1)"; then _LT_COMPILER_OPTION([if $compiler PIC flag $_LT_TAGVAR(lt_prog_compiler_pic, $1) works], [_LT_TAGVAR(lt_cv_prog_compiler_pic_works, $1)], [$_LT_TAGVAR(lt_prog_compiler_pic, $1)@&t@m4_if([$1],[],[ -DPIC],[m4_if([$1],[CXX],[ -DPIC],[])])], [], [case $_LT_TAGVAR(lt_prog_compiler_pic, $1) in "" | " "*) ;; *) _LT_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_TAGVAR(lt_prog_compiler_pic, $1)" ;; esac], [_LT_TAGVAR(lt_prog_compiler_pic, $1)= _LT_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) fi _LT_TAGDECL([pic_flag], [lt_prog_compiler_pic], [1], [Additional compiler flags for building library objects]) _LT_TAGDECL([wl], [lt_prog_compiler_wl], [1], [How to pass a linker flag through the compiler]) # # Check to make sure the static flag actually works. # wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_TAGVAR(lt_prog_compiler_static, $1)\" _LT_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], _LT_TAGVAR(lt_cv_prog_compiler_static_works, $1), $lt_tmp_static_flag, [], [_LT_TAGVAR(lt_prog_compiler_static, $1)=]) _LT_TAGDECL([link_static_flag], [lt_prog_compiler_static], [1], [Compiler flag to prevent dynamic linking]) ])# _LT_COMPILER_PIC # _LT_LINKER_SHLIBS([TAGNAME]) # ---------------------------- # See if the linker supports building shared libraries. m4_defun([_LT_LINKER_SHLIBS], [AC_REQUIRE([LT_PATH_LD])dnl AC_REQUIRE([LT_PATH_NM])dnl m4_require([_LT_PATH_MANIFEST_TOOL])dnl m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl m4_require([_LT_TAG_COMPILER])dnl AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) m4_if([$1], [CXX], [ _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] case $host_os in aix[[4-9]]*) # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to GNU nm, but means don't demangle to AIX nm. # Without the "-l" option, or with the "-B" option, AIX nm treats # weak defined symbols like other global defined symbols, whereas # GNU nm marks them as "W". # While the 'weak' keyword is ignored in the Export File, we need # it in the Import File for the 'aix-soname' feature, so we have # to replace the "-B" option with "-P" for AIX nm. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi ;; pw32*) _LT_TAGVAR(export_symbols_cmds, $1)=$ltdll_cmds ;; cygwin* | mingw* | cegcc*) case $cc_basename in cl*) _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' ;; *) _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] ;; esac ;; *) _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' ;; esac ], [ runpath_var= _LT_TAGVAR(allow_undefined_flag, $1)= _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(archive_cmds, $1)= _LT_TAGVAR(archive_expsym_cmds, $1)= _LT_TAGVAR(compiler_needs_object, $1)=no _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' _LT_TAGVAR(hardcode_automatic, $1)=no _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(hardcode_libdir_separator, $1)= _LT_TAGVAR(hardcode_minus_L, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported _LT_TAGVAR(inherit_rpath, $1)=no _LT_TAGVAR(link_all_deplibs, $1)=unknown _LT_TAGVAR(module_cmds, $1)= _LT_TAGVAR(module_expsym_cmds, $1)= _LT_TAGVAR(old_archive_from_new_cmds, $1)= _LT_TAGVAR(old_archive_from_expsyms_cmds, $1)= _LT_TAGVAR(thread_safe_flag_spec, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= # include_expsyms should be a list of space-separated symbols to be *always* # included in the symbol list _LT_TAGVAR(include_expsyms, $1)= # exclude_expsyms can be an extended regexp of symbols to exclude # it will be wrapped by ' (' and ')$', so one must not match beginning or # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc', # as well as any symbol that contains 'd'. _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out # platforms (ab)use it in PIC code, but their linkers get confused if # the symbol is explicitly referenced. Since portable code cannot # rely on this symbol name, it's probably fine to never include it in # preloaded symbol tables. # Exclude shared library initialization/finalization symbols. dnl Note also adjust exclude_expsyms for C++ above. extract_expsyms_cmds= case $host_os in cygwin* | mingw* | pw32* | cegcc*) # FIXME: the MSVC++ port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using # Microsoft Visual C++. if test yes != "$GCC"; then with_gnu_ld=no fi ;; interix*) # we just hope/assume this is gcc and not c89 (= MSVC++) with_gnu_ld=yes ;; openbsd* | bitrig*) with_gnu_ld=no ;; esac _LT_TAGVAR(ld_shlibs, $1)=yes # On some targets, GNU ld is compatible enough with the native linker # that we're better off using the native interface for both. lt_use_gnu_ld_interface=no if test yes = "$with_gnu_ld"; then case $host_os in aix*) # The AIX port of GNU ld has always aspired to compatibility # with the native linker. However, as the warning in the GNU ld # block says, versions before 2.19.5* couldn't really create working # shared libraries, regardless of the interface used. case `$LD -v 2>&1` in *\ \(GNU\ Binutils\)\ 2.19.5*) ;; *\ \(GNU\ Binutils\)\ 2.[[2-9]]*) ;; *\ \(GNU\ Binutils\)\ [[3-9]]*) ;; *) lt_use_gnu_ld_interface=yes ;; esac ;; *) lt_use_gnu_ld_interface=yes ;; esac fi if test yes = "$lt_use_gnu_ld_interface"; then # If archive_cmds runs LD, not CC, wlarc should be empty wlarc='$wl' # Set some defaults for GNU ld with shared library support. These # are reset later if shared libraries are not supported. Putting them # here allows them to be overridden if necessary. runpath_var=LD_RUN_PATH _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' # ancient GNU ld didn't support --whole-archive et. al. if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else _LT_TAGVAR(whole_archive_flag_spec, $1)= fi supports_anon_versioning=no case `$LD -v | $SED -e 's/([^)]\+)\s\+//' 2>&1` in *GNU\ gold*) supports_anon_versioning=yes ;; *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... *\ 2.11.*) ;; # other 2.11 versions *) supports_anon_versioning=yes ;; esac # See if GNU ld supports shared libraries. case $host_os in aix[[3-9]]*) # On AIX/PPC, the GNU linker is very broken if test ia64 != "$host_cpu"; then _LT_TAGVAR(ld_shlibs, $1)=no cat <<_LT_EOF 1>&2 *** Warning: the GNU linker, at least up to release 2.19, is reported *** to be unable to reliably create shared libraries on AIX. *** Therefore, libtool is disabling shared libraries support. If you *** really care for shared libraries, you may want to install binutils *** 2.20 or above, or modify your PATH so that a non-GNU linker is found. *** You will then need to restart the configuration process. _LT_EOF fi ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='' ;; m68k) _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes ;; esac ;; beos*) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(allow_undefined_flag, $1)=unsupported # Joseph Beckenbach <jrb3@best.com> says some releases of gcc # support --undefined. This deserves some investigation. FIXME _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; cygwin* | mingw* | pw32* | cegcc*) # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, # as there is no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.* //'\'' | sort | uniq > $export_symbols' _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file, use it as # is; otherwise, prepend EXPORTS... _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; haiku*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(link_all_deplibs, $1)=yes ;; os2*) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported shrext_cmds=.dll _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes ;; interix[[3-9]]*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) tmp_diet=no if test linux-dietlibc = "$host_os"; then case $cc_basename in diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) esac fi if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ && test no = "$tmp_diet" then tmp_addflag=' $pic_flag' tmp_sharedflag='-shared' case $cc_basename,$host_cpu in pgcc*) # Portland Group C compiler _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag' ;; pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group f77 and f90 compilers _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 tmp_addflag=' -i_dynamic -nofor_main' ;; ifc* | ifort*) # Intel Fortran compiler tmp_addflag=' -nofor_main' ;; lf95*) # Lahey Fortran 8.1 _LT_TAGVAR(whole_archive_flag_spec, $1)= tmp_sharedflag='--shared' ;; nagfor*) # NAGFOR 5.3 tmp_sharedflag='-Wl,-shared' ;; xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) tmp_sharedflag='-qmkshrobj' tmp_addflag= ;; nvcc*) # Cuda Compiler Driver 2.2 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes ;; esac case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C 5.9 _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 tmp_sharedflag='-G' ;; esac _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi case $cc_basename in tcc*) _LT_TAGVAR(export_dynamic_flag_spec, $1)='-rdynamic' ;; xlf* | bgf* | bgxlf* | mpixlf*) # IBM XL Fortran 10.1 on PPC cannot create shared libs itself _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' fi ;; esac else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= else _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' fi ;; solaris*) if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then _LT_TAGVAR(ld_shlibs, $1)=no cat <<_LT_EOF 1>&2 *** Warning: The releases 2.8.* of the GNU linker cannot reliably *** create shared libraries on Solaris systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.9.1 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) case `$LD -v 2>&1` in *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) _LT_TAGVAR(ld_shlibs, $1)=no cat <<_LT_EOF 1>&2 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot *** reliably create shared libraries on SCO systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.16.91.0.3 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF ;; *) # For security reasons, it is highly recommended that you always # use absolute paths for naming shared libraries, and exclude the # DT_RUNPATH tag from executables and libraries. But doing so # requires that you compile everything twice, which is a pain. if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; sunos4*) _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' wlarc= _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac if test no = "$_LT_TAGVAR(ld_shlibs, $1)"; then runpath_var= _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= fi else # PORTME fill in a description of your system's linker (not GNU ld) case $host_os in aix3*) _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=yes _LT_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' # Note: this linker hardcodes the directories in LIBPATH if there # are no directories specified by -L. _LT_TAGVAR(hardcode_minus_L, $1)=yes if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. _LT_TAGVAR(hardcode_direct, $1)=unsupported fi ;; aix[[4-9]]*) if test ia64 = "$host_cpu"; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag= else # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to GNU nm, but means don't demangle to AIX nm. # Without the "-l" option, or with the "-B" option, AIX nm treats # weak defined symbols like other global defined symbols, whereas # GNU nm marks them as "W". # While the 'weak' keyword is ignored in the Export File, we need # it in the Import File for the 'aix-soname' feature, so we have # to replace the "-B" option with "-P" for AIX nm. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # have runtime linking enabled, and use it for executables. # For shared libraries, we enable/disable runtime linking # depending on the kind of the shared library created - # when "with_aix_soname,aix_use_runtimelinking" is: # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables # "aix,yes" lib.so shared, rtl:yes, for executables # lib.a static archive # "both,no" lib.so.V(shr.o) shared, rtl:yes # lib.a(lib.so.V) shared, rtl:no, for executables # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a(lib.so.V) shared, rtl:no # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a static archive case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) for ld_flag in $LDFLAGS; do if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then aix_use_runtimelinking=yes break fi done if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then # With aix-soname=svr4, we create the lib.so.V shared archives only, # so we don't have lib.a shared libs to link our executables. # We have to force runtime linking in this case. aix_use_runtimelinking=yes LDFLAGS="$LDFLAGS -Wl,-brtl" fi ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. _LT_TAGVAR(archive_cmds, $1)='' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(file_list_spec, $1)='$wl-f,' case $with_aix_soname,$aix_use_runtimelinking in aix,*) ;; # traditional, no import file svr4,* | *,yes) # use import file # The Import File defines what to hardcode. _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no ;; esac if test yes = "$GCC"; then case $host_os in aix4.[[012]]|aix4.[[012]].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`$CC -print-prog-name=collect2` if test -f "$collect2name" && strings "$collect2name" | $GREP resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 _LT_TAGVAR(hardcode_direct, $1)=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)= fi ;; esac shared_flag='-shared' if test yes = "$aix_use_runtimelinking"; then shared_flag="$shared_flag "'$wl-G' fi # Need to ensure runtime linking is disabled for the traditional # shared library, or the linker may eventually find shared libraries # /with/ Import File - we do not want to mix them. shared_flag_aix='-shared' shared_flag_svr4='-shared $wl-G' else # not using gcc if test ia64 = "$host_cpu"; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test yes = "$aix_use_runtimelinking"; then shared_flag='$wl-G' else shared_flag='$wl-bM:SRE' fi shared_flag_aix='$wl-bM:SRE' shared_flag_svr4='$wl-G' fi fi _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. _LT_TAGVAR(always_export_symbols, $1)=yes if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. _LT_TAGVAR(allow_undefined_flag, $1)='-berok' # Determine the default libpath from the value encoded in an # empty executable. _LT_SYS_MODULE_PATH_AIX([$1]) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag else if test ia64 = "$host_cpu"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an # empty executable. _LT_SYS_MODULE_PATH_AIX([$1]) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' if test yes = "$with_gnu_ld"; then # We only use this code for GNU lds that support --whole-archive. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' else # Exported symbols can be pulled into shared objects from archives _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' fi _LT_TAGVAR(archive_cmds_need_lc, $1)=yes _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' # -brtl affects multiple linker settings, -berok does not and is overridden later compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' if test svr4 != "$with_aix_soname"; then # This is similar to how AIX traditionally builds its shared libraries. _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' fi if test aix != "$with_aix_soname"; then _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' else # used by -dlpreopen to get the symbols _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' fi _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' fi fi ;; amigaos*) case $host_cpu in powerpc) # see comment about AmigaOS4 .so support _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='' ;; m68k) _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes ;; esac ;; bsdi[[45]]*) _LT_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic ;; cygwin* | mingw* | pw32* | cegcc*) # When not using gcc, we currently assume that we are using # Microsoft Visual C++. # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. case $cc_basename in cl*) # Native MSVC _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=yes _LT_TAGVAR(file_list_spec, $1)='@' # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then cp "$export_symbols" "$output_objdir/$soname.def"; echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; else $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; fi~ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_TAGVAR(exclude_expsyms, $1)='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*' _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1,DATA/'\'' | $SED -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' # Don't use ranlib _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ lt_tool_outputfile="@TOOL_OUTPUT@"~ case $lt_outputfile in *.exe|*.EXE) ;; *) lt_outputfile=$lt_outputfile.exe lt_tool_outputfile=$lt_tool_outputfile.exe ;; esac~ if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; $RM "$lt_outputfile.manifest"; fi' ;; *) # Assume MSVC wrapper _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' # The linker will automatically build a .lib file if we build a DLL. _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' # FIXME: Should let the user specify the lib program. _LT_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes ;; esac ;; darwin* | rhapsody*) _LT_DARWIN_LINKER_FEATURES($1) ;; dgux*) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor # support. Future versions do this automatically, but an explicit c++rt0.o # does not break anything, and helps significantly (at the cost of a little # extra space). freebsd2.2*) _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; # Unfortunately, older versions of FreeBSD 2 do not have this feature. freebsd2.*) _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. freebsd* | dragonfly*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; hpux9*) if test yes = "$GCC"; then _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' else _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(hardcode_direct, $1)=yes # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' ;; hpux10*) if test yes,no = "$GCC,$with_gnu_ld"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi if test no = "$with_gnu_ld"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_TAGVAR(hardcode_minus_L, $1)=yes fi ;; hpux11*) if test yes,no = "$GCC,$with_gnu_ld"; then case $host_cpu in hppa*64*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else case $host_cpu in hppa*64*) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) m4_if($1, [], [ # Older versions of the 11.00 compiler do not understand -b yet # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) _LT_LINKER_OPTION([if $CC understands -b], _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) ;; esac fi if test no = "$with_gnu_ld"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: case $host_cpu in hppa*64*|ia64*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_TAGVAR(hardcode_minus_L, $1)=yes ;; esac fi ;; irix5* | irix6* | nonstopux*) if test yes = "$GCC"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' # Try to use the -exported_symbol ld option, if it does not # work, assume that -exports_file does not work either and # implicitly export all symbols. # This should be the same for all languages, so no per-tag cache variable. AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], [lt_cv_irix_exported_symbol], [save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" AC_LINK_IFELSE( [AC_LANG_SOURCE( [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], [C++], [[int foo (void) { return 0; }]], [Fortran 77], [[ subroutine foo end]], [Fortran], [[ subroutine foo end]])])], [lt_cv_irix_exported_symbol=yes], [lt_cv_irix_exported_symbol=no]) LDFLAGS=$save_LDFLAGS]) if test yes = "$lt_cv_irix_exported_symbol"; then _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' fi else _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' fi _LT_TAGVAR(archive_cmds_need_lc, $1)='no' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(inherit_rpath, $1)=yes _LT_TAGVAR(link_all_deplibs, $1)=yes ;; linux*) case $cc_basename in tcc*) # Fabrice Bellard et al's Tiny C Compiler _LT_TAGVAR(ld_shlibs, $1)=yes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else _LT_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; newsos6) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *nto* | *qnx*) ;; openbsd* | bitrig*) if test -f /usr/libexec/ld.so; then _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=yes if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' else _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' fi else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; os2*) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported shrext_cmds=.dll _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes ;; osf3*) if test yes = "$GCC"; then _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' else _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' fi _LT_TAGVAR(archive_cmds_need_lc, $1)='no' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: ;; osf4* | osf5*) # as osf3* with the addition of -msym flag if test yes = "$GCC"; then _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' else _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp' # Both c and cxx compiler support -rpath directly _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' fi _LT_TAGVAR(archive_cmds_need_lc, $1)='no' _LT_TAGVAR(hardcode_libdir_separator, $1)=: ;; solaris*) _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' if test yes = "$GCC"; then wlarc='$wl' _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' else case `$CC -V 2>&1` in *"Compilers 5.0"*) wlarc='' _LT_TAGVAR(archive_cmds, $1)='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' ;; *) wlarc='$wl' _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' ;; esac fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no case $host_os in solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands '-z linker_flag'. GCC discards it without '$wl', # but is careful enough not to reorder. # Supported since Solaris 2.6 (maybe 2.5.1?) if test yes = "$GCC"; then _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' else _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' fi ;; esac _LT_TAGVAR(link_all_deplibs, $1)=yes ;; sunos4*) if test sequent = "$host_vendor"; then # Use $CC to link under sequent, because it throws in some extra .o # files that make .init and .fini sections work. _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; sysv4) case $host_vendor in sni) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=yes # is this really true??? ;; siemens) ## LD is ld it makes a PLAMLIB ## CC just makes a GrossModule. _LT_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' _LT_TAGVAR(hardcode_direct, $1)=no ;; motorola) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie ;; esac runpath_var='LD_RUN_PATH' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; sysv4.3*) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' ;; sysv4*MP*) if test -d /usr/nec; then _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var=LD_RUN_PATH hardcode_runpath_var=yes _LT_TAGVAR(ld_shlibs, $1)=yes fi ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var='LD_RUN_PATH' if test yes = "$GCC"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We CANNOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' runpath_var='LD_RUN_PATH' if test yes = "$GCC"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; uts4*) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) _LT_TAGVAR(ld_shlibs, $1)=no ;; esac if test sni = "$host_vendor"; then case $host in sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Blargedynsym' ;; esac fi fi ]) AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no _LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld _LT_DECL([], [libext], [0], [Old archive suffix (normally "a")])dnl _LT_DECL([], [shrext_cmds], [1], [Shared library suffix (normally ".so")])dnl _LT_DECL([], [extract_expsyms_cmds], [2], [The commands to extract the exported symbol list from a shared archive]) # # Do we need to explicitly link libc? # case "x$_LT_TAGVAR(archive_cmds_need_lc, $1)" in x|xyes) # Assume -lc should be added _LT_TAGVAR(archive_cmds_need_lc, $1)=yes if test yes,yes = "$GCC,$enable_shared"; then case $_LT_TAGVAR(archive_cmds, $1) in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. AC_CACHE_CHECK([whether -lc should be explicitly linked in], [lt_cv_]_LT_TAGVAR(archive_cmds_need_lc, $1), [$RM conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if AC_TRY_EVAL(ac_compile) 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$_LT_TAGVAR(lt_prog_compiler_wl, $1) pic_flag=$_LT_TAGVAR(lt_prog_compiler_pic, $1) compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$_LT_TAGVAR(allow_undefined_flag, $1) _LT_TAGVAR(allow_undefined_flag, $1)= if AC_TRY_EVAL(_LT_TAGVAR(archive_cmds, $1) 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) then lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=no else lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1)=yes fi _LT_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $RM conftest* ]) _LT_TAGVAR(archive_cmds_need_lc, $1)=$lt_cv_[]_LT_TAGVAR(archive_cmds_need_lc, $1) ;; esac fi ;; esac _LT_TAGDECL([build_libtool_need_lc], [archive_cmds_need_lc], [0], [Whether or not to add -lc for building shared libraries]) _LT_TAGDECL([allow_libtool_libs_with_static_runtimes], [enable_shared_with_static_runtimes], [0], [Whether or not to disallow shared libs when runtime libs are static]) _LT_TAGDECL([], [export_dynamic_flag_spec], [1], [Compiler flag to allow reflexive dlopens]) _LT_TAGDECL([], [whole_archive_flag_spec], [1], [Compiler flag to generate shared objects directly from archives]) _LT_TAGDECL([], [compiler_needs_object], [1], [Whether the compiler copes with passing no objects directly]) _LT_TAGDECL([], [old_archive_from_new_cmds], [2], [Create an old-style archive from a shared archive]) _LT_TAGDECL([], [old_archive_from_expsyms_cmds], [2], [Create a temporary old-style archive to link instead of a shared archive]) _LT_TAGDECL([], [archive_cmds], [2], [Commands used to build a shared archive]) _LT_TAGDECL([], [archive_expsym_cmds], [2]) _LT_TAGDECL([], [module_cmds], [2], [Commands used to build a loadable module if different from building a shared archive.]) _LT_TAGDECL([], [module_expsym_cmds], [2]) _LT_TAGDECL([], [with_gnu_ld], [1], [Whether we are building with GNU ld or not]) _LT_TAGDECL([], [allow_undefined_flag], [1], [Flag that allows shared libraries with undefined symbols to be built]) _LT_TAGDECL([], [no_undefined_flag], [1], [Flag that enforces no undefined symbols]) _LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], [Flag to hardcode $libdir into a binary during linking. This must work even if $libdir does not exist]) _LT_TAGDECL([], [hardcode_libdir_separator], [1], [Whether we need a single "-rpath" flag with a separated argument]) _LT_TAGDECL([], [hardcode_direct], [0], [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes DIR into the resulting binary]) _LT_TAGDECL([], [hardcode_direct_absolute], [0], [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes DIR into the resulting binary and the resulting library dependency is "absolute", i.e impossible to change by setting $shlibpath_var if the library is relocated]) _LT_TAGDECL([], [hardcode_minus_L], [0], [Set to "yes" if using the -LDIR flag during linking hardcodes DIR into the resulting binary]) _LT_TAGDECL([], [hardcode_shlibpath_var], [0], [Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into the resulting binary]) _LT_TAGDECL([], [hardcode_automatic], [0], [Set to "yes" if building a shared library automatically hardcodes DIR into the library and all subsequent libraries and executables linked against it]) _LT_TAGDECL([], [inherit_rpath], [0], [Set to yes if linker adds runtime paths of dependent libraries to runtime path list]) _LT_TAGDECL([], [link_all_deplibs], [0], [Whether libtool must link a program against all its dependency libraries]) _LT_TAGDECL([], [always_export_symbols], [0], [Set to "yes" if exported symbols are required]) _LT_TAGDECL([], [export_symbols_cmds], [2], [The commands to list exported symbols]) _LT_TAGDECL([], [exclude_expsyms], [1], [Symbols that should not be listed in the preloaded symbols]) _LT_TAGDECL([], [include_expsyms], [1], [Symbols that must always be exported]) _LT_TAGDECL([], [prelink_cmds], [2], [Commands necessary for linking programs (against libraries) with templates]) _LT_TAGDECL([], [postlink_cmds], [2], [Commands necessary for finishing linking programs]) _LT_TAGDECL([], [file_list_spec], [1], [Specify filename containing input files]) dnl FIXME: Not yet implemented dnl _LT_TAGDECL([], [thread_safe_flag_spec], [1], dnl [Compiler flag to generate thread safe objects]) ])# _LT_LINKER_SHLIBS # _LT_LANG_C_CONFIG([TAG]) # ------------------------ # Ensure that the configuration variables for a C compiler are suitably # defined. These variables are subsequently used by _LT_CONFIG to write # the compiler configuration to 'libtool'. m4_defun([_LT_LANG_C_CONFIG], [m4_require([_LT_DECL_EGREP])dnl lt_save_CC=$CC AC_LANG_PUSH(C) # Source file extension for C test sources. ac_ext=c # Object file extension for compiled C test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(){return(0);}' _LT_TAG_COMPILER # Save the default compiler, since it gets overwritten when the other # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. compiler_DEFAULT=$CC # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... if test -n "$compiler"; then _LT_COMPILER_NO_RTTI($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_SYS_DYNAMIC_LINKER($1) _LT_LINKER_HARDCODE_LIBPATH($1) LT_SYS_DLOPEN_SELF _LT_CMD_STRIPLIB # Report what library types will actually be built AC_MSG_CHECKING([if libtool supports shared libraries]) AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[[4-9]]*) if test ia64 != "$host_cpu"; then case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in yes,aix,yes) ;; # shared object as lib.so file only yes,svr4,*) ;; # shared object as lib.so archive member only yes,*) enable_static=no ;; # shared object in lib.a archive as well esac fi ;; esac AC_MSG_RESULT([$enable_shared]) AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. test yes = "$enable_shared" || enable_static=yes AC_MSG_RESULT([$enable_static]) _LT_CONFIG($1) fi AC_LANG_POP CC=$lt_save_CC ])# _LT_LANG_C_CONFIG # _LT_LANG_CXX_CONFIG([TAG]) # -------------------------- # Ensure that the configuration variables for a C++ compiler are suitably # defined. These variables are subsequently used by _LT_CONFIG to write # the compiler configuration to 'libtool'. m4_defun([_LT_LANG_CXX_CONFIG], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_PATH_MANIFEST_TOOL])dnl if test -n "$CXX" && ( test no != "$CXX" && ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) || (test g++ != "$CXX"))); then AC_PROG_CXXCPP else _lt_caught_CXX_error=yes fi AC_LANG_PUSH(C++) _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(allow_undefined_flag, $1)= _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(archive_expsym_cmds, $1)= _LT_TAGVAR(compiler_needs_object, $1)=no _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(hardcode_libdir_separator, $1)= _LT_TAGVAR(hardcode_minus_L, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported _LT_TAGVAR(hardcode_automatic, $1)=no _LT_TAGVAR(inherit_rpath, $1)=no _LT_TAGVAR(module_cmds, $1)= _LT_TAGVAR(module_expsym_cmds, $1)= _LT_TAGVAR(link_all_deplibs, $1)=unknown _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds _LT_TAGVAR(no_undefined_flag, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no # Source file extension for C++ test sources. ac_ext=cpp # Object file extension for compiled C++ test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # No sense in running all these tests if we already determined that # the CXX compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. if test yes != "$_lt_caught_CXX_error"; then # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_LD=$LD lt_save_GCC=$GCC GCC=$GXX lt_save_with_gnu_ld=$with_gnu_ld lt_save_path_LD=$lt_cv_path_LD if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx else $as_unset lt_cv_prog_gnu_ld fi if test -n "${lt_cv_path_LDCXX+set}"; then lt_cv_path_LD=$lt_cv_path_LDCXX else $as_unset lt_cv_path_LD fi test -z "${LDCXX+set}" || LD=$LDCXX CC=${CXX-"c++"} CFLAGS=$CXXFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) if test -n "$compiler"; then # We don't want -fno-exception when compiling C++ code, so set the # no_builtin_flag separately if test yes = "$GXX"; then _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' else _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= fi if test yes = "$GXX"; then # Set up default GNU C++ configuration LT_PATH_LD # Check if GNU C++ uses GNU ld as the underlying linker, since the # archiving commands below assume that GNU ld is being used. if test yes = "$with_gnu_ld"; then _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' # If archive_cmds runs LD, not CC, wlarc should be empty # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to # investigate it a little bit more. (MM) wlarc='$wl' # ancient GNU ld didn't support --whole-archive et. al. if eval "`$CC -print-prog-name=ld` --help 2>&1" | $GREP 'no-whole-archive' > /dev/null; then _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else _LT_TAGVAR(whole_archive_flag_spec, $1)= fi else with_gnu_ld=no wlarc= # A generic and very simple default shared library creation # command for GNU C++ for the case where it uses the native # linker, instead of GNU ld. If possible, this setting should # overridden to take advantage of the native linker features on # the platform it is being used on. _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' fi # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' else GXX=no with_gnu_ld=no wlarc= fi # PORTME: fill in a description of your system's C++ link characteristics AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) _LT_TAGVAR(ld_shlibs, $1)=yes case $host_os in aix3*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; aix[[4-9]]*) if test ia64 = "$host_cpu"; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag= else aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # have runtime linking enabled, and use it for executables. # For shared libraries, we enable/disable runtime linking # depending on the kind of the shared library created - # when "with_aix_soname,aix_use_runtimelinking" is: # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables # "aix,yes" lib.so shared, rtl:yes, for executables # lib.a static archive # "both,no" lib.so.V(shr.o) shared, rtl:yes # lib.a(lib.so.V) shared, rtl:no, for executables # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a(lib.so.V) shared, rtl:no # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables # lib.a static archive case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) for ld_flag in $LDFLAGS; do case $ld_flag in *-brtl*) aix_use_runtimelinking=yes break ;; esac done if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then # With aix-soname=svr4, we create the lib.so.V shared archives only, # so we don't have lib.a shared libs to link our executables. # We have to force runtime linking in this case. aix_use_runtimelinking=yes LDFLAGS="$LDFLAGS -Wl,-brtl" fi ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. _LT_TAGVAR(archive_cmds, $1)='' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(file_list_spec, $1)='$wl-f,' case $with_aix_soname,$aix_use_runtimelinking in aix,*) ;; # no import file svr4,* | *,yes) # use import file # The Import File defines what to hardcode. _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no ;; esac if test yes = "$GXX"; then case $host_os in aix4.[[012]]|aix4.[[012]].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`$CC -print-prog-name=collect2` if test -f "$collect2name" && strings "$collect2name" | $GREP resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 _LT_TAGVAR(hardcode_direct, $1)=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)= fi esac shared_flag='-shared' if test yes = "$aix_use_runtimelinking"; then shared_flag=$shared_flag' $wl-G' fi # Need to ensure runtime linking is disabled for the traditional # shared library, or the linker may eventually find shared libraries # /with/ Import File - we do not want to mix them. shared_flag_aix='-shared' shared_flag_svr4='-shared $wl-G' else # not using gcc if test ia64 = "$host_cpu"; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test yes = "$aix_use_runtimelinking"; then shared_flag='$wl-G' else shared_flag='$wl-bM:SRE' fi shared_flag_aix='$wl-bM:SRE' shared_flag_svr4='$wl-G' fi fi _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to # export. _LT_TAGVAR(always_export_symbols, $1)=yes if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. # The "-G" linker flag allows undefined symbols. _LT_TAGVAR(no_undefined_flag, $1)='-bernotok' # Determine the default libpath from the value encoded in an empty # executable. _LT_SYS_MODULE_PATH_AIX([$1]) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag else if test ia64 = "$host_cpu"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an # empty executable. _LT_SYS_MODULE_PATH_AIX([$1]) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' if test yes = "$with_gnu_ld"; then # We only use this code for GNU lds that support --whole-archive. _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' else # Exported symbols can be pulled into shared objects from archives _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' fi _LT_TAGVAR(archive_cmds_need_lc, $1)=yes _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' # -brtl affects multiple linker settings, -berok does not and is overridden later compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' if test svr4 != "$with_aix_soname"; then # This is similar to how AIX traditionally builds its shared # libraries. Need -bnortl late, we may have -brtl in LDFLAGS. _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' fi if test aix != "$with_aix_soname"; then _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' else # used by -dlpreopen to get the symbols _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' fi _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' fi fi ;; beos*) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then _LT_TAGVAR(allow_undefined_flag, $1)=unsupported # Joseph Beckenbach <jrb3@best.com> says some releases of gcc # support --undefined. This deserves some investigation. FIXME _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; chorus*) case $cc_basename in *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; cygwin* | mingw* | pw32* | cegcc*) case $GXX,$cc_basename in ,cl* | no,cl*) # Native MSVC # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=yes _LT_TAGVAR(file_list_spec, $1)='@' # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then cp "$export_symbols" "$output_objdir/$soname.def"; echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; else $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; fi~ $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes # Don't use ranlib _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ lt_tool_outputfile="@TOOL_OUTPUT@"~ case $lt_outputfile in *.exe|*.EXE) ;; *) lt_outputfile=$lt_outputfile.exe lt_tool_outputfile=$lt_tool_outputfile.exe ;; esac~ func_to_tool_file "$lt_outputfile"~ if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; $RM "$lt_outputfile.manifest"; fi' ;; *) # g++ # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, # as there is no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file, use it as # is; otherwise, prepend EXPORTS... _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; darwin* | rhapsody*) _LT_DARWIN_LINKER_FEATURES($1) ;; os2*) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported shrext_cmds=.dll _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ $ECHO EXPORTS >> $output_objdir/$libname.def~ prefix_cmds="$SED"~ if test EXPORTS = "`$SED 1q $export_symbols`"; then prefix_cmds="$prefix_cmds -e 1d"; fi~ prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ emximp -o $lib $output_objdir/$libname.def' _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes ;; dgux*) case $cc_basename in ec++*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; ghcx*) # Green Hills C++ Compiler # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; freebsd2.*) # C++ shared libraries reported to be fairly broken before # switch to ELF _LT_TAGVAR(ld_shlibs, $1)=no ;; freebsd-elf*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; freebsd* | dragonfly*) # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF # conventions _LT_TAGVAR(ld_shlibs, $1)=yes ;; haiku*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(link_all_deplibs, $1)=yes ;; hpux9*) _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, # but as the default # location of the library. case $cc_basename in CC*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; aCC*) _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes = "$GXX"; then _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' else # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; hpux10*|hpux11*) if test no = "$with_gnu_ld"; then _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: case $host_cpu in hppa*64*|ia64*) ;; *) _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' ;; esac fi case $host_cpu in hppa*64*|ia64*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, # but as the default # location of the library. ;; esac case $cc_basename in CC*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; aCC*) case $host_cpu in hppa*64*) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes = "$GXX"; then if test no = "$with_gnu_ld"; then case $host_cpu in hppa*64*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac fi else # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; interix[[3-9]]*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; irix5* | irix6*) case $cc_basename in CC*) # SGI C++ _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' # Archives containing C++ object files must be created using # "CC -ar", where "CC" is the IRIX C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' ;; *) if test yes = "$GXX"; then if test no = "$with_gnu_ld"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' else _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib' fi fi _LT_TAGVAR(link_all_deplibs, $1)=yes ;; esac _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(inherit_rpath, $1)=yes ;; linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib $wl-retain-symbols-file,$export_symbols; mv \$templib $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' # Archives containing C++ object files must be created using # "CC -Bstatic", where "CC" is the KAI C++ compiler. _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; icpc* | ecpc* ) # Intel C++ with_gnu_ld=yes # version 8.0 and above of icpc choke on multiply defined symbols # if we add $predep_objects and $postdep_objects, however 7.1 and # earlier do not add the objects themselves. case `$CC -V 2>&1` in *"Version 7."*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 8.0 or newer tmp_idyn= case $host_cpu in ia64*) tmp_idyn=' -i_dynamic';; esac _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; esac _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' ;; pgCC* | pgcpp*) # Portland Group C++ compiler case `$CC -V` in *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ $RANLIB $oldlib' _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ rm -rf $tpldir~ $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 6 and above use weak symbols _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; esac _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl--rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' ;; cxx*) # Compaq C++ _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib $wl-retain-symbols-file $wl$export_symbols' runpath_var=LD_RUN_PATH _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' ;; xl* | mpixl* | bgxl*) # IBM XL 8.0 on PPC, with GNU ld _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ echo "local: *; };" >> $output_objdir/$libname.ver~ $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C++ 5.9 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file $wl$export_symbols' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes # Not sure whether something based on # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 # would be better. output_verbose_link_cmd='func_echo_all' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' ;; esac ;; esac ;; lynxos*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; m88k*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; mvs*) case $cc_basename in cxx*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; netbsd*) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' wlarc= _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no fi # Workaround some broken pre-1.5 toolchains output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' ;; *nto* | *qnx*) _LT_TAGVAR(ld_shlibs, $1)=yes ;; openbsd* | bitrig*) if test -f /usr/libexec/ld.so; then _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file,$export_symbols -o $lib' _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' fi output_verbose_link_cmd=func_echo_all else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; osf3* | osf4* | osf5*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Archives containing C++ object files must be created using # the KAI C++ compiler. case $host in osf3*) _LT_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; *) _LT_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; esac ;; RCC*) # Rational C++ 2.4.1 # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; cxx*) case $host in osf3*) _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' ;; *) _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ echo "-hidden">> $lib.exp~ $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~ $RM $lib.exp' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' ;; esac _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) if test yes,no = "$GXX,$with_gnu_ld"; then _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' case $host in osf3*) _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' ;; esac _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' else # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; psos*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; sunos4*) case $cc_basename in CC*) # Sun C++ 4.x # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; lcc*) # Lucid # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; solaris*) case $cc_basename in CC* | sunCC*) # Sun C++ 4.2, 5.x and Centerline C++ _LT_TAGVAR(archive_cmds_need_lc,$1)=yes _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G$allow_undefined_flag $wl-M $wl$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no case $host_os in solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands '-z linker_flag'. # Supported since Solaris 2.6 (maybe 2.5.1?) _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;; esac _LT_TAGVAR(link_all_deplibs, $1)=yes output_verbose_link_cmd='func_echo_all' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. _LT_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' ;; gcx*) # Green Hills C++ Compiler _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' # The C++ compiler must be used to create the archive. _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' ;; *) # GNU C++ compiler with Solaris linker if test yes,no = "$GXX,$with_gnu_ld"; then _LT_TAGVAR(no_undefined_flag, $1)=' $wl-z ${wl}defs' if $CC --version | $GREP -v '^2\.7' > /dev/null; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' else # g++ 2.7 appears to require '-G' NOT '-shared' on this # platform. _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' fi _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir' case $host_os in solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' ;; esac fi ;; esac ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var='LD_RUN_PATH' case $cc_basename in CC*) _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We CANNOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' runpath_var='LD_RUN_PATH' case $cc_basename in CC*) _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ '"$_LT_TAGVAR(old_archive_cmds, $1)" _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ '"$_LT_TAGVAR(reload_cmds, $1)" ;; *) _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac ;; vxworks*) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no ;; esac AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no _LT_TAGVAR(GCC, $1)=$GXX _LT_TAGVAR(LD, $1)=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... _LT_SYS_HIDDEN_LIBDEPS($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_SYS_DYNAMIC_LINKER($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi # test -n "$compiler" CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS LDCXX=$LD LD=$lt_save_LD GCC=$lt_save_GCC with_gnu_ld=$lt_save_with_gnu_ld lt_cv_path_LDCXX=$lt_cv_path_LD lt_cv_path_LD=$lt_save_path_LD lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld fi # test yes != "$_lt_caught_CXX_error" AC_LANG_POP ])# _LT_LANG_CXX_CONFIG # _LT_FUNC_STRIPNAME_CNF # ---------------------- # func_stripname_cnf prefix suffix name # strip PREFIX and SUFFIX off of NAME. # PREFIX and SUFFIX must not contain globbing or regex special # characters, hashes, percent signs, but SUFFIX may contain a leading # dot (in which case that matches only a dot). # # This function is identical to the (non-XSI) version of func_stripname, # except this one can be used by m4 code that may be executed by configure, # rather than the libtool script. m4_defun([_LT_FUNC_STRIPNAME_CNF],[dnl AC_REQUIRE([_LT_DECL_SED]) AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) func_stripname_cnf () { case @S|@2 in .*) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%\\\\@S|@2\$%%"`;; *) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%@S|@2\$%%"`;; esac } # func_stripname_cnf ])# _LT_FUNC_STRIPNAME_CNF # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) # --------------------------------- # Figure out "hidden" library dependencies from verbose # compiler output when linking a shared library. # Parse the compiler output and extract the necessary # objects, libraries and library flags. m4_defun([_LT_SYS_HIDDEN_LIBDEPS], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl AC_REQUIRE([_LT_FUNC_STRIPNAME_CNF])dnl # Dependencies to place before and after the object being linked: _LT_TAGVAR(predep_objects, $1)= _LT_TAGVAR(postdep_objects, $1)= _LT_TAGVAR(predeps, $1)= _LT_TAGVAR(postdeps, $1)= _LT_TAGVAR(compiler_lib_search_path, $1)= dnl we can't use the lt_simple_compile_test_code here, dnl because it contains code intended for an executable, dnl not a library. It's possible we should let each dnl tag define a new lt_????_link_test_code variable, dnl but it's only used here... m4_if([$1], [], [cat > conftest.$ac_ext <<_LT_EOF int a; void foo (void) { a = 0; } _LT_EOF ], [$1], [CXX], [cat > conftest.$ac_ext <<_LT_EOF class Foo { public: Foo (void) { a = 0; } private: int a; }; _LT_EOF ], [$1], [F77], [cat > conftest.$ac_ext <<_LT_EOF subroutine foo implicit none integer*4 a a=0 return end _LT_EOF ], [$1], [FC], [cat > conftest.$ac_ext <<_LT_EOF subroutine foo implicit none integer a a=0 return end _LT_EOF ], [$1], [GCJ], [cat > conftest.$ac_ext <<_LT_EOF public class foo { private int a; public void bar (void) { a = 0; } }; _LT_EOF ], [$1], [GO], [cat > conftest.$ac_ext <<_LT_EOF package foo func foo() { } _LT_EOF ]) _lt_libdeps_save_CFLAGS=$CFLAGS case "$CC $CFLAGS " in #( *\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;; *\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;; *\ -fuse-linker-plugin*\ *) CFLAGS="$CFLAGS -fno-use-linker-plugin" ;; esac dnl Parse the compiler output and extract the necessary dnl objects, libraries and library flags. if AC_TRY_EVAL(ac_compile); then # Parse the compiler output and extract the necessary # objects, libraries and library flags. # Sentinel used to keep track of whether or not we are before # the conftest object file. pre_test_object_deps_done=no for p in `eval "$output_verbose_link_cmd"`; do case $prev$p in -L* | -R* | -l*) # Some compilers place space between "-{L,R}" and the path. # Remove the space. if test x-L = "$p" || test x-R = "$p"; then prev=$p continue fi # Expand the sysroot to ease extracting the directories later. if test -z "$prev"; then case $p in -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;; -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;; -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;; esac fi case $p in =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; esac if test no = "$pre_test_object_deps_done"; then case $prev in -L | -R) # Internal compiler library paths should come after those # provided the user. The postdeps already come after the # user supplied libs so there is no need to process them. if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then _LT_TAGVAR(compiler_lib_search_path, $1)=$prev$p else _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} $prev$p" fi ;; # The "-l" case would never come before the object being # linked, so don't bother handling this case. esac else if test -z "$_LT_TAGVAR(postdeps, $1)"; then _LT_TAGVAR(postdeps, $1)=$prev$p else _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} $prev$p" fi fi prev= ;; *.lto.$objext) ;; # Ignore GCC LTO objects *.$objext) # This assumes that the test object file only shows up # once in the compiler output. if test "$p" = "conftest.$objext"; then pre_test_object_deps_done=yes continue fi if test no = "$pre_test_object_deps_done"; then if test -z "$_LT_TAGVAR(predep_objects, $1)"; then _LT_TAGVAR(predep_objects, $1)=$p else _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" fi else if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then _LT_TAGVAR(postdep_objects, $1)=$p else _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" fi fi ;; *) ;; # Ignore the rest. esac done # Clean up. rm -f a.out a.exe else echo "libtool.m4: error: problem compiling $1 test program" fi $RM -f confest.$objext CFLAGS=$_lt_libdeps_save_CFLAGS # PORTME: override above test on systems where it is broken m4_if([$1], [CXX], [case $host_os in interix[[3-9]]*) # Interix 3.5 installs completely hosed .la files for C++, so rather than # hack all around it, let's just trust "g++" to DTRT. _LT_TAGVAR(predep_objects,$1)= _LT_TAGVAR(postdep_objects,$1)= _LT_TAGVAR(postdeps,$1)= ;; esac ]) case " $_LT_TAGVAR(postdeps, $1) " in *" -lc "*) _LT_TAGVAR(archive_cmds_need_lc, $1)=no ;; esac _LT_TAGVAR(compiler_lib_search_dirs, $1)= if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | $SED -e 's! -L! !g' -e 's!^ !!'` fi _LT_TAGDECL([], [compiler_lib_search_dirs], [1], [The directories searched by this compiler when creating a shared library]) _LT_TAGDECL([], [predep_objects], [1], [Dependencies to place before and after the objects being linked to create a shared library]) _LT_TAGDECL([], [postdep_objects], [1]) _LT_TAGDECL([], [predeps], [1]) _LT_TAGDECL([], [postdeps], [1]) _LT_TAGDECL([], [compiler_lib_search_path], [1], [The library search path used internally by the compiler when linking a shared library]) ])# _LT_SYS_HIDDEN_LIBDEPS # _LT_LANG_F77_CONFIG([TAG]) # -------------------------- # Ensure that the configuration variables for a Fortran 77 compiler are # suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_F77_CONFIG], [AC_LANG_PUSH(Fortran 77) if test -z "$F77" || test no = "$F77"; then _lt_disable_F77=yes fi _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(allow_undefined_flag, $1)= _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(archive_expsym_cmds, $1)= _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(hardcode_libdir_separator, $1)= _LT_TAGVAR(hardcode_minus_L, $1)=no _LT_TAGVAR(hardcode_automatic, $1)=no _LT_TAGVAR(inherit_rpath, $1)=no _LT_TAGVAR(module_cmds, $1)= _LT_TAGVAR(module_expsym_cmds, $1)= _LT_TAGVAR(link_all_deplibs, $1)=unknown _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds _LT_TAGVAR(no_undefined_flag, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no # Source file extension for f77 test sources. ac_ext=f # Object file extension for compiled f77 test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # No sense in running all these tests if we already determined that # the F77 compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. if test yes != "$_lt_disable_F77"; then # Code to be used in simple compile tests lt_simple_compile_test_code="\ subroutine t return end " # Code to be used in simple link tests lt_simple_link_test_code="\ program t end " # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_GCC=$GCC lt_save_CFLAGS=$CFLAGS CC=${F77-"f77"} CFLAGS=$FFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) GCC=$G77 if test -n "$compiler"; then AC_MSG_CHECKING([if libtool supports shared libraries]) AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[[4-9]]*) if test ia64 != "$host_cpu"; then case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in yes,aix,yes) ;; # shared object as lib.so file only yes,svr4,*) ;; # shared object as lib.so archive member only yes,*) enable_static=no ;; # shared object in lib.a archive as well esac fi ;; esac AC_MSG_RESULT([$enable_shared]) AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. test yes = "$enable_shared" || enable_static=yes AC_MSG_RESULT([$enable_static]) _LT_TAGVAR(GCC, $1)=$G77 _LT_TAGVAR(LD, $1)=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_SYS_DYNAMIC_LINKER($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi # test -n "$compiler" GCC=$lt_save_GCC CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS fi # test yes != "$_lt_disable_F77" AC_LANG_POP ])# _LT_LANG_F77_CONFIG # _LT_LANG_FC_CONFIG([TAG]) # ------------------------- # Ensure that the configuration variables for a Fortran compiler are # suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_FC_CONFIG], [AC_LANG_PUSH(Fortran) if test -z "$FC" || test no = "$FC"; then _lt_disable_FC=yes fi _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(allow_undefined_flag, $1)= _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(archive_expsym_cmds, $1)= _LT_TAGVAR(export_dynamic_flag_spec, $1)= _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=no _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(hardcode_libdir_separator, $1)= _LT_TAGVAR(hardcode_minus_L, $1)=no _LT_TAGVAR(hardcode_automatic, $1)=no _LT_TAGVAR(inherit_rpath, $1)=no _LT_TAGVAR(module_cmds, $1)= _LT_TAGVAR(module_expsym_cmds, $1)= _LT_TAGVAR(link_all_deplibs, $1)=unknown _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds _LT_TAGVAR(no_undefined_flag, $1)= _LT_TAGVAR(whole_archive_flag_spec, $1)= _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=no # Source file extension for fc test sources. ac_ext=${ac_fc_srcext-f} # Object file extension for compiled fc test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # No sense in running all these tests if we already determined that # the FC compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. if test yes != "$_lt_disable_FC"; then # Code to be used in simple compile tests lt_simple_compile_test_code="\ subroutine t return end " # Code to be used in simple link tests lt_simple_link_test_code="\ program t end " # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_GCC=$GCC lt_save_CFLAGS=$CFLAGS CC=${FC-"f95"} CFLAGS=$FCFLAGS compiler=$CC GCC=$ac_cv_fc_compiler_gnu _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) if test -n "$compiler"; then AC_MSG_CHECKING([if libtool supports shared libraries]) AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[[4-9]]*) if test ia64 != "$host_cpu"; then case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in yes,aix,yes) ;; # shared object as lib.so file only yes,svr4,*) ;; # shared object as lib.so archive member only yes,*) enable_static=no ;; # shared object in lib.a archive as well esac fi ;; esac AC_MSG_RESULT([$enable_shared]) AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. test yes = "$enable_shared" || enable_static=yes AC_MSG_RESULT([$enable_static]) _LT_TAGVAR(GCC, $1)=$ac_cv_fc_compiler_gnu _LT_TAGVAR(LD, $1)=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... _LT_SYS_HIDDEN_LIBDEPS($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_SYS_DYNAMIC_LINKER($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi # test -n "$compiler" GCC=$lt_save_GCC CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS fi # test yes != "$_lt_disable_FC" AC_LANG_POP ])# _LT_LANG_FC_CONFIG # _LT_LANG_GCJ_CONFIG([TAG]) # -------------------------- # Ensure that the configuration variables for the GNU Java Compiler compiler # are suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_GCJ_CONFIG], [AC_REQUIRE([LT_PROG_GCJ])dnl AC_LANG_SAVE # Source file extension for Java test sources. ac_ext=java # Object file extension for compiled Java test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="class foo {}" # Code to be used in simple link tests lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_GCC=$GCC GCC=yes CC=${GCJ-"gcj"} CFLAGS=$GCJFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_TAGVAR(LD, $1)=$LD _LT_CC_BASENAME([$compiler]) # GCJ did not exist at the time GCC didn't implicitly link libc in. _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... if test -n "$compiler"; then _LT_COMPILER_NO_RTTI($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi AC_LANG_RESTORE GCC=$lt_save_GCC CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS ])# _LT_LANG_GCJ_CONFIG # _LT_LANG_GO_CONFIG([TAG]) # -------------------------- # Ensure that the configuration variables for the GNU Go compiler # are suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_GO_CONFIG], [AC_REQUIRE([LT_PROG_GO])dnl AC_LANG_SAVE # Source file extension for Go test sources. ac_ext=go # Object file extension for compiled Go test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="package main; func main() { }" # Code to be used in simple link tests lt_simple_link_test_code='package main; func main() { }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_GCC=$GCC GCC=yes CC=${GOC-"gccgo"} CFLAGS=$GOFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_TAGVAR(LD, $1)=$LD _LT_CC_BASENAME([$compiler]) # Go did not exist at the time GCC didn't implicitly link libc in. _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_TAGVAR(reload_flag, $1)=$reload_flag _LT_TAGVAR(reload_cmds, $1)=$reload_cmds ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change ## the running order or otherwise move them around unless you know exactly ## what you are doing... if test -n "$compiler"; then _LT_COMPILER_NO_RTTI($1) _LT_COMPILER_PIC($1) _LT_COMPILER_C_O($1) _LT_COMPILER_FILE_LOCKS($1) _LT_LINKER_SHLIBS($1) _LT_LINKER_HARDCODE_LIBPATH($1) _LT_CONFIG($1) fi AC_LANG_RESTORE GCC=$lt_save_GCC CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS ])# _LT_LANG_GO_CONFIG # _LT_LANG_RC_CONFIG([TAG]) # ------------------------- # Ensure that the configuration variables for the Windows resource compiler # are suitably defined. These variables are subsequently used by _LT_CONFIG # to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_RC_CONFIG], [AC_REQUIRE([LT_PROG_RC])dnl AC_LANG_SAVE # Source file extension for RC test sources. ac_ext=rc # Object file extension for compiled RC test sources. objext=o _LT_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' # Code to be used in simple link tests lt_simple_link_test_code=$lt_simple_compile_test_code # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_GCC=$GCC GCC= CC=${RC-"windres"} CFLAGS= compiler=$CC _LT_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) _LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes if test -n "$compiler"; then : _LT_CONFIG($1) fi GCC=$lt_save_GCC AC_LANG_RESTORE CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS ])# _LT_LANG_RC_CONFIG # LT_PROG_GCJ # ----------- AC_DEFUN([LT_PROG_GCJ], [m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], [AC_CHECK_TOOL(GCJ, gcj,) test set = "${GCJFLAGS+set}" || GCJFLAGS="-g -O2" AC_SUBST(GCJFLAGS)])])[]dnl ]) # Old name: AU_ALIAS([LT_AC_PROG_GCJ], [LT_PROG_GCJ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([LT_AC_PROG_GCJ], []) # LT_PROG_GO # ---------- AC_DEFUN([LT_PROG_GO], [AC_CHECK_TOOL(GOC, gccgo,) ]) # LT_PROG_RC # ---------- AC_DEFUN([LT_PROG_RC], [AC_CHECK_TOOL(RC, windres,) ]) # Old name: AU_ALIAS([LT_AC_PROG_RC], [LT_PROG_RC]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([LT_AC_PROG_RC], []) # _LT_DECL_EGREP # -------------- # If we don't have a new enough Autoconf to choose the best grep # available, choose the one first in the user's PATH. m4_defun([_LT_DECL_EGREP], [AC_REQUIRE([AC_PROG_EGREP])dnl AC_REQUIRE([AC_PROG_FGREP])dnl test -z "$GREP" && GREP=grep _LT_DECL([], [GREP], [1], [A grep program that handles long lines]) _LT_DECL([], [EGREP], [1], [An ERE matcher]) _LT_DECL([], [FGREP], [1], [A literal string matcher]) dnl Non-bleeding-edge autoconf doesn't subst GREP, so do it here too AC_SUBST([GREP]) ]) # _LT_DECL_OBJDUMP # -------------- # If we don't have a new enough Autoconf to choose the best objdump # available, choose the one first in the user's PATH. m4_defun([_LT_DECL_OBJDUMP], [AC_CHECK_TOOL(OBJDUMP, objdump, false) test -z "$OBJDUMP" && OBJDUMP=objdump _LT_DECL([], [OBJDUMP], [1], [An object symbol dumper]) AC_SUBST([OBJDUMP]) ]) # _LT_DECL_DLLTOOL # ---------------- # Ensure DLLTOOL variable is set. m4_defun([_LT_DECL_DLLTOOL], [AC_CHECK_TOOL(DLLTOOL, dlltool, false) test -z "$DLLTOOL" && DLLTOOL=dlltool _LT_DECL([], [DLLTOOL], [1], [DLL creation program]) AC_SUBST([DLLTOOL]) ]) # _LT_DECL_SED # ------------ # Check for a fully-functional sed program, that truncates # as few characters as possible. Prefer GNU sed if found. m4_defun([_LT_DECL_SED], [AC_PROG_SED test -z "$SED" && SED=sed Xsed="$SED -e 1s/^X//" _LT_DECL([], [SED], [1], [A sed program that does not truncate output]) _LT_DECL([], [Xsed], ["\$SED -e 1s/^X//"], [Sed that helps us avoid accidentally triggering echo(1) options like -n]) ])# _LT_DECL_SED m4_ifndef([AC_PROG_SED], [ ############################################################ # NOTE: This macro has been submitted for inclusion into # # GNU Autoconf as AC_PROG_SED. When it is available in # # a released version of Autoconf we should remove this # # macro and use it instead. # ############################################################ m4_defun([AC_PROG_SED], [AC_MSG_CHECKING([for a sed that does not truncate output]) AC_CACHE_VAL(lt_cv_path_SED, [# Loop through the user's path and test for sed and gsed. # Then use that list of sed's as ones to test for truncation. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for lt_ac_prog in sed gsed; do for ac_exec_ext in '' $ac_executable_extensions; do if $as_executable_p "$as_dir/$lt_ac_prog$ac_exec_ext"; then lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" fi done done done IFS=$as_save_IFS lt_ac_max=0 lt_ac_count=0 # Add /usr/xpg4/bin/sed as it is typically found on Solaris # along with /bin/sed that truncates output. for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do test ! -f "$lt_ac_sed" && continue cat /dev/null > conftest.in lt_ac_count=0 echo $ECHO_N "0123456789$ECHO_C" >conftest.in # Check for GNU sed and select it if it is found. if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then lt_cv_path_SED=$lt_ac_sed break fi while true; do cat conftest.in conftest.in >conftest.tmp mv conftest.tmp conftest.in cp conftest.in conftest.nl echo >>conftest.nl $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break cmp -s conftest.out conftest.nl || break # 10000 chars as input seems more than enough test 10 -lt "$lt_ac_count" && break lt_ac_count=`expr $lt_ac_count + 1` if test "$lt_ac_count" -gt "$lt_ac_max"; then lt_ac_max=$lt_ac_count lt_cv_path_SED=$lt_ac_sed fi done done ]) SED=$lt_cv_path_SED AC_SUBST([SED]) AC_MSG_RESULT([$SED]) ])#AC_PROG_SED ])#m4_ifndef # Old name: AU_ALIAS([LT_AC_PROG_SED], [AC_PROG_SED]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([LT_AC_PROG_SED], []) # _LT_CHECK_SHELL_FEATURES # ------------------------ # Find out whether the shell is Bourne or XSI compatible, # or has some other useful features. m4_defun([_LT_CHECK_SHELL_FEATURES], [if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then lt_unset=unset else lt_unset=false fi _LT_DECL([], [lt_unset], [0], [whether the shell understands "unset"])dnl # test EBCDIC or ASCII case `echo X|tr X '\101'` in A) # ASCII based system # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr lt_SP2NL='tr \040 \012' lt_NL2SP='tr \015\012 \040\040' ;; *) # EBCDIC based system lt_SP2NL='tr \100 \n' lt_NL2SP='tr \r\n \100\100' ;; esac _LT_DECL([SP2NL], [lt_SP2NL], [1], [turn spaces into newlines])dnl _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl ])# _LT_CHECK_SHELL_FEATURES # _LT_PATH_CONVERSION_FUNCTIONS # ----------------------------- # Determine what file name conversion functions should be used by # func_to_host_file (and, implicitly, by func_to_host_path). These are needed # for certain cross-compile configurations and native mingw. m4_defun([_LT_PATH_CONVERSION_FUNCTIONS], [AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_CANONICAL_BUILD])dnl AC_MSG_CHECKING([how to convert $build file names to $host format]) AC_CACHE_VAL(lt_cv_to_host_file_cmd, [case $host in *-*-mingw* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32 ;; *-*-cygwin* ) lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32 ;; * ) # otherwise, assume *nix lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32 ;; esac ;; *-*-cygwin* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin ;; *-*-cygwin* ) lt_cv_to_host_file_cmd=func_convert_file_noop ;; * ) # otherwise, assume *nix lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin ;; esac ;; * ) # unhandled hosts (and "normal" native builds) lt_cv_to_host_file_cmd=func_convert_file_noop ;; esac ]) to_host_file_cmd=$lt_cv_to_host_file_cmd AC_MSG_RESULT([$lt_cv_to_host_file_cmd]) _LT_DECL([to_host_file_cmd], [lt_cv_to_host_file_cmd], [0], [convert $build file names to $host format])dnl AC_MSG_CHECKING([how to convert $build file names to toolchain format]) AC_CACHE_VAL(lt_cv_to_tool_file_cmd, [#assume ordinary cross tools, or native build. lt_cv_to_tool_file_cmd=func_convert_file_noop case $host in *-*-mingw* ) case $build in *-*-mingw* ) # actually msys lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32 ;; esac ;; esac ]) to_tool_file_cmd=$lt_cv_to_tool_file_cmd AC_MSG_RESULT([$lt_cv_to_tool_file_cmd]) _LT_DECL([to_tool_file_cmd], [lt_cv_to_tool_file_cmd], [0], [convert $build files to toolchain format])dnl ])# _LT_PATH_CONVERSION_FUNCTIONS ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/m4/ltsugar.m4�������������������������������������������������������������������������0000644�0001750�0001750�00000010440�13341246640�012326� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������# ltsugar.m4 -- libtool m4 base layer. -*-Autoconf-*- # # Copyright (C) 2004-2005, 2007-2008, 2011-2015 Free Software # Foundation, Inc. # Written by Gary V. Vaughan, 2004 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. # serial 6 ltsugar.m4 # This is to help aclocal find these macros, as it can't see m4_define. AC_DEFUN([LTSUGAR_VERSION], [m4_if([0.1])]) # lt_join(SEP, ARG1, [ARG2...]) # ----------------------------- # Produce ARG1SEPARG2...SEPARGn, omitting [] arguments and their # associated separator. # Needed until we can rely on m4_join from Autoconf 2.62, since all earlier # versions in m4sugar had bugs. m4_define([lt_join], [m4_if([$#], [1], [], [$#], [2], [[$2]], [m4_if([$2], [], [], [[$2]_])$0([$1], m4_shift(m4_shift($@)))])]) m4_define([_lt_join], [m4_if([$#$2], [2], [], [m4_if([$2], [], [], [[$1$2]])$0([$1], m4_shift(m4_shift($@)))])]) # lt_car(LIST) # lt_cdr(LIST) # ------------ # Manipulate m4 lists. # These macros are necessary as long as will still need to support # Autoconf-2.59, which quotes differently. m4_define([lt_car], [[$1]]) m4_define([lt_cdr], [m4_if([$#], 0, [m4_fatal([$0: cannot be called without arguments])], [$#], 1, [], [m4_dquote(m4_shift($@))])]) m4_define([lt_unquote], $1) # lt_append(MACRO-NAME, STRING, [SEPARATOR]) # ------------------------------------------ # Redefine MACRO-NAME to hold its former content plus 'SEPARATOR''STRING'. # Note that neither SEPARATOR nor STRING are expanded; they are appended # to MACRO-NAME as is (leaving the expansion for when MACRO-NAME is invoked). # No SEPARATOR is output if MACRO-NAME was previously undefined (different # than defined and empty). # # This macro is needed until we can rely on Autoconf 2.62, since earlier # versions of m4sugar mistakenly expanded SEPARATOR but not STRING. m4_define([lt_append], [m4_define([$1], m4_ifdef([$1], [m4_defn([$1])[$3]])[$2])]) # lt_combine(SEP, PREFIX-LIST, INFIX, SUFFIX1, [SUFFIX2...]) # ---------------------------------------------------------- # Produce a SEP delimited list of all paired combinations of elements of # PREFIX-LIST with SUFFIX1 through SUFFIXn. Each element of the list # has the form PREFIXmINFIXSUFFIXn. # Needed until we can rely on m4_combine added in Autoconf 2.62. m4_define([lt_combine], [m4_if(m4_eval([$# > 3]), [1], [m4_pushdef([_Lt_sep], [m4_define([_Lt_sep], m4_defn([lt_car]))])]]dnl [[m4_foreach([_Lt_prefix], [$2], [m4_foreach([_Lt_suffix], ]m4_dquote(m4_dquote(m4_shift(m4_shift(m4_shift($@)))))[, [_Lt_sep([$1])[]m4_defn([_Lt_prefix])[$3]m4_defn([_Lt_suffix])])])])]) # lt_if_append_uniq(MACRO-NAME, VARNAME, [SEPARATOR], [UNIQ], [NOT-UNIQ]) # ----------------------------------------------------------------------- # Iff MACRO-NAME does not yet contain VARNAME, then append it (delimited # by SEPARATOR if supplied) and expand UNIQ, else NOT-UNIQ. m4_define([lt_if_append_uniq], [m4_ifdef([$1], [m4_if(m4_index([$3]m4_defn([$1])[$3], [$3$2$3]), [-1], [lt_append([$1], [$2], [$3])$4], [$5])], [lt_append([$1], [$2], [$3])$4])]) # lt_dict_add(DICT, KEY, VALUE) # ----------------------------- m4_define([lt_dict_add], [m4_define([$1($2)], [$3])]) # lt_dict_add_subkey(DICT, KEY, SUBKEY, VALUE) # -------------------------------------------- m4_define([lt_dict_add_subkey], [m4_define([$1($2:$3)], [$4])]) # lt_dict_fetch(DICT, KEY, [SUBKEY]) # ---------------------------------- m4_define([lt_dict_fetch], [m4_ifval([$3], m4_ifdef([$1($2:$3)], [m4_defn([$1($2:$3)])]), m4_ifdef([$1($2)], [m4_defn([$1($2)])]))]) # lt_if_dict_fetch(DICT, KEY, [SUBKEY], VALUE, IF-TRUE, [IF-FALSE]) # ----------------------------------------------------------------- m4_define([lt_if_dict_fetch], [m4_if(lt_dict_fetch([$1], [$2], [$3]), [$4], [$5], [$6])]) # lt_dict_filter(DICT, [SUBKEY], VALUE, [SEPARATOR], KEY, [...]) # -------------------------------------------------------------- m4_define([lt_dict_filter], [m4_if([$5], [], [], [lt_join(m4_quote(m4_default([$4], [[, ]])), lt_unquote(m4_split(m4_normalize(m4_foreach(_Lt_key, lt_car([m4_shiftn(4, $@)]), [lt_if_dict_fetch([$1], _Lt_key, [$2], [$3], [_Lt_key ])])))))])[]dnl ]) ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/m4/ltoptions.m4�����������������������������������������������������������������������0000644�0001750�0001750�00000034262�13341246640�012710� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������# Helper functions for option handling. -*- Autoconf -*- # # Copyright (C) 2004-2005, 2007-2009, 2011-2015 Free Software # Foundation, Inc. # Written by Gary V. Vaughan, 2004 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. # serial 8 ltoptions.m4 # This is to help aclocal find these macros, as it can't see m4_define. AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) # _LT_MANGLE_OPTION(MACRO-NAME, OPTION-NAME) # ------------------------------------------ m4_define([_LT_MANGLE_OPTION], [[_LT_OPTION_]m4_bpatsubst($1__$2, [[^a-zA-Z0-9_]], [_])]) # _LT_SET_OPTION(MACRO-NAME, OPTION-NAME) # --------------------------------------- # Set option OPTION-NAME for macro MACRO-NAME, and if there is a # matching handler defined, dispatch to it. Other OPTION-NAMEs are # saved as a flag. m4_define([_LT_SET_OPTION], [m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), _LT_MANGLE_DEFUN([$1], [$2]), [m4_warning([Unknown $1 option '$2'])])[]dnl ]) # _LT_IF_OPTION(MACRO-NAME, OPTION-NAME, IF-SET, [IF-NOT-SET]) # ------------------------------------------------------------ # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. m4_define([_LT_IF_OPTION], [m4_ifdef(_LT_MANGLE_OPTION([$1], [$2]), [$3], [$4])]) # _LT_UNLESS_OPTIONS(MACRO-NAME, OPTION-LIST, IF-NOT-SET) # ------------------------------------------------------- # Execute IF-NOT-SET unless all options in OPTION-LIST for MACRO-NAME # are set. m4_define([_LT_UNLESS_OPTIONS], [m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), [m4_ifdef(_LT_MANGLE_OPTION([$1], _LT_Option), [m4_define([$0_found])])])[]dnl m4_ifdef([$0_found], [m4_undefine([$0_found])], [$3 ])[]dnl ]) # _LT_SET_OPTIONS(MACRO-NAME, OPTION-LIST) # ---------------------------------------- # OPTION-LIST is a space-separated list of Libtool options associated # with MACRO-NAME. If any OPTION has a matching handler declared with # LT_OPTION_DEFINE, dispatch to that macro; otherwise complain about # the unknown option and exit. m4_defun([_LT_SET_OPTIONS], [# Set options m4_foreach([_LT_Option], m4_split(m4_normalize([$2])), [_LT_SET_OPTION([$1], _LT_Option)]) m4_if([$1],[LT_INIT],[ dnl dnl Simply set some default values (i.e off) if boolean options were not dnl specified: _LT_UNLESS_OPTIONS([LT_INIT], [dlopen], [enable_dlopen=no ]) _LT_UNLESS_OPTIONS([LT_INIT], [win32-dll], [enable_win32_dll=no ]) dnl dnl If no reference was made to various pairs of opposing options, then dnl we run the default mode handler for the pair. For example, if neither dnl 'shared' nor 'disable-shared' was passed, we enable building of shared dnl archives by default: _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], [_LT_ENABLE_FAST_INSTALL]) _LT_UNLESS_OPTIONS([LT_INIT], [aix-soname=aix aix-soname=both aix-soname=svr4], [_LT_WITH_AIX_SONAME([aix])]) ]) ])# _LT_SET_OPTIONS ## --------------------------------- ## ## Macros to handle LT_INIT options. ## ## --------------------------------- ## # _LT_MANGLE_DEFUN(MACRO-NAME, OPTION-NAME) # ----------------------------------------- m4_define([_LT_MANGLE_DEFUN], [[_LT_OPTION_DEFUN_]m4_bpatsubst(m4_toupper([$1__$2]), [[^A-Z0-9_]], [_])]) # LT_OPTION_DEFINE(MACRO-NAME, OPTION-NAME, CODE) # ----------------------------------------------- m4_define([LT_OPTION_DEFINE], [m4_define(_LT_MANGLE_DEFUN([$1], [$2]), [$3])[]dnl ])# LT_OPTION_DEFINE # dlopen # ------ LT_OPTION_DEFINE([LT_INIT], [dlopen], [enable_dlopen=yes ]) AU_DEFUN([AC_LIBTOOL_DLOPEN], [_LT_SET_OPTION([LT_INIT], [dlopen]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'dlopen' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_DLOPEN], []) # win32-dll # --------- # Declare package support for building win32 dll's. LT_OPTION_DEFINE([LT_INIT], [win32-dll], [enable_win32_dll=yes case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*) AC_CHECK_TOOL(AS, as, false) AC_CHECK_TOOL(DLLTOOL, dlltool, false) AC_CHECK_TOOL(OBJDUMP, objdump, false) ;; esac test -z "$AS" && AS=as _LT_DECL([], [AS], [1], [Assembler program])dnl test -z "$DLLTOOL" && DLLTOOL=dlltool _LT_DECL([], [DLLTOOL], [1], [DLL creation program])dnl test -z "$OBJDUMP" && OBJDUMP=objdump _LT_DECL([], [OBJDUMP], [1], [Object dumper program])dnl ])# win32-dll AU_DEFUN([AC_LIBTOOL_WIN32_DLL], [AC_REQUIRE([AC_CANONICAL_HOST])dnl _LT_SET_OPTION([LT_INIT], [win32-dll]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'win32-dll' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) # _LT_ENABLE_SHARED([DEFAULT]) # ---------------------------- # implement the --enable-shared flag, and supports the 'shared' and # 'disable-shared' LT_INIT options. # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. m4_define([_LT_ENABLE_SHARED], [m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl AC_ARG_ENABLE([shared], [AS_HELP_STRING([--enable-shared@<:@=PKGS@:>@], [build shared libraries @<:@default=]_LT_ENABLE_SHARED_DEFAULT[@:>@])], [p=${PACKAGE-default} case $enableval in yes) enable_shared=yes ;; no) enable_shared=no ;; *) enable_shared=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_shared=yes fi done IFS=$lt_save_ifs ;; esac], [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) _LT_DECL([build_libtool_libs], [enable_shared], [0], [Whether or not to build shared libraries]) ])# _LT_ENABLE_SHARED LT_OPTION_DEFINE([LT_INIT], [shared], [_LT_ENABLE_SHARED([yes])]) LT_OPTION_DEFINE([LT_INIT], [disable-shared], [_LT_ENABLE_SHARED([no])]) # Old names: AC_DEFUN([AC_ENABLE_SHARED], [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[shared]) ]) AC_DEFUN([AC_DISABLE_SHARED], [_LT_SET_OPTION([LT_INIT], [disable-shared]) ]) AU_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) AU_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AM_ENABLE_SHARED], []) dnl AC_DEFUN([AM_DISABLE_SHARED], []) # _LT_ENABLE_STATIC([DEFAULT]) # ---------------------------- # implement the --enable-static flag, and support the 'static' and # 'disable-static' LT_INIT options. # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. m4_define([_LT_ENABLE_STATIC], [m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl AC_ARG_ENABLE([static], [AS_HELP_STRING([--enable-static@<:@=PKGS@:>@], [build static libraries @<:@default=]_LT_ENABLE_STATIC_DEFAULT[@:>@])], [p=${PACKAGE-default} case $enableval in yes) enable_static=yes ;; no) enable_static=no ;; *) enable_static=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_static=yes fi done IFS=$lt_save_ifs ;; esac], [enable_static=]_LT_ENABLE_STATIC_DEFAULT) _LT_DECL([build_old_libs], [enable_static], [0], [Whether or not to build static libraries]) ])# _LT_ENABLE_STATIC LT_OPTION_DEFINE([LT_INIT], [static], [_LT_ENABLE_STATIC([yes])]) LT_OPTION_DEFINE([LT_INIT], [disable-static], [_LT_ENABLE_STATIC([no])]) # Old names: AC_DEFUN([AC_ENABLE_STATIC], [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[static]) ]) AC_DEFUN([AC_DISABLE_STATIC], [_LT_SET_OPTION([LT_INIT], [disable-static]) ]) AU_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) AU_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AM_ENABLE_STATIC], []) dnl AC_DEFUN([AM_DISABLE_STATIC], []) # _LT_ENABLE_FAST_INSTALL([DEFAULT]) # ---------------------------------- # implement the --enable-fast-install flag, and support the 'fast-install' # and 'disable-fast-install' LT_INIT options. # DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. m4_define([_LT_ENABLE_FAST_INSTALL], [m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl AC_ARG_ENABLE([fast-install], [AS_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], [optimize for fast installation @<:@default=]_LT_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], [p=${PACKAGE-default} case $enableval in yes) enable_fast_install=yes ;; no) enable_fast_install=no ;; *) enable_fast_install=no # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_fast_install=yes fi done IFS=$lt_save_ifs ;; esac], [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) _LT_DECL([fast_install], [enable_fast_install], [0], [Whether or not to optimize for fast installation])dnl ])# _LT_ENABLE_FAST_INSTALL LT_OPTION_DEFINE([LT_INIT], [fast-install], [_LT_ENABLE_FAST_INSTALL([yes])]) LT_OPTION_DEFINE([LT_INIT], [disable-fast-install], [_LT_ENABLE_FAST_INSTALL([no])]) # Old names: AU_DEFUN([AC_ENABLE_FAST_INSTALL], [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'fast-install' option into LT_INIT's first parameter.]) ]) AU_DEFUN([AC_DISABLE_FAST_INSTALL], [_LT_SET_OPTION([LT_INIT], [disable-fast-install]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'disable-fast-install' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) # _LT_WITH_AIX_SONAME([DEFAULT]) # ---------------------------------- # implement the --with-aix-soname flag, and support the `aix-soname=aix' # and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. DEFAULT # is either `aix', `both' or `svr4'. If omitted, it defaults to `aix'. m4_define([_LT_WITH_AIX_SONAME], [m4_define([_LT_WITH_AIX_SONAME_DEFAULT], [m4_if($1, svr4, svr4, m4_if($1, both, both, aix))])dnl shared_archive_member_spec= case $host,$enable_shared in power*-*-aix[[5-9]]*,yes) AC_MSG_CHECKING([which variant of shared library versioning to provide]) AC_ARG_WITH([aix-soname], [AS_HELP_STRING([--with-aix-soname=aix|svr4|both], [shared library versioning (aka "SONAME") variant to provide on AIX, @<:@default=]_LT_WITH_AIX_SONAME_DEFAULT[@:>@.])], [case $withval in aix|svr4|both) ;; *) AC_MSG_ERROR([Unknown argument to --with-aix-soname]) ;; esac lt_cv_with_aix_soname=$with_aix_soname], [AC_CACHE_VAL([lt_cv_with_aix_soname], [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT) with_aix_soname=$lt_cv_with_aix_soname]) AC_MSG_RESULT([$with_aix_soname]) if test aix != "$with_aix_soname"; then # For the AIX way of multilib, we name the shared archive member # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File. # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag, # the AIX toolchain works better with OBJECT_MODE set (default 32). if test 64 = "${OBJECT_MODE-32}"; then shared_archive_member_spec=shr_64 else shared_archive_member_spec=shr fi fi ;; *) with_aix_soname=aix ;; esac _LT_DECL([], [shared_archive_member_spec], [0], [Shared archive member basename, for filename based shared library versioning on AIX])dnl ])# _LT_WITH_AIX_SONAME LT_OPTION_DEFINE([LT_INIT], [aix-soname=aix], [_LT_WITH_AIX_SONAME([aix])]) LT_OPTION_DEFINE([LT_INIT], [aix-soname=both], [_LT_WITH_AIX_SONAME([both])]) LT_OPTION_DEFINE([LT_INIT], [aix-soname=svr4], [_LT_WITH_AIX_SONAME([svr4])]) # _LT_WITH_PIC([MODE]) # -------------------- # implement the --with-pic flag, and support the 'pic-only' and 'no-pic' # LT_INIT options. # MODE is either 'yes' or 'no'. If omitted, it defaults to 'both'. m4_define([_LT_WITH_PIC], [AC_ARG_WITH([pic], [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@], [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], [lt_p=${PACKAGE-default} case $withval in yes|no) pic_mode=$withval ;; *) pic_mode=default # Look at the argument we got. We use all the common list separators. lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for lt_pkg in $withval; do IFS=$lt_save_ifs if test "X$lt_pkg" = "X$lt_p"; then pic_mode=yes fi done IFS=$lt_save_ifs ;; esac], [pic_mode=m4_default([$1], [default])]) _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl ])# _LT_WITH_PIC LT_OPTION_DEFINE([LT_INIT], [pic-only], [_LT_WITH_PIC([yes])]) LT_OPTION_DEFINE([LT_INIT], [no-pic], [_LT_WITH_PIC([no])]) # Old name: AU_DEFUN([AC_LIBTOOL_PICMODE], [_LT_SET_OPTION([LT_INIT], [pic-only]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put the 'pic-only' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: dnl AC_DEFUN([AC_LIBTOOL_PICMODE], []) ## ----------------- ## ## LTDL_INIT Options ## ## ----------------- ## m4_define([_LTDL_MODE], []) LT_OPTION_DEFINE([LTDL_INIT], [nonrecursive], [m4_define([_LTDL_MODE], [nonrecursive])]) LT_OPTION_DEFINE([LTDL_INIT], [recursive], [m4_define([_LTDL_MODE], [recursive])]) LT_OPTION_DEFINE([LTDL_INIT], [subproject], [m4_define([_LTDL_MODE], [subproject])]) m4_define([_LTDL_TYPE], []) LT_OPTION_DEFINE([LTDL_INIT], [installable], [m4_define([_LTDL_TYPE], [installable])]) LT_OPTION_DEFINE([LTDL_INIT], [convenience], [m4_define([_LTDL_TYPE], [convenience])]) ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/m4/ax_cxx_compile_stdcxx.m4�����������������������������������������������������������0000664�0001750�0001750�00000047453�13407173247�015271� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������# =========================================================================== # https://www.gnu.org/software/autoconf-archive/ax_cxx_compile_stdcxx.html # =========================================================================== # # SYNOPSIS # # AX_CXX_COMPILE_STDCXX(VERSION, [ext|noext], [mandatory|optional]) # # DESCRIPTION # # Check for baseline language coverage in the compiler for the specified # version of the C++ standard. If necessary, add switches to CXX and # CXXCPP to enable support. VERSION may be '11' (for the C++11 standard) # or '14' (for the C++14 standard). # # The second argument, if specified, indicates whether you insist on an # extended mode (e.g. -std=gnu++11) or a strict conformance mode (e.g. # -std=c++11). If neither is specified, you get whatever works, with # preference for an extended mode. # # The third argument, if specified 'mandatory' or if left unspecified, # indicates that baseline support for the specified C++ standard is # required and that the macro should error out if no mode with that # support is found. If specified 'optional', then configuration proceeds # regardless, after defining HAVE_CXX${VERSION} if and only if a # supporting mode is found. # # LICENSE # # Copyright (c) 2008 Benjamin Kosnik <bkoz@redhat.com> # Copyright (c) 2012 Zack Weinberg <zackw@panix.com> # Copyright (c) 2013 Roy Stogner <roystgnr@ices.utexas.edu> # Copyright (c) 2014, 2015 Google Inc.; contributed by Alexey Sokolov <sokolov@google.com> # Copyright (c) 2015 Paul Norman <penorman@mac.com> # Copyright (c) 2015 Moritz Klammler <moritz@klammler.eu> # Copyright (c) 2016 Krzesimir Nowak <qdlacz@gmail.com> # # Copying and distribution of this file, with or without modification, are # permitted in any medium without royalty provided the copyright notice # and this notice are preserved. This file is offered as-is, without any # warranty. #serial 7 dnl This macro is based on the code from the AX_CXX_COMPILE_STDCXX_11 macro dnl (serial version number 13). AX_REQUIRE_DEFINED([AC_MSG_WARN]) AC_DEFUN([AX_CXX_COMPILE_STDCXX], [dnl m4_if([$1], [11], [ax_cxx_compile_alternatives="11 0x"], [$1], [14], [ax_cxx_compile_alternatives="14 1y"], [$1], [17], [ax_cxx_compile_alternatives="17 1z"], [m4_fatal([invalid first argument `$1' to AX_CXX_COMPILE_STDCXX])])dnl m4_if([$2], [], [], [$2], [ext], [], [$2], [noext], [], [m4_fatal([invalid second argument `$2' to AX_CXX_COMPILE_STDCXX])])dnl m4_if([$3], [], [ax_cxx_compile_cxx$1_required=true], [$3], [mandatory], [ax_cxx_compile_cxx$1_required=true], [$3], [optional], [ax_cxx_compile_cxx$1_required=false], [m4_fatal([invalid third argument `$3' to AX_CXX_COMPILE_STDCXX])]) AC_LANG_PUSH([C++])dnl ac_success=no AC_CACHE_CHECK(whether $CXX supports C++$1 features by default, ax_cv_cxx_compile_cxx$1, [AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_testbody_$1])], [ax_cv_cxx_compile_cxx$1=yes], [ax_cv_cxx_compile_cxx$1=no])]) if test x$ax_cv_cxx_compile_cxx$1 = xyes; then ac_success=yes fi m4_if([$2], [noext], [], [dnl if test x$ac_success = xno; then for alternative in ${ax_cxx_compile_alternatives}; do switch="-std=gnu++${alternative}" cachevar=AS_TR_SH([ax_cv_cxx_compile_cxx$1_$switch]) AC_CACHE_CHECK(whether $CXX supports C++$1 features with $switch, $cachevar, [ac_save_CXX="$CXX" CXX="$CXX $switch" AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_testbody_$1])], [eval $cachevar=yes], [eval $cachevar=no]) CXX="$ac_save_CXX"]) if eval test x\$$cachevar = xyes; then CXX="$CXX $switch" if test -n "$CXXCPP" ; then CXXCPP="$CXXCPP $switch" fi ac_success=yes break fi done fi]) m4_if([$2], [ext], [], [dnl if test x$ac_success = xno; then dnl HP's aCC needs +std=c++11 according to: dnl http://h21007.www2.hp.com/portal/download/files/unprot/aCxx/PDF_Release_Notes/769149-001.pdf dnl Cray's crayCC needs "-h std=c++11" for alternative in ${ax_cxx_compile_alternatives}; do for switch in -std=c++${alternative} +std=c++${alternative} "-h std=c++${alternative}"; do cachevar=AS_TR_SH([ax_cv_cxx_compile_cxx$1_$switch]) AC_CACHE_CHECK(whether $CXX supports C++$1 features with $switch, $cachevar, [ac_save_CXX="$CXX" CXX="$CXX $switch" AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_testbody_$1])], [eval $cachevar=yes], [eval $cachevar=no]) CXX="$ac_save_CXX"]) if eval test x\$$cachevar = xyes; then CXX="$CXX $switch" if test -n "$CXXCPP" ; then CXXCPP="$CXXCPP $switch" fi ac_success=yes break fi done if test x$ac_success = xyes; then break fi done fi]) AC_LANG_POP([C++]) if test x$ax_cxx_compile_cxx$1_required = xtrue; then if test x$ac_success = xno; then AC_MSG_ERROR([*** A compiler with support for C++$1 language features is required.]) fi fi if test x$ac_success = xno; then HAVE_CXX$1=0 AC_MSG_NOTICE([No compiler with C++$1 support was found]) else HAVE_CXX$1=1 AC_DEFINE(HAVE_CXX$1,1, [define if the compiler supports basic C++$1 syntax]) fi AC_SUBST(HAVE_CXX$1) m4_if([$1], [17], [AC_MSG_WARN([C++17 is not yet standardized, so the checks may change in incompatible ways anytime])]) ]) dnl Test body for checking C++11 support m4_define([_AX_CXX_COMPILE_STDCXX_testbody_11], _AX_CXX_COMPILE_STDCXX_testbody_new_in_11 ) dnl Test body for checking C++14 support m4_define([_AX_CXX_COMPILE_STDCXX_testbody_14], _AX_CXX_COMPILE_STDCXX_testbody_new_in_11 _AX_CXX_COMPILE_STDCXX_testbody_new_in_14 ) m4_define([_AX_CXX_COMPILE_STDCXX_testbody_17], _AX_CXX_COMPILE_STDCXX_testbody_new_in_11 _AX_CXX_COMPILE_STDCXX_testbody_new_in_14 _AX_CXX_COMPILE_STDCXX_testbody_new_in_17 ) dnl Tests for new features in C++11 m4_define([_AX_CXX_COMPILE_STDCXX_testbody_new_in_11], [[ // If the compiler admits that it is not ready for C++11, why torture it? // Hopefully, this will speed up the test. #ifndef __cplusplus #error "This is not a C++ compiler" #elif __cplusplus < 201103L && !(defined _MSC_VER) #error "This is not a C++11 compiler" #else namespace cxx11 { namespace test_static_assert { template <typename T> struct check { static_assert(sizeof(int) <= sizeof(T), "not big enough"); }; } namespace test_final_override { struct Base { virtual void f() {} }; struct Derived : public Base { virtual void f() override {} }; } namespace test_double_right_angle_brackets { template < typename T > struct check {}; typedef check<void> single_type; typedef check<check<void>> double_type; typedef check<check<check<void>>> triple_type; typedef check<check<check<check<void>>>> quadruple_type; } namespace test_decltype { int f() { int a = 1; decltype(a) b = 2; return a + b; } } namespace test_type_deduction { template < typename T1, typename T2 > struct is_same { static const bool value = false; }; template < typename T > struct is_same<T, T> { static const bool value = true; }; template < typename T1, typename T2 > auto add(T1 a1, T2 a2) -> decltype(a1 + a2) { return a1 + a2; } int test(const int c, volatile int v) { static_assert(is_same<int, decltype(0)>::value == true, ""); static_assert(is_same<int, decltype(c)>::value == false, ""); static_assert(is_same<int, decltype(v)>::value == false, ""); auto ac = c; auto av = v; auto sumi = ac + av + 'x'; auto sumf = ac + av + 1.0; static_assert(is_same<int, decltype(ac)>::value == true, ""); static_assert(is_same<int, decltype(av)>::value == true, ""); static_assert(is_same<int, decltype(sumi)>::value == true, ""); static_assert(is_same<int, decltype(sumf)>::value == false, ""); static_assert(is_same<int, decltype(add(c, v))>::value == true, ""); return (sumf > 0.0) ? sumi : add(c, v); } } namespace test_noexcept { int f() { return 0; } int g() noexcept { return 0; } static_assert(noexcept(f()) == false, ""); static_assert(noexcept(g()) == true, ""); } namespace test_constexpr { template < typename CharT > unsigned long constexpr strlen_c_r(const CharT *const s, const unsigned long acc) noexcept { return *s ? strlen_c_r(s + 1, acc + 1) : acc; } template < typename CharT > unsigned long constexpr strlen_c(const CharT *const s) noexcept { return strlen_c_r(s, 0UL); } static_assert(strlen_c("") == 0UL, ""); static_assert(strlen_c("1") == 1UL, ""); static_assert(strlen_c("example") == 7UL, ""); static_assert(strlen_c("another\0example") == 7UL, ""); } namespace test_rvalue_references { template < int N > struct answer { static constexpr int value = N; }; answer<1> f(int&) { return answer<1>(); } answer<2> f(const int&) { return answer<2>(); } answer<3> f(int&&) { return answer<3>(); } void test() { int i = 0; const int c = 0; static_assert(decltype(f(i))::value == 1, ""); static_assert(decltype(f(c))::value == 2, ""); static_assert(decltype(f(0))::value == 3, ""); } } namespace test_uniform_initialization { struct test { static const int zero {}; static const int one {1}; }; static_assert(test::zero == 0, ""); static_assert(test::one == 1, ""); } namespace test_lambdas { void test1() { auto lambda1 = [](){}; auto lambda2 = lambda1; lambda1(); lambda2(); } int test2() { auto a = [](int i, int j){ return i + j; }(1, 2); auto b = []() -> int { return '0'; }(); auto c = [=](){ return a + b; }(); auto d = [&](){ return c; }(); auto e = [a, &b](int x) mutable { const auto identity = [](int y){ return y; }; for (auto i = 0; i < a; ++i) a += b--; return x + identity(a + b); }(0); return a + b + c + d + e; } int test3() { const auto nullary = [](){ return 0; }; const auto unary = [](int x){ return x; }; using nullary_t = decltype(nullary); using unary_t = decltype(unary); const auto higher1st = [](nullary_t f){ return f(); }; const auto higher2nd = [unary](nullary_t f1){ return [unary, f1](unary_t f2){ return f2(unary(f1())); }; }; return higher1st(nullary) + higher2nd(nullary)(unary); } } namespace test_variadic_templates { template <int...> struct sum; template <int N0, int... N1toN> struct sum<N0, N1toN...> { static constexpr auto value = N0 + sum<N1toN...>::value; }; template <> struct sum<> { static constexpr auto value = 0; }; static_assert(sum<>::value == 0, ""); static_assert(sum<1>::value == 1, ""); static_assert(sum<23>::value == 23, ""); static_assert(sum<1, 2>::value == 3, ""); static_assert(sum<5, 5, 11>::value == 21, ""); static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, ""); } // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function // because of this. namespace test_template_alias_sfinae { struct foo {}; template<typename T> using member = typename T::member_type; template<typename T> void func(...) {} template<typename T> void func(member<T>*) {} void test(); void test() { func<foo>(0); } } } // namespace cxx11 #endif // __cplusplus >= 201103L ]]) dnl Tests for new features in C++14 m4_define([_AX_CXX_COMPILE_STDCXX_testbody_new_in_14], [[ // If the compiler admits that it is not ready for C++14, why torture it? // Hopefully, this will speed up the test. #ifndef __cplusplus #error "This is not a C++ compiler" #elif __cplusplus < 201402L #error "This is not a C++14 compiler" #else namespace cxx14 { namespace test_polymorphic_lambdas { int test() { const auto lambda = [](auto&&... args){ const auto istiny = [](auto x){ return (sizeof(x) == 1UL) ? 1 : 0; }; const int aretiny[] = { istiny(args)... }; return aretiny[0]; }; return lambda(1, 1L, 1.0f, '1'); } } namespace test_binary_literals { constexpr auto ivii = 0b0000000000101010; static_assert(ivii == 42, "wrong value"); } namespace test_generalized_constexpr { template < typename CharT > constexpr unsigned long strlen_c(const CharT *const s) noexcept { auto length = 0UL; for (auto p = s; *p; ++p) ++length; return length; } static_assert(strlen_c("") == 0UL, ""); static_assert(strlen_c("x") == 1UL, ""); static_assert(strlen_c("test") == 4UL, ""); static_assert(strlen_c("another\0test") == 7UL, ""); } namespace test_lambda_init_capture { int test() { auto x = 0; const auto lambda1 = [a = x](int b){ return a + b; }; const auto lambda2 = [a = lambda1(x)](){ return a; }; return lambda2(); } } namespace test_digit_separators { constexpr auto ten_million = 100'000'000; static_assert(ten_million == 100000000, ""); } namespace test_return_type_deduction { auto f(int& x) { return x; } decltype(auto) g(int& x) { return x; } template < typename T1, typename T2 > struct is_same { static constexpr auto value = false; }; template < typename T > struct is_same<T, T> { static constexpr auto value = true; }; int test() { auto x = 0; static_assert(is_same<int, decltype(f(x))>::value, ""); static_assert(is_same<int&, decltype(g(x))>::value, ""); return x; } } } // namespace cxx14 #endif // __cplusplus >= 201402L ]]) dnl Tests for new features in C++17 m4_define([_AX_CXX_COMPILE_STDCXX_testbody_new_in_17], [[ // If the compiler admits that it is not ready for C++17, why torture it? // Hopefully, this will speed up the test. #ifndef __cplusplus #error "This is not a C++ compiler" #elif __cplusplus <= 201402L #error "This is not a C++17 compiler" #else #if defined(__clang__) #define REALLY_CLANG #else #if defined(__GNUC__) #define REALLY_GCC #endif #endif #include <initializer_list> #include <utility> #include <type_traits> namespace cxx17 { #if !defined(REALLY_CLANG) namespace test_constexpr_lambdas { // TODO: test it with clang++ from git constexpr int foo = [](){return 42;}(); } #endif // !defined(REALLY_CLANG) namespace test::nested_namespace::definitions { } namespace test_fold_expression { template<typename... Args> int multiply(Args... args) { return (args * ... * 1); } template<typename... Args> bool all(Args... args) { return (args && ...); } } namespace test_extended_static_assert { static_assert (true); } namespace test_auto_brace_init_list { auto foo = {5}; auto bar {5}; static_assert(std::is_same<std::initializer_list<int>, decltype(foo)>::value); static_assert(std::is_same<int, decltype(bar)>::value); } namespace test_typename_in_template_template_parameter { template<template<typename> typename X> struct D; } namespace test_fallthrough_nodiscard_maybe_unused_attributes { int f1() { return 42; } [[nodiscard]] int f2() { [[maybe_unused]] auto unused = f1(); switch (f1()) { case 17: f1(); [[fallthrough]]; case 42: f1(); } return f1(); } } namespace test_extended_aggregate_initialization { struct base1 { int b1, b2 = 42; }; struct base2 { base2() { b3 = 42; } int b3; }; struct derived : base1, base2 { int d; }; derived d1 {{1, 2}, {}, 4}; // full initialization derived d2 {{}, {}, 4}; // value-initialized bases } namespace test_general_range_based_for_loop { struct iter { int i; int& operator* () { return i; } const int& operator* () const { return i; } iter& operator++() { ++i; return *this; } }; struct sentinel { int i; }; bool operator== (const iter& i, const sentinel& s) { return i.i == s.i; } bool operator!= (const iter& i, const sentinel& s) { return !(i == s); } struct range { iter begin() const { return {0}; } sentinel end() const { return {5}; } }; void f() { range r {}; for (auto i : r) { [[maybe_unused]] auto v = i; } } } namespace test_lambda_capture_asterisk_this_by_value { struct t { int i; int foo() { return [*this]() { return i; }(); } }; } namespace test_enum_class_construction { enum class byte : unsigned char {}; byte foo {42}; } namespace test_constexpr_if { template <bool cond> int f () { if constexpr(cond) { return 13; } else { return 42; } } } namespace test_selection_statement_with_initializer { int f() { return 13; } int f2() { if (auto i = f(); i > 0) { return 3; } switch (auto i = f(); i + 4) { case 17: return 2; default: return 1; } } } #if !defined(REALLY_CLANG) namespace test_template_argument_deduction_for_class_templates { // TODO: test it with clang++ from git template <typename T1, typename T2> struct pair { pair (T1 p1, T2 p2) : m1 {p1}, m2 {p2} {} T1 m1; T2 m2; }; void f() { [[maybe_unused]] auto p = pair{13, 42u}; } } #endif // !defined(REALLY_CLANG) namespace test_non_type_auto_template_parameters { template <auto n> struct B {}; B<5> b1; B<'a'> b2; } #if !defined(REALLY_CLANG) namespace test_structured_bindings { // TODO: test it with clang++ from git int arr[2] = { 1, 2 }; std::pair<int, int> pr = { 1, 2 }; auto f1() -> int(&)[2] { return arr; } auto f2() -> std::pair<int, int>& { return pr; } struct S { int x1 : 2; volatile double y1; }; S f3() { return {}; } auto [ x1, y1 ] = f1(); auto& [ xr1, yr1 ] = f1(); auto [ x2, y2 ] = f2(); auto& [ xr2, yr2 ] = f2(); const auto [ x3, y3 ] = f3(); } #endif // !defined(REALLY_CLANG) #if !defined(REALLY_CLANG) namespace test_exception_spec_type_system { // TODO: test it with clang++ from git struct Good {}; struct Bad {}; void g1() noexcept; void g2(); template<typename T> Bad f(T*, T*); template<typename T1, typename T2> Good f(T1*, T2*); static_assert (std::is_same_v<Good, decltype(f(g1, g2))>); } #endif // !defined(REALLY_CLANG) namespace test_inline_variables { template<class T> void f(T) {} template<class T> inline T g(T) { return T{}; } template<> inline void f<>(int) {} template<> int g<>(int) { return 5; } } } // namespace cxx17 #endif // __cplusplus <= 201402L ]]) ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/m4/ax_gcc_func_attribute.m4�����������������������������������������������������������0000644�0001750�0001750�00000020150�13407473054�015172� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������# =========================================================================== # https://www.gnu.org/software/autoconf-archive/ax_gcc_func_attribute.html # =========================================================================== # # SYNOPSIS # # AX_GCC_FUNC_ATTRIBUTE(ATTRIBUTE) # # DESCRIPTION # # This macro checks if the compiler supports one of GCC's function # attributes; many other compilers also provide function attributes with # the same syntax. Compiler warnings are used to detect supported # attributes as unsupported ones are ignored by default so quieting # warnings when using this macro will yield false positives. # # The ATTRIBUTE parameter holds the name of the attribute to be checked. # # If ATTRIBUTE is supported define HAVE_FUNC_ATTRIBUTE_<ATTRIBUTE>. # # The macro caches its result in the ax_cv_have_func_attribute_<attribute> # variable. # # The macro currently supports the following function attributes: # # alias # aligned # alloc_size # always_inline # artificial # cold # const # constructor # constructor_priority for constructor attribute with priority # deprecated # destructor # dllexport # dllimport # error # externally_visible # fallthrough # flatten # format # format_arg # gnu_inline # hot # ifunc # leaf # malloc # noclone # noinline # nonnull # noreturn # nothrow # optimize # pure # sentinel # sentinel_position # unused # used # visibility # warning # warn_unused_result # weak # weakref # # Unsupported function attributes will be tested with a prototype # returning an int and not accepting any arguments and the result of the # check might be wrong or meaningless so use with care. # # LICENSE # # Copyright (c) 2013 Gabriele Svelto <gabriele.svelto@gmail.com> # # Copying and distribution of this file, with or without modification, are # permitted in any medium without royalty provided the copyright notice # and this notice are preserved. This file is offered as-is, without any # warranty. #serial 9 AC_DEFUN([AX_GCC_FUNC_ATTRIBUTE], [ AS_VAR_PUSHDEF([ac_var], [ax_cv_have_func_attribute_$1]) AC_CACHE_CHECK([for __attribute__(($1))], [ac_var], [ AC_LINK_IFELSE([AC_LANG_PROGRAM([ m4_case([$1], [alias], [ int foo( void ) { return 0; } int bar( void ) __attribute__(($1("foo"))); ], [aligned], [ int foo( void ) __attribute__(($1(32))); ], [alloc_size], [ void *foo(int a) __attribute__(($1(1))); ], [always_inline], [ inline __attribute__(($1)) int foo( void ) { return 0; } ], [artificial], [ inline __attribute__(($1)) int foo( void ) { return 0; } ], [cold], [ int foo( void ) __attribute__(($1)); ], [const], [ int foo( void ) __attribute__(($1)); ], [constructor_priority], [ int foo( void ) __attribute__((__constructor__(65535/2))); ], [constructor], [ int foo( void ) __attribute__(($1)); ], [deprecated], [ int foo( void ) __attribute__(($1(""))); ], [destructor], [ int foo( void ) __attribute__(($1)); ], [dllexport], [ __attribute__(($1)) int foo( void ) { return 0; } ], [dllimport], [ int foo( void ) __attribute__(($1)); ], [error], [ int foo( void ) __attribute__(($1(""))); ], [externally_visible], [ int foo( void ) __attribute__(($1)); ], [fallthrough], [ int foo( void ) {switch (0) { case 1: __attribute__(($1)); case 2: break ; }}; ], [flatten], [ int foo( void ) __attribute__(($1)); ], [format], [ int foo(const char *p, ...) __attribute__(($1(printf, 1, 2))); ], [format_arg], [ char *foo(const char *p) __attribute__(($1(1))); ], [gnu_inline], [ inline __attribute__(($1)) int foo( void ) { return 0; } ], [hot], [ int foo( void ) __attribute__(($1)); ], [ifunc], [ int my_foo( void ) { return 0; } static int (*resolve_foo(void))(void) { return my_foo; } int foo( void ) __attribute__(($1("resolve_foo"))); ], [leaf], [ __attribute__(($1)) int foo( void ) { return 0; } ], [malloc], [ void *foo( void ) __attribute__(($1)); ], [noclone], [ int foo( void ) __attribute__(($1)); ], [noinline], [ __attribute__(($1)) int foo( void ) { return 0; } ], [nonnull], [ int foo(char *p) __attribute__(($1(1))); ], [noreturn], [ void foo( void ) __attribute__(($1)); ], [nothrow], [ int foo( void ) __attribute__(($1)); ], [optimize], [ __attribute__(($1(3))) int foo( void ) { return 0; } ], [pure], [ int foo( void ) __attribute__(($1)); ], [sentinel], [ int foo(void *p, ...) __attribute__(($1)); ], [sentinel_position], [ int foo(void *p, ...) __attribute__(($1(1))); ], [returns_nonnull], [ void *foo( void ) __attribute__(($1)); ], [unused], [ int foo( void ) __attribute__(($1)); ], [used], [ int foo( void ) __attribute__(($1)); ], [visibility], [ int foo_def( void ) __attribute__(($1("default"))); int foo_hid( void ) __attribute__(($1("hidden"))); int foo_int( void ) __attribute__(($1("internal"))); int foo_pro( void ) __attribute__(($1("protected"))); ], [warning], [ int foo( void ) __attribute__(($1(""))); ], [warn_unused_result], [ int foo( void ) __attribute__(($1)); ], [weak], [ int foo( void ) __attribute__(($1)); ], [weakref], [ static int foo( void ) { return 0; } static int bar( void ) __attribute__(($1("foo"))); ], [ m4_warn([syntax], [Unsupported attribute $1, the test may fail]) int foo( void ) __attribute__(($1)); ] )], []) ], dnl GCC doesn't exit with an error if an unknown attribute is dnl provided but only outputs a warning, so accept the attribute dnl only if no warning were issued. [AS_IF([test -s conftest.err], [AS_VAR_SET([ac_var], [no])], [AS_VAR_SET([ac_var], [yes])])], [AS_VAR_SET([ac_var], [no])]) ]) AS_IF([test yes = AS_VAR_GET([ac_var])], [AC_DEFINE_UNQUOTED(AS_TR_CPP(HAVE_FUNC_ATTRIBUTE_$1), 1, [Define to 1 if the system has the `$1' function attribute])], []) AS_VAR_POPDEF([ac_var]) ]) ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/m4/ax_cxx_compile_stdcxx_11.m4��������������������������������������������������������0000664�0001750�0001750�00000003215�13407173247�015556� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������# ============================================================================= # https://www.gnu.org/software/autoconf-archive/ax_cxx_compile_stdcxx_11.html # ============================================================================= # # SYNOPSIS # # AX_CXX_COMPILE_STDCXX_11([ext|noext], [mandatory|optional]) # # DESCRIPTION # # Check for baseline language coverage in the compiler for the C++11 # standard; if necessary, add switches to CXX and CXXCPP to enable # support. # # This macro is a convenience alias for calling the AX_CXX_COMPILE_STDCXX # macro with the version set to C++11. The two optional arguments are # forwarded literally as the second and third argument respectively. # Please see the documentation for the AX_CXX_COMPILE_STDCXX macro for # more information. If you want to use this macro, you also need to # download the ax_cxx_compile_stdcxx.m4 file. # # LICENSE # # Copyright (c) 2008 Benjamin Kosnik <bkoz@redhat.com> # Copyright (c) 2012 Zack Weinberg <zackw@panix.com> # Copyright (c) 2013 Roy Stogner <roystgnr@ices.utexas.edu> # Copyright (c) 2014, 2015 Google Inc.; contributed by Alexey Sokolov <sokolov@google.com> # Copyright (c) 2015 Paul Norman <penorman@mac.com> # Copyright (c) 2015 Moritz Klammler <moritz@klammler.eu> # # Copying and distribution of this file, with or without modification, are # permitted in any medium without royalty provided the copyright notice # and this notice are preserved. This file is offered as-is, without any # warranty. #serial 18 AX_REQUIRE_DEFINED([AX_CXX_COMPILE_STDCXX]) AC_DEFUN([AX_CXX_COMPILE_STDCXX_11], [AX_CXX_COMPILE_STDCXX([11], [$1], [$2])]) �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/m4/lt~obsolete.m4���������������������������������������������������������������������0000644�0001750�0001750�00000013774�13341246640�013234� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������# lt~obsolete.m4 -- aclocal satisfying obsolete definitions. -*-Autoconf-*- # # Copyright (C) 2004-2005, 2007, 2009, 2011-2015 Free Software # Foundation, Inc. # Written by Scott James Remnant, 2004. # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. # serial 5 lt~obsolete.m4 # These exist entirely to fool aclocal when bootstrapping libtool. # # In the past libtool.m4 has provided macros via AC_DEFUN (or AU_DEFUN), # which have later been changed to m4_define as they aren't part of the # exported API, or moved to Autoconf or Automake where they belong. # # The trouble is, aclocal is a bit thick. It'll see the old AC_DEFUN # in /usr/share/aclocal/libtool.m4 and remember it, then when it sees us # using a macro with the same name in our local m4/libtool.m4 it'll # pull the old libtool.m4 in (it doesn't see our shiny new m4_define # and doesn't know about Autoconf macros at all.) # # So we provide this file, which has a silly filename so it's always # included after everything else. This provides aclocal with the # AC_DEFUNs it wants, but when m4 processes it, it doesn't do anything # because those macros already exist, or will be overwritten later. # We use AC_DEFUN over AU_DEFUN for compatibility with aclocal-1.6. # # Anytime we withdraw an AC_DEFUN or AU_DEFUN, remember to add it here. # Yes, that means every name once taken will need to remain here until # we give up compatibility with versions before 1.7, at which point # we need to keep only those names which we still refer to. # This is to help aclocal find these macros, as it can't see m4_define. AC_DEFUN([LTOBSOLETE_VERSION], [m4_if([1])]) m4_ifndef([AC_LIBTOOL_LINKER_OPTION], [AC_DEFUN([AC_LIBTOOL_LINKER_OPTION])]) m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP])]) m4_ifndef([_LT_AC_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH])]) m4_ifndef([_LT_AC_SHELL_INIT], [AC_DEFUN([_LT_AC_SHELL_INIT])]) m4_ifndef([_LT_AC_SYS_LIBPATH_AIX], [AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX])]) m4_ifndef([_LT_PROG_LTMAIN], [AC_DEFUN([_LT_PROG_LTMAIN])]) m4_ifndef([_LT_AC_TAGVAR], [AC_DEFUN([_LT_AC_TAGVAR])]) m4_ifndef([AC_LTDL_ENABLE_INSTALL], [AC_DEFUN([AC_LTDL_ENABLE_INSTALL])]) m4_ifndef([AC_LTDL_PREOPEN], [AC_DEFUN([AC_LTDL_PREOPEN])]) m4_ifndef([_LT_AC_SYS_COMPILER], [AC_DEFUN([_LT_AC_SYS_COMPILER])]) m4_ifndef([_LT_AC_LOCK], [AC_DEFUN([_LT_AC_LOCK])]) m4_ifndef([AC_LIBTOOL_SYS_OLD_ARCHIVE], [AC_DEFUN([AC_LIBTOOL_SYS_OLD_ARCHIVE])]) m4_ifndef([_LT_AC_TRY_DLOPEN_SELF], [AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF])]) m4_ifndef([AC_LIBTOOL_PROG_CC_C_O], [AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O])]) m4_ifndef([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS])]) m4_ifndef([AC_LIBTOOL_OBJDIR], [AC_DEFUN([AC_LIBTOOL_OBJDIR])]) m4_ifndef([AC_LTDL_OBJDIR], [AC_DEFUN([AC_LTDL_OBJDIR])]) m4_ifndef([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH])]) m4_ifndef([AC_LIBTOOL_SYS_LIB_STRIP], [AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP])]) m4_ifndef([AC_PATH_MAGIC], [AC_DEFUN([AC_PATH_MAGIC])]) m4_ifndef([AC_PROG_LD_GNU], [AC_DEFUN([AC_PROG_LD_GNU])]) m4_ifndef([AC_PROG_LD_RELOAD_FLAG], [AC_DEFUN([AC_PROG_LD_RELOAD_FLAG])]) m4_ifndef([AC_DEPLIBS_CHECK_METHOD], [AC_DEFUN([AC_DEPLIBS_CHECK_METHOD])]) m4_ifndef([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI])]) m4_ifndef([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE])]) m4_ifndef([AC_LIBTOOL_PROG_COMPILER_PIC], [AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC])]) m4_ifndef([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS])]) m4_ifndef([AC_LIBTOOL_POSTDEP_PREDEP], [AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP])]) m4_ifndef([LT_AC_PROG_EGREP], [AC_DEFUN([LT_AC_PROG_EGREP])]) m4_ifndef([LT_AC_PROG_SED], [AC_DEFUN([LT_AC_PROG_SED])]) m4_ifndef([_LT_CC_BASENAME], [AC_DEFUN([_LT_CC_BASENAME])]) m4_ifndef([_LT_COMPILER_BOILERPLATE], [AC_DEFUN([_LT_COMPILER_BOILERPLATE])]) m4_ifndef([_LT_LINKER_BOILERPLATE], [AC_DEFUN([_LT_LINKER_BOILERPLATE])]) m4_ifndef([_AC_PROG_LIBTOOL], [AC_DEFUN([_AC_PROG_LIBTOOL])]) m4_ifndef([AC_LIBTOOL_SETUP], [AC_DEFUN([AC_LIBTOOL_SETUP])]) m4_ifndef([_LT_AC_CHECK_DLFCN], [AC_DEFUN([_LT_AC_CHECK_DLFCN])]) m4_ifndef([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER])]) m4_ifndef([_LT_AC_TAGCONFIG], [AC_DEFUN([_LT_AC_TAGCONFIG])]) m4_ifndef([AC_DISABLE_FAST_INSTALL], [AC_DEFUN([AC_DISABLE_FAST_INSTALL])]) m4_ifndef([_LT_AC_LANG_CXX], [AC_DEFUN([_LT_AC_LANG_CXX])]) m4_ifndef([_LT_AC_LANG_F77], [AC_DEFUN([_LT_AC_LANG_F77])]) m4_ifndef([_LT_AC_LANG_GCJ], [AC_DEFUN([_LT_AC_LANG_GCJ])]) m4_ifndef([AC_LIBTOOL_LANG_C_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG])]) m4_ifndef([_LT_AC_LANG_C_CONFIG], [AC_DEFUN([_LT_AC_LANG_C_CONFIG])]) m4_ifndef([AC_LIBTOOL_LANG_CXX_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG])]) m4_ifndef([_LT_AC_LANG_CXX_CONFIG], [AC_DEFUN([_LT_AC_LANG_CXX_CONFIG])]) m4_ifndef([AC_LIBTOOL_LANG_F77_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG])]) m4_ifndef([_LT_AC_LANG_F77_CONFIG], [AC_DEFUN([_LT_AC_LANG_F77_CONFIG])]) m4_ifndef([AC_LIBTOOL_LANG_GCJ_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG])]) m4_ifndef([_LT_AC_LANG_GCJ_CONFIG], [AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG])]) m4_ifndef([AC_LIBTOOL_LANG_RC_CONFIG], [AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG])]) m4_ifndef([_LT_AC_LANG_RC_CONFIG], [AC_DEFUN([_LT_AC_LANG_RC_CONFIG])]) m4_ifndef([AC_LIBTOOL_CONFIG], [AC_DEFUN([AC_LIBTOOL_CONFIG])]) m4_ifndef([_LT_AC_FILE_LTDLL_C], [AC_DEFUN([_LT_AC_FILE_LTDLL_C])]) m4_ifndef([_LT_REQUIRED_DARWIN_CHECKS], [AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS])]) m4_ifndef([_LT_AC_PROG_CXXCPP], [AC_DEFUN([_LT_AC_PROG_CXXCPP])]) m4_ifndef([_LT_PREPARE_SED_QUOTE_VARS], [AC_DEFUN([_LT_PREPARE_SED_QUOTE_VARS])]) m4_ifndef([_LT_PROG_ECHO_BACKSLASH], [AC_DEFUN([_LT_PROG_ECHO_BACKSLASH])]) m4_ifndef([_LT_PROG_F77], [AC_DEFUN([_LT_PROG_F77])]) m4_ifndef([_LT_PROG_FC], [AC_DEFUN([_LT_PROG_FC])]) m4_ifndef([_LT_PROG_CXX], [AC_DEFUN([_LT_PROG_CXX])]) ����libcmis-0.5.2/Makefile.am���������������������������������������������������������������������������0000664�0001750�0001750�00000002343�13407704503�012124� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������include $(top_srcdir)/coverage.mk SUBDIRS = inc src if ENABLE_TESTS SUBDIRS += qa endif ACLOCAL_AMFLAGS = -I m4 pkgconfig_DATA = \ libcmis-@LIBCMIS_API_VERSION@.pc \ libcmis-c-@LIBCMIS_API_VERSION@.pc pkgconfigdir = $(libdir)/pkgconfig if ENABLE_MAN cmis-client.1: doc/cmis-client.xml $(DOCBOOK2MAN) $< man_MANS = cmis-client.1 endif EXTRA_DIST = \ libcmis.pc.in \ libcmis-c.pc.in \ COPYING.MPL \ COPYING.GPL \ COPYING.LGPL \ doc/cmis-client.xml.in \ cppcheck-suppress \ qa/libcmis/data DISTCLEANFILES = \ cmis-client.1 \ libcmis-@LIBCMIS_API_VERSION@.pc \ libcmis-c-@LIBCMIS_API_VERSION@.pc dist-hook: @if test -d "$(srcdir)/.git"; \ then \ echo Creating ChangeLog && \ ( cd "$(top_srcdir)" && \ echo '# Generated by Makefile. Do not edit.'; echo; \ $(top_srcdir)/missing --run git log --pretty=medium ) > ChangeLog.tmp \ && mv -f ChangeLog.tmp $(top_distdir)/ChangeLog \ || ( rm -f ChangeLog.tmp ; \ echo Failed to generate ChangeLog >&2 ); \ else \ echo A git clone is required to generate a ChangeLog >&2; \ fi cppcheck: @CPPCHECK@ -q --enable=style,performance,portability \ -j @CPPCHECK_PARALLELISM@ \ --suppressions-list=@SRCDIR@/cppcheck-suppress \ --error-exitcode=1 @SRCDIR@ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/libcmis.pc.in�������������������������������������������������������������������������0000664�0001750�0001750�00000000441�13407173247�012445� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������prefix=@prefix@ exec_prefix=@exec_prefix@ libdir=@libdir@ includedir=@includedir@ Name: libcmis Description: CMIS protocol client library Version: @VERSION@ Requires: libcurl libxml-2.0 Libs: -L${libdir} -lcmis-@LIBCMIS_API_VERSION@ Cflags: -I${includedir}/libcmis-@LIBCMIS_API_VERSION@ �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/missing�������������������������������������������������������������������������������0000755�0001750�0001750�00000015336�13407230143�011465� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������#! /bin/sh # Common wrapper for a few potentially missing GNU programs. scriptversion=2018-03-07.03; # UTC # Copyright (C) 1996-2018 Free Software Foundation, Inc. # Originally written by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # You should have received a copy of the GNU General Public License # along with this program. If not, see <https://www.gnu.org/licenses/>. # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. if test $# -eq 0; then echo 1>&2 "Try '$0 --help' for more information" exit 1 fi case $1 in --is-lightweight) # Used by our autoconf macros to check whether the available missing # script is modern enough. exit 0 ;; --run) # Back-compat with the calling convention used by older automake. shift ;; -h|--h|--he|--hel|--help) echo "\ $0 [OPTION]... PROGRAM [ARGUMENT]... Run 'PROGRAM [ARGUMENT]...', returning a proper advice when this fails due to PROGRAM being missing or too old. Options: -h, --help display this help and exit -v, --version output version information and exit Supported PROGRAM values: aclocal autoconf autoheader autom4te automake makeinfo bison yacc flex lex help2man Version suffixes to PROGRAM as well as the prefixes 'gnu-', 'gnu', and 'g' are ignored when checking the name. Send bug reports to <bug-automake@gnu.org>." exit $? ;; -v|--v|--ve|--ver|--vers|--versi|--versio|--version) echo "missing $scriptversion (GNU Automake)" exit $? ;; -*) echo 1>&2 "$0: unknown '$1' option" echo 1>&2 "Try '$0 --help' for more information" exit 1 ;; esac # Run the given program, remember its exit status. "$@"; st=$? # If it succeeded, we are done. test $st -eq 0 && exit 0 # Also exit now if we it failed (or wasn't found), and '--version' was # passed; such an option is passed most likely to detect whether the # program is present and works. case $2 in --version|--help) exit $st;; esac # Exit code 63 means version mismatch. This often happens when the user # tries to use an ancient version of a tool on a file that requires a # minimum version. if test $st -eq 63; then msg="probably too old" elif test $st -eq 127; then # Program was missing. msg="missing on your system" else # Program was found and executed, but failed. Give up. exit $st fi perl_URL=https://www.perl.org/ flex_URL=https://github.com/westes/flex gnu_software_URL=https://www.gnu.org/software program_details () { case $1 in aclocal|automake) echo "The '$1' program is part of the GNU Automake package:" echo "<$gnu_software_URL/automake>" echo "It also requires GNU Autoconf, GNU m4 and Perl in order to run:" echo "<$gnu_software_URL/autoconf>" echo "<$gnu_software_URL/m4/>" echo "<$perl_URL>" ;; autoconf|autom4te|autoheader) echo "The '$1' program is part of the GNU Autoconf package:" echo "<$gnu_software_URL/autoconf/>" echo "It also requires GNU m4 and Perl in order to run:" echo "<$gnu_software_URL/m4/>" echo "<$perl_URL>" ;; esac } give_advice () { # Normalize program name to check for. normalized_program=`echo "$1" | sed ' s/^gnu-//; t s/^gnu//; t s/^g//; t'` printf '%s\n' "'$1' is $msg." configure_deps="'configure.ac' or m4 files included by 'configure.ac'" case $normalized_program in autoconf*) echo "You should only need it if you modified 'configure.ac'," echo "or m4 files included by it." program_details 'autoconf' ;; autoheader*) echo "You should only need it if you modified 'acconfig.h' or" echo "$configure_deps." program_details 'autoheader' ;; automake*) echo "You should only need it if you modified 'Makefile.am' or" echo "$configure_deps." program_details 'automake' ;; aclocal*) echo "You should only need it if you modified 'acinclude.m4' or" echo "$configure_deps." program_details 'aclocal' ;; autom4te*) echo "You might have modified some maintainer files that require" echo "the 'autom4te' program to be rebuilt." program_details 'autom4te' ;; bison*|yacc*) echo "You should only need it if you modified a '.y' file." echo "You may want to install the GNU Bison package:" echo "<$gnu_software_URL/bison/>" ;; lex*|flex*) echo "You should only need it if you modified a '.l' file." echo "You may want to install the Fast Lexical Analyzer package:" echo "<$flex_URL>" ;; help2man*) echo "You should only need it if you modified a dependency" \ "of a man page." echo "You may want to install the GNU Help2man package:" echo "<$gnu_software_URL/help2man/>" ;; makeinfo*) echo "You should only need it if you modified a '.texi' file, or" echo "any other file indirectly affecting the aspect of the manual." echo "You might want to install the Texinfo package:" echo "<$gnu_software_URL/texinfo/>" echo "The spurious makeinfo call might also be the consequence of" echo "using a buggy 'make' (AIX, DU, IRIX), in which case you might" echo "want to install GNU make:" echo "<$gnu_software_URL/make/>" ;; *) echo "You might have modified some files without having the proper" echo "tools for further handling them. Check the 'README' file, it" echo "often tells you about the needed prerequisites for installing" echo "this package. You may also peek at any GNU archive site, in" echo "case some other package contains this missing '$1' program." ;; esac } give_advice "$1" | sed -e '1s/^/WARNING: /' \ -e '2,$s/^/ /' >&2 # Propagate the correct exit status (expected to be 127 for a program # not found, 63 for a program that failed due to version mismatch). exit $st # Local variables: # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" # time-stamp-end: "; # UTC" # End: ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/COPYING.GPL���������������������������������������������������������������������������0000664�0001750�0001750�00000043254�13407173247�011557� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������ GNU GENERAL PUBLIC LICENSE Version 2, June 1991 Copyright (C) 1989, 1991 Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. Preamble The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change free software--to make sure the software is free for all its users. This General Public License applies to most of the Free Software Foundation's software and to any other program whose authors commit to using it. (Some other Free Software Foundation software is covered by the GNU Lesser General Public License instead.) You can apply it to your programs, too. When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs; and that you know you can do these things. To protect your rights, we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights. These restrictions translate to certain responsibilities for you if you distribute copies of the software, or if you modify it. For example, if you distribute copies of such a program, whether gratis or for a fee, you must give the recipients all the rights that you have. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights. We protect your rights with two steps: (1) copyright the software, and (2) offer you this license which gives you legal permission to copy, distribute and/or modify the software. Also, for each author's protection and ours, we want to make certain that everyone understands that there is no warranty for this free software. If the software is modified by someone else and passed on, we want its recipients to know that what they have is not the original, so that any problems introduced by others will not reflect on the original authors' reputations. Finally, any free program is threatened constantly by software patents. We wish to avoid the danger that redistributors of a free program will individually obtain patent licenses, in effect making the program proprietary. To prevent this, we have made it clear that any patent must be licensed for everyone's free use or not licensed at all. The precise terms and conditions for copying, distribution and modification follow. GNU GENERAL PUBLIC LICENSE TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 0. This License applies to any program or other work which contains a notice placed by the copyright holder saying it may be distributed under the terms of this General Public License. The "Program", below, refers to any such program or work, and a "work based on the Program" means either the Program or any derivative work under copyright law: that is to say, a work containing the Program or a portion of it, either verbatim or with modifications and/or translated into another language. (Hereinafter, translation is included without limitation in the term "modification".) Each licensee is addressed as "you". Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running the Program is not restricted, and the output from the Program is covered only if its contents constitute a work based on the Program (independent of having been made by running the Program). Whether that is true depends on what the Program does. 1. You may copy and distribute verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and give any other recipients of the Program a copy of this License along with the Program. You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee. 2. You may modify your copy or copies of the Program or any portion of it, thus forming a work based on the Program, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions: a) You must cause the modified files to carry prominent notices stating that you changed the files and the date of any change. b) You must cause any work that you distribute or publish, that in whole or in part contains or is derived from the Program or any part thereof, to be licensed as a whole at no charge to all third parties under the terms of this License. c) If the modified program normally reads commands interactively when run, you must cause it, when started running for such interactive use in the most ordinary way, to print or display an announcement including an appropriate copyright notice and a notice that there is no warranty (or else, saying that you provide a warranty) and that users may redistribute the program under these conditions, and telling the user how to view a copy of this License. (Exception: if the Program itself is interactive but does not normally print such an announcement, your work based on the Program is not required to print an announcement.) These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Program, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Program, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it. Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Program. In addition, mere aggregation of another work not based on the Program with the Program (or with a work based on the Program) on a volume of a storage or distribution medium does not bring the other work under the scope of this License. 3. You may copy and distribute the Program (or a work based on it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you also do one of the following: a) Accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, b) Accompany it with a written offer, valid for at least three years, to give any third party, for a charge no more than your cost of physically performing source distribution, a complete machine-readable copy of the corresponding source code, to be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, c) Accompany it with the information you received as to the offer to distribute corresponding source code. (This alternative is allowed only for noncommercial distribution and only if you received the program in object code or executable form with such an offer, in accord with Subsection b above.) The source code for a work means the preferred form of the work for making modifications to it. For an executable work, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the executable. However, as a special exception, the source code distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable. If distribution of executable or object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place counts as distribution of the source code, even though third parties are not compelled to copy the source along with the object code. 4. You may not copy, modify, sublicense, or distribute the Program except as expressly provided under this License. Any attempt otherwise to copy, modify, sublicense or distribute the Program is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance. 5. You are not required to accept this License, since you have not signed it. However, nothing else grants you permission to modify or distribute the Program or its derivative works. These actions are prohibited by law if you do not accept this License. Therefore, by modifying or distributing the Program (or any work based on the Program), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Program or works based on it. 6. Each time you redistribute the Program (or any work based on the Program), the recipient automatically receives a license from the original licensor to copy, distribute or modify the Program subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein. You are not responsible for enforcing compliance by third parties to this License. 7. If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Program at all. For example, if a patent license would not permit royalty-free redistribution of the Program by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Program. If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply and the section as a whole is intended to apply in other circumstances. It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system, which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice. This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License. 8. If the distribution and/or use of the Program is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Program under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded. In such case, this License incorporates the limitation as if written in the body of this License. 9. The Free Software Foundation may publish revised and/or new versions of the General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. Each version is given a distinguishing version number. If the Program specifies a version number of this License which applies to it and "any later version", you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of this License, you may choose any version ever published by the Free Software Foundation. 10. If you wish to incorporate parts of the Program into other free programs whose distribution conditions are different, write to the author to ask for permission. For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this. Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally. NO WARRANTY 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. END OF TERMS AND CONDITIONS How to Apply These Terms to Your New Programs If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms. To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively convey the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found. <one line to give the program's name and a brief idea of what it does.> Copyright (C) <year> <name of author> This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. Also add information on how to contact you by electronic and paper mail. If the program is interactive, make it output a short notice like this when it starts in an interactive mode: Gnomovision version 69, Copyright (C) year name of author Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. This is free software, and you are welcome to redistribute it under certain conditions; type `show c' for details. The hypothetical commands `show w' and `show c' should show the appropriate parts of the General Public License. Of course, the commands you use may be called something other than `show w' and `show c'; they could even be mouse-clicks or menu items--whatever suits your program. You should also get your employer (if you work as a programmer) or your school, if any, to sign a "copyright disclaimer" for the program, if necessary. Here is a sample; alter the names: Yoyodyne, Inc., hereby disclaims all copyright interest in the program `Gnomovision' (which makes passes at compilers) written by James Hacker. <signature of Ty Coon>, 1 April 1989 Ty Coon, President of Vice This General Public License does not permit incorporating your program into proprietary programs. If your program is a subroutine library, you may consider it more useful to permit linking proprietary applications with the library. If this is what you want to do, use the GNU Lesser General Public License instead of this License. ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������libcmis-0.5.2/depcomp�������������������������������������������������������������������������������0000755�0001750�0001750�00000056020�13407230143�011436� �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������0000000�0000000������������������������������������������������������������������������������������������������������������������������������������������������������������������������#! /bin/sh # depcomp - compile a program generating dependencies as side-effects scriptversion=2018-03-07.03; # UTC # Copyright (C) 1999-2018 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # You should have received a copy of the GNU General Public License # along with this program. If not, see <https://www.gnu.org/licenses/>. # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # Originally written by Alexandre Oliva <oliva@dcc.unicamp.br>. case $1 in '') echo "$0: No command. Try '$0 --help' for more information." 1>&2 exit 1; ;; -h | --h*) cat <<\EOF Usage: depcomp [--help] [--version] PROGRAM [ARGS] Run PROGRAMS ARGS to compile a file, generating dependencies as side-effects. Environment variables: depmode Dependency tracking mode. source Source file read by 'PROGRAMS ARGS'. object Object file output by 'PROGRAMS ARGS'. DEPDIR directory where to store dependencies. depfile Dependency file to output. tmpdepfile Temporary file to use when outputting dependencies. libtool Whether libtool is used (yes/no). Report bugs to <bug-automake@gnu.org>. EOF exit $? ;; -v | --v*) echo "depcomp $scriptversion" exit $? ;; esac # Get the directory component of the given path, and save it in the # global variables '$dir'. Note that this directory component will # be either empty or ending with a '/' character. This is deliberate. set_dir_from () { case $1 in */*) dir=`echo "$1" | sed -e 's|/[^/]*$|/|'`;; *) dir=;; esac } # Get the suffix-stripped basename of the given path, and save it the # global variable '$base'. set_base_from () { base=`echo "$1" | sed -e 's|^.*/||' -e 's/\.[^.]*$//'` } # If no dependency file was actually created by the compiler invocation, # we still have to create a dummy depfile, to avoid errors with the # Makefile "include basename.Plo" scheme. make_dummy_depfile () { echo "#dummy" > "$depfile" } # Factor out some common post-processing of the generated depfile. # Requires the auxiliary global variable '$tmpdepfile' to be set. aix_post_process_depfile () { # If the compiler actually managed to produce a dependency file, # post-process it. if test -f "$tmpdepfile"; then # Each line is of the form 'foo.o: dependency.h'. # Do two passes, one to just change these to # $object: dependency.h # and one to simply output # dependency.h: # which is needed to avoid the deleted-header problem. { sed -e "s,^.*\.[$lower]*:,$object:," < "$tmpdepfile" sed -e "s,^.*\.[$lower]*:[$tab ]*,," -e 's,$,:,' < "$tmpdepfile" } > "$depfile" rm -f "$tmpdepfile" else make_dummy_depfile fi } # A tabulation character. tab=' ' # A newline character. nl=' ' # Character ranges might be problematic outside the C locale. # These definitions help. upper=ABCDEFGHIJKLMNOPQRSTUVWXYZ lower=abcdefghijklmnopqrstuvwxyz digits=0123456789 alpha=${upper}${lower} if test -z "$depmode" || test -z "$source" || test -z "$object"; then echo "depcomp: Variables source, object and depmode must be set" 1>&2 exit 1 fi # Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po. depfile=${depfile-`echo "$object" | sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`} tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`} rm -f "$tmpdepfile" # Avoid interferences from the environment. gccflag= dashmflag= # Some modes work just like other modes, but use different flags. We # parameterize here, but still list the modes in the big case below, # to make depend.m4 easier to write. Note that we *cannot* use a case # here, because this file can only contain one case statement. if test "$depmode" = hp; then # HP compiler uses -M and no extra arg. gccflag=-M depmode=gcc fi if test "$depmode" = dashXmstdout; then # This is just like dashmstdout with a different argument. dashmflag=-xM depmode=dashmstdout fi cygpath_u="cygpath -u -f -" if test "$depmode" = msvcmsys; then # This is just like msvisualcpp but w/o cygpath translation. # Just convert the backslash-escaped backslashes to single forward # slashes to satisfy depend.m4 cygpath_u='sed s,\\\\,/,g' depmode=msvisualcpp fi if test "$depmode" = msvc7msys; then # This is just like msvc7 but w/o cygpath translation. # Just convert the backslash-escaped backslashes to single forward # slashes to satisfy depend.m4 cygpath_u='sed s,\\\\,/,g' depmode=msvc7 fi if test "$depmode" = xlc; then # IBM C/C++ Compilers xlc/xlC can output gcc-like dependency information. gccflag=-qmakedep=gcc,-MF depmode=gcc fi case "$depmode" in gcc3) ## gcc 3 implements dependency tracking that does exactly what ## we want. Yay! Note: for some reason libtool 1.4 doesn't like ## it if -MD -MP comes after the -MF stuff. Hmm. ## Unfortunately, FreeBSD c89 acceptance of flags depends upon ## the command line argument order; so add the flags where they ## appear in depend2.am. Note that the slowdown incurred here ## affects only configure: in makefiles, %FASTDEP% shortcuts this. for arg do case $arg in -c) set fnord "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" "$arg" ;; *) set fnord "$@" "$arg" ;; esac shift # fnord shift # $arg done "$@" stat=$? if test $stat -ne 0; then rm -f "$tmpdepfile" exit $stat fi mv "$tmpdepfile" "$depfile" ;; gcc) ## Note that this doesn't just cater to obsosete pre-3.x GCC compilers. ## but also to in-use compilers like IMB xlc/xlC and the HP C compiler. ## (see the conditional assignment to $gccflag above). ## There are various ways to get dependency output from gcc. Here's ## why we pick this rather obscure method: ## - Don't want to use -MD because we'd like the dependencies to end ## up in a subdir. Having to rename by hand is ugly. ## (We might end up doing this anyway to support other compilers.) ## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like ## -MM, not -M (despite what the docs say). Also, it might not be ## supported by the other compilers which use the 'gcc' depmode. ## - Using -M directly means running the compiler twice (even worse ## than renaming). if test -z "$gccflag"; then gccflag=-MD, fi "$@" -Wp,"$gccflag$tmpdepfile" stat=$? if test $stat -ne 0; then rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" echo "$object : \\" > "$depfile" # The second -e expression handles DOS-style file names with drive # letters. sed -e 's/^[^:]*: / /' \ -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile" ## This next piece of magic avoids the "deleted header file" problem. ## The problem is that when a header file which appears in a .P file ## is deleted, the dependency causes make to die (because there is ## typically no way to rebuild the header). We avoid this by adding ## dummy dependencies for each header file. Too bad gcc doesn't do ## this for us directly. ## Some versions of gcc put a space before the ':'. On the theory ## that the space means something, we add a space to the output as ## well. hp depmode also adds that space, but also prefixes the VPATH ## to the object. Take care to not repeat it in the output. ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. tr ' ' "$nl" < "$tmpdepfile" \ | sed -e 's/^\\$//' -e '/^$/d' -e "s|.*$object$||" -e '/:$/d' \ | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; hp) # This case exists only to let depend.m4 do its work. It works by # looking at the text of this script. This case will never be run, # since it is checked for above. exit 1 ;; sgi) if test "$libtool" = yes; then "$@" "-Wp,-MDupdate,$tmpdepfile" else "$@" -MDupdate "$tmpdepfile" fi stat=$? if test $stat -ne 0; then rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files echo "$object : \\" > "$depfile" # Clip off the initial element (the dependent). Don't try to be # clever and replace this with sed code, as IRIX sed won't handle # lines with more than a fixed number of characters (4096 in # IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines; # the IRIX cc adds comments like '#:fec' to the end of the # dependency line. tr ' ' "$nl" < "$tmpdepfile" \ | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' \ | tr "$nl" ' ' >> "$depfile" echo >> "$depfile" # The second pass generates a dummy entry for each header file. tr ' ' "$nl" < "$tmpdepfile" \ | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \ >> "$depfile" else make_dummy_depfile fi rm -f "$tmpdepfile" ;; xlc) # This case exists only to let depend.m4 do its work. It works by # looking at the text of this script. This case will never be run, # since it is checked for above. exit 1 ;; aix) # The C for AIX Compiler uses -M and outputs the dependencies # in a .u file. In older versions, this file always lives in the # current directory. Also, the AIX compiler puts '$object:' at the # start of each line; $object doesn't have directory information. # Version 6 uses the directory in both cases. set_dir_from "$object" set_base_from "$object" if test "$libtool" = yes; then tmpdepfile1=$dir$base.u tmpdepfile2=$base.u tmpdepfile3=$dir.libs/$base.u "$@" -Wc,-M else tmpdepfile1=$dir$base.u tmpdepfile2=$dir$base.u tmpdepfile3=$dir$base.u "$@" -M fi stat=$? if test $stat -ne 0; then rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" exit $stat fi for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" do test -f "$tmpdepfile" && break done aix_post_process_depfile ;; tcc) # tcc (Tiny C Compiler) understand '-MD -MF file' since version 0.9.26 # FIXME: That version still under development at the moment of writing. # Make that this statement remains true also for stable, released # versions. # It will wrap lines (doesn't matter whether long or short) with a # trailing '\', as in: # # foo.o : \ # foo.c \ # foo.h \ # # It will put a trailing '\' even on the last line, and will use leading # spaces rather than leading tabs (at least since its commit 0394caf7 # "Emit spaces for -MD"). "$@" -MD -MF "$tmpdepfile" stat=$? if test $stat -ne 0; then rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" # Each non-empty line is of the form 'foo.o : \' or ' dep.h \'. # We have to change lines of the first kind to '$object: \'. sed -e "s|.*:|$object :|" < "$tmpdepfile" > "$depfile" # And for each line of the second kind, we have to emit a 'dep.h:' # dummy dependency, to avoid the deleted-header problem. sed -n -e 's|^ *\(.*\) *\\$|\1:|p' < "$tmpdepfile" >> "$depfile" rm -f "$tmpdepfile" ;; ## The order of this option in the case statement is important, since the ## shell code in configure will try each of these formats in the order ## listed in this file. A plain '-MD' option would be understood by many ## compilers, so we must ensure this comes after the gcc and icc options. pgcc) # Portland's C compiler understands '-MD'. # Will always output deps to 'file.d' where file is the root name of the # source file under compilation, even if file resides in a subdirectory. # The object file name does not affect the name of the '.d' file. # pgcc 10.2 will output # foo.o: sub/foo.c sub/foo.h # and will wrap long lines using '\' : # foo.o: sub/foo.c ... \ # sub/foo.h ... \ # ... set_dir_from "$object" # Use the source, not the object, to determine the base name, since # that's sadly what pgcc will do too. set_base_from "$source" tmpdepfile=$base.d # For projects that build the same source file twice into different object # files, the pgcc approach of using the *source* file root name can cause # problems in parallel builds. Use a locking strategy to avoid stomping on # the same $tmpdepfile. lockdir=$base.d-lock trap " echo '$0: caught signal, cleaning up...' >&2 rmdir '$lockdir' exit 1 " 1 2 13 15 numtries=100 i=$numtries while test $i -gt 0; do # mkdir is a portable test-and-set. if mkdir "$lockdir" 2>/dev/null; then # This process acquired the lock. "$@" -MD stat=$? # Release the lock. rmdir "$lockdir" break else # If the lock is being held by a different process, wait # until the winning process is done or we timeout. while test -d "$lockdir" && test $i -gt 0; do sleep 1 i=`expr $i - 1` done fi i=`expr $i - 1` done trap - 1 2 13 15 if test $i -le 0; then echo "$0: failed to acquire lock after $numtries attempts" >&2 echo "$0: check lockdir '$lockdir'" >&2 exit 1 fi if test $stat -ne 0; then rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" # Each line is of the form `foo.o: dependent.h', # or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'. # Do two passes, one to just change these to # `$object: dependent.h' and one to simply `dependent.h:'. sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile" # Some versions of the HPUX 10.20 sed can't process this invocation # correctly. Breaking it into two sed invocations is a workaround. sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" \ | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; hp2) # The "hp" stanza above does not work with aCC (C++) and HP's ia64 # compilers, which have integrated preprocessors. The correct option # to use with these is +Maked; it writes dependencies to a file named # 'foo.d', which lands next to the object file, wherever that # happens to be. # Much of this is similar to the tru64 case; see comments there. set_dir_from "$object" set_base_from "$object" if test "$libtool" = yes; then tmpdepfile1=$dir$base.d tmpdepfile2=$dir.libs/$base.d "$@" -Wc,+Maked else tmpdepfile1=$dir$base.d tmpdepfile2=$dir$base.d "$@" +Maked fi stat=$? if test $stat -ne 0; then rm -f "$tmpdepfile1" "$tmpdepfile2" exit $stat fi for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" do test -f "$tmpdepfile" && break done if test -f "$tmpdepfile"; then sed -e "s,^.*\.[$lower]*:,$object:," "$tmpdepfile" > "$depfile" # Add 'dependent.h:' lines. sed -ne '2,${ s/^ *// s/ \\*$// s/$/:/ p }' "$tmpdepfile" >> "$depfile" else make_dummy_depfile fi rm -f "$tmpdepfile" "$tmpdepfile2" ;; tru64) # The Tru64 compiler uses -MD to generate dependencies as a side # effect. 'cc -MD -o foo.o ...' puts the dependencies into 'foo.o.d'. # At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put # dependencies in 'foo.d' instead, so we check for that too. # Subdirectories are respected. set_dir_from "$object" set_base_from "$object" if test "$libtool" = yes; then # Libtool generates 2 separate objects for the 2 libraries. These # two compilations output dependencies in $dir.libs/$base.o.d and # in $dir$base.o.d. We have to check for both files, because # one of the two compilations can be disabled. We should prefer # $dir$base.o.d over $dir.libs/$base.o.d because the latter is # automatically cleaned when .libs/ is deleted, while ignoring # the former would cause a distcleancheck panic. tmpdepfile1=$dir$base.o.d # libtool 1.5 tmpdepfile2=$dir.libs/$base.o.d # Likewise. tmpdepfile3=$dir.libs/$base.d # Compaq CCC V6.2-504 "$@" -Wc,-MD else tmpdepfile1=$dir$base.d tmpdepfile2=$dir$base.d tmpdepfile3=$dir$base.d "$@" -MD fi stat=$? if test $stat -ne 0; then rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" exit $stat fi for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" do test -f "$tmpdepfile" && break done # Same post-processing that is required for AIX mode. aix_post_process_depfile ;; msvc7) if test "$libtool" = yes; then showIncludes=-Wc,-showIncludes else showIncludes=-showIncludes fi "$@" $showIncludes > "$tmpdepfile" stat=$? grep -v '^Note: including file: ' "$tmpdepfile" if test $stat -ne 0; then rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" echo "$object : \\" > "$depfile" # The first sed program below extracts the file names and escapes # backslashes for cygpath. The second sed program outputs the file # name when reading, but also accumulates all include files in the # hold buffer in order to output them again at the end. This only # works with sed implementations that can handle large buffers. sed < "$tmpdepfile" -n ' /^Note: including file: *\(.*\)/ { s//\1/ s/\\/\\\\/g p }' | $cygpath_u | sort -u | sed -n ' s/ /\\ /g s/\(.*\)/'"$tab"'\1 \\/p s/.\(.*\) \\/\1:/ H $ { s/.*/'"$tab"'/ G p }' >> "$depfile" echo >> "$depfile" # make sure the fragment doesn't end with a backslash rm -f "$tmpdepfile" ;; msvc7msys) # This case exists only to let depend.m4 do its work. It works by # looking at the text of this script. This case will never be run, # since it is checked for above. exit 1 ;; #nosideeffect) # This comment above is used by automake to tell side-effect # dependency tracking mechanisms from slower ones. dashmstdout) # Important note: in order to support this mode, a compiler *must* # always write the preprocessed file to stdout, regardless of -o. "$@" || exit $? # Remove the call to Libtool. if test "$libtool" = yes; then while test "X$1" != 'X--mode=compile'; do shift done shift fi # Remove '-o $object'. IFS=" " for arg do case $arg in -o) shift ;; $object) shift ;; *) set fnord "$@" "$arg" shift # fnord shift # $arg ;; esac done test -z "$dashmflag" && dashmflag=-M # Require at least two characters before searching for ':' # in the target name. This is to cope with DOS-style filenames: # a dependency such as 'c:/foo/bar' could be seen as target 'c' otherwise. "$@" $dashmflag | sed "s|^[$tab ]*[^:$tab ][^:][^:]*:[$tab ]*|$object: |" > "$tmpdepfile" rm -f "$depfile" cat < "$tmpdepfile" > "$depfile" # Some versions of the HPUX 10.20 sed can't process this sed invocation # correctly. Breaking it into two sed invocations is a workaround. tr ' ' "$nl" < "$tmpdepfile" \ | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \ | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; dashXmstdout) # This case only exists to satisfy depend.m4. It is never actually # run, as this mode is specially recognized in the preamble. exit 1 ;; makedepend) "$@" || exit $? # Remove any Libtool call if test "$libtool" = yes; then while test "X$1" != 'X--mode=compile'; do shift done shift fi # X makedepend shift cleared=no eat=no for arg do case $cleared in no) set ""; shift cleared=yes ;; esac if test $eat = yes; then eat=no continue fi case "$arg" in -D*|-I*) set fnord "$@" "$arg"; shift ;; # Strip any option that makedepend may not understand. Remove # the object too, otherwise makedepend will parse it as a source file. -arch) eat=yes ;; -*|$object) ;; *) set fnord "$@" "$arg"; shift ;; esac done obj_suffix=`echo "$object" | sed 's/^.*\././'` touch "$tmpdepfile" ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@" rm -f "$depfile" # makedepend may prepend the VPATH from the source file name to the object. # No need to regex-escape $object, excess matching of '.' is harmless. sed "s|^.*\($object *:\)|\1|" "$tmpdepfile" > "$depfile" # Some versions of the HPUX 10.20 sed can't process the last invocation # correctly. Breaking it into two sed invocations is a workaround. sed '1,2d' "$tmpdepfile" \ | tr ' ' "$nl" \ | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' \ | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" "$tmpdepfile".bak ;; cpp) # Important note: in order to support this mode, a compiler *must* # always write the preprocessed file to stdout. "$@" || exit $? # Remove the call to Libtool. if test "$libtool" = yes; then while test "X$1" != 'X--mode=compile'; do shift done shift fi # Remove '-o $object'. IFS=" " for arg do case $arg in -o) shift ;; $object) shift ;; *) set fnord "$@" "$arg" shift # fnord shift # $arg ;; esac done "$@" -E \ | sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ -e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ | sed '$ s: \\$::' > "$tmpdepfile" rm -f "$depfile" echo "$object : \\" > "$depfile" cat < "$tmpdepfile" >> "$depfile" sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; msvisualcpp) # Important note: in order to support this mode, a compiler *must* # always write the preprocessed file to stdout. "$@" || exit $? # Remove the call to Libtool. if test "$libtool" = yes; then while test "X$1" != 'X--mode=compile'; do shift done shift fi IFS=" " for arg do case "$arg" in -o) shift ;; $object) shift ;; "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI") set fnord "$@" shift shift ;; *) set fnord "$@" "$arg" shift shift ;; esac done "$@" -E 2>/dev/null | sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::\1:p' | $cygpath_u | sort -u > "$tmpdepfile" rm -f "$depfile" echo "$object : \\" > "$depfile" sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::'"$tab"'\1 \\:p' >> "$depfile" echo "$tab" >> "$depfile" sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::\1\::p' >> "$depfile" rm -f "$tmpdepfile" ;; msvcmsys) # This case exists only to let depend.m4 do its work. It works by # looking at the text of this script. This case will never be run, # since it is checked for above. exit 1 ;; none) exec "$@" ;; *) echo "Unknown depmode $depmode" 1>&2 exit 1 ;; esac exit 0 # Local Variables: # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'before-save-hook 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-time-zone: "UTC0" # time-stamp-end: "; # UTC" # End: ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������