I'm trying to run uvm-systemc on macosx. Link to download: http://accellera.org/images/downloads/drafts-review/uvm-systemc-1.0-alpha1.tar.gz
In the install flow, ../configure works fine, but on make i get this error:
Making all in macros
CCLD libmacros.la
ar: no archive members specified
usage: ar -d [-TLsv] archive file ...
ar -m [-TLsv] archive file ...
ar -m [-abiTLsv] position archive file ...
ar -p [-TLsv] archive [file ...]
ar -q [-cTLsv] archive file ...
ar -r [-cuTLsv] archive file ...
ar -r [-abciuTLsv] position archive file ...
ar -t [-TLsv] archive [file ...]
ar -x [-ouTLsv] archive [file ...]
make[4]: *** [libmacros.la] Error 1
make[3]: *** [all-recursive] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all] Error 2
make: *** [all-recursive] Error 1
I've looked online, and it seems that it is a makefile problem. However the uvm-systemc makefile is way to complex for me to comprehend where the issue could reside. Any ideas on why is this happening?
Thanks
The issue is due to the libtool being executed to create a library file without a cpp file .
The tlm1 directory (and macros directory) do not have any .cpp file , hence there is no need to call the libtool in the respective makefiles.
As the UVM-SystemC for Mac OS is not in the list of tested OS you MAY run a few more issues.
I ran into 3 issues ( including the one mentioned above ). workaround to those are provided below .
The OS version for which the installation was completed.
ProductName: Mac OS X
ProductVersion: 10.11.4
BuildVersion: 15E65
1)
command :
step 1
../configure --with-systemc=[systemC-Base]/systemc-2.3.1
step 2 :
[base]/uvm-systemc-1.0-alpha1/objdir/ make
Error:
Making all in macros
CCLD libmacros.la
ar: no archive members specified
usage: ar -d [-TLsv] archive file ...
ar -m [-TLsv] archive file ...
ar -m [-abiTLsv] position archive file ...
ar -p [-TLsv] archive [file ...]
ar -q [-cTLsv] archive file ...
ar -r [-cuTLsv] archive file ...
ar -r [-abciuTLsv] position archive file ...
ar -t [-TLsv] archive [file ...]
ar -x [-ouTLsv] archive [file ...]
make[4]: *** [libmacros.la] Error 1
make[3]: *** [all-recursive] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all] Error 2
make: [all-recursive] Error 1
Fix :
changes to 2 files
[ objdir - is the run temporary directory for the make script ]
[base]/uvm-systemc-1.0-alpha1/objdir/src/uvmsc/tlm1/Makefile -
comment out the libtool run.
line 314
# $(AM_V_CCLD)$(LINK) $(libtlm1_la_OBJECTS) $(libtlm1_la_LIBADD) $(LIBS)
[base]/uvm-systemc-1.0-alpha1/objdir/src/uvmsc/macros/Makefile
line 311
# $(AM_V_CCLD)$(LINK) $(libmacros_la_OBJECTS) $(libmacros_la_LIBADD) $(LIBS)
OR
[ for this you have to re-run
../configure --with-systemc=[systemC-Base]/systemc-2.3.1
so that it can recreated the
<base>/uvm-systemc-1.0-alpha1/objdir/src/uvmsc/tlm1/Makefile
and the
[base]/uvm-systemc-1.0-alpha1/objdir/src/uvmsc/macros/Makefile ]
comment out the libtool run in the base file.
[base]/uvm-systemc-1.0-alpha1/src/uvmsc/tlm1/Makefile.in
line 314
# $(AM_V_CCLD)$(LINK) $(libtlm1_la_OBJECTS) $(libtlm1_la_LIBADD) $(LIBS)
[base]/uvm-systemc-1.0-alpha1/src/uvmsc/macros/Makefile
line 311
# $(AM_V_CCLD)$(LINK) $(libmacros_la_OBJECTS) $(libmacros_la_LIBADD) $(LIBS)
———————————
2)
Command :
make install
Error :
/bin/sh: ../../../config/install-sh: Permission denied
Fix :
[[base]/uvm-systemc-1.0-alpha1/objdir] chmod +x ../config/install-sh
3)
Command:
make check
Error :
[systemC-base]/systemc-2.3.1/include/tlm_core/tlm_1/tlm_req_rsp/tlm_channels/tlm_req_rsp_channels/tlm_put_get_imp.h:32:3: note: constrained by private inheritance here
private virtual tlm_put_if< PUT_DATA > ,
[systemC-base]/systemc-2.3.1/include/tlm_core/tlm_1/tlm_req_rsp/tlm_channels/tlm_req_rsp_channels/tlm_put_get_imp.h:87:7: error: inherited virtual base class 'tlm_blocking_get_if' has private destructor
class tlm_master_imp :
[systemC-base]/systemc-2.3.1/include/tlm_core/tlm_1/tlm_req_rsp/tlm_channels/tlm_req_rsp_channels/tlm_put_get_imp.h:33:3: note: constrained by private inheritance here
private virtual tlm_get_peek_if< GET_DATA >
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
[systemc-base]/systemc-2.3.1/include/tlm_core/tlm_1/tlm_req_rsp/tlm_channels/tlm_req_rsp_channels/tlm_put_get_imp.h:87:7: error: inherited virtual base class 'tlm_nonblocking_get_if' has private destructor
—————————
Fix :
———————————
This seems like a compiler related issue. MAYBE in some platforms this is okay but it failed for this platform.
To fix this the source file of the systemC installation needs to be updated.
You can update the source file and re-install - gmake install (systemC)
or just update the include file.
[systemC-base]/systemc-2.3.1/src/tlm_core/tlm_1/tlm_req_rsp/tlm_channels/tlm_req_rsp_channels/tlm_put_get_imp.h
[systemC-Base]/obj/ - gmake install
OR
[systemC-base]/systemc-2.3.1/include/tlm_core/tlm_1/tlm_req_rsp/tlm_channels/tlm_req_rsp_channels/tlm_put_get_imp.h
change line 31,32
class tlm_put_get_imp :
private virtual tlm_put_if< PUT_DATA > ,
public virtual tlm_get_peek_if< GET_DATA > // change from private to public - private fails
change line 86,87
class tlm_master_imp :
private tlm_put_get_imp< REQ , RSP > ,
public virtual tlm_master_if< REQ , RSP > // change from private to public - private fails
Related
I am trying to build a Xilinx XDMA driver for Yocto, using their supplied makefile. When I run my recipe the build fails with the following errors:
DEBUG: Executing shell function do_compile
NOTE: make -j 32 KERNEL_SRC=./tmp/work-shared/intel-corei7-64/kernel-source
KERNEL_PATH=./tmp/work-shared/intel-corei7-64/kernel-source
KERNEL_VERSION=5.10.78-intel-pk-standard CC=x86_64-poky-linux-gcc
-fuse-ld=bfd
-fmacro-prefix-map=./tmp/work/intel_corei7_64-poky-linux/xdma-driver-mod/1.0+gitAUTOINC+8d75946900-r0=/usr/src/debug/xdma-driver-mod/1.0+gitAUTOINC+8d75946900-r0
-fdebug-prefix-map=./tmp/work/intel_corei7_64-poky-linux/xdma-driver-mod/1.0+gitAUTOINC+8d75946900-r0=/usr/src/debug/xdma-driver-mod/1.0+gitAUTOINC+8d75946900-r0
-fdebug-prefix-map=./tmp/work/intel_corei7_64-poky-linux/xdma-driver-mod/1.0+gitAUTOINC+8d75946900-r0/recipe-sysroot=
-fdebug-prefix-map=./tmp/work/intel_corei7_64-poky-linux/xdma-driver-mod/1.0+gitAUTOINC+8d75946900-r0/recipe-sysroot-native=
-fdebug-prefix-map=./tmp/work-shared/intel-corei7-64/kernel-source=/usr/src/kernel LD=x86_64-poky-linux-ld.bfd
AR=x86_64-poky-linux-ar
O=./tmp/work-shared/intel-corei7-64/kernel-build-artifacts KBUILD_EXTRA_SYMBOLS=
Makefile:17: XVC_FLAGS: .
make -C /lib/modules/5.13.0-40-generic/build
M=./tmp/work/intel_corei7_64-poky-linux/xdma-driver-mod/1.0+gitAUTOINC+8d75946900-r0/git/linux_driver/xdma modules
make[1]: Entering directory '/usr/src/linux-headers-5.13.0-40-generic'
make[2]: Entering directory './tmp/work-shared/intel-corei7-64/kernel-build-artifacts'
./tmp/work/intel_corei7_64-poky-linux/xdma-driver-mod/1.0+gitAUTOINC+8d75946900-r0/git/linux_driver/xdma/Makefile:17: XVC_FLAGS: .
CC [M] ./tmp/work/intel_corei7_64-poky-linux/xdma-driver-mod/1.0+gitAUTOINC+8d75946900-r0/git/linux_driver/xdma/libxdma.o
CC [M] ./tmp/work/intel_corei7_64-poky-linux/xdma-driver-mod/1.0+gitAUTOINC+8d75946900-r0/git/linux_driver/xdma/xdma_cdev.o
x86_64-poky-linux-gcc: error: missing argument to '-gdwarf-'
CC [M] ./tmp/work/intel_corei7_64-poky-linux/xdma-driver-mod/1.0+gitAUTOINC+8d75946900-r0/git/linux_driver/xdma/cdev_ctrl.o
make[3]: *** [/usr/src/linux-headers-5.13.0-40-generic/scripts/Makefile.build:281: ./tmp/work/intel_corei7_64-poky-linux/xdma-driver-mod/1.0+gitAUTOINC+8d75946900-r0/git/linux_driver/xdma/libxdma.o] Error 1
make[3]: *** Waiting for unfinished jobs....
x86_64-poky-linux-gcc: error: missing argument to '-gdwarf-'
ERROR: oe_runmake failed
WARNING: exit code 1 from a shell command.
I have no idea why this happens as it is not something I have specifically enabled. I have searched through the module.bbclass file but I couldn't see anything obvious. I believe that something needs to be configured such that the -gdwarf- actual ends up being set to a valid value (e.g. -gdwarf-2 or -gdwarf-4 etc.)
A grep through the poky repo for dwarf did not reveal anything neither did a search of /usr/src/linux-headers-5.13.0-40-generic/scripts/.
My bitbake recipe is as follows:
LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://LICENSE;md5=441c1ecbc199a036abf37f3aa47c5f34"
SRC_URI += https://github.com/Xilinx/dma_ip_drivers.git;protocol=ssh;nobranch=1;branch=master"
# Modify these as desired
PV = "1.0+git${SRCPV}"
SRCREV = "8d7594690058dfa828accc02ac81348e416ffe38"
S = "${WORKDIR}/git/xdma/linux-driver/xdma"
RPROVIDES_${PN} += "xdma"
inherit module
EXTRA_OEMAKE_task-install:append = " -C ${STAGING_KERNEL_DIR} M=${S}"
EXTRA_OEMAKE += "KDIR=${STAGING_KERNEL_DIR}"
The makefile is the standard one from GitHub. The driver builds correctly for Ubuntu using make and I can also build the module if I change my recipe such that it does not include inherit module; this change will build the module (xdma.ko) but does to install it in the roofs. I am also not sure if inherit module includes additional functionality which may be rewired.
How to I either:
prevent / disable the -gdwarf flag being generated
configure the recipe that the -gdwarf- resolves to something valid
View the actual command being invoked that is causing the issue.
Attempts to build the xdma.ko module without the inherit module result in an invalid binary being built, i.e. when I try an load the module on the target I get:
insmod xdma.ko
insmod: ERROR: could not insert module xdma.ko: Invalid module format
Which indicates that the module is compiled from the wrong target.
inherit module is required when building kernel modules for Yocto. If it is omitted the build modules is not compatible with the target.
Workaround for the -gdwarf- error was to manually write a new makefile which is compatible with Yocto:
TARGET_MODULE:=xdma
topdir := $(shell cd $(src)/.. && pwd)
EXTRA_CFLAGS := -I$(topdir)/include
SRC := $(shell pwd)
$(TARGET_MODULE)-objs := libxdma.o xdma_cdev.o cdev_ctrl.o cdev_events.o cdev_sgdma.o cdev_xvc.o cdev_bypass.o xdma_mod.o xdma_thread.o
obj-m := $(TARGET_MODULE).o
all :
$(MAKE) -C $(KERNEL_SRC) M=$(SRC)
modules_install:
$(MAKE) -C $(KERNEL_SRC) M=$(SRC) modules_install
clean:
rm -f *.o *~ core .depend .*.cmd *.ko *.mod.c
rm -f Module.markers Module.symvers modules.order
rm -rf .tmp_versions Modules.symvers
This makefile correctly builds the Xilinx XDMA driver for Yocto. I can confirm that the driver works with Kintex-KC705 FPGA development card.
mkdir .build && \
cd .build && \
./../configure --prefix=$HOME/my_octave && \ [1]
make -j2 && \ [2]
make check && \
make install
While running make -j2 I get the error as
error: print: error opening file 'extended.tex'
error: called from print>latex_standalone at line 1029 column 5
__opengl_print__ at line 214 column 5
print at line 759 column 16 plotimages at line 109 column 7
GEN doc/interpreter/gplot.pdfMakefile:27911: recipe for target `'doc/interpreter/extended.pdf' failedmake[2]: *** [doc/interpreter/extended.pdf] Error `1make[2]: *** Waiting for unfinished jobs....make[2]: Leaving directory `'/home/bhanu/octave/.build'Makefile:26305: recipe for target 'all-recursive' failedmake[1]: *** `[all-recursive] Error 1make[1]: Leaving directory '/home/bhanu/octave/.build'Makefile:9916:
recipe for target 'all' failedmake: *** [all] Error 2
Can someone help me solve the error? I am running it on Ubuntu 18.04 system.
Some times the build process tries to rebuild all the documentation.
I am building from the source octave-5.2.0.tar.lz file and
the usual workaround is just
touch AUTHORS BUGS INSTALL.OCTAVE
between configure and the first make in the
build tree.
At the end of build phase I have only two PDFs
./doc/interpreter/octave.pdf
./doc/liboctave/liboctave.pdf
Create file named 'extended.tex' like this:
touch doc/interpreter/extended.tex
You have to do this inside the octave/.build/ directory.
Do this for any errors similar to this in the future. It worked for me this way.
I followed these instructions. Download lmbench3.tar.gz from lmbench3
and Unpack LMbench to create a tree like so:
lmbench/
Results/
doc/
scripts/
src/
And Go to the lmbench directory, and type make results see
But the result is wrong:
7 warnings generated.
gcc -O -DRUSAGE -DHAVE_uint=1 -DHAVE_uint64_t=1 -DHAVE_int64_t=1 -DHAVE_DRAND48 -c getopt.c -o ../bin/i686-apple-darwin15.6.0/getopt.o
gcc -O -DRUSAGE -DHAVE_uint=1 -DHAVE_uint64_t=1 -DHAVE_int64_t=1 -DHAVE_DRAND48 -c lib_sched.c -o ../bin/i686-apple-darwin15.6.0/lib_sched.o
lib_sched.c:94:3: error: non-void function 'handle_scheduler' should return a
value [-Wreturn-type]
return;
^
1 error generated.
make[2]: *** [../bin/i686-apple-darwin15.6.0/lib_sched.o] Error 1
make[1]: *** [lmbench] Error 2
make: *** [build] Error 2
How to solve it?
You can change the statement
return;
into
return 0;
at line 94 of lib_sched.c
Then this file should compile without this error.
I want to use NetBeans IDE 8 to compile my Fortran code.
I have installed NetBeans and MinGW.
The following addresses are added to Environmental Variables:
"C:\MinGW\bin;C:\MinGW\msys\1.0\bin"
After running a simple code like this
" subroutine bar()
print *, 'hello from bar...'
end
"
I receive the following long message:
"/C/MinGW/msys/1.0/bin/make.exe" -f nbproject/Makefile-Debug.mk QMAKE= SUBPROJECTS= .build-conf
make.exe[1]: Entering directory `/c/Users/Behi/Documents/NetBeansProjects/Hello_3'
"/C/MinGW/msys/1.0/bin/make.exe" -f nbproject/Makefile-Debug.mk dist/Debug/MinGW-Windows/hello_3.exe
make.exe[2]: Entering directory `/c/Users/Behi/Documents/NetBeansProjects/Hello_3'
mkdir -p build/Debug/MinGW-Windows
make.exe[2]: mkdir: Command not found
make.exe[2]: *** [build/Debug/MinGW-Windows/bar.o] Error 127
make.exe[2]: Leaving directory `/c/Users/Behi/Documents/NetBeansProjects/Hello_3'
make.exe[1]: *** [.build-conf] Error 2
make.exe[1]: Leaving directory `/c/Users/Behi/Documents/NetBeansProjects/Hello_3'
make.exe": *** [.build-impl] Error 2
BUILD FAILED (exit value 2, total time: 2s)
Can any one give me some suggestions?
I installed OCaml 4.01.0 from http://protz.github.io/ocaml-installer/. I am now trying to build camlp5-6.11. When I run ./configure && make world.opt in cygwin, I get
...
sed -e "s|#VERSION#|6.11|" -e "s|#CAMLP5DIR#|D:\OCaml\lib/camlp5|" META.tpl > META
make[2]: Leaving directory '/cygdrive/d/Downloads/camlp5-6.11/etc'
make[2]: Entering directory '/cygdrive/d/Downloads/camlp5-6.11/top'
ocamlrun.exe ../boot/camlp5r.exe -nolib -I ../boot -mode S -o camlp5_top.ppo camlp5_top.ml
ocamlc.opt -warn-error A -I ../main -I ../boot -I ../ocaml_stuff/4.01.0/utils -I ../ocaml_stuff/4.01.0/parsing -I D:OCamllib/compiler-libs -c -impl camlp5_top.ppo
File "camlp5_top.ml", line 51, characters 14-32:
Error: Unbound module Toploop
../config/Makefile:20: recipe for target 'camlp5_top.cmo' failed
make[2]: *** [camlp5_top.cmo] Error 2
make[2]: Leaving directory '/cygdrive/d/Downloads/camlp5-6.11/top'
Makefile:26: recipe for target 'out' failed
make[1]: *** [out] Error 2
make[1]: Leaving directory '/cygdrive/d/Downloads/camlp5-6.11'
Makefile:141: recipe for target 'world.opt' failed
make: *** [world.opt] Error 2
How do I fix this?
I suspect the Makefile of Camlp5 hasn't been tested on Windows. It probably doesn't deal properly with backslashes: indeed, in your output, I can see D:OCamllib/compiler-libs which leads me to think that the error lies on the Camlp5 side: the path should obviously be D:\OCaml\lib....
Little-known fact about windows: / works as a path separator just as well, so if that's an option, you could probably try to hardcode d:/ocaml/ somewhere in the Makefile as the root dir for your OCaml installation, but you'd also have to fix the Makefile to generate d:/ocaml/lib as the library directory.