# HG changeset patch # User Srinivasa Sarva # Date 1307052642 25200 # Node ID d8461ade59a0303fdb4d0826ea6ec16a5895df05 # Parent c0dae1e3ca2f387fd10e21a23ed112545462ca45 7048757 Move tidy to Userland diff -r c0dae1e3ca2f -r d8461ade59a0 components/meta-packages/history/SUNWtidy.p5m --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/components/meta-packages/history/SUNWtidy.p5m Thu Jun 02 15:10:42 2011 -0700 @@ -0,0 +1,33 @@ +# +# CDDL HEADER START +# +# The contents of this file are subject to the terms of the +# Common Development and Distribution License (the "License"). +# You may not use this file except in compliance with the License. +# +# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE +# or http://www.opensolaris.org/os/licensing. +# See the License for the specific language governing permissions +# and limitations under the License. +# +# When distributing Covered Code, include this CDDL HEADER in each +# file and include the License file at usr/src/OPENSOLARIS.LICENSE. +# If applicable, add the following below this CDDL HEADER, with the +# fields enclosed by brackets "[]" replaced with your own identifying +# information: Portions Copyright [yyyy] [name of copyright owner] +# +# CDDL HEADER END +# +# Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved. +# + +# +# Legacy package information for renamed SUNWtidy package +# + +set name=pkg.fmri value=pkg:/SUNWtidy@1.0.0,5.11-0.133 +set name=pkg.renamed value=true + +set name=org.opensolaris.consolidation value=$(CONSOLIDATION) + +depend fmri=text/tidy@1.0.0-0.133 type=require diff -r c0dae1e3ca2f -r d8461ade59a0 components/tidy/Makefile --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/components/tidy/Makefile Thu Jun 02 15:10:42 2011 -0700 @@ -0,0 +1,72 @@ +# +# CDDL HEADER START +# +# The contents of this file are subject to the terms of the +# Common Development and Distribution License (the "License"). +# You may not use this file except in compliance with the License. +# +# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE +# or http://www.opensolaris.org/os/licensing. +# See the License for the specific language governing permissions +# and limitations under the License. +# +# When distributing Covered Code, include this CDDL HEADER in each +# file and include the License file at usr/src/OPENSOLARIS.LICENSE. +# If applicable, add the following below this CDDL HEADER, with the +# fields enclosed by brackets "[]" replaced with your own identifying +# information: Portions Copyright [yyyy] [name of copyright owner] +# +# CDDL HEADER END +# + +# +# Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved. +# + +include ../../make-rules/shared-macros.mk + +COMPONENT_NAME= tidy +COMPONENT_VERSION= 1.0.0 +COMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION) +COMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.gz +COMPONENT_ARCHIVE_HASH= sha1:305704f7569b9e0abea81033f609f9a19dbbcfe2 +COMPONENT_ARCHIVE_URL= http://static.opensolaris.org/tarball/userland/$(COMPONENT_ARCHIVE) + + +include ../../make-rules/prep.mk +include ../../make-rules/configure.mk +include ../../make-rules/ips.mk +include ../../make-rules/lint-libraries.mk + +#tree.js, treeview.js, tidyenum_8h.html are installed +#from files directory manually as doxygen didn't generate them. +#This needs to be fixed later. + +COMPONENT_PREP_ACTION = \ + (cd $(SOURCE_DIR); doxygen htmldoc/doxygen.cfg) + +CONFIGURE_OPTIONS += --disable-static +CONFIGURE_OPTIONS += --enable-access +CONFIGURE_OPTIONS += --enable-utf16 +CONFIGURE_OPTIONS += --enable-asian +CONFIGURE_OPTIONS += CFLAGS="$(CFLAGS)" + +COMPONENT_PRE_CONFIGURE_ACTION = \ + ($(CP) -r $(SOURCE_DIR)/test $(@D)) + +PROTODOCDIR=$(PROTOUSRSHAREDIR)/doc/tidy + +$(PROTODOCDIR): + $(MKDIR) $@ + +# common targets +build: $(BUILD_32_and_64) + +install: $(INSTALL_32_and_64) $(PROTODOCDIR) + $(CP) -r $(SOURCE_DIR)/htmldoc/api $(PROTODOCDIR) + +test: $(TEST_32_and_64) + +BUILD_PKG_DEPENDENCIES = $(BUILD_TOOLS) + +include ../../make-rules/depend.mk diff -r c0dae1e3ca2f -r d8461ade59a0 components/tidy/files/libtidy.3 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/components/tidy/files/libtidy.3 Thu Jun 02 15:10:42 2011 -0700 @@ -0,0 +1,36 @@ +.\" libtidy man page for the Tidy Sourceforge project +.TH libtidy 3 "1 Feb 2007" "HTML Tidy 1.0.0" "Libraries" +.SH NAME +\fBlibtidy\fR - validate, correct, and pretty-print HTML files +.SH LIBRARY +The Tidy HTML Parser Library (libtidy, -ltidy) +.PP +.br +.SH DESCRIPTION +.PP +\fB#include \fP +.br +\fB#include \fP +.PP +.br +The +\fBtidy\fP +library provides parsing facilities for validating HTML, similar to +those found in +\fBlint\fP(1). +These functions are available in the +\fBlibtidy\fP +library. +Programs should be linked with +\fB\-ltidy\fP. +.SH "SEE ALSO" +\fBtidy\fP(1) +.PP +.br +Complete documentation in HTML format is available under +\fB/usr/share/doc/tidy/html\fP. +.SH AUTHOR +\fBTidy\fR was written by Dave Raggett <\fIdsr@w3.org\fR>, and is now maintained and developed by the Tidy team at \fIhttp://tidy.sourceforge.net/\fR. It is released under the \fIMIT Licence\fR. +.LP +Generated automatically with HTML Tidy released on 1 September 2005. + diff -r c0dae1e3ca2f -r d8461ade59a0 components/tidy/files/tab2space.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/components/tidy/files/tab2space.1 Thu Jun 02 15:10:42 2011 -0700 @@ -0,0 +1,56 @@ +.\" tab2space man page for the Tidy Sourceforge project +.TH tab2space 1 "1 Feb 2007" "HTML Tidy 1.0.0" "User commands" + +.SH NAME +\fBtab2space\fR - Utility to expand tabs and ensure consistent line endings +.br +.SH SYNOPSIS +\fBtab2space\fR [option ...] [[infile] [outfile]] ... +.SH DESCRIPTION +tab2space is a command-line utility which performs tab expansion and +ensures consistent and appropriate line ending termination characters. +tab2space is distributed as part of the tidy(1) package. +.SH OPTIONS +.TP +\fB-help\fR, \fB-h\fR +display detailed help message +.TP +\fB-dos\fR, \fB-crlf\fR +set line ends to CRLF +(\fIPC-DOS/Windows - default\fR) +.TP +\fB-mac\fR, \fB-cr\fR +set line ends to CR +(\fIclassic Mac OS\fR) +.TP +\fB-unix\fR, \fB-lf\fR +set line ends to LF +(\fIUnix\fR) +.TP +\fB-tabs\fR +preserve tabs, e.g. for Makefile +.TP +\fB-t\fR +set tabs to (default is 4) spaces +.SH USAGE +.LP +Use \fB--\fR\fIhelp\fR or \fB-\fR\fIh\fR for detailed configuration options. +.LP +Input/Output default to stdin/stdout respectively. +.LP +For further info on HTML see \fIhttp://www.w3.org/MarkUp\fR. +.LP +For more information about HTML Tidy, visit the project home page at \fIhttp://tidy.sourceforge.net\fR. Here, you will find links to documentation, mailing lists (with searchable archives) and links to report bugs. +.SH "EXIT STATUS" +.IP 0 +All input files were processed successfully. +.IP 1 +There were warnings. +.IP 2 +There were errors. +.SH "SEE ALSO" +HTML Tidy Project Page at \fIhttp://tidy.sourceforge.net\fR +.SH AUTHOR +\fBTidy\fR was written by Dave Raggett <\fIdsr@w3.org\fR>, and is now maintained and developed by the Tidy team at \fIhttp://tidy.sourceforge.net/\fR. It is released under the \fIMIT Licence\fR. +.LP +Generated automatically with HTML Tidy released on 1 September 2005. diff -r c0dae1e3ca2f -r d8461ade59a0 components/tidy/files/tidy.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/components/tidy/files/tidy.1 Thu Jun 02 15:10:42 2011 -0700 @@ -0,0 +1,1405 @@ +.\" tidy man page for the Tidy Sourceforge project +.TH tidy 1 "1 Feb 2007" "HTML Tidy 1.0.0" "User commands" + +.SH NAME +\fBtidy\fR - validate, correct, and pretty-print HTML files +.br +.SH SYNOPSIS +\fBtidy\fR [option ...] [file ...] [option ...] [file ...] +.SH DESCRIPTION +Tidy reads HTML, XHTML and XML files and writes cleaned up markup. For +HTML variants, it detects and corrects many common coding errors and +strives to produce visually equivalent markup that is both W3C +compliant and works on most browsers. A common use of Tidy is to +convert plain HTML to XHTML. For generic XML files, Tidy is limited to +correcting basic well-formedness errors and pretty printing. +.LP +If no input file is specified, Tidy reads the standard input. If no +output file is specified, Tidy writes the tidied markup to the standard +output. If no error file is specified, Tidy writes messages to the +standard error. +For command line options that expect a numerical argument, a default is +assumed if no meaningful value can be found. +.SH OPTIONS + +.SS File manipulation + +.TP +\fB-output \fR, \fB-o \fR +write output to the specified +(\fIoutput-file: \fR) +.TP +\fB-config \fR +set configuration options from the specified + +.TP +\fB-file \fR, \fB-f \fR +write errors to the specified +(\fIerror-file: \fR) +.TP +\fB-modify\fR, \fB-m\fR +modify the original input files +(\fIwrite-back: yes\fR) +.SS Processing directives + +.TP +\fB-indent\fR, \fB-i\fR +indent element content +(\fIindent: auto\fR) +.TP +\fB-wrap \fR, \fB-w \fR +wrap text at the specified . 0 is assumed if is +missing. When this option is omitted, the default of the configuration +option "wrap" applies. +(\fIwrap: \fR) +.TP +\fB-upper\fR, \fB-u\fR +force tags to upper case +(\fIuppercase-tags: yes\fR) +.TP +\fB-clean\fR, \fB-c\fR +replace FONT, NOBR and CENTER tags by CSS +(\fIclean: yes\fR) +.TP +\fB-bare\fR, \fB-b\fR +strip out smart quotes and em dashes, etc. +(\fIbare: yes\fR) +.TP +\fB-numeric\fR, \fB-n\fR +output numeric rather than named entities +(\fInumeric-entities: yes\fR) +.TP +\fB-errors\fR, \fB-e\fR +only show errors +(\fImarkup: no\fR) +.TP +\fB-quiet\fR, \fB-q\fR +suppress nonessential output +(\fIquiet: yes\fR) +.TP +\fB-omit\fR +omit optional end tags +(\fIhide-endtags: yes\fR) +.TP +\fB-xml\fR +specify the input is well formed XML +(\fIinput-xml: yes\fR) +.TP +\fB-asxml\fR, \fB-asxhtml\fR +convert HTML to well formed XHTML +(\fIoutput-xhtml: yes\fR) +.TP +\fB-ashtml\fR +force XHTML to well formed HTML +(\fIoutput-html: yes\fR) +.TP +\fB-access \fR +do additional accessibility checks ( = 0, 1, 2, 3). 0 is assumed +if is missing. +(\fIaccessibility-check: \fR) +.SS Character encodings + +.TP +\fB-raw\fR +output values above 127 without conversion to entities + +.TP +\fB-ascii\fR +use ISO-8859-1 for input, US-ASCII for output + +.TP +\fB-latin0\fR +use ISO-8859-15 for input, US-ASCII for output + +.TP +\fB-latin1\fR +use ISO-8859-1 for both input and output + +.TP +\fB-iso2022\fR +use ISO-2022 for both input and output + +.TP +\fB-utf8\fR +use UTF-8 for both input and output + +.TP +\fB-mac\fR +use MacRoman for input, US-ASCII for output + +.TP +\fB-win1252\fR +use Windows-1252 for input, US-ASCII for output + +.TP +\fB-ibm858\fR +use IBM-858 (CP850+Euro) for input, US-ASCII for output + +.TP +\fB-utf16le\fR +use UTF-16LE for both input and output + +.TP +\fB-utf16be\fR +use UTF-16BE for both input and output + +.TP +\fB-utf16\fR +use UTF-16 for both input and output + +.TP +\fB-big5\fR +use Big5 for both input and output + +.TP +\fB-shiftjis\fR +use Shift_JIS for both input and output + +.TP +\fB-language \fR +set the two-letter language code (for future use) +(\fIlanguage: \fR) +.SS Miscellaneous + +.TP +\fB-version\fR, \fB-v\fR +show the version of Tidy + +.TP +\fB-help\fR, \fB-h\fR, \fB-?\fR +list the command line options + +.TP +\fB-xml-help\fR +list the command line options in XML format + +.TP +\fB-help-config\fR +list all configuration options + +.TP +\fB-xml-config\fR +list all configuration options in XML format + +.TP +\fB-show-config\fR +list the current configuration settings + +.SH USAGE +.LP +Use \fB--\fR\fIoptionX valueX\fR for the detailed configuration option +"optionX" with argument "valueX". See also below under \fBDetailed +Configuration Options\fR as to how to conveniently group all such +options in a single config file. +.LP +Input/Output default to stdin/stdout respectively. Single letter +options apart from \fB-f\fR and \fB-o\fR may be combined as in: +.LP +.in 1i +\fBtidy -f errs.txt -imu foo.html\fR +.LP +For further info on HTML see \fIhttp://www.w3.org/MarkUp\fR. +.LP +For more information about HTML Tidy, visit the project home page at +\fIhttp://tidy.sourceforge.net\fR. Here, you will find links to +documentation, mailing lists (with searchable archives) and links to +report bugs. +.SH ENVIRONMENT +.TP +.B HTML_TIDY +Name of the default configuration file. This should be an absolute +path, since you will probably invoke \fBtidy\fR from different +directories. The value of HTML_TIDY will be parsed after the +compiled-in default (defined with -DTIDY_CONFIG_FILE), but before any +of the files specified using \fB-config\fR. +.SH "EXIT STATUS" +.IP 0 +All input files were processed successfully. +.IP 1 +There were warnings. +.IP 2 +There were errors. + +.SH ______________________________ +.SH " " +.SH "DETAILED CONFIGURATION OPTIONS" +This section describes the Detailed (i.e., "expanded") Options, which +may be specified by preceding each option with \fB--\fR at the command +line, followed by its desired value, OR by placing the options and +values in a configuration file, and telling tidy to read that file with +the \fB-config\fR standard option. +.SH SYNOPSIS +\fBtidy --\fR\fIoption1 \fRvalue1 \fB--\fIoption2 \fRvalue2 [standard +options ...] +.br +\fBtidy -config \fIconfig-file \fR[standard options ...] +.SH WARNING +The options detailed here do not include the "standard" command-line +options (i.e., those preceded by a single '\fB-\fR') described above in +the first section of this man page. +.SH DESCRIPTION +A list of options for configuring the behavior of Tidy, which can be +passed either on the command line, or specified in a configuration +file. +.LP +A Tidy configuration file is simply a text file, where each option +is listed on a separate line in the form +.LP +.in 1i +\fBoption1\fR: \fIvalue1\fR +.br +\fBoption2\fR: \fIvalue2\fR +.br +etc. +.LP +The permissible values for a given option depend on the option's +\fBType\fR. There are five types: \fIBoolean\fR, \fIAutoBool\fR, +\fIDocType\fR, \fIEnum\fR, and \fIString\fR. Boolean types allow any of +\fIyes/no, y/n, true/false, t/f, 1/0\fR. AutoBools allow \fIauto\fR in +addition to the values allowed by Booleans. Integer types take +non-negative integers. String types generally have no defaults, and +you should provide them in non-quoted form (unless you wish the output +to contain the literal quotes). +.LP +Enum, Encoding, and DocType "types" have a fixed repertoire of items; +consult the \fIExample\fR[s] provided below for the option[s] in +question. +.LP +You only need to provide options and values for those whose defaults +you wish to override, although you may wish to include some +already-defaulted options and values for the sake of documentation and +explicitness. +.LP +Here is a sample config file, with at least one example of each of the +five Types: +.LP +\fI + // sample Tidy configuration options + output-xhtml: yes + add-xml-decl: no + doctype: strict + char-encoding: ascii + indent: auto + wrap: 76 + repeated-attributes: keep-last + error-file: errs.txt +\fR +.LP +Below is a summary and brief description of each of the options. They +are listed alphabetically within each category. There are five +categories: \fIHTML, XHTML, XML\fR options, \fIDiagnostics\fR options, +\fIPretty Print\fR options, \fICharacter Encoding\fR options, and +\fIMiscellaneous\fR options. +.LP +.SH OPTIONS + +.SS HTML, XHTML, XML options: + +.TP +\fBadd-xml-decl\fR + +Type: \fIBoolean\fR +.br +Default: \fIno\fR +.br +Example: \fIy/n, yes/no, t/f, true/false, 1/0\fR + +This option specifies if Tidy should add the XML declaration when +outputting XML or XHTML. Note that if the input already includes an + declaration then this option will be ignored. If the +encoding for the output is different from "ascii", one of the utf +encodings or "raw", the declaration is always added as required by the +XML standard. + + +.rj 1 +\fBSee also\fR: \fIchar-encoding\fR, \fIoutput-encoding\fR +.TP +\fBadd-xml-space\fR + +Type: \fIBoolean\fR +.br +Default: \fIno\fR +.br +Example: \fIy/n, yes/no, t/f, true/false, 1/0\fR + +This option specifies if Tidy should add xml:space="preserve" to +elements such as
,