I'am trying to undrestand the build process of openwrt. basically i'am adding traces using $(warning), commenting some instructions and so on.
At some point i run make world and face an error. My problem is that i forget in which files exactly i made changes.
This is make error output after the command make -d world :
Reading makefile `tp-link.mk' (search path) (no ~ expansion)...
Reading makefile `ubnt.mk' (search path) (no ~ expansion)...
Reading makefile `generic.mk' (search path) (no ~ expansion)...
Reading makefile `legacy.mk' (search path) (no ~ expansion)...
Makefile:102: *** commands commence before first target. Stop.
Reaping losing child 0x008a0f20 PID 3213
make[5]: *** [image-prereq] Error 2
Removing child 0x008a0f20 PID 3213 from chain.
Reaping losing child 0x0257c930 PID 3210
make[4]: *** [prereq] Error 2
Removing child 0x0257c930 PID 3210 from chain.
Reaping losing child 0x01196730 PID 3207
make[3]: *** [target/linux/prereq] Error 2
Removing child 0x01196730 PID 3207 from chain.
Reaping losing child 0x01432210 PID 3194
make[2]: *** [/home/user/Bureau/Workspace/arduino/openwrt-yun_2/openwrt/staging_dir/target-mips_34kc_musl-1.1.15/stamp/.target_prereq] Error 2
Removing child 0x01432210 PID 3194 from chain.
Reaping losing child 0x01cb58c0 PID 3189
make[1]: *** [prereq] Error 2
Removing child 0x01cb58c0 PID 3189 from chain.
Récupération du statut de sortie du processus fils 0x0167e4a0 PID 3074
make: *** [world] Erreur 2
Suppression du processus fils 0x0167e4a0 PID 3074 de la chaîne.
what i undrestand from this output is that make is complaining about an error on line 102 when trying to read legacy.mk. I'am sure that i didn't make any change on this file.
My question:
How can we use make debug option to know from which Makefile the problem come ?
Problem resolved: by mistake i have replaced a 2 space by a tab in the file image.mk line 605. The make error message was really not helpful.
How i find the mistake: The most obvious solution git checkout ,then meld the modified files.
Related
I'm having some trouble using ABySS to assemble reads downloaded from the NCBI SRA.
The command I've used is:
abyss-pe name=SRR530529_1 k=27 in=/home/bilalm/H_glaber_quality_filtering/AfterQC/good_reads/SRR530529.good.fq
But the assembly process had stopped with an error message ' Abyss-fixmate: error: all reads are mateless. '
The tail of the error message is:
Building the Burrows-Wheeler transform...
Building the character occurrence table...
Mateless 193637763 100%
Unaligned 0
Singleton 0
FR 0
RF 0
FF 0
Different 0
Total 193637763
abyss-fixmate: error: All reads are mateless. This can happen when first and second read IDs do not match.
error: `SRR530529-3.hist': No such file or directory
/usr/bin/abyss-pe:561: recipe for target 'SRR530529-3.dist' failed
make: *** [SRR530529-3.dist] Error 1
make: *** Deleting file 'SRR530529-3.dist'
The ABySS version: 2.0.1
The fastq file size is: 52G
What has happened? What does mateless mean? My intentions were to clean the data and then assemble the naked mole rat genome using 4 fastq reads (SRR530529, SRR530530, SRR530531 & SRR530532) which I have downloaded from the NCBI SRA.
Cheers, Billy.
You are using the abyss program to assemble paired-end reads, but you are feeding it only one file. If you have paired-end reads, each pair must have the same name so they can be recognized as a pair. Normally you would have the forward and reverse reads in two separated files, and would feed them like:
abyss-pe name=SRR530529_1 k=27 in='reads1.fa reads2.fa'
If you have single reads (mateless), then I'm not sure abyss will work, but you can try this:
abyss-pe name=SRR530529_1 k=27 se=/home/bilalm/H_glaber_quality_filtering/AfterQC/good_reads/SRR530529.good.fq
I have got the source files from insight-weekly-CVS-7.0.50-20091130. I have got the following errors. Thanks for your help.
config.status: executing bfd_stdint.h commands ./config.status: line 2602: cmp: command not found
config.status: executing default commands
mingw32-make[3]: Nothing to be done for 'info'.
mingw32-make[3]: Leaving directory 'C:/insight-weekly-CVS-7.0.50-20091130/src/bfd/po'
mingw32-make[3]: Entering directory 'C:/insight-weekly-CVS-7.0.50-20091130/src/bfd'
mingw32-make[3]: Nothing to be done for 'info-am'.
mingw32-make[3]: Leaving directory 'C:/insight-weekly-CVS-7.0.50-20091130/src/bfd'
mingw32-make[2]: *** [Makefile:1546: info-recursive] Error 1
mingw32-make[2]: Leaving directory 'C:/insight-weekly-CVS-7.0.50-20091130/src/bfd'## Heading ##
mingw32-make[1]: *** [Makefile:3333: all-bfd] Error 2
mingw32-make[1]: Leaving directory 'C:/insight-weekly-//CVS-7.0.50-20091130/src'
mingw32-make: *** [Makefile:854: all] Error 2
I have a python script that process files in a directory on Linux Mint. Part of the code is like the following:
path_to_dir = "/home/user/Im a folder with libs to install/"
if os.path.isdir(path_to_dir):
print "it can locate the directory"
os.chdir(path_to_dir) # everything ok here :D
subprocess.call(['./configure'], shell = True)
subprocess.call(['make'], shell = True)
subprocess.call(['make install'], shell = True) # problem happens here
When executing subprocess.call(['make install'], shell = True) it throws this error:
/bin/bash: /home/user/Im: No such file or directory
make[3]: *** [install-libLTLIBRARIES] Error 127
make[2]: *** [install-am] Error 2
make[1]: *** [install-recursive] Error 1
make: *** [install-recursive] Error 1
How can I deal with spaces in paths when executing subprocess.call(['make install'], shell = True)? (I'm using Python 2.7)
Edit: I found out the source of the errors: the Makefile of the libraries I'm using (downloaded from somewhere on Internet) don't support spaces in the path.
I tested the answer given here using this code in the terminal located in the path "/home/user/Im a folder with libs to install/" and using a root account:
./configure
make
make install /home/user/Im\ a\ folder\ with\ libs\ to\ install/Makefile
It gives me the same error:
/bin/bash: /home/user/Im: No such file or directory
[install-libLTLIBRARIES] Error 127
make[3]: se sale del directorio «/home/user/Im a folder with libs to install/»
make[2]: *** [install-am] Error 2
make[2]: se sale del directorio «/home/user/Im a folder with libs to install/»
make[1]: *** [install-recursive] Error 1
make[1]: se sale del directorio «/home/user/Im a folder with libs to install/»
make: *** [install-recursive] Error 1
It can locate the folder, but it seems that, internally, it passes the path to Linux bash with no scape characters.
I'm accepting nafas as the answer because he helped me to locate the source of the problem.
You should be able to replace spaces with their escaped versions.
Try:
path_to_dir = path_to_dir.replace(" ", "\\ ")
Also, think about replacing all special characters like '&', '<', '>', '|', '*', '?', etc. in the string which are not permitted in filename and must be escaped
path_to_dir = path_to_dir.replace(" ", "\\ ").replace("?", "\\?").replace("&", "\\&").replace("(", "\\(").replace(")", "\\)").replace("*", "\\*").replace("<", "\\<").replace(">", "\\>")
skip the spaces using \
e.g. :
Im\ a\ folder\ with\ libs\ to\ install
I have clone the latest linux source from git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
And compile this kernel using (make O=/usr/local/kernel).
But when i install the kernel the following error getting,
# make O=/usr/local/kernel modules_install install
make[1]: Entering directory `/usr/local/kernel'
rm: invalid option -- '0'
Try 'rm --help' for more information.
make[1]: *** [_modinst_] Error 1
make: *** [sub-make] Error 2
I faced the same issue today (24/1/20) and after a bit of searching, I decided to remove the # in front of each line in modinst target in Makefile. The problem was immediately visible to me. If you add space in extra version, the space will appear in your folder name. So, if you write extra version as
EXTRAVERSION= -test[un-noticed-space-here]
Your module folder name will also have that space. To avoid it, I tried the following
Made sure that there are no spaces at the end of version lines in Makefile
Did "make kernelversion" and made sure that it is devoid of any space character
Did a
echo -n `make kernelversion`| wc
and reconfirmed above point by comparing wc output and the count of characters from previous step
I'm trying to build trace-cmd.git from source; the worst is, I had already built this once on this same machine, succesfully; however didn't keep any notes, and cannot tell what could have happened in the meantime.
So now I'm trying to rebuild, and I get the dreaded:
trace-cmd$ make
make: *** No rule to make target `/media/disk/trace-cmd/event-parse.c', needed by `event-parse.o'. Stop.
Ok, let's see what the debug says:
trace-cmd$ make -d
...
Successfully remade target file `trace_python_dir'.
Pruning file `tc_version.h'.
Considering target file `libparsevent.a'.
Considering target file `event-parse.o'.
Pruning file `/media/disk/src/trace-cmd/event-parse.c'. ## THIS EXISTS!
Pruning file `.event-parse.d'.
Considering target file `/media/disk/trace-cmd/event-parse.c'. ## THIS DOESN'T???
File `/media/disk/trace-cmd/event-parse.c' does not exist.
...
Trying pattern rule with stem `event-parse.w'.
Trying implicit prerequisite `/media/disk/trace-cmd/SCCS/s.event-parse.w'.
Trying pattern rule with stem `event-parse'.
Rejecting impossible implicit prerequisite `/media/disk/trace-cmd/event-parse.w'.
No implicit rule found for `/media/disk/trace-cmd/event-parse.c'.
Finished prerequisites of target file `/media/disk/trace-cmd/event-parse.c'.
Must remake target `/media/disk/trace-cmd/event-parse.c'.
make: *** No rule to make target `/media/disk/trace-cmd/event-parse.c', needed by `event-parse.o'. Stop.
OK, what is going on? Of course the actual file exists:
trace-cmd$ ls -la /media/disk/src/trace-cmd/event-parse.c
-rw-r--r-- 1 user user 121563 2013-03-20 19:03 /media/disk/src/trace-cmd/event-parse.c
... but this is /media/disk/src/trace-cmd/event-parse.c!! And:
make already found it once;
yet make decided to, for some reason, drop the /src/ from the path,
... and that file obviously doesn't exist:
trace-cmd$ ls /media/disk/trace-cmd/event-parse.c
ls: cannot access /media/disk/trace-cmd/event-parse.c: No such file or directory
Can someone explain me, for what possible reason could make decide to drop a part of the path, such that it cannot find a file, that it originally had a correct reference to?
Got it - thought I'd focus on that .event-parse.d file:
trace-cmd$ head -n 4 .event-parse.d
event-parse.o: /media/disk/trace-cmd/event-parse.c \
/usr/include/stdio.h /usr/include/features.h /usr/include/bits/predefs.h \
/usr/include/sys/cdefs.h /usr/include/bits/wordsize.h \
/usr/include/gnu/stubs.h /usr/include/gnu/stubs-32.h \
... and indeed, that is the wrong path there... What happens if I delete this .d file?
trace-cmd$ rm .event-parse.d
trace-cmd$ make
COMPILE FPIC event-parse.o
make: *** No rule to make target `/media/disk/trace-cmd/trace-seq.c', needed by `trace-seq.o'. Stop.
Oh, my. There must be more of them:
trace-cmd$ ls .*.d
.event-parse.d .plugin_kmem.d .trace-filter.d .trace-options.d .trace-seq.d
.kbuffer-parse.d .plugin_kvm.d .trace-ftrace.d .trace-output.d .trace-split.d
.kernel-shark.d .plugin_mac80211.d .trace-graph.d .trace-plot-cpu.d .trace-stack.d
...
... and indeed, there are; apparently cached files from previous compilation, where indeed I compiled in another directory. And if I delete them all:
trace-cmd$ rm .*.d
trace-cmd$ make
...
gcc --shared event-parse.o trace-seq.o parse-filter.o parse-utils.o trace-util.o trace-input.o trace-ftrace.o trace-output.o trace-recorder.o trace-restore.o trace-usage.o trace-blk-hack.o kbuffer-parse.o ctracecmd_wrap.o -o ctracecmd.so
Note: to build the gui, type "make gui"
to build man pages, type "make doc"
Well, that seemingly worked; I'm back to being happy again :)
Cheers!