code:
;;;;;;;;;;;;;;;;;;;;;
; FPM Configuration ;
;;;;;;;;;;;;;;;;;;;;;

; All relative paths in this configuration file are relative to PHP's install
; prefix (/usr). This prefix can be dynamically changed by using the
; '-p' argument from the command line.

; Include one or more files. If glob(3) exists, it is used to include a bunch of
; files from a glob(3) pattern. This directive can be used everywhere in the
; file.
; Relative path can also be used. They will be prefixed by:
;  - the global prefix if it's been set (-p argument)
;  - /usr otherwise
;include=etc/fpm.d/*.conf

;;;;;;;;;;;;;;;;;;
; Global Options ;
;;;;;;;;;;;;;;;;;;

[global]
; Pid file
; Note: the default prefix is /var
; Default Value: none
pid = /run/php-fpm.pid

; Error log file
; If it's set to "syslog", log is sent to syslogd instead of being written
; in a local file.
; Note: the default prefix is /var
; Default Value: log/php-fpm.log
error_log = /var/log/php-fpm/php-fpm.log

; syslog_facility is used to specify what type of program is logging the
; message. This lets syslogd specify that messages from different facilities
; will be handled differently.
; See syslog(3) for possible values (ex daemon equiv LOG_DAEMON)
; Default Value: daemon
;syslog.facility = daemon

; syslog_ident is prepended to every message. If you have multiple FPM
; instances running on the same server, you can change the default value
; which must suit common needs.
; Default Value: php-fpm
;syslog.ident = php-fpm

; Log level
; Possible Values: alert, error, warning, notice, debug
; Default Value: notice
;log_level = notice

; If this number of child processes exit with SIGSEGV or SIGBUS within the time
; interval set by emergency_restart_interval then FPM will restart. A value
; of '0' means 'Off'.
; Default Value: 0
;emergency_restart_threshold = 0

; Interval of time used by emergency_restart_interval to determine when
; a graceful restart will be initiated.  This can be useful to work around
; accidental corruptions in an accelerator's shared memory.
; Available Units: s(econds), m(inutes), h(ours), or d(ays)
; Default Unit: seconds
; Default Value: 0
;emergency_restart_interval = 0

; Time limit for child processes to wait for a reaction on signals from master.
; Available units: s(econds), m(inutes), h(ours), or d(ays)
; Default Unit: seconds
; Default Value: 0
;process_control_timeout = 0

; The maximum number of processes FPM will fork. This has been design to control
; the global number of processes when using dynamic PM within a lot of pools.
; Use it with caution.
; Note: A value of 0 indicates no limit
; Default Value: 0
; process.max = 128

; Specify the nice(2) priority to apply to the master process (only if set)
; The value can vary from -19 (highest priority) to 20 (lower priority)
; Note: - It will only work if the FPM master process is launched as root
;       - The pool process will inherit the master process priority
;         unless it specified otherwise
; Default Value: no set
; process.priority = -19

; Send FPM to background. Set to 'no' to keep FPM in foreground for debugging.
; Default Value: yes
daemonize = no

; Set open file descriptor rlimit for the master process.
; Default Value: system defined value
;rlimit_files = 1024

; Set max core size rlimit for the master process.
; Possible Values: 'unlimited' or an integer greater or equal to 0
; Default Value: system defined value
;rlimit_core = 0

; Specify the event mechanism FPM will use. The following is available:
; - select     (any POSIX os)
; - poll       (any POSIX os)
; - epoll      (linux >= 2.5.44)
; - kqueue     (FreeBSD >= 4.1, OpenBSD >= 2.9, NetBSD >= 2.0)
; - /dev/poll  (Solaris >= 7)
; - port       (Solaris >= 10)
; Default Value: not set (auto detection)
;events.mechanism = epoll

; When FPM is build with systemd integration, specify the interval,
; in second, between health report notification to systemd.
; Set to 0 to disable.
; Available Units: s(econds), m(inutes), h(ours)
; Default Unit: seconds
; Default value: 10
;systemd_interval = 10

;;;;;;;;;;;;;;;;;;;;
; Pool Definitions ;
;;;;;;;;;;;;;;;;;;;;

; Multiple pools of child processes may be started with different listening
; ports and different management options.  The name of the pool will be
; used in logs and stats. There is no limitation on the number of pools which
; FPM can handle. Your system will tell you anyway :)

; Start a new pool named 'www'.
; the variable $pool can we used in any directive and will be replaced by the
; pool name ('www' here)
[www]

; Per pool prefix
; It only applies on the following directives:
; - 'slowlog'
; - 'listen' (unixsocket)
; - 'chroot'
; - 'chdir'
; - 'php_values'
; - 'php_admin_values'
; When not set, the global prefix (or /usr) applies instead.
; Note: This directive can also be relative to the global prefix.
; Default Value: none
;prefix = /path/to/pools/$pool

; Unix user/group of processes
; Note: The user is mandatory. If the group is not set, the default user's group
;       will be used.
user = apache
group = apache

; The address on which to accept FastCGI requests.
; Valid syntaxes are:
;   'ip.add.re.ss:port'    - to listen on a TCP socket to a specific address on
;                            a specific port;
;   'port'                 - to listen on a TCP socket to all addresses on a
;                            specific port;
;   '/path/to/unix/socket' - to listen on a unix socket.
; Note: This value is mandatory.
listen = 127.0.0.1:9000

; Set listen(2) backlog.
; Default Value: 128 (-1 on FreeBSD and OpenBSD)
;listen.backlog = 128

; Set permissions for unix socket, if one is used. In Linux, read/write
; permissions must be set in order to allow connections from a web server. Many
; BSD-derived systems allow connections regardless of permissions.
; Default Values: user and group are set as the running user
;                 mode is set to 0666
;listen.owner = apache
;listen.group = apache
;listen.mode = 0666

; List of ipv4 addresses of FastCGI clients which are allowed to connect.
; Equivalent to the FCGI_WEB_SERVER_ADDRS environment variable in the original
; PHP FCGI (5.2.2+). Makes sense only with a tcp listening socket. Each address
; must be separated by a comma. If this value is left blank, connections will be
; accepted from any ip address.
; Default Value: any
;listen.allowed_clients = 127.0.0.1

; Specify the nice(2) priority to apply to the pool processes (only if set)
; The value can vary from -19 (highest priority) to 20 (lower priority)
; Note: - It will only work if the FPM master process is launched as root
;       - The pool processes will inherit the master process priority
;         unless it specified otherwise
; Default Value: no set
; priority = -19

; Choose how the process manager will control the number of child processes.
; Possible Values:
;   static  - a fixed number (pm.max_children) of child processes;
;   dynamic - the number of child processes are set dynamically based on the
;             following directives. With this process management, there will be
;             always at least 1 children.
;             pm.max_children      - the maximum number of children that can
;                                    be alive at the same time.
;             pm.start_servers     - the number of children created on startup.
;             pm.min_spare_servers - the minimum number of children in 'idle'
;                                    state (waiting to process). If the number
;                                    of 'idle' processes is less than this
;                                    number then some children will be created.
;             pm.max_spare_servers - the maximum number of children in 'idle'
;                                    state (waiting to process). If the number
;                                    of 'idle' processes is greater than this
;                                    number then some children will be killed.
;  ondemand - no children are created at startup. Children will be forked when
;             new requests will connect. The following parameter are used:
;             pm.max_children           - the maximum number of children that
;                                         can be alive at the same time.
;             pm.process_idle_timeout   - The number of seconds after which
;                                         an idle process will be killed.
; Note: This value is mandatory.
pm = dynamic

; The number of child processes to be created when pm is set to 'static' and the
; maximum number of child processes when pm is set to 'dynamic' or 'ondemand'.
; This value sets the limit on the number of simultaneous requests that will be
; served. Equivalent to the ApacheMaxClients directive with mpm_prefork.
; Equivalent to the PHP_FCGI_CHILDREN environment variable in the original PHP
; CGI. The below defaults are based on a server without much resources. Don't
; forget to tweak pm.* to fit your needs.
; Note: Used when pm is set to 'static', 'dynamic' or 'ondemand'
; Note: This value is mandatory.
pm.max_children = 5

; The number of child processes created on startup.
; Note: Used only when pm is set to 'dynamic'
; Default Value: min_spare_servers + (max_spare_servers - min_spare_servers) / 2
pm.start_servers = 2

; The desired minimum number of idle server processes.
; Note: Used only when pm is set to 'dynamic'
; Note: Mandatory when pm is set to 'dynamic'
pm.min_spare_servers = 1

; The desired maximum number of idle server processes.
; Note: Used only when pm is set to 'dynamic'
; Note: Mandatory when pm is set to 'dynamic'
pm.max_spare_servers = 3

; The number of seconds after which an idle process will be killed.
; Note: Used only when pm is set to 'ondemand'
; Default Value: 10s
;pm.process_idle_timeout = 10s;

; The number of requests each child process should execute before respawning.
; This can be useful to work around memory leaks in 3rd party libraries. For
; endless request processing specify '0'. Equivalent to PHP_FCGI_MAX_REQUESTS.
; Default Value: 0
;pm.max_requests = 500

; The URI to view the FPM status page. If this value is not set, no URI will be
; recognized as a status page. It shows the following informations:
;   pool                 - the name of the pool;
;   process manager      - static, dynamic or ondemand;
;   start time           - the date and time FPM has started;
;   start since          - number of seconds since FPM has started;
;   accepted conn        - the number of request accepted by the pool;
;   listen queue         - the number of request in the queue of pending
;                          connections (see backlog in listen(2));
;   max listen queue     - the maximum number of requests in the queue
;                          of pending connections since FPM has started;
;   listen queue len     - the size of the socket queue of pending connections;
;   idle processes       - the number of idle processes;
;   active processes     - the number of active processes;
;   total processes      - the number of idle + active processes;
;   max active processes - the maximum number of active processes since FPM
;                          has started;
;   max children reached - number of times, the process limit has been reached,
;                          when pm tries to start more children (works only for
;                          pm 'dynamic' and 'ondemand');
; Value are updated in real time.
; Example output:
;   pool:                 www
;   process manager:      static
;   start time:           01/Jul/2011:17:53:49 +0200
;   start since:          62636
;   accepted conn:        190460
;   listen queue:         0
;   max listen queue:     1
;   listen queue len:     42
;   idle processes:       4
;   active processes:     11
;   total processes:      15
;   max active processes: 12
;   max children reached: 0
;
; By default the status page output is formatted as text/plain. Passing either
; 'html', 'xml' or 'json' in the query string will return the corresponding
; output syntax. Example:
;   http://www.foo.bar/status
;   http://www.foo.bar/status?json
;   http://www.foo.bar/status?html
;   http://www.foo.bar/status?xml
;
; By default the status page only outputs short status. Passing 'full' in the
; query string will also return status for each pool process.
; Example:
;   http://www.foo.bar/status?full
;   http://www.foo.bar/status?json&full
;   http://www.foo.bar/status?html&full
;   http://www.foo.bar/status?xml&full
; The Full status returns for each process:
;   pid                  - the PID of the process;
;   state                - the state of the process (Idle, Running, ...);
;   start time           - the date and time the process has started;
;   start since          - the number of seconds since the process has started;
;   requests             - the number of requests the process has served;
;   request duration     - the duration in µs of the requests;
;   request method       - the request method (GET, POST, ...);
;   request URI          - the request URI with the query string;
;   content length       - the content length of the request (only with POST);
;   user                 - the user (PHP_AUTH_USER) (or '-' if not set);
;   script               - the main script called (or '-' if not set);
;   last request cpu     - the %cpu the last request consumed
;                          it's always 0 if the process is not in Idle state
;                          because CPU calculation is done when the request
;                          processing has terminated;
;   last request memory  - the max amount of memory the last request consumed
;                          it's always 0 if the process is not in Idle state
;                          because memory calculation is done when the request
;                          processing has terminated;
; If the process is in Idle state, then informations are related to the
; last request the process has served. Otherwise informations are related to
; the current request being served.
; Example output:
;   ************************
;   pid:                  31330
;   state:                Running
;   start time:           01/Jul/2011:17:53:49 +0200
;   start since:          63087
;   requests:             12808
;   request duration:     1250261
;   request method:       GET
;   request URI:          /test_mem.php?N=10000
;   content length:       0
;   user:                 -
;   script:               /home/fat/web/docs/php/test_mem.php
;   last request cpu:     0.00
;   last request memory:  0
;
; Note: There is a real-time FPM status monitoring sample web page available
;       It's available in: /usr/share/fpm/status.html
;
; Note: The value must start with a leading slash (/). The value can be
;       anything, but it may not be a good idea to use the .php extension or it
;       may conflict with a real PHP file.
; Default Value: not set
;pm.status_path = /status

; The ping URI to call the monitoring page of FPM. If this value is not set, no
; URI will be recognized as a ping page. This could be used to test from outside
; that FPM is alive and responding, or to
; - create a graph of FPM availability (rrd or such);
; - remove a server from a group if it is not responding (load balancing);
; - trigger alerts for the operating team (24/7).
; Note: The value must start with a leading slash (/). The value can be
;       anything, but it may not be a good idea to use the .php extension or it
;       may conflict with a real PHP file.
; Default Value: not set
;ping.path = /ping

; This directive may be used to customize the response of a ping request. The
; response is formatted as text/plain with a 200 response code.
; Default Value: pong
;ping.response = pong

; The access log file
; Default: not set
;access.log = log/$pool.access.log

; The access log format.
; The following syntax is allowed
;  %%: the '%' character
;  %C: %CPU used by the request
;      it can accept the following format:
;      - %{user}C for user CPU only
;      - %{system}C for system CPU only
;      - %{total}C  for user + system CPU (default)
;  %d: time taken to serve the request
;      it can accept the following format:
;      - %{seconds}d (default)
;      - %{miliseconds}d
;      - %{mili}d
;      - %{microseconds}d
;      - %{micro}d
;  %e: an environment variable (same as $_ENV or $_SERVER)
;      it must be associated with embraces to specify the name of the env
;      variable. Some exemples:
;      - server specifics like: %{REQUEST_METHOD}e or %{SERVER_PROTOCOL}e
;      - HTTP headers like: %{HTTP_HOST}e or %{HTTP_USER_AGENT}e
;  %f: script filename
;  %l: content-length of the request (for POST request only)
;  %m: request method
;  %M: peak of memory allocated by PHP
;      it can accept the following format:
;      - %{bytes}M (default)
;      - %{kilobytes}M
;      - %{kilo}M
;      - %{megabytes}M
;      - %{mega}M
;  %n: pool name
;  %o: output header
;      it must be associated with embraces to specify the name of the header:
;      - %{Content-Type}o
;      - %{X-Powered-By}o
;      - %{Transfert-Encoding}o
;      - ....
;  %p: PID of the child that serviced the request
;  %P: PID of the parent of the child that serviced the request
;  %q: the query string
;  %Q: the '?' character if query string exists
;  %r: the request URI (without the query string, see %q and %Q)
;  %R: remote IP address
;  %s: status (response code)
;  %t: server time the request was received
;      it can accept a strftime(3) format:
;      %d/%b/%Y:%H:%M:%S %z (default)
;  %T: time the log has been written (the request has finished)
;      it can accept a strftime(3) format:
;      %d/%b/%Y:%H:%M:%S %z (default)
;  %u: remote user
;
; Default: "%R - %u %t \"%m %r\" %s"
;access.format = "%R - %u %t \"%m %r%Q%q\" %s %f %{mili}d %{kilo}M %C%%"

; The log file for slow requests
; Default Value: not set
; Note: slowlog is mandatory if request_slowlog_timeout is set
slowlog = /var/log/php-fpm/www-slow.log

; The timeout for serving a single request after which a PHP backtrace will be
; dumped to the 'slowlog' file. A value of '0s' means 'off'.
; Available units: s(econds)(default), m(inutes), h(ours), or d(ays)
; Default Value: 0
;request_slowlog_timeout = 0

; The timeout for serving a single request after which the worker process will
; be killed. This option should be used when the 'max_execution_time' ini option
; does not stop script execution for some reason. A value of '0' means 'off'.
; Available units: s(econds)(default), m(inutes), h(ours), or d(ays)
; Default Value: 0
;request_terminate_timeout = 0

; Set open file descriptor rlimit.
; Default Value: system defined value
;rlimit_files = 1024

; Set max core size rlimit.
; Possible Values: 'unlimited' or an integer greater or equal to 0
; Default Value: system defined value
;rlimit_core = 0

; Chroot to this directory at the start. This value must be defined as an
; absolute path. When this value is not set, chroot is not used.
; Note: you can prefix with '$prefix' to chroot to the pool prefix or one
; of its subdirectories. If the pool prefix is not set, the global prefix
; will be used instead.
; Note: chrooting is a great security feature and should be used whenever
;       possible. However, all PHP paths will be relative to the chroot
;       (error_log, sessions.save_path, ...).
; Default Value: not set
;chroot =

; Chdir to this directory at the start.
; Note: relative path can be used.
; Default Value: current directory or / when chroot
;chdir = /var/www

; Redirect worker stdout and stderr into main error log. If not set, stdout and
; stderr will be redirected to /dev/null according to FastCGI specs.
; Note: on highloaded environement, this can cause some delay in the page
; process time (several ms).
; Default Value: no
;catch_workers_output = yes

; Limits the extensions of the main script FPM will allow to parse. This can
; prevent configuration mistakes on the web server side. You should only limit
; FPM to .php extensions to prevent malicious users to use other extensions to
; exectute php code.
; Note: set an empty value to allow all extensions.
; Default Value: .php
;security.limit_extensions = .php .php3 .php4 .php5

; Pass environment variables like LD_LIBRARY_PATH. All $VARIABLEs are taken from
; the current environment.
; Default Value: clean env
;env[HOSTNAME] = $HOSTNAME
;env[PATH] = /usr/local/bin:/usr/bin:/bin
;env[TMP] = /tmp
;env[TMPDIR] = /tmp
;env[TEMP] = /tmp

; Additional php.ini defines, specific to this pool of workers. These settings
; overwrite the values previously defined in the php.ini. The directives are the
; same as the PHP SAPI:
;   php_value/php_flag             - you can set classic ini defines which can
;                                    be overwritten from PHP call 'ini_set'.
;   php_admin_value/php_admin_flag - these directives won't be overwritten by
;                                     PHP call 'ini_set'
; For php_*flag, valid values are on, off, 1, 0, true, false, yes or no.

; Defining 'extension' will load the corresponding shared extension from
; extension_dir. Defining 'disable_functions' or 'disable_classes' will not
; overwrite previously defined php.ini values, but will append the new value
; instead.

; Note: path INI options can be relative and will be expanded with the prefix
; (pool, global or /usr)

; Default Value: nothing is defined by default except the values in php.ini and
;                specified at startup with the -d argument
;php_admin_value[sendmail_path] = /usr/sbin/sendmail -t -i -f www@my.domain.com
;php_flag[display_errors] = off
;php_admin_value[error_log] = /var/log/fpm-php.www.log
;php_admin_flag[log_errors] = on
;php_admin_value[memory_limit] = 32M

; Set session path to a directory owned by process user
php_value[session.save_handler] = files
php_value[session.save_path] = /tmp


code:
diff -Naurp php-5.3.4RC1/ext/imap/php_imap.c php-5.3.4RC1.oden/ext/imap/php_imap.c
--- php-5.3.4RC1/ext/imap/php_imap.c	2010-11-18 16:22:22.000000000 +0100
+++ php-5.3.4RC1.oden/ext/imap/php_imap.c	2010-11-22 10:01:42.538863104 +0100
@@ -164,6 +164,22 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_imap_geta
 	ZEND_ARG_INFO(0, mailbox)
 ZEND_END_ARG_INFO()
 #endif
+#if defined(HAVE_IMAP2005)
+ZEND_BEGIN_ARG_INFO_EX(arginfo_imap_setannotation, 0, 0, 5)
+	ZEND_ARG_INFO(0, stream_id)
+	ZEND_ARG_INFO(0, mailbox)
+	ZEND_ARG_INFO(0, entry)
+	ZEND_ARG_INFO(0, attr)
+	ZEND_ARG_INFO(0, value)
+ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_imap_getannotation, 0, 0, 4)
+	ZEND_ARG_INFO(0, stream_id)
+	ZEND_ARG_INFO(0, mailbox)
+	ZEND_ARG_INFO(0, entry)
+	ZEND_ARG_INFO(0, attr)
+ZEND_END_ARG_INFO()
+#endif

 ZEND_BEGIN_ARG_INFO_EX(arginfo_imap_expunge, 0, 0, 1)
 	ZEND_ARG_INFO(0, stream_id)
@@ -408,6 +424,11 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_imap_stat
 	ZEND_ARG_INFO(0, options)
 ZEND_END_ARG_INFO()

+ZEND_BEGIN_ARG_INFO_EX(arginfo_imap_status_current, 0, 0, 2)
+	ZEND_ARG_INFO(0, stream_id)
+	ZEND_ARG_INFO(0, options)
+ZEND_END_ARG_INFO()
+
 ZEND_BEGIN_ARG_INFO_EX(arginfo_imap_bodystruct, 0, 0, 3)
 	ZEND_ARG_INFO(0, stream_id)
 	ZEND_ARG_INFO(0, msg_no)
@@ -507,6 +528,7 @@ const zend_function_entry imap_functions
 	PHP_FE(imap_binary,								arginfo_imap_binary)
 	PHP_FE(imap_utf8,								arginfo_imap_utf8)
 	PHP_FE(imap_status,								arginfo_imap_status)
+	PHP_FE(imap_status_current,						arginfo_imap_status_current)
 	PHP_FE(imap_mailboxmsginfo,						arginfo_imap_mailboxmsginfo)
 	PHP_FE(imap_setflag_full,						arginfo_imap_setflag_full)
 	PHP_FE(imap_clearflag_full,						arginfo_imap_clearflag_full)
@@ -537,6 +559,10 @@ const zend_function_entry imap_functions
 	PHP_FE(imap_setacl,								arginfo_imap_setacl)
 	PHP_FE(imap_getacl,								arginfo_imap_getacl)
 #endif
+#if defined(HAVE_IMAP2005)
+ 	PHP_FE(imap_setannotation,						arginfo_imap_setannotation)
+ 	PHP_FE(imap_getannotation,						arginfo_imap_getannotation)
+#endif

 	PHP_FE(imap_mail,								arginfo_imap_mail)

@@ -798,6 +824,30 @@ void mail_getacl(MAILSTREAM *stream, cha
 /* }}} */
 #endif

+#if defined(HAVE_IMAP2005)
+/* {{{ mail_getannotation
+ *
+ * Mail GET_ANNOTATION callback
+ * Called via the mail_parameter function in c-client:src/c-client/mail.c
+ */
+void mail_getannotation(MAILSTREAM *stream, ANNOTATION *alist)
+{
+        ANNOTATION_VALUES *cur;
+
+	TSRMLS_FETCH();
+
+	/* walk through the ANNOTATION_VALUES */
+
+	for(cur = alist->values; cur; cur = cur->next) {
+	    if (cur->value)
+		add_assoc_stringl(IMAPG(imap_annotation_list), cur->attr, cur->value, strlen(cur->value), 1);
+	    else
+		add_assoc_stringl(IMAPG(imap_annotation_list), cur->attr, "", 0, 1);
+	}
+}
+/* }}} */
+#endif
+
 /* {{{ PHP_GINIT_FUNCTION
  */
 static PHP_GINIT_FUNCTION(imap)
@@ -823,6 +873,7 @@ static PHP_GINIT_FUNCTION(imap)
 #if defined(HAVE_IMAP2000) || defined(HAVE_IMAP2001)
 	imap_globals->quota_return = NIL;
 	imap_globals->imap_acl_list = NIL;
+	imap_globals->imap_annotation_list = NIL;
 #endif
 	imap_globals->gets_stream = NIL;
 }
@@ -1547,7 +1598,119 @@ PHP_FUNCTION(imap_getacl)
 }
 /* }}} */
 #endif /* HAVE_IMAP2000 || HAVE_IMAP2001 */
+
+#if defined(HAVE_IMAP2005)
+
+/* {{{ proto bool imap_setannotation(resource stream_id, string mailbox, string entry, string attr, string value)
+	Sets an annotation for a given mailbox */
+PHP_FUNCTION(imap_setannotation)
+{
+	zval **streamind, **mailbox, **entry, **attr, **value;
+	pils *imap_le_struct;
+        long ret;
+
+        // TODO: Use zend_parse_parameters here
+	if (ZEND_NUM_ARGS() != 5 || zend_get_parameters_ex(5, &streamind, &mailbox, &entry, &attr, &value) == FAILURE) {
+		ZEND_WRONG_PARAM_COUNT();
+	}
+
+	ZEND_FETCH_RESOURCE(imap_le_struct, pils *, streamind, -1, "imap", le_imap);
+
+	convert_to_string_ex(mailbox);
+	convert_to_string_ex(entry);
+	convert_to_string_ex(attr);
+	convert_to_string_ex(value);
+
+        // create annotation object
+        ANNOTATION *annotation = mail_newannotation();
+        if (!annotation)
+            RETURN_FALSE;
+        annotation->values = mail_newannotationvalue();
+        if (!annotation->values) {
+            mail_free_annotation(&annotation);
+            RETURN_FALSE;
+        }
+
+        // fill in annotation values
+        annotation->mbox = Z_STRVAL_PP(mailbox);
+        annotation->entry = Z_STRVAL_PP(entry);
+        annotation->values->attr = Z_STRVAL_PP(attr);
+        annotation->values->value = Z_STRVAL_PP(value);
+
+        ret = imap_setannotation(imap_le_struct->imap_stream, annotation);
+
+        // make sure mail_free_annotation doesn't free our variables
+        annotation->mbox = NULL;
+        annotation->entry = NULL;
+        annotation->values->attr = NULL;
+        annotation->values->value = NULL;
+        mail_free_annotation(&annotation);
+
+        RETURN_BOOL(ret);
+}
+/* }}} */
+
+/* {{{ proto array imap_getannotation(resource stream_id, string mailbox, string entry, string attr)
+	Gets the ACL for a given mailbox */
+PHP_FUNCTION(imap_getannotation)
+{
+	zval **streamind, **mailbox, **entry, **attr;
+	pils *imap_le_struct;
+        long ret;
+
+	if(ZEND_NUM_ARGS() != 4 || zend_get_parameters_ex(4, &streamind, &mailbox, &entry, &attr) == FAILURE) {
+		ZEND_WRONG_PARAM_COUNT();
+	}

+	ZEND_FETCH_RESOURCE(imap_le_struct, pils *, streamind, -1, "imap", le_imap);
+
+	convert_to_string_ex(mailbox);
+	convert_to_string_ex(entry);
+	convert_to_string_ex(attr);
+
+	/* initializing the special array for the return values */
+	if (array_init(return_value) == FAILURE) {
+		RETURN_FALSE;
+	}
+
+        // fillup calling parameters
+        STRINGLIST *entries = mail_newstringlist();
+        if (!entries)
+            RETURN_FALSE;
+
+        STRINGLIST *cur = entries;
+        cur->text.data = (unsigned char *)cpystr(Z_STRVAL_PP(entry));
+        cur->text.size = Z_STRLEN_PP(entry);
+        cur->next = NIL;
+
+        STRINGLIST *attributes = mail_newstringlist();
+        if (!attributes)
+            RETURN_FALSE;
+        cur = attributes;
+        cur->text.data = (unsigned char *)cpystr (Z_STRVAL_PP(attr));
+        cur->text.size = Z_STRLEN_PP(attr);
+        cur->next = NIL;
+
+        IMAPG(imap_annotation_list) = return_value;
+
+        /* set the callback for the GET_ANNOTATION function */
+	mail_parameters(NIL, SET_ANNOTATION, (void *) mail_getannotation);
+        ret = imap_getannotation(imap_le_struct->imap_stream, Z_STRVAL_PP(mailbox), entries, attributes);
+
+        mail_free_stringlist(&entries);
+        mail_free_stringlist(&attributes);
+
+        if (!ret) {
+            zval_dtor(return_value);
+            RETURN_FALSE;
+        }
+
+	IMAPG(imap_annotation_list) = NIL;
+}
+/* }}} */
+
+#endif /* HAVE_IMAP2005 */
+
 /* {{{ proto bool imap_expunge(resource stream_id)
    Permanently delete all messages marked for deletion */
 PHP_FUNCTION(imap_expunge)
@@ -3190,6 +3353,42 @@ PHP_FUNCTION(imap_msgno)
 }
 /* }}} */

+/* {{{ proto object imap_status_current(resource stream_id, int options)
+   Get (cached) status info from current mailbox */
+PHP_FUNCTION(imap_status_current)
+{
+ 	zval **streamind, **pflags;
+	pils *imap_le_struct;
+	long flags = 0L;
+
+ 	if (ZEND_NUM_ARGS() != 2 || zend_get_parameters_ex(2, &streamind, &pflags) == FAILURE) {
+ 		ZEND_WRONG_PARAM_COUNT();
+ 	}
+
+	ZEND_FETCH_RESOURCE(imap_le_struct, pils *, streamind, -1, "imap", le_imap);
+
+	convert_to_long_ex(pflags);
+	flags = Z_LVAL_PP(pflags);
+
+	if (object_init(return_value) == FAILURE) {
+		RETURN_FALSE;
+	}
+
+	if (flags & SA_MESSAGES) {
+		add_property_long(return_value, "messages", imap_le_struct->imap_stream->nmsgs);
+	}
+	if (flags & SA_RECENT) {
+		add_property_long(return_value, "recent", imap_le_struct->imap_stream->recent);
+	}
+	if (flags & SA_UIDNEXT) {
+		add_property_long(return_value, "uidnext", imap_le_struct->imap_stream->uid_last+1);
+	}
+	if (flags & SA_UIDVALIDITY) {
+		add_property_long(return_value, "uidvalidity", imap_le_struct->imap_stream->uid_validity);
+	}
+}
+/* }}} */
+
 /* {{{ proto object imap_status(resource stream_id, string mailbox, int options)
    Get status info from a mailbox */
 PHP_FUNCTION(imap_status)
diff -Naurp php-5.3.4RC1/ext/imap/php_imap.h php-5.3.4RC1.oden/ext/imap/php_imap.h
--- php-5.3.4RC1/ext/imap/php_imap.h	2010-01-03 10:23:27.000000000 +0100
+++ php-5.3.4RC1.oden/ext/imap/php_imap.h	2010-11-22 10:01:42.542862889 +0100
@@ -153,6 +153,7 @@ PHP_FUNCTION(imap_lsub);
 PHP_FUNCTION(imap_lsub_full);
 PHP_FUNCTION(imap_create);
 PHP_FUNCTION(imap_rename);
+PHP_FUNCTION(imap_status_current);
 PHP_FUNCTION(imap_status);
 PHP_FUNCTION(imap_bodystruct);
 PHP_FUNCTION(imap_fetch_overview);
@@ -173,6 +174,9 @@ PHP_FUNCTION(imap_mime_header_decode);
 PHP_FUNCTION(imap_thread);
 PHP_FUNCTION(imap_timeout);

+// TODO: Needs fixing in configure in
+#define HAVE_IMAP2005 1
+
 #if defined(HAVE_IMAP2000) || defined(HAVE_IMAP2001)
 PHP_FUNCTION(imap_get_quota);
 PHP_FUNCTION(imap_get_quotaroot);
@@ -180,7 +184,10 @@ PHP_FUNCTION(imap_set_quota);
 PHP_FUNCTION(imap_setacl);
 PHP_FUNCTION(imap_getacl);
 #endif
-
+#if defined(HAVE_IMAP2005)
+PHP_FUNCTION(imap_setannotation);
+PHP_FUNCTION(imap_getannotation);
+#endif

 ZEND_BEGIN_MODULE_GLOBALS(imap)
 	char *imap_user;
@@ -211,6 +218,9 @@ ZEND_BEGIN_MODULE_GLOBALS(imap)
 	zval **quota_return;
 	zval *imap_acl_list;
 #endif
+#if defined(HAVE_IMAP2005)
+        zval *imap_annotation_list;
+#endif
 	/* php_stream for php_mail_gets() */
 	php_stream *gets_stream;
 ZEND_END_MODULE_GLOBALS(imap)

repo_name: ayhanyalcinsoy/main


code:
diff -Naurp php-5.3.4RC1/ext/imap/php_imap.c php-5.3.4RC1.oden/ext/imap/php_imap.c
--- php-5.3.4RC1/ext/imap/php_imap.c	2010-11-22 10:39:59.349863220 +0100
+++ php-5.3.4RC1.oden/ext/imap/php_imap.c	2010-11-22 10:40:14.709956619 +0100
@@ -163,6 +163,11 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_imap_geta
 	ZEND_ARG_INFO(0, stream_id)
 	ZEND_ARG_INFO(0, mailbox)
 ZEND_END_ARG_INFO()
+
+ZEND_BEGIN_ARG_INFO_EX(arginfo_imap_myrights, 0, 0, 2)
+	ZEND_ARG_INFO(0, stream_id)
+	ZEND_ARG_INFO(0, mailbox)
+ZEND_END_ARG_INFO()
 #endif
 #if defined(HAVE_IMAP2005)
 ZEND_BEGIN_ARG_INFO_EX(arginfo_imap_setannotation, 0, 0, 5)
@@ -558,6 +563,7 @@ const zend_function_entry imap_functions
 	PHP_FE(imap_set_quota,							arginfo_imap_set_quota)
 	PHP_FE(imap_setacl,								arginfo_imap_setacl)
 	PHP_FE(imap_getacl,								arginfo_imap_getacl)
+	PHP_FE(imap_myrights,							arginfo_imap_myrights)
 #endif
 #if defined(HAVE_IMAP2005)
  	PHP_FE(imap_setannotation,						arginfo_imap_setannotation)
@@ -822,6 +828,20 @@ void mail_getacl(MAILSTREAM *stream, cha
 	}
 }
 /* }}} */
+
+/* {{{ mail_myrights
+ *
+ * Mail MYRIGHTS callback
+ * Called via the mail_parameter function in c-client:src/c-client/mail.c
+ */
+void mail_myrights(MAILSTREAM *stream, char *mailbox, char *rights)
+{
+	TSRMLS_FETCH();
+
+	ZVAL_STRING(IMAPG(imap_acl_list), rights, 1);
+
+}
+/* }}} */
 #endif

 #if defined(HAVE_IMAP2005)
@@ -1597,6 +1617,36 @@ PHP_FUNCTION(imap_getacl)
 	IMAPG(imap_acl_list) = NIL;
 }
 /* }}} */
+
+/* {{{ proto string imap_myrights(resource stream_id, string mailbox)
+	Gets my rights (ACL) for a given mailbox */
+PHP_FUNCTION(imap_myrights)
+{
+	zval **streamind, **mailbox;
+	pils *imap_le_struct;
+
+	if(ZEND_NUM_ARGS() != 2 || zend_get_parameters_ex(2, &streamind, &mailbox) == FAILURE) {
+		ZEND_WRONG_PARAM_COUNT();
+	}
+
+	ZEND_FETCH_RESOURCE(imap_le_struct, pils *, streamind, -1, "imap", le_imap);
+
+	convert_to_string_ex(mailbox);
+
+	IMAPG(imap_acl_list) = return_value;
+
+	/* set the callback for the GET_ACL function */
+	mail_parameters(NIL, SET_MYRIGHTS, (void *) mail_myrights);
+	if(!imap_myrights(imap_le_struct->imap_stream, Z_STRVAL_PP(mailbox))) {
+		php_error(E_WARNING, "c-client imap_myrights failed");
+		zval_dtor(return_value);
+		RETURN_FALSE;
+	}
+
+	IMAPG(imap_acl_list) = NIL;
+}
+/* }}} */
+
 #endif /* HAVE_IMAP2000 || HAVE_IMAP2001 */

 #if defined(HAVE_IMAP2005)
diff -Naurp php-5.3.4RC1/ext/imap/php_imap.h php-5.3.4RC1.oden/ext/imap/php_imap.h
--- php-5.3.4RC1/ext/imap/php_imap.h	2010-11-22 10:39:59.349863220 +0100
+++ php-5.3.4RC1.oden/ext/imap/php_imap.h	2010-11-22 10:40:14.709956619 +0100
@@ -183,6 +183,7 @@ PHP_FUNCTION(imap_get_quotaroot);
 PHP_FUNCTION(imap_set_quota);
 PHP_FUNCTION(imap_setacl);
 PHP_FUNCTION(imap_getacl);
+PHP_FUNCTION(imap_myrights);
 #endif
 #if defined(HAVE_IMAP2005)
 PHP_FUNCTION(imap_setannotation);


code:
--- ext/imap/config.m4	2006-01-23 23:55:13.000000000 +0200
+++ ext.orig/imap/config.m4	2006-01-23 23:56:08.000000000 +0200
@@ -146,12 +146,6 @@
       AC_MSG_ERROR(Cannot find rfc822.h. Please check your c-client installation.)
     fi

-    if test -r "$IMAP_DIR/c-client/c-client.a"; then
-      ln -s "$IMAP_DIR/c-client/c-client.a" "$IMAP_DIR/c-client/libc-client.a" >/dev/null 2>&1
-    elif test -r "$IMAP_DIR/$PHP_LIBDIR/c-client.a"; then
-      ln -s "$IMAP_DIR/$PHP_LIBDIR/c-client.a" "$IMAP_DIR/$PHP_LIBDIR/libc-client.a" >/dev/null 2>&1
-    fi
-
     for lib in c-client4 c-client imap; do
       IMAP_LIB=$lib
       IMAP_LIB_CHK($PHP_LIBDIR)


code:
--- php-5.2.14.orig/ext/gd/gd.c	2011-01-26 12:38:42.956023043 +0200
+++ php-5.2.14/ext/gd/gd.c	2011-01-26 13:37:21.171023045 +0200
@@ -4593,6 +4593,11 @@
 		return;
 	}

+    if (aa_steps != 4 && aa_steps != 16) {
+        php_error_docref(NULL TSRMLS_CC, E_WARNING, "Antialias steps must be 4 or 16");
+        RETURN_FALSE;
+    }
+
 	ZEND_FETCH_RESOURCE(bg_img, gdImagePtr, &img, -1, "Image", le_gd);
 	ZEND_FETCH_RESOURCE(f_ind, int *, &fnt, -1, "Type 1 font", le_ps_font);


code:
Index: ext/date/lib/parse_tz.c
===================================================================
RCS file: /repository/php-src/ext/date/lib/parse_tz.c,v
retrieving revision 1.35
diff -u -r1.35 parse_tz.c
--- ext/date/lib/parse_tz.c	31 Dec 2007 07:12:08 -0000	1.35
+++ ext/date/lib/parse_tz.c	10 Jan 2008 11:42:15 -0000
@@ -20,6 +20,16 @@

 #include "timelib.h"

+#ifdef HAVE_SYSTEM_TZDATA
+#include <sys/mman.h>
+#include <sys/stat.h>
+#include <limits.h>
+#include <fcntl.h>
+#include <unistd.h>
+
+#include "php_scandir.h"
+#endif
+
 #include <stdio.h>

 #ifdef HAVE_STRING_H
@@ -27,7 +37,10 @@
 #else
 #include <strings.h>
 #endif
+
+#ifndef HAVE_SYSTEM_TZDATA
 #include "timezonedb.h"
+#endif

 #if (defined(__APPLE__) || defined(__APPLE_CC__)) && (defined(__BIG_ENDIAN__) || defined(__LITTLE_ENDIAN__))
 # if defined(__LITTLE_ENDIAN__)
@@ -202,6 +215,195 @@
 	}
 }

+#ifdef HAVE_SYSTEM_TZDATA
+
+#ifdef HAVE_SYSTEM_TZDATA_PREFIX
+#define ZONEINFO_PREFIX HAVE_SYSTEM_TZDATA_PREFIX
+#else
+#define ZONEINFO_PREFIX "/usr/share/zoneinfo"
+#endif
+
+static const timelib_tzdb *timezonedb_system = NULL;
+
+/* Filter out some non-tzdata files and the posix/right databases, if
+ * present. */
+static int index_filter(const struct dirent *ent)
+{
+	return strcmp(ent->d_name, ".") != 0
+		&& strcmp(ent->d_name, "..") != 0
+		&& strcmp(ent->d_name, "posix") != 0
+		&& strcmp(ent->d_name, "posixrules") != 0
+		&& strcmp(ent->d_name, "right") != 0
+		&& strstr(ent->d_name, ".tab") == NULL;
+}
+
+/* Create the zone identifier index by trawling the filesystem. */
+static void create_zone_index(timelib_tzdb *db)
+{
+	size_t dirstack_size,  dirstack_top;
+	size_t index_size, index_next;
+	timelib_tzdb_index_entry *db_index;
+	char **dirstack;
+
+	/* LIFO stack to hold directory entres to scan; each slot is a
+	 * directory name relative to the zoneinfo prefix. */
+	dirstack_size = 32;
+	dirstack = malloc(dirstack_size * sizeof *dirstack);
+	dirstack_top = 1;
+	dirstack[0] = strdup("");
+
+	/* Index array. */
+	index_size = 64;
+	db_index = malloc(index_size * sizeof *db_index);
+	index_next = 0;
+
+	do {
+		struct dirent **ents;
+		char name[PATH_MAX], *top;
+		int count;
+
+		/* Pop the top stack entry, and iterate through its contents. */
+		top = dirstack[--dirstack_top];
+		snprintf(name, sizeof name, ZONEINFO_PREFIX "/%s", top);
+
+		count = php_scandir(name, &ents, index_filter, php_alphasort);
+
+		while (count > 0) {
+			struct stat st;
+			const char *leaf = ents[count - 1]->d_name;
+
+			snprintf(name, sizeof name, ZONEINFO_PREFIX "/%s/%s",
+				 top, leaf);
+
+			if (strlen(name) && stat(name, &st) == 0) {
+				/* Name, relative to the zoneinfo prefix. */
+				const char *root = top;
+
+				if (root[0] == '/') root++;
+
+				snprintf(name, sizeof name, "%s%s%s", root,
+					 *root ? "/": "", leaf);
+
+				if (S_ISDIR(st.st_mode)) {
+					if (dirstack_top == dirstack_size) {
+						dirstack_size *= 2;
+						dirstack = realloc(dirstack,
+								   dirstack_size * sizeof *dirstack);
+					}
+					dirstack[dirstack_top++] = strdup(name);
+				}
+				else {
+					if (index_next == index_size) {
+						index_size *= 2;
+						db_index = realloc(db_index,
+								   index_size * sizeof *db_index);
+					}
+
+					db_index[index_next].id = strdup(name);
+					db_index[index_next++].pos = 0;
+				}
+			}
+
+			free(ents[--count]);
+		}
+
+		free(ents);
+		free(top);
+	} while (dirstack_top);
+
+	db->index = db_index;
+	db->index_size = index_next;
+
+	free(dirstack);
+}
+
+/* Return the mmap()ed tzfile if found, else NULL.  On success, the
+ * length of the mapped data is placed in *length. */
+static char *map_tzfile(const char *timezone, size_t *length)
+{
+	char fname[PATH_MAX];
+	struct stat st;
+	char *p;
+	int fd;
+
+	if (strstr(timezone, "..") != NULL) {
+		return NULL;
+	}
+
+	snprintf(fname, sizeof fname, ZONEINFO_PREFIX "/%s", timezone);
+
+	fd = open(fname, O_RDONLY);
+	if (fd == -1) {
+		return NULL;
+	} else if (fstat(fd, &st) != 0 || st.st_size < 21) {
+		close(fd);
+		return NULL;
+	}
+
+	*length = st.st_size;
+	p = mmap(NULL, st.st_size, PROT_READ, MAP_SHARED, fd, 0);
+	close(fd);
+
+	return p != MAP_FAILED ? p : NULL;
+}
+
+const timelib_tzdb *timelib_builtin_db(void)
+{
+	if (timezonedb_system == NULL) {
+		timelib_tzdb *tmp = malloc(sizeof *tmp);
+
+		tmp->version = "0.system";
+		tmp->data = NULL;
+		create_zone_index(tmp);
+		timezonedb_system = tmp;
+	}
+
+	return timezonedb_system;
+}
+
+const timelib_tzdb_index_entry *timelib_timezone_builtin_identifiers_list(int *count)
+{
+	*count = timezonedb_system->index_size;
+	return timezonedb_system->index;
+}
+
+int timelib_timezone_id_is_valid(char *timezone, const timelib_tzdb *tzdb)
+{
+	char fname[PATH_MAX];
+
+	if (strstr(timezone, "..") != NULL) {
+		return 0;
+	}
+
+	snprintf(fname, sizeof fname, ZONEINFO_PREFIX "/%s", timezone);
+
+	return access(fname, R_OK) == 0 ? 1 : 0;
+}
+
+timelib_tzinfo *timelib_parse_tzfile(char *timezone, const timelib_tzdb *tzdb)
+{
+	char *tzf, *orig;
+	timelib_tzinfo *tmp;
+	size_t len;
+
+	orig = map_tzfile(timezone, &len);
+	if (orig == NULL) {
+		return NULL;
+	}
+
+	tmp = timelib_tzinfo_ctor(timezone);
+
+	tzf = orig + 20;
+	read_header(&tzf, tmp);
+	read_transistions(&tzf, tmp);
+	read_types(&tzf, tmp);
+
+	munmap(orig, len);
+
+	return tmp;
+}
+#else /* !HAVE_SYSTEM_TZDATA */
+
 static int seek_to_tz_position(const unsigned char **tzf, char *timezone, const timelib_tzdb *tzdb)
 {
 	int left = 0, right = tzdb->index_size - 1;
@@ -258,6 +460,7 @@

 	return tmp;
 }
+#endif

 static ttinfo* fetch_timezone_offset(timelib_tzinfo *tz, timelib_sll ts, timelib_sll *transition_time)
 {
Index: ext/date/lib/timelib.m4
===================================================================
RCS file: /repository/php-src/ext/date/lib/timelib.m4,v
retrieving revision 1.4
diff -u -r1.4 timelib.m4
--- ext/date/lib/timelib.m4	3 Jul 2005 23:30:52 -0000	1.4
+++ ext/date/lib/timelib.m4	10 Jan 2008 11:42:16 -0000
@@ -78,3 +78,17 @@

 dnl Check for strtoll, atoll
 AC_CHECK_FUNCS(strtoll atoll strftime)
+
+PHP_ARG_WITH(system-tzdata, for use of system timezone data,
+[  --with-system-tzdata[=DIR]      to specify use of system timezone data],
+no, no)
+
+if test "$PHP_SYSTEM_TZDATA" != "no"; then
+   AC_DEFINE(HAVE_SYSTEM_TZDATA, 1, [Define if system timezone data is used])
+
+   if test "$PHP_SYSTEM_TZDATA" != "yes"; then
+      AC_DEFINE_UNQUOTED(HAVE_SYSTEM_TZDATA_PREFIX, "$PHP_SYSTEM_TZDATA",
+                         [Define for location of system timezone data])
+   fi
+fi
+


code:
<?xml version="1.0" ?>
<!DOCTYPE PISI SYSTEM "http://www.pisilinux.org/projeler/pisi/pisi-spec.dtd">
<PISI>
    <Source>
        <Name>php</Name>
        <Homepage>http://www.php.net</Homepage>
        <Packager>
            <Name>Fatih Turgel</Name>
            <Email>turgelfatih@gmail.com</Email>
        </Packager>
        <License>PHP</License>
        <IsA>library</IsA>
        PHP7 is an HTML-embedded scripting language. The goal of the language is to allow web developers to write dynamically generated pages quickly
        <Description>PHP7 is an HTML-embedded scripting language. Much of its syntax is borrowed from C, Java and Perl with a couple of unique PHP-specific features thrown in. The goal of the language is to allow web developers to write dynamically generated pages quickly.</Description>
        <Archive sha1sum="b15bd8fef8d5b99b993784e9c2254ab82f616c64" type="tarbz2">http://us2.php.net/distributions/php-7.2.0.tar.bz2</Archive>
        <BuildDependencies>
            <Dependency>gd-devel</Dependency>
            <Dependency>re2c</Dependency>
            <Dependency>libzip-devel</Dependency>
            <Dependency>harfbuzz-devel</Dependency>
            <Dependency>apr-devel</Dependency>
            <Dependency>apr-util-devel</Dependency>
            <Dependency>apache</Dependency>
            <Dependency>postfix</Dependency>
            <Dependency>libxslt-devel</Dependency>
            <Dependency>db-devel</Dependency>
            <Dependency>mariadb-lib</Dependency>
            <Dependency>libmcrypt-devel</Dependency>
            <Dependency>mit-kerberos</Dependency>
            <Dependency>libc-client</Dependency>
            <Dependency>postgresql-server</Dependency>
            <Dependency>libjpeg-turbo-devel</Dependency>
            <Dependency>zlib-devel</Dependency>
            <Dependency>curl-devel</Dependency>
            <Dependency>gdbm-devel</Dependency>
            <Dependency>libpng-devel</Dependency>
            <Dependency>freetype-devel</Dependency>
            <Dependency>openssl-devel</Dependency>
        </BuildDependencies>
        <Patches>

            <Patch level="0">db6.patch</Patch>

            <Patch level="1">debian/052-phpinfo_no_configure.patch</Patch>
        </Patches>
    </Source>

    <Package>
        <Name>php-cli</Name>
        <RuntimeDependencies>
            <Dependency version="current">php-common</Dependency>
            <Dependency>gd</Dependency>
            <Dependency>curl</Dependency>
            <Dependency>zlib</Dependency>
            <Dependency>bzip2</Dependency>
            <Dependency>libpng</Dependency>
            <Dependency>libxslt</Dependency>
            <Dependency>libxml2</Dependency>
            <Dependency>freetype</Dependency>
            <Dependency>mariadb-lib</Dependency>
            <Dependency>libmcrypt</Dependency>
            <Dependency>mit-kerberos</Dependency>
            <Dependency>postgresql-lib</Dependency>
            <Dependency>openldap-client</Dependency>
            <Dependency>libjpeg-turbo</Dependency>
        </RuntimeDependencies>
        <Files>
            <Path fileType="config">/etc/php/cli</Path>
            <Path fileType="executable">/usr/bin</Path>
            <Path fileType="man">/usr/share/man</Path>
        </Files>
        <AdditionalFiles>
            <AdditionalFile target="/usr/bin/go-pear" permission="0755" owner="root">go-pear</AdditionalFile>
        </AdditionalFiles>
    </Package>

    <Package>
        <Name>php-common</Name>
        Common config files for PHP
        <RuntimeDependencies>
            <Dependency>db</Dependency>
            <Dependency>pam</Dependency>
            <Dependency>gdbm</Dependency>
            <Dependency>mit-kerberos</Dependency>
        </RuntimeDependencies>

        <Files>
            <Path fileType="library">/usr/lib/php/modules</Path>
            <Path fileType="data">/usr/share/php7</Path>
            <Path fileType="data">/etc/php/ext</Path>
        </Files>
    </Package>

    <Package>
        <Name>php-devel</Name>
        Development files for PHP
        <RuntimeDependencies>
            <Dependency version="current">php-common</Dependency>
        </RuntimeDependencies>
        <Files>
            <Path fileType="executable">/usr/bin/php-config</Path>
            <Path fileType="executable">/usr/bin/phpize</Path>
            <Path fileType="header">/usr/include</Path>
            <Path fileType="library">/usr/lib/php/build</Path>
            <Path fileType="man">/usr/share/man/man1/php-config*</Path>
            <Path fileType="man">/usr/share/man/man1/phpize*</Path>
        </Files>
    </Package>

    <Package>
        <Name>mod_php</Name>
        <PartOf>server.web</PartOf>
        <RuntimeDependencies>
            <Dependency>xz</Dependency>
            <Dependency>apache</Dependency>
            <Dependency>libtool-ltdl</Dependency>
            <Dependency>mariadb-lib</Dependency>
            <Dependency>postgresql-lib</Dependency>
            <Dependency>gd</Dependency>
            <Dependency>libxslt</Dependency>
            <Dependency>mit-kerberos</Dependency>
            <Dependency>openldap-client</Dependency>
            <Dependency>cyrus-sasl</Dependency>
            <Dependency>harfbuzz</Dependency>
            <Dependency>php-common</Dependency>
            <Dependency>libmcrypt</Dependency>
            <Dependency>libjpeg-turbo</Dependency>
        </RuntimeDependencies>
        <Files>
            <Path fileType="library">/usr/lib/apache2/modules/libphp7.so</Path>
            <Path fileType="config">/etc/apache2</Path>
            <Path fileType="config">/etc/php/apache2</Path>
        </Files>
        <AdditionalFiles>
            <AdditionalFile target="/etc/apache2/modules.d/70_mod_php7.conf" permission="0644" owner="root">70_mod_php7.conf</AdditionalFile>
        </AdditionalFiles>
    </Package>

    <Package>
        <Name>php-zip</Name>
        Zip extension for PHP
        <RuntimeDependencies>
            <Dependency>php-common</Dependency>
            <Dependency>libzip</Dependency>
            <Dependency>mit-kerberos</Dependency>
        </RuntimeDependencies>
        <Files>
            <Path fileType="library">/usr/lib/php/modules/zip.so</Path>
            <Path fileType="config">/etc/php/cli/ext/10-php-zip.ini</Path>
            <Path fileType="config">/etc/php/ext/10-php-zip.ini</Path>
        </Files>
        <AdditionalFiles>
            <AdditionalFile target="/etc/php/ext/10-php-zip.ini" permission="0644" owner="root">10-php-zip.ini</AdditionalFile>
        </AdditionalFiles>
    </Package>

    <Package>
        <Name>php-imap</Name>
        Module for PHP to enable IMAP support
        <RuntimeDependencies>
            <Dependency>openssl</Dependency>
            <Dependency>e2fsprogs</Dependency>
            <Dependency>php-common</Dependency>
            <Dependency>libc-client</Dependency>
            <Dependency>mit-kerberos</Dependency>
        </RuntimeDependencies>
        <Files>
            <Path fileType="library">/usr/lib/php/modules/imap.so</Path>
            <Path fileType="config">/etc/php/ext/11-php-imap.ini</Path>
            <Path fileType="config">/etc/php/cli/ext/11-php-imap.ini</Path>
            <Path fileType="config">/etc/php/apache2/ext/11-php-imap.ini</Path>
        </Files>
        <AdditionalFiles>
            <AdditionalFile target="/etc/php/ext/11-php-imap.ini" permission="0644" owner="root">11-php-imap.ini</AdditionalFile>
        </AdditionalFiles>
    </Package>
    <Package>
        <Name>php-fpm</Name>
        FPM for PHP
        <RuntimeDependencies>
            <Dependency>libxslt</Dependency>
            <Dependency>libmcrypt</Dependency>
            <Dependency>php-common</Dependency>
            <Dependency>libjpeg-turbo</Dependency>
            <Dependency>postgresql-lib</Dependency>
            <Dependency>openldap-client</Dependency>
        </RuntimeDependencies>
        <Files>
            <Path fileType="executable">/usr/sbin/php-fpm</Path>
            <Path fileType="man">/usr/share/man/man8/php-fpm.8</Path>
            <Path fileType="config">/etc/php/ext/php-fpm.conf</Path>
            <Path fileType="config">/etc/php-fpm.d/www.conf.default</Path>
            <Path fileType="data">/usr/share/fpm</Path>
            <Path fileType="data">/run</Path>
            <Path fileType="data">/var/log</Path>
        </Files>
        <AdditionalFiles>
            <AdditionalFile target="/etc/php/ext/php-fpm.conf" permission="0644" owner="root">php-fpm.conf</AdditionalFile>
        </AdditionalFiles>
        <Provides>
            <COMAR script="service.py">System.Service</COMAR>
        </Provides>
    </Package>

    <History>
        <Update release="4">
            <Date>2017-12-24</Date>
            <Version>7.2.0</Version>
            <Comment>Version Bump</Comment>
            <Name>Mustafa Cinasal</Name>
            <Email>muscnsl@gmail.com</Email>
        </Update>
        <Update release="3">
            <Date>2017-06-06</Date>
            <Version>5.6.30</Version>
            <Comment>Version Bump</Comment>
            <Name>Kamil Atlı</Name>
            <Email>suvari@pisilinux.org</Email>
        </Update>
        <Update release="2">
            <Date>2016-06-09</Date>
            <Version>5.6.20</Version>
            <Comment>Release Bump</Comment>
            <Name>Pisi Linux Community</Name>
            <Email>admin@pisilinux.org</Email>
        </Update>
        <Update release="1">
            <Date>2016-04-20</Date>
            <Version>5.6.20</Version>
            <Comment>First release</Comment>
            <Name>Serdar Soytetir</Name>
            <Email>kaptan@pisilinux.org</Email>
        </Update>
    </History>
</PISI>


code:
<?xml version="1.0" ?>
<PISI>
    <Source>
        <Name>php</Name>
        Dinamik HTML sayfaları oluşturmak için kullanılan bir programlama dili
        <Description xml:lang="tr">PHP7, dinamik HTML sayfaları oluşturmak için kullanılan bir programlama dilidir. Dil yapısının önemli bir kısmı C, Java ve Perl'den alınmıştır. Bu dilin amacı, web geliştiricilerinin kısa zamanda dinamik sayfalar oluşturmasına imkan vermektir.</Description>
        <Description xml:lang="es">PHP7 es un languaje interpretado que puede estar embebido en HTML. Muchas partes de su sintaxis fueron prestados de C, Java y Perl con algunas facilidades agregados únicas de PHP. El lenguaje permite a desarrolladores web escribir de manera sencilla páginas con contenido dinámico.</Description>
    </Source>

    <Package>
        <Name>php-common</Name>
        PHP için genel yapılandırma dosyaları
    </Package>
</PISI>


code:
<PISI>
    <Name>programming.profiler</Name>
</PISI>


code:
#!/usr/bin/python
# -*- coding: utf-8 -*-
#
# Licensed under the GNU General Public License, version 3.
# See the file http://www.gnu.org/licenses/gpl.txt

from pisi.actionsapi import autotools
from pisi.actionsapi import pisitools
from pisi.actionsapi import shelltools
from pisi.actionsapi import get

def setup():
    shelltools.export("CFLAGS", get.CFLAGS().replace("-fstack-protector",""))
    shelltools.export("CPPFLAGS", get.CXXFLAGS().replace("-fstack-protector",""))
    autotools.configure("--without-mpicc")

def build():
    autotools.make()

def install():
    autotools.rawInstall("DESTDIR=%s" % get.installDIR())

    pisitools.dodoc("AUTHORS", "FAQ.txt", "NEWS", "README*")


code:
------------------------------------------------------------------------
r15766 | mjw | 2016-01-21 03:37:43 -0800 (Thu, 21 Jan 2016) | 13 lines
Changed paths:
   M /trunk/NEWS
   M /trunk/coregrind/m_libcproc.c
   M /trunk/coregrind/m_main.c
   M /trunk/coregrind/m_syswrap/syswrap-generic.c
   M /trunk/coregrind/m_syswrap/syswrap-solaris.c

Bug #357833 Setting RLIMIT_DATA to zero breaks with linux 4.5+

We used to set the process datasize rlimit to zero to prevent
any internal use of brk() from having any effect. But later
linux kernels redefine RLIMIT_DATA as the size of any data
areas, including some dynamic mmap memory allocations.

See bug #357833 for the commit that went into linux 4.5
changing the definition of RLIMIT_DATA. So don't mess with
RLIMIT_DATA anymore. Just remember it for use in the syscall
wrappers.

This also cleans up some hacks around the execv and spawn wrappers.
------------------------------------------------------------------------
Index: coregrind/m_syswrap/syswrap-generic.c
===================================================================
--- coregrind/m_syswrap/syswrap-generic.c	(revision 15765)
+++ coregrind/m_syswrap/syswrap-generic.c	(revision 15766)
@@ -3014,9 +3014,6 @@
       vg_assert(j == tot_args+1);
    }

-   /* restore the DATA rlimit for the child */
-   VG_(setrlimit)(VKI_RLIMIT_DATA, &VG_(client_rlimit_data));
-
    /*
       Set the signal state up for exec.

Index: coregrind/m_syswrap/syswrap-solaris.c
===================================================================
--- coregrind/m_syswrap/syswrap-solaris.c	(revision 15765)
+++ coregrind/m_syswrap/syswrap-solaris.c	(revision 15766)
@@ -1589,10 +1589,6 @@
 #undef COPY_CHAR_TO_ARGENV
 #undef COPY_STRING_TOARGENV

-   /* HACK: Temporarily restore the DATA rlimit for spawned child.
-      This is a terrible hack to provide sensible brk limit for child. */
-   VG_(setrlimit)(VKI_RLIMIT_DATA, &VG_(client_rlimit_data));
-
    /* Actual spawn() syscall. */
    SysRes res = VG_(do_syscall5)(__NR_spawn, (UWord) path, (UWord) attrs,
                                  attrs_size, (UWord) argenv, argenv_size);
@@ -1599,11 +1595,6 @@
    SET_STATUS_from_SysRes(res);
    VG_(free)(argenv);

-   /* Restore DATA rlimit back to its previous value set in m_main.c. */
-   struct vki_rlimit zero = { 0, 0 };
-   zero.rlim_max = VG_(client_rlimit_data).rlim_max;
-   VG_(setrlimit)(VKI_RLIMIT_DATA, &zero);
-
    if (SUCCESS) {
       PRINT("   spawn: process %d spawned child %ld\n", VG_(getpid)(), RES);
    }
@@ -3794,9 +3785,6 @@
       VG_(sigprocmask)(VKI_SIG_SETMASK, &tst->sig_mask, NULL);
    }

-   /* Restore the DATA rlimit for the child. */
-   VG_(setrlimit)(VKI_RLIMIT_DATA, &VG_(client_rlimit_data));
-
    /* Debug-only printing. */
    if (0) {
       HChar **cpp;
Index: coregrind/m_main.c
===================================================================
--- coregrind/m_main.c	(revision 15765)
+++ coregrind/m_main.c	(revision 15766)
@@ -1627,7 +1627,6 @@
    Bool    logging_to_fd      = False;
    const HChar* xml_fname_unexpanded = NULL;
    Int     loglevel, i;
-   struct vki_rlimit zero = { 0, 0 };
    XArray* addr2dihandle = NULL;

    //============================================================
@@ -1800,13 +1799,15 @@
    VG_(debugLog)(1, "main", "... %s\n", VG_(name_of_launcher));

    //--------------------------------------------------------------
-   // Get the current process datasize rlimit, and set it to zero.
-   // This prevents any internal uses of brk() from having any effect.
-   // We remember the old value so we can restore it on exec, so that
-   // child processes will have a reasonable brk value.
+   // We used to set the process datasize rlimit to zero to prevent
+   // any internal use of brk() from having any effect. But later
+   // linux kernels redefine RLIMIT_DATA as the size of any data
+   // areas, including some dynamic mmap memory allocations.
+   // See bug #357833 for the commit that went into linux 4.5
+   // changing the definition of RLIMIT_DATA. So don't mess with
+   // RLIMIT_DATA here now anymore. Just remember it for use in
+   // the syscall wrappers.
    VG_(getrlimit)(VKI_RLIMIT_DATA, &VG_(client_rlimit_data));
-   zero.rlim_max = VG_(client_rlimit_data).rlim_max;
-   VG_(setrlimit)(VKI_RLIMIT_DATA, &zero);

    // Get the current process stack rlimit.
    VG_(getrlimit)(VKI_RLIMIT_STACK, &VG_(client_rlimit_stack));
Index: coregrind/m_libcproc.c
===================================================================
--- coregrind/m_libcproc.c	(revision 15765)
+++ coregrind/m_libcproc.c	(revision 15766)
@@ -450,9 +450,6 @@
    HChar** envp;
    SysRes res;

-   /* restore the DATA rlimit for the child */
-   VG_(setrlimit)(VKI_RLIMIT_DATA, &VG_(client_rlimit_data));
-
    envp = VG_(env_clone)(VG_(client_envp));
    VG_(env_remove_valgrind_env_stuff)( envp, True /*ro_strings*/, NULL );

@@ -511,17 +508,9 @@
 #  undef COPY_CHAR_TO_ARGENV
 #  undef COPY_STRING_TOARGENV

-   /* HACK: Temporarily restore the DATA rlimit for spawned child. */
-   VG_(setrlimit)(VKI_RLIMIT_DATA, &VG_(client_rlimit_data));
-
    SysRes res = VG_(do_syscall5)(__NR_spawn, (UWord) filename, (UWord) NULL, 0,
                                  (UWord) argenv, argenv_size);

-   /* Restore DATA rlimit back to its previous value set in m_main.c. */
-   struct vki_rlimit zero = { 0, 0 };
-   zero.rlim_max = VG_(client_rlimit_data).rlim_max;
-   VG_(setrlimit)(VKI_RLIMIT_DATA, &zero);
-
    VG_(free)(argenv);
    for (HChar **p = envp; *p != NULL; p++) {
       VG_(free)(*p);


code:
<?xml version="1.0" ?>
<!DOCTYPE PISI SYSTEM "http://www.pisilinux.org/projeler/pisi/pisi-spec.dtd">
<PISI>
    <Source>
        <Name>valgrind</Name>
        <Homepage>http://www.valgrind.org</Homepage>
        <Packager>
            <Name>PisiLinux Community</Name>
            <Email>admins@pisilinux.org</Email>
        </Packager>
        <License>GPLv2</License>
        <IsA>app:console</IsA>
        <Summary>Memory access debugger for X86 and PPC Linux platforms</Summary>
        <Description>Valgrind is an award-winning suite of tools for debugging and profiling Linux programs. With the tools that come with Valgrind, you can automatically detect many memory management and threading bugs, avoiding hours of frustrating bug-hunting, making your programs more stable. You can also perform detailed profiling, to speed up and reduce memory use of your programs.</Description>
        <Archive sha1sum="ddf13e22dd0ee688bd533fc66b94cf88f75fad86" type="tarbz2">ftp://sourceware.org/pub/valgrind/valgrind-3.13.0.tar.bz2</Archive>
        <BuildDependencies>
            <Dependency>glibc-devel</Dependency>
            <Dependency>boost-devel</Dependency>
            <Dependency>gdb-devel</Dependency>
        </BuildDependencies>
        <Patches>
<!--             <Patch level="0">fix_rlimit.patch</Patch> -->
        </Patches>
    </Source>

    <Package>
        <Name>valgrind</Name>
        <RuntimeDependencies>
            <Dependency>glibc</Dependency>
            <Dependency>perl</Dependency>
        </RuntimeDependencies>
        <Files>
            <Path fileType="executable">/usr/bin</Path>
            <Path fileType="header">/usr/include/valgrind</Path>
            <Path fileType="library">/usr/lib</Path>
            <Path fileType="doc">/usr/share/doc/valgrind</Path>
            <Path fileType="man">/usr/share/man</Path>
        </Files>
    </Package>

    <History>
        <Update release="4">
            <Date>2018-01-31</Date>
            <Version>3.13.0</Version>
            <Comment>Version Bump</Comment>
            <Name>Mustafa Cinasal</Name>
            <Email>muscnsl@gmail.com</Email>
        </Update>
        <Update release="3">
            <Date>2017-02-17</Date>
            <Version>3.12.0</Version>
            <Comment>Version Bump</Comment>
            <Name>Kamil Atlı</Name>
            <Email>suvari@pisilinux.org</Email>
        </Update>
        <Update release="2">
            <Date>2016-06-09</Date>
            <Version>3.11.0</Version>
            <Comment>Release Bump</Comment>
            <Name>Pisi Linux Community</Name>
            <Email>admin@pisilinux.org</Email>
        </Update>
        <Update release="1">
            <Date>2016-03-29</Date>
            <Version>3.11.0</Version>
            <Comment>First release</Comment>
            <Name>Ayhan Yalçınsoy</Name>
            <Email>ayhanyalcinsoy@pisilinux.org</Email>
        </Update>
    </History>
</PISI>


code:
<?xml version="1.0" ?>
<PISI>
    <Source>
        <Name>valgrind</Name>
        <Summary xml:lang="tr">X86 ve PPC Linux platformları için bellek erişimi hata ayıklayıcı</Summary>
        <Description xml:lang="tr">Valgrind, bu konuda ödül kazanmış Linux için çizge ve hata ayıklama araçları takımıdır. Valgrind ile gelen araçlar yardımıyla, birçok hafıza yönetimi ve iş parçacığı hatalarını otomatik olarak yakalayabilir, boşa geçen hata ayıklama saatlerinizi kazanabilir, programlarınızı daha kararlı bir hale getirebilirsiniz. Ayrıca programlarınızı daha hızlı çalışır yapmak ve kullandıkları hafızayı azaltmak için iş parçacıklarını detaylı olarak inceleyebilirsiniz.</Description>
    </Source>
</PISI>


code:
<PISI>
    <Name>programming.scm</Name>
</PISI>


code:
# -*- coding: utf-8 -*-
#
# Licensed under the GNU General Public License, version 3.
# See the file http://www.gnu.org/licenses/gpl.txt

from pisi.actionsapi import shelltools
from pisi.actionsapi import perlmodules
from pisi.actionsapi import autotools
from pisi.actionsapi import pisitools
from pisi.actionsapi import get

config = """
V                       = 1
CFLAGS                  = %s
LDFLAGS                 = %s
INSTALLDIRS             = vendor
DESTDIR                 = %s
prefix                  = /usr
htmldir                 = /usr/share/doc/git
sysconfdir              = /etc
ETC_GITCONFIG           = /etc/gitconfig
GITWEB_CSS              = gitweb/gitweb.css
GITWEB_LOGO             = gitweb/git-logo.png
GITWEB_FAVICON          = gitweb/git-favicon.png
GITWEB_JS               = gitweb/gitweb.js
PYTHON_PATH             = /usr/bin/python3
PERL_MM_OPT             =""
GIT_TEST_OPTS           ='--no-color'
gitwebdir               = /var/www/localhost/cgi-bin
ASCIIDOC8               = 1
ASCIIDOC_NO_ROFF        = 1
BLK_SHA1                = 1
NEEDS_CRYPTO_WITH_SSL   = 1
USE_LIBPCRE             = 1
NO_CROSS_DIRECTORY_HARDLINKS = 1
MAN_BOLD_LITERAL        = 1
V                       = 1
""" % (get.CFLAGS(), get.LDFLAGS(), get.installDIR())

def setup():
    shelltools.echo("config.mak", config)

def build():
    pisitools.dosed("Makefile", "^CC = .*$", "CC = %s" % get.CC())
    autotools.make("all doc")

def install():
    autotools.rawInstall("install-doc")

    # Install bash completion
    pisitools.insinto("/etc/bash_completion.d", "contrib/completion/git-completion.bash", "git")
    shelltools.chmod("%s/etc/bash_completion.d/git" % get.installDIR(), 0644)

    # for git-daemon
    pisitools.dodir("/pub/scm")

    # emacs support
    #autotools.install("-C contrib/emacs")
    #pisitools.insinto("/usr/share/doc/emacs-git", "contrib/emacs/README")

    # Some docs
    pisitools.dodoc("README.md", "COPYING", "Documentation/SubmittingPatches")

    # remove .pod and .packlist files
    perlmodules.removePodfiles()
    perlmodules.removePacklist()


code:
from comar.service import *

serviceType = "server"
serviceDesc = _({"en": "GIT Server",
                 "tr": "GIT Sunucusu"})
serviceDefault = "off"
serviceConf = "git-daemon"

@synchronized
def start():
    startService(command="/usr/bin/git",
                 args="daemon \
                       --base-path=/pub/scm \
                       --pid-file=/run/git-daemon.pid \
                       --user-path=public_git \
                       --detach \
                       --export-all \
                       --syslog \
                       --verbose %s" % config.get("GITDAEMON_OPTS"),
                 pidfile="/run/git-daemon.pid",
                 donotify=True)

@synchronized
def stop():
    stopService(pidfile="/run/git-daemon.pid",
                donotify=True)

def status():
    return isServiceRunning("/run/git-daemon.pid")


code: (add-to-list 'vc-handled-backends 'GIT)


code:
# Include the current git branch in the prompt

if type __git_ps1 >/dev/null 2>/dev/null; then
  export PS1="$(echo -n "$PS1" | sed "s|\\\W\]|\\\W\$(__git_ps1 \" (%s)\")\]|")"
fi


code:
Index: git-1.7.6.4/gitweb/Makefile
===================================================================
--- git-1.7.6.4.orig/gitweb/Makefile
+++ git-1.7.6.4/gitweb/Makefile
@@ -56,7 +56,7 @@ PERL_PATH  ?= /usr/bin/perl
 # Shell quote;
 bindir_SQ = $(subst ','\'',$(bindir))#'
 gitwebdir_SQ = $(subst ','\'',$(gitwebdir))#'
-gitwebstaticdir_SQ = $(subst ','\'',$(gitwebdir)/static)#'
+gitwebstaticdir_SQ = $(subst ','\'',$(gitwebdir)/gitweb)#'
 SHELL_PATH_SQ = $(subst ','\'',$(SHELL_PATH))#'
 PERL_PATH_SQ  = $(subst ','\'',$(PERL_PATH))#'
 DESTDIR_SQ    = $(subst ','\'',$(DESTDIR))#'


code:
--- git-1.5.0.6/gitweb/gitweb.perl~	2007-03-30 01:37:05.000000000 +0100
+++ git-1.5.0.6/gitweb/gitweb.perl	2007-05-07 08:31:37.000000000 +0100
@@ -39,7 +39,7 @@ our $projectroot = "++GITWEB_PROJECTROOT
 our $home_link = $my_uri || "/";

 # string of the home link on top of all pages
-our $home_link_str = "++GITWEB_HOME_LINK_STR++";
+our $home_link_str = $ENV{'SERVER_NAME'} ? "git://" . $ENV{'SERVER_NAME'} : "projects";

 # name of your site or organization to appear in page titles
 # replace this with something more descriptive for clearer bookmarks


code:
From 09891c65a5f7409ce0bd37daced0ff31fbb1b1c9 Mon Sep 17 00:00:00 2001
From: Todd Zullinger <tmz@pobox.com>
Date: Mon, 23 Mar 2009 00:03:36 -0400
Subject: [PATCH] git-cvsimport: Ignore cvsps-2.2b1 Branches: output

Signed-off-by: Todd Zullinger <tmz@pobox.com>
---
 git-cvsimport.perl |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/git-cvsimport.perl b/git-cvsimport.perl
index e439202..d020f1a 100755
--- a/git-cvsimport.perl
+++ b/git-cvsimport.perl
@@ -952,7 +952,7 @@ while (<CVS>) {
 	} elsif (/^-+$/) { # end of unknown-line processing
 		$state = 1;
 	} elsif ($state != 11) { # ignore stuff when skipping
-		print STDERR "* UNKNOWN LINE * $_\n";
+		print STDERR "* UNKNOWN LINE * $_\n" unless /^Branches: /;
 	}
 }
 commit() if $branch and $state != 11;
--
1.6.2.2


code:
# Meaningful options are:
#   --syslog         --- Enables syslog logging
#   --verbose        --- Enables verbose logging
#   --export-all     --- Exports all repositories even if they don't contain git-daemon-export-ok file
#   --port=XXXX      --- Starts in port XXXX instead of 9418
#   --base-path=/path --- Remap all the path requests as relative to the given path
#
GITDAEMON_OPTS=""


code:
Alias /git /var/www/localhost/cgi-bin

<Directory /var/www/localhost/cgi-bin>
  Options +ExecCGI
  AddHandler cgi-script .cgi
  DirectoryIndex gitweb.cgi
</Directory>


code:
Index: git-1.6.3/gitk-git/gitk
===================================================================
--- git-1.6.3.orig/gitk-git/gitk
+++ git-1.6.3/gitk-git/gitk
@@ -10931,9 +10931,9 @@ if {[tk windowingsystem] eq "aqua"} {
     set textfont {Monaco 9}
     set uifont {{Lucida Grande} 9 bold}
 } else {
-    set mainfont {Helvetica 9}
-    set textfont {Courier 9}
-    set uifont {Helvetica 9 bold}
+    set mainfont {{DejaVu Sans} 9}
+    set textfont {{DejaVu Sans Mono} 9}
+    set uifont {{DejaVu Sans} 9 bold}
 }
 set tabstop 8
 set findmergefiles 0


code:
# Write project root here
PROJECT_ROOT="/usr/local/scm"


code:
--- gitweb/gitweb.perl	2007-04-04 11:40:33.000000000 +0300
+++ gitweb/gitweb.perl	2007-04-08 21:30:31.000000000 +0300
@@ -32,8 +32,14 @@
 our $GIT = "++GIT_BINDIR++/git";

 # absolute fs-path which will be prepended to the project path
-#our $projectroot = "/pub/scm";
-our $projectroot = "++GITWEB_PROJECTROOT++";
+our $projectroot = "/usr/local/scm";
+open(CONF, '/etc/conf.d/gitweb');
+
+while (<CONF>) {
+    do { $projectroot = $1; last } if /^PROJECT_ROOT="([^"]+)"/;
+}
+
+close(CONF);

 # target of the home link on top of all pages
 our $home_link = $my_uri || "/";


code:
<?xml version="1.0" ?>
<!DOCTYPE PISI SYSTEM "http://www.pisilinux.org/projeler/pisi/pisi-spec.dtd">
<PISI>
    <Source>
        <Name>git</Name>
        <Homepage>http://git-scm.com/</Homepage>
        <Packager>
            <Name>PisiLinux Community</Name>
            <Email>admins@pisilinux.org</Email>
        </Packager>
        <License>GPLv2</License>
        Fast Version Control System
        <Description>Git is a fast, scalable, distributed revision control system with an unusually rich command set that provides both high-level operations and full access to internals.</Description>
        <Archive sha1sum="42aafae5c29324b1fee0264a6c804fdffbd1d8d1" type="tarxz">https://www.kernel.org/pub/software/scm/git/git-2.12.0.tar.xz</Archive>
        <BuildDependencies>
            <Dependency>tcltk-devel</Dependency>
            <Dependency>openssl-devel</Dependency>
            <Dependency>libpcre-devel</Dependency>
            <Dependency>curl-devel</Dependency>
            <Dependency>zlib-devel</Dependency>
            <Dependency>expat-devel</Dependency>
            <Dependency>xmlto</Dependency>
            <Dependency>asciidoc</Dependency>
            <Dependency>perl-Error</Dependency>
            <Dependency>perl</Dependency>
            <Dependency>libxslt</Dependency>
            <Dependency>util-linux</Dependency>

        </BuildDependencies>
        <Patches>

        </Patches>
    </Source>

    <Package>
        <Name>git</Name>
        <IsA>app:console</IsA>
        <RuntimeDependencies>
            <Dependency>perl-String-ShellQuote</Dependency>
            <Dependency>perl-Net-SMTP-SSL</Dependency>
            <Dependency>perl-Authen-SASL</Dependency>
            <Dependency>perl-libwww</Dependency>
            <Dependency>libpcre</Dependency>
            <Dependency version="current">perl-Git</Dependency>
            <Dependency>openssh</Dependency>
            <Dependency>openssl</Dependency>
            <Dependency>rsync</Dependency>
            <Dependency>expat</Dependency>
            <Dependency>zlib</Dependency>
            <Dependency>curl</Dependency>
        </RuntimeDependencies>
        <Files>
            <Path fileType="executable">/usr/bin</Path>
            <Path fileType="executable">/usr/libexec/git-core</Path>
            <Path fileType="data">/etc/bash_completion.d</Path>
            <Path fileType="data">/usr/share/git-core</Path>
            <Path fileType="locale">/usr/share/locale</Path>
            <Path fileType="man">/usr/share/man</Path>
            <Path fileType="doc">/usr/share/doc</Path>
        </Files>
    </Package>

    <Package>
        <Name>git-daemon</Name>
        <IsA>service</IsA>
        GIT protocol daemon
        <RuntimeDependencies>
            <Dependency>zlib</Dependency>
            <Dependency>libpcre</Dependency>
            <Dependency version="current">git</Dependency>
        </RuntimeDependencies>
        <Files>
            <Path fileType="config">/etc/conf.d/git-daemon</Path>
            <Path fileType="executable">/usr/libexec/git-core/git-daemon</Path>
            <Path fileType="man">/usr/share/man/man1/*daemon*.1*</Path>
            <Path fileType="data">/pub/scm</Path>
        </Files>
        <AdditionalFiles>
            <AdditionalFile owner="root" permission="0644" target="/etc/conf.d/git-daemon">git-daemon.confd</AdditionalFile>
        </AdditionalFiles>
        <Provides>
            <COMAR script="service.py">System.Service</COMAR>
        </Provides>
    </Package>

    <Package>
        <Name>perl-Git</Name>
        <IsA>library</IsA>
        <PartOf>programming.language.perl</PartOf>
        Perl interface to GIT
        <RuntimeDependencies>
            <Dependency>perl-Error</Dependency>
            <Dependency>perl</Dependency>
        </RuntimeDependencies>
        <Files>
            <Path fileType="library">/usr/lib/perl5</Path>
            <Path fileType="man">/usr/share/man/man3/Git.3pm</Path>
        </Files>
    </Package>

    <Package>
        <Name>gitk</Name>
        <IsA>app:gui</IsA>
        Git revision tree visualiser
        <RuntimeDependencies>
            <Dependency version="current">git</Dependency>
            <Dependency>tcltk</Dependency>
        </RuntimeDependencies>
        <Files>
            <Path fileType="executable">/usr/bin/gitk</Path>
            <Path fileType="localedata">/usr/share/gitk</Path>
            <Path fileType="man">/usr/share/man/man1/*gitk*.1*</Path>
        </Files>
    </Package>

    <Package>
        <Name>git-gui</Name>
        <IsA>app:gui</IsA>
        Git GUI tool
        <RuntimeDependencies>
            <Dependency version="current">git</Dependency>
            <Dependency version="current">gitk</Dependency>
            <Dependency>tcltk</Dependency>
        </RuntimeDependencies>
        <Files>
            <Path fileType="executable">/usr/libexec/git-core/git-gui*</Path>
            <Path fileType="executable">/usr/libexec/git-core/git-citool</Path>
            <Path fileType="data">/usr/share/git-gui</Path>
            <Path fileType="man">/usr/share/man/man1/git-gui.1*</Path>
            <Path fileType="man">/usr/share/man/man1/git-citool.1*</Path>
        </Files>
    </Package>

    <Package>
        <Name>gitweb</Name>
        <IsA>app:web</IsA>
        <PartOf>server.web</PartOf>
        Simple web interface to GIT repositories
        <RuntimeDependencies>
            <Dependency version="current">git</Dependency>
        </RuntimeDependencies>
        <Files>
            <Path fileType="data">/var/www/localhost</Path>
            <Path fileType="config">/etc/conf.d/gitweb</Path>
            <Path fileType="config">/etc/apache2/conf.d</Path>
        </Files>
        <AdditionalFiles>
            <AdditionalFile owner="root" permission="0644" target="/etc/conf.d/gitweb">gitweb.confd</AdditionalFile>
            <AdditionalFile owner="root" permission="0644" target="/etc/apache2/conf.d/git.conf">git.conf.httpd</AdditionalFile>
        </AdditionalFiles>
    </Package>

    <History>
        <Update release="4">
            <Date>2017-03-19</Date>
            <Version>2.12.0</Version>
            <Comment>Version bump.</Comment>
            <Name>Alihan Öztürk</Name>
            <Email>alihan@pisilnux.org</Email>
        </Update>
        <Update release="3">
            <Date>2016-11-12</Date>
            <Version>2.10.2</Version>
            <Comment>Version bump.</Comment>
            <Name>Yusuf Aydemir</Name>
            <Email>yusuf.aydemir@pisilnux.org</Email>
        </Update>
        <Update release="2">
            <Date>2016-06-09</Date>
            <Version>2.7.2</Version>
            <Comment>Release Bump</Comment>
            <Name>Pisi Linux Community</Name>
            <Email>admin@pisilinux.org</Email>
        </Update>
        <Update release="1">
            <Date>2016-02-26</Date>
            <Version>2.7.2</Version>
            <Comment>First release</Comment>
            <Name>Ertuğrul Erata</Name>
            <Email>ertugrulerata@gmail.com</Email>
        </Update>
    </History>
</PISI>


code:
<?xml version="1.0" ?>
<PISI>
    <Source>
        <Name>git</Name>
        <Description xml:lang="tr">Git hızlı, ölçeklenebilir ve dağıtılmış, ve sık rastlanmayan zengin komut kümesi içeren, hem yüksek seviyeli işlemleri hem dahili işlemlere tam erişimi sağlayan bir sürüm kontrol sistemidir.</Description>
        Hızlı Sürüm Denetim Sistemi
        <Description xml:lang="es">GIT es un sistema rápido, escalable y distribuido de control de versiones con un amplio espectro de comandos que permite operaciones de alto nivel tanto como operaciones con acceso a detalles internos.</Description>
    </Source>

    <Package>
        <Name>git-emacs</Name>
        emacs için GIT bütünleşmesi
    </Package>

    <Package>
        <Name>git-daemon</Name>
        GIT protokolü hizmeti
    </Package>

    <Package>
        <Name>perl-Git</Name>
        GIT için perl arayüzü
    </Package>

    <Package>
        <Name>emacs-Git</Name>
        Emacs için git desteği
    </Package>

    <Package>
        <Name>git-svn</Name>
        Subversion depolarıyla etkileşmek için gerekli Git araçları
    </Package>

    <Package>
        <Name>git-cvs</Name>
        CVS depolarıyla etkileşmek için gerekli Git araçları
    </Package>

    <Package>
        <Name>gitk</Name>
        Git sürüm ağacı görüntüleyici
    </Package>

    <Package>
        <Name>git-gui</Name>
        GIT için basit bir grafik arayüz
    </Package>

    <Package>
        <Name>gitweb</Name>
        GIT için Web arayüzü
        interfaz web para GIT
    </Package>
</PISI>


code:
#!/usr/bin/python
# -*- coding: utf-8 -*-
#
# Copyright 2015 TUBITAK/UEKAE
# Licensed under the GNU General Public License, version 2.
# See the file http://www.gnu.org/copyleft/gpl.txt.

from pisi.actionsapi import autotools
from pisi.actionsapi import pisitools
from pisi.actionsapi import cmaketools
from pisi.actionsapi import get

def setup():
    cmaketools.configure()

def build():
    cmaketools.make()

def install():
    cmaketools.rawInstall("DESTDIR=%s" % get.installDIR())

    #pisitools.dodoc("AUTHORS", "ChangeLog", "README*", "NEWS")


code:
<?xml version="1.0" ?>
<!DOCTYPE PISI SYSTEM "http://www.pardus.org.tr/projeler/pisi/pisi-spec.dtd">
<PISI>
    <Source>
        <Name>libgit2</Name>
        <Homepage>https://libgit2.github.com</Homepage>
        <Packager>
            <Name>Ertuğrul Erata</Name>
            <Email>ertugrulerata@gmail.com</Email>
        </Packager>
        <License>GPLv2</License>
        <Icon>libgit2</Icon>
        <IsA>app:gui</IsA>
        <Summary>A linkable library for Git</Summary>
        <Description>A plain C library to interface with the git version control system</Description>
        <Archive sha1sum="c65238d0e0a698b202a3a886d003228cac6dacc3" type="targz">https://github.com/libgit2/libgit2/archive/v0.25.1.tar.gz</Archive>
        <BuildDependencies>
            <Dependency>zlib-devel</Dependency>
            <Dependency>openssl-devel</Dependency>
            <Dependency>python</Dependency>
            <Dependency>cmake</Dependency>
        </BuildDependencies>
        <Patches>
            <!--
            <Patch level="1"></Patch>
            -->
        </Patches>
    </Source>

    <Package>
        <Name>libgit2</Name>
        <RuntimeDependencies>
            <Dependency>zlib</Dependency>
            <Dependency>openssl</Dependency>
        </RuntimeDependencies>
        <Files>
            <Path fileType="library">/usr/lib</Path>
        </Files>
    </Package>

    <Package>
        <Name>libgit2-devel</Name>
        <RuntimeDependencies>
            <Dependency release="current">libgit2</Dependency>
            <Dependency>zlib</Dependency>
            <Dependency>openssl</Dependency>
        </RuntimeDependencies>
        <Files>
            <Path fileType="library">/usr/lib/pkgconfig</Path>
	    <Path fileType="header">/usr/include</Path>
        </Files>
    </Package>

    <History>
        <Update release="3">
            <Date>2017-03-02</Date>
            <Version>0.25.1</Version>
            <Comment>Version Bump</Comment>
            <Name>Pisi Linux Community</Name>
            <Email>admin@pisilinux.org</Email>
        </Update>
        <Update release="2">
            <Date>2016-06-09</Date>
            <Version>0.23.0</Version>
            <Comment>Release Bump</Comment>
            <Name>Pisi Linux Community</Name>
            <Email>admin@pisilinux.org</Email>
        </Update>
        <Update release="1">
            <Date>2015-08-01</Date>
            <Version>0.23.0</Version>
            <Comment>First release</Comment>
            <Name>Ertuğrul Erata</Name>
            <Email>ertugrulerata@gmail.com</Email>
        </Update>
    </History>
</PISI>


code:
<?xml version="1.0" ?>
<PISI>
    <Source>
        <Name>libgit2</Name>
        <Summary xml:lang="">git c dili kütüphanesi</Summary>
        <Description xml:lang="">git için c kütüphanesi</Description>
    </Source>
</PISI>


code:
#!/usr/bin/python
# -*- coding: utf-8 -*-
#
# Licensed under the GNU General Public License, version 3.
# See the file http://www.gnu.org/licenses/gpl.txt

from pisi.actionsapi import pisitools
from pisi.actionsapi import pythonmodules

def setup():
    pythonmodules.compile()

def install():
    pythonmodules.install()

    pisitools.dodir("/etc/bash_completion.d")
    pisitools.insinto("/etc/bash_completion.d", "contrib/bash_completion", "mercurial")

    pisitools.doman("doc/*.1")
    pisitools.doman("doc/*.5")

    pisitools.dohtml("doc/*.html")
    #pisitools.dodoc("doc/*.txt")


code:
<?xml version="1.0" ?>
<!DOCTYPE PISI SYSTEM "http://www.pisilinux.org/projeler/pisi/pisi-spec.dtd">
<PISI>
    <Source>
        <Name>mercurial</Name>
        <Homepage>http://www.selenic.com/mercurial</Homepage>
        <Packager>
            <Name>PisiLinux Community</Name>
            <Email>admins@pisilinux.org</Email>
        </Packager>
        <License>GPLv2</License>
        <IsA>app:console</IsA>
        <Summary>A distributed SCM tool</Summary>
        <Description>A fast, lightweight Source Control Management system designed for efficient handling of very large distributed projects.</Description>
        <Archive sha1sum="bcfd5c28e873855a87d6ad9ccbde36bd4ecd2c55" type="targz">https://www.mercurial-scm.org/release/mercurial-4.1.1.tar.gz</Archive>
        <BuildDependencies>
            <Dependency>python-devel</Dependency>
        </BuildDependencies>
    </Source>

    <Package>
        <Name>mercurial</Name>
        <RuntimeDependencies>
            <Dependency>python</Dependency>
        </RuntimeDependencies>
        <Files>
            <Path fileType="executable">/usr/bin</Path>
            <Path fileType="data">/etc/bash_completion.d</Path>
            <Path fileType="library">/usr/lib</Path>
            <Path fileType="doc">/usr/share/doc</Path>
            <Path fileType="man">/usr/share/man</Path>
        </Files>
    </Package>

    <History>
        <Update release="3">
            <Date>2017-03-19</Date>
            <Version>4.1.1</Version>
            <Comment>Version Bump</Comment>
            <Name>Pisi Linux Community</Name>
            <Email>admin@pisilinux.org</Email>
            <Comment>Version bump.</Comment>
            <Name>Ertuğrul Erata</Name>
            <Email>ertugrulerata@gmail.com</Email>
        </Update>
        <Update release="2">
            <Date>2016-06-09</Date>
            <Version>3.8.3</Version>
            <Comment>Version Bump</Comment>
            <Name>Pisi Linux Community</Name>
            <Email>admin@pisilinux.org</Email>
        </Update>
        <Update release="1">
            <Date>2015-04-04</Date>
            <Version>3.3.3</Version>
            <Comment>First release</Comment>
            <Name>Yusuf Aydemir</Name>
            <Email>yusuf.aydemir@pisilinux.org</Email>
        </Update>
    </History>
</PISI>


code:
<?xml version="1.0" ?>
<PISI>
    <Source>
        <Name>mercurial</Name>
        <Summary xml:lang="tr">Dağıtık bir kaynak kod yönetim aracı</Summary>
        <Description xml:lang="tr">Çok büyük dağıtık projelerin verimli bir şekilde idare edilmesi amacıyla geliştirilmiş hızlı, hafif bir kaynak kod kontrol yönetimi sistemi</Description>
        <Description xml:lang="fr">Système de gestion de code source, rapide et léger conçu pour gérer de manière efficace les projets distribués de très grande taille.</Description>
        <Description xml:lang="es">Un sistema rápido y liviano de administración de fuentes (Source Control Management) diseñado para manejo eficaz de proyectos muy largos y distribuidos.</Description>
    </Source>
</PISI>


code:
#!/usr/bin/python
# -*- coding: utf-8 -*-
#
# Licensed under the GNU General Public License, version 3.
# See the file http://www.gnu.org/licenses/gpl.txt

from pisi.actionsapi import get
from pisi.actionsapi import autotools
from pisi.actionsapi import pisitools
from pisi.actionsapi import shelltools
from pisi.actionsapi import perlmodules

def setup():
    # Respect the user LDFLAGS
    shelltools.system("./autogen.sh")

    shelltools.export("EXTRA_LDFLAGS", get.LDFLAGS())

    autotools.configure("--disable-static \
                         --with-jdk=/usr/lib/jvm/java-7-openjdk \
                         --enable-javahl \
                         --with-apr=/usr \
                         --with-apr-util=/usr \
                         --with-apache=/usr/lib/apache2/ \
                         --with-apxs \
                         --with-serf=/usr \
                         --with-sqlite=/usr \
                         --with-zlib=/usr \
                         --with-jikes=no \
                         --without-berkeley-db \
                         --disable-mod-activation")

    pisitools.dosed("libtool"," -shared ", " -Wl,--as-needed -shared ")

def build():
    # svn
    autotools.make()

    # python bindings
    autotools.make("swig-py")

    # perl bindings (needed by git-svn*)
    # Sometimes parallel build breaks perl bindings
    autotools.make("-j1 swig-pl")

    # java bindings
    autotools.make("-j1 javahl")

def install():
    # install svn
    autotools.rawInstall("DESTDIR=%s" % get.installDIR())

    # install swig-py
    autotools.rawInstall("DESTDIR=%s" % get.installDIR(), "install-swig-py")

    # install swig-pl
    autotools.rawInstall("DESTDIR=%s" % get.installDIR(), "install-swig-pl")

    # install javahl
    autotools.rawInstall("DESTDIR=%s" % get.installDIR(), "install-javahl")

    # Move py/c'into proper dir
    pisitools.domove("/usr/lib/svn-python/svn", "/usr/lib/%s/site-packages" % get.curPYTHON())
    pisitools.domove("/usr/lib/svn-python/libsvn", "/usr/lib/%s/site-packages" % get.curPYTHON())
    pisitools.removeDir("/usr/lib/svn-python")

    # some helper tools
    pisitools.insinto("/usr/bin", "tools/backup/hot-backup.py", "svn-hot-backup")
    # FIXME: these tools are replaced by new ones
    # pisitools.insinto("/usr/bin", "contrib/client-side/svn_load_dirs.pl", "svn-load-dirs")
    # pisitools.insinto("/usr/bin", "contrib/client-side/svnmerge.py", "svnmerge")
    # shelltools.chmod("%s/usr/bin/svnmerge" % get.installDIR(), 0755)

    # Install upstream bash completion script
    pisitools.insinto("/etc/bash_completion.d", "tools/client-side/bash_completion", "subversion")

    # Documentation and etc.
    #pisitools.insinto("/usr/share/doc/%s" % get.srcNAME(), "contrib")
    pisitools.insinto("/usr/share/doc/%s" % get.srcNAME(), "tools/xslt")
    pisitools.insinto("/var/www/localhost/htdocs", "tools/xslt/*")

    # Create virtual repository root
    pisitools.dodir("/var/svn")

    pisitools.dodoc("README")

    # remove unnecessary files i.e. perllocal.pod, .packlist
    perlmodules.removePacklist()
    perlmodules.removePodfiles()


code:
#!/usr/bin/python

import os

def postInstall(fromVersion, fromRelease, toVersion, toRelease):
    os.system("/bin/mkdir -p /var/svn/conf")
    os.system("/usr/bin/svnadmin create /var/svn/repos")

    os.system("/bin/chmod -R 774 /var/svn/repos")
    os.system("/bin/chmod 775 /var/svn/repos")

    os.system("/bin/chown -R svn:svn /var/svn")


code:
from comar.service import *

serviceType = "server"
serviceDesc = _({"en": "SVN Server",
                 "tr": "SVN Sunucusu"})
serviceConf = "svnserve"

PIDFILE = "/var/svn/svnserve.pid"

# Note that "/etc/conf.d/svnserve" passes --root=/var/svn by default

@synchronized
def start():
    startService(command="/usr/bin/svnserve",
                 args="--pid-file=%s %s" % (PIDFILE, config.get("SVNSERVE_OPTS")),
                 chuid="%s:%s" % (config.get("SVNSERVE_USER"), config.get("SVNSERVE_GROUP")),
                 donotify=True)

@synchronized
def stop():
    stopService(pidfile=PIDFILE,
                donotify=True)

def status():
    return isServiceRunning(pidfile=PIDFILE)


code:
LoadModule dav_module         modules/mod_dav.so
LoadModule dav_svn_module     modules/mod_dav_svn.so
LoadModule authz_svn_module   modules/mod_authz_svn.so

# To serve all repositories under SVNParentPath with same configuration
<Location /svn>
DAV svn
SVNParentPath /var/svn/repos
SVNIndexXSLT "/svnindex.xsl"
#AuthType Basic
#AuthName "Subversion repository"
#AuthUserFile /var/svn/conf/svnusers_default
#Require valid-user
</Location>

#
# Example configuration to enable HTTP access for a directory
# containing Subversion repositories, "/var/www/svn".  Each repository
# must be both:
#
#   a) readable and writable by the 'apache' user, and
#
#   b) labelled with the 'httpd_sys_content_t' context if using
#   SELinux
#

#
# To create a new repository "http://localhost/repos/stuff" using
# this configuration, run as root:
#
#   # cd /var/www/svn
#   # svnadmin create stuff
#   # chown -R apache.apache stuff
#   # chcon -R -t httpd_sys_content_t stuff
#

#<Location /repos>
#   DAV svn
#   SVNParentPath /var/www/svn
#
#   # Limit write permission to list of valid users.
#   <LimitExcept GET PROPFIND OPTIONS REPORT>
#      # Require SSL connection for password protection.
#      # SSLRequireSSL
#
#      AuthType Basic
#      AuthName "Authorization Realm"
#      AuthUserFile /path/to/passwdfile
#      Require valid-user
#   </LimitExcept>
#</Location>


code:
diff -ur subversion-1.4.0.orig/Makefile.in subversion-1.4.0/Makefile.in
--- subversion-1.4.0.orig/Makefile.in	2006-11-06 16:36:17.000000000 +0200
+++ subversion-1.4.0/Makefile.in	2006-11-06 16:50:14.000000000 +0200
@@ -209,10 +209,6 @@
       $(INSTALL_DATA) "$$i" $(DESTDIR)$(swig_pydir); \
     done; \
   fi; \
-  $(PYTHON) -c 'import compileall; \
-    compileall.compile_dir("$(DESTDIR)$(swig_pydir)", 1, "$(swig_pydir)"); \
-    compileall.compile_dir("$(DESTDIR)$(swig_pydir_extra)", 1, \
-    "$(swig_pydir_extra)");'

 # The path to generated and complementary source files for the SWIG
 # bindings.


code:
The first half of this is certainly upstream-worthy, but the second half is presumably
some Fedora-specific KDE packaging thing.  It's not obvious how to get
kde4-config to report the directory which contains the .so files.

--- subversion-1.8.0/build/ac-macros/kwallet.m4.kwallet
+++ subversion-1.8.0/build/ac-macros/kwallet.m4
@@ -63,15 +63,15 @@ AC_DEFUN(SVN_LIB_KWALLET,
                   fi
                 done
                 qt_include_dirs="`$PKG_CONFIG --cflags-only-I QtCore QtDBus QtGui`"
-                kde_dir="`$KDE4_CONFIG --prefix`"
-                SVN_KWALLET_INCLUDES="$DBUS_CPPFLAGS $qt_include_dirs -I$kde_dir/include"
+                kde_include_dirs="-I`$KDE4_CONFIG --path include`"
+                SVN_KWALLET_INCLUDES="$DBUS_CPPFLAGS $qt_include_dirs $kde_include_dirs"
                 qt_libs_other_options="`$PKG_CONFIG --libs-only-other QtCore QtDBus QtGui`"
                 SVN_KWALLET_LIBS="$DBUS_LIBS -lQtCore -lQtDBus -lQtGui -lkdecore -lkdeui $qt_libs_other_options"
                 CXXFLAGS="$CXXFLAGS $SVN_KWALLET_INCLUDES"
                 LIBS="$LIBS $SVN_KWALLET_LIBS"
                 qt_lib_dirs="`$PKG_CONFIG --libs-only-L QtCore QtDBus QtGui`"
                 kde_lib_suffix="`$KDE4_CONFIG --libsuffix`"
-                LDFLAGS="$old_LDFLAGS `SVN_REMOVE_STANDARD_LIB_DIRS($qt_lib_dirs -L$kde_dir/lib$kde_lib_suffix)`"
+                LDFLAGS="$old_LDFLAGS `SVN_REMOVE_STANDARD_LIB_DIRS($qt_lib_dirs)` -L$libdir/kde4/devel"
                 AC_LANG(C++)
                 AC_LINK_IFELSE([AC_LANG_SOURCE([[
 #include <kwallet.h>


code:
diff -uap subversion-1.7.0/build/generator/gen_base.py.pie subversion-1.7.0/build/generator/gen_base.py
--- subversion-1.8.0/build/generator/gen_base.py.pie
+++ subversion-1.8.0/build/generator/gen_base.py
@@ -409,7 +409,7 @@ class TargetLinked(Target):
     self.install = options.get('install')
     self.compile_cmd = options.get('compile-cmd')
     self.sources = options.get('sources', '*.c *.cpp')
-    self.link_cmd = options.get('link-cmd', '$(LINK)')
+    self.link_cmd = options.get('link-cmd', '$(LINK_LIB)')

     self.external_lib = options.get('external-lib')
     self.external_project = options.get('external-project')
@@ -465,6 +465,11 @@ class TargetExe(TargetLinked):
     self.manpages = options.get('manpages', '')
     self.testing = options.get('testing')

+    if self.install == 'test' or self.install == 'bdb-test':
+      self.link_cmd = '$(LINK_TEST)'
+    else:
+      self.link_cmd = '$(LINK_EXE)'
+
   def add_dependencies(self):
     TargetLinked.add_dependencies(self)

@@ -515,8 +520,8 @@ class TargetLib(TargetLinked):
     self.msvc_export = options.get('msvc-export', '').split()

     ### hmm. this is Makefile-specific
-    if self.link_cmd == '$(LINK)':
-      self.link_cmd = '$(LINK_LIB)'
+    if self.install == 'test':
+       self.link_cmd = '$(LINK_TEST_LIB)'

 class TargetApacheMod(TargetLib):

--- subversion-1.8.0/Makefile.in.pie
+++ subversion-1.8.0/Makefile.in
@@ -203,6 +203,9 @@ COMPILE_CXXHL_CXX = $(LIBTOOL) $(LTCXXFL

 LINK = $(LIBTOOL) $(LTFLAGS) --mode=link $(CC) $(LT_LDFLAGS) $(CFLAGS) $(LDFLAGS)
 LINK_LIB = $(LINK) $(LT_SO_VERSION) -rpath $(libdir)
+LINK_TEST = $(LINK) -no-install
+LINK_TEST_LIB = $(LINK) -avoid-version
+LINK_EXE = $(LINK) -pie
 LINK_CXX = $(LIBTOOL) $(LTCXXFLAGS) --mode=link $(CXX) $(LT_LDFLAGS) $(CXXFLAGS) $(LDFLAGS) -rpath $(libdir)
 LINK_CXX_LIB = $(LINK_CXX) $(LT_SO_VERSION)

@@ -676,7 +679,7 @@ schema-clean:
 	$(PYTHON) $(top_srcdir)/build/transform_sql.py $< $(top_srcdir)/$@

 .c.o:
-	$(COMPILE) -o $@ -c $<
+	$(COMPILE) -fpie -o $@ -c $<

 .cpp.o:
 	$(COMPILE_CXX) -o $@ -c $<


code:
diff -uap subversion-1.7.0/build.conf.rpath subversion-1.7.0/build.conf
--- subversion-1.8.0/build.conf.rpath
+++ subversion-1.8.0/build.conf
@@ -501,7 +501,7 @@ type = swig_lib
 lang = python
 path = subversion/bindings/swig/python/libsvn_swig_py
 libs = libsvn_client libsvn_wc libsvn_ra libsvn_delta libsvn_subr apriconv apr
-link-cmd = $(LINK)
+link-cmd = $(LINK_LIB)
 install = swig-py-lib
 # need special build rule to include -DSWIGPYTHON
 compile-cmd = $(COMPILE_SWIG_PY)
@@ -524,7 +524,7 @@ type = swig_lib
 lang = ruby
 path = subversion/bindings/swig/ruby/libsvn_swig_ruby
 libs = libsvn_client libsvn_wc libsvn_delta libsvn_subr apriconv apr
-link-cmd = $(LINK) $(SWIG_RB_LIBS)
+link-cmd = $(LINK_LIB) $(SWIG_RB_LIBS)
 install = swig-rb-lib
 # need special build rule to include
 compile-cmd = $(COMPILE_SWIG_RB)
--- subversion-1.8.0/build/generator/gen_base.py.rpath
+++ subversion-1.8.0/build/generator/gen_base.py
@@ -514,6 +514,10 @@ class TargetLib(TargetLinked):
     self.msvc_fake = options.get('msvc-fake') == 'yes' # has fake target
     self.msvc_export = options.get('msvc-export', '').split()

+    ### hmm. this is Makefile-specific
+    if self.link_cmd == '$(LINK)':
+      self.link_cmd = '$(LINK_LIB)'
+
 class TargetApacheMod(TargetLib):

   def __init__(self, name, options, gen_obj):
--- subversion-1.8.0/Makefile.in.rpath
+++ subversion-1.8.0/Makefile.in
@@ -201,8 +201,8 @@ COMPILE_JAVAHL_JAVAH = $(JAVAH)
 # special compilation for files destined for cxxhl
 COMPILE_CXXHL_CXX = $(LIBTOOL) $(LTCXXFLAGS) --mode=compile $(COMPILE_CXX) $(LT_CFLAGS) $(CXXHL_INCLUDES) -o $@ -c

-LINK = $(LIBTOOL) $(LTFLAGS) --mode=link $(CC) $(LT_LDFLAGS) $(CFLAGS) $(LDFLAGS) -rpath $(libdir)
-LINK_LIB = $(LINK) $(LT_SO_VERSION)
+LINK = $(LIBTOOL) $(LTFLAGS) --mode=link $(CC) $(LT_LDFLAGS) $(CFLAGS) $(LDFLAGS)
+LINK_LIB = $(LINK) $(LT_SO_VERSION) -rpath $(libdir)
 LINK_CXX = $(LIBTOOL) $(LTCXXFLAGS) --mode=link $(CXX) $(LT_LDFLAGS) $(CXXFLAGS) $(LDFLAGS) -rpath $(libdir)
 LINK_CXX_LIB = $(LINK_CXX) $(LT_SO_VERSION)


code:
 Makefile.in |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/Makefile.in
+++ b/Makefile.in
@@ -652,7 +652,7 @@ check-swig-pl: swig-pl swig-pl-lib
 	cd $(SWIG_PL_DIR)/native; $(MAKE) test

 install-swig-pl: swig-pl install-swig-pl-lib
-	cd $(SWIG_PL_DIR)/native; $(MAKE) install
+	cd $(SWIG_PL_DIR)/native; $(MAKE) install_vendor

 EXTRACLEAN_SWIG_PL=rm -f $(SWIG_PL_SRC_DIR)/native/svn_*.c \
                          $(SWIG_PL_SRC_DIR)/native/core.c


code:
[miscellany]
enable-auto-props = yes

[auto-props]
*.png = svn:mime-type=image/png
*.jpg = svn:mime-type=image/jpeg
*.jpe = svn:mime-type=image/jpeg
*.jpeg = svn:mime-type=image/jpeg
*.bmp = svn:mime-type=image/x-ms-bmp
*.odp = svn:mime-type=application/vnd.oasis.opendocument.presentation
*.odt = svn:mime-type=application/vnd.oasis.opendocument.text
*.ods = svn:mime-type=application/vnd.oasis.opendocument.spreadsheet
*.ogg = svn:mime-type=audio/ogg


code:
clear LD_RUN_PATH, it will end up as RPATH in ELF binaries

ERROR: RPATH "/usr/src/packages/BUILD/subversion-1.5.x/subversion/libsvn_subr/.libs" on /var/tmp/subversion-1.5.0-build/usr/lib/perl5/vendor_perl/5.10.0/ppc-linux-thread-multi-64int/auto/SVN/_Wc/_Wc.so is not allowed

---
 Makefile.in |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/Makefile.in
+++ b/Makefile.in
@@ -641,7 +641,7 @@ $(SWIG_PL_DIR)/native/Makefile.PL: $(SWI
 	./config.status subversion/bindings/swig/perl/native/Makefile.PL

 $(SWIG_PL_DIR)/native/Makefile: $(SWIG_PL_DIR)/native/Makefile.PL
-	cd $(SWIG_PL_DIR)/native; $(PERL) Makefile.PL
+	cd $(SWIG_PL_DIR)/native; $(PERL) Makefile.PL ; for i in `grep -wl ^LD_RUN_PATH Makefile Makefile.[^P]*` ; do sed -i 's@^LD_RUN_PATH.*@LD_RUN_PATH=@' $$i ; done

 swig-pl_DEPS = autogen-swig-pl libsvn_swig_perl \
   $(SWIG_PL_DIR)/native/Makefile


code:
--- Makefile.in.orig	2009-02-16 14:10:48.000000000 -0200
+++ Makefile.in	2009-06-04 00:56:29.000000000 -0300
@@ -678,6 +678,7 @@

 $(SWIG_PL_DIR)/native/Makefile: $(SWIG_PL_DIR)/native/Makefile.PL
 	cd $(SWIG_PL_DIR)/native; $(PERL) Makefile.PL PREFIX=$(prefix)
+	cd $(SWIG_PL_DIR)/native; sed -i 's|LD_RUN_PATH|DIE_RPATH_DIE|g' Makefile{,.{client,delta,fs,ra,repos,wc}}

 # There is a "readlink -f" command on some systems for the same purpose,
 # but it's not as portable (e.g. Mac OS X doesn't have it).  These should
 # only be used where Python/Perl are known to be available.