dentearl / mafTools

Bioinformatics tools for dealing with Multiple Alignment Format (MAF) files.
Other
104 stars 32 forks source link

Install error on mafExtractor #13

Closed jwasmuth closed 8 years ago

jwasmuth commented 8 years ago

Hi, I'm trying to install on ubuntu and get an error. The output is pasted below. Any help is very welcome. Thanks James

mafTools$ make Makefile:16: Because dependency ../sonLib is missing mafComparator, mafTransitiveClosure, mafStats, mafToFastaStitcher, mafPairCoverage, mafCoverage will not be built / tested / cleaned. See README.md for information about dependencies. cd lib && make all make[1]: Entering directory /home/james/install/mafTools/lib' gcc -O3 -c -std=c99 -O3 -Wextra -Wall -Werror -pedantic -I ../external/ -I ../inc/ common.c -o common.o.tmp mv common.o.tmp common.o gcc -O3 -c -std=c99 -O3 -Wextra -Wall -Werror -pedantic -I ../external/ -I ../inc/ sharedMaf.c -o sharedMaf.o.tmp -lm mv sharedMaf.o.tmp sharedMaf.o make[1]: Leaving directory/home/james/install/mafTools/lib' cd mafValidator && make all make[1]: Entering directory /home/james/install/mafTools/mafValidator' cp src/mafValidator.py ../bin/mafValidator.py.tmp chmod +x ../bin/mafValidator.py.tmp mv ../bin/mafValidator.py.tmp ../bin/mafValidator.py make[1]: Leaving directory/home/james/install/mafTools/mafValidator' cd mafPositionFinder && make all make[1]: Entering directory /home/james/install/mafTools/mafPositionFinder' cc -c -o src/buildVersion.o src/buildVersion.c mkdir -p ../bin/ gcc -std=c99 -O3 -Wall -Werror --pedantic -funroll-loops -DNDEBUG -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes -I ../../sonLib/lib -I ../inc -I ../external -O3 src/mafPositionFinder.c ../lib/common.o ../lib/sharedMaf.o ../external/CuTest.a src/buildVersion.o -o ../bin/mafPositionFinder.tmp -lm mv ../bin/mafPositionFinder.tmp ../bin/mafPositionFinder make[1]: Leaving directory/home/james/install/mafTools/mafPositionFinder' cd mafExtractor && make all make[1]: Entering directory /home/james/install/mafTools/mafExtractor' gcc -std=c99 -O3 -c -O3 -Wall -Werror --pedantic -funroll-loops -DNDEBUG -Wshadow -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes -I ../../sonLib/lib -I ../inc -I ../external src/mafExtractorAPI.c -o src/mafExtractorAPI.o.tmp -lm src/mafExtractorAPI.c: In function ‘checkBlock’: src/mafExtractorAPI.c:423:17: error: variable ‘dummy’ set but not used [-Werror=unused-but-set-variable] mafBlock_t *dummy = NULL; ^ cc1: all warnings being treated as errors make[1]: *** [src/mafExtractorAPI.o] Error 1 make[1]: Leaving directory/home/james/install/mafTools/mafExtractor' make: *\ [mafExtractor.all] Error 2

atrigila commented 8 years ago

Hi, I am having a similar issue

make
cd lib && make all
make[1]: entering directory «/home/ana/Descargas/mafTools/mafTools-master/lib»
make[1]: Nothing to be done for «all».
make[1]: leaving directory «/home/ana/Descargas/mafTools/mafTools-master/lib»
cd mafComparator && make all
make[1]: entering directory «/home/ana/Descargas/mafTools/mafTools-master/mafComparator»
fatal: ambiguous argument 'HEAD': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
Traceback (most recent call last):
  File "../lib/createVersionSources.py", line 93, in <module>
    main()
  File "../lib/createVersionSources.py", line 87, in main
    buildSha = getSha()
  File "../lib/createVersionSources.py", line 56, in getSha
    return runCommand([GIT, 'rev-parse', 'HEAD']).strip()
  File "../lib/createVersionSources.py", line 44, in runCommand
    mtt.handleReturnCode(p.returncode, cmd)
  File "/home/ana/Descargas/mafTools/mafTools-master/lib/mafToolsTest.py", line 117, in handleReturnCode
    '%s retcode:%d' %(' '.join(cmd), retcode))
RuntimeError: Experienced an error while trying to execute: /usr/bin/git rev-parse HEAD retcode:128
make[1]: *** [src/buildVersion.c] Error 1
make[1]: leaving directory «/home/ana/Descargas/mafTools/mafTools-master/mafComparator»
make: *** [mafComparator.all] Error 2

I appreciate your feedback. Thanks!

dentearl commented 8 years ago

@anabellat I think your issue is different, it looks like you have an install of mafTools that isn't a git repo (not sure how). The give-away for that is both

fatal: ambiguous argument 'HEAD': unknown revision or path not in the working tree.

and

RuntimeError: Experienced an error while trying to execute: /usr/bin/git rev-parse HEAD retcode:128

As the retcode 128 is what git throws when it finds itself operating outside a repo. A solution for this would be to make sure you've cloned your mafTools repo from github.

dentearl commented 8 years ago

@jwasmuth It looks like you're hitting an issue due to more stringent checks in later versions of gcc. From the message,

src/mafExtractorAPI.c -o src/mafExtractorAPI.o.tmp -lm src/mafExtractorAPI.c: In function ‘checkBlock’: src/mafExtractorAPI.c:423:17: error: variable ‘dummy’ set but not used [-Werror=unused-but-set-variable] mafBlock_t *dummy = NULL;

It appears simply removing that line could clean up the error. It make take me a day or two to eek out try this, test it and update. If you're in a hurry you could try it on your install and report back here / send a pull request :)

dentearl commented 8 years ago

Changed default flags into gcc should correct @jwasmuth issue (if it doesn't please re-open this issue).

@anabellat if your issue is not resolved by my earlier comment please open a New Issue and I'll follow up with you there.