Index: head/devel/msp430-debug-stack/Makefile =================================================================== --- head/devel/msp430-debug-stack/Makefile (revision 455592) +++ head/devel/msp430-debug-stack/Makefile (revision 455593) @@ -1,57 +1,57 @@ # $FreeBSD$ PORTNAME= msp430-debug-stack PORTVERSION= 3.10.001.000 -PORTREVISION= 5 +PORTREVISION= 6 CATEGORIES= devel MASTER_SITES= http://www.ti.com/lit/sw/slac460v/ \ http://www.ti.com/lit/ug/slau320z/:doc1 \ http://www.ti.com/lit/ug/slau656b/:doc2 DISTFILES= slac460v.zip \ slau320z.pdf:doc1 \ slau656b.pdf:doc2 DIST_SUBDIR= ${PORTNAME}-${PORTVERSION} EXTRACT_ONLY= slac460v.zip MAINTAINER= lev@FreeBSD.org COMMENT= TI MSP430 debugging interface library LICENSE= BSD3CLAUSE LIB_DEPENDS= libboost_filesystem.so:devel/boost-libs \ libhidapi.so:comms/hidapi BROKEN_powerpc64= fails to compile: adapt_enum.h: 'to_string' is not a member of 'std' USES= compiler:c++11-lib dos2unix gmake zip:infozip USE_LDCONFIG= yes WRKSRC= ${WRKDIR} DOS2UNIX_REGEX= .*\.(cpp|h) MAKE_ARGS+= BOOST_DIR=${LOCALBASE} \ HIDAPI_DIR=${LOCALBASE} MAKE_JOBS_UNSAFE= yes SUB_FILES+= pkg-message REINPLACE_ARGS= -i "" post-patch: @${FIND} ${WRKSRC}/DLL430_v3/src/TI/DLL430 \ \( -name '*.cpp' -o -name '*.h' \) -print0 | ${XARGS} -0 \ ${REINPLACE_CMD} -e 's|[io]fstream|std::&|; s|std::std::|std::|' do-install: ${INSTALL_LIB} ${WRKSRC}/libmsp430.so ${STAGEDIR}${PREFIX}/lib/libmsp430.so ${INSTALL_DATA} ${WRKSRC}/libmsp430.a ${STAGEDIR}${PREFIX}/lib/libmsp430.a ${MKDIR} ${STAGEDIR}${PREFIX}/include/libmsp430 ${INSTALL_DATA} ${WRKSRC}/DLL430_v3/include/* ${STAGEDIR}${PREFIX}/include/libmsp430/ ${MKDIR} ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${DISTDIR}/${DIST_SUBDIR}/slau320z.pdf ${STAGEDIR}${DOCSDIR}/ ${INSTALL_DATA} ${DISTDIR}/${DIST_SUBDIR}/slau656b.pdf ${STAGEDIR}${DOCSDIR}/ ${MKDIR} ${STAGEDIR}${PREFIX}/etc/devd ${INSTALL_DATA} ${FILESDIR}/mspfet.conf ${STAGEDIR}${PREFIX}/etc/devd .include Index: head/devel/msp430-debug-stack/files/patch-DLL430__v3_src_TI_DLL430_UsbCdcIoChannel.cpp =================================================================== --- head/devel/msp430-debug-stack/files/patch-DLL430__v3_src_TI_DLL430_UsbCdcIoChannel.cpp (revision 455592) +++ head/devel/msp430-debug-stack/files/patch-DLL430__v3_src_TI_DLL430_UsbCdcIoChannel.cpp (revision 455593) @@ -1,20 +1,63 @@ ---- DLL430_v3/src/TI/DLL430/UsbCdcIoChannel.cpp.orig 2017-12-05 18:49:13.159254000 +0300 -+++ DLL430_v3/src/TI/DLL430/UsbCdcIoChannel.cpp 2017-12-05 18:49:23.590490000 +0300 -@@ -401,7 +401,7 @@ bool UsbCdcIoChannel::openPort() +--- DLL430_v3/src/TI/DLL430/UsbCdcIoChannel.cpp.orig 2017-12-05 19:25:19.220234000 +0300 ++++ DLL430_v3/src/TI/DLL430/UsbCdcIoChannel.cpp 2017-12-05 19:31:57.808647000 +0300 +@@ -309,6 +309,22 @@ + } + #else + stringstream cdcIdStream; ++ ++#ifdef __FreeBSD__ ++ ++ path p( "/dev" ); ++ if( exists(p) && is_directory(p) ) { ++ ++ cdcIdStream << hex << setfill('0') << "mspfet" << setw(4) << productId; ++ ++ const directory_iterator end; ++ for( directory_iterator it(p); it != end; ++it ) { ++ ++ string dir = it->path().string(); ++ if( dir.find( cdcIdStream.str() ) != string::npos ) { ++ { ++ ++#else + cdcIdStream << hex << setfill('0') << "usb:v" << setw(4) << vendorId << "p" << setw(4) << productId; + + path p("/sys/class/tty/"); +@@ -330,6 +346,7 @@ + ifNumStream >> interfaceNumber; + if (modalias.find(cdcIdStream.str()) == 0 && interfaceNumber == 0) + { ++#endif + const string filename = it->path().filename().string(); + const string portPath = string("/dev/") + filename; + +@@ -375,7 +392,11 @@ + + bool UsbCdcIoChannel::openPort() + { ++#if BOOST_VERSION < 106600 + ioService = new boost::asio::io_service; ++#else ++ ioService = new boost::asio::io_context; ++#endif + port = new boost::asio::serial_port(*ioService); + timer = new boost::asio::deadline_timer(*ioService); + +@@ -384,7 +405,7 @@ int retry = 5; while (ec && --retry ) { - this_thread::sleep_for(chrono::milliseconds(5)); + this_thread::sleep_for(std::chrono::milliseconds(5)); ec = port->open(portInfo.path, ec); } -@@ -426,7 +426,7 @@ void UsbCdcIoChannel::retrieveStatus() +@@ -409,7 +430,7 @@ { openPort(); //Seeing issues on some platforms (eg. Ubuntu) when port is immediately closed again - this_thread::sleep_for(chrono::milliseconds(100)); + this_thread::sleep_for(std::chrono::milliseconds(100)); close(); } } Index: head/devel/msp430-debug-stack/files/patch-DLL430_v3_src_TI_DLL430_UsbCdcIoChannel.h =================================================================== --- head/devel/msp430-debug-stack/files/patch-DLL430_v3_src_TI_DLL430_UsbCdcIoChannel.h (nonexistent) +++ head/devel/msp430-debug-stack/files/patch-DLL430_v3_src_TI_DLL430_UsbCdcIoChannel.h (revision 455593) @@ -0,0 +1,14 @@ +--- DLL430_v3/src/TI/DLL430/UsbCdcIoChannel.h.orig 2017-12-05 19:32:41.218250000 +0300 ++++ DLL430_v3/src/TI/DLL430/UsbCdcIoChannel.h 2017-12-05 19:33:09.405049000 +0300 +@@ -73,7 +73,11 @@ + + private: + std::vector inputBuffer; ++#if BOOST_VERSION < 106600 + boost::asio::io_service* ioService; ++#else ++ boost::asio::io_context* ioService; ++#endif + boost::asio::serial_port* port; + boost::asio::deadline_timer* timer; + ComState comState; Property changes on: head/devel/msp430-debug-stack/files/patch-DLL430_v3_src_TI_DLL430_UsbCdcIoChannel.h ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property Index: head/devel/msp430-debug-stack/files/patch-ThirdParty_BSL430_DLL_BSL430_DLL_Physical_Interfaces_MSPBSL_PhysicalInterfaceSerialUART.cpp =================================================================== --- head/devel/msp430-debug-stack/files/patch-ThirdParty_BSL430_DLL_BSL430_DLL_Physical_Interfaces_MSPBSL_PhysicalInterfaceSerialUART.cpp (revision 455592) +++ head/devel/msp430-debug-stack/files/patch-ThirdParty_BSL430_DLL_BSL430_DLL_Physical_Interfaces_MSPBSL_PhysicalInterfaceSerialUART.cpp (revision 455593) @@ -1,37 +1,49 @@ ---- ThirdParty/BSL430_DLL/BSL430_DLL/Physical_Interfaces/MSPBSL_PhysicalInterfaceSerialUART.cpp.orig 2017-12-05 18:38:46.034235000 +0300 -+++ ThirdParty/BSL430_DLL/BSL430_DLL/Physical_Interfaces/MSPBSL_PhysicalInterfaceSerialUART.cpp 2017-12-05 18:39:30.622349000 +0300 -@@ -193,27 +193,27 @@ void MSPBSL_PhysicalInterfaceSerialUART: +--- ThirdParty/BSL430_DLL/BSL430_DLL/Physical_Interfaces/MSPBSL_PhysicalInterfaceSerialUART.cpp.orig 2017-12-05 19:25:19.310735000 +0300 ++++ ThirdParty/BSL430_DLL/BSL430_DLL/Physical_Interfaces/MSPBSL_PhysicalInterfaceSerialUART.cpp 2017-12-05 19:34:23.723027000 +0300 +@@ -129,7 +129,11 @@ + + + //TODO: Catch exception forunknown ports ++#if BOOST_VERSION < 106600 + io_service io; ++#else ++ io_context io; ++#endif + port = new serial_port( io, PORT ); + port->set_option( serial_port_base::character_size( 8 ) ); + port->set_option( serial_port_base::flow_control( serial_port_base::flow_control::none ) ); +@@ -193,27 +197,27 @@ port->set_option(RESETControl(LOW_SIGNAL)); port->set_option(TESTControl(LOW_SIGNAL)); - this_thread::sleep_for(chrono::milliseconds(10)); + this_thread::sleep_for(std::chrono::milliseconds(10)); port->set_option(TESTControl(HIGH_SIGNAL)); - this_thread::sleep_for(chrono::milliseconds(10)); + this_thread::sleep_for(std::chrono::milliseconds(10)); port->set_option(TESTControl(LOW_SIGNAL)); - this_thread::sleep_for(chrono::milliseconds(10)); + this_thread::sleep_for(std::chrono::milliseconds(10)); port->set_option(TESTControl(HIGH_SIGNAL)); - this_thread::sleep_for(chrono::milliseconds(10)); + this_thread::sleep_for(std::chrono::milliseconds(10)); if( method == STANDARD_INVOKE ) { port->set_option(RESETControl(HIGH_SIGNAL)); - this_thread::sleep_for(chrono::milliseconds(10)); + this_thread::sleep_for(std::chrono::milliseconds(10)); port->set_option(TESTControl(LOW_SIGNAL)); } else if ( method == BSL_XXXX_INVOKE ) { port->set_option(TESTControl(LOW_SIGNAL)); - this_thread::sleep_for(chrono::milliseconds(10)); + this_thread::sleep_for(std::chrono::milliseconds(10)); port->set_option(RESETControl(HIGH_SIGNAL)); } - this_thread::sleep_for(chrono::milliseconds(250)); + this_thread::sleep_for(std::chrono::milliseconds(250)); } Index: head/devel/msp430-debug-stack/files/patch-ThirdParty_BSL430_DLL_BSL430_DLL_Physical_Interfaces_MSPBSL_PhysicalInterfaceSerialUART.h =================================================================== --- head/devel/msp430-debug-stack/files/patch-ThirdParty_BSL430_DLL_BSL430_DLL_Physical_Interfaces_MSPBSL_PhysicalInterfaceSerialUART.h (nonexistent) +++ head/devel/msp430-debug-stack/files/patch-ThirdParty_BSL430_DLL_BSL430_DLL_Physical_Interfaces_MSPBSL_PhysicalInterfaceSerialUART.h (revision 455593) @@ -0,0 +1,13 @@ +--- ThirdParty/BSL430_DLL/BSL430_DLL/Physical_Interfaces/MSPBSL_PhysicalInterfaceSerialUART.h.orig 2017-12-05 19:35:16.469154000 +0300 ++++ ThirdParty/BSL430_DLL/BSL430_DLL/Physical_Interfaces/MSPBSL_PhysicalInterfaceSerialUART.h 2017-12-05 19:35:38.930835000 +0300 +@@ -72,6 +72,10 @@ + virtual std::string getErrorInformation( uint16_t err ); + + private: ++#if BOOST_VERSION < 106600 + boost::asio::io_service io; ++#else ++ boost::asio::io_context io; ++#endif + boost::asio::serial_port* port; + }; Property changes on: head/devel/msp430-debug-stack/files/patch-ThirdParty_BSL430_DLL_BSL430_DLL_Physical_Interfaces_MSPBSL_PhysicalInterfaceSerialUART.h ___________________________________________________________________ Added: fbsd:nokeywords ## -0,0 +1 ## +yes \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: svn:mime-type ## -0,0 +1 ## +text/plain \ No newline at end of property