Changeset 26141

05/18/10 15:18:22 (7 years ago)

New methods: new_valist, new_with_constraints.

4 edited


  • branches/ratatoskr/midgard/core/midgard/INSTALL

    r24458 r26141  
    552006, 2007, 2008, 2009 Free Software Foundation, Inc.
    7    This file is free documentation; the Free Software Foundation gives
    8 unlimited permission to copy, distribute and modify it.
     7   Copying and distribution of this file, with or without modification,
     8are permitted in any medium without royalty provided the copyright
     9notice and this notice are preserved.  This file is offered as-is,
     10without warranty of any kind.
    1012Basic Installation
    1416configure, build, and install this package.  The following
    1517more-detailed instructions are generic; see the `README' file for
    16 instructions specific to this package.
     18instructions specific to this package.  Some packages provide this
     19`INSTALL' file but do not implement all of the features documented
     20below.  The lack of an optional feature in a given package is not
     21necessarily a bug.  More recommendations for GNU packages can be found
     22in *note Makefile Conventions: (standards)Makefile Conventions.
    1824   The `configure' shell script attempts to guess correct values for
    4349of `autoconf'.
    45 The simplest way to compile this package is:
     51   The simplest way to compile this package is:
    4753  1. `cd' to the directory containing the package's source code and type
    5561  3. Optionally, type `make check' to run any self-tests that come with
    56      the package.
     62     the package, generally using the just-built uninstalled binaries.
    5864  4. Type `make install' to install the programs and any data files and
    59      documentation.
    61   5. You can remove the program binaries and object files from the
     65     documentation.  When installing into a prefix owned by root, it is
     66     recommended that the package be configured and built as a regular
     67     user, and only the `make install' phase executed with root
     68     privileges.
     70  5. Optionally, type `make installcheck' to repeat any self-tests, but
     71     this time using the binaries in their final installed location.
     72     This target does not install anything.  Running this target as a
     73     regular user, particularly if the prior `make install' required
     74     root privileges, verifies that the installation completed
     75     correctly.
     77  6. You can remove the program binaries and object files from the
    6278     source code directory by typing `make clean'.  To also remove the
    6379     files that `configure' created (so you can compile the package for
    6884     with the distribution.
    70   6. Often, you can also type `make uninstall' to remove the installed
    71      files again.
     86  7. Often, you can also type `make uninstall' to remove the installed
     87     files again.  In practice, not all packages have tested that
     88     uninstallation works correctly, even though it is required by the
     89     GNU Coding Standards.
     91  8. Some packages, particularly those that use Automake, provide `make
     92     distcheck', which can by used by developers to test that all other
     93     targets like `make install' and `make uninstall' work correctly.
     94     This target is generally not run by end users.
    7396Compilers and Options
    94117directory where you want the object files and executables to go and run
    95118the `configure' script.  `configure' automatically checks for the
    96 source code in the directory that `configure' is in and in `..'.
     119source code in the directory that `configure' is in and in `..'.  This
     120is known as a "VPATH" build.
    98122   With a non-GNU `make', it is safer to compile the package for one
    121145`/usr/local/bin', include files under `/usr/local/include', etc.  You
    122146can specify an installation prefix other than `/usr/local' by giving
    123 `configure' the option `--prefix=PREFIX'.
     147`configure' the option `--prefix=PREFIX', where PREFIX must be an
     148absolute file name.
    125150   You can specify separate installation prefixes for
    132157options like `--bindir=DIR' to specify different values for particular
    133158kinds of files.  Run `configure --help' for a list of the directories
    134 you can set and what kinds of files go in them.
     159you can set and what kinds of files go in them.  In general, the
     160default for these options is expressed in terms of `${prefix}', so that
     161specifying just `--prefix' will affect all of the other directory
     162specifications that were not explicitly provided.
     164   The most portable way to affect installation locations is to pass the
     165correct locations to `configure'; however, many packages provide one or
     166both of the following shortcuts of passing variable assignments to the
     167`make install' command line to change installation locations without
     168having to reconfigure or recompile.
     170   The first method involves providing an override variable for each
     171affected directory.  For example, `make install
     172prefix=/alternate/directory' will choose an alternate location for all
     173directory configuration variables that were expressed in terms of
     174`${prefix}'.  Any directories that were specified during `configure',
     175but not in terms of `${prefix}', must each be overridden at install
     176time for the entire installation to be relocated.  The approach of
     177makefile variable overrides for each directory variable is required by
     178the GNU Coding Standards, and ideally causes no recompilation.
     179However, some platforms have known limitations with the semantics of
     180shared libraries that end up requiring recompilation when using this
     181method, particularly noticeable in packages that use GNU Libtool.
     183   The second method involves providing the `DESTDIR' variable.  For
     184example, `make install DESTDIR=/alternate/directory' will prepend
     185`/alternate/directory' before all installation names.  The approach of
     186`DESTDIR' overrides is not required by the GNU Coding Standards, and
     187does not work on platforms that have drive letters.  On the other hand,
     188it does better at avoiding recompilation issues, and works well even
     189when some directory options were not specified in terms of `${prefix}'
     190at `configure' time.
     192Optional Features
    136195   If the package supports it, you can cause programs to be installed
    137196with an extra prefix or suffix on their names by giving `configure' the
    138197option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
    140 Optional Features
    141 =================
    143199   Some packages pay attention to `--enable-FEATURE' options to
    152208you can use the `configure' options `--x-includes=DIR' and
    153209`--x-libraries=DIR' to specify their locations.
     211   Some packages offer the ability to configure how verbose the
     212execution of `make' will be.  For these packages, running `./configure
     213--enable-silent-rules' sets the default to minimal output, which can be
     214overridden with `make V=1'; while running `./configure
     215--disable-silent-rules' sets the default to verbose, which can be
     216overridden with `make V=0'.
    155218Particular systems
    291      Use DIR as the installation prefix.  *Note Installation Names::
     354     Use DIR as the installation prefix.  *note Installation Names::
    292355     for more details, including other options available for fine-tuning
    293356     the installation locations.
  • branches/ratatoskr/midgard/core/midgard/doc/C/midgard-2.0-sections.txt

    r26133 r26141  
    596599<SUBSECTION Standard>
  • branches/ratatoskr/midgard/core/midgard/src/midgard_query_constraint_group.c

    r25919 r26141  
    3434 * midgard_query_constraint_group_new:
     35 *
     36 * Create new #MidgardQueryConstraintGroup instance with default "AND" group type.
     37 *
     38 * Returns: #MidgardQueryConstraintGroup instance or %NULL
     39 *
     40 * Since: 10.05.1
     41 */
     42MidgardQueryConstraintGroup *
     43midgard_query_constraint_group_new (void)
     45        return midgard_query_constraint_group_new_valist ("AND", NULL);
     49 * midgard_query_constraint_group_new_with_constraints:
     50 * @type: constraints group type
     51 * @constraints: an array of #MidgardQueryConstraintSimple constraints
     52 * @n_constraints: the length of given constraints array
     53 *
     54 * Returns: #MidgardQueryConstraintGroup instance or %NULL
     55 *
     56 * Since: 10.05.1
     57 */
     58MidgardQueryConstraintGroup *
     59midgard_query_constraint_group_new_with_constraints (const gchar *type, MidgardQueryConstraintSimple **constraints, guint n_constraints)
     61        g_return_val_if_fail (type != NULL, NULL);
     62        g_return_val_if_fail (constraints != NULL, NULL);
     64        MidgardQueryConstraintGroup *self = midgard_query_constraint_group_new_valist (type, NULL);
     65        if (!self)
     66                return NULL;
     68        if (n_constraints == 0)
     69                return self;
     71        guint i;
     72        for (i = 0; i < n_constraints; i++) {
     73                midgard_query_constraint_group_add_constraint (self, constraints[i], NULL);
     74        }
     76        return self;
     80 * midgard_query_constraint_group_new_valist:
    3581 * @type: constraints group type ('OR' or 'AND')
    3682 * @constraint: list of constraints to add to group or NULL
     83 *
     84 * This is C convinient function. It's not designed for language bindings.
    3785 *
    3886 * Returns: #MidgardQueryConstraintGroup instance or %NULL
    3987 *
    40  * Since: 10.05
     88 * Since: 10.05.1
    4189 */
    4290MidgardQueryConstraintGroup *
    43 midgard_query_constraint_group_new (const gchar *type, MidgardQueryConstraintSimple *constraint, ...)
     91midgard_query_constraint_group_new_valist (const gchar *type, MidgardQueryConstraintSimple *constraint, ...)
    4593        g_return_val_if_fail (type != NULL, NULL);
  • branches/ratatoskr/midgard/core/midgard/src/midgard_query_constraint_group.h

    r25919 r26141  
    5454GType                           midgard_query_constraint_group_get_type         (void);
    55 MidgardQueryConstraintGroup     *midgard_query_constraint_group_new             (const gchar *type, MidgardQueryConstraintSimple *constraint, ...);
     55MidgardQueryConstraintGroup     *midgard_query_constraint_group_new             (void);
     56MidgardQueryConstraintGroup     *midgard_query_constraint_group_new_valist      (const gchar *type, MidgardQueryConstraintSimple *constraint, ...);
     57MidgardQueryConstraintGroup     *midgard_query_constraint_group_new_with_constraints    (const gchar *type, MidgardQueryConstraintSimple **constraints, guint n_constraints);
    5658const gchar                     *midgard_query_constraint_group_get_group_type  (MidgardQueryConstraintGroup *self);
    5759gboolean                        midgard_query_constraint_group_set_group_type           (MidgardQueryConstraintGroup *self, const gchar *type);
Note: See TracChangeset for help on using the changeset viewer.