How to build Stanford Dune OS? - operating-system

I am trying to build the Standford Dune OS with:
git clone http://dune.scs.stanford.edu/dune.git
make -C kern
but I get the following errors:
make[1]: Entering directory `/home/think/Desktop/build/dune/kern'
mkdir -p /home/think/Desktop/build/dune/kern/tmp/.tmp_versions
make -C /lib/modules/3.11.0-12-generic/build M=/home/think/Desktop/build/dune/kern MODVERDIR=/home/think/Desktop/build/dune/kern/tmp/.tmp_versions modules
make[2]: Entering directory `/usr/src/linux-headers-3.11.0-12-generic'
CC [M] /home/think/Desktop/build/dune/kern/vmx.o
/home/think/Desktop/build/dune/kern/vmx.c: In function ‘vmx_setup_initial_guest_state’:
/home/think/Desktop/build/dune/kern/vmx.c:793:10: error: ‘X86_CR4_RDWRGSFS’ undeclared (first use in this function)
cr4 |= X86_CR4_RDWRGSFS;
^
/home/think/Desktop/build/dune/kern/vmx.c:793:10: note: each undeclared identifier is reported only once for each function it appears in
/home/think/Desktop/build/dune/kern/vmx.c: In function ‘vmx_enable’:
/home/think/Desktop/build/dune/kern/vmx.c:1631:2: error: implicit declaration of function ‘store_gdt’ [-Werror=implicit-function-declaration]
store_gdt(&__get_cpu_var(host_gdt));
^
cc1: some warnings being treated as errors
make[3]: *** [/home/think/Desktop/build/dune/kern/vmx.o] Error 1
make[2]: *** [_module_/home/think/Desktop/build/dune/kern] Error 2
make[2]: Leaving directory `/usr/src/linux-headers-3.11.0-12-generic'
make[1]: *** [modules] Error 2
make[1]: Leaving directory `/home/think/Desktop/build/dune/kern'
make: *** [kern] Error 2
How can I fix this?

downgrade your kernel! I am using 3.2.0. wanted to port dune to 3.14.0 but just didn't have time..

Related

stk11xx driver on raspberry-pi installation error

I have an error in my instalation in my raspberry-pi 3, it's a driver for a web-cam
I took the driver on this page:
https://github.com/hbars/stk11xx-driver
and the manual for this instalation is here:
https://github.com/hbars/stk11xx-driver/blob/master/INSTALL
it's on this line:
make -f Makefile.standalone driver
error:
make -f Makefile.standalone driver
make -C /lib/modules/4.19.66-v7+/build SUBDIRS=/home/pi/stk11xx-2.1.0 modules
make[1]: Entering directory '/usr/src/linux-headers-4.19.66-v7+'
CC [M] /home/pi/stk11xx-2.1.0/stk11xx-usb.o
/home/pi/stk11xx-2.1.0/stk11xx-usb.c: In function 'usb_stk11xx_probe':
/home/pi/stk11xx-2.1.0/stk11xx-usb.c:793:2: error: implicit declaration of function 'init_MUTEX' [-Werror=implicit-function-declaration]
init_MUTEX(&dev->mutex);
^~~~~~~~~~
cc1: some warnings being treated as errors
scripts/Makefile.build:303: recipe for target '/home/pi/stk11xx-2.1.0/stk11xx-usb.o' failed
make[2]: *** [/home/pi/stk11xx-2.1.0/stk11xx-usb.o] Error 1
Makefile:1519: recipe for target '_module_/home/pi/stk11xx-2.1.0' failed
make[1]: *** [_module_/home/pi/stk11xx-2.1.0] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-4.19.66-v7+'
Makefile.standalone:13: recipe for target 'driver' failed
make: *** [driver] Error 2
sorry this is not the good error it's the one:
make -C /lib/modules/4.19.66-v7+/build SUBDIRS=/home/pi/stk11xx-driver modules
make[1]: Entering directory '/usr/src/linux-headers-4.19.66-v7+'
mkdir: cannot create directory '/home/pi/stk11xx-driver/.tmp_versions': Permission denied
/bin/sh: 1: cannot create /home/pi/stk11xx-driver/modules.order: Permission denied
scripts/Makefile.build:462: recipe for target '/home/pi/stk11xx-driver/modules.order' failed
make[2]: *** [/home/pi/stk11xx-driver/modules.order] Error 2
Makefile:1519: recipe for target '_module_/home/pi/stk11xx-driver' failed
make[1]: *** [_module_/home/pi/stk11xx-driver] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-4.19.66-v7+'
Makefile.standalone:13: recipe for target 'driver' failed
make: *** [driver] Error 2
I have resolved my problem I had to put sudo in front of make -f Makefile.standalone driver
but I have an other error:
make -C /lib/modules/4.19.66-v7+/build SUBDIRS= modules
make[1]: Entering directory '/usr/src/linux-headers-4.19.66-v7+'
HOSTCC scripts/basic/fixdep
HOSTCC scripts/kconfig/conf.o
HOSTCC scripts/kconfig/zconf.tab.o
HOSTLD scripts/kconfig/conf
scripts/kconfig/conf --syncconfig Kconfig
make[2]: *** No rule to make target 'arch/arm/tools/syscall.tbl', needed by 'arch/arm/include/generated/uapi/asm/unistd-common.h'. Stop.
arch/arm/Makefile:319: recipe for target 'archheaders' failed
make[1]: *** [archheaders] Error 2
make[1]: Leaving directory '/usr/src/linux-headers-4.19.66-v7+'
Makefile.standalone:13: recipe for target 'driver' failed
make: *** [driver] Error 2
So I have resolved my problem, replacing all PWD whith shell pwd in Makefile.standalonee

configure//make error on Ubuntu Pjsip PJproject

I am trying to extract opus rtp packets and convert them into wav format from the pcap file. In order to do so, I installed pjproject2.6 using the following commands:
cd pjproject2.6/
./configure
make dep && make
After the last command, I ran into the following error:
In file included from /usr/include/c++/7/cmath:47:0,
from /usr/include/c++/7/math.h:36,
from ../../yuv/source/compare.cc:14:
/usr/include/c++/7/bits/std_abs.h: In function ‘constexpr long double std::abs(long double)’:
/usr/include/c++/7/bits/std_abs.h:78:22: error: x87 register return with x87 disabled
abs(long double __x)
^
/home/administrator/pjproject-2.6/build/rules.mak:178: recipe for target 'output/libyuv-x86_64-unknown-linux-gnu/compare.o' failed
make[3]: *** [output/libyuv-x86_64-unknown-linux-gnu/compare.o] Error 1
make[3]: Leaving directory '/home/administrator/pjproject-2.6/third_party/build/yuv'
Makefile:100: recipe for target 'libyuv-x86_64-unknown-linux-gnu.a' failed
make[2]: *** [libyuv-x86_64-unknown-linux-gnu.a] Error 2
make[2]: Leaving directory '/home/administrator/pjproject-2.6/third_party/build/yuv'
Makefile:7: recipe for target 'all' failed
make[1]: *** [all] Error 1
make[1]: Leaving directory '/home/administrator/pjproject-2.6/third_party/build'
Makefile:14: recipe for target 'all' failed
make: *** [all] Error 1
Any suggestions? Thanks in advance!

How to compile static collectd?

I'm trying to compile static collectd:
cd collectd-5.4.1/
./configure --enable-debug --enable-cpu --enable-df --enable-disk --enable-interface --enable-load --enable-memory --enable-processes --enable-rrdtool --enable-snmp --enable-statsd --enable-logfile --disable-shared --with-librrd=/opt/local
make all
after that I see an error:
CC perl_la-perl.lo
perl.c:44:21: error: poisoning existing macro [-Werror]
# pragma GCC poison sprintf
^
1 error generated.
make[3]: *** [perl_la-perl.lo] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all] Error 2
make: *** [all-recursive] Error 1
How to fix that?
A quick fix might be to disable the perl plugin, if you don't need it

slony1-2.2.1 installation error

I am trying to install slony1-2.2.1 in ubuntu 12.04 + postgresql-9.3. The configuration is done but when i am firing "make all" command the following error is shown:
root#administrator:/home/priyatam/Desktop/icons/slony1-2.2.1# make all
make[1]: Entering directory /home/priyatam/Desktop/icons/slony1-2.2.1/src'
make[2]: Entering directory/home/priyatam/Desktop/icons/slony1-2.2.1/src/parsestatements'
./test-scanner < /dev/null > emptytestresult.log
./test-scanner < ./test_sql.sql > test_sql.log`
./test-scanner < ./cstylecomments.sql > cstylecomments.log
make[2]: Leaving directory/home/priyatam/Desktop/icons/slony1-2.2.1/src/parsestatements'
make[2]: Entering directory /home/priyatam/Desktop/icons/slony1-2.2.1/src/slon'
make[2]: Nothing to be done forall'.
make[2]: Leaving directory /home/priyatam/Desktop/icons/slony1-2.2.1/src/slon'
make[2]: Entering directory/home/priyatam/Desktop/icons/slony1-2.2.1/src/slonik'
make[2]: Nothing to be done for all'.
make[2]: Leaving directory/home/priyatam/Desktop/icons/slony1-2.2.1/src/slonik'
make[2]: Entering directory /home/priyatam/Desktop/icons/slony1-2.2.1/src/backend'
gcc -g -O2 -Wall -Wmissing-prototypes -Wmissing-declarations -I../.. -fpic -I/usr/include/postgresql -c -o slony1_funcs.o slony1_funcs.c
slony1_funcs.c:23:23: fatal error: miscadmin.h: No such file or directory
compilation terminated.
make[2]: *** [slony1_funcs.o] Error 1
make[2]: Leaving directory/home/priyatam/Desktop/icons/slony1-2.2.1/src/backend'
make[1]: * [all] Error 2
make[1]: Leaving directory `/home/priyatam/Desktop/icons/slony1-2.2.1/src'
make: * [all] Error 2
please help me out.
A couple of observations before the answer.
Why are you running "make all" as root? It might be required for "make install", but try to avoid running as root otherwise.
Why are you building the source in "Desktop/icons/..."? Don't you think maybe in six months you might want to find it again? Consider putting your source in /usr/local/src or somewhere similar.
OK - the error is pretty clear. File "slony1_funcs.c" on line 23 tries to include "miscadmin.h" and fails. If you had googled "slony postgresql miscadmin.h no such file or directory" then you'd have seen several cases where people had the same problem (and solved it). Consider searching next time.
The problem is that it can't find the source headers for PostgreSQL. Since you're on ubuntu the package will be called something like 'postgresql-server-dev-9.3'.

Gtk3 installation

I'm trying to install gtk+-3.2.3 on Ubuntu natty. This is a fresh Ubuntu install with security updates only. I have not installed any new versions of gtk. I just have gtk2, that Ubuntu comes with. First I installed the following:
sudo apt-get install libffi-dev zlib1g-dev fam libdbus-1-dev libdbus-glib-1-dev gobject-introspection libxext-dev libxrender1-dbg colordiff libcairo2-dev libtiff4-dev libpng12-dev libxft-dev libxi-devel
I have the following folders in: /home/mike/gtk
atk-2.1.5
gdk-pixbuf-2.24.1
glib-2.30.1
gtk+-3.2.3
pango-1.29.1
Then:
cd /home/mike/gtk/glib-2.30.1
./configure && make
rm -rf /home/mike/gtk/include/glib.h /home/mike/gtk/include/gmodule.h (glib INSTALL instructions)
repeat for the other folders except without the rm, in the following order:
atk-2.1.5
gdk-pixbuf-2.24.1
pango-1.29.1
gtk+-3.2.3
Before running ./configure for gtk+-3.2.3 enter this in the terminal:
CPPFLAGS="-I/home/mike/gtk/include"
LDFLAGS="-L/home/mike/gtk/lib"
PKG_CONFIG_PATH="/home/mike/gtk/lib/pkgconfig"
export CPPFLAGS LDFLAGS PKG_CONFIG_PATH
LD_LIBRARY_PATH="/home/mike/gtk/lib"
PATH="/home/mike/gtk/bin:$PATH"
export LD_LIBRARY_PATH PATH
export PKG_CONFIG_PATH="/home/mike/gtk/lib/pkgconfig:$PKG_CONFIG_PATH"
I get the these errors when I run make on gtk+-3.2.3:
gdkwindow-x11.c: In function '_gdk_x11_moveresize_handle_event':
gdkwindow-x11.c:4301:9: error: 'XIEvent' undeclared (first use in this function)
gdkwindow-x11.c:4301:9: note: each undeclared identifier is reported only once for each function it appears in
gdkwindow-x11.c:4301:18: error: 'ev' undeclared (first use in this function)
gdkwindow-x11.c:4301:33: error: expected expression before ')' token
gdkwindow-x11.c:4302:9: error: 'XIDeviceEvent' undeclared (first use in this function)
gdkwindow-x11.c:4302:24: error: 'xev' undeclared (first use in this function)
gdkwindow-x11.c:4302:46: error: expected expression before ')' token
gdkwindow-x11.c:4306:16: error: 'XI_Motion' undeclared (first use in this function)
gdkwindow-x11.c:4308:13: warning: implicit declaration of function '_gdk_x11_device_xi2_translate_state'
gdkwindow-x11.c:4313:16: error: 'XI_ButtonRelease' undeclared (first use in this function)
make[4]: *** [gdkwindow-x11.lo] Error 1
make[4]: Leaving directory `/home/mike/gtk/gtk+-3.2.3/gdk/x11'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/home/mike/gtk/gtk+-3.2.3/gdk'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/home/mike/gtk/gtk+-3.2.3/gdk'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/mike/gtk/gtk+-3.2.3'
make: *** [all] Error 2
You place GTK3's source code in an arbitrary directory (into which you have write permissions). And you run ./configure from there.
You may want to pass the configure scripts (of each package) a common --prefix to override the default of /usr/local/ (this is needed, e.g. with --prefix $HOME/pub, if you cannot write under /usr/ because you don't have root access).