Bug 239348 - [NEW PORT] lang/vlang: Simple, fast, safe, compiled language for developing maintainable software.
Summary: [NEW PORT] lang/vlang: Simple, fast, safe, compiled language for developing m...
Status: In Progress
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Mateusz Piotrowski
URL:
Keywords:
: 240300 (view as bug list)
Depends on:
Blocks:
 
Reported: 2019-07-20 16:59 UTC by Martin Filla
Modified: 2019-10-12 19:17 UTC (History)
3 users (show)

See Also:


Attachments
vlang.shar (2.01 KB, text/plain)
2019-07-20 16:59 UTC, Martin Filla
no flags Details
vlang.shar (1.96 KB, text/plain)
2019-07-21 10:10 UTC, Martin Filla
no flags Details
vlang.shar (1.63 KB, text/plain)
2019-09-23 10:13 UTC, Martin Filla
no flags Details
vlang.shar (1.91 KB, text/plain)
2019-09-26 09:15 UTC, Martin Filla
no flags Details
vlang.shar (1.91 KB, text/plain)
2019-10-10 10:12 UTC, Martin Filla
no flags Details
vlang.shar (1.72 KB, text/plain)
2019-10-12 19:17 UTC, Martin Filla
freebsd: maintainer-approval+
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Filla 2019-07-20 16:59:15 UTC
Created attachment 205947 [details]
vlang.shar

Simple, fast, safe, compiled language for developing maintainable software.
Comment 1 Mateusz Piotrowski freebsd_committer 2019-07-20 19:37:39 UTC
Hi there, thanks for the submission.

Please check your patch with portlint:
https://www.freebsd.org/doc/en/books/porters-handbook/porting-portlint.html
Comment 2 Martin Filla 2019-07-21 09:58:04 UTC
Hi,
I am sorry
Comment 3 Martin Filla 2019-07-21 10:10:05 UTC
Created attachment 205966 [details]
vlang.shar

Hi there, here you have new file.
Comment 4 Martin Filla 2019-08-15 22:51:23 UTC
ping
Comment 5 Mateusz Piotrowski freebsd_committer 2019-08-16 11:03:40 UTC
The port does not build in a clean environment like poudriere because it attempts to use curl (which is not installed anyway) during the build phase. The problem is that there is no internet connection during build phase.

It should not be that hard to make it work but it might need setting ALL_TARGET to soemthing different or patching the makefile a little bit.

Also, I think I wonder if we could change PORTNAME to vlang as well.
Comment 6 Walter Schwarzenfeld freebsd_triage 2019-08-16 11:33:35 UTC
I think bin/v is also no good name, should also changed to bin/vlang
Comment 7 Mateusz Piotrowski freebsd_committer 2019-08-16 13:02:52 UTC
(In reply to Walter Schwarzenfeld from comment #6)

It is short, true. I'd stick to the defaults, however. If "v" the name for a compiler that the vlang community expects then it should be so. That's at least my opinion.
Comment 8 Martin Filla 2019-08-25 23:01:27 UTC
(In reply to Walter Schwarzenfeld from comment #6)
(In reply to Mateusz Piotrowski from comment #7)

Mateusz Piotrowski have true, because community expects short name "v" but i dont 
know what people from ports.
Comment 9 Tobias Kortkamp freebsd_committer 2019-09-03 12:19:46 UTC
*** Bug 240300 has been marked as a duplicate of this bug. ***
Comment 10 Lewis Cook 2019-09-03 12:51:08 UTC
Is there any follow-up regarding this port? I proposed a port earlier, which doesn't rely on curl as aforementioned above and was marked duplicate (never occurred to me to see if this port preexisted, I do apologize). Alternatively, it fetches both (the V compiler written in C then V-variation, the former being used to initially bootstrap the V-variant)—then built with the native compiler installed on the system. Although it doesn't fix the remaining issues of V itself, it's a step closer to V development on FreeBSD. Cheers!
Comment 11 Martin Filla 2019-09-03 15:43:36 UTC
(In reply to Lewis Cook from comment #10)
(In reply to Mateusz Piotrowski from comment #7)

I am working on port 

https://github.com/Martinfx/FreeBSD-Ports/commit/78a054ee7ff1b3193e7bfe7c2130fa11b397fdc7
Comment 12 Martin Filla 2019-09-23 10:13:29 UTC
Created attachment 207733 [details]
vlang.shar

Hi, last changes for port v language
Comment 13 Martin Filla 2019-09-24 22:55:17 UTC
(In reply to Mateusz Piotrowski from comment #1)

Hi there, look like this now ok ? :-)
Comment 14 Mateusz Piotrowski freebsd_committer 2019-09-25 12:34:51 UTC
The port does not build in a clean environment of poudriere:

===>  Building for v-0.1.20
gmake[1]: Entering directory '/wrkdirs/usr/ports/lang/vlang/work/v-0.1.20'
rm -rf vc/
git clone --depth 1 --quiet https://github.com/vlang/vc
gmake[1]: git: Command not found
gmake[1]: *** [Makefile:13: all] Error 127
gmake[1]: Leaving directory '/wrkdirs/usr/ports/lang/vlang/work/v-0.1.20'
===> Compilation failed unexpectedly.
Try to set MAKE_JOBS_UNSAFE=yes and rebuild before reporting the failure to
the maintainer.
*** Error code 1

Stop.
make: stopped in /usr/ports/lang/vlang
===========================================================================
[00:00:11] Error: Build failed in phase: build
[00:00:11] Cleaning up
[00:00:11] Unmounting file systems
Comment 15 Mateusz Piotrowski freebsd_committer 2019-09-25 15:17:41 UTC
I've posted some improvements here: https://reviews.freebsd.org/D21787

I'd like the future maintainer to fix tests before vlang gets committed (be it Martin or Lewis).
Comment 16 Martin Filla 2019-09-26 09:14:12 UTC
(In reply to Mateusz Piotrowski from comment #15)
Hello Mateusz, 
I haven't access to reviews.freebsd.org but you have in makefile with CLAGS typing error. 
First problems are with CFLAGS. With flag -fstack-protector-strong vlang haven't problem 
but with -fno-strict-aliasing vlang crash to SIGABRT Signal 6.

Program received signal SIGABRT, Aborted.
0x000000080041e5da in kill () from /lib/libc.so.7
(gdb) t
[Current thread is 1 (LWP 101724 of process 65138)]
(gdb) bt
#0  0x000000080041e5da in kill () from /lib/libc.so.7
#1  0x000000080041e590 in ?? () from /lib/libc.so.7
#2  0x000000080041e500 in __stack_chk_fail () from /lib/libc.so.7
#3  0x000000000021b2fe in os__executable () at /vlang/work/vc-0.1.20/v.c:5079
#4  0x000000000023d32e in new_v (args=...) at /vlang/work/vc-0.1.20/v.c:12065
#5  0x000000000023c1f3 in main (argc=<optimized out>, argv=<optimized out>) at /vlang/work/vc-0.1.20/v.c:11164
(gdb) exit

Next complication are tests 
v-0.1.20/thirdparty/glfw/GLFW/glfw3.h:202:12: fatal error: 'GL/gl.h' file not found
  #include <GL/gl.h>
           ^~~~~~~~~ 

I will report this issues vlang developers.
Comment 17 Martin Filla 2019-09-26 09:15:06 UTC
Created attachment 207838 [details]
vlang.shar
Comment 18 Martin Filla 2019-10-10 10:12:12 UTC
Created attachment 208224 [details]
vlang.shar
Comment 19 Martin Filla 2019-10-12 16:03:15 UTC
Last report for this port
crypto.rand test failed bacause it's not implemented yet.
print_backtrace_skipping_top_frames is not implemented on this platform for now...
other all tests are ok.
Comment 20 Martin Filla 2019-10-12 19:17:04 UTC
Created attachment 208271 [details]
vlang.shar