1. 16 Jan, 2015 2 commits
    • Jeffrey Lee's avatar
      Escape some dollars · 617d00bf
      Jeffrey Lee authored
        s/modulewrap - Escape some dollars contained in strings to avoid warnings from objasm
        Resulting binary unchanged (FilerAction)
      Version 5.83. Retagged as 'RISC_OSLib-5_83'
    • Jeffrey Lee's avatar
      Escape some dollars · 4733881f
      Jeffrey Lee authored
        kernel/s/k_body, s/initmodule - Escape some dollars contained in strings to avoid warnings from objasm
        Resulting binary unchanged
      Version 5.83. Retagged as 'RISC_OSLib-5_83'
  2. 23 Aug, 2014 1 commit
    • Robert Sprowson's avatar
      Minor rlib cleanups · dc7ea073
      Robert Sprowson authored
      dbox.c: address of cancelled by dereference
      event.c: spelling
      txtar.c: don't grab the caret when clicking toggle size
      txtedit.c: use BOOL for a boolean
      win.c: when looking at the behind window handle we want -1 not 'DUD' (which happens to be -1)
      wimp.h: add comment about window handle -3
      Retagged as RISC_OSLib-5_83.
      Version 5.83. Not tagged
  3. 01 Aug, 2014 2 commits
    • Jeffrey Lee's avatar
      Makefile tweaks · 9ac4cc52
      Jeffrey Lee authored
        Makefile - Get the -depend option from ${STDTOOLOPTIONS}; also allows us to pull in the throwback flag. Fix all ${AS} calls to use ${AFLAGS} so that dependencies are tracked properly.
        Identical to previous binary
      Version 5.83. Retagged as 'RISC_OSLib-5_83'
    • Jeffrey Lee's avatar
      Fix rlib static data size · 917098cb
      Jeffrey Lee authored
        rlib/s/rlibdata - Reduce RlibSpace by 1, to take into account the removal of a static from rlib/c/xfersend
        Tested on BB-xM
        Fixes 'Static data size in library and stub disagree' error when running ROM apps
      Version 5.83. Retagged as 'RISC_OSLib-5_83'
  4. 31 Jul, 2014 1 commit
    • Robert Sprowson's avatar
      Some RISC_OSLib rlib enhancements · 5b7cef10
      Robert Sprowson authored
      Add a new menu_setcolours() function to allow the fore/background colour bits to be set on a menu entry.
      Use the new menu_setcolours() function instead of making assumptions about menu's internal structure layout.
      New functions dbox_hidefield and dbox_unhidefield added to complement the fade/unfade ones.
      As dbox_findicon/findiconbefore are only ever used to find writables, rename them as such. Also, make them find writable (type 15) AND writable draggable (type 14) icons.
      Allow navigation by tab/shift tab through icons like the Style Guide chapter 16 says we should. In fact it's a little odd that dbox is emulating 'Ktar' validation itself manually when the Wimp has done this since version 2.92, but maintaining it is less effort than going and checking all the templates.
      Fix bug when looking for leading capital letter matches to complete a dbox, the previous code was looking at the cached copy of the icon flags in d->window rathe...
  5. 08 Jul, 2014 1 commit
  6. 15 Jun, 2014 1 commit
    • Ben Avison's avatar
      Add C99 standard headers wchar.h and wctype.h · 3ed0fb98
      Ben Avison authored
        These were previously languishing in the C compiler sources, but they
        belong in the C library. Note however that the library does not implement
        the functions described in these headers at the present time, so any
        attempt to use them will result in link-time errors.
        Untested (known not working)
      Version 5.83. Tagged as 'RISC_OSLib-5_83'
  7. 08 May, 2014 1 commit
    • Robert Sprowson's avatar
      Check for NULL pointers before finding the syshandle · da9f2a03
      Robert Sprowson authored
      menu.c: if NULL return -1, this has the added advantage that a menu maker (see event_attachmenumaker) can return NULL to mean "no menu thanks" and not data abort in event.c
      dbox.c: if NULL return 0, this is somewhat consistent with template_syshandle()
      menu.h: typo in comment corrected
      Version 5.82. Tagged as 'RISC_OSLib-5_82'
  8. 25 Mar, 2014 1 commit
    • Ben Avison's avatar
      Unbreak stdio.h for C90 mode · 83945ac3
      Ben Avison authored
        Large file support made use of long longs in various definitions. These
        were switched out in PCC mode, but no allowances were made for the fact
        that C90 doesn't define long long either.
        Remember that to force cc to use non-builtin standard headers, you need
        to point at these using the -j switch (e.g. -jC:). The only version of
        cc which featured the C90-incompatible stdio.h was 5.70.
        Checked that the header now works when included in -pcc, -c90 and -c99 modes.
      Version 5.81. Tagged as 'RISC_OSLib-5_81'
  9. 21 Jan, 2014 1 commit
    • Robert Sprowson's avatar
      Permit wildcards in RISC_OSLib application's messages files · 76d1dff4
      Robert Sprowson authored
      msgs.c: includes a MessageTrans parser that duplicates MessageTrans_Lookup (needed because the lookup function returns pointers to static C strings). However, did not allow '?' wildcards in the message token names.
      Version 5.80. Tagged as 'RISC_OSLib-5_80'
  10. 20 Jan, 2014 1 commit
    • Jeffrey Lee's avatar
      Fix 32bitification error · a654e89d
      Jeffrey Lee authored
        kernel/s/k_body - At CopyUpDone in _kernel_system(), a big block of conditional code was converted to unconditional as part of the 32bit conversion process. However one line for setting up the error handler remained conditional, potentially preventing the correct error buffer pointer being set when about to start the child task.
        Tested on BB-xM
      Version 5.79. Tagged as 'RISC_OSLib-5_79'
  11. 24 Oct, 2013 1 commit
    • Robert Sprowson's avatar
      Some library fixes · c9b6d7f3
      Robert Sprowson authored
      Fix for problem passing long command lines via system(), while there are good arguments to leave the threshold at 255, non DDEUtils aware programs get brutally truncated command strings, and since the old threshold of 255 applied when the kernel handled 256 command lines, upping the limit to 1k is no worse than before.
      Fix for Edit failing to draw lines of text longer than 192 characters (ticket #350). Several factors were conspiring here: on a mode change the window width in characters wasn't being clamped, whereas user entered limits in the menu were, then the internal buffer ("PAINTBUFSIZE") was too short so lines got truncated, and when larger than 256 got wrapped modulo 256 due to the use of an array of chars. Now set at compile time with BIG_WINDOW_SIZE_LIMIT with a new theoretical maximum of 8192. Currently limited to 480 since it uses stack variables.
      In the C library:
       armsys.c: adapt the threshold at which to use DDEUtils based on the kernel version number
       scanf.c: squash a warning
       time.c: mark the table of month lengths as constant so we can claw back 13 words of static workspace without having to change the stubs
      In RISC OS lib:
       bbc.c: remove local definitions of some SWI numbers
       template.c: squash a warning
       txt.c: delete Modula-2 support
       txt1.c: compare pointer with NULL not an integer
       txtar.c: introduce BIG_WINDOW_SIZE_LIMIT, rationalise a few sprintf's, mark private functions as static
       txtundo.c/txtedit.c: squash old style function warnings
       txtoptmenu.c: clamp the window width read from Edit$Options properly, delete long disabled code
       txtscrap.c: dead function deleted
      Version 5.78. Tagged as 'RISC_OSLib-5_78'
  12. 06 Oct, 2013 1 commit
  13. 30 Jun, 2013 1 commit
    • Robert Sprowson's avatar
      Added some missing font_paint() flags · 3842fca0
      Robert Sprowson authored
      font.h: missing flags defined (those flags that can be used without needing to change the prototype of font_paint()
      fontlist.h: comment typo
      No code changes, retagged as RISC_OSLib-5_77
  14. 06 Apr, 2013 1 commit
  15. 24 Mar, 2013 1 commit
    • Robert Sprowson's avatar
      Build fix · 8e9a4e8e
      Robert Sprowson authored
      s/h_brazil: use Hdr:System instead of GETting them one at a time
      c/scanf: type cast
      Version 5.77. Tagged as 'RISC_OSLib-5_77'
  16. 20 Mar, 2013 1 commit
  17. 15 Jan, 2013 1 commit
    • Robert Sprowson's avatar
      Add JPEG_ to swis.h · e1060d17
      Robert Sprowson authored
      This is in the 'SprExtend' header, which messes up the alphabetical ordering a bit.
      Version 5.75. Tagged as 'RISC_OSLib-5_75'
  18. 12 Oct, 2012 1 commit
    • Ben Avison's avatar
      Merged in a fix to <math.h> from C compiler · 9fe4fc44
      Ben Avison authored
        This change was first applied to the inbuilt headers in the C compiler at
        version 5.59 (07 Apr 2005), but was accidentally not copied into the
        RISC_OSLib version of math.h. Fortunately, this would only have affected
        anyone compiling software with the -jC: switch.
        Untested, but should be a safe change.
      Version 5.74. Tagged as 'RISC_OSLib-5_74'
  19. 25 Sep, 2012 1 commit
    • Robert Sprowson's avatar
      Style guide ammendment · 6fbe9ace
      Robert Sprowson authored
      While the txtedit part of RISC_OSLib has never been famed for its adherence this brings the delete operation (^K ref Style Guide p38, !ResEd, and the drag & drop protocol specification) into line.
      Version 5.73. Tagged as 'RISC_OSLib-5_73'
  20. 01 Sep, 2012 1 commit
    • Jeffrey Lee's avatar
      Generate symbols file during ROM builds · 235e5e7d
      Jeffrey Lee authored
        Makefile - The symbols file that gets generated during the build now gets copied to the install folder for ROM builds. This allows it to be picked up easily by debugging tools.
        Tested with BCM2835, OMAP3 & Disc builds
      Version 5.72. Retagged as 'RISC_OSLib-5_72'
  21. 28 Aug, 2012 1 commit
  22. 21 Aug, 2012 1 commit
  23. 15 Aug, 2012 1 commit
    • Jeffrey Lee's avatar
      Add VCHIQ to SWIOptions · aaef61b3
      Jeffrey Lee authored
        SWIOptions,feb - Added VCHIQ to SWI header list
        Makefile - Add SWIOptions as a dependency to s.swioptions, so exported swis.h will rebuild correctly if SWIOptions is changed
        Tested briefly
      Version 5.71. Tagged as 'RISC_OSLib-5_71'
  24. 26 Jun, 2012 1 commit
    • Jeffrey Lee's avatar
      Improve sanity checks in default_unwind_handler · 7289ddae
      Jeffrey Lee authored
        kernel/s/k_body - Now ignores unaligned PC values, as they either indicate stack corruption or Thumb use (which the unwind handler doesn't support anyway)
        Tested on Raspberry Pi with high processor vectors
      Version 5.70. Tagged as 'RISC_OSLib-5_70'
  25. 11 Jun, 2012 1 commit
    • Robert Sprowson's avatar
      Make mktime() correct for local time. · 27bebb79
      Robert Sprowson authored
      Following an earlier fix, the logic of mktime() has turned out to need reviewing too.
      To summarise
        time() -> a UTC time in seconds
        gmtime() -> breaks down a UTC time into components
        localtime() -> breaks down a UTC time into local components (tz + DST)
        mktime() -> converts local components back into UTC time, normalising
      In mktime(), the current locale (via setlocale()) is considered and used to choose the timezone, assuming an appropriate territory module is loaded.
      The value of the tm_isdst field is factored into the offset calculation.
      However, mktime() is also defined as normalising the components of time and updating the caller's block with normalised values, in local time, so the local offset is reapplied at the end.
      Moved time_to_tm up in the function so mktime() can use it.
      Corrected/lined up some comments.
      Also, mktime() no longer forces tm_isdst to -1, it preserves the user's value, so consecutive mktime()s are consistent.
      Added test to "test/tzones.c", results compared with Windows XP.
      Version 5.69. Tagged as 'RISC_OSLib-5_69'
  26. 28 May, 2012 1 commit
    • Robert Sprowson's avatar
      Add locale support for selecting timezones from C armsys.c · 9fab6d08
      Robert Sprowson authored
        Ammended time() to match ISO9899 and just return UTC like it says.
        Inlined the single use of _bbctime() macro.
        The timezone within a territory can now be specified as part of the setlocale() function.
        This uses a qualifier to the already accepted territory name, for an example see test/tzones.c
        Shock addition of some comments to the locale parsing function.
        To avoid needing to mess about with C library workspace the timezone and territory are encoded internally into 1 word, with 10 bits allowing up to 1024 territories worldwide.
        Ripple through to strftime().
        localtime() updated to respect locale selection.
        Copyright headers added.
      Output compared with Windows XP using setlocale versus tzset to shift the program into Pacific time.
      Version 5.68. Tagged as 'RISC_OSLib-5_68'
  27. 27 Mar, 2012 1 commit
    • Jeffrey Lee's avatar
      Fix asasm 2.00 warnings · 98660885
      Jeffrey Lee authored
        clib/s/cl_entries - Symbol names containing $'s are now wrapped in |'s to prevent potential unintended variable expansion
        s/h_modmacro, s/h_stubs - Modify Entry/Entry2 to not add their own vertical bars to symbol names (causing two sets of bars that cancel each other out)
        Tungsten ROM version identical to before when built under objasm
        Needs Library-1_54 for ROM link symbol files to be generated correctly
      Version 5.67. Retagged as 'RISC_OSLib-5_67'
  28. 16 Feb, 2012 1 commit
  29. 04 Feb, 2012 1 commit
    • Jeffrey Lee's avatar
      Add ZLib module to SWIOptions · 59236321
      Jeffrey Lee authored
        SWIOptions,feb - Now includes ZLib module SWIs
        SWI export tested, seems OK
      Version 5.66. Not tagged
  30. 06 Dec, 2011 1 commit
    • Jeffrey Lee's avatar
      Use correct CLZ check · 23deb4ff
      Jeffrey Lee authored
        s/longlong - Only look for ARMv5 support when deciding if CLZ is available, not ARMv5T
        Tested in OMAP3 ROM
      Version 5.66. Tagged as 'RISC_OSLib-5_66'
  31. 26 Nov, 2011 1 commit
    • Robert Sprowson's avatar
      Review use of StrongARM switch. · 8988adae
      Robert Sprowson authored
      Was being used to conditionalise things which aren't really StrongARM related, now should be read as "support split I+D caches" switch.
      Version 5.65. Tagged as 'RISC_OSLib-5_65'
  32. 13 Nov, 2011 1 commit
  33. 12 Nov, 2011 1 commit
    • Ben Avison's avatar
      Fix stack imbalance in module stubs · faec85ad
      Ben Avison authored
        A minus sign was missing - this meant that any module built using stubs
        from the last 2 weeks would branch through zero at the end of initialisation.
        Modules now work again!
      Retagged as 'RISC_OSLib-5_64'
      Version 5.64. Not tagged
  34. 28 Oct, 2011 2 commits
    • Ben Avison's avatar
      File handling improvements · 8dcb6880
      Ben Avison authored
        * Added 64-bit file pointer API support, following the LFS spec v1.5
          (see Docs directory). Internally, now uses 64-bit file pointers
          exclusively. For now, the backend still limits you to 4GB-1 files, but
          clients of the C library won't need recompiling again to support larger
          files than this once they use the new API.
        * Fixed a large number of warnings produced in compilation, assembly and
          linking, many of them new and resulting from the improved checks in the
          latest toolchain.
        * Increased the maximum stream buffer size from 16MB to 1GB.
        * Added Hdr:SDFS and Hdr:SDIO to the list of headers used to build swis.h
          if they are present.
        Verified that the new 64-bit file pointer buffering code works using a
        ROM build (since the toolchain makes extensive use of reading, writing
        and seeking internally).
      Version 5.64. Tagged as 'RISC_OSLib-5_64'
    • Ben Avison's avatar
      Long long multiply bugfix · 3f057115
      Ben Avison authored
        Last revision broke _ll_mullu (the runtime support function for multiplying
        a 64-bit integer by an unsigned 32-bit integer) except for ROM builds that
        target CPUs with the M extension. So in practice, IOMD ROMs and softloadable
        C libraries both exhibited the bug.
        Verified that the compiler will now run against this C library (previously
        it reported many non-sensical errors).
      Version 5.63. Tagged as 'RISC_OSLib-5_63'
  35. 18 Oct, 2011 1 commit
    • Robert Sprowson's avatar
      Change to use StdTools. · 7f2ef214
      Robert Sprowson authored
      Be more quiet when cleaning.
      STM/LDM changed to Push/Pull.
      Moved an illegal instruction back into ARM's illegal instruction space.
      Version 5.62. Tagged as 'RISC_OSLib-5_62'
  36. 24 Sep, 2011 1 commit
    • Jeffrey Lee's avatar
      Fix objasm 4 warnings. Enable (S|U)MULL/CLZ in math code. · a6d65423
      Jeffrey Lee authored
        s/longlong - The code has always had the ability to use CLZ & long multiply instructions, but it's never been enabled. The nonfunctional code to detect the CPU architecture at runtime has been disabled, and instead a fixed configuration is selected at compile time with the help of Hdr:CPU.Arch. Also added lots of ROUT's for safety.
        s/objmacs - Updated push/pop macros to make use of LDR/STR when only one register is to be transferred. This fixes a few objasm 4 warnings and should result in a speed boost where applicable.
        Tested on rev A2 BB-xM.
        Different math code configurations tested briefly.
      Version 5.61. Tagged as 'RISC_OSLib-5_61'
  37. 06 Aug, 2011 1 commit
    • Jeffrey Lee's avatar
      Update to work with zero page relocation · 14a49538
      Jeffrey Lee authored
        clib/s/cl_stub, kernel/s/k_body, s/initmodule - Use OS_ReadSysInfo 6 to look up CLibWord/RISCOSLibWord/CLibCounter location each time it's needed instead of using hardcoded addresses. SWI overhead shouldn't be too bad since the zero page areas are rarely used.
        rlib/c/menu - Fix null pointer access when attempting to clear a submenu pointer via menu_submenu(...,...,NULL)
        s/h_workspc - Remove old local definitions of CLibCounter, RISCOSLibWorkSpace and CLibWorkSpace. Use Hdr:PublicWS instead.
        Tested on rev A2 BB-xM
      Version 5.60. Tagged as 'RISC_OSLib-5_60'