gnuastro-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[gnuastro-commits] master 4ca8e36 1/2: Debian packaging checklist comple


From: Mohammad Akhlaghi
Subject: [gnuastro-commits] master 4ca8e36 1/2: Debian packaging checklist completed, Lintian warnings fixed
Date: Thu, 11 May 2017 19:41:23 -0400 (EDT)

branch: master
commit 4ca8e36a02ed9de315acb94057c54aca9d4f570c
Author: Mohammad Akhlaghi <address@hidden>
Commit: Mohammad Akhlaghi <address@hidden>

    Debian packaging checklist completed, Lintian warnings fixed
    
    The debian packaging checklist has been completed and tested and the
    Lintian extra warnings (spelling checks) were almost completely
    fixed. Except two:
    
     - shlib-calls-exit: Since the library calls the `exit' function, which is
            not recommended since the exiting is meant to be done by the caller
            program, not a library. However, Gnuastro's library is still under
            heavy development. In particular, we don't have an error management
            system yet, so this can be ignored now.
    
     - no-symbols-control-file: [From the webpage] Although the package
            includes a shared library, the package does not have a symbols
            control file. dpkg can use symbols files in order to generate more
            accurate library dependencies for applications, based on the
            symbols from the library that are actually used by the application.
    
    One uninitialized-variable compiler warning was also corrected. The debian
    compiler uses the `-Wunused-result' option, so all calls with `asprintf'
    gave a warning because we aren't using its return value (the number of
    elements allocated). This can safely be ignored for now.
---
 bin/statistics/statistics.c |  4 ++--
 doc/release-checklist.txt   | 39 +++++++++++++++++++++++++++++----------
 lib/arithmetic.c            |  2 +-
 lib/fits.c                  |  2 +-
 lib/options.c               |  2 +-
 lib/txt.c                   |  6 +++---
 6 files changed, 37 insertions(+), 18 deletions(-)

diff --git a/bin/statistics/statistics.c b/bin/statistics/statistics.c
index a873d32..9333fe8 100644
--- a/bin/statistics/statistics.c
+++ b/bin/statistics/statistics.c
@@ -720,12 +720,12 @@ print_input_info(struct statisticsparams *p)
   /* Range. */
   str=NULL;
   if( !isnan(p->greaterequal) && !isnan(p->lessthan) )
-    asprintf(&str, "from (inclusive) %g, upto (exclusive) %g",
+    asprintf(&str, "from (inclusive) %g, up to (exclusive) %g",
              p->greaterequal, p->lessthan);
   else if( !isnan(p->greaterequal) )
     asprintf(&str, "from (inclusive) %g", p->greaterequal);
   else if( !isnan(p->lessthan) )
-    asprintf(&str, "upto (exclusive) %g", p->lessthan);
+    asprintf(&str, "up to (exclusive) %g", p->lessthan);
   if(str)
     {
       printf("Range: ");
diff --git a/doc/release-checklist.txt b/doc/release-checklist.txt
index 7c29c49..20f5e1c 100644
--- a/doc/release-checklist.txt
+++ b/doc/release-checklist.txt
@@ -126,23 +126,23 @@ Steps necessary to Package Gnuastro for Debian.
      $ git clone git://anonscm.debian.org/debian-astro/packages/gnuastro.git
 
  - A `gnuastro' directory will be built, for the moment don't go in it,
-   we'll keep all out temporary files in this parent directory. Put a copy
-   of the tarball to be packaged in this directory and make a standard
+   we'll keep all temporary files in this parent directory. Put a copy of
+   the tarball to be packaged in this directory and make a standard
    symbolic link to it (IMPORTANT: the `dash' is changed to an `underscore'
    and an `orig' is added), then go into the cloned directory.
 
-     $ ln -s gnuastro-XXXX.tar.gz gnuastro_XXXX.orig.tar.gz
+     $ ln -s gnuastro-A.B.CCC-DDDD.tar.gz gnuastro_A.B.CCC.orig.tar.gz
      $ cd gnuastro
 
  - You need to checkout to the `upstream' branch, clean everything that was
-   in it and inject this release's raw package source files into it as
-   shown below. Note that we should run `rm -rf ./*', because the `.git'
-   hidden directory must stay.
+   in it and unpack this release's raw package source files into it as
+   shown below.
 
      $ git checkout upstream
-     $ rm *                     # To delete all the non-hidden files
-     $ rm .autom4te.cfg .dir-locals.el .git .tarball-version .version
-     $ rm -rf bin/ bootstrapped/ doc/ lib/ tests/
+     $ mv .git ../gnuastro-tmp-git         # We want to keep `.git'.
+     $ rm -rf ./*                          # Delete every non-hidden file.
+     $ rm ./.*                             # Delete the hidden files.
+     $ mv ../gnuastro-tmp-git .git         # Bring back the `.git' directory.
      $ tar xf ../gnuastro_XXXX.orig.tar.gz --strip-components=1
 
  - We now need to commit these into the `upstream' branch of the Git
@@ -157,6 +157,20 @@ Steps necessary to Package Gnuastro for Debian.
 
      $ git checkout master
 
+ - Again, we need to clean everything that already exists here, except
+   `.git' and `debian':
+
+     $ mv debian ../gnuastro-tmp-debian    # We want to keep `debian'.
+     $ mv .git ../gnuastro-tmp-git         # We want to keep `.git'.
+     $ rm -rf ./*                          # Delete non-hidden files and dirs.
+     $ rm ./.*                             # Delete the hidden files.
+     $ mv ../gnuastro-tmp-git .git         # Bring back the `.git' directory.
+     $ mv ../gnuastro-tmp-debian debian    # Bring back the `debian' directory.
+
+ - Unpack the distribution tarball into the master branch too:
+
+     $ tar xf ../gnuastro_XXXX.orig.tar.gz --strip-components=1
+
  - Update the ChangeLog (similar to previous entries):
 
      $ emacs debian/changelog
@@ -165,6 +179,11 @@ Steps necessary to Package Gnuastro for Debian.
 
      $ sudo pbuilder update
 
- - Run `pdebuild':
+ - Run `pdebuild' to build the package.
 
      $ pdebuild
+
+ - Run Lintian to check the build.
+
+     $ lintian -E -I --pedantic                                         \
+               /var/cache/pbuilder/result/gnuastro_XXXX-1_amd64.changes
diff --git a/lib/arithmetic.c b/lib/arithmetic.c
index d73e189..363ff0b 100644
--- a/lib/arithmetic.c
+++ b/lib/arithmetic.c
@@ -232,7 +232,7 @@ arithmetic_check_float_input(gal_data_t *in, int operator, 
char *numstr)
       error(EXIT_FAILURE, 0, "the %s operator can only accept single or "
             "double precision floating point numbers as its operand. The "
             "%s operand has type %s. You can use the `float' or `double' "
-            "operators before this operator to explicity convert to the "
+            "operators before this operator to explicitly convert to the "
             "desired precision floating point type. If the operand was "
             "originally a typed number (string of characters), add an `f' "
             "after it so it is directly read into the proper precision "
diff --git a/lib/fits.c b/lib/fits.c
index 69bd122..3ed2418 100644
--- a/lib/fits.c
+++ b/lib/fits.c
@@ -1740,7 +1740,7 @@ set_display_format(char *tdisp, gal_data_t *data, char 
*filename, char *hdu,
 
     default:
       error(EXIT_FAILURE, 0, "%s (hdu: %s): Format character `%c' in the "
-            "value (%s) of the keywork %s not recognized in %s", filename, hdu,
+            "value (%s) of the keyword %s not recognized in %s", filename, hdu,
             tdisp[0], tdisp, keyname, __func__);
     }
 
diff --git a/lib/options.c b/lib/options.c
index efe39b7..2abfc83 100644
--- a/lib/options.c
+++ b/lib/options.c
@@ -1724,7 +1724,7 @@ options_print_all(struct gal_options_common_params *cp, 
char *dirname,
       errno=0;
       fp=fopen(filename, "w");
       if(fp==NULL)
-        error(EXIT_FAILURE, errno, "%s: could't open to write "
+        error(EXIT_FAILURE, errno, "%s: couldn't open to write "
               "configuration file in %s", dirname, __func__);
 
       /* Print the basic information as comments in the file first. */
diff --git a/lib/txt.c b/lib/txt.c
index 880b2e3..dcc174c 100644
--- a/lib/txt.c
+++ b/lib/txt.c
@@ -512,7 +512,7 @@ txt_get_info(char *filename, int format, size_t *numdata, 
size_t *dsize)
   size_t numtokens;
   int firstlinedone=0;
   gal_data_t *datall=NULL, *dataarr;
-  char *line, *format_err, *comm_start;
+  char *line, *format_err="empty", *comm_start;
   size_t linelen=10; /* `linelen' will be increased by `getline'. */
 
 
@@ -531,7 +531,7 @@ txt_get_info(char *filename, int format, size_t *numdata, 
size_t *dsize)
   errno=0;
   fp=fopen(filename, "r");
   if(fp==NULL)
-    error(EXIT_FAILURE, errno, "%s: could't open to read as a plain "
+    error(EXIT_FAILURE, errno, "%s: couldn't open to read as a plain "
           "text %s in %s", filename, format_err, __func__);
 
 
@@ -855,7 +855,7 @@ gal_txt_read(char *filename, size_t *dsize, gal_data_t 
*info,
   errno=0;
   fp=fopen(filename, "r");
   if(fp==NULL)
-    error(EXIT_FAILURE, errno, "%s: could't open to read as a text table "
+    error(EXIT_FAILURE, errno, "%s: couldn't open to read as a text table "
           "in %s", filename, __func__);
 
   /* Allocate the space necessary to keep a copy of each line as we parse



reply via email to

[Prev in Thread] Current Thread [Next in Thread]