Benson-Genomics-Lab / TRF

Tandem Repeats Finder: a program to analyze DNA sequences
https://tandem.bu.edu/trf/trf.html
GNU Affero General Public License v3.0
152 stars 26 forks source link

Non-executable TRF #18

Open rnbehm opened 1 year ago

rnbehm commented 1 year ago

I am having a lot of pain trying to get TRF to work. No matter what I do or if I download the executable separate and move it in, I cannot get it to actually be executable. I even tried renaming it like was discussed in https://github.com/Dfam-consortium/RepeatModeler/issues/20 as using TRF for RepeatMasker is my end goal. Would appreciate any help or guidance.

My code:

git clone https://github.com/Benson-Genomics-Lab/TRF.git successfully downloads and shows up as TRF in my programs list cd TRF mkdir build cd build ../configure full output below checking build system type... x86_64-pc-linux-gnu checking host system type... x86_64-pc-linux-gnu checking target system type... x86_64-pc-linux-gnu checking for a BSD-compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for a thread-safe mkdir -p... /bin/mkdir -p checking for gawk... gawk checking whether make sets $(MAKE)... yes checking whether make supports nested variables... yes checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... 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 whether gcc understands -c and -o together... yes checking whether make supports the include directive... yes (GNU style) checking dependency style of gcc... gcc3 checking for ranlib... ranlib checking whether ln -s works... yes checking how to run the C preprocessor... gcc -E checking for grep that handles long lines and -e... /bin/grep checking for egrep... /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 limits.h usability... yes checking limits.h presence... yes checking for limits.h... yes checking stddef.h usability... yes checking stddef.h presence... yes checking for stddef.h... yes checking for stdlib.h... (cached) yes checking for string.h... (cached) yes checking for size_t... yes checking for stdlib.h... (cached) yes checking for GNU libc compatible malloc... yes checking for stdlib.h... (cached) yes checking for GNU libc compatible realloc... yes checking for library containing floor... -lm checking for sqrt... yes checking for memset... yes checking for strchr... yes checking for strerror... yes checking for strstr... yes checking for strtol... yes checking that generated files are newer than configure... done configure: creating ./config.status config.status: creating Makefile config.status: creating src/Makefile config.status: creating config.h config.status: executing depfiles commands continuing on with the installation instructions make full output below CDPATH="${ZSH_VERSION+.}:" && cd .. && /bin/bash /home/rbehm/Programs/TRF/missing aclocal-1.16 cd .. && /bin/bash /home/rbehm/Programs/TRF/missing automake-1.16 --gnu CDPATH="${ZSH_VERSION+.}:" && cd .. && /bin/bash /home/rbehm/Programs/TRF/missing autoconf /bin/bash ./config.status --recheck running CONFIG_SHELL=/bin/bash /bin/bash ../configure --no-create --no-recursion checking build system type... x86_64-pc-linux-gnu checking host system type... x86_64-pc-linux-gnu checking target system type... x86_64-pc-linux-gnu checking for a BSD-compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for a thread-safe mkdir -p... /bin/mkdir -p checking for gawk... gawk checking whether make sets $(MAKE)... yes checking whether make supports nested variables... yes checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... 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 whether gcc understands -c and -o together... yes checking whether make supports the include directive... yes (GNU style) checking dependency style of gcc... gcc3 checking for ranlib... ranlib checking whether ln -s works... yes checking how to run the C preprocessor... gcc -E checking for grep that handles long lines and -e... /bin/grep checking for egrep... /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 limits.h usability... yes checking limits.h presence... yes checking for limits.h... yes checking stddef.h usability... yes checking stddef.h presence... yes checking for stddef.h... yes checking for stdlib.h... (cached) yes checking for string.h... (cached) yes checking for size_t... yes checking for stdlib.h... (cached) yes checking for GNU libc compatible malloc... yes checking for stdlib.h... (cached) yes checking for GNU libc compatible realloc... yes checking for library containing floor... -lm checking for sqrt... yes checking for memset... yes checking for strchr... yes checking for strerror... yes checking for strstr... yes checking for strtol... yes checking that generated files are newer than configure... done configure: creating ./config.status /bin/bash ./config.status config.status: creating Makefile config.status: creating src/Makefile config.status: creating config.h config.status: config.h is unchanged config.status: executing depfiles commands (CDPATH="${ZSH_VERSION+.}:" && cd .. && /bin/bash /home/rbehm/Programs/TRF/missing autoheader) rm -f stamp-h1 touch ../config.h.in cd . && /bin/bash ./config.status config.h config.status: creating config.h config.status: config.h is unchanged make all-recursive make[1]: Entering directory '/home/rbehm/Programs/TRF/build' Making all in src make[2]: Entering directory '/home/rbehm/Programs/TRF/build/src' gcc -DHAVE_CONFIG_H -I. -I../../src -I.. -fno-align-functions -fno-align-loops -g -O2 -MT trf-trf.o -MD -MP -MF .deps/trf-trf.Tpo -c -o trf-trf.o test -f 'trf.c' || echo '../../src/'trf.c In file included from ../../src/trfrun.h:94, from ../../src/trf.c:34: ../../src/trfclean.h: In function 'GetList': ../../src/trfclean.h:171:41: warning: ignoring return value of 'fgets', declared with attribute warn_unused_result [-Wunused-result] 171 | for (counter =0; counter<9; counter++) fgets(hsequence, 255, fp); | ^~~~~~~~~ ../../src/trfclean.h:174:41: warning: ignoring return value of 'fgets', declared with attribute warn_unused_result [-Wunused-result] 174 | for (counter =0; counter<3; counter++) fgets(hparameters, 255, fp); | ^~~~~~~ ../../src/trfclean.h: In function 'CleanAlignments': ../../src/trfclean.h:522:4: warning: ignoring return value of 'fgets', declared with attribute warn_unused_result [-Wunused-result] 522 | fgets(string2, 260, al_fp); | ^~~~~~ ../../src/trfclean.h:523:4: warning: ignoring return value of 'fgets', declared with attribute warn_unused_result [-Wunused-result] 523 | fgets(string3, 260, al_fp); | ^~~~~~ ../../src/trfclean.h:541:4: warning: ignoring return value of 'fgets', declared with attribute warn_unused_result [-Wunused-result] 541 | fgets(string2, 260, al_fp); | ^~~~~~ ../../src/trfclean.h: In function 'BreakAlignments': ../../src/trfclean.h:606:3: warning: ignoring return value of 'fgets', declared with attribute warn_unused_result [-Wunused-result] 606 | fgets( headlns[i], 200, al_fp); | ^~~~~~~~~~ ../../src/trfclean.h:632:4: warning: ignoring return value of 'fgets', declared with attribute warn_unused_result [-Wunused-result] 632 | fgets(buffer, 200, al_fp); | ^~~~~~~~~ In file included from ../../src/trf.c:34: ../../src/trfrun.h: In function 'TRF': ../../src/trfrun.h:727:25: warning: '%s' directive writing up to 259 bytes into a region of size between 0 and 259 [-Wformat-overflow=] 727 | sprintf(htmlstring,"%s.%s.html",paramset.outputprefix,paramstring); | ^~ ~~~ In file included from /usr/include/stdio.h:867, from ../../src/trf.c:28: /usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: 'builtin___sprintf_chk' output between 7 and 525 bytes into a destination of size 260 36 | return builtin_sprintf_chk (s, USE_FORTIFY_LEVEL - 1, | ^~~~~~~~~~~~~~ 37 | bos (s), fmt, va_arg_pack ()); | ~~~~~~~~~ In file included from ../../src/trf.c:34: ../../src/trfrun.h:728:25: warning: '%s' directive writing up to 259 bytes into a region of size between 0 and 259 [-Wformat-overflow=] 728 | sprintf(txtstring ,"%s.%s.txt.html",paramset.outputprefix,paramstring); | ^~ ~~~ In file included from /usr/include/stdio.h:867, from ../../src/trf.c:28: /usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: '_builtinsprintf_chk' output between 11 and 529 bytes into a destination of size 260 36 | return builtin___sprintf_chk (s, USE_FORTIFY_LEVEL - 1, | ^~~~~~~~~~~~~~ 37 | bos (s), fmt, va_arg_pack ()); | ~~~~~~~~~ In file included from ../../src/trf.c:34: ../../src/trfrun.h:729:25: warning: '%s' directive writing up to 259 bytes into a region of size between 0 and 259 [-Wformat-overflow=] 729 | sprintf(datstring ,"%s.%s.dat",paramset.outputprefix,paramstring); | ^~ ~~~ In file included from /usr/include/stdio.h:867, from ../../src/trf.c:28: /usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: '_builtinsprintf_chk' output between 6 and 524 bytes into a destination of size 260 36 | return builtin___sprintf_chk (s, USE_FORTIFY_LEVEL - 1, | ^~~~~~~~~~~~~~ 37 | bos (s), fmt, va_arg_pack ()); | ~~~~~~~~~ In file included from ../../src/trf.c:34: ../../src/trfrun.h:730:25: warning: '%s' directive writing up to 259 bytes into a region of size between 0 and 259 [-Wformat-overflow=] 730 | sprintf(maskstring,"%s.%s.mask",paramset.outputprefix,paramstring); | ^~ ~~~ In file included from /usr/include/stdio.h:867, from ../../src/trf.c:28: /usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: '_builtinsprintf_chk' output between 7 and 525 bytes into a destination of size 260 36 | return builtin___sprintf_chk (s, USE_FORTIFY_LEVEL - 1, | ^~~~~~~~~~~~~~ 37 | bos (s), fmt, va_arg_pack ()); | ~~~~~~~~~ In file included from ../../src/trf.c:34: ../../src/trfrun.h: In function 'TRFControlRoutine': ../../src/trfrun.h:342:20: warning: '%s' directive writing up to 259 bytes into a region of size between 0 and 259 [-Wformat-overflow=] 342 | sprintf(desth,"%s.%s.summary.html",prefix,paramstring); | ^~ ~~~ In file included from /usr/include/stdio.h:867, from ../../src/trf.c:28: /usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: '_builtinsprintf_chk' output between 15 and 533 bytes into a destination of size 260 36 | return builtin___sprintf_chk (s, USE_FORTIFY_LEVEL - 1, | ^~~~~~~~~~~~~~ 37 | bos (s), fmt, va_arg_pack ()); | ~~~~~~~~~ In file included from ../../src/trf.c:34: ../../src/trfrun.h:355:21: warning: '%s' directive writing up to 259 bytes into a region of size between 0 and 259 [-Wformat-overflow=] 355 | sprintf(destm,"%s.%s.mask",prefix,paramstring); | ^~ ~~~ In file included from /usr/include/stdio.h:867, from ../../src/trf.c:28: /usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: '_builtinsprintf_chk' output between 7 and 525 bytes into a destination of size 260 36 | return builtin___sprintf_chk (s, USE_FORTIFY_LEVEL - 1, | ^~~~~~~~~~~~~~ 37 | bos (s), fmt, va_arg_pack ()); | ~~~~~~~~~ In file included from ../../src/trf.c:34: ../../src/trfrun.h:369:22: warning: '%s' directive writing up to 259 bytes into a region of size between 0 and 259 [-Wformat-overflow=] 369 | sprintf(destd,"%s.%s.dat",prefix,paramstring); | ^~ ~~~ In file included from /usr/include/stdio.h:867, from ../../src/trf.c:28: /usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: '_builtinsprintf_chk' output between 6 and 524 bytes into a destination of size 260 36 | return builtin___sprintf_chk (s, USE_FORTIFY_LEVEL - 1, | ^~~~~~~~~~~~~~ 37 | bos (s), fmt, va_arg_pack ()); | ~~~~~~~~~ In file included from ../../src/trf.c:34: ../../src/trfrun.h:420:20: warning: '.s' directive writing 2 bytes into a region of size between 1 and 260 [-Wformat-overflow=] 420 | sprintf(input,"%s.s%d",prefix,i); | ^~ ../../src/trfrun.h:420:17: note: directive argument in the range [1, 2147483647] 420 | sprintf(input,"%s.s%d",prefix,i); | ^~~~ In file included from /usr/include/stdio.h:867, from ../../src/trf.c:28: /usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: '_builtinsprintf_chk' output between 4 and 272 bytes into a destination of size 260 36 | return builtin___sprintf_chk (s, USE_FORTIFY_LEVEL - 1, | ^~~~~~~~~~~~~~ 37 | bos (s), fmt, va_arg_pack ()); | ~~~~~~~~~ In file included from ../../src/trf.c:34: ../../src/trfrun.h:512:21: warning: '%s' directive writing up to 259 bytes into a region of size between 0 and 259 [-Wformat-overflow=] 512 | sprintf(outh,"%s.%s.1.html",input,paramstring); | ^~ ~~~ In file included from /usr/include/stdio.h:867, from ../../src/trf.c:28: /usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: '_builtinsprintf_chk' output between 9 and 527 bytes into a destination of size 260 36 | return builtin___sprintf_chk (s, USE_FORTIFY_LEVEL - 1, | ^~~~~~~~~~~~~~ 37 | bos (s), fmt, va_arg_pack ()); | ~~~~~~~~~ In file included from ../../src/trf.c:34: ../../src/trfrun.h:535:26: warning: '.s' directive writing 2 bytes into a region of size between 1 and 260 [-Wformat-overflow=] 535 | sprintf(maskstring,"%s.s%d.%s.mask",prefix,i,paramstring); | ^~ ../../src/trfrun.h:535:23: note: directive argument in the range [1, 2147483647] 535 | sprintf(maskstring,"%s.s%d.%s.mask",prefix,i,paramstring); | ^~~~ In file included from /usr/include/stdio.h:867, from ../../src/trf.c:28: /usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: '_builtinsprintf_chk' output between 10 and 537 bytes into a destination of size 260 36 | return builtin___sprintf_chk (s, USE_FORTIFY_LEVEL - 1, | ^~~~~~~~~~~~~~ 37 | bos (s), fmt, va_arg_pack ()); | ~~~~~~~~~ In file included from ../../src/trf.c:34: ../../src/trfrun.h:544:20: warning: '.s' directive writing 2 bytes into a region of size between 1 and 260 [-Wformat-overflow=] 544 | sprintf(outm,"%s.s%d.%s.mask",prefix,i,paramstring); | ^~ ../../src/trfrun.h:544:17: note: directive argument in the range [1, 2147483647] 544 | sprintf(outm,"%s.s%d.%s.mask",prefix,i,paramstring); | ^~~~ In file included from /usr/include/stdio.h:867, from ../../src/trf.c:28: /usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: '_builtinsprintf_chk' output between 10 and 537 bytes into a destination of size 260 36 | return builtin___sprintf_chk (s, USE_FORTIFY_LEVEL - 1, | ^~~~~~~~~~~~~~ 37 | bos (s), fmt, va_arg_pack ()); | ~~~~~~~~~ In file included from ../../src/trf.c:34: ../../src/trfrun.h:308:27: warning: '%s' directive writing up to 259 bytes into a region of size between 0 and 259 [-Wformat-overflow=] 308 | sprintf(maskstring,"%s.%s.mask",paramset.outputprefix,paramstring); | ^~ ~~~ In file included from /usr/include/stdio.h:867, from ../../src/trf.c:28: /usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: '_builtinsprintf_chk' output between 7 and 525 bytes into a destination of size 260 36 | return builtin___sprintf_chk (s, USE_FORTIFY_LEVEL - 1, | ^~~~~~~~~~~~~~ 37 | bos (s), fmt, va_arg_pack ()); | ~~~~~~~~~ In file included from ../../src/trf.c:34: ../../src/trfrun.h:220:44: warning: '%s' directive writing up to 259 bytes into a region of size between 0 and 259 [-Wformat-overflow=] 220 | sprintf(destd,"%s.%s.dat",prefix,paramstring); | ^~ ~~~ In file included from /usr/include/stdio.h:867, from ../../src/trf.c:28: /usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: '_builtinsprintf_chk' output between 6 and 524 bytes into a destination of size 260 36 | return builtin___sprintf_chk (s, USE_FORTIFY_LEVEL - 1, | ^~~~~~~~~~~~~~ 37 | bos (s), fmt, va_arg_pack ()); | ~~~~~~~~~ In file included from ../../src/trf.c:34: ../../src/trfrun.h:308:27: warning: '%s' directive writing up to 259 bytes into a region of size between 0 and 259 [-Wformat-overflow=] 308 | sprintf(maskstring,"%s.%s.mask",paramset.outputprefix,paramstring); | ^~ ~~~ In file included from /usr/include/stdio.h:867, from ../../src/trf.c:28: /usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: '_builtinsprintf_chk' output between 7 and 525 bytes into a destination of size 260 36 | return builtin___sprintf_chk (s, USE_FORTIFY_LEVEL - 1, | ^~~~~~~~~~~~~~ 37 | bos (s), fmt, __va_arg_pack ()); | ~~~~~~~~~ mv -f .deps/trf-trf.Tpo .deps/trf-trf.Po gcc -fno-align-functions -fno-align-loops -g -O2 -o trf trf-trf.o -lm make[2]: Leaving directory '/home/rbehm/Programs/TRF/build/src' make[2]: Entering directory '/home/rbehm/Programs/TRF/build' make[2]: Leaving directory '/home/rbehm/Programs/TRF/build' make[1]: Leaving directory '/home/rbehm/Programs/TRF/build' now I want to test the installation to see if it all worked using the samples provided trf test_seqs.fasta 2 5 7 80 10 50 2000 -l 10 but I get an error! Command 'trf' not found, did you mean: command 'tlf' from deb tlf (1.4.0-2) command 'tjf' from deb pvm-examples (3.4.6-2build2) command 'trs' from deb konwert (1.8-13build1) command 'tr' from deb coreutils (8.30-3ubuntu2) command 'tf' from deb tf (1:4.0s1-20build1) command 'tf' from deb tf5 (5.0beta8-7) command 'erf' from deb xoreos-tools (0.0.5-1build4) command 'trn' from deb trn4 (4.0-test77-12) Try: apt install

It doesn't matter which directory I run this line in TRF, TRF/build, TRF/build/src I get the same error. Please help!

yzhernand commented 1 year ago

Hi. Did you run sudo make install before running those commands? It looks like your shell cannot find TRF in its path.

rnbehm commented 1 year ago

Hi. Did you run sudo make install before running those commands? It looks like your shell cannot find TRF in its path.

I unfortunately do not have sudo permissions

yzhernand commented 1 year ago

I see. Then you should copy the src/trf binary into either $HOME/bin or $HOME/.local/bin, whichever one exists and is in your PATH. If neither exists, create the latter, add it to your path in what ever file your shell uses for configuration, and then reload your shell.

eg, for zsh modify .zshrc so that it has a line like:

path=($HOME/.local/bin $path)

then close/reopen the zsh instance.