debian/0000755000000000000000000000000012071014710007157 5ustar debian/patches/0000755000000000000000000000000012070534123010612 5ustar debian/patches/series0000644000000000000000000000007212070517666012043 0ustar 20-correct-spelling-errors.patch fix_makefile_clean.patch debian/patches/20-correct-spelling-errors.patch0000644000000000000000000000752111675266410016660 0ustar Author: Slavko Description: This patch changes the spell errors from writeable to writable. --- a/doc/Readme +++ b/doc/Readme @@ -388,7 +388,7 @@ val = OpenFileAppend(fname, fsize, handle); val = OpenFileRead(fname, fsize, handle); val = CloseFile(handle); -val = ResolveHandle(fname, handle, writeable); +val = ResolveHandle(fname, handle, writable); val = RenameFile(oldname, newname); val = DeleteFile(fname); val = Read(handle, n); --- a/doc/Changelog +++ b/doc/Changelog @@ -1053,7 +1053,7 @@ OpenFileAppend(fname, fsize, handle) OpenFileRead(fname, fsize, handle) CloseFile(handle) - ResolveHandle(fname, handle, writeable) + ResolveHandle(fname, handle, writable) RenameFile(oldname, newname) DeleteFile(fname) SendMessage(queue, msg) @@ -1348,7 +1348,7 @@ OpenFileAppend(fname, fsize, handle, result) OpenFileRead(fname, fsize, handle, result) CloseFile(handle, result) - ResolveHandle(fname, handle, writeable, result) + ResolveHandle(fname, handle, writable, result) RenameFile(oldname, newname, result) DeleteFile(fname, result) SendMessage(queue, msg, result) --- a/NXT/NXTDefs.h +++ b/NXT/NXTDefs.h @@ -4508,12 +4508,12 @@ mov _result, __FCArgs.Result \ release __FCMutex -#define __resolveHandle(_fname, _handle, _writeable, _result) \ +#define __resolveHandle(_fname, _handle, _writable, _result) \ acquire __FRHMutex \ mov __FRHArgs.Filename, _fname \ syscall FileResolveHandle, __FRHArgs \ mov _handle, __FRHArgs.FileHandle \ - mov _writeable, __FRHArgs.WriteHandle \ + mov _writable, __FRHArgs.WriteHandle \ mov _result, __FRHArgs.Result \ release __FRHMutex @@ -15919,11 +15919,11 @@ * * \param _fname The name of the file for which to resolve a handle. * \param _handle The file handle output from the function call. - * \param _writeable A boolean flag indicating whether the handle is + * \param _writable A boolean flag indicating whether the handle is * to a file open for writing (true) or reading (false). * \param _result The function call result. See \ref LoaderErrors. */ -#define ResolveHandle(_fname, _handle, _writeable, _result) __resolveHandle(_fname, _handle, _writeable, _result) +#define ResolveHandle(_fname, _handle, _writable, _result) __resolveHandle(_fname, _handle, _writable, _result) /** * Rename a file. --- a/NXT/NXCDefs.h +++ b/NXT/NXCDefs.h @@ -8859,11 +8859,11 @@ * * \param filename The name of the file for which to resolve a handle. * \param handle The file handle output from the function call. - * \param writeable A boolean flag indicating whether the handle is + * \param writable A boolean flag indicating whether the handle is * to a file open for writing (true) or reading (false). * \return The function call result. See \ref LoaderErrors. */ -inline unsigned int ResolveHandle(string filename, byte & handle, bool & writeable); +inline unsigned int ResolveHandle(string filename, byte & handle, bool & writable); /** * Rename a file. @@ -9352,7 +9352,7 @@ #define OpenFileAppend(_fname, _fsize, _handle) asm { __openFileAppend(_fname, _fsize, _handle, __RETVAL__) } #define OpenFileRead(_fname, _fsize, _handle) asm { __openFileRead(_fname, _fsize, _handle, __RETVAL__) } #define CloseFile(_handle) asm { __closeFile(_handle, __RETVAL__) } -#define ResolveHandle(_fname, _handle, _writeable) asm { __resolveHandle(_fname, _handle, _writeable, __RETVAL__) } +#define ResolveHandle(_fname, _handle, _writable) asm { __resolveHandle(_fname, _handle, _writable, __RETVAL__) } #define RenameFile(_oldname, _newname) asm { __renameFile(_oldname, _newname, __RETVAL__) } #define DeleteFile(_fname) asm { __deleteFile(_fname, __RETVAL__) } #define ResizeFile(_fname, _newsize) asm { __fileResize(_fname, _newsize, __RETVAL__) } debian/patches/fix_makefile_clean.patch0000644000000000000000000000130112070534123015413 0ustar Description: Adds another deletion of files to the Makefile clean target Author: Petter Reinholdtsen --- a/NXT/nbcunix.mak +++ b/NXT/nbcunix.mak @@ -7,13 +7,14 @@ clean:: rm -f *.o *.ppu *.rst *.compiled *.dcu nbc_preproc.inc + rm -f ../*.o ../*.ppu ../*.rst ../bricktools/*.o ../bricktools/*.ppu realclean:: clean rm -f $(PROGRAMS) mkdata NBCCommonData.pas NXTDefsData.pas NXCDefsData.pas install:: all -PFLAGS=-S2cdghi -dRELEASE -vewnhi -l -Fu../ -Fu. -Fu../bricktools -dCAN_DOWNLOAD +PFLAGS=-S2cdghi -dRELEASE -vewnhi -l -Fu../ -Fu. -Fu../bricktools -dCAN_DOWNLOAD -k"-z relro" # PTOOLPREFIX may differ on different platforms (e.g. /usr/local/bin/) debian/README.Debian0000644000000000000000000000166611677114153011246 0ustar nbc for Debian ------------------ The udev rule is prepared to create device file with mode 0664 and owned by root:plugdev, then to allow users to work with Lego NXT, the user must be a member of plugdev group. This can be done, for example by executing as root: addgroup plugdev Download the NBC Guide (http://bricxcc.sourceforge.net/nbc/doc/NBC_Guide.pdf) for detailed information about the NBC language. A reference guide for NXC is also available (http://bricxcc.sourceforge.net/nbc/nxcdoc/NXC_Guide.pdf). You can also access online API help for NXC or download a compiled HTML help file (http://bricxcc.sourceforge.net/nbc/nxcdoc/nxc_api.chm). To take advantage of multi-dimensional array support and native shift and wait operations be sure to download the enhanced NBC/NXC firmware (http://bricxcc.sourceforge.net/lms_arm_nbcnxc.zip) and install it on your NXT. -- Slavko Sun, 06 May 2010 20:49:24 +0200 debian/docs0000644000000000000000000000001311675267544010054 0ustar doc/Readme debian/source/0000755000000000000000000000000011404562323010466 5ustar debian/source/format0000644000000000000000000000001411404562323011674 0ustar 3.0 (quilt) debian/nbc.lintian-overrides0000644000000000000000000000004611411127200013275 0ustar nbc binary: maintainer-not-full-name debian/watch0000644000000000000000000000030011676036165010223 0ustar # See uscan(1) for format # Compulsory line, this is a version 3 file version=3 # Uncomment to examine a Webpage opts="dversionmangle=s/\+dfsg//g" \ http://sf.net/bricxcc/nbc-(.+)\.src\.tgz debian/install0000644000000000000000000000002211674671307010565 0ustar NXT/nbc usr/bin debian/changelog0000644000000000000000000000211712071006607011040 0ustar nbc (1.2.1.r4+dfsg-1) unstable; urgency=low * added patch to fix clean target nbcunix.mak (thanks to Petter Reinholdtsen) * improved rules file and removed the 10-add_makefile.patch patch as unnecessary (thanks to Petter Reinholdtsen) * added hardenning option into nbcunix.mak to patch * changed the standards version to 3.9.4 (no other changes) * changed copyright format uri to versioned one * added patch to solve spelling errors * added LEGO in short description to better description * install rules file by dh_installudev * moved nbc.1 from patch to debian/ directory and added license item in copyright file for it * changed license of the debian/* files to MPL, to simplify licencing * removed png/* from source; because uncluean license and while it is not necessary in Linux release * removed GIFImage.pas from source; because DFSG violation and while it is not necessary in Linux release * upload sponsored by Petter Reinholdtsen * initial Debian release (Closes: #518230, #660314) -- Slavko Wed, 02 Jan 2013 11:35:46 +0100 debian/manpages0000644000000000000000000000001511674670441010712 0ustar debian/nbc.1 debian/source.lintian-overrides0000644000000000000000000000004412071001072014032 0ustar nbc source: maintainer-not-full-namedebian/rules0000755000000000000000000000111312070534413010241 0ustar #!/usr/bin/make -f # -*- makefile -*- # Sample debian/rules that uses debhelper. # This file was originally written by Joey Hess and Craig Small. # As a special exception, when this file is copied by dh-make into a # dh-make output file, you may use that output file without restriction. # This special exception was added by Craig Small in version 0.37 of dh-make. # Uncomment this to turn on verbose mode. #export DH_VERBOSE=1 %: dh $@ override_dh_auto_build: dh_auto_build make -C NXT -f nbcunix.mak override_dh_auto_clean: dh_auto_clean make -C NXT -f nbcunix.mak realclean debian/nbc.10000644000000000000000000000455311677113424010027 0ustar .TH NBC 1 "September 21, 2009" .SH NAME nbc \- Compiler for LEGO Mindstorms NXT .SH SYNOPSIS .B nbc .RI [ options ] " file " [options] .SH DESCRIPTION This manual page documents briefly the .B nbc command. .PP \fBnbc\fP is a program that compiles Not eXactly C (NXC) files or NeXT Byte Code (NBC) files into programs that can run on the standard LEGO MINDSTORMS NXT firmware or the enhanced NBC/NXC firmware. The nbc compiler can either save the compiler output to a file or upload it to a LEGO Mindstorms NXT for execution. The compiler can also compile NXT Picture files (.ric) using the text-based RICScript language. Since nbc can compile different programming languages it uses the file extension to determine the type of code it is compiling. NXC programs should use the .nxc file extension, NBC programs should use the .nbc file extension, and RICScript programs should use the .rs file extension. .SH OPTIONS .TP .B \-S= specify port name (COMn or usb), resource name, or alias .TP .B \-d download program .TP .B \-b treat input file as a binary file (don't compile it) .TP .B \-q quiet mode .TP .B \-n prevent the system file from being included .TP .B \-D=[=] define macro .TP .B \-x decompile program .TP .B \-Z[1|2] turn on compiler optimizations .TP .B \-ER=n set maximum errors before aborting (0 == no limit) .TP .B \-PD=n set max preprocessor recursion depth (default == 10) .TP .B \-O= specify output file .TP .B \-E= write compiler errors to .TP .B \-I= search for include files .TP .B \-nbc= save NXC intermediate NBC code to .TP .B \-L= generate code listing to .TP .B \-Y= generate symbol table to .TP .B \-w[-|+] warnings off or on [default is on] .TP .B \-sm[-|+] compiler status messages off or on [default is on] .TP .B \-EF enhanced firmware .TP .B \-safecall NXC will wrap all function calls in Acquire/Release .TP .B \-api dump the API to stdout .TP .B \-v=n set the targeted firmware version (default == 128, NXT 1.1 == 105) .TP .B \-help display command line options .SH AUTHOR nbc was written by John Hansen. .PP This manual page was written by Sebastian Reichel , for the Debian project (but may be used by others). debian/control0000644000000000000000000000236612071013666010602 0ustar Source: nbc Section: electronics Priority: extra Maintainer: Slavko #Build-Depends: debhelper (>= 9), hardening-wrapper, libusb-dev, fp-compiler, fp-units-fcl Build-Depends: debhelper (>= 8), libusb-dev, fp-compiler, fp-units-fcl Standards-Version: 3.9.4 Homepage: http://bricxcc.sourceforge.net/nbc/ Package: nbc Architecture: any Depends: ${shlibs:Depends}, ${misc:Depends} Recommends: bluez | bluetooth Suggests: libnxt, t2n Description: Compiler for LEGO Mindstorms NXT bricks Next Byte Codes (NBC) is a simple language with an assembly language syntax that can be used to program LEGO's NXT programmable brick (from the new LEGO Mindstorms NXT set). . Not eXactly C (NXC) is a high level language, similar to C, built on top of the NBC compiler. It can also be used to program the NXT brick. NXC is basically NQC for the NXT. To compile NXC programs just use the NBC compiler with source code files that have a .nxc file extension. . If you are just getting started with programming, then graphical environments such as the Mindstorms NXT software may be better choices for you. If, however, you're a programmer and you prefer typing a few lines to drag and drop icon programming, then either NBC or NXC may be perfect for you. . debian/copyright0000644000000000000000000000233411704114013011113 0ustar Format: http://anonscm.debian.org/viewvc/dep/web/deps/dep5.mdwn?view=markup&pathrev=213 Upstream-Name: nbc Source: http://bricxcc.sourceforge.net/nbc/ There was removed GIFImage.pas and png/* from original released sources, because these are not necessary in Linux release. The GIFImage.pas license restrictions violates the DFSG and png/* haves unclean license information. Files: * Copyright: 2006-2011, John Hansen License: MPL-1.1 Files: debian/* Copyright: 2011 Slavko License: MPL-1.1 Files: debian/nbc.1 Copyright: 2009 Sebastian Reichel License: MPL-1.1 License: MPL-1.1 The contents of this package are subject to the Mozilla Public License Version 1.1 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.mozilla.org/MPL/ . Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License. . The complete text of the Mozilla Public Lecense version 1.1 can be found at "http://www.mozilla.org/MPL/MPL-1.1.html" debian/nbc.udev0000644000000000000000000000050211404557707010624 0ustar # pravidlo pre NXT 2.0 SUBSYSTEM=="usb", ACTION=="add", ATTR{idVendor}=="0694", ATTR{idProduct}=="0002", \ MODE="0660", GROUP="plugdev", SYMLINK+="nxt-%k" #, SYMLINK+="legonxt-%n" # asi pre firmware flash mode SUBSYSTEM=="usb", ACTION=="add", ATTR{idVendor}=="03eb", \ MODE="0660", GROUP="plugdev" debian/compat0000644000000000000000000000000212071000043010347 0ustar 8