public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* grap, anybody?
@ 2020-01-06 21:40 bonhard
  2020-01-07  6:17 ` Brian Inglis
  2020-01-07 11:28 ` Takashi Yano
  0 siblings, 2 replies; 6+ messages in thread
From: bonhard @ 2020-01-06 21:40 UTC (permalink / raw)
  To: cygwin; +Cc: fergusd84

I have a version of grap, being
grap 1.42 compiled under CYGWIN_NT-6.1 1.5.25(0.156/4/2)
compiled (guessing) more than a decade ago. It still works, which is a good
thing, because if I try to compile the current version
https://www.lunabase.org/~faber/Vault/software/grap/grap-1.45.tar.gz
with the current Cygwin provision CYGWIN_NT-10.0-WOW 3.1.2(0.340/5/3) the
process fails at make, after a successful ./configure.
However, the executable I have does NOT work under the 64-bit version of
Cygwin.
Q1 Can anybody provide a fix to compile grap 1.45 for Cygwin32?
Q2 Ditto Cygwin64 (or _any_ version of grap that works for Cygwin64)?
Q3 Failing any hints or pointers for compilation (preferred) can anybody
please provide a pointer to a grap executable that works for Cygwin64?
Thank you! 


--------------------------------------------------------------------
mail2web LIVE ? Free email based on Microsoft? Exchange technology -
https://link.mail2web.com/LIVE



--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: grap, anybody?
  2020-01-06 21:40 grap, anybody? bonhard
@ 2020-01-07  6:17 ` Brian Inglis
  2020-01-07 11:28 ` Takashi Yano
  1 sibling, 0 replies; 6+ messages in thread
From: Brian Inglis @ 2020-01-07  6:17 UTC (permalink / raw)
  To: cygwin

On 2020-01-06 14:39, bonhard@uklinux.net wrote:
> I have a version of grap, being
> grap 1.42 compiled under CYGWIN_NT-6.1 1.5.25(0.156/4/2)
> compiled (guessing) more than a decade ago. It still works, which is a good
> thing, because if I try to compile the current version
> https://www.lunabase.org/~faber/Vault/software/grap/grap-1.45.tar.gz
> with the current Cygwin provision CYGWIN_NT-10.0-WOW 3.1.2(0.340/5/3) the
> process fails at make, after a successful ./configure.
> However, the executable I have does NOT work under the 64-bit version of
> Cygwin.
> Q1 Can anybody provide a fix to compile grap 1.45 for Cygwin32?
> Q2 Ditto Cygwin64 (or _any_ version of grap that works for Cygwin64)?
> Q3 Failing any hints or pointers for compilation (preferred) can anybody
> please provide a pointer to a grap executable that works for Cygwin64?

Using basic grap.cygport variable definitions, issues are:

$ cygport grap.cygport download all
...
configure: creating ./config.status
config.status: creating Makefile
config.status: creating config.h
config.status: config.h is unchanged
config.status: executing depfiles commands
bison -y -d grap.yy && rm -f y.tab.c
bison: grap.yy: cannot open: No such file or directory
make: *** [Makefile:995: y.tab.h] Error 1
*** ERROR: make failed

fudged by:

$ cd grap-1.45-1.x86_64/build/
$ llgo grap.yy
lrwxrwxrwx 1 40 Jan 14  2019 grap.yy -> grap-1.45-1.x86_64/src/grap-1.45/grap.yy
$ ln -fs ../src/grap-1.45/grap.yy .
'./grap.yy' -> '../src/grap-1.45/grap.yy'
$ llgo grap.yy
lrwxrwxrwx 1 24 Jan  6 20:55 grap.yy -> ../src/grap-1.45/grap.yy
$ cd ../../

then:

$ cygport grap.cygport compile
...
make[1]: *** No rule to make target 'grap*.defines', needed by 'all-am'.  Stop.
make[1]: *** Waiting for unfinished jobs....
mv -f .deps/grap_draw.Tpo .deps/grap_draw.Po
mv -f .deps/grap_parse.Tpo .deps/grap_parse.Po
mv -f .deps/grap_pic.Tpo .deps/grap_pic.Po
mv -f .deps/grap_tokenizer.Tpo .deps/grap_tokenizer.Po
make[1]: Leaving directory '.../grap-1.45-1.x86_64/build'
make: *** [Makefile:381: all] Error 2
*** ERROR: make failed

because:

$ cd grap-1.45-1.x86_64/src/grap-1.45/
$ fgrep 'dist_defines_DATA = ' Makefile.{am,in}
Makefile.am:dist_defines_DATA = grap*.defines
Makefile.in:dist_defines_DATA = grap*.defines

fudged by:

$ cd grap-1.45-1.x86_64/build/
$ ln -s ../src/grap-1.45/*.defines .
'./grap.defines' -> '../src/grap-1.45/grap.defines'
'./grap.tex.defines' -> '../src/grap-1.45/grap.tex.defines'

retry:

$ cygport grap.cygport compile
...
make[1]: *** No rule to make target 'examples/*.d', needed by 'all-am'.  Stop.
make[1]: *** Waiting for unfinished jobs....
.../grap-1.45-1.x86_64/src/grap-1.45/grap_lex.ll: In function ‘int yylex()’:
.../grap-1.45-1.x86_64/src/grap-1.45/grap_lex.ll:201:52: warning: comparison
between signed and unsigned integer expressions [-Wsign-compare]
                            for ( unsigned i = 0; i < yyleng; i++ )
                                                  ~~^~~~~~~~
grap.yy: In function ‘int yyparse()’:
grap.yy:582:12: error: ‘strptime’ was not declared in this scope
        if (strptime($5->c_str(), $3->c_str(), &tm) != 0) {
            ^~~~~~~~
grap.yy:582:12: note: suggested alternative: ‘strftime’
        if (strptime($5->c_str(), $3->c_str(), &tm) != 0) {
            ^~~~~~~~
            strftime
.../grap-1.45-1.x86_64/src/grap-1.45/grap_lex.ll:725:12: error: ‘strdup’ was not
declared in this scope
  char *c = strdup(yytext);
            ^~~~~~
.../grap-1.45-1.x86_64/src/grap-1.45/grap_lex.ll:725:12: note: suggested
alternative: ‘strcmp’
  char *c = strdup(yytext);
            ^~~~~~
            strcmp
grap_lex.cc: In function ‘void yy_init_buffer(YY_BUFFER_STATE, FILE*)’:
grap_lex.cc:3723:48: error: ‘fileno’ was not declared in this scope

                                                ^
grap_lex.cc:3723:48: note: suggested alternative: ‘file’

                                                ^
                                                file
make[1]: *** [Makefile:497: grap.o] Error 1
make[1]: *** [Makefile:497: grap_lex.o] Error 1
make[1]: Leaving directory '.../grap-1.45-1.x86_64/build'
make: *** [Makefile:381: all] Error 2
*** ERROR: make failed

patched with:

--- grap-1.45-1.x86_64/origsrc/grap-1.45/grap.yy        2014-08-24
16:58:06.000000000 -0600
+++ grap-1.45-1.x86_64/src/grap-1.45/grap.yy    2020-01-06 22:38:47.338711700 -0700
@@ -10,6 +10,7 @@
 #include <iostream>
 #include <stack>
 #include <math.h>
+#include <time.h>
 #ifdef STDC_HEADERS
 #include <limits.h>
 #else

--- grap-1.45-1.x86_64/origsrc/grap-1.45/grap_lex.ll    2014-08-24
16:55:34.000000000 -0600
+++ grap-1.45-1.x86_64/src/grap-1.45/grap_lex.ll        2020-01-06
22:42:17.566551300 -0700
@@ -20,6 +20,8 @@ extern "C" {
 #include <sys/param.h>
 #include <set>
 #include <map>
+#include <stdio.h>
+#include <string.h>
 #include "grap.h"
 #include "grap_data.h"
 #include "grap_draw.h"

gives:

$ cygport grap.cygport compile
...
make[1]: *** No rule to make target 'examples/*.d', needed by 'all-am'.  Stop.
make[1]: *** Waiting for unfinished jobs....
make[1]: Leaving directory '.../grap-1.45-1.x86_64/build'
make: *** [Makefile:381: all] Error 2
*** ERROR: make failed

bypass with:

$ cd grap-1.45-1.x86_64/build/
$ ln -s ../src/grap-1.45/examples .
'./examples' -> '../src/grap-1.45/examples'
$ cd ../../

result:

$ cygport grap.cygport compile
...
.../grap-1.45-1.x86_64/src/grap-1.45/grap_lex.ll:727:12: error: ‘strdup’ was not
declared in this scope
  char *c = strdup(yytext);
            ^~~~~~
.../grap-1.45-1.x86_64/src/grap-1.45/grap_lex.ll:727:12: note: suggested
alternative: ‘strcmp’
  char *c = strdup(yytext);
            ^~~~~~
            strcmp
grap_lex.cc: In function ‘void yy_init_buffer(YY_BUFFER_STATE, FILE*)’:
grap_lex.cc:3725:48: error: ‘fileno’ was not declared in this scope

                                                ^
grap_lex.cc:3725:48: note: suggested alternative: ‘file’

                                                ^
                                                file
make[1]: *** [Makefile:497: grap_lex.o] Error 1
make[1]: *** Waiting for unfinished jobs....
mv -f .deps/grap_parse.Tpo .deps/grap_parse.Po
mv -f .deps/grap_tokenizer.Tpo .deps/grap_tokenizer.Po
make[1]: Leaving directory '.../grap-1.45-1.x86_64/build'
make: *** [Makefile:381: all] Error 2
*** ERROR: make failed

and this now won't go away even after deleting the generated files and touching
the sources.

Anyone else have suggestions?

-- 
Take care. Thanks, Brian Inglis, Calgary, Alberta, Canada

This email may be disturbing to some readers as it contains
too much technical detail. Reader discretion is advised.

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: grap, anybody?
  2020-01-06 21:40 grap, anybody? bonhard
  2020-01-07  6:17 ` Brian Inglis
@ 2020-01-07 11:28 ` Takashi Yano
  1 sibling, 0 replies; 6+ messages in thread
From: Takashi Yano @ 2020-01-07 11:28 UTC (permalink / raw)
  To: cygwin

On Mon, 6 Jan 2020 16:39:43 -0500
"bonhard@uklinux.net" wrote:
> I have a version of grap, being
> grap 1.42 compiled under CYGWIN_NT-6.1 1.5.25(0.156/4/2)
> compiled (guessing) more than a decade ago. It still works, which is a good
> thing, because if I try to compile the current version
> https://www.lunabase.org/~faber/Vault/software/grap/grap-1.45.tar.gz
> with the current Cygwin provision CYGWIN_NT-10.0-WOW 3.1.2(0.340/5/3) the
> process fails at make, after a successful ./configure.
> However, the executable I have does NOT work under the 64-bit version of
> Cygwin.
> Q1 Can anybody provide a fix to compile grap 1.45 for Cygwin32?
> Q2 Ditto Cygwin64 (or _any_ version of grap that works for Cygwin64)?
> Q3 Failing any hints or pointers for compilation (preferred) can anybody
> please provide a pointer to a grap executable that works for Cygwin64?

Try following patch.

--- configure.ac.orig	2014-08-31 00:33:45.000000000 +0900
+++ configure.ac	2020-01-07 08:43:59.559103700 +0900
@@ -45,10 +45,10 @@
 AC_MSG_CHECKING(if ${CXX} supports -std=c++0x)
 old_cxxflags="$CXXFLAGS"
 old_cppflags="$CPPFLAGS"
-CXXFLAGS="$CXXFLAGS -std=c++0x"
-CPPFLAGS="$CPPFLAGS -std=c++0x"
+CXXFLAGS="$CXXFLAGS -D_XOPEN_SOURCE=700"
+CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=700"
 AC_TRY_COMPILE([], [], [
-	CX0FLAGS="-std=c++0x"
+	CX0FLAGS=""
 	AC_MSG_RESULT(yes)
 	], [
 	CX0FLAGS=""

-- 
Takashi Yano <takashi.yano@nifty.ne.jp>

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: grap, anybody?
  2020-01-07 22:10 ` Fergus Daly
@ 2020-01-07 22:41   ` Marco Atzeri
  0 siblings, 0 replies; 6+ messages in thread
From: Marco Atzeri @ 2020-01-07 22:41 UTC (permalink / raw)
  To: cygwin; +Cc: fergusd84

Am 07.01.2020 um 23:10 schrieb Fergus Daly:
> 
> I'm just not up to it, but given the trivial nature of the single required patch, is there anybody out there who could take this on for the Cygwin provision?
> (There must be 00s of users who need it? I'm truly surprised that grap, or rather its lack, hasn't had a much higher historical profile in this forum.)
> Does it matter that the source files https://www.lunabase.org/~faber/Vault/software/grap/grap-1.45.tar.gz are "owned" by somebody else?
> (I imagine it does. Just asking.)
> 


1) This is not a forum, but a mailing list.

2) Where is the sorce file is irrilevant. The LICENSE matters,
   but as the package is in Debian I assume it is fine.

3) about making a package
   "Somebody Has To Do Itâ„¢. Are you volunteering? "
    https://cygwin.com/acronyms/#SHTDI


All maintainers are volounteers. They build packages that they care.
It seems grap has not passed the minimal threshold for anyone to
volounteer for it.
Feel free to offer yourself
https://cygwin.com/packaging-contributors-guide.html

Regards
Marco



--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 6+ messages in thread

* RE: grap, anybody?
  2020-01-07 17:36 Fergus Daly
@ 2020-01-07 22:10 ` Fergus Daly
  2020-01-07 22:41   ` Marco Atzeri
  0 siblings, 1 reply; 6+ messages in thread
From: Fergus Daly @ 2020-01-07 22:10 UTC (permalink / raw)
  To: cygwin; +Cc: Fergus Daly

>> Try following patch.

--- configure.ac.orig	2014-08-31 00:33:45.000000000 +0900
+++ configure.ac	2020-01-07 08:43:59.559103700 +0900
@@ -45,10 +45,10 @@
 AC_MSG_CHECKING(if ${CXX} supports -std=c++0x)
 old_cxxflags="$CXXFLAGS"
 old_cppflags="$CPPFLAGS"
-CXXFLAGS="$CXXFLAGS -std=c++0x"
-CPPFLAGS="$CPPFLAGS -std=c++0x"
+CXXFLAGS="$CXXFLAGS -D_XOPEN_SOURCE=700"
+CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=700"
 AC_TRY_COMPILE([], [], [
-	CX0FLAGS="-std=c++0x"
+	CX0FLAGS=""
 	AC_MSG_RESULT(yes)
 	], [
 	CX0FLAGS=""

> Thank you! This patch enabled compilation of the grap-1.45 executable for 32-bit and 64-bit Cygwin respectively.

I'm just not up to it, but given the trivial nature of the single required patch, is there anybody out there who could take this on for the Cygwin provision?
(There must be 00s of users who need it? I'm truly surprised that grap, or rather its lack, hasn't had a much higher historical profile in this forum.)
Does it matter that the source files https://www.lunabase.org/~faber/Vault/software/grap/grap-1.45.tar.gz are "owned" by somebody else? 
(I imagine it does. Just asking.)


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: grap, anybody?
@ 2020-01-07 17:36 Fergus Daly
  2020-01-07 22:10 ` Fergus Daly
  0 siblings, 1 reply; 6+ messages in thread
From: Fergus Daly @ 2020-01-07 17:36 UTC (permalink / raw)
  To: cygwin; +Cc: Fergus Daly

>> Try following patch.

--- configure.ac.orig	2014-08-31 00:33:45.000000000 +0900
+++ configure.ac	2020-01-07 08:43:59.559103700 +0900
@@ -45,10 +45,10 @@
 AC_MSG_CHECKING(if ${CXX} supports -std=c++0x)
 old_cxxflags="$CXXFLAGS"
 old_cppflags="$CPPFLAGS"
-CXXFLAGS="$CXXFLAGS -std=c++0x"
-CPPFLAGS="$CPPFLAGS -std=c++0x"
+CXXFLAGS="$CXXFLAGS -D_XOPEN_SOURCE=700"
+CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=700"
 AC_TRY_COMPILE([], [], [
-	CX0FLAGS="-std=c++0x"
+	CX0FLAGS=""
 	AC_MSG_RESULT(yes)
 	], [
 	CX0FLAGS=""

Thank you! This patch enabled compilation of the grap-1.45 executable for 32-bit and 64-bit Cygwin respectively.
Fergus

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2020-01-07 22:41 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-01-06 21:40 grap, anybody? bonhard
2020-01-07  6:17 ` Brian Inglis
2020-01-07 11:28 ` Takashi Yano
2020-01-07 17:36 Fergus Daly
2020-01-07 22:10 ` Fergus Daly
2020-01-07 22:41   ` Marco Atzeri

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).