This archive contains answers to questions sent to Unidata support through mid-2025. Note that the archive is no longer being updated. We provide the archive for reference; many of the answers presented here remain technically correct, even if somewhat outdated. For the most up-to-date information on the use of NSF Unidata software and data services, please consult the Software Documentation first.
Ajit, > I did try using testUnits but it does not compile on windows because of a > missing glob.h (required for CUnit tests). > > Glob.h is reportedly a unix/linux only header. > So I have no choice but to use my own test project. > > I just pulled the sources from test_utNewBaseUnit() and (hopefully) mimicked > all the project properties from testUnits > > Here is my version in entirety (fyi) > > void test_utNewBaseUnit() > { > ut_system* unitSystem = ut_new_system(); ... > ut_unit *second = ut_new_base_unit(unitSystem); > if (ut_offset_by_time(second, ut_encode_time(1970, 1, 1, 0, 0, 0)) == NULL) > { > printf("Error\n"); > return; > } The above isn't an error. The second unit hasn't been sufficiently defined for ut_offet_by_time() to work correctly. > All the calls in this test work excepting for the time related ones > (highlighted). I didn't see any highlights. Our support-email system might have stripped them out. Regards, Steve Emmerson Ticket Details =================== Ticket ID: OTA-964622 Department: Support UDUNITS Priority: Normal Status: Closed =================== NOTE: All email exchanges with Unidata User Support are recorded in the Unidata inquiry tracking system and then made publicly available through the web. If you do not want to have your interactions made available in this way, you must let us know in each email you send to us.