1 Востаннє редагувалося Дмитро-Чебурашка (13.05.2019 11:25:57)

Тема: Тестуввання Cygwin та його використання у віндовсі

Всім здоров'я та гарного настрою!

Тестую Cygwin. Хочу щось скомпіляти.  Ось, я абсолютно не уявляю,
як наприклад мені тепер додати у свого Cygwin-а потрібні бібліотеки.  Той же libncursesw.

Дима@Komp ~
$ cd F:\Htop\htop-1.0.3
-bash: cd: F:Htophtop-1.0.3: No such file or directory

Дима@Komp ~
$

Дима@Komp ~
$

Дима@Komp ~
$ cd F:\Htop

Дима@Komp /cygdrive/f/Htop
$ cd htop-1.0.3

Дима@Komp /cygdrive/f/Htop/htop-1.0.3
$ ./configure
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.exe
checking for suffix of executables... .exe
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking minix/config.h usability... no
checking minix/config.h presence... no
checking for minix/config.h... no
checking whether it is safe to define __EXTENSIONS__... yes
checking build system type... i686-pc-cygwin
checking host system type... i686-pc-cygwin
checking target system type... i686-pc-cygwin
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking for gcc... (cached) gcc
checking whether we are using the GNU C compiler... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gcc option to accept ISO C89... (cached) none needed
checking whether gcc and cc understand -c and -o together... yes
checking how to print strings... printf
checking for a sed that does not truncate output... /usr/bin/sed
checking for fgrep... /usr/bin/grep -F
checking for ld used by gcc... D:/MinGW/mingw32/bin/ld.exe
) is GNU ld... noinker (D:/MinGW/mingw32/bin/ld.exe
checking for BSD- or MS-compatible name lister (nm)... /cygdrive/d/MinGW/bin/nm -B
checking the name lister (/cygdrive/d/MinGW/bin/nm -B) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 8192
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
 option to reload object files... -r.exe
checking for objdump... objdump
checking how to recognize dependent libraries... file_magic ^x86 archive import|^x86 DLL
checking for ar... ar
checking for strip... strip
checking for ranlib... ranlib
checking command to parse /cygdrive/d/MinGW/bin/nm -B output from gcc object... failed
checking for dlfcn.h... no
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -DDLL_EXPORT -DPIC
checking if gcc PIC flag -DDLL_EXPORT -DPIC works... yes
checking if gcc static flag -static works... yes
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
) supports shared libraries... yes:/MinGW/mingw32/bin/ld.exe
checking dynamic linker characteristics... Win32 ld.exe
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... no
checking whether to build static libraries... yes
checking for ceil in -lm... yes
checking for dirent.h that defines DIR... yes
checking for library containing opendir... none required
checking for ANSI C header files... (cached) yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking for strings.h... (cached) yes
checking sys/param.h usability... yes
checking sys/param.h presence... yes
checking for sys/param.h... yes
checking sys/time.h usability... yes
checking sys/time.h presence... yes
checking for sys/time.h... yes
checking for unistd.h... (cached) yes
checking execinfo.h usability... no
checking execinfo.h presence... no
checking for execinfo.h... no
checking for stdbool.h that conforms to C99... yes
checking for _Bool... yes
checking for an ANSI C-conforming const... yes
checking for pid_t... yes
checking for uid_t in sys/types.h... no
checking whether closedir returns void... no
checking return type of signal handlers... void
checking whether lstat correctly handles trailing slash... no
checking whether stat accepts an empty string... no
checking for memmove... yes
checking for strncasecmp... yes
checking for strstr... yes
checking for strdup... yes
checking whether gcc -std=c99 option works... yes
checking for refresh in -lncursesw... no
configure: error: You may want to use --disable-unicode or install libncursesw.

Дима@Komp /cygdrive/f/Htop/htop-1.0.3
$

Так, не можу взагалі нагугліти цю бібліотеку, і як конкретно її поставити.

2

Re: Тестуввання Cygwin та його використання у віндовсі

Ось тут пишуть, що треба ще раз запустити setup.exe та вибрати які бібліотеки встановити - http://www.cygwin.com/install.html

3 Востаннє редагувалося Дмитро-Чебурашка (13.05.2019 20:21:07)

Re: Тестуввання Cygwin та його використання у віндовсі

Та  я знаю, я ж вчора перед тим як завдати питання півгодини гуглив і ще півгодини яндексів, і сьогодні також. і я так і не зрозумів які біблиотеки треба додати. Я навить заскриняю, бо я може якось щось не те роблю або чогось не розумію.

Post's attachments

ygwin0.png 123.07 kb, 127 downloads since 2019-05-13 

4

Re: Тестуввання Cygwin та його використання у віндовсі

А спробуй скрипт apt-cyg, ось тут за посиланням є інформація як його встановити: https://stackoverflow.com/a/28857280

5

Re: Тестуввання Cygwin та його використання у віндовсі

Дмитро-Чебурашка написав:

Та  я знаю, я ж вчора перед тим як завдати питання півгодини гуглив і ще півгодини яндексів, і сьогодні також. і я так і не зрозумів які біблиотеки треба додати. Я навить заскриняю, бо я може якось щось не те роблю або чогось не розумію.

Здається, я зрозумів у чому проблема. На скріншоті у тебе "View" -> "Pending". Спробуй змінити на "View" -> "Full".

6 Востаннє редагувалося reverse2500 (14.05.2019 06:33:24)

Re: Тестуввання Cygwin та його використання у віндовсі

Cygwin це не актуально, спробуй WSL2
ще варіант спробувати зібрати pkgsrc, сам користувався в Cygwin

7 Востаннє редагувалося Дмитро-Чебурашка (14.05.2019 13:29:13)

Re: Тестуввання Cygwin та його використання у віндовсі

Так, але поки знову не зрозуміло - галочку я виставити не можу,
а слово унинсталл взагалі лякає. Незрозуміло знову що це.

спробую може я скрипт apt-cyg, але все отно бажано було б розібратися чомуж так важко зробитищось природне і елементарне, додати бібліотеку яка мабуть же існує, взагалі повинне природно матися на увазі додавання чого-небуть.

- Ніколи не програмуйте та не пийте пиво  - це  речі зовсім різні і не сповязані, пиво можа і не пити. Буде навить краще.

https://replace.org.ua/misc.php?action=pun_attachment&item=1981&download=0

Post's attachments

ygwin1.png 95.65 kb, 85 downloads since 2019-05-14 

Re: Тестуввання Cygwin та його використання у віндовсі

А ось, там слова видалити, тримати і переустановити Вже зрозуміліше.

9

Re: Тестуввання Cygwin та його використання у віндовсі

Дмитро-Чебурашка написав:

А ось, там слова видалити, тримати і переустановити Вже зрозуміліше.

Так, тобі потрібно вибрати версію программи/бібліотеки зі списка. Але я думаю, що ти це вже зробив. :)

До речі, apt-cyg у мене не працює. (Лише зараз мав нагоду перевірити, дома користуюсь виключно Linux). Це якщо ще хтось захоче спробувати цей скрипт.

Подякували: Дмитро-Чебурашка1

Re: Тестуввання Cygwin та його використання у віндовсі

Я був упевнений, що ця сама libncursesw перевстановлена і додані також її первинники, і ось, проте, компіляція

Дима@Komp ~
$ cd F:\Htop

Дима@Komp /cygdrive/f/Htop
$ cd htop-1.0.3

Дима@Komp /cygdrive/f/Htop/htop-1.0.3
$ ./configure
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.exe
checking for suffix of executables... .exe
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking minix/config.h usability... no
checking minix/config.h presence... no
checking for minix/config.h... no
checking whether it is safe to define __EXTENSIONS__... yes
checking build system type... i686-pc-cygwin
checking host system type... i686-pc-cygwin
checking target system type... i686-pc-cygwin
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking for gcc... (cached) gcc
checking whether we are using the GNU C compiler... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gcc option to accept ISO C89... (cached) none needed
checking whether gcc and cc understand -c and -o together... yes
checking how to print strings... printf
checking for a sed that does not truncate output... /usr/bin/sed
checking for fgrep... /usr/bin/grep -F
checking for ld used by gcc... D:/MinGW/mingw32/bin/ld.exe
) is GNU ld... noinker (D:/MinGW/mingw32/bin/ld.exe
checking for BSD- or MS-compatible name lister (nm)... /cygdrive/d/MinGW/bin/nm -B
checking the name lister (/cygdrive/d/MinGW/bin/nm -B) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 8192
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
 option to reload object files... -r.exe
checking for objdump... objdump
checking how to recognize dependent libraries... file_magic ^x86 archive import|^x86 DLL
checking for ar... ar
checking for strip... strip
checking for ranlib... ranlib
checking command to parse /cygdrive/d/MinGW/bin/nm -B output from gcc object... failed
checking for dlfcn.h... no
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -DDLL_EXPORT -DPIC
checking if gcc PIC flag -DDLL_EXPORT -DPIC works... yes
checking if gcc static flag -static works... yes
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
) supports shared libraries... yes:/MinGW/mingw32/bin/ld.exe
checking dynamic linker characteristics... Win32 ld.exe
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... no
checking whether to build static libraries... yes
checking for ceil in -lm... yes
checking for dirent.h that defines DIR... yes
checking for library containing opendir... none required
checking for ANSI C header files... (cached) yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking for strings.h... (cached) yes
checking sys/param.h usability... yes
checking sys/param.h presence... yes
checking for sys/param.h... yes
checking sys/time.h usability... yes
checking sys/time.h presence... yes
checking for sys/time.h... yes
checking for unistd.h... (cached) yes
checking execinfo.h usability... no
checking execinfo.h presence... no
checking for execinfo.h... no
checking for stdbool.h that conforms to C99... yes
checking for _Bool... yes
checking for an ANSI C-conforming const... yes
checking for pid_t... yes
checking for uid_t in sys/types.h... no
checking whether closedir returns void... no
checking return type of signal handlers... void
checking whether lstat correctly handles trailing slash... no
checking whether stat accepts an empty string... no
checking for memmove... yes
checking for strncasecmp... yes
checking for strstr... yes
checking for strdup... yes
checking whether gcc -std=c99 option works... yes
checking for refresh in -lncursesw... no
configure: error: You may want to use --disable-unicode or install libncursesw.

Дима@Komp /cygdrive/f/Htop/htop-1.0.3
$

11

Re: Тестуввання Cygwin та його використання у віндовсі

А пакет libncurses-devel інстальовано?

Подякували: Дмитро-Чебурашка1

Re: Тестуввання Cygwin та його використання у віндовсі

Встановив на новому диску cygwin; пробую скомпіляти  тобто фактично тестую, граюся

Дима@Komp /usr/bin
$ cd

Дима@Komp ~
$ cd F:\HeloWorld

Дима@Komp /cygdrive/f/HeloWorld
$ g++ ublas_test.cpp -o ublas_test
ublas_test.cpp:1:42: fatal error: boost/numeric/ublas/vector.hpp: No such file or directory
 #include <boost/numeric/ublas/vector.hpp>
                                          ^
compilation terminated.

Дима@Komp /cygdrive/f/HeloWorld
$

Чого ж він не знаходить файли які точно там є? Чого йому ще? setup-x86 сам встановив файли
в якісь директорії, я нічого там не поправляв.



#include <boost/numeric/ublas/vector.hpp>
#include <boost/numeric/ublas/matrix.hpp>
#include <boost/numeric/ublas/io.hpp>

using namespace boost::numeric::ublas;

// "y = Ax" приклад
int main()
{
    vector<double> x(2);
    x(0) = 1; x(1) = 2;

    matrix<double> A(2,2);
    A(0,0) = 0; A(0,1) = 1;
    A(1,0) = 2; A(1,1) = 3;

    vector<double> y = prod(A, x);

    std::cout << y << std::endl;

    return 0;
}

13 Востаннє редагувалося Дмитро-Чебурашка (29.05.2019 11:33:10)

Re: Тестуввання Cygwin та його використання у віндовсі

libncurses-devel я пробував знайти, але, мабуть, є лише архіви з розширенням lst gz і tar gz, принаймні лише їх знайшов тотал командер. Я гадки не маю, чому це так.

Re: Тестуввання Cygwin та його використання у віндовсі

Чи є спеціальний форум, де можна ставити питання саме по cygwin?