[erlang-questions] Problem building OTP on OpenBSD
Björn-Egil Dahlberg
egil@REDACTED
Thu Sep 18 01:34:35 CEST 2008
Yes, it is an error.
The following changes should resolve this issue:
diff -Nau c_src/memsup.c@@/main/release/r12b_patch/OTP_R12B-4
c_src/memsup.c@@/main/release/r12b_patch/r12b_otp_7558/LATEST
--- c_src/memsup.c@@/main/release/r12b_patch/OTP_R12B-4 2008-09-01
14:51:12.000000000 +0200
+++ c_src/memsup.c@@/main/release/r12b_patch/r12b_otp_7558/LATEST
2008-09-18 01:05:58.000000000 +0200
@@ -404,13 +404,13 @@
#endif
#if defined(BSD4_4)
-static void
+static int
get_extended_mem_bsd4(memory_ext *me) {
struct vmtotal vt;
long pgsz;
- if (!get_vmtotal(&vt)) goto fail;
- if ((pgsz = sysconf(_SC_PAGESIZE)) == -1) goto fail;
+ if (!get_vmtotal(&vt)) return 0;
+ if ((pgsz = sysconf(_SC_PAGESIZE)) == -1) return 0;
me->total = (vt.t_free + vt.t_rm);
me->free = vt.t_free;
@@ -418,10 +418,7 @@
me->flag = F_MEM_TOTAL | F_MEM_FREE;
- return;
-fail:
- print_error("%s", strerror(errno));
- exit(1);
+ return 1;
}
#endif
The build has been tested on:
FreeBSD 5.0-RELEASE #0: Thu Jan 16 22:16:53 GMT 2003
OpenBSD 4.0 GENERIC.RAID#2 sparc64
Regards,
Björn-Egil
Erlang/OTP
Jérôme Desquilbet wrote:
> I get the following error while building OTP R12B-4 on OpenBSD 4.3.
> Any idea?
> Thanks a lot,
> Jérôme.
>
>
> === Entering application os_mon
> gmake[3]: Entering directory
> `/usr/tools/erlang/otp_src_R12B-4/lib/os_mon/src'
> gmake[3]: Nothing to be done for `opt'.
> gmake[3]: Leaving directory
> `/usr/tools/erlang/otp_src_R12B-4/lib/os_mon/src'
> gmake[3]: Entering directory
> `/usr/tools/erlang/otp_src_R12B-4/lib/os_mon/c_src'
>
> gmake -f i386-unknown-openbsd4.3/Makefile TYPE=opt
> gmake[4]: Entering directory
> `/usr/tools/erlang/otp_src_R12B-4/lib/os_mon/c_src'
>
> gcc -c -o ../priv/obj/i386-unknown-openbsd4.3/memsup.o -g -O2
> -I/usr/tools/erlan
> g/otp_src_R12B-4/erts/i386-unknown-openbsd4.3 -DHAVE_CONFIG_H memsup.c
> memsup.c: In function `get_extended_mem':
> memsup.c:456: error: void value not ignored as it ought to be
> gmake[4]: *** [../priv/obj/i386-unknown-openbsd4.3/memsup.o] Error 1
> gmake[4]: Leaving directory
> `/usr/tools/erlang/otp_src_R12B-4/lib/os_mon/c_src'
> gmake[3]: *** [opt] Error 2
> gmake[3]: Leaving directory
> `/usr/tools/erlang/otp_src_R12B-4/lib/os_mon/c_src'
> gmake[2]: *** [opt] Error 2
> gmake[2]: Leaving directory `/usr/tools/erlang/otp_src_R12B-4/lib/os_mon'
> gmake[1]: *** [opt] Error 2
> gmake[1]: Leaving directory `/usr/tools/erlang/otp_src_R12B-4/lib'
> gmake: *** [libs] Error 2
>
>
>
>
>
> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://www.erlang.org/mailman/listinfo/erlang-questions
More information about the erlang-questions
mailing list